Skip to content

Commit 090535d

Browse files
Dedupe faker fixture.
1 parent 8e9c2e2 commit 090535d

File tree

3 files changed

+6
-10
lines changed

3 files changed

+6
-10
lines changed

tests/conftest.py

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,5 @@
11
import pytest
2+
from faker import Faker
23
from flask import Flask
34
from flask.testing import FlaskClient
45

@@ -13,3 +14,8 @@ def app() -> Flask:
1314
@pytest.fixture(scope="session")
1415
def client(app) -> FlaskClient:
1516
return app.test_client()
17+
18+
19+
@pytest.fixture(scope="session")
20+
def faker() -> Faker:
21+
return Faker("en_UK")

tests/integration/conftest.py

Lines changed: 0 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -30,11 +30,6 @@
3030
AWS_REGION = "eu-west-1"
3131

3232

33-
@pytest.fixture(scope="session")
34-
def faker() -> Faker:
35-
return Faker("en_UK")
36-
37-
3833
@pytest.fixture(scope="session")
3934
def localstack(request: pytest.FixtureRequest) -> URL:
4035
if url := os.getenv("RUNNING_LOCALSTACK_URL", None):

tests/unit/services/test_eligibility_services.py

Lines changed: 0 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -16,11 +16,6 @@
1616
from tests.fixtures.matchers.eligibility import is_condition, is_eligibility_status
1717

1818

19-
@pytest.fixture(scope="session")
20-
def faker() -> Faker:
21-
return Faker("en_UK")
22-
23-
2419
def test_eligibility_service_returns_from_repo():
2520
# Given
2621
person_repo = MagicMock(spec=PersonRepo)

0 commit comments

Comments
 (0)