error check in test