From 21502ed023b17a5dce2078a97a642da287bc76f9 Mon Sep 17 00:00:00 2001 From: "Timothy J. Aveni" Date: Sun, 20 Sep 2026 19:52:37 -0700 Subject: [PATCH] Qualify read-only forwarding and scoped portable discovery --- test/composite-fixture.ts | 3 ++- test/fixtures/local-first-composite/DocumentLabel.qx | 6 ++++++ test/fixtures/local-first-composite/workspace.qx | 5 +++++ 3 files changed, 13 insertions(+), 1 deletion(-) create mode 100644 test/fixtures/local-first-composite/DocumentLabel.qx diff --git a/test/composite-fixture.ts b/test/composite-fixture.ts index 156d8aa..f60412c 100644 --- a/test/composite-fixture.ts +++ b/test/composite-fixture.ts @@ -11,7 +11,7 @@ import { compileQuery } from "../src/query/compile.js"; import { readReaderFixture } from "./reader-fixture.js"; const directory = resolve("test/fixtures/local-first-composite"); export async function loadCompositeWorkspace() { - const changed = new Set(["DocumentFactory", "DocumentMetadata", "CommentFactory"]); + const changed = new Set(["DocumentFactory", "DocumentMetadata", "DocumentLabel", "CommentFactory"]); const read = (name: string) => readFile(resolve(directory, `${name}.qx`), "utf8"); const source = { repository: "https://example.test/composite.git", commit: "b".repeat(40) }; const interfaces = new Map(); @@ -22,6 +22,7 @@ export async function loadCompositeWorkspace() { "DocumentActions", "DocumentFactory", "DocumentMetadata", + "DocumentLabel", "CommentFactory", ]) { const result = compileCapabilityResourceSource( diff --git a/test/fixtures/local-first-composite/DocumentLabel.qx b/test/fixtures/local-first-composite/DocumentLabel.qx new file mode 100644 index 0000000..dc1649a --- /dev/null +++ b/test/fixtures/local-first-composite/DocumentLabel.qx @@ -0,0 +1,6 @@ +interface DocumentLabel id "interface:reader:document-label" +revision "interface:reader:document-label@1" { + queryable value title id "document:view-title" : string { + get id "document:view-title:get" execution snapshot targets [browser, server]; + } +} diff --git a/test/fixtures/local-first-composite/workspace.qx b/test/fixtures/local-first-composite/workspace.qx index af3eea3..62e7a44 100644 --- a/test/fixtures/local-first-composite/workspace.qx +++ b/test/fixtures/local-first-composite/workspace.qx @@ -7,6 +7,7 @@ workspace Reader id "workspace:reader" revision "workspace:reader@1" commit "aaa import package ReaderRuntime; import package CommentRuntime; import interface DocumentMetadata; + import interface DocumentLabel; import interface CommentFactory; // Shared record definitions, repeated explicitly in independently locked resources. @@ -62,6 +63,10 @@ workspace Reader id "workspace:reader" revision "workspace:reader@1" commit "aaa }; } + conform Document as DocumentLabel id "conformance:reader:document-label" { + bind title.get to interface DocumentMetadata.label.get; + } + conform Document as DocumentMetadata id "conformance:reader:document-metadata" { private state Label id "slot:document:label" on Document : string policy register; initialize { label to state Label; };