Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix: importing more than 10 subgroups #1059

Merged

Conversation

timadevelop
Copy link
Contributor

@timadevelop timadevelop commented Jun 17, 2024

What this PR does / why we need it:

Which issue this PR fixes : fixes #1014

PR Readiness Checklist:

Complete these before marking the PR as ready to review:

  • the CHANGELOG.md release notes have been updated to reflect any significant (and particularly user-facing) changes introduced by this PR

Copy link
Collaborator

@jonasvoelcker jonasvoelcker left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks very promising :)

@jonasvoelcker
Copy link
Collaborator

jonasvoelcker commented Jun 17, 2024

Hi @timadevelop,

thanks for your contribution so far, it seems like you are on the right track. Unfortunately the SubGroupUtil.java.legacy handles the subgroups differently and as we support also older version, it might be good to separate the initial test from the one with many subgroups.

Would it be possible that you maybe add this scenario as @order(48) with a separate json-file so we can add this line to ignore it for older Keycloak versions?

assumeTrue(VersionUtil.ge(KEYCLOAK_VERSION, "23"));

Best Regards
Jonas

Comment on lines 1707 to 1709
GroupRepresentation subGroup = subGroups.get(0);
assertThat("subgroup is null", subGroup, notNullValue());
assertThat("subgroup's name not equal", subGroup.getName(), startsWith("My SubGroup"));
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

tbh we don't care about the name or the order of the groups, but i think it's ok to leave this assert here

@timadevelop
Copy link
Contributor Author

@jonasvoelcker done ✅ . Also fixed the 98/shouldUpdateRealmDeleteGroup test, it depended on groups from 47th one (hence new one interfered with it).

Signed-off-by: Jonas Voelcker <barmer@jonas-voelcker.de>
@jonasvoelcker
Copy link
Collaborator

@timadevelop I've changed the order as no init step is needed that way. ;)

@jonasvoelcker jonasvoelcker merged commit b798f8f into adorsys:main Jun 17, 2024
11 checks passed
@timadevelop
Copy link
Contributor Author

@jonasvoelcker thank you

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Cannot create 20 or more subGroups
2 participants