more tests and error messages added