Commits

Ian Cordasco committed afb6824

Fix tests and imports

  • Participants
  • Parent commits 396fc8a

Comments (0)

Files changed (3)

File test_uritemplate.py

         t = URITemplate(uri)
         self.assertEqual(str(t), uri)
         self.assertEqual(str(t.variables[0]), '/endpoint')
-        self.assertEqual(repr(t), 'URITemplate(%s)' % uri)
+        self.assertEqual(repr(t), 'URITemplate("%s")' % uri)
         self.assertEqual(repr(t.variables[0]), 'URIVariable(/endpoint)')
 
     def test_hash(self):

File uritemplate/template.py

 """
 
 import re
-import collections
 from uritemplate.variable import URIVariable
 
 template_re = re.compile('{([^\}]+)}')

File uritemplate/variable.py

 except ImportError:
     # python 3
     from urllib.parse import quote
+import collections
 
 
 class URIVariable(object):