コード例 #1
0
 def tearDown(self):
     # Delete the test record in storage and revert storage to original
     # state.
     if self._testMethodName.startswith('test_post'):
         # Use 'id' of POST response
         IKEPolicy.get(id=self.uuid).delete()
     else:
         self.ikepolicy.delete()
コード例 #2
0
 def delete(self):
     IKEPolicy.get(id=self.id).delete()
コード例 #3
0
 def test_get_no_record(self):
     """Test case to fetch an IKEpolicy with invalid id."""
     with self.assertRaises(ResourceNotFound):
         IKEPolicy.get(id=generate_uuid())