Sorry but this when/should pattern is something that doesn't match all test cases and makes them hard to read as you can't inline the assertion and loose the idea of assertEquals as you need to replace this with an assertTrue/False (which in fact looses the comparison feature when the assertion fails).
Will not fix.