@volter/twin-standard 1.0.1 → 1.0.3
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/src/protocol-3.js +7 -1
- package/package.json +1 -1
- package/src/protocol-3.ts +6 -1
package/dist/src/protocol-3.js
CHANGED
|
@@ -100,7 +100,7 @@ function srcFileInForm(unit, name) {
|
|
|
100
100
|
return (isLane(unit) ? ['manifest.ts', 'index.ts', 'fetch.ts', 'budget.ts'] : ['manifest.ts', 'index.ts', 'cli.ts', 'fetch.ts', 'server.ts', 'budget.ts']).includes(name);
|
|
101
101
|
}
|
|
102
102
|
/** The fixed files of semantics/ besides the families' handler files and their tests. */
|
|
103
|
-
const SEMANTICS_FIXED = new Set(['states.ts', 'index.ts', 'shared.ts', 'doors.ts', 'seed.ts', 'around.ts', 'events.ts', 'clock.ts', 'tenant.ts', 'scenario.ts', 'gap.ts', 'graphql.ts', 'sockets.ts']);
|
|
103
|
+
const SEMANTICS_FIXED = new Set(['states.ts', 'index.ts', 'shared.ts', 'doors.ts', 'seed.ts', 'around.ts', 'events.ts', 'clock.ts', 'tenant.ts', 'scenario.ts', 'gap.ts', 'graphql.ts', 'sockets.ts', 'board.ts']);
|
|
104
104
|
/** journeys/'s closed set. */
|
|
105
105
|
const JOURNEY_FILES = new Set(['customer-life.outline.md', 'customer-life.outline.verdict.json', 'customer-life.json', 'customer-life.verdict.json', 'decisions.json',
|
|
106
106
|
'vendor-examples.json', 'vendor-examples.verdict.json', 'demand.json', 'unreachable.json', 'score.json', 'coverage.json',
|
|
@@ -353,6 +353,12 @@ const criteria = [
|
|
|
353
353
|
found.push(`clock.ts exports ${names.join(', ') || 'nothing'}, not only clock`);
|
|
354
354
|
continue;
|
|
355
355
|
}
|
|
356
|
+
if (f === 'board.ts') {
|
|
357
|
+
const names = [...text.matchAll(/^export\s+(?:async\s+)?function\s+([A-Za-z0-9_$]+)/gm)].map((m) => m[1]);
|
|
358
|
+
if (names.join() !== 'board' || /^export\s+(const|let|var|class)\s|^export\s*\{/m.test(text))
|
|
359
|
+
found.push(`board.ts exports ${names.join(', ') || 'nothing'}, not only board`);
|
|
360
|
+
continue;
|
|
361
|
+
}
|
|
356
362
|
if (f === 'around.ts') {
|
|
357
363
|
const names = [...text.matchAll(/^export\s+(?:async\s+)?function\s+([A-Za-z0-9_$]+)/gm)].map((m) => m[1]);
|
|
358
364
|
if (names.join() !== 'around')
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@volter/twin-standard",
|
|
3
|
-
"version": "1.0.
|
|
3
|
+
"version": "1.0.3",
|
|
4
4
|
"description": "The Protocol 3 standard for Volter twin packs: the criteria a pack is graded by, the grader, the gate a pack repository and the twin catalog run on every change and submission, and the spec derivation the grade checks against. Pin a version: every place a pack is judged judges by that standard.",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"twin",
|
package/src/protocol-3.ts
CHANGED
|
@@ -86,7 +86,7 @@ function srcFileInForm(unit: GradeUnit, name: string): boolean {
|
|
|
86
86
|
return (isLane(unit) ? ['manifest.ts', 'index.ts', 'fetch.ts', 'budget.ts'] : ['manifest.ts', 'index.ts', 'cli.ts', 'fetch.ts', 'server.ts', 'budget.ts']).includes(name);
|
|
87
87
|
}
|
|
88
88
|
/** The fixed files of semantics/ besides the families' handler files and their tests. */
|
|
89
|
-
const SEMANTICS_FIXED = new Set(['states.ts', 'index.ts', 'shared.ts', 'doors.ts', 'seed.ts', 'around.ts', 'events.ts', 'clock.ts', 'tenant.ts', 'scenario.ts', 'gap.ts', 'graphql.ts', 'sockets.ts']);
|
|
89
|
+
const SEMANTICS_FIXED = new Set(['states.ts', 'index.ts', 'shared.ts', 'doors.ts', 'seed.ts', 'around.ts', 'events.ts', 'clock.ts', 'tenant.ts', 'scenario.ts', 'gap.ts', 'graphql.ts', 'sockets.ts', 'board.ts']);
|
|
90
90
|
/** journeys/'s closed set. */
|
|
91
91
|
const JOURNEY_FILES = new Set(['customer-life.outline.md', 'customer-life.outline.verdict.json', 'customer-life.json', 'customer-life.verdict.json', 'decisions.json',
|
|
92
92
|
'vendor-examples.json', 'vendor-examples.verdict.json', 'demand.json', 'unreachable.json', 'score.json', 'coverage.json',
|
|
@@ -313,6 +313,11 @@ const criteria: Criterion[] = [
|
|
|
313
313
|
if (names.join() !== 'clock' || /^export\s+(const|let|var|class)\s|^export\s*\{/m.test(text)) found.push(`clock.ts exports ${names.join(', ') || 'nothing'}, not only clock`);
|
|
314
314
|
continue;
|
|
315
315
|
}
|
|
316
|
+
if (f === 'board.ts') {
|
|
317
|
+
const names = [...text.matchAll(/^export\s+(?:async\s+)?function\s+([A-Za-z0-9_$]+)/gm)].map((m) => m[1]);
|
|
318
|
+
if (names.join() !== 'board' || /^export\s+(const|let|var|class)\s|^export\s*\{/m.test(text)) found.push(`board.ts exports ${names.join(', ') || 'nothing'}, not only board`);
|
|
319
|
+
continue;
|
|
320
|
+
}
|
|
316
321
|
if (f === 'around.ts') {
|
|
317
322
|
const names = [...text.matchAll(/^export\s+(?:async\s+)?function\s+([A-Za-z0-9_$]+)/gm)].map((m) => m[1]);
|
|
318
323
|
if (names.join() !== 'around') found.push(`around.ts exports ${names.join(', ') || 'nothing'}, not only around`);
|