Added test for changing password, and a small fix