diff options
| author | Pablo Sabater <pabloosabaterr@gmail.com> | 2026-03-11 20:40:02 +0100 |
|---|---|---|
| committer | Junio C Hamano <gitster@pobox.com> | 2026-03-11 12:53:16 -0700 |
| commit | 6523589a2c034de168f6240d040e0910f7aeddda (patch) | |
| tree | d542487a5d8c4cbada19fc50c0642b805203aeb4 /t/t9200-git-cvsexportcommit.sh | |
| parent | 4aa72ea1f64e8ddcd1865c76b24591c0916c0b5d (diff) | |
| download | git-6523589a2c034de168f6240d040e0910f7aeddda.tar.xz | |
t9200: handle missing CVS with skip_all
CVS initialization runs outside a test_expect_success and when it
fails, the error report isn't good.
Wrap CVS initialization in a skip_all check so when CVS initialization
fails, the error report becomes clearer.
Move the Git repo initialization into its own test_expect_success instead
of being in the same CVS check.
Signed-off-by: Pablo Sabater <pabloosabaterr@gmail.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
Diffstat (limited to 't/t9200-git-cvsexportcommit.sh')
| -rwxr-xr-x | t/t9200-git-cvsexportcommit.sh | 18 |
1 files changed, 11 insertions, 7 deletions
diff --git a/t/t9200-git-cvsexportcommit.sh b/t/t9200-git-cvsexportcommit.sh index a44eabf0d8..cba3b1a28a 100755 --- a/t/t9200-git-cvsexportcommit.sh +++ b/t/t9200-git-cvsexportcommit.sh @@ -30,13 +30,17 @@ export CVSROOT CVSWORK GIT_DIR rm -rf "$CVSROOT" "$CVSWORK" -cvs init && -test -d "$CVSROOT" && -cvs -Q co -d "$CVSWORK" . && -echo >empty && -git add empty && -git commit -q -a -m "Initial" 2>/dev/null || -exit 1 +if ! cvs init || ! test -d "$CVSROOT" || ! cvs -Q co -d "$CVSWORK" . +then + skip_all="cvs repository set-up fails" + test_done +fi + +test_expect_success 'git setup' ' + echo >empty && + git add empty && + git commit -q -a -m Initial +' check_entries () { # $1 == directory, $2 == expected |
