-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
b4a3cb3
commit d3b1099
Showing
2 changed files
with
10 additions
and
7 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -3,11 +3,14 @@ mkdir -p "$(dirname "$OUT")" | |
|
||
cd "$(dirname "$0")/dafny" | ||
OUTPUT=$(Binaries/Dafny /deprecation:0 /compile:0 /timeLimit:$3 /print:$OUT.bpl /vcsCores:1 /proverLog:$OUT-@[email protected] "$1") | ||
|
||
# Check if "$1.expect" exists and if so if it contains " Error:", then it's ok for the above to fail | ||
if [ $? -eq 0 ] || ([ -f "$1.expect" ] && grep -q " Error:" "$1.expect"); then | ||
if [ $? -eq 0 ]; then | ||
exit 0 | ||
else | ||
echo "[ERROR] $OUTPUT" | ||
exit 1 | ||
fi | ||
while read -r out_line; do | ||
# Return error if the output line contains " Error:" but does not start with | ||
# the filename. This means it's not a verification error pointing to the file. | ||
if grep -q " Error:" <<< "$out_line" && ! [[ "$1" =~ "$(echo "$out_line" | sed "s|\.dfy.*|.dfy|g")" ]]; then | ||
echo "[ERROR] $OUTPUT" | ||
exit 1 | ||
fi | ||
done <<< "$OUTPUT" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters