| 1 | #!/usr/bin/env bash |
| 2 | |
| 3 | . "$(dirname "$0")/testlib.sh" |
| 4 | |
| 5 | begin_test "progress meter displays positive progress" |
| 6 | ( |
| 7 | set -e |
| 8 | |
| 9 | reponame="progress-meter" |
| 10 | setup_remote_repo "$reponame" |
| 11 | clone_repo "$reponame" "$reponame" |
| 12 | |
| 13 | git lfs track "*.dat" |
| 14 | git add .gitattributes |
| 15 | git commit -m "initial commit" |
| 16 | |
| 17 | for i in `seq 1 128`; do |
| 18 | printf "%s" "$i" > "$i.dat" |
| 19 | done |
| 20 | |
| 21 | git add *.dat |
| 22 | git commit -m "add many objects" |
| 23 | |
| 24 | git push origin main 2>&1 | tee push.log |
| 25 | [ "0" -eq "${PIPESTATUS[0]}" ] |
| 26 | |
| 27 | grep "Uploading LFS objects: 100% (128/128), 276 B" push.log |
| 28 | ) |
| 29 | end_test |