Skip to content

Commit edb8eeb

Browse files
authored
Merge pull request #1905 from smowton/smowton/cleanup/broken-regression-tests
Fix broken test descriptions
2 parents c188986 + 706ffa7 commit edb8eeb

File tree

172 files changed

+285
-6
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

172 files changed

+285
-6
lines changed

regression/ansi-c/Forward_Declaration2/test.desc

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,7 @@
11
CORE
22
main.c
33

4+
^EXIT=(1|64)$
45
^SIGNAL=0$
56
^CONVERSION ERROR$
67
--

regression/ansi-c/Incomplete_Type1/test.desc

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,7 @@
11
CORE
22
main.c
33

4+
^EXIT=(1|64)$
45
^SIGNAL=0$
56
^CONVERSION ERROR$
67
--

regression/ansi-c/function_return1/test.desc

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,7 @@ CORE
22
main.c
33
--verbosity 2
44
^main.c:3:1: warning: function has return void but a return statement returning signed int$
5+
^EXIT=0$
56
^SIGNAL=0$
67
--
78
^warning: ignoring

regression/ansi-c/static2/test.desc

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,5 +2,7 @@ CORE
22
main.c
33
main2.c --function foo
44
^main symbol `foo' is ambiguous$
5+
^EXIT=(1|64)$
6+
^SIGNAL=0$
57
--
68
^warning: ignoring

regression/ansi-c/static3/test.desc

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,5 +2,7 @@ CORE
22
main.c
33
main2.c --function foo
44
^main symbol `foo' is ambiguous$
5+
^EXIT=(1|64)$
6+
^SIGNAL=0$
57
--
68
^warning: ignoring

regression/cbmc-java/NondetArray/test.desc

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,5 +2,7 @@ CORE
22
NondetArray.class
33
--function NondetArray.main
44
^VERIFICATION SUCCESSFUL$
5+
^EXIT=0$
6+
^SIGNAL=0$
57
--
68
^warning: ignoring

regression/cbmc-java/NondetArray2/test.desc

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,8 @@ CORE
22
NondetArray2.class
33
--function NondetArray2.main --unwind 5
44
^VERIFICATION SUCCESSFUL$
5+
^EXIT=0$
6+
^SIGNAL=0$
57
--
68
--
79
Disabled pending fixing warnings for array-of with zero length:

regression/cbmc-java/NondetArray3/test.desc

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,8 @@ CORE
22
NondetArray3.class
33
--function NondetArray3.main --unwind 5
44
^VERIFICATION SUCCESSFUL$
5+
^EXIT=0$
6+
^SIGNAL=0$
57
--
68
--
79
Disabled pending fixing warnings for array-of with zero length:

regression/cbmc-java/NondetArray4/test.desc

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,5 +2,7 @@ CORE
22
NondetArray4.class
33
--function NondetArray4.main
44
^VERIFICATION SUCCESSFUL$
5+
^EXIT=0$
6+
^SIGNAL=0$
57
--
68
^warning: ignoring

regression/cbmc-java/NondetAssume1/test.desc

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,5 +2,7 @@ CORE
22
NondetAssume1.class
33
--function NondetAssume1.main
44
^VERIFICATION SUCCESSFUL$
5+
^EXIT=0$
6+
^SIGNAL=0$
57
--
68
^warning: ignoring

regression/cbmc-java/NondetAssume2/test.desc

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,5 +2,7 @@ CORE
22
NondetAssume2.class
33
--function NondetAssume2.main
44
^VERIFICATION SUCCESSFUL$
5+
^EXIT=0$
6+
^SIGNAL=0$
57
--
68
^warning: ignoring

regression/cbmc-java/NondetBoolean/test.desc

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,5 +2,7 @@ CORE
22
NondetBoolean.class
33
--function NondetBoolean.main
44
^VERIFICATION FAILED$
5+
^EXIT=10$
6+
^SIGNAL=0$
57
--
68
^warning: ignoring

regression/cbmc-java/NondetByte/test.desc

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,5 +2,7 @@ CORE
22
NondetByte.class
33
--function NondetByte.main
44
^VERIFICATION FAILED$
5+
^EXIT=10$
6+
^SIGNAL=0$
57
--
68
^warning: ignoring

regression/cbmc-java/NondetCastToObject/test.desc

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,5 +2,7 @@ CORE
22
NondetCastToObject.class
33
--function NondetCastToObject.main
44
^VERIFICATION SUCCESSFUL$
5+
^EXIT=0$
6+
^SIGNAL=0$
57
--
68
^warning: ignoring

regression/cbmc-java/NondetChar/test.desc

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,5 +2,7 @@ CORE
22
NondetChar.class
33
--function NondetChar.main
44
^VERIFICATION FAILED$
5+
^EXIT=10$
6+
^SIGNAL=0$
57
--
68
^warning: ignoring

regression/cbmc-java/NondetDirectFromMethod/test.desc

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,5 +2,7 @@ CORE
22
NondetDirectFromMethod.class
33
--function NondetDirectFromMethod.main
44
^VERIFICATION SUCCESSFUL$
5+
^EXIT=0$
6+
^SIGNAL=0$
57
--
68
^warning: ignoring

regression/cbmc-java/NondetDouble/test.desc

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,5 +2,7 @@ CORE
22
NondetDouble.class
33
--function NondetDouble.main
44
^VERIFICATION FAILED$
5+
^EXIT=10$
6+
^SIGNAL=0$
57
--
68
^warning: ignoring

regression/cbmc-java/NondetFloat/test.desc

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,5 +2,7 @@ CORE
22
NondetFloat.class
33
--function NondetFloat.main
44
^VERIFICATION FAILED$
5+
^EXIT=10$
6+
^SIGNAL=0$
57
--
68
^warning: ignoring

regression/cbmc-java/NondetGenericArray/test.desc

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,8 @@ CORE
22
NondetGenericArray.class
33
--function NondetGenericArray.main
44
^VERIFICATION SUCCESSFUL$
5+
^EXIT=0$
6+
^SIGNAL=0$
57
--
68
--
79
Disabled pending fixing warnings for array-of with zero length:

regression/cbmc-java/NondetGenericRecursive/test.desc

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,5 +2,7 @@ CORE
22
NondetGenericRecursive.class
33
--function NondetGenericRecursive.main
44
^VERIFICATION FAILED$
5+
^EXIT=10$
6+
^SIGNAL=0$
57
--
68
^warning: ignoring

regression/cbmc-java/NondetGenericRecursive2/test.desc

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,5 +2,7 @@ CORE
22
NondetGenericRecursive2.class
33
--function NondetGenericRecursive2.main
44
^VERIFICATION SUCCESSFUL$
5+
^EXIT=0$
6+
^SIGNAL=0$
57
--
68
^warning: ignoring

regression/cbmc-java/NondetGenericWithNull/test.desc

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,5 +2,7 @@ CORE
22
NondetGenericWithNull.class
33
--function NondetGenericWithNull.main
44
^VERIFICATION FAILED$
5+
^EXIT=10$
6+
^SIGNAL=0$
57
--
68
^warning: ignoring

regression/cbmc-java/NondetGenericWithoutNull/test.desc

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,5 +2,7 @@ CORE
22
NondetGenericWithoutNull.class
33
--function NondetGenericWithoutNull.main
44
^VERIFICATION SUCCESSFUL$
5+
^EXIT=0$
6+
^SIGNAL=0$
57
--
68
^warning: ignoring

regression/cbmc-java/NondetInit/test.desc

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,4 +2,6 @@ CORE
22
Test.class
33
--function Test.check
44
^VERIFICATION SUCCESSFUL$
5+
^EXIT=0$
6+
^SIGNAL=0$
57
--

regression/cbmc-java/NondetInit/test_lazy.desc

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,8 @@ CORE symex-driven-lazy-loading-expected-failure
22
Test.class
33
--function Test.check --lazy-methods
44
^VERIFICATION SUCCESSFUL$
5+
^EXIT=0$
6+
^SIGNAL=0$
57
--
68
--
79
This doesn't work under symex-driven lazy loading because it is incompatible with --lazy-methods

regression/cbmc-java/NondetInit2/test.desc

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,3 +2,5 @@ CORE
22
Test.class
33
--function Test.main
44
^VERIFICATION SUCCESSFUL$
5+
^EXIT=0$
6+
^SIGNAL=0$

regression/cbmc-java/NondetInit3/test.desc

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,3 +2,5 @@ CORE
22
Test.class
33
--function Test.main
44
^VERIFICATION SUCCESSFUL$
5+
^EXIT=0$
6+
^SIGNAL=0$

regression/cbmc-java/NondetInt/test.desc

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,5 +2,7 @@ CORE
22
NondetInt.class
33
--function NondetInt.main
44
^VERIFICATION FAILED$
5+
^EXIT=10$
6+
^SIGNAL=0$
57
--
68
^warning: ignoring

regression/cbmc-java/NondetLong/test.desc

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,5 +2,7 @@ CORE
22
NondetLong.class
33
--function NondetLong.main
44
^VERIFICATION FAILED$
5+
^EXIT=10$
6+
^SIGNAL=0$
57
--
68
^warning: ignoring

regression/cbmc-java/NondetShort/test.desc

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,5 +2,7 @@ CORE
22
NondetShort.class
33
--function NondetShort.main
44
^VERIFICATION FAILED$
5+
^EXIT=10$
6+
^SIGNAL=0$
57
--
68
^warning: ignoring

regression/cbmc-java/address_space_size_limit1/test.desc

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,4 +2,6 @@ CORE
22
Test.class
33
--object-bits 4
44
too many addressed objects
5+
^EXIT=6$
6+
^SIGNAL=0$
57
--

regression/cbmc-java/array2/test.desc

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,5 +2,7 @@ CORE
22
test.class
33
--function test.f --cover location
44
\d+ of \d+ covered
5+
^EXIT=0$
6+
^SIGNAL=0$
57
--
68
^warning: ignoring

regression/cbmc-java/exceptions26/test.desc

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,8 @@ CORE
22
test.class
33

44
^VERIFICATION SUCCESSFUL$
5+
^EXIT=0$
6+
^SIGNAL=0$
57
--
68
^warning: ignoring
79
--

regression/cbmc-java/exceptions27/test.desc

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,8 @@ CORE
22
test.class
33

44
VERIFICATION SUCCESSFUL
5+
^EXIT=0$
6+
^SIGNAL=0$
57
--
68
^warning: ignoring
79
--

regression/cbmc-java/inherited_static_field1/test.desc

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,8 @@ CORE
22
Test.class
33
--function Test.main
44
^VERIFICATION SUCCESSFUL$
5+
^EXIT=0$
6+
^SIGNAL=0$
57
--
68
--
79
This checks that jbmc knows that test.x and parent.x refer to the same field.

regression/cbmc-java/inherited_static_field10/test.desc

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,8 @@ Test.class
44
Stub static field x found for non-stub type java::Test\. In future this will be a fatal error\.
55
assertion at file Test\.java line 6 .* FAILURE
66
^VERIFICATION FAILED$
7+
^EXIT=10$
8+
^SIGNAL=0$
79
--
810
Stub static field x found for non-stub type java::Parent\. In future this will be a fatal error\.
911
--

regression/cbmc-java/inherited_static_field2/test.desc

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,8 @@ CORE
22
Test.class
33
--function Test.main
44
^VERIFICATION SUCCESSFUL$
5+
^EXIT=0$
6+
^SIGNAL=0$
57
--
68
--
79
This checks that jbmc knows that Test.x and InterfaceWithStatic.x are the same field.

regression/cbmc-java/inherited_static_field3/test.desc

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,8 @@ CORE
22
Test.class
33
--function Test.main
44
^VERIFICATION SUCCESSFUL$
5+
^EXIT=0$
6+
^SIGNAL=0$
57
--
68
--
79
This is the same as test inherited_static_field1, except Test's parent is opaque.

regression/cbmc-java/inherited_static_field4/test.desc

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,8 @@ Test.class
33
--function Test.main
44
assertion at file Test\.java line 6 .* FAILURE
55
^VERIFICATION FAILED$
6+
^EXIT=10$
7+
^SIGNAL=0$
68
--
79
--
810
This checks that jbmc knows that the hidden field Grandparent.x is not the same

regression/cbmc-java/inherited_static_field5/test.desc

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,8 @@ CORE
22
Test.class
33
--function Test.main
44
^VERIFICATION SUCCESSFUL$
5+
^EXIT=0$
6+
^SIGNAL=0$
57
--
68
--
79
This is the same as inherited_static_field2, except that Test's parent is opaque. It must pass because

regression/cbmc-java/inherited_static_field6/test.desc

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,8 @@ Test.class
33
--function Test.main
44
assertion at file Test\.java line 6 .* FAILURE
55
^VERIFICATION FAILED$
6+
^EXIT=10$
7+
^SIGNAL=0$
68
--
79
--
810
This test is the same as inherited_static_field4, except that Test's parent is opaque.

regression/cbmc-java/inherited_static_field7/test.desc

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,8 @@ CORE
22
Test.class
33
--function Test.main
44
^VERIFICATION SUCCESSFUL$
5+
^EXIT=0$
6+
^SIGNAL=0$
57
--
68
--
79
This test must pass, as there is only one opaque parent (interface_with_static).

regression/cbmc-java/inherited_static_field8/test.desc

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,8 @@ Test.class
44
assertion at file Test\.java line 6 .* SUCCESS
55
assertion at file Test\.java line 7 .* FAILURE
66
^VERIFICATION FAILED$
7+
^EXIT=10$
8+
^SIGNAL=0$
79
--
810
--
911
This test is the same as inherited_static_field4, except that Test's grandparent is opaque.

regression/cbmc-java/inherited_static_field9/test.desc

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,8 @@ Stub static field x found for non-stub type java::Test\. In future this will be
55
Stub static field x found for non-stub type java::Parent\. In future this will be a fatal error\.
66
assertion at file Test\.java line 6 .* FAILURE
77
^VERIFICATION FAILED$
8+
^EXIT=10$
9+
^SIGNAL=0$
810
--
911
--
1012
This tests the corner case where static fields are found on non-stub types, here caused

regression/cbmc-java/lambda1/B.class

-123 Bytes
Binary file not shown.

regression/cbmc-java/lambda1/C.class

-124 Bytes
Binary file not shown.
-73 Bytes
Binary file not shown.
-767 Bytes
Binary file not shown.

regression/cbmc-java/lambda1/Lambdatest.java

Lines changed: 15 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -36,11 +36,11 @@ public int j(int x) {
3636

3737
public int k(int x) {
3838
a.x = 10;
39-
39+
4040
Function<Integer, Integer> foo = (y) -> y * a.x;
4141
return foo.apply(x);
4242
}
43-
43+
4444
public int l(int x) {
4545
b.y = 10;
4646
Function<Integer, Integer> foo = (y) -> {
@@ -75,6 +75,19 @@ public int capture2(Float a) {
7575
public boolean custom(Integer i) {
7676
return custom.is_ok(i);
7777
}
78+
79+
public static void main(String[] args) {
80+
// Uses all of the above test functions, to ensure they are loaded under
81+
// symex-driven loading:
82+
83+
Lambdatest lt = new Lambdatest();
84+
lt.f(0.0f, 0, 0);
85+
lt.i(0);
86+
lt.j(0);
87+
lt.k(0);
88+
lt.l(0);
89+
lt.m(0);
90+
}
7891
}
7992

8093
class C implements CustomLambda<Integer> {

0 commit comments

Comments
 (0)