##// END OF EJS Templates
fix(tests): fixed vcs tests after changes to how headers are passed in VCS calls
super-admin -
r5189:5635ef4e default
parent child Browse files
Show More
@@ -99,8 +99,7 b' def test_repo_maker_uses_session_for_cla'
99 'server_and_port', 'endpoint', 'test_dummy_scm', stub_session_factory)
99 'server_and_port', 'endpoint', 'test_dummy_scm', stub_session_factory)
100 repo_maker.example_call()
100 repo_maker.example_call()
101 stub_session_factory().post.assert_called_with(
101 stub_session_factory().post.assert_called_with(
102 'http://server_and_port/endpoint', data=mock.ANY,
102 'http://server_and_port/endpoint', data=mock.ANY)
103 headers={'X-RC-Method': 'example_call', 'X-RC-Repo-Name': None})
104
103
105
104
106 def test_repo_maker_uses_session_for_instance_methods(
105 def test_repo_maker_uses_session_for_instance_methods(
@@ -110,8 +109,7 b' def test_repo_maker_uses_session_for_ins'
110 repo = repo_maker('stub_path', 'stub_repo_id', config)
109 repo = repo_maker('stub_path', 'stub_repo_id', config)
111 repo.example_call()
110 repo.example_call()
112 stub_session_factory().post.assert_called_with(
111 stub_session_factory().post.assert_called_with(
113 'http://server_and_port/endpoint', data=mock.ANY,
112 'http://server_and_port/endpoint', data=mock.ANY)
114 headers={'X-RC-Method': 'example_call', 'X-RC-Repo-Name': 'stub_path'})
115
113
116
114
117 @mock.patch('rhodecode.lib.vcs.client_http.ThreadlocalSessionFactory')
115 @mock.patch('rhodecode.lib.vcs.client_http.ThreadlocalSessionFactory')
General Comments 0
You need to be logged in to leave comments. Login now