File tree Expand file tree Collapse file tree 2 files changed +4
-4
lines changed
Expand file tree Collapse file tree 2 files changed +4
-4
lines changed Original file line number Diff line number Diff line change @@ -75,15 +75,15 @@ def handler(event, context):
7575 logger .info (f"Record from DPS skipped for { imms_id } " )
7676 return {"statusCode" : 200 , "body" : f"Record from DPS skipped for { imms_id } " }
7777 else :
78- operation = OperationName .DELETE
78+ operation = OperationName .DELETE_PHYSICAL
7979 new_image = record ["dynamodb" ]["Keys" ]
8080 logger .info (f"Record to delta:{ new_image } " )
8181 imms_id = new_image ["PK" ]["S" ].split ("#" )[1 ]
8282 response = delta_table .put_item (
8383 Item = {
8484 "PK" : str (uuid .uuid4 ()),
8585 "ImmsID" : imms_id ,
86- "Operation" : OperationName .DELETE ,
86+ "Operation" : OperationName .DELETE_PHYSICAL ,
8787 "VaccineType" : "default" ,
8888 "SupplierSystem" : "default" ,
8989 "DateTimeStamp" : approximate_creation_time .isoformat (),
Original file line number Diff line number Diff line change @@ -183,8 +183,8 @@ def test_handler_imms_convert_to_flat_json(self):
183183 """Test that the Imms field contains the correct flat JSON data for CREATE, UPDATE, and DELETE operations."""
184184 expected_action_flags = [
185185 {"Operation" : OperationName .CREATE , "EXPECTED_ACTION_FLAG" : ActionFlag .CREATE },
186- # {"Operation": OperationName.UPDATE, "EXPECTED_ACTION_FLAG": ActionFlag.UPDATE},
187- # {"Operation": OperationName.DELETE , "EXPECTED_ACTION_FLAG": ActionFlag..DELETE },
186+ {"Operation" : OperationName .UPDATE , "EXPECTED_ACTION_FLAG" : ActionFlag .UPDATE },
187+ {"Operation" : OperationName .DELETE_PHYSICAL , "EXPECTED_ACTION_FLAG" : ActionFlag .DELETE_PHYSICAL },
188188 ]
189189
190190 for test_case in expected_action_flags :
You can’t perform that action at this time.
0 commit comments