Fix test failure on float

due to rounding, the values are just 'almost' equal.
This commit is contained in:
Björn Pedersen 2015-02-23 11:19:32 +01:00
parent 1f11fc7be5
commit 0238a80e24

View File

@ -37,8 +37,8 @@ class TestFileTiffMetadata(PillowTestCase):
self.assertEqual(loaded.tag[50838], (len(textdata),))
self.assertEqual(loaded.tag[50839], textdata)
self.assertEqual(loaded.tag[tag_ids['RollAngle']], floatdata)
self.assertEqual(loaded.tag[tag_ids['YawAngle']], doubledata)
self.assertAlmostEqual(loaded.tag[tag_ids['RollAngle']], floatdata)
self.assertAlmostEqual(loaded.tag[tag_ids['YawAngle']], doubledata)
def test_read_metadata(self):
img = Image.open('Tests/images/hopper_g4.tif')