ne propose pas les logs si tests reussis

This commit is contained in:
hugogogo
2021-12-14 23:14:53 +01:00
parent 1f3b86f0f4
commit 1b8c0aaea9
2 changed files with 10 additions and 8 deletions

View File

@@ -1,6 +1,4 @@
#!/bin/bash cat << EOF
hello
#cat << EOF EOF
#hello
#EOF

View File

@@ -225,11 +225,15 @@ DEFAULT_DIR="./tests/defaults/"
# ask to show the diff # ask to show the diff
# -rsn1 will stop read after first key pressed # -rsn1 will stop read after first key pressed
if [ $TOTAL_SUCCESS -lt $TOTAL_TEST ]
then
read -rsn1 -p 'if you want to see the diff, press "y"' DIFF read -rsn1 -p 'if you want to see the diff, press "y"' DIFF
if [[ "${DIFF,,}" == y ]] if [[ "${DIFF,,}" == y ]]
then then
diff -y --width=100 --color=always "$BASH_LOG" "$MINISHELL_LOG" diff -y --width=100 --color=always "$BASH_LOG" "$MINISHELL_LOG"
fi fi
fi
# delete files created during tests # delete files created during tests
delete_files delete_files