Skip to content

test: use stronger assertions in util tests#797

Merged
annejan merged 1 commit intomainfrom
fix/test-assertions
Mar 27, 2026
Merged

test: use stronger assertions in util tests#797
annejan merged 1 commit intomainfrom
fix/test-assertions

Conversation

@nogeenhenk
Copy link
Copy Markdown
Contributor

Summary

Address AI findings in tests/auto/util/tst_util.cpp:

  • Use exact counts (>= 3, == 1, >= 2) instead of weak assertions (>= 2, > 0, >= 1)
  • Use QCOMPARE instead of QVERIFY for equality checks in namedValuesEdgeCases for better test failure messages

- Use exact counts instead of >= for named values parsing
- Use QCOMPARE instead of QVERIFY for better error messages
@annejan annejan merged commit f3a76dc into main Mar 27, 2026
15 of 16 checks passed
@annejan annejan deleted the fix/test-assertions branch March 27, 2026 23:53
@coveralls
Copy link
Copy Markdown

Coverage Status

coverage: 18.572%. remained the same
when pulling 94d9be7 on fix/test-assertions
into 790ca75 on main.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants