summaryrefslogtreecommitdiffstats
path: root/tests/test_utils.py
diff options
context:
space:
mode:
authorDaniel Baumann <daniel.baumann@progress-linux.org>2023-07-13 05:37:58 +0000
committerDaniel Baumann <daniel.baumann@progress-linux.org>2023-07-13 05:37:58 +0000
commit335c010ac5fbaf2bc33cb7f28ceac3d5bfffb677 (patch)
tree35bf32721245769d8287281a8a85ba1e3fcb40d9 /tests/test_utils.py
parentReleasing debian version 0.16.3-2. (diff)
downloadgita-335c010ac5fbaf2bc33cb7f28ceac3d5bfffb677.tar.xz
gita-335c010ac5fbaf2bc33cb7f28ceac3d5bfffb677.zip
Merging upstream version 0.16.4.
Signed-off-by: Daniel Baumann <daniel.baumann@progress-linux.org>
Diffstat (limited to '')
-rw-r--r--tests/test_utils.py8
1 files changed, 4 insertions, 4 deletions
diff --git a/tests/test_utils.py b/tests/test_utils.py
index 9679116..acf9853 100644
--- a/tests/test_utils.py
+++ b/tests/test_utils.py
@@ -115,17 +115,17 @@ def test_auto_group(repos, paths, expected):
(
[{"abc": {"path": "/root/repo/", "type": "", "flags": []}}, False],
True,
- "abc \x1b[31mrepo *+_ \x1b[0m msg xx",
+ "abc \x1b[31mrepo [*+?] \x1b[0m msg xx",
),
(
[{"abc": {"path": "/root/repo/", "type": "", "flags": []}}, True],
True,
- "abc repo *+_ msg xx",
+ "abc repo [*+?] msg xx",
),
(
[{"repo": {"path": "/root/repo2/", "type": "", "flags": []}}, False],
False,
- "repo \x1b[32mrepo _ \x1b[0m msg xx",
+ "repo \x1b[32mrepo [?] \x1b[0m msg xx",
),
],
)
@@ -135,7 +135,7 @@ def test_describe(test_input, diff_return, expected, monkeypatch):
monkeypatch.setattr(info, "get_commit_msg", lambda *_: "msg")
monkeypatch.setattr(info, "get_commit_time", lambda *_: "xx")
monkeypatch.setattr(info, "has_untracked", lambda *_: True)
- monkeypatch.setattr("os.chdir", lambda x: None)
+ monkeypatch.setattr(info, "get_common_commit", lambda x: "")
info.get_color_encoding.cache_clear() # avoid side effect
assert expected == next(utils.describe(*test_input))