Skip to content

Commit f57ffc3

Browse files
GitHub #493: v2: teach the invariant, automate the ceremony with AI-first tools (#512)
1 parent a8aebfc commit f57ffc3

4 files changed

Lines changed: 32 additions & 12 deletions

File tree

src/V2/Support/PlatformConformanceSuite.php

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -35,7 +35,7 @@ final class PlatformConformanceSuite
3535

3636
public const RESULT_VERSION = 1;
3737

38-
public const AUTHORITY_DOC = 'docs/architecture/platform-conformance-suite.md';
38+
public const AUTHORITY_DOC = 'https://github.com/durable-workflow/workflow/blob/v2/docs/architecture/platform-conformance-suite.md';
3939

4040
public const CATEGORY_STATUS_STABLE = 'stable';
4141

@@ -196,7 +196,7 @@ private static function fixtureCatalog(): array
196196
'path' => 'tests/fixtures/control-plane/',
197197
],
198198
],
199-
'authority_doc' => 'durable-workflow.github.io/docs/polyglot/cli-python-parity.md',
199+
'authority_doc' => 'https://github.com/durable-workflow/durable-workflow.github.io/blob/main/docs/polyglot/cli-python-parity.md',
200200
],
201201
'worker_task_lifecycle' => [
202202
'status' => self::CATEGORY_STATUS_STABLE,
@@ -219,7 +219,7 @@ private static function fixtureCatalog(): array
219219
'path' => 'tests/fixtures/external-task-result/',
220220
],
221221
],
222-
'authority_doc' => 'server/docs/contracts/external-task-input.md, server/docs/contracts/external-task-result.md',
222+
'authority_doc' => 'https://github.com/durable-workflow/server/blob/main/docs/contracts/external-task-input.md, https://github.com/durable-workflow/server/blob/main/docs/contracts/external-task-result.md',
223223
],
224224
'history_replay_bundles' => [
225225
'status' => self::CATEGORY_STATUS_STABLE,
@@ -234,7 +234,7 @@ private static function fixtureCatalog(): array
234234
'path' => 'tests/fixtures/golden_history/',
235235
],
236236
],
237-
'authority_doc' => 'workflow/docs/api-stability.md (frozen history-event wire formats)',
237+
'authority_doc' => 'https://github.com/durable-workflow/workflow/blob/v2/docs/api-stability.md',
238238
],
239239
'failure_repair_actionability' => [
240240
'status' => self::CATEGORY_STATUS_STABLE,
@@ -249,7 +249,7 @@ private static function fixtureCatalog(): array
249249
'path' => 'docs/contracts/replay-verification.md',
250250
],
251251
],
252-
'authority_doc' => 'server/docs/contracts/external-task-result.md',
252+
'authority_doc' => 'https://github.com/durable-workflow/server/blob/main/docs/contracts/external-task-result.md',
253253
],
254254
'cli_json_envelopes' => [
255255
'status' => self::CATEGORY_STATUS_STABLE,
@@ -264,7 +264,7 @@ private static function fixtureCatalog(): array
264264
'path' => 'schemas/',
265265
],
266266
],
267-
'authority_doc' => 'durable-workflow.github.io/docs/polyglot/cli-reference.md',
267+
'authority_doc' => 'https://github.com/durable-workflow/durable-workflow.github.io/blob/main/docs/polyglot/cli-reference.md',
268268
],
269269
'waterline_observer_envelopes' => [
270270
'status' => self::CATEGORY_STATUS_PROVISIONAL,
@@ -275,7 +275,7 @@ private static function fixtureCatalog(): array
275275
'path' => 'tests/fixtures/observer/ (planned)',
276276
],
277277
],
278-
'authority_doc' => 'waterline/CONFORMANCE.md',
278+
'authority_doc' => 'https://github.com/durable-workflow/waterline/blob/v2/CONFORMANCE.md',
279279
],
280280
'mcp_discovery_envelopes' => [
281281
'status' => self::CATEGORY_STATUS_PROVISIONAL,
@@ -294,7 +294,7 @@ private static function fixtureCatalog(): array
294294
'path' => 'tests/Feature/McpWorkflowServerTest.php',
295295
],
296296
],
297-
'authority_doc' => 'durable-workflow.github.io/docs/mcp-workflows.md',
297+
'authority_doc' => 'https://github.com/durable-workflow/durable-workflow.github.io/blob/main/docs/mcp-workflows.md',
298298
],
299299
];
300300
}

src/V2/Support/SdkNeutralityContract.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -44,7 +44,7 @@ final class SdkNeutralityContract
4444

4545
public const VERSION = 1;
4646

47-
public const AUTHORITY_DOC = 'docs/architecture/sdk-neutrality.md';
47+
public const AUTHORITY_DOC = 'https://github.com/durable-workflow/workflow/blob/v2/docs/architecture/sdk-neutrality.md';
4848

4949
public const POSTURE_PRIORITY = 'priority';
5050

tests/Unit/V2/PlatformConformanceSuiteTest.php

Lines changed: 22 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -30,7 +30,7 @@ public function testManifestAdvertisesAuthorityIdentity(): void
3030
$this->assertSame('durable-workflow.v2.platform-conformance.suite', $manifest['schema']);
3131
$this->assertSame(1, $manifest['version']);
3232
$this->assertSame(
33-
'docs/architecture/platform-conformance-suite.md',
33+
'https://github.com/durable-workflow/workflow/blob/v2/docs/architecture/platform-conformance-suite.md',
3434
$manifest['authority_doc'],
3535
);
3636
$this->assertSame(
@@ -138,6 +138,26 @@ public function testEveryFixtureCategoryDeclaresStatusDescriptionAndAtLeastOneSo
138138
}
139139
}
140140

141+
public function testEveryFixtureCategoryAuthorityDocIsACustomerResolvableUrl(): void
142+
{
143+
$manifest = PlatformConformanceSuite::manifest();
144+
145+
foreach ($manifest['fixture_catalog'] as $name => $category) {
146+
$this->assertArrayHasKey('authority_doc', $category, "$name needs authority_doc");
147+
148+
$authorityDoc = $category['authority_doc'];
149+
$this->assertIsString($authorityDoc, "$name authority_doc must be a string");
150+
151+
foreach (preg_split('/,\s*/', $authorityDoc) as $entry) {
152+
$this->assertMatchesRegularExpression(
153+
'#^https://#',
154+
$entry,
155+
"$name authority_doc entry `$entry` must be a customer-resolvable https:// URL",
156+
);
157+
}
158+
}
159+
}
160+
141161
public function testMcpDiscoveryCategoryNamesCurrentReferenceSurface(): void
142162
{
143163
$manifest = PlatformConformanceSuite::manifest();
@@ -149,7 +169,7 @@ public function testMcpDiscoveryCategoryNamesCurrentReferenceSurface(): void
149169
'MCP conformance remains advisory until the public fixture set is promoted.',
150170
);
151171
$this->assertSame(
152-
'durable-workflow.github.io/docs/mcp-workflows.md',
172+
'https://github.com/durable-workflow/durable-workflow.github.io/blob/main/docs/mcp-workflows.md',
153173
$category['authority_doc'],
154174
);
155175
$this->assertContains(

tests/Unit/V2/SdkNeutralityContractTest.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,7 @@ public function testManifestAdvertisesAuthorityIdentity(): void
3131
$this->assertSame('durable-workflow.v2.sdk-neutrality.contract', $manifest['schema']);
3232
$this->assertSame(1, $manifest['version']);
3333
$this->assertSame(
34-
'docs/architecture/sdk-neutrality.md',
34+
'https://github.com/durable-workflow/workflow/blob/v2/docs/architecture/sdk-neutrality.md',
3535
$manifest['authority_doc'],
3636
);
3737
}

0 commit comments

Comments
 (0)