Make configuration and compatibility contracts executable

This commit is contained in:
2026-11-12 08:27:53 +01:00
parent 306266ae40
commit 85a75383a0
28 changed files with 2284 additions and 8 deletions
@@ -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());
}
}
}