diff options
| author | Bryce Kwon <bryce@brycekwon.com> | |
|---|---|---|
| committer | Bryce Kwon <bryce@brycekwon.com> | |
| commit | ||
| parent | ||
| tree | ||
| download | ||
Align with spaces instead of tabs
Diffstat (limited to 'tests/t0001-git-version.sh')
| -rwxr-xr-x | tests/t0001-git-version.sh | 8 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
1 file changed, 4 insertions, 4 deletions
diff --git a/tests/t0001-git-version.sh b/tests/t0001-git-version.sh index dd49002..76b24db 100755 --- a/tests/t0001-git-version.sh +++ b/tests/t0001-git-version.sh @@ -15,8 +15,8 @@ CGIT_TEST_NO_CREATE_REPOS=YesPlease . ./setup.sh test_expect_success 'extract Git version from Makefile' ' - sed -n -e "/^GIT_VERSION[ ]*=/ { - s/^GIT_VERSION[ ]*=[ ]*// + sed -n -e "/^GIT_VERSION[[:space:]]*=/ { + s/^GIT_VERSION[[:space:]]*=[[:space:]]*// p }" "$TEST_OUTPUT_DIRECTORY/../Makefile" >makefile_version ' @@ -27,7 +27,7 @@ test_expect_success 'extract Git version from Makefile' ' test_expect_success 'test Git version matches Makefile' ' ( cat "$TEST_OUTPUT_DIRECTORY/../vendor/git/GIT-VERSION-FILE" || echo "No GIT-VERSION-FILE" ) | - sed -e "s/GIT_VERSION[ ]*=[ ]*//" -e "s/\\.dirty$//" >git_version && + sed -e "s/GIT_VERSION[[:space:]]*=[[:space:]]*//" -e "s/\\.dirty$//" >git_version && sed -e "s/-/./g" makefile_version >makefile_git_version && test_cmp git_version makefile_git_version ' @@ -42,7 +42,7 @@ test_expect_success 'test submodule version matches Makefile' ' ( cd "$TEST_OUTPUT_DIRECTORY/.." && submodule_oid=$(git ls-files --stage -- vendor/git | - sed -e "s/^[0-9]* \\([0-9a-f]*\\) [0-9] .*$/\\1/") && + sed -e "s/^[0-9]* \\([0-9a-f]*\\) [0-9][[:space:]].*$/\\1/") && cd vendor/git && git describe --match "v[0-9]*" $submodule_oid ) | sed -e "s/^v//" -e "s/-/./" >submodule_version && |
