99import os
1010
1111
12- @pytest .mark .smoketest
1312def test_ping (nhsd_apim_proxy_url ):
1413 os .environ ["PROXY_NAME" ] = "dev"
1514 # print(env)
1615 resp = requests .get (f"{ nhsd_apim_proxy_url } /_ping" )
1716 assert resp .status_code == 200
1817
1918
20- @pytest .mark .smoketest
2119def test_wait_for_ping (nhsd_apim_proxy_url ):
2220 retries = 0
2321 resp = requests .get (f"{ nhsd_apim_proxy_url } /_ping" )
24- deployed_commitId = resp .json ().get ("commitId" )
22+ deployed_commit_id = resp .json ().get ("commitId" )
2523
26- while (deployed_commitId != getenv ('SOURCE_COMMIT_ID' )
24+ while (deployed_commit_id != getenv ('SOURCE_COMMIT_ID' )
2725 and retries <= 30
2826 and resp .status_code == 200 ):
2927 resp = requests .get (f"{ nhsd_apim_proxy_url } /_ping" )
30- deployed_commitId = resp .json ().get ("commitId" )
28+ deployed_commit_id = resp .json ().get ("commitId" )
3129 retries += 1
3230
3331 if resp .status_code != 200 :
3432 pytest .fail (f"Status code { resp .status_code } , expecting 200" )
3533 elif retries >= 30 :
3634 pytest .fail ("Timeout Error - max retries" )
3735
38- assert deployed_commitId == getenv ('SOURCE_COMMIT_ID' )
36+ assert deployed_commit_id == getenv ('SOURCE_COMMIT_ID' )
3937
4038
4139@pytest .mark .smoketest
40+ @pytest .mark .skip (reason = "No longer required 30/10/2023" )
4241def test_status (nhsd_apim_proxy_url , status_endpoint_auth_headers ):
4342 resp = requests .get (
4443 f"{ nhsd_apim_proxy_url } /_status" , headers = status_endpoint_auth_headers
@@ -47,18 +46,17 @@ def test_status(nhsd_apim_proxy_url, status_endpoint_auth_headers):
4746 # Make some additional assertions about your status response here!
4847
4948
50- @pytest .mark .smoketest
5149def test_wait_for_status (nhsd_apim_proxy_url , status_endpoint_auth_headers ):
5250 retries = 0
5351 resp = requests .get (f"{ nhsd_apim_proxy_url } /_status" , headers = status_endpoint_auth_headers )
54- deployed_commitId = resp .json ().get ("commitId" )
52+ deployed_commit_id = resp .json ().get ("commitId" )
5553
56- while (deployed_commitId != getenv ('SOURCE_COMMIT_ID' )
54+ while (deployed_commit_id != getenv ('SOURCE_COMMIT_ID' )
5755 and retries <= 30
5856 and resp .status_code == 200
5957 and resp .json ().get ("version" )):
6058 resp = requests .get (f"{ nhsd_apim_proxy_url } /_status" , headers = status_endpoint_auth_headers )
61- deployed_commitId = resp .json ().get ("commitId" )
59+ deployed_commit_id = resp .json ().get ("commitId" )
6260 retries += 1
6361
6462 if resp .status_code != 200 :
@@ -68,7 +66,7 @@ def test_wait_for_status(nhsd_apim_proxy_url, status_endpoint_auth_headers):
6866 elif not resp .json ().get ("version" ):
6967 pytest .fail ("version not found" )
7068
71- assert deployed_commitId == getenv ('SOURCE_COMMIT_ID' )
69+ assert deployed_commit_id == getenv ('SOURCE_COMMIT_ID' )
7270
7371
7472def test_app_unauthorised (nhsd_apim_proxy_url , nhsd_apim_auth_headers ):
0 commit comments