fixed tests as well to compile with the latest changes from error codes to exceptions