예제 #1
0
 def test_home_named_route(self):
     self.assertEqual('/', url_for('home'))
예제 #2
0
 def test_default_controller_view_url(self):
     self.assertEqual('/c/1', url_for(controller='c', action='view', id=1))
예제 #3
0
 def test_default_controller_action_url(self):
     for action in ['edit', 'update', 'delete']:
         self.assertEqual('/c/1/%s' % action,
                          url_for(controller='c', action=action, id=1))
예제 #4
0
 def test_default_controller_index_url(self):
     self.assertEqual('/c', url_for(controller='c', action='index'))
예제 #5
0
 def test_default_controller_new_url(self):
     self.assertEqual('/c/new', url_for(controller='c', action='new'))
예제 #6
0
 def test_home_named_route(self):
     self.assertEqual("/", url_for("home"))
예제 #7
0
 def test_default_controller_url(self):
     self.assertEqual('/c', url_for(controller='c'))
예제 #8
0
 def test_default_controller_action_url(self):
     for action in ["edit", "update", "delete"]:
         self.assertEqual("/c/1/%s" % action, url_for(controller="c", action=action, id=1))
예제 #9
0
 def test_default_controller_view_url(self):
     self.assertEqual("/c/1", url_for(controller="c", action="view", id=1))
예제 #10
0
 def test_default_controller_new_url(self):
     self.assertEqual("/c/new", url_for(controller="c", action="new"))
예제 #11
0
 def test_default_controller_index_url(self):
     self.assertEqual("/c", url_for(controller="c", action="index"))
예제 #12
0
 def test_default_controller_url(self):
     self.assertEqual("/c", url_for(controller="c"))