Skip to content

Commit

Permalink
gh-265: calculate fixture once per testing session (#266)
Browse files Browse the repository at this point in the history
Follows up #241. See explanation
of what the `scope` parameter does for `pytest.fixture`. Seems silly to
not use it (although in this case the speed-up will be minimal).
  • Loading branch information
paddyroddy authored Sep 25, 2024
1 parent a5ce1a9 commit f26c8c8
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion tests/conftest.py
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
import pytest


@pytest.fixture
@pytest.fixture(scope="session")
def rng():
import numpy as np

Expand Down

0 comments on commit f26c8c8

Please sign in to comment.