diff --git a/modules/gplazma2-multimap/src/test/java/org/dcache/gplazma/plugins/GplazmaMultiMapFileTest.java b/modules/gplazma2-multimap/src/test/java/org/dcache/gplazma/plugins/GplazmaMultiMapFileTest.java index fbd77d75c23..5bf2241e5e4 100644 --- a/modules/gplazma2-multimap/src/test/java/org/dcache/gplazma/plugins/GplazmaMultiMapFileTest.java +++ b/modules/gplazma2-multimap/src/test/java/org/dcache/gplazma/plugins/GplazmaMultiMapFileTest.java @@ -1,5 +1,6 @@ package org.dcache.gplazma.plugins; +import static java.util.stream.Collectors.toList; import static org.hamcrest.MatcherAssert.assertThat; import static org.hamcrest.Matchers.empty; import static org.hamcrest.Matchers.hasItem; @@ -496,7 +497,7 @@ public void shouldAddOpWithoutIssuer() throws Exception { var opPrincipals = mappedPrincipals.stream() .filter(OAuthProviderPrincipal.class::isInstance) - .toList(); + .collect(toList()); // Avoid asserting the OP's placeholder issuer URL because we don't // guarantee that value. assertThat(opPrincipals.size(), equalTo(1));