tests for raising errors