Skip to content

Commit f6524d7

Browse files
committed
Updated makefile and e2e tests
1 parent 0fc4c1a commit f6524d7

2 files changed

Lines changed: 12 additions & 4 deletions

File tree

e2e_batch/Makefile

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
11
-include .env
22

33
run-immunization-batch:
4-
ENV=$(environment) python -m unittest -v -c
4+
ENVIRONMENT=$(environment) poetry run python -m unittest -v -c

e2e_batch/test_e2e_batch.py

Lines changed: 11 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -37,7 +37,6 @@ def tearDown(self):
3737
delete_file_from_s3(ACK_BUCKET, ack_key)
3838

3939
if environment != "ref":
40-
# TODO: Clenaup functionality after each test
4140
def test_create_success(self):
4241
"""Test CREATE scenario."""
4342
input_file = generate_csv("PHYLIS", "0.3", action_flag="CREATE")
@@ -183,9 +182,13 @@ def test_header_name_validation_error(self):
183182
ack_content = get_file_content_from_s3(ACK_BUCKET, ack_key)
184183
check_ack_file_content(ack_content, "Failure", FILE_NAME_VAL_ERROR, None)
185184

185+
# This test updates the permissions_config.json file from the imms-internal-dev-supplier-config
186+
# S3 bucket shared across multiple environments (PR environments, internal-dev, int, and ref).
187+
# Running this may modify permissions in these environments, causing unintended side effects.
188+
@unittest.skip("Modifies shared S3 permissions configuration")
186189
def test_invalid_permission(self):
187190
"""Test INVALID-PERMISSION error scenario."""
188-
upload_config_file("MMR_FULL")
191+
upload_config_file("MMR_FULL") # permissions_config.json is updated here
189192
time.sleep(20)
190193

191194
input_file = generate_csv("PHYLIS", "0.3", action_flag="CREATE")
@@ -207,8 +210,13 @@ def test_invalid_permission(self):
207210
def test_end_to_end_speed_test_with_100000_rows(self):
208211
"""Test end_to_end_speed_test_with_100000_rows scenario with full integration"""
209212
input_file = generate_csv_with_ordered_100000_rows(None)
210-
upload_file_to_s3(input_file, SOURCE_BUCKET, INPUT_PREFIX)
213+
214+
key = upload_file_to_s3(input_file, SOURCE_BUCKET, INPUT_PREFIX)
215+
self.uploaded_files.append(key)
216+
211217
final_ack_key = wait_for_ack_file(None, input_file, timeout=1800)
218+
self.ack_files.append(final_ack_key)
219+
212220
response = verify_final_ack_file(final_ack_key)
213221
assert response is True
214222

0 commit comments

Comments
 (0)