Tidied error case testing.