diff --git a/src/eligibility_signposting_api/app.py b/src/eligibility_signposting_api/app.py index 98dd5b9b..623642bd 100644 --- a/src/eligibility_signposting_api/app.py +++ b/src/eligibility_signposting_api/app.py @@ -35,7 +35,7 @@ def create_app() -> Flask: logger.info("app created") # Register views & error handler - app.register_blueprint(eligibility_blueprint, url_prefix="/eligibility") + app.register_blueprint(eligibility_blueprint, url_prefix="/patient-check") app.register_error_handler(Exception, handle_exception) # Set up dependency injection using wireup diff --git a/tests/integration/in_process/test_eligibility_endpoint.py b/tests/integration/in_process/test_eligibility_endpoint.py index f587e7d6..59c32746 100644 --- a/tests/integration/in_process/test_eligibility_endpoint.py +++ b/tests/integration/in_process/test_eligibility_endpoint.py @@ -13,7 +13,7 @@ def test_nhs_number_given(client: FlaskClient, persisted_person: NHSNumber, camp # Given # When - response = client.get(f"/eligibility/{persisted_person}") + response = client.get(f"/patient-check/{persisted_person}") # Then assert_that( @@ -26,7 +26,7 @@ def test_no_nhs_number_given(client: FlaskClient): # Given # When - response = client.get("/eligibility/") + response = client.get("/patient-check/") # Then assert_that( @@ -41,7 +41,7 @@ def test_actionable_by_rule(client: FlaskClient, persisted_77yo_person: NHSNumbe # Given # When - response = client.get(f"/eligibility/{persisted_77yo_person}") + response = client.get(f"/patient-check/{persisted_77yo_person}") # Then assert_that( @@ -58,7 +58,7 @@ def test_not_actionable_by_rule(client: FlaskClient, persisted_person: NHSNumber # Given # When - response = client.get(f"/eligibility/{persisted_person}") + response = client.get(f"/patient-check/{persisted_person}") # Then assert_that( diff --git a/tests/integration/lambda/test_app_running_as_lambda.py b/tests/integration/lambda/test_app_running_as_lambda.py index 0705a2f6..a8acc537 100644 --- a/tests/integration/lambda/test_app_running_as_lambda.py +++ b/tests/integration/lambda/test_app_running_as_lambda.py @@ -39,7 +39,7 @@ def test_install_and_call_lambda_flask( "http": { "sourceIp": "192.0.0.1", "method": "GET", - "path": f"/eligibility/{persisted_person}", + "path": f"/patient-check/{persisted_person}", "protocol": "HTTP/1.1", } }, @@ -76,7 +76,7 @@ def test_install_and_call_flask_lambda_over_http( # Given # When - response = httpx.get(str(flask_function_url / "eligibility" / persisted_person)) + response = httpx.get(str(flask_function_url / "patient-check" / persisted_person)) # Then assert_that( @@ -97,7 +97,7 @@ def test_install_and_call_flask_lambda_with_unknown_nhs_number( nhs_number = NHSNumber(faker.nhs_number()) # When - response = httpx.get(str(flask_function_url / "eligibility" / nhs_number)) + response = httpx.get(str(flask_function_url / "patient-check" / nhs_number)) # Then assert_that( diff --git a/tests/unit/views/test_eligibility.py b/tests/unit/views/test_eligibility.py index 8ca6d23a..f93d833f 100644 --- a/tests/unit/views/test_eligibility.py +++ b/tests/unit/views/test_eligibility.py @@ -43,7 +43,7 @@ def test_nhs_number_given(app: Flask, client: FlaskClient): # Given with get_app_container(app).override.service(EligibilityService, new=FakeEligibilityService()): # When - response = client.get("/eligibility/12345") + response = client.get("/patient-check/12345") # Then assert_that( @@ -56,7 +56,7 @@ def test_no_nhs_number_given(app: Flask, client: FlaskClient): # Given with get_app_container(app).override.service(EligibilityService, new=FakeUnknownPersonEligibilityService()): # When - response = client.get("/eligibility/") + response = client.get("/patient-check/") # Then assert_that( @@ -81,7 +81,7 @@ def test_no_nhs_number_given(app: Flask, client: FlaskClient): def test_unexpected_error(app: Flask, client: FlaskClient): # Given with get_app_container(app).override.service(EligibilityService, new=FakeUnexpectedErrorEligibilityService()): - response = client.get("/eligibility/12345") + response = client.get("/patient-check/12345") assert_that( response, is_response()