fixed expected exception caught to NoSuchMethodException.