complete Studio core and JavaFX boundary migration
Intrepid/Prometeu/Studio/pipeline/pr-master Build started...
JaCoCo Coverage #### Project Overview No changes detected, that affect the code coverage. * Line Coverage: 64.01% (20482/31999) * Branch Coverage: 54.22% (8240/15196) * Lines of Code: 31999 * Cyclomatic Complexity: 13164 #### Quality Gates Summary Output truncated.
Test / Build skipped: 15, passed: 715
Intrepid/Prometeu/Studio/pipeline/head This commit looks good

This commit is contained in:
2026-09-25 11:28:18 +01:00
parent 10f1b3f87c
commit a0a5050d5e
461 changed files with 9319 additions and 7205 deletions
@@ -0,0 +1,90 @@
package p.studio.architecture;
import com.tngtech.archunit.core.importer.ImportOption;
import com.tngtech.archunit.junit.AnalyzeClasses;
import com.tngtech.archunit.junit.ArchTest;
import com.tngtech.archunit.lang.ArchRule;
import static com.tngtech.archunit.lang.syntax.ArchRuleDefinition.noClasses;
@AnalyzeClasses(packages = {"p.studio", "p.packer"}, importOptions = ImportOption.DoNotIncludeTests.class)
class StudioBoundaryArchTest {
@ArchTest
static final ArchRule staticContainerCannotReturn = noClasses()
.that().resideInAnyPackage("p.studio..")
.should().haveSimpleName("Container")
.because("DEC-0059 requires the static service locator to be physically absent");
@ArchTest
static final ArchRule appContainerCompatibilityBridgeCannotReturn = noClasses()
.that().resideInAnyPackage("p.studio..")
.should().haveSimpleName("AppContainer")
.because("DEC-0059 requires Spring composition without a legacy service bag");
@ArchTest
static final ArchRule studioApiIsFrameworkAndProviderNeutral = noClasses()
.that().resideInAPackage("p.studio.api..")
.should().dependOnClassesThat().resideInAnyPackage(
"javafx..",
"org.springframework..",
"org.springframework.modulith..",
"p.packer..",
"p.studio.compiler..",
"p.studio.lsp..",
"p.studio.utilities..",
"p.studio.core..",
"p.studio.ui..")
.because("DEC-0059 requires a toolkit and provider neutral public Studio API");
@ArchTest
static final ArchRule studioCoreDoesNotDependOnJavaFx = noClasses()
.that().resideInAPackage("p.studio.core..")
.should().dependOnClassesThat().resideInAPackage("javafx..")
.because("DEC-0059 requires the Studio Core to compile without JavaFX");
@ArchTest
static final ArchRule studioCoreDoesNotDependOnSpring = noClasses()
.that().resideInAPackage("p.studio.core..")
.should().dependOnClassesThat().resideInAPackage("org.springframework..")
.because("DEC-0059 confines Spring to application composition and keeps core as constructor-injected POJOs");
@ArchTest
static final ArchRule studioCoreDoesNotDependOnLegacySharedInfrastructure = noClasses()
.that().resideInAPackage("p.studio.core..")
.should().dependOnClassesThat().resideInAPackage("p.studio.utilities..")
.because("DEC-0059 requires the extracted core to own explicit contracts instead of inheriting the mixed Studio utility classpath");
@ArchTest
static final ArchRule javaFxAdapterDoesNotDependOnCoreOrProviderImplementations = noClasses()
.that().resideInAPackage("p.studio.ui.javafx..")
.should().dependOnClassesThat().resideInAnyPackage(
"p.studio.core..",
"p.packer..",
"p.studio.compiler..",
"p.studio.lsp..",
"p.studio.utilities..")
.because("DEC-0059 requires JavaFX to consume Studio API contracts only");
@ArchTest
static final ArchRule javaFxAdapterDoesNotOrchestrateTheFileSystem = noClasses()
.that().resideInAPackage("p.studio.ui.javafx..")
.should().dependOnClassesThat().haveFullyQualifiedName("java.nio.file.Files")
.because("DEC-0059 keeps filesystem orchestration behind neutral Studio services");
@ArchTest
static final ArchRule javaFxAdapterDoesNotOwnSerialization = noClasses()
.that().resideInAPackage("p.studio.ui.javafx..")
.should().dependOnClassesThat().resideInAPackage("com.fasterxml.jackson..")
.because("DEC-0059 keeps serialization in core or application adapters, not visual controls");
@ArchTest
static final ArchRule packerDoesNotDependOnStudio = noClasses()
.that().resideInAPackage("p.packer..")
.should().dependOnClassesThat().resideInAnyPackage(
"p.studio.api..",
"p.studio.core..",
"p.studio.ui..",
"p.studio.ui.javafx.window..",
"p.studio.ui.javafx.workspaces..")
.because("DEC-0059 keeps p.packer autonomous and dependency direction Studio to Packer");
}