Skip to content

Commit 6d6461b

Browse files
author
Vladimir Kotal
committed
compare dictionaries properly
1 parent de6b605 commit 6d6461b

File tree

1 file changed

+3
-2
lines changed

1 file changed

+3
-2
lines changed

opengrok-tools/src/test/python/test_mirror.py

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -287,7 +287,8 @@ def test_get_repos_for_project(monkeypatch):
287287
Test argument passing between get_repos_for_project() and get_repository()
288288
"""
289289
project_name = 'foo'
290-
proxy_dict = {}
290+
proxy_dict = {"http_proxy": "http://foo.bar:80",
291+
"https_proxy": "http://foo.bar:80"}
291292
git_cmd_path = "/foo/git"
292293
commands = {"git": git_cmd_path}
293294
timeout = 314159
@@ -318,7 +319,7 @@ def mock_get_repo_type(*args):
318319
git_repo = repos[0]
319320
assert git_repo.timeout == timeout
320321
assert git_repo.command == git_cmd_path
321-
assert git_repo.env == proxy_dict # XXX contains
322+
assert git_repo.env.items() >= proxy_dict.items()
322323

323324
# Now ignore the repository
324325
repos = get_repos_for_project(project_name, None, source_root,

0 commit comments

Comments
 (0)