fix merge conflict mistakes

This commit is contained in:
Bill Burke 2015-06-15 09:28:11 -04:00
parent 43bad9a608
commit 38a2ea2fdf
4 changed files with 4 additions and 3 deletions

View file

@ -131,6 +131,7 @@ public class DefaultCacheUserProvider implements CacheUserProvider {
if (cached == null) {
UserModel model = getDelegate().getUserById(id, realm);
if (model == null) return null;
if (managedUsers.containsKey(id)) return managedUsers.get(id);
if (userInvalidations.containsKey(id)) return model;
cached = new CachedUser(realm, model);
cache.addCachedUser(realm.getId(), cached);
@ -155,6 +156,7 @@ public class DefaultCacheUserProvider implements CacheUserProvider {
if (cached == null) {
UserModel model = getDelegate().getUserByUsername(username, realm);
if (model == null) return null;
if (managedUsers.containsKey(model.getId())) return managedUsers.get(model.getId());
if (userInvalidations.containsKey(model.getId())) return model;
cached = new CachedUser(realm, model);
cache.addCachedUser(realm.getId(), cached);

View file

@ -246,7 +246,6 @@ public class AccountTest {
events.expectLogin().session((String) null).error("invalid_user_credentials")
.removeDetail(Details.CONSENT)
.assertEvent();
events.expectLogin().session((String) null).user(userId).error("invalid_user_credentials").assertEvent();
loginPage.open();
loginPage.login("test-user@localhost", "new-password");

View file

@ -154,7 +154,7 @@ public class LoginTest {
Assert.assertEquals("Account is disabled, contact admin.", loginPage.getError());
events.expectLogin().user(userId).session((String) null).error("invalid_user_credentials")
events.expectLogin().user(userId).session((String) null).error("user_disabled")
.detail(Details.USERNAME, "login-test")
.removeDetail(Details.CONSENT)
.assertEvent();

View file

@ -183,7 +183,7 @@ public class OAuthGrantTest {
oauth.openLoginForm();
appPage.assertCurrent();
events.expectLogin()
.detail(Details.AUTH_METHOD, "sso")
.detail(Details.AUTH_METHOD, OIDCLoginProtocol.LOGIN_PROTOCOL)
.detail(Details.CONSENT, Details.CONSENT_VALUE_PERSISTED_CONSENT)
.removeDetail(Details.USERNAME)
.client("third-party").assertEvent();