1171
Marcin Kuzminski <marcin@python-works.com>
parents:
diff
changeset
|
1 from rhodecode.tests import *
|
Marcin Kuzminski <marcin@python-works.com>
parents:
diff
changeset
|
2
|
Marcin Kuzminski <marcin@python-works.com>
parents:
diff
changeset
|
3 class TestReposGroupsController(TestController):
|
Marcin Kuzminski <marcin@python-works.com>
parents:
diff
changeset
|
4
|
Marcin Kuzminski <marcin@python-works.com>
parents:
diff
changeset
|
5 def test_index(self):
|
Marcin Kuzminski <marcin@python-works.com>
parents:
diff
changeset
|
6 response = self.app.get(url('repos_groups'))
|
Marcin Kuzminski <marcin@python-works.com>
parents:
diff
changeset
|
7 # Test response...
|
Marcin Kuzminski <marcin@python-works.com>
parents:
diff
changeset
|
8
|
Marcin Kuzminski <marcin@python-works.com>
parents:
diff
changeset
|
9 def test_index_as_xml(self):
|
Marcin Kuzminski <marcin@python-works.com>
parents:
diff
changeset
|
10 response = self.app.get(url('formatted_repos_groups', format='xml'))
|
Marcin Kuzminski <marcin@python-works.com>
parents:
diff
changeset
|
11
|
Marcin Kuzminski <marcin@python-works.com>
parents:
diff
changeset
|
12 def test_create(self):
|
Marcin Kuzminski <marcin@python-works.com>
parents:
diff
changeset
|
13 response = self.app.post(url('repos_groups'))
|
Marcin Kuzminski <marcin@python-works.com>
parents:
diff
changeset
|
14
|
Marcin Kuzminski <marcin@python-works.com>
parents:
diff
changeset
|
15 def test_new(self):
|
Marcin Kuzminski <marcin@python-works.com>
parents:
diff
changeset
|
16 response = self.app.get(url('new_repos_group'))
|
Marcin Kuzminski <marcin@python-works.com>
parents:
diff
changeset
|
17
|
Marcin Kuzminski <marcin@python-works.com>
parents:
diff
changeset
|
18 def test_new_as_xml(self):
|
Marcin Kuzminski <marcin@python-works.com>
parents:
diff
changeset
|
19 response = self.app.get(url('formatted_new_repos_group', format='xml'))
|
Marcin Kuzminski <marcin@python-works.com>
parents:
diff
changeset
|
20
|
Marcin Kuzminski <marcin@python-works.com>
parents:
diff
changeset
|
21 def test_update(self):
|
Marcin Kuzminski <marcin@python-works.com>
parents:
diff
changeset
|
22 response = self.app.put(url('repos_group', id=1))
|
Marcin Kuzminski <marcin@python-works.com>
parents:
diff
changeset
|
23
|
Marcin Kuzminski <marcin@python-works.com>
parents:
diff
changeset
|
24 def test_update_browser_fakeout(self):
|
Marcin Kuzminski <marcin@python-works.com>
parents:
diff
changeset
|
25 response = self.app.post(url('repos_group', id=1), params=dict(_method='put'))
|
Marcin Kuzminski <marcin@python-works.com>
parents:
diff
changeset
|
26
|
Marcin Kuzminski <marcin@python-works.com>
parents:
diff
changeset
|
27 def test_delete(self):
|
Marcin Kuzminski <marcin@python-works.com>
parents:
diff
changeset
|
28 response = self.app.delete(url('repos_group', id=1))
|
Marcin Kuzminski <marcin@python-works.com>
parents:
diff
changeset
|
29
|
Marcin Kuzminski <marcin@python-works.com>
parents:
diff
changeset
|
30 def test_delete_browser_fakeout(self):
|
Marcin Kuzminski <marcin@python-works.com>
parents:
diff
changeset
|
31 response = self.app.post(url('repos_group', id=1), params=dict(_method='delete'))
|
Marcin Kuzminski <marcin@python-works.com>
parents:
diff
changeset
|
32
|
Marcin Kuzminski <marcin@python-works.com>
parents:
diff
changeset
|
33 def test_show(self):
|
Marcin Kuzminski <marcin@python-works.com>
parents:
diff
changeset
|
34 response = self.app.get(url('repos_group', id=1))
|
Marcin Kuzminski <marcin@python-works.com>
parents:
diff
changeset
|
35
|
Marcin Kuzminski <marcin@python-works.com>
parents:
diff
changeset
|
36 def test_show_as_xml(self):
|
Marcin Kuzminski <marcin@python-works.com>
parents:
diff
changeset
|
37 response = self.app.get(url('formatted_repos_group', id=1, format='xml'))
|
Marcin Kuzminski <marcin@python-works.com>
parents:
diff
changeset
|
38
|
Marcin Kuzminski <marcin@python-works.com>
parents:
diff
changeset
|
39 def test_edit(self):
|
Marcin Kuzminski <marcin@python-works.com>
parents:
diff
changeset
|
40 response = self.app.get(url('edit_repos_group', id=1))
|
Marcin Kuzminski <marcin@python-works.com>
parents:
diff
changeset
|
41
|
Marcin Kuzminski <marcin@python-works.com>
parents:
diff
changeset
|
42 def test_edit_as_xml(self):
|
Marcin Kuzminski <marcin@python-works.com>
parents:
diff
changeset
|
43 response = self.app.get(url('formatted_edit_repos_group', id=1, format='xml'))
|