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

[2606] Fixed Non-deterministic behavior of HashSet that might fail the test ClientLibrariesImplTest #2621

Expand Up @@ -22,7 +22,6 @@
import java.util.Arrays;
import java.util.Collection;
import java.util.Collections;
import java.util.HashSet;
import java.util.LinkedHashSet;
import java.util.List;
import java.util.Map;
Expand Down Expand Up @@ -297,7 +296,7 @@ private String getInline(LibraryType libraryType) {
@NotNull
protected Set<String> getCategoriesFromComponents() {
try (ResourceResolver resourceResolver = resolverFactory.getServiceResourceResolver(Collections.singletonMap(ResourceResolverFactory.SUBSERVICE, COMPONENTS_SERVICE))) {
Set<String> categories = new HashSet<>();
Set<String> categories = new LinkedHashSet<>();
for (ClientLibrary library : this.getAllClientLibraries(resourceResolver)) {
for (String category : library.getCategories()) {
if (pattern == null || pattern.matcher(category).matches()) {
Expand Down