Skip to content
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.

Commit 3467688

Browse files
author
Enrico Steffinlongo
committedMay 12, 2023
Add regression tests for --extract-core-goto
1 parent abe3e83 commit 3467688

File tree

3 files changed

+30
-0
lines changed

3 files changed

+30
-0
lines changed
 
Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,9 @@
1+
CORE
2+
test.c
3+
--export-core-goto ""
4+
^ERROR: Please provide a filename to write the goto-binary to.$
5+
^EXIT=6$
6+
^SIGNAL=0$
7+
--
8+
--
9+
Ensure that --export-core-goto exported.core.goto terminates with error when incorrectly used.
Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,15 @@
1+
CORE
2+
test.c
3+
--export-core-goto exported.core.goto
4+
^Parsing test.c$
5+
^Converting$
6+
^Type-checking test$
7+
^Generating GOTO Program$
8+
^Removal of function pointers and virtual functions$
9+
^Generic Property Instrumentation$
10+
Exported goto-program in core-goto form at exported.core.goto
11+
^EXIT=0$
12+
^SIGNAL=0$
13+
--
14+
--
15+
Ensure that --export-core-goto exported.core.goto terminates successfully and logs this.
Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
int main(int argc, char **argv)
2+
{
3+
int arr[] = { 0, 1, 2, 3, 4 };
4+
__CPROVER_assert(arr[0] == 1, "expected failure: 0 != 1");
5+
return 0;
6+
}

0 commit comments

Comments
 (0)
Please sign in to comment.