Skip to content

Commit 9fbf6ff

Browse files
thk123tautschnig
authored andcommitted
Test to demonstrate assert bug on alpine
The user added assert in this test does not get coverage under alpine linux.
1 parent cca4e2c commit 9fbf6ff

File tree

2 files changed

+22
-0
lines changed

2 files changed

+22
-0
lines changed

regression/cbmc/simple_assert/main.c

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,9 @@
1+
#include <assert.h>
2+
3+
int main(int argc, char *argv[])
4+
{
5+
int x = 5;
6+
assert(x == 5);
7+
8+
return 0;
9+
}
Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
CORE
2+
main.c
3+
--cover location
4+
^EXIT=0$
5+
^SIGNAL=0$
6+
^\[main\.coverage\.1\] .* function main block 1: SATISFIED$
7+
(1 of 1|3 of 3) covered \(100\.0%\)$
8+
--
9+
^warning: ignoring
10+
^CONVERSION ERROR$
11+
^\[main\.coverage\..\] .* function main block .: FAILED$
12+
--
13+
On Windows/Visual Studio, "assert" does not introduce any branching.

0 commit comments

Comments
 (0)