def test_extract_frame_number_from_filepath_invalid_name(self): filepath = '/test/test/0209_f01_m01.jpg' with self.assertRaises(ValueError): actual = extract_visual_features.extract_frame_number_from_filepath( filepath)
def test_extract_frame_number_from_filepath_valid_name(self): filepath = '/test/test/0209_f01_m01_3004.jpg' actual = extract_visual_features.extract_frame_number_from_filepath( filepath) expected = 3004 self.assertEqual(actual, expected)
def test_extract_frame_number_from_filepath_no_name(self): filepath = '' with self.assertRaises(ValueError): actual = extract_visual_features.extract_frame_number_from_filepath( filepath)
def test_extract_frame_number_from_filepath_invalid_name(self): filepath = '/test/test/0209_f01_m01.jpg' with self.assertRaises(ValueError): actual = extract_visual_features.extract_frame_number_from_filepath(filepath)
def test_extract_frame_number_from_filepath_valid_name(self): filepath = '/test/test/0209_f01_m01_3004.jpg' actual = extract_visual_features.extract_frame_number_from_filepath(filepath) expected = 3004 self.assertEqual(actual, expected)
def test_extract_frame_number_from_filepath_no_name(self): filepath = '' with self.assertRaises(ValueError): actual = extract_visual_features.extract_frame_number_from_filepath(filepath)