Make configuration and compatibility contracts executable
This commit is contained in:
@@ -11,6 +11,13 @@
|
||||
<module.java.release>25</module.java.release>
|
||||
</properties>
|
||||
<dependencies>
|
||||
<dependency>
|
||||
<groupId>de.neitzel.fxdesigner</groupId>
|
||||
<artifactId>designer-core</artifactId>
|
||||
<version>${project.version}</version>
|
||||
<type>test-jar</type>
|
||||
<scope>test</scope>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>de.neitzel.fxdesigner</groupId>
|
||||
<artifactId>designer-kit-ui</artifactId>
|
||||
|
||||
+27
@@ -0,0 +1,27 @@
|
||||
package de.neitzel.fxdesigner.standalone;
|
||||
|
||||
import de.neitzel.fxdesigner.config.*;
|
||||
import de.neitzel.fxdesigner.host.*;
|
||||
import java.nio.file.*;
|
||||
import java.util.*;
|
||||
import java.util.concurrent.*;
|
||||
import org.junit.jupiter.api.*;
|
||||
import org.junit.jupiter.api.io.TempDir;
|
||||
|
||||
class ConfigurationIntegrationTest {
|
||||
@TempDir Path root;
|
||||
|
||||
@Test
|
||||
void configurationFailureKeepsRealStandaloneDocumentEditable() throws Exception {
|
||||
var catalog = ConfigurationHostContract.fixture(root);
|
||||
var diagnostics = new ArrayList<HostServices.Diagnostic>();
|
||||
try (var host =
|
||||
new StandaloneHost(
|
||||
new ConfiguredRuntimes(Map.of()),
|
||||
l -> CompletableFuture.completedFuture(null),
|
||||
diagnostics::add)) {
|
||||
ConfigurationHostContract.exercise(host.services(), catalog);
|
||||
Assertions.assertFalse(diagnostics.isEmpty());
|
||||
}
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user