def test_terminate_index_normal_video(self): """Test terminate_index_video""" test = TestSources(video_port=3000) test.running_tests_video = [ self.MockTest(1), self.MockTest(2), self.MockTest(3), self.MockTest(19)] test.terminate_index_video(0)
def test_terminate_index_normal_video(self): """Test terminate_index_video""" test = TestSources(video_port=3000) test.running_tests_video = [ self.MockTest(1), self.MockTest(2), self.MockTest(3), self.MockTest(19) ] test.terminate_index_video(0)
def test_terminate_index_error_video(self): """Test for terminate_video""" testsrc = TestSources(video_port=3000) testsrc.running_tests_video = [ self.MockTest(1), self.MockTest(2), self.MockTest(3), self.MockTest(19)] tests = [-100, 20, 1e10, "hi", [1, 2, 3]] for test in tests: with pytest.raises(InvalidIndexError): testsrc.terminate_index_video(test)
def test_terminate_index_error_video(self): """Test for terminate_video""" testsrc = TestSources(video_port=3000) testsrc.running_tests_video = [ self.MockTest(1), self.MockTest(2), self.MockTest(3), self.MockTest(19) ] tests = [-100, 20, 1e10, "hi", [1, 2, 3]] for test in tests: with pytest.raises(InvalidIndexError): testsrc.terminate_index_video(test)