@anselmdk/feature-spec-md 0.6.1 → 0.6.2-rc.1
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/cli.js +35 -141
- package/dist/cli.js.map +1 -1
- package/dist/githubReportMetadata.d.ts +7 -0
- package/dist/githubReportMetadata.d.ts.map +1 -0
- package/dist/githubReportMetadata.js +152 -0
- package/dist/githubReportMetadata.js.map +1 -0
- package/dist/index.d.ts +2 -0
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +1 -0
- package/dist/index.js.map +1 -1
- package/dist/playwright.d.ts +3 -3
- package/dist/playwright.d.ts.map +1 -1
- package/dist/playwright.js +62 -15
- package/dist/playwright.js.map +1 -1
- package/dist/reportArtifacts.d.ts +1 -1
- package/dist/reportArtifacts.d.ts.map +1 -1
- package/dist/reportArtifacts.js +1 -1
- package/dist/reportArtifacts.js.map +1 -1
- package/dist/reportHtml.d.ts +3 -1
- package/dist/reportHtml.d.ts.map +1 -1
- package/dist/reportHtml.js +11 -14
- package/dist/reportHtml.js.map +1 -1
- package/dist/reportTemplate.d.ts +0 -1
- package/dist/reportTemplate.d.ts.map +1 -1
- package/dist/reportTemplate.js +146 -192
- package/dist/reportTemplate.js.map +1 -1
- package/dist/reportTemplates/shared.d.ts +6 -0
- package/dist/reportTemplates/shared.d.ts.map +1 -0
- package/dist/reportTemplates/shared.js +15 -0
- package/dist/reportTemplates/shared.js.map +1 -0
- package/dist/screenshots.d.ts +1 -3
- package/dist/screenshots.d.ts.map +1 -1
- package/dist/screenshots.js +20 -23
- package/dist/screenshots.js.map +1 -1
- package/dist/types.d.ts +3 -23
- package/dist/types.d.ts.map +1 -1
- package/package.json +2 -2
- package/src/mocks/current/screenshots/screenshots.json +19 -1
- package/src/mocks/previous/screenshots/screenshots.json +10 -1
package/dist/screenshots.js
CHANGED
|
@@ -1,42 +1,36 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* Screenshot evidence manifest loading and normalization for generated spec
|
|
3
|
-
* implementation reports.
|
|
4
|
-
*/
|
|
5
1
|
import { readFile } from "node:fs/promises";
|
|
6
2
|
import { expandArtifactPatterns } from "./filePatterns.js";
|
|
7
|
-
/** Load screenshot evidence manifests and normalize entries for report rendering. */
|
|
8
3
|
export async function collectSpecScreenshots(patterns) {
|
|
9
|
-
const
|
|
4
|
+
const evidence = [];
|
|
10
5
|
for (const file of await expandArtifactPatterns(patterns)) {
|
|
11
6
|
const parsed = JSON.parse(await readFile(file, "utf8"));
|
|
12
|
-
const entries = Array.isArray(parsed)
|
|
13
|
-
? parsed
|
|
7
|
+
const entries = isRecord(parsed) && Array.isArray(parsed.evidence)
|
|
8
|
+
? parsed.evidence
|
|
14
9
|
: isRecord(parsed) && Array.isArray(parsed.screenshots)
|
|
15
10
|
? parsed.screenshots
|
|
16
11
|
: [];
|
|
17
12
|
for (const entry of entries) {
|
|
18
|
-
const
|
|
19
|
-
if (
|
|
20
|
-
|
|
13
|
+
const normalized = normalizeEvidence(entry);
|
|
14
|
+
if (normalized)
|
|
15
|
+
evidence.push(normalized);
|
|
21
16
|
}
|
|
22
17
|
}
|
|
23
|
-
return
|
|
18
|
+
return evidence;
|
|
24
19
|
}
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
const screenshotKeys = new Set(screenshots.map((screenshot) => screenshotKey(screenshot.specPath, screenshot.line)));
|
|
20
|
+
export function validateScenarioScreenshots(specs, evidence) {
|
|
21
|
+
const evidenceKeys = new Set(evidence.map((entry) => screenshotKey(entry.specPath, entry.line)));
|
|
28
22
|
const issues = [];
|
|
29
23
|
for (const spec of specs) {
|
|
30
24
|
for (const scenario of spec.scenarios) {
|
|
31
25
|
if (scenario.evidence.screenshots === "required") {
|
|
32
26
|
for (const step of scenario.steps) {
|
|
33
|
-
if (!
|
|
27
|
+
if (!evidenceKeys.has(screenshotKey(spec.filePath, step.line))) {
|
|
34
28
|
issues.push({
|
|
35
29
|
code: "missing-screenshot-evidence",
|
|
36
30
|
severity: "error",
|
|
37
31
|
filePath: spec.filePath,
|
|
38
32
|
line: step.line,
|
|
39
|
-
message: `
|
|
33
|
+
message: `Visual evidence is required for ${scenario.id} ${step.keyword} ${step.text}`,
|
|
40
34
|
});
|
|
41
35
|
}
|
|
42
36
|
}
|
|
@@ -51,23 +45,26 @@ export function screenshotKey(filePath, line) {
|
|
|
51
45
|
export function normalizeFilePath(filePath) {
|
|
52
46
|
return filePath.replace(/\\/g, "/").replace(/^\.\//, "");
|
|
53
47
|
}
|
|
54
|
-
function
|
|
48
|
+
function normalizeEvidence(value) {
|
|
55
49
|
if (!isRecord(value))
|
|
56
50
|
return null;
|
|
57
51
|
const specPath = value.specPath;
|
|
58
52
|
const line = value.line;
|
|
53
|
+
const changed = value.changed;
|
|
59
54
|
const imagePath = value.path ?? value.imagePath;
|
|
60
|
-
if (typeof specPath !== "string" ||
|
|
61
|
-
|
|
62
|
-
|
|
55
|
+
if (typeof specPath !== "string" || typeof line !== "number")
|
|
56
|
+
return null;
|
|
57
|
+
const changedValue = typeof changed === "boolean" ? changed : true;
|
|
58
|
+
if (changedValue && typeof imagePath !== "string")
|
|
63
59
|
return null;
|
|
64
|
-
}
|
|
65
60
|
return {
|
|
66
61
|
specPath: normalizeFilePath(specPath),
|
|
67
62
|
line,
|
|
68
|
-
|
|
63
|
+
changed: changedValue,
|
|
64
|
+
path: typeof imagePath === "string" ? imagePath : undefined,
|
|
69
65
|
title: typeof value.title === "string" ? value.title : undefined,
|
|
70
66
|
testPath: typeof value.testPath === "string" ? value.testPath : undefined,
|
|
67
|
+
comparedWithLine: typeof value.comparedWithLine === "number" ? value.comparedWithLine : undefined,
|
|
71
68
|
};
|
|
72
69
|
}
|
|
73
70
|
function isRecord(value) {
|
package/dist/screenshots.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"screenshots.js","sourceRoot":"","sources":["../src/screenshots.ts"],"names":[],"mappings":"AAAA
|
|
1
|
+
{"version":3,"file":"screenshots.js","sour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
-
/** Shared frontmatter fields supported by all spec documents. */
|
|
6
1
|
export type SpecFrontmatter = {
|
|
7
2
|
id: string;
|
|
8
3
|
title: string;
|
|
9
4
|
status?: "draft" | "active" | "deprecated";
|
|
10
5
|
owner?: string;
|
|
11
6
|
};
|
|
12
|
-
/** Frontmatter fields supported by documents that may reference models. */
|
|
13
7
|
export type ModelReferenceFrontmatter = SpecFrontmatter & {
|
|
14
8
|
model?: string;
|
|
15
9
|
models?: string[] | string;
|
|
@@ -20,14 +14,11 @@ export type ScenarioEvidencePolicy = {
|
|
|
20
14
|
test: ScenarioTestType;
|
|
21
15
|
screenshots: ScreenshotPolicy;
|
|
22
16
|
};
|
|
23
|
-
/** Frontmatter fields supported by `*.feature.md` files. */
|
|
24
17
|
export type FeatureFrontmatter = ModelReferenceFrontmatter & {
|
|
25
18
|
test?: ScenarioTestType;
|
|
26
19
|
screenshots?: ScreenshotPolicy;
|
|
27
20
|
};
|
|
28
|
-
/** Frontmatter fields supported by `*.design.md` files. */
|
|
29
21
|
export type DesignFrontmatter = ModelReferenceFrontmatter;
|
|
30
|
-
/** Parsed contents of one `*.model.md` file. */
|
|
31
22
|
export type ModelSpec = {
|
|
32
23
|
kind: "model";
|
|
33
24
|
filePath: string;
|
|
@@ -38,7 +29,6 @@ export type ModelSpec = {
|
|
|
38
29
|
rules: FeatureRule[];
|
|
39
30
|
source: string;
|
|
40
31
|
};
|
|
41
|
-
/** Parsed contents of one `*.feature.md` file. */
|
|
42
32
|
export type FeatureSpec = {
|
|
43
33
|
kind?: "feature";
|
|
44
34
|
filePath: string;
|
|
@@ -49,7 +39,6 @@ export type FeatureSpec = {
|
|
|
49
39
|
scenarios: FeatureScenario[];
|
|
50
40
|
source: string;
|
|
51
41
|
};
|
|
52
|
-
/** Parsed contents of one `*.stack.md` file. */
|
|
53
42
|
export type StackSpec = {
|
|
54
43
|
kind: "stack";
|
|
55
44
|
filePath: string;
|
|
@@ -63,7 +52,6 @@ export type StackSpec = {
|
|
|
63
52
|
rules: FeatureRule[];
|
|
64
53
|
source: string;
|
|
65
54
|
};
|
|
66
|
-
/** Parsed contents of one `*.design.md` file. */
|
|
67
55
|
export type DesignSpec = {
|
|
68
56
|
kind: "design";
|
|
69
57
|
filePath: string;
|
|
@@ -78,16 +66,13 @@ export type DesignSpec = {
|
|
|
78
66
|
rules: FeatureRule[];
|
|
79
67
|
source: string;
|
|
80
68
|
};
|
|
81
|
-
/** Any parsed spec document. */
|
|
82
69
|
export type SpecDocument = ModelSpec | FeatureSpec | StackSpec | DesignSpec;
|
|
83
|
-
/** A model concept declared in the `## Model` section. */
|
|
84
70
|
export type ModelItem = {
|
|
85
71
|
id: string;
|
|
86
72
|
title: string;
|
|
87
73
|
body: string;
|
|
88
74
|
line: number;
|
|
89
75
|
};
|
|
90
|
-
/** A rule declared in the `## Rules` section. */
|
|
91
76
|
export type FeatureRule = {
|
|
92
77
|
id: string;
|
|
93
78
|
text: string;
|
|
@@ -95,7 +80,6 @@ export type FeatureRule = {
|
|
|
95
80
|
strength: "required" | "recommended" | "optional" | "unspecified";
|
|
96
81
|
line: number;
|
|
97
82
|
};
|
|
98
|
-
/** A concrete example declared in the `## Scenarios` section. */
|
|
99
83
|
export type FeatureScenario = {
|
|
100
84
|
id: string;
|
|
101
85
|
title: string;
|
|
@@ -103,7 +87,6 @@ export type FeatureScenario = {
|
|
|
103
87
|
evidence: ScenarioEvidencePolicy;
|
|
104
88
|
steps: FeatureStep[];
|
|
105
89
|
};
|
|
106
|
-
/** A single Given / When / Then style step inside a scenario. */
|
|
107
90
|
export type FeatureStep = {
|
|
108
91
|
keyword: StepKeyword;
|
|
109
92
|
text: string;
|
|
@@ -111,7 +94,6 @@ export type FeatureStep = {
|
|
|
111
94
|
};
|
|
112
95
|
export type RuleKeyword = "MUST" | "MUST NOT" | "SHOULD" | "SHOULD NOT" | "MAY" | "OPTIONAL";
|
|
113
96
|
export type StepKeyword = "Given" | "When" | "Then" | "And" | "But";
|
|
114
|
-
/** Validation problem found in a spec, test reference, or report input. */
|
|
115
97
|
export type ValidationIssue = {
|
|
116
98
|
code: string;
|
|
117
99
|
severity: "error" | "warning";
|
|
@@ -119,7 +101,6 @@ export type ValidationIssue = {
|
|
|
119
101
|
filePath?: string;
|
|
120
102
|
line?: number;
|
|
121
103
|
};
|
|
122
|
-
/** A model item, rule, or scenario ID found in executable tests. */
|
|
123
104
|
export type TestReference = {
|
|
124
105
|
id: string;
|
|
125
106
|
filePath: string;
|
|
@@ -127,7 +108,6 @@ export type TestReference = {
|
|
|
127
108
|
kind: "model" | "rule" | "scenario";
|
|
128
109
|
source: "title" | "tag" | "covers" | "annotation" | "free-text";
|
|
129
110
|
};
|
|
130
|
-
/** Coverage state for one expected model item, rule, or scenario. */
|
|
131
111
|
export type CoverageItem = {
|
|
132
112
|
id: string;
|
|
133
113
|
title?: string;
|
|
@@ -136,7 +116,6 @@ export type CoverageItem = {
|
|
|
136
116
|
covered: boolean;
|
|
137
117
|
references: TestReference[];
|
|
138
118
|
};
|
|
139
|
-
/** Complete test coverage mapping for a set of spec documents. */
|
|
140
119
|
export type CoverageSummary = {
|
|
141
120
|
modelCoverage?: CoverageItem[];
|
|
142
121
|
ruleCoverage: CoverageItem[];
|
|
@@ -145,12 +124,13 @@ export type CoverageSummary = {
|
|
|
145
124
|
orphanRuleReferences: TestReference[];
|
|
146
125
|
orphanScenarioReferences: TestReference[];
|
|
147
126
|
};
|
|
148
|
-
/** Screenshot evidence associated with an exact spec line. */
|
|
149
127
|
export type SpecScreenshot = {
|
|
150
128
|
specPath: string;
|
|
151
129
|
line: number;
|
|
152
|
-
|
|
130
|
+
changed?: boolean;
|
|
131
|
+
path?: string;
|
|
153
132
|
title?: string;
|
|
154
133
|
testPath?: string;
|
|
134
|
+
comparedWithLine?: number;
|
|
155
135
|
};
|
|
156
136
|
//# sourceMappingURL=types.d.ts.map
|
package/dist/types.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"types.d.ts","sourceR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ACpC,MAAM,EAAE,OAAO,GAAG,KAAK,GAAG,QAAQ,GAAG,YAAY,GAAG,WAAW,CAAC;CACjE,CAAC;AAEF,MAAM,MAAM,YAAY,GAAG;IACzB,EAAE,EAAE,MAAM,CAAC;IACX,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,QAAQ,CAAC,EAAE,MAAM,CAAC;IAClB,IAAI,CAAC,EAAE,MAAM,CAAC;IACd,OAAO,EAAE,OAAO,CAAC;IACjB,UAAU,EAAE,aAAa,EAAE,CAAC;CAC7B,CAAC;AAEF,MAAM,MAAM,eAAe,GAAG;IAC5B,aAAa,CAAC,EAAE,YAAY,EAAE,CAAC;IAC/B,YAAY,EAAE,YAAY,EAAE,CAAC;IAC7B,gBAAgB,EAAE,YAAY,EAAE,CAAC;IACjC,qBAAqB,CAAC,EAAE,aAAa,EAAE,CAAC;IACxC,oBAAoB,EAAE,aAAa,EAAE,CAAC;IACtC,wBAAwB,EAAE,aAAa,EAAE,CAAC;CAC3C,CAAC;AAEF,MAAM,MAAM,cAAc,GAAG;IAC3B,QAAQ,EAAE,MAAM,CAAC;IACjB,IAAI,EAAE,MAAM,CAAC;IACb,OAAO,CAAC,EAAE,OAAO,CAAC;IAClB,IAAI,CAAC,EAAE,MAAM,CAAC;IACd,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,QAAQ,CAAC,EAAE,MAAM,CAAC;IAClB,gBAAgB,CAAC,EAAE,MAAM,CAAC;CAC3B,CAAC"}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@anselmdk/feature-spec-md",
|
|
3
|
-
"version": "0.6.1",
|
|
3
|
+
"version": "0.6.2-rc.1",
|
|
4
4
|
"description": "Markdown specs for AI-assisted, testable spec driven development across model, feature, stack, and design documents.",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"repository": {
|
|
@@ -46,7 +46,7 @@
|
|
|
46
46
|
"spec:report": "tsx src/cli.ts report",
|
|
47
47
|
"report:mock": "tsx src/mockReports.ts",
|
|
48
48
|
"format": "prettier --write .",
|
|
49
|
-
"check:example": "tsx src/cli.ts check --specs examples/**/*.feature.md --require-scenario-coverage=false",
|
|
49
|
+
"check:example": "tsx src/cli.ts check --specs examples/**/*.feature.md --tests \"\" --require-scenario-coverage=false --require-rule-coverage=false --require-model-coverage=false",
|
|
50
50
|
"report:example": "tsx src/cli.ts report --specs examples/**/*.feature.md --tests tests/**/*.test.ts --out test-results/feature-spec-report/index.html",
|
|
51
51
|
"test": "npm run test:unit && npm run test:playwright",
|
|
52
52
|
"test:unit": "tsx --test tests/**/*.test.ts",
|
|
@@ -1,18 +1,36 @@
|
|
|
1
1
|
{
|
|
2
|
-
"
|
|
2
|
+
"evidence": [
|
|
3
3
|
{
|
|
4
4
|
"specPath": "src/mocks/current/specs/ticket-inbox.feature.md",
|
|
5
5
|
"line": 27,
|
|
6
|
+
"changed": true,
|
|
6
7
|
"path": "screenshots/SUPPORT-INBOX-S001-line-27-current.svg",
|
|
7
8
|
"title": "Inbox with priority badges",
|
|
8
9
|
"testPath": "src/mocks/current/tests/supportDesk.spec.ts"
|
|
9
10
|
},
|
|
11
|
+
{
|
|
12
|
+
"specPath": "src/mocks/current/specs/ticket-inbox.feature.md",
|
|
13
|
+
"line": 28,
|
|
14
|
+
"changed": false,
|
|
15
|
+
"title": "Inbox remains visually unchanged after selecting the first ticket",
|
|
16
|
+
"testPath": "src/mocks/current/tests/supportDesk.spec.ts",
|
|
17
|
+
"comparedWithLine": 27
|
|
18
|
+
},
|
|
10
19
|
{
|
|
11
20
|
"specPath": "src/mocks/current/specs/ticket-reply.feature.md",
|
|
12
21
|
"line": 27,
|
|
22
|
+
"changed": true,
|
|
13
23
|
"path": "screenshots/SUPPORT-REPLY-S001-line-27-current.svg",
|
|
14
24
|
"title": "Reply composer with suggested answer",
|
|
15
25
|
"testPath": "src/mocks/current/tests/supportDesk.spec.ts"
|
|
26
|
+
},
|
|
27
|
+
{
|
|
28
|
+
"specPath": "src/mocks/current/specs/ticket-reply.feature.md",
|
|
29
|
+
"line": 28,
|
|
30
|
+
"changed": false,
|
|
31
|
+
"title": "Reply composer stays visually unchanged while text is reviewed",
|
|
32
|
+
"testPath": "src/mocks/current/tests/supportDesk.spec.ts",
|
|
33
|
+
"comparedWithLine": 27
|
|
16
34
|
}
|
|
17
35
|
]
|
|
18
36
|
}
|
|
@@ -1,11 +1,20 @@
|
|
|
1
1
|
{
|
|
2
|
-
"
|
|
2
|
+
"evidence": [
|
|
3
3
|
{
|
|
4
4
|
"specPath": "src/mocks/previous/specs/ticket-inbox.feature.md",
|
|
5
5
|
"line": 27,
|
|
6
|
+
"changed": true,
|
|
6
7
|
"path": "screenshots/SUPPORT-INBOX-S001-line-27-previous.svg",
|
|
7
8
|
"title": "Inbox before priority badges",
|
|
8
9
|
"testPath": "src/mocks/previous/tests/supportDesk.spec.ts"
|
|
10
|
+
},
|
|
11
|
+
{
|
|
12
|
+
"specPath": "src/mocks/previous/specs/ticket-inbox.feature.md",
|
|
13
|
+
"line": 28,
|
|
14
|
+
"changed": false,
|
|
15
|
+
"title": "Inbox remains visually unchanged after selecting the first ticket",
|
|
16
|
+
"testPath": "src/mocks/previous/tests/supportDesk.spec.ts",
|
|
17
|
+
"comparedWithLine": 27
|
|
9
18
|
}
|
|
10
19
|
]
|
|
11
20
|
}
|