コード例 #1
0
ファイル: tests.py プロジェクト: dimastark/python3-tasks
 def test_19(self):
     """ Test case 19 """
     inf = g.GifInfo(os.path.join(DIR, '..', 'test_files/19.gif'))
     self.assertTrue(inf.loops == "Infinity")
コード例 #2
0
ファイル: tests.py プロジェクト: dimastark/python3-tasks
 def test_17(self):
     """ Test case 17 """
     with self.assertRaises(ValueError):
         g.GifInfo(os.path.join(DIR, '..', 'test_files/17.gif'))
コード例 #3
0
ファイル: tests.py プロジェクト: dimastark/python3-tasks
 def test_18(self):
     """ Test case 18 """
     inf = g.GifInfo(os.path.join(DIR, '..', 'test_files/18.gif'))
     self.assertAlmostEqual(inf.aratio, 0)
コード例 #4
0
ファイル: tests.py プロジェクト: dimastark/python3-tasks
 def test_14(self):
     """ Test case 14 """
     inf = g.GifInfo(os.path.join(DIR, '..', 'test_files/14.gif'))
     self.assertTrue(len(inf.frames) > 100)
コード例 #5
0
ファイル: tests.py プロジェクト: dimastark/python3-tasks
 def test_16(self):
     """ Test case 16 """
     inf = g.GifInfo(os.path.join(DIR, '..', 'test_files/16.gif'))
     self.assertTrue(inf.frames)
コード例 #6
0
ファイル: tests.py プロジェクト: dimastark/python3-tasks
 def test_header(self):
     """ Parse title """
     inf = g.GifInfo(os.path.join(DIR, '..', 'test_files/col.gif'))
     self.assertTrue(inf.size[0] == inf.size[1])
コード例 #7
0
ファイル: tests.py プロジェクト: dimastark/python3-tasks
 def test_7(self):
     """ Test case 7 """
     inf = g.GifInfo(os.path.join(DIR, '..', 'test_files/7.gif'))
     self.assertTrue(len(inf.frames) == 7)
コード例 #8
0
ファイル: tests.py プロジェクト: dimastark/python3-tasks
 def test_extensions(self):
     """ Parse extensions """
     inf1 = g.GifInfo(os.path.join(DIR, '..', 'test_files/comm.gif'))
     inf2 = g.GifInfo(os.path.join(DIR, '..', 'test_files/col.gif'))
     inf3 = g.GifInfo(os.path.join(DIR, '..', 'test_files/frames.gif'))
     self.assertEqual(inf1.spec, inf2.spec, inf3.spec)
コード例 #9
0
ファイル: tests.py プロジェクト: dimastark/python3-tasks
 def test_frames(self):
     """ Parse frames """
     inf = g.GifInfo(os.path.join(DIR, '..', 'test_files/frames.gif'))
     self.assertTrue(len(inf.frames) == 16)
コード例 #10
0
ファイル: tests.py プロジェクト: dimastark/python3-tasks
 def test_colors(self):
     """  Parse colors table """
     inf = g.GifInfo(os.path.join(DIR, '..', 'test_files/col.gif'))
     self.assertTrue(len(inf.colors) == 4)
コード例 #11
0
ファイル: tests.py プロジェクト: dimastark/python3-tasks
 def test_comments(self):
     """ Parse comments ext """
     inf = g.GifInfo(os.path.join(DIR, '..', 'test_files/comm.gif'))
     self.assertTrue(len(inf.comments) > 0)
コード例 #12
0
ファイル: tests.py プロジェクト: dimastark/python3-tasks
 def test_20(self):
     """ Test case 20 """
     inf = g.GifInfo(os.path.join(DIR, '..', 'test_files/20.gif'))
     self.assertTrue(inf.loops == len(inf.frames))