Exemple #1
0
 def test_default_controller_url(self):
     self.assertEqual('/c',
                     url_for(controller='c'))
Exemple #2
0
 def test_home_named_route(self):
     self.assertEqual('/',
                      url_for('home'))
Exemple #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))
Exemple #4
0
 def test_default_controller_view_url(self):
     self.assertEqual('/c/1',
                      url_for(controller='c', action='view', id=1))
Exemple #5
0
 def test_default_controller_new_url(self):
     self.assertEqual('/c/new',
                      url_for(controller='c', action='new'))
Exemple #6
0
 def test_default_controller_index_url(self):
     self.assertEqual('/c',
                      url_for(controller='c', action='index'))