3
0
Fork 0
mirror of https://github.com/YosysHQ/sby.git synced 2025-11-02 22:07:53 +00:00

Test property statuses for cover_assert

Cover properties shouldn't be marked fail when the test failed early due to an assertion.
This should fail without other changes.
This commit is contained in:
Krystine Sherwin 2025-07-05 12:40:57 +12:00
parent 4d8462b58e
commit 911ae02ee5
No known key found for this signature in database
5 changed files with 105 additions and 0 deletions

16
tests/statusdb/mixed.v Normal file
View file

@ -0,0 +1,16 @@
module test (input CP, CN, input A, B, output reg XP, XN);
reg [7:0] counter = 0;
always @* begin
assume (A || B);
assume (!A || !B);
assert (A == B);
cover (counter == 3 && A);
cover (counter == 3 && B);
end
always @(posedge CP)
counter <= counter + 1;
always @(posedge CP)
XP <= A;
always @(negedge CN)
XN <= B;
endmodule