Commit Graph

209 Commits

Author SHA1 Message Date
Lars-Peter Clausen 1858c6a313 Set regression test for explicit enum cast to supported
Update the enum cast test to reflect that enum casts are now supported.

Also add a small check to verify that the right value got assigned to the
enum after the cast.

Signed-off-by: Lars-Peter Clausen <lars@metafoo.de>
2022-01-17 20:21:28 +01:00
Stephen Williams 7c73ef8fb6 ivtest: Mark as NI tests that are known to fail.
Mark them as NI so that in the fugure they might be turned back
on if they can be made to work. Keep the tests around as reference.

Also, remove reports that are no longer tested in CI. This is because
they are no longer tested by a previous patch that relies on the
change vvp_reg.pl behavior around failed tests.

Remove now obsolete update_msys2_report.pl, and simplify the test.sh
script, since diff commands and Windows specific trickery are no
longer needed.
2022-01-16 13:17:46 -08:00
Stephen Williams d0b9c11d35 ivtest: vvp_reg.pl sets exit status
If there are any failures, return a non-zero exit status so that
invoking scripts can detect that failures happen. This eliminates
the need to use regression report reference outputs, and should
make it easier to merge PRs that add or impact tests.
2022-01-16 11:03:21 -08:00
Lars-Peter Clausen e176ce0776 Add regression test for signed struct
Add a test that checks that signing annotations on structs are supported
and that signed structs are properly evaluated as a signed value.

Signed-off-by: Lars-Peter Clausen <lars@metafoo.de>
2022-01-16 16:16:33 +01:00
Lars-Peter Clausen 38c4c20cbc Add test for packed arrays of types from other scopes
Extend the array_packed test to check declaring a packed array of a type
from another scope that is addressed via a scoped identifier.

Signed-off-by: Lars-Peter Clausen <lars@metafoo.de>
2022-01-15 22:26:29 +01:00
Lars-Peter Clausen c670170ac0 Add test for direct packed arrays of struct and enums
It is possible to directly declare a packed array of a struct or enum
without having to create a typedef first.

Add a check to the array_packed test that this is supported and works as
expected.

Signed-off-by: Lars-Peter Clausen <lars@metafoo.de>
2022-01-15 22:26:29 +01:00
Lars-Peter Clausen d856a35e4d Add regression test for enums declared in structs and classes
These tests check that a enum that is declared in a struct or class are
correctly elaborated and also name collisions with the enum names are
detected.

Signed-off-by: Lars-Peter Clausen <lars@metafoo.de>
2022-01-15 21:43:01 +01:00
Lars-Peter Clausen 3e5f9fd044 Add a regression test with invalid struct member declarations
The test checks that all invalid declarations produce an error and also do
not crash the application.

Signed-off-by: Lars-Peter Clausen <lars@metafoo.de>
2022-01-15 19:54:13 +01:00
Stephen Williams cea237b407 Add ivtest to the iverilog source tree
By adding ivtest to the iverilog source tree, it is easier to keep
the regression test synchronized with the source that is being tested.
This should be especially helpful for PRs that add a new feature, and
have a matching ivtest PR with the regression test for that feature.
2022-01-15 10:18:50 -08:00