Assertions inside sub-methods should be recognised

It looks like test methods that call ‘verify’ or ‘check’ methods, which then perform assertions are flagged as not containing assertions.

It would be good if the ‘no assertion’ rule dropped through method calls to see if asserts were hit in sub-methods.


Hey @robert.baillie - this is something we are have been working on for a while, and it’s coming with our new engine. We are in the process of porting the existing ruleset, so it’s going to take some more weeks, but all the rules will work traversing calls/sub-methods. This will work for anything: DML in loops, assertions, etc.

There is even more to be excited for, so stay tuned! Thanks for your patience on this.

1 Like

Hello @robert.baillie, I’m happy to communicate that an early access version of our new code review engine is available.
The new engine works with a more accurate version of our ruleset and the case described in your post should be correctly addressed.

Please let me know if you want to try the new engine with one of your projects.