Removed unused code
Use entity factory in PasswordGrant
Close mockery
Added unittests