fixed test, now testing for throw via emit('error')