tests for User::hasEmailEnabled