From 3f4365025a7416955a25516fa3ebb228762299ad Mon Sep 17 00:00:00 2001 From: levBagryansky <28lev11@gmail.com> Date: Fri, 26 Apr 2024 20:58:20 +0300 Subject: [PATCH] #3058: violations --- .../org/eolang/maven/hash/ChRemoteTest.java | 22 +++++++++---------- 1 file changed, 11 insertions(+), 11 deletions(-) diff --git a/eo-maven-plugin/src/test/java/org/eolang/maven/hash/ChRemoteTest.java b/eo-maven-plugin/src/test/java/org/eolang/maven/hash/ChRemoteTest.java index 9e7a5d4d23..5241e917b3 100644 --- a/eo-maven-plugin/src/test/java/org/eolang/maven/hash/ChRemoteTest.java +++ b/eo-maven-plugin/src/test/java/org/eolang/maven/hash/ChRemoteTest.java @@ -25,7 +25,9 @@ package org.eolang.maven.hash; import com.yegor256.WeAreOnline; -import org.cactoos.Scalar; +import java.util.stream.Collectors; +import java.util.stream.Stream; +import java.util.stream.StreamSupport; import org.cactoos.experimental.Threads; import org.hamcrest.MatcherAssert; import org.hamcrest.Matchers; @@ -33,10 +35,6 @@ import org.junit.jupiter.api.Test; import org.junit.jupiter.api.extension.ExtendWith; -import java.util.stream.Collectors; -import java.util.stream.Stream; -import java.util.stream.StreamSupport; - /** * Test case for {@link ChRemote}. * @since 0.26 @@ -77,12 +75,14 @@ void isThreadSafe() { final int threads = 200; final String sample = new ChRemote("0.23.19").value(); MatcherAssert.assertThat( - StreamSupport.stream(new Threads<>( - threads, - Stream.generate( - () -> new ChRemote("0.23.19") - ).limit(threads).collect(Collectors.toList()) - ).spliterator(), false) + "You can use this class concurrently", + StreamSupport.stream( + new Threads<>( + threads, + Stream.generate( + () -> new ChRemote("0.23.19") + ).limit(threads).collect(Collectors.toList()) + ).spliterator(), false) .filter(str -> !sample.equals(str)) .collect(Collectors.toList()), Matchers.empty()