Commits

Ian Cordasco committed 4463708

More tests and remove kruft

Comments (0)

Files changed (2)

test_uritemplate.py

         self.assertEqual(v.safe, '')
         self.assertEqual(v.start, '?')
 
+    def test_post_parse_ampersand(self):
+        v = self.v
+        v.operator = '&'
+        v.post_parse()
+        self.assertEqual(v.join_str, '&')
+        self.assertEqual(v.safe, '')
+        self.assertEqual(v.start, '&')
+
 
 class TestAPI(TestCase):
     uri = 'https://api.github.com{/endpoint}'

uritemplate/variable.py

         if self.operator == '?':
             self.start = '?'
             self.join_str = '&'
-        if self.operator == '&':
-            self.start = self.join_str = '&'
 
         if self.operator in ('+', '#'):
             self.safe = URIVariable.reserved