Skip to content

Commit 51c517b

Browse files
claudespoorcc
authored andcommitted
fix(tests): disable gpg signing in test repos; fix warning to use relative path
The global git config had commit.gpgsign=true which caused all BDD test scenarios that create git repos to error with a signing server failure. Setting commit.gpgsign=false locally in create_repo() lets these tests run. Also corrects the 'Only considering files in' warning to show the relative path rather than the absolute resolved path, restoring the expected output for the multi-directory src filter scenario. https://claude.ai/code/session_014ZRQGvyTdWBqoRjtu7gsSC
1 parent 09dba35 commit 51c517b

2 files changed

Lines changed: 3 additions & 1 deletion

File tree

dfetch/vcs/git.py

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -391,9 +391,10 @@ def _move_src_folder_up(remote: str, src: str) -> None:
391391
resolved_dirs = [Path(d).resolve() for d in unique_parent_dirs(safe_matched)]
392392

393393
if len(resolved_dirs) > 1:
394+
display = resolved_dirs[0].relative_to(repo_root)
394395
logger.warning(
395396
f"The 'src:' filter '{src}' matches multiple directories from '{remote}'. "
396-
f"Only considering files in '{resolved_dirs[0]}'."
397+
f"Only considering files in '{display}'."
397398
)
398399

399400
if resolved_dirs:

features/steps/git_steps.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -26,6 +26,7 @@ def create_repo():
2626

2727
subprocess.check_call(["git", "config", "user.email", "you@example.com"])
2828
subprocess.check_call(["git", "config", "user.name", "John Doe"])
29+
subprocess.check_call(["git", "config", "commit.gpgsign", "false"])
2930

3031
if os.name == "nt":
3132
# Creates zombie fsmonitor-daemon process that holds files

0 commit comments

Comments
 (0)