diff --git a/test/test-happy-path.sh b/test/test-happy-path.sh index 49cf77b0..2d44da77 100755 --- a/test/test-happy-path.sh +++ b/test/test-happy-path.sh @@ -23,8 +23,8 @@ begin_test "happy path" clone_repo "$reponame" repo # This executes Git LFS from the local repo that was just cloned. - out=$(git lfs track "*.dat" 2>&1) - echo "$out" | grep "Tracking \*.dat" + git lfs track "*.dat" 2>&1 | tee track.log + grep "Tracking \*.dat" track.log contents="a" contents_oid=$(printf "$contents" | shasum -a 256 | cut -f 1 -d " ") @@ -39,10 +39,7 @@ begin_test "happy path" grep "create mode 100644 a.dat" commit.log grep "create mode 100644 .gitattributes" commit.log - out=$(cat a.dat) - if [ "$out" != "a" ]; then - exit 1 - fi + [ "a" = "$(cat a.dat)" ] # This is a small shell function that runs several git commands together. assert_pointer "master" "a.dat" "$contents_oid" 1 @@ -61,10 +58,7 @@ begin_test "happy path" git pull 2>&1 | grep "Downloading a.dat (1 B)" - out=$(cat a.dat) - if [ "$out" != "a" ]; then - exit 1 - fi + [ "a" = "$(cat a.dat)" ] assert_pointer "master" "a.dat" "$contents_oid" 1 )