@@ -3,10 +3,8 @@ package org.scip_code.scip_java.kotlinc.test
33import com.tschuchort.compiletesting.KotlinCompilation
44import com.tschuchort.compiletesting.PluginOption
55import com.tschuchort.compiletesting.SourceFile
6- import io.kotest.assertions.assertSoftly
76import io.kotest.assertions.fail
8- import io.kotest.assertions.withClue
9- import io.kotest.matchers.collections.shouldContain
7+ import io.kotest.matchers.collections.shouldContainAll
108import io.kotest.matchers.shouldBe
119import io.kotest.matchers.shouldNotBe
1210import java.io.File
@@ -103,9 +101,7 @@ class AnalyzerTest {
103101 }
104102 },
105103 )
106- assertSoftly(document.occurrencesList) {
107- withClue(this ) { occurrences.forEach(::shouldContain) }
108- }
104+ document.occurrencesList.shouldContainAll(* occurrences)
109105
110106 val symbols =
111107 arrayOf(
@@ -120,7 +116,7 @@ class AnalyzerTest {
120116 signatureText = " public final fun foo(): Unit"
121117 },
122118 )
123- assertSoftly( document.symbolsList) { withClue( this ) { symbols.forEach(::shouldContain) } }
119+ document.symbolsList.shouldContainAll( * symbols)
124120 }
125121
126122 @Test
@@ -189,9 +185,7 @@ class AnalyzerTest {
189185 }
190186 },
191187 )
192- assertSoftly(document.occurrencesList) {
193- withClue(this ) { occurrences.forEach(::shouldContain) }
194- }
188+ document.occurrencesList.shouldContainAll(* occurrences)
195189 }
196190
197191 @Test
@@ -279,9 +273,7 @@ class AnalyzerTest {
279273 }
280274 },
281275 )
282- assertSoftly(document.occurrencesList) {
283- withClue(this ) { occurrences.forEach(::shouldContain) }
284- }
276+ document.occurrencesList.shouldContainAll(* occurrences)
285277
286278 val symbols =
287279 arrayOf(
@@ -306,7 +298,7 @@ class AnalyzerTest {
306298 signatureText = " public final fun localClassMethod(): Unit"
307299 },
308300 )
309- assertSoftly( document.symbolsList) { withClue( this ) { symbols.forEach(::shouldContain) } }
301+ document.symbolsList.shouldContainAll( * symbols)
310302 }
311303
312304 @Test
@@ -412,9 +404,7 @@ class AnalyzerTest {
412404 }
413405 },
414406 )
415- assertSoftly(document.occurrencesList) {
416- withClue(this ) { occurrences.forEach(::shouldContain) }
417- }
407+ document.occurrencesList.shouldContainAll(* occurrences)
418408
419409 val symbols =
420410 arrayOf(
@@ -441,7 +431,7 @@ class AnalyzerTest {
441431 addOverriddenSymbols(" sample/Interface#foo()." )
442432 },
443433 )
444- assertSoftly( document.symbolsList) { withClue( this ) { symbols.forEach(::shouldContain) } }
434+ document.symbolsList.shouldContainAll( * symbols)
445435 }
446436
447437 @Test
@@ -627,9 +617,7 @@ class AnalyzerTest {
627617 }
628618 },
629619 )
630- assertSoftly(document.occurrencesList) {
631- withClue(this ) { occurrences.forEach(::shouldContain) }
632- }
620+ document.occurrencesList.shouldContainAll(* occurrences)
633621
634622 val symbols =
635623 arrayOf(
@@ -663,7 +651,7 @@ class AnalyzerTest {
663651 addOverriddenSymbols(" sample/Interface#foo()." )
664652 },
665653 )
666- assertSoftly( document.symbolsList) { withClue( this ) { symbols.forEach(::shouldContain) } }
654+ document.symbolsList.shouldContainAll( * symbols)
667655 }
668656
669657 @Test
@@ -732,9 +720,7 @@ class AnalyzerTest {
732720 }
733721 },
734722 )
735- assertSoftly(document.occurrencesList) {
736- withClue(this ) { occurrences.forEach(::shouldContain) }
737- }
723+ document.occurrencesList.shouldContainAll(* occurrences)
738724 }
739725
740726 @Test
@@ -777,9 +763,7 @@ class AnalyzerTest {
777763 }
778764 },
779765 )
780- assertSoftly(document.occurrencesList) {
781- withClue(this ) { occurrences.forEach(::shouldContain) }
782- }
766+ document.occurrencesList.shouldContainAll(* occurrences)
783767 }
784768
785769 @Test
@@ -1310,9 +1294,7 @@ class AnalyzerTest {
13101294 },
13111295 )
13121296
1313- assertSoftly(document.occurrencesList) {
1314- withClue(document.occurrencesList) { occurrences.forEach(::shouldContain) }
1315- }
1297+ document.occurrencesList.shouldContainAll(* occurrences)
13161298
13171299 val symbols =
13181300 arrayOf(
@@ -1323,7 +1305,7 @@ class AnalyzerTest {
13231305 }
13241306 )
13251307
1326- assertSoftly( document.symbolsList) { withClue( this ) { symbols.forEach(::shouldContain) } }
1308+ document.symbolsList.shouldContainAll( * symbols)
13271309 }
13281310
13291311 @Test
@@ -1397,9 +1379,7 @@ class AnalyzerTest {
13971379 }
13981380 },
13991381 )
1400- assertSoftly(document.occurrencesList) {
1401- withClue(this ) { occurrences.forEach(::shouldContain) }
1402- }
1382+ document.occurrencesList.shouldContainAll(* occurrences)
14031383
14041384 val symbols =
14051385 arrayOf(
@@ -1414,7 +1394,7 @@ class AnalyzerTest {
14141394 signatureText = " public final fun foo(): Unit"
14151395 },
14161396 )
1417- assertSoftly( document.symbolsList) { withClue( this ) { symbols.forEach(::shouldContain) } }
1397+ document.symbolsList.shouldContainAll( * symbols)
14181398 }
14191399
14201400 @Test
0 commit comments