CS fixes and tidy up of tests

Sure. I'll add it.