aboutsummaryrefslogtreecommitdiffstats
path: root/unittest/iptc.py
diff options
context:
space:
mode:
authorOlivier Tilloy <olivier@tilloy.net>2009-02-24 19:49:45 +0100
committerOlivier Tilloy <olivier@tilloy.net>2009-02-24 19:49:45 +0100
commitb7dfe1a41b0afca712384d67271fef0a4a860df4 (patch)
treed8d2b00d440e64b7db7f4ccd121ac42251b5dab6 /unittest/iptc.py
parent8ae2364a45e96c8afbb07ebb0499004092c1ba71 (diff)
downloadpyexiv2-b7dfe1a41b0afca712384d67271fef0a4a860df4.tar.gz
IPTC Undefined conversion.
Diffstat (limited to 'unittest/iptc.py')
-rw-r--r--unittest/iptc.py8
1 files changed, 7 insertions, 1 deletions
diff --git a/unittest/iptc.py b/unittest/iptc.py
index 43e5313..dee5383 100644
--- a/unittest/iptc.py
+++ b/unittest/iptc.py
@@ -82,4 +82,10 @@ class TestIptcTag(unittest.TestCase):
self.failUnlessRaises(IptcValueError, IptcTag._convert_to_python, '21:12:98+00:00', xtype)
self.failUnlessRaises(IptcValueError, IptcTag._convert_to_python, '081242+0000', xtype)
- # TODO: other types
+ def test_convert_to_python_undefined(self):
+ xtype = 'Undefined'
+ # Valid values
+ self.assertEqual(IptcTag._convert_to_python('Some binary data.', xtype),
+ 'Some binary data.')
+ self.assertEqual(IptcTag._convert_to_python('�lj1�eEϟ�u����ᒻ;C(�SpI]���QI�}', xtype),
+ '�lj1�eEϟ�u����ᒻ;C(�SpI]���QI�}')