Example #1
0
 def testCanonicalIncludesDateParam(self):
     s = ImageSetDesc(graph1, None, "/set?date=2010-11-20")
     self.assertEqual(s.canonicalSetUri(), SITE["set?date=2010-11-20"])
Example #2
0
 def testCanonicalIncludesDirParam(self):
     s = ImageSetDesc(graph1, None,
                      "/set?dir=http%3A%2F%2Fexample.com%2Fd1&current=foo")
     self.assertEqual(s.canonicalSetUri(),
                      SITE["set?dir=http%3A%2F%2Fexample.com%2Fd1"])
Example #3
0
 def testCanonicalIncludesStarParam(self):
     s = ImageSetDesc(graph1, None,
                      "/set?dir=http%3A%2F%2Fexample.com%2Fd1&star=only")
     self.assertEqual(
         s.canonicalSetUri(),
         SITE["set?dir=http%3A%2F%2Fexample.com%2Fd1&star=only"])
Example #4
0
 def testCanonicalOmitsCurrentParam(self):
     s = ImageSetDesc(graph1, None, "/set?tag=t&current=foo")
     self.assertEqual(s.canonicalSetUri(), SITE["set?tag=t"])
Example #5
0
 def testCanonicalIncludesDateParam(self):
     s = ImageSetDesc(graph1, None, "/set?date=2010-11-20")
     self.assertEqual(s.canonicalSetUri(), SITE["set?date=2010-11-20"])
Example #6
0
 def testCanonicalIncludesStarParam(self):
     s = ImageSetDesc(graph1, None, "/set?dir=http%3A%2F%2Fexample.com%2Fd1&star=only")
     self.assertEqual(s.canonicalSetUri(), SITE["set?dir=http%3A%2F%2Fexample.com%2Fd1&star=only"])
Example #7
0
 def testCanonicalIncludesDirParam(self):
     s = ImageSetDesc(graph1, None, "/set?dir=http%3A%2F%2Fexample.com%2Fd1&current=foo")
     self.assertEqual(s.canonicalSetUri(), SITE["set?dir=http%3A%2F%2Fexample.com%2Fd1"])
Example #8
0
 def testCanonicalOmitsCurrentParam(self):
     s = ImageSetDesc(graph1, None, "/set?tag=t&current=foo")
     self.assertEqual(s.canonicalSetUri(), SITE["set?tag=t"])