Skip to content

Commit 0f1556b

Browse files
committed
pyproject(doctest) Use list, reruns
1 parent 0b885cd commit 0f1556b

File tree

3 files changed

+15
-7
lines changed

3 files changed

+15
-7
lines changed

pyproject.toml

Lines changed: 12 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -213,8 +213,18 @@ convention = "numpy"
213213
"*/__init__.py" = ["F401"]
214214

215215
[tool.pytest.ini_options]
216-
addopts = "--tb=short --no-header --showlocals --doctest-modules"
217-
doctest_optionflags = "ELLIPSIS NORMALIZE_WHITESPACE"
216+
addopts = [
217+
"--tb=short",
218+
"--no-header",
219+
"--showlocals",
220+
"--doctest-docutils-modules",
221+
"-p no:doctest",
222+
"--reruns=2"
223+
]
224+
doctest_optionflags = [
225+
"ELLIPSIS",
226+
"NORMALIZE_WHITESPACE"
227+
]
218228
testpaths = [
219229
"src/libvcs",
220230
"tests",

src/libvcs/sync/git.py

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -73,8 +73,7 @@ class GitRemoteRefNotFound(exc.CommandError):
7373

7474
def __init__(self, git_tag: str, ref_output: str, *args: object) -> None:
7575
return super().__init__(
76-
f"Could not fetch remote in refs/remotes/{git_tag}:"
77-
+ f"Output: {ref_output}",
76+
f"Could not fetch remote in refs/remotes/{git_tag}:Output: {ref_output}",
7877
)
7978

8079

@@ -529,8 +528,8 @@ def update_repo(
529528
self.cmd.stash.pop(index=True, quiet=True)
530529
self.log.exception(
531530
f"\nFailed to rebase in: '{self.path}'.\n"
532-
+ "You will have to resolve the "
533-
+ "conflicts manually",
531+
"You will have to resolve the "
532+
"conflicts manually",
534533
)
535534
return
536535

tests/test_exc.py

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,3 @@
1-
# ruff: noqa: TRY003
21
"""tests for libvcs exceptions."""
32

43
from __future__ import annotations

0 commit comments

Comments
 (0)