That was a bit foolish of me. I put the test in after I had a failure condition. I fixed the source of the failure but didn't retest the test by reintroducing the failure. Classic programmer hubris :)

I'm a strong believer of the "when in Rome" coding ethos, and to be honest somehow had completely missed the if spacing, probably because the rest of the file is so similar to my own conventions.