Show More
@@ -112,6 +112,7 b' class TestGitServer(object):' | |||
|
112 | 112 | with patch('os.environ', {'SSH_CLIENT': '10.10.10.10 b'}): |
|
113 | 113 | with patch('os.putenv') as putenv_mock: |
|
114 | 114 | server._update_environment() |
|
115 | ||
|
115 | 116 | expected_data = { |
|
116 | 117 | "username": git_server.user, |
|
117 | 118 | "scm": "git", |
@@ -122,8 +123,8 b' class TestGitServer(object):' | |||
|
122 | 123 | "locked_by": [None, None], |
|
123 | 124 | "config": "" |
|
124 | 125 | } |
|
125 | putenv_mock.assert_called_once_with( | |
|
126 | 'RC_SCM_DATA', json.dumps(expected_data)) | |
|
126 | args, kwargs = putenv_mock.call_args | |
|
127 | assert json.loads(args[1]) == expected_data | |
|
127 | 128 | |
|
128 | 129 | |
|
129 | 130 | class TestGitServerCheckPermissions(object): |
@@ -83,7 +83,7 b' def test_get_config(pylonsapp, user_util' | |||
|
83 | 83 | app = simplehg.SimpleHg(application=None, |
|
84 | 84 | config={'auth_ret_code': '', 'base_path': ''}, |
|
85 | 85 | registry=None) |
|
86 |
extras = |
|
|
86 | extras = [('foo', 'FOO', 'bar', 'BAR')] | |
|
87 | 87 | |
|
88 | 88 | hg_config = app._create_config(extras, repo_name=repo.repo_name) |
|
89 | 89 | |
@@ -110,7 +110,7 b' def test_get_config(pylonsapp, user_util' | |||
|
110 | 110 | ('phases', 'publish', 'True'), |
|
111 | 111 | ('extensions', 'largefiles', ''), |
|
112 | 112 | ('paths', '/', hg_config_org.get('paths', '/')), |
|
113 |
('rhodecode', 'RC_SCM_DATA', ' |
|
|
113 | ('rhodecode', 'RC_SCM_DATA', '[["foo", "FOO", "bar", "BAR"]]') | |
|
114 | 114 | ] |
|
115 | 115 | for entry in expected_config: |
|
116 | 116 | assert entry in hg_config |
General Comments 0
You need to be logged in to leave comments.
Login now