Show More
@@ -35,11 +35,13 b' from rhodecode.tests.fixture import Fixt' | |||||
35 |
|
35 | |||
36 | fixture = Fixture() |
|
36 | fixture = Fixture() | |
37 |
|
37 | |||
38 | NODE_HISTORY = { |
|
38 | ||
|
39 | def get_node_history(backend_type): | |||
|
40 | return { | |||
39 | 'hg': json.loads(fixture.load_resource('hg_node_history_response.json')), |
|
41 | 'hg': json.loads(fixture.load_resource('hg_node_history_response.json')), | |
40 | 'git': json.loads(fixture.load_resource('git_node_history_response.json')), |
|
42 | 'git': json.loads(fixture.load_resource('git_node_history_response.json')), | |
41 | 'svn': json.loads(fixture.load_resource('svn_node_history_response.json')), |
|
43 | 'svn': json.loads(fixture.load_resource('svn_node_history_response.json')), | |
42 | } |
|
44 | }[backend_type] | |
43 |
|
45 | |||
44 |
|
46 | |||
45 | def route_path(name, params=None, **kwargs): |
|
47 | def route_path(name, params=None, **kwargs): | |
@@ -297,7 +299,7 b' class TestFilesViews(object):' | |||||
297 | repo_name=backend.repo_name, |
|
299 | repo_name=backend.repo_name, | |
298 | commit_id='tip', f_path='vcs/nodes.py'), |
|
300 | commit_id='tip', f_path='vcs/nodes.py'), | |
299 | extra_environ=xhr_header) |
|
301 | extra_environ=xhr_header) | |
300 |
assert |
|
302 | assert get_node_history(backend.alias) == json.loads(response.body) | |
301 |
|
303 | |||
302 | def test_file_source_history_svn(self, backend_svn, xhr_header): |
|
304 | def test_file_source_history_svn(self, backend_svn, xhr_header): | |
303 | simple_repo = backend_svn['svn-simple-layout'] |
|
305 | simple_repo = backend_svn['svn-simple-layout'] | |
@@ -319,7 +321,7 b' class TestFilesViews(object):' | |||||
319 | params=dict(annotate=1)), |
|
321 | params=dict(annotate=1)), | |
320 |
|
322 | |||
321 | extra_environ=xhr_header) |
|
323 | extra_environ=xhr_header) | |
322 |
assert |
|
324 | assert get_node_history(backend.alias) == json.loads(response.body) | |
323 |
|
325 | |||
324 | def test_tree_search_top_level(self, backend, xhr_header): |
|
326 | def test_tree_search_top_level(self, backend, xhr_header): | |
325 | commit = backend.repo.get_commit(commit_idx=173) |
|
327 | commit = backend.repo.get_commit(commit_idx=173) |
General Comments 0
You need to be logged in to leave comments.
Login now