From 5eb7363ddd97b2077c4814f23221909cc2e96e0c Mon Sep 17 00:00:00 2001 From: Jon Koops Date: Thu, 11 Jan 2024 19:42:10 +0100 Subject: [PATCH] Promote Account Console v3 to default and deprecate v2 (#25852) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Closes #19663 Signed-off-by: Jon Koops Co-authored-by: Martin Bartoš --- common/src/main/java/org/keycloak/common/Profile.java | 4 ++-- common/src/test/java/org/keycloak/common/ProfileTest.java | 8 ++++---- js/apps/account-ui/index.html | 2 +- js/apps/account-ui/pom.xml | 4 ++-- js/apps/account-ui/src/root/Root.tsx | 1 + .../admin-ui/cypress/support/pages/admin-ui/Masthead.ts | 4 ++-- .../java/org/keycloak/it/cli/dist/FeaturesDistTest.java | 2 +- .../java/org/keycloak/testsuite/admin/ServerInfoTest.java | 2 +- .../webauthn/account/AbstractWebAuthnAccountTest.java | 4 ++++ 9 files changed, 18 insertions(+), 13 deletions(-) diff --git a/common/src/main/java/org/keycloak/common/Profile.java b/common/src/main/java/org/keycloak/common/Profile.java index bf1e93ae3a..9d937e2a89 100755 --- a/common/src/main/java/org/keycloak/common/Profile.java +++ b/common/src/main/java/org/keycloak/common/Profile.java @@ -48,8 +48,8 @@ public class Profile { AUTHORIZATION("Authorization Service", Type.DEFAULT), ACCOUNT_API("Account Management REST API", Type.DEFAULT), - ACCOUNT2("Account Management Console 2", Type.DEFAULT, Feature.ACCOUNT_API), - ACCOUNT3("Account Management Console 3", Type.PREVIEW, Feature.ACCOUNT_API), + ACCOUNT2("Account Management Console 2", Type.DEPRECATED, Feature.ACCOUNT_API), + ACCOUNT3("Account Management Console 3", Type.DEFAULT, Feature.ACCOUNT_API), ADMIN_FINE_GRAINED_AUTHZ("Fine-Grained Admin Permissions", Type.PREVIEW), diff --git a/common/src/test/java/org/keycloak/common/ProfileTest.java b/common/src/test/java/org/keycloak/common/ProfileTest.java index d488722dd4..c57e5d6b71 100644 --- a/common/src/test/java/org/keycloak/common/ProfileTest.java +++ b/common/src/test/java/org/keycloak/common/ProfileTest.java @@ -71,7 +71,7 @@ public class ProfileTest { Profile.Feature.TRANSIENT_USERS, Profile.Feature.DPOP, Profile.Feature.FIPS, - Profile.Feature.ACCOUNT3, + Profile.Feature.ACCOUNT2, Profile.Feature.ADMIN_FINE_GRAINED_AUTHZ, Profile.Feature.DYNAMIC_SCOPES, Profile.Feature.DOCKER, @@ -89,7 +89,7 @@ public class ProfileTest { disabledFeatures.add(Profile.Feature.KERBEROS); } assertEquals(profile.getDisabledFeatures(), disabledFeatures); - assertEquals(profile.getPreviewFeatures(), Profile.Feature.ACCOUNT3, Profile.Feature.ADMIN_FINE_GRAINED_AUTHZ, Profile.Feature.MULTI_SITE, Profile.Feature.RECOVERY_CODES, Profile.Feature.SCRIPTS, Profile.Feature.TOKEN_EXCHANGE, Profile.Feature.CLIENT_SECRET_ROTATION, Profile.Feature.UPDATE_EMAIL, Profile.Feature.DPOP); + assertEquals(profile.getPreviewFeatures(), Profile.Feature.ADMIN_FINE_GRAINED_AUTHZ, Profile.Feature.MULTI_SITE, Profile.Feature.RECOVERY_CODES, Profile.Feature.SCRIPTS, Profile.Feature.TOKEN_EXCHANGE, Profile.Feature.CLIENT_SECRET_ROTATION, Profile.Feature.UPDATE_EMAIL, Profile.Feature.DPOP); } @Test @@ -100,14 +100,14 @@ public class ProfileTest { try { Profile.configure(new PropertiesProfileConfigResolver(properties)); } catch (ProfileException e) { - Assert.assertEquals("Feature account2 depends on disabled feature account-api", e.getMessage()); + Assert.assertEquals("Feature account3 depends on disabled feature account-api", e.getMessage()); } } @Test public void checkSuccessIfFeatureDisabledWithDisabledDependencies() { Properties properties = new Properties(); - properties.setProperty("keycloak.profile.feature.account2", "disabled"); + properties.setProperty("keycloak.profile.feature.account3", "disabled"); properties.setProperty("keycloak.profile.feature.account_api", "disabled"); Profile.configure(new PropertiesProfileConfigResolver(properties)); Assert.assertFalse(Profile.isFeatureEnabled(Profile.Feature.ACCOUNT2)); diff --git a/js/apps/account-ui/index.html b/js/apps/account-ui/index.html index a1f7738b68..f284617802 100644 --- a/js/apps/account-ui/index.html +++ b/js/apps/account-ui/index.html @@ -6,7 +6,7 @@ - Keycloak account console + Account Management