def setUp(self): super(TestSnapshotDelete, self).setUp() self.snapshots_mock.get.return_value = self.snapshot self.snapshots_mock.delete.return_value = None # Get the command object to mock self.cmd = snapshot.DeleteSnapshot(self.app, None)
def setUp(self): super(TestSnapshotDelete, self).setUp() self.snapshots_mock.get.return_value = fakes.FakeResource( None, copy.deepcopy(volume_fakes.SNAPSHOT), loaded=True) self.snapshots_mock.delete.return_value = None # Get the command object to mock self.cmd = snapshot.DeleteSnapshot(self.app, None)
def setUp(self): super(TestSnapshotDelete, self).setUp() self.snapshots_mock.get = ( volume_fakes.FakeSnapshot.get_snapshots(self.snapshots)) self.snapshots_mock.delete.return_value = None # Get the command object to mock self.cmd = snapshot.DeleteSnapshot(self.app, None)