- assertEquals(gip.getContent(),
- gotGopm.get(gip.getPolicyId()).getProperties().values().iterator().next());
+ assertEquals(gip.getContent(), gotGopm.get(gip.getPolicyId()).getProperties().values().iterator().next());
+
+ Map<String, LegacyGuardPolicyOutput> updatedGopm = databaseProvider.updateGuardPolicy(gip);
+ assertEquals(gip.getPolicyId(), updatedGopm.keySet().iterator().next());
+ assertEquals(gip.getContent(), updatedGopm.get(gip.getPolicyId()).getProperties().values().iterator().next());
+
+ Map<String, LegacyGuardPolicyOutput> deletedGopm = databaseProvider.deleteGuardPolicy(gip.getPolicyId(), "1");
+ assertEquals(gip.getPolicyId(), deletedGopm.keySet().iterator().next());
+ assertEquals(gip.getContent(), deletedGopm.get(gip.getPolicyId()).getProperties().values().iterator().next());