Commit e4bd7efa authored by Łukasz Nowak's avatar Łukasz Nowak

Proof that stopped is no-op on destruction in progress.

parent a123ba25
......@@ -10,6 +10,60 @@ class TestVifibSlapComputerPartitionStopped(TestVifibSlapWebServiceMixin):
sequence_list.addSequenceString(sequence_string)
sequence_list.play(self)
def test_ComputerPartition_stopped_destroy_requested(self):
"""Checks that stopped does not raise in case if destroy was requested"""
sequence_list = SequenceList()
sequence_string = self\
.prepare_stopped_computer_partition_sequence_string + """
LoginTestVifibCustomer
RequestSoftwareInstanceDestroy
Tic
Logout
LoginDefaultUser
CheckComputerPartitionInstanceCleanupSalePackingListConfirmed
CheckComputerPartitionInstanceHostingSalePackingListDelivered
Logout
SlapLoginCurrentComputer
SoftwareInstanceStopped
Tic
SlapLogout
LoginDefaultUser
CheckComputerPartitionInstanceCleanupSalePackingListConfirmed
Logout
"""
sequence_list.addSequenceString(sequence_string)
sequence_list.play(self)
def test_ComputerPartition_stopped_destroy_requested_started(self):
"""Checks that stopped does not raise in case if destroy was requested
on started one"""
sequence_list = SequenceList()
sequence_string = self\
.prepare_started_computer_partition_sequence_string + """
LoginTestVifibCustomer
RequestSoftwareInstanceDestroy
Tic
Logout
LoginDefaultUser
CheckComputerPartitionInstanceCleanupSalePackingListConfirmed
Logout
SlapLoginCurrentComputer
SoftwareInstanceStopped
Tic
SlapLogout
LoginDefaultUser
CheckComputerPartitionInstanceCleanupSalePackingListConfirmed
Logout
"""
sequence_list.addSequenceString(sequence_string)
sequence_list.play(self)
def test_suite():
suite = unittest.TestSuite()
suite.addTest(unittest.makeSuite(TestVifibSlapComputerPartitionStopped))
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment