mirror of
https://codeberg.org/PGPainless/sop-java.git
synced 2024-11-22 23:22:05 +01:00
Replace assumeTrue(false) with explicit TestAbortedException
This commit is contained in:
parent
7a825c7607
commit
7325cad696
1 changed files with 2 additions and 2 deletions
|
@ -8,6 +8,7 @@ import org.junit.jupiter.api.condition.EnabledIf;
|
||||||
import org.junit.jupiter.params.ParameterizedTest;
|
import org.junit.jupiter.params.ParameterizedTest;
|
||||||
import org.junit.jupiter.params.provider.Arguments;
|
import org.junit.jupiter.params.provider.Arguments;
|
||||||
import org.junit.jupiter.params.provider.MethodSource;
|
import org.junit.jupiter.params.provider.MethodSource;
|
||||||
|
import org.opentest4j.TestAbortedException;
|
||||||
import sop.SOP;
|
import sop.SOP;
|
||||||
|
|
||||||
import java.util.stream.Stream;
|
import java.util.stream.Stream;
|
||||||
|
@ -15,7 +16,6 @@ import java.util.stream.Stream;
|
||||||
import static org.junit.jupiter.api.Assertions.assertFalse;
|
import static org.junit.jupiter.api.Assertions.assertFalse;
|
||||||
import static org.junit.jupiter.api.Assertions.assertNotNull;
|
import static org.junit.jupiter.api.Assertions.assertNotNull;
|
||||||
import static org.junit.jupiter.api.Assertions.assertTrue;
|
import static org.junit.jupiter.api.Assertions.assertTrue;
|
||||||
import static org.junit.jupiter.api.Assumptions.assumeTrue;
|
|
||||||
|
|
||||||
@EnabledIf("sop.testsuite.operation.AbstractSOPTest#hasBackends")
|
@EnabledIf("sop.testsuite.operation.AbstractSOPTest#hasBackends")
|
||||||
public class VersionTest extends AbstractSOPTest {
|
public class VersionTest extends AbstractSOPTest {
|
||||||
|
@ -59,7 +59,7 @@ public class VersionTest extends AbstractSOPTest {
|
||||||
try {
|
try {
|
||||||
sop.version().getSopSpecVersion();
|
sop.version().getSopSpecVersion();
|
||||||
} catch (RuntimeException e) {
|
} catch (RuntimeException e) {
|
||||||
assumeTrue(false); // SOP backend does not support this operation yet
|
throw new TestAbortedException("SOP backend does not support 'version --sop-spec' yet.");
|
||||||
}
|
}
|
||||||
|
|
||||||
String sopSpec = sop.version().getSopSpecVersion();
|
String sopSpec = sop.version().getSopSpecVersion();
|
||||||
|
|
Loading…
Reference in a new issue