Example #1
0
 def test_it_should_tell_the_truth_about_MP4_files(self):
     test_file = File('/path/to/file.MP4')
     self.assertFalse(test_file.is_image())
     self.assertTrue(test_file.is_video())
     self.assertEqual(test_file.filename(), '/path/to/file.MP4')
     self.assertEqual(test_file.ext(), '.mp4')
     self.assertEqual(test_file.media_type(), 'MP4')
     self.assertEqual(test_file.date_taken_tag(), 'QuickTime:CreateDate')
     self.assertEqual(test_file.rotation_tag(), 'Composite:Rotation')
Example #2
0
 def test_it_should_tell_the_truth_about_MTS_files(self):
     test_file = File('/path/to/file.MTS')
     self.assertFalse(test_file.is_image())
     self.assertTrue(test_file.is_video())
     self.assertEqual(test_file.filename(), '/path/to/file.MTS')
     self.assertEqual(test_file.ext(), '.mts')
     self.assertEqual(test_file.media_type(), 'MTS')
     self.assertEqual(test_file.date_taken_tag(), 'H264:DateTimeOriginal')
     self.assertEqual(test_file.rotation_tag(), 'Composite:Rotation')
Example #3
0
 def test_it_should_tell_the_truth_about_JPEG_files(self):
     test_file = File('/path/to/file.JPEG')
     self.assertTrue(test_file.is_image())
     self.assertFalse(test_file.is_video())
     self.assertEqual(test_file.filename(), '/path/to/file.JPEG')
     self.assertEqual(test_file.ext(), '.jpeg')
     self.assertEqual(test_file.media_type(), 'JPEG')
     self.assertEqual(test_file.date_taken_tag(), 'EXIF:DateTimeOriginal')
     self.assertEqual(test_file.rotation_tag(), 'EXIF:Orientation')