@agent-teams/feature-module-standard 0.2.4 → 0.3.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.
Files changed (72) hide show
  1. package/CHANGELOG.md +23 -0
  2. package/README.md +29 -20
  3. package/dist/features/conformance-fixtures/testing/conformance-case-inputs.d.ts +53 -0
  4. package/dist/features/conformance-fixtures/testing/conformance-case-inputs.d.ts.map +1 -0
  5. package/dist/features/conformance-fixtures/testing/conformance-case-inputs.js +70 -0
  6. package/dist/features/conformance-fixtures/testing/conformance-case-inputs.js.map +1 -0
  7. package/dist/features/conformance-fixtures/testing/conformance-cases-later.d.ts +3 -0
  8. package/dist/features/conformance-fixtures/testing/conformance-cases-later.d.ts.map +1 -0
  9. package/dist/features/conformance-fixtures/testing/conformance-cases-later.js +170 -0
  10. package/dist/features/conformance-fixtures/testing/conformance-cases-later.js.map +1 -0
  11. package/dist/features/conformance-fixtures/testing/conformance-cases.d.ts +3 -16
  12. package/dist/features/conformance-fixtures/testing/conformance-cases.d.ts.map +1 -1
  13. package/dist/features/conformance-fixtures/testing/conformance-cases.js +102 -215
  14. package/dist/features/conformance-fixtures/testing/conformance-cases.js.map +1 -1
  15. package/dist/features/conformance-fixtures/testing/example-sources.d.ts.map +1 -1
  16. package/dist/features/conformance-fixtures/testing/example-sources.js +12 -8
  17. package/dist/features/conformance-fixtures/testing/example-sources.js.map +1 -1
  18. package/dist/features/conformance-fixtures/testing/example-tree.d.ts +8 -8
  19. package/dist/features/conformance-fixtures/testing/example-tree.d.ts.map +1 -1
  20. package/dist/features/conformance-fixtures/testing/example-tree.js +39 -27
  21. package/dist/features/conformance-fixtures/testing/example-tree.js.map +1 -1
  22. package/dist/features/feature-dependencies/application/check-feature-dependencies.d.ts +2 -2
  23. package/dist/features/feature-dependencies/application/check-feature-dependencies.d.ts.map +1 -1
  24. package/dist/features/feature-dependencies/application/check-feature-dependencies.js +88 -56
  25. package/dist/features/feature-dependencies/application/check-feature-dependencies.js.map +1 -1
  26. package/dist/features/feature-dependencies/application/feature-graphs.d.ts.map +1 -1
  27. package/dist/features/feature-dependencies/application/feature-graphs.js +1 -1
  28. package/dist/features/feature-dependencies/application/feature-graphs.js.map +1 -1
  29. package/dist/features/feature-dependencies/application/layer-direction.d.ts +2 -2
  30. package/dist/features/feature-dependencies/application/layer-direction.d.ts.map +1 -1
  31. package/dist/features/feature-dependencies/application/layer-direction.js +17 -11
  32. package/dist/features/feature-dependencies/application/layer-direction.js.map +1 -1
  33. package/dist/features/feature-layout/application/analyze-feature-tree.d.ts +1 -1
  34. package/dist/features/feature-layout/application/analyze-feature-tree.d.ts.map +1 -1
  35. package/dist/features/feature-layout/application/analyze-feature-tree.js +62 -28
  36. package/dist/features/feature-layout/application/analyze-feature-tree.js.map +1 -1
  37. package/dist/features/feature-layout/application/find-overlapping-roots.d.ts.map +1 -1
  38. package/dist/features/feature-layout/application/find-overlapping-roots.js +3 -2
  39. package/dist/features/feature-layout/application/find-overlapping-roots.js.map +1 -1
  40. package/dist/features/feature-layout/application/infer-directory-layout.d.ts +2 -2
  41. package/dist/features/feature-layout/application/infer-directory-layout.d.ts.map +1 -1
  42. package/dist/features/feature-layout/application/infer-directory-layout.js +3 -4
  43. package/dist/features/feature-layout/application/infer-directory-layout.js.map +1 -1
  44. package/dist/features/feature-model/domain/model.d.ts +10 -10
  45. package/dist/features/feature-model/domain/model.d.ts.map +1 -1
  46. package/dist/features/feature-model/domain/model.js +39 -13
  47. package/dist/features/feature-model/domain/model.js.map +1 -1
  48. package/dist/features/module-check/application/check-feature-module.d.ts +1 -1
  49. package/dist/features/module-check/application/check-feature-module.d.ts.map +1 -1
  50. package/dist/features/module-check/application/check-feature-module.js +24 -12
  51. package/dist/features/module-check/application/check-feature-module.js.map +1 -1
  52. package/dist/features/node-runner/application/run-feature-module-check.d.ts +4 -4
  53. package/dist/features/node-runner/application/run-feature-module-check.d.ts.map +1 -1
  54. package/dist/features/node-runner/application/run-feature-module-check.js +58 -24
  55. package/dist/features/node-runner/application/run-feature-module-check.js.map +1 -1
  56. package/dist/features/node-runner/composition/check-feature-module-on-disk.d.ts +1 -1
  57. package/dist/features/node-runner/composition/check-feature-module-on-disk.d.ts.map +1 -1
  58. package/dist/features/node-runner/composition/check-feature-module-on-disk.js +12 -5
  59. package/dist/features/node-runner/composition/check-feature-module-on-disk.js.map +1 -1
  60. package/dist/fixtures.d.ts +4 -4
  61. package/dist/fixtures.d.ts.map +1 -1
  62. package/dist/fixtures.js +3 -3
  63. package/dist/fixtures.js.map +1 -1
  64. package/dist/index.d.ts +12 -12
  65. package/dist/index.d.ts.map +1 -1
  66. package/dist/index.js +7 -7
  67. package/dist/index.js.map +1 -1
  68. package/dist/node.d.ts +3 -3
  69. package/dist/node.d.ts.map +1 -1
  70. package/dist/node.js +2 -2
  71. package/dist/node.js.map +1 -1
  72. package/package.json +3 -3
package/CHANGELOG.md CHANGED
@@ -1,5 +1,28 @@
1
1
  # Changelog
2
2
 
3
+ ## 0.3.1
4
+
5
+ ### Patch Changes
6
+
7
+ - [#455](https://github.com/agent-teams-ai/engineering-foundation/pull/455) [`3bee016`](https://github.com/agent-teams-ai/engineering-foundation/commit/3bee0168797580b931dd7e355d0fb8e0ed5691de) Thanks [@777genius](https://github.com/777genius)! - Use the public asynchronous native compiler SDK for signature proofs, preserving the existing syntax oracle while awaiting sequential comparisons and cleanup. Recheck cancellation before approval reads, baseline promotion and admission effects.
8
+
9
+ Release FMS with its updated exact Foundation development dependency so each published version retains immutable packed bytes.
10
+
11
+ ## 0.3.0
12
+
13
+ ### Minor Changes
14
+
15
+ - [#443](https://github.com/agent-teams-ai/engineering-foundation/pull/443) [`17520f7`](https://github.com/agent-teams-ai/engineering-foundation/commit/17520f7d84d364f5bb40195785c2b7a9269663a0) Thanks [@777genius](https://github.com/777genius)! - Admit Foundation `^3.0.0` for the optional Node runner peer while preserving
16
+ the `^1.8.0` minimum and `^2.0.0` window. Foundation 3 relocates technical
17
+ presets and evolves quality coverage; the runner continues to use only the
18
+ public source-graph observation and ratchet budget contracts. Keep the pure
19
+ entries dependency-free and retain the exact current-workspace development link.
20
+
21
+ Ship this compatible peer expansion as a new 0.x minor before migrating a
22
+ consumer to Foundation 3. Follow the companion migration and final packed
23
+ installed-consumer qualification in
24
+ `docs/development/feature-module-standard-foundation-3-migration.md`.
25
+
3
26
  ## 0.2.4
4
27
 
5
28
  ### Patch Changes
package/README.md CHANGED
@@ -40,18 +40,18 @@ so a profile can compare it with the digest it pins. Applicability follows decla
40
40
  sub-feature exists only where `featureRoots` declares it, so in any other module
41
41
  a `features` directory inside a feature keeps its v1 meaning.
42
42
 
43
- | Rules | Diagnostic codes |
44
- | --- | --- |
45
- | Tree: feature roots at `<features root>/<name>` and `<parent>/features/<name>`, one container name, only role directories, the container and mapped files below a feature root | `feature-root-placement`, `feature-duplicate`, `feature-undeclared`, `container-file`, `container-empty`, `entry-unmapped` |
46
- | Test ownership: a test belongs to the deepest feature, sub-feature tests live in the mirrored test root, and a test uses another visible feature only through public, internal API and testing surfaces | `test-unowned`, `test-misplaced` (warnings: the standard says SHOULD), `not-visible`, `deep-import` |
47
- | Visibility and curated surfaces: a sub-feature is visible to its parent and the parent's descendants; no deep imports | `not-visible`, `deep-import`, `surface-unowned` |
48
- | Layer direction (v1): domain and application never import contracts; adapters reach siblings through the application core | `layer-direction` |
49
- | Composition contracts (module-level composition is named by `moduleComposition`): they are composition code, only composition code depends on them, visible features only | `composition-contract-misplaced`, `composition-contract-layer`, `not-visible` |
50
- | Assembly: only a parent's composition wires its direct sub-feature, and it wires every one that exposes a composition surface | `assembly-misplaced`, `assembly-missing` |
51
- | Republication: declared, from a direct sub-feature, one level at a time | `republication-undeclared`, `republication-skips-level`, `republication-invalid`, `republication-mismatch`, `republication-not-sub-feature` |
52
- | Declared use edges, when the consumer has a profile | `use-undeclared`, `use-edge-invalid` |
53
- | Cycles: downward and lateral use edges, runtime and type-only alike; load-time cycles between files of different features | `feature-cycle`, `load-cycle` |
54
- | Growth: depth warning and per-feature metrics (files, tests, sub-features, consumer file groups) | `depth-warning` |
43
+ | Rules | Diagnostic codes |
44
+ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------- |
45
+ | Tree: feature roots at `<features root>/<name>` and `<parent>/features/<name>`, one container name, only role directories, the container and mapped files below a feature root | `feature-root-placement`, `feature-duplicate`, `feature-undeclared`, `container-file`, `container-empty`, `entry-unmapped` |
46
+ | Test ownership: a test belongs to the deepest feature, sub-feature tests live in the mirrored test root, and a test uses another visible feature only through public, internal API and testing surfaces | `test-unowned`, `test-misplaced` (warnings: the standard says SHOULD), `not-visible`, `deep-import` |
47
+ | Visibility and curated surfaces: a sub-feature is visible to its parent and the parent's descendants; no deep imports | `not-visible`, `deep-import`, `surface-unowned` |
48
+ | Layer direction (v1): domain and application never import contracts; adapters reach siblings through the application core | `layer-direction` |
49
+ | Composition contracts (module-level composition is named by `moduleComposition`): they are composition code, only composition code depends on them, visible features only | `composition-contract-misplaced`, `composition-contract-layer`, `not-visible` |
50
+ | Assembly: only a parent's composition wires its direct sub-feature, and it wires every one that exposes a composition surface | `assembly-misplaced`, `assembly-missing` |
51
+ | Republication: declared, from a direct sub-feature, one level at a time | `republication-undeclared`, `republication-skips-level`, `republication-invalid`, `republication-mismatch`, `republication-not-sub-feature` |
52
+ | Declared use edges, when the consumer has a profile | `use-undeclared`, `use-edge-invalid` |
53
+ | Cycles: downward and lateral use edges, runtime and type-only alike; load-time cycles between files of different features | `feature-cycle`, `load-cycle` |
54
+ | Growth: depth warning and per-feature metrics (files, tests, sub-features, consumer file groups) | `depth-warning` |
55
55
 
56
56
  Every code is in `ERROR_CODES` or `WARNING_CODES`; a MUST of the standard is an error and a SHOULD a warning
57
57
  that does not fail the module. Diagnostics are sorted and stable. `invalid-path` reports any input path that is
@@ -77,20 +77,29 @@ conformance test, run the same data.
77
77
 
78
78
  `@agent-teams/feature-module-standard/node` checks a module on disk. It reads the declared roots through
79
79
  `@agent-teams/engineering-foundation/source-graph`, runs the kernel and compares the per-feature metrics with
80
- growth budgets from `@agent-teams/engineering-foundation/ratchet` (warnings only). Engineering Foundation `^1.8.0 || ^2.0.0` is an
80
+ growth budgets from `@agent-teams/engineering-foundation/ratchet` (warnings only). Engineering Foundation `^1.8.0 || ^2.0.0 || ^3.0.0` is an
81
81
  optional peer dependency: users of `.` and `./fixtures` do not need it.
82
+ The Foundation 3 window is prepared for the companion release. See the
83
+ [migration and qualification record](../../docs/development/feature-module-standard-foundation-3-migration.md)
84
+ for the unchanged runner contracts and the required final installed-artifact gate.
82
85
 
83
86
  ```ts
84
- import { checkFeatureModuleOnDisk, formatNodeReport } from '@agent-teams/feature-module-standard/node';
87
+ import {
88
+ checkFeatureModuleOnDisk,
89
+ formatNodeReport,
90
+ } from "@agent-teams/feature-module-standard/node";
85
91
 
86
92
  const report = await checkFeatureModuleOnDisk({
87
93
  consumerRoot: process.cwd(),
88
- sourceRoots: ['src'],
89
- testRoots: ['tests/features'],
90
- testFeaturesRoot: 'tests/features',
91
- structure: { featuresRoot: 'src/features', roleDirectories: { domain: 'domain', application: 'application' } },
92
- surfaces: { public: ['src/features/orders/contracts/public.ts'] },
93
- budgets: [{ metric: 'sourceFiles', max: 40 }],
94
+ sourceRoots: ["src"],
95
+ testRoots: ["tests/features"],
96
+ testFeaturesRoot: "tests/features",
97
+ structure: {
98
+ featuresRoot: "src/features",
99
+ roleDirectories: { domain: "domain", application: "application" },
100
+ },
101
+ surfaces: { public: ["src/features/orders/contracts/public.ts"] },
102
+ budgets: [{ metric: "sourceFiles", max: 40 }],
94
103
  });
95
104
  process.stdout.write(formatNodeReport(report));
96
105
  ```
@@ -0,0 +1,53 @@
1
+ import { inferDirectoryLayout } from "../../feature-layout/application/infer-directory-layout.js";
2
+ import { ERROR_CODES, WARNING_CODES } from "../../feature-model/domain/model.js";
3
+ import type { DiagnosticCode, FeatureModuleInput, ImportMode, ImportRecord, LayerRole, Republication, RepublishedSurface, RoleRoot, SurfaceMap, UseEdge } from "../../feature-model/domain/model.js";
4
+ import { FEATURES_ROOT, MODULE_COMPOSITION, TEST_FEATURES_ROOT, exampleModule, exampleRoots, fileOf, importOf, roleDirectories } from "./example-tree.js";
5
+ export { ERROR_CODES, WARNING_CODES };
6
+ export type { DiagnosticCode, FeatureModuleInput, ImportMode, ImportRecord, LayerRole, Republication, RepublishedSurface, RoleRoot, SurfaceMap, UseEdge, };
7
+ /** One fixture: a complete module description and the exact diagnostic codes the kernel must report for it. */
8
+ export type ConformanceCase = Readonly<{
9
+ id: string;
10
+ /** Where Feature Module Standard v1.1 states the rule: a section name, with the example table or bullet it uses. */
11
+ source: string;
12
+ description: string;
13
+ input: FeatureModuleInput;
14
+ /** Sorted diagnostic codes, duplicates kept; empty when the module conforms. */
15
+ expect: readonly DiagnosticCode[];
16
+ /** False only when an error code is among `expect`; a warning does not fail. */
17
+ ok: boolean;
18
+ }>;
19
+ type Change = Readonly<{
20
+ files?: readonly string[];
21
+ imports?: readonly ImportRecord[];
22
+ drop?: (record: ImportRecord) => boolean;
23
+ input?: Partial<FeatureModuleInput>;
24
+ }>;
25
+ export declare const define: (id: string, source: string, description: string, expect: readonly DiagnosticCode[], change?: Change) => ConformanceCase;
26
+ export declare const f: typeof fileOf;
27
+ export declare const ex = "Sub-features: Examples";
28
+ export declare const type = "type-only";
29
+ export declare const orders = "src/features/orders";
30
+ export declare const odCoupons = "orders/discounts/coupons";
31
+ export declare const billingApi = "src/features/billing/application/internal-api.ts";
32
+ export declare const testRoot = "tests/features/orders";
33
+ export declare const discountsTest = "tests/features/orders/features/discounts/discount.test.ts";
34
+ export declare const billingKit = "src/features/billing/application/kit.ts";
35
+ export declare const reportsApi = "src/capabilities/reports/api.ts";
36
+ export declare const reportsAdapter = "src/capabilities/reports/adapters/store.ts";
37
+ export declare const billingApi2 = "src/features/billing/api.ts";
38
+ export declare const v1Files: string[];
39
+ export declare const profileCase: (id: string, expect: readonly DiagnosticCode[], imports: readonly ImportRecord[], description: string) => ConformanceCase;
40
+ export declare const withApi: {
41
+ files: string[];
42
+ input: {
43
+ surfaces: {
44
+ public?: readonly string[];
45
+ compositionContract?: readonly string[];
46
+ compositionSurface?: readonly string[];
47
+ testing?: readonly string[];
48
+ internalApi: string[];
49
+ };
50
+ };
51
+ };
52
+ export { FEATURES_ROOT, MODULE_COMPOSITION, TEST_FEATURES_ROOT, exampleModule, exampleRoots, importOf, roleDirectories, inferDirectoryLayout, };
53
+ //# sourceMappingURL=conformance-case-inputs.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"conformance-case-inputs.d.ts","sourceRoot":"","sources":["../../../../src/features/conformance-fixtures/testing/conformance-case-inputs.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,oBAAoB,EAAE,MAAM,4DAA4D,CAAC;AAClG,OAAO,EAAE,WAAW,EAAE,aAAa,EAAE,MAAM,qCAAqC,CAAC;AACjF,OAAO,KAAK,EACV,cAAc,EACd,kBAAkB,EAClB,UAAU,EACV,YAAY,EACZ,SAAS,EACT,aAAa,EACb,kBAAkB,EAClB,QAAQ,EACR,UAAU,EACV,OAAO,EACR,MAAM,qCAAqC,CAAC;AAC7C,OAAO,EACL,aAAa,EACb,kBAAkB,EAClB,kBAAkB,EAClB,aAAa,EACb,YAAY,EACZ,MAAM,EACN,QAAQ,EACR,eAAe,EAChB,MAAM,mBAAmB,CAAC;AAE3B,OAAO,EAAE,WAAW,EAAE,aAAa,EAAE,CAAC;AAEtC,YAAY,EACV,cAAc,EACd,kBAAkB,EAClB,UAAU,EACV,YAAY,EACZ,SAAS,EACT,aAAa,EACb,kBAAkB,EAClB,QAAQ,EACR,UAAU,EACV,OAAO,GACR,CAAC;AAEF,+GAA+G;AAC/G,MAAM,MAAM,eAAe,GAAG,QAAQ,CAAC;IACrC,EAAE,EAAE,MAAM,CAAC;IACX,oHAAoH;IACpH,MAAM,EAAE,MAAM,CAAC;IACf,WAAW,EAAE,MAAM,CAAC;IACpB,K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B,kBAAkB,EAClB,aAAa,EACb,YAAY,EACZ,QAAQ,EACR,eAAe,EACf,oBAAoB,GACrB,CAAC"}
@@ -0,0 +1,70 @@
1
+ import { inferDirectoryLayout } from "../../feature-layout/application/infer-directory-layout.js";
2
+ import { ERROR_CODES, WARNING_CODES } from "../../feature-model/domain/model.js";
3
+ import { FEATURES_ROOT, MODULE_COMPOSITION, TEST_FEATURES_ROOT, exampleModule, exampleRoots, fileOf, importOf, roleDirectories, } from "./example-tree.js";
4
+ export { ERROR_CODES, WARNING_CODES };
5
+ const warnings = new Set(WARNING_CODES);
6
+ export const define = (id, source, description, expect, change = {}) => {
7
+ const base = exampleModule();
8
+ const input = {
9
+ ...base,
10
+ ...change.input,
11
+ files: [...base.files, ...(change.files ?? [])],
12
+ imports: [
13
+ ...base.imports.filter((record) => !(change.drop?.(record) ?? false)),
14
+ ...(change.imports ?? []),
15
+ ],
16
+ };
17
+ return { id, source, description, input, expect, ok: expect.every((code) => warnings.has(code)) };
18
+ };
19
+ export const f = fileOf;
20
+ export const ex = "Sub-features: Examples";
21
+ export const type = "type-only";
22
+ export const orders = `${FEATURES_ROOT}/orders`;
23
+ export const odCoupons = "orders/discounts/coupons";
24
+ export const billingApi = `${FEATURES_ROOT}/billing/application/internal-api.ts`;
25
+ export const testRoot = `${TEST_FEATURES_ROOT}/orders`;
26
+ export const discountsTest = `${testRoot}/features/discounts/discount.test.ts`;
27
+ export const billingKit = `${FEATURES_ROOT}/billing/application/kit.ts`;
28
+ // A repository whose layout is not the default declares its roots and role mapping itself.
29
+ const reports = "src/capabilities/reports";
30
+ const billing2 = "src/features/billing";
31
+ export const reportsApi = `${reports}/api.ts`;
32
+ export const reportsAdapter = `${reports}/adapters/store.ts`;
33
+ export const billingApi2 = `${billing2}/api.ts`;
34
+ const files = [
35
+ reportsApi,
36
+ `${reports}/module.ts`,
37
+ reportsAdapter,
38
+ billingApi2,
39
+ `${billing2}/contracts.ts`,
40
+ ];
41
+ export const v1Files = [
42
+ `${FEATURES_ROOT}/legacy/domain/model.ts`,
43
+ `${FEATURES_ROOT}/legacy/features/helper.ts`,
44
+ ];
45
+ export const profileCase = (id, expect, imports, description) => ({
46
+ id,
47
+ source: "Abstract repository layout",
48
+ description,
49
+ expect,
50
+ ok: expect.length === 0,
51
+ input: {
52
+ files,
53
+ imports,
54
+ featureRoots: [reports, billing2],
55
+ roleRoots: [
56
+ { root: reportsApi, role: "application" },
57
+ { root: `${reports}/module.ts`, role: "composition" },
58
+ { root: `${reports}/adapters`, role: "adapters" },
59
+ { root: billingApi2, role: "application" },
60
+ { root: `${billing2}/contracts.ts`, role: "contracts" },
61
+ ],
62
+ surfaces: { public: [reportsApi, billingApi2] },
63
+ },
64
+ });
65
+ export const withApi = {
66
+ files: [billingApi],
67
+ input: { surfaces: { ...exampleModule().surfaces, internalApi: [billingApi] } },
68
+ };
69
+ export { FEATURES_ROOT, MODULE_COMPOSITION, TEST_FEATURES_ROOT, exampleModule, exampleRoots, importOf, roleDirectories, inferDirectoryLayout, };
70
+ //# sourceMappingURL=conformance-case-inputs.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"conformance-case-inputs.js","sourceRoot":"","sources":["../../../../src/features/conformance-fixtures/testing/conformance-case-inputs.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,oBAAoB,EAAE,MAAM,4DAA4D,CAAC;AAClG,OAAO,EAAE,WAAW,EAAE,aAAa,EAAE,MAAM,qCAAqC,CAAC;AAajF,OAAO,EACL,aAAa,EACb,kBAAkB,EAClB,kBAAkB,EAClB,aAAa,EACb,YAAY,EACZ,MAAM,EACN,QAAQ,EACR,eAAe,GAChB,MAAM,mBAAmB,CAAC;AAE3B,OAAO,EAAE,WAAW,EAAE,aAAa,EAAE,CAAC;AAmCtC,MAAM,QAAQ,GAAwB,IAAI,GAAG,CAAC,aAAa,CAAC,CAAC;AAC7D,MAAM,CAAC,MAAM,MAAM,GAAG,CACpB,EAAU,EACV,MAAc,EACd,WAAmB,EACnB,MAAi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AAC,EAAE;KAChD;CACF,CAAC,CAAC;AACH,MAAM,CAAC,MAAM,OAAO,GAAG;IACrB,KAAK,EAAE,CAAC,UAAU,CAAC;IACnB,KAAK,EAAE,EAAE,QAAQ,EAAE,EAAE,GAAG,aAAa,EAAE,CAAC,QAAQ,EAAE,WAAW,EAAE,CAAC,UAAU,CAAC,EAAE,EAAE;CAChF,CAAC;AAEF,OAAO,EACL,aAAa,EACb,kBAAkB,EAClB,kBAAkB,EAClB,aAAa,EACb,YAAY,EACZ,QAAQ,EACR,eAAe,EACf,oBAAoB,GACrB,CAAC"}
@@ -0,0 +1,3 @@
1
+ import type { ConformanceCase } from "./conformance-case-inputs.js";
2
+ export declare const laterConformanceCases: readonly ConformanceCase[];
3
+ //# sourceMappingURL=conformance-cases-later.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"conformance-cases-later.d.ts","sourceRoot":"","sources":["../../../../src/features/conformance-fixtures/testing/conformance-cases-later.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,eAAe,EAAE,MAAM,8BAA8B,CAAC;AA0BpE,eAAO,MAAM,qBAAqB,EAAE,SAAS,eAAe,EA4X3D,CAAC"}
@@ -0,0 +1,170 @@
1
+ import { define, f, ex, type, orders, odCoupons, billingApi, testRoot, discountsTest, billingKit, reportsApi, reportsAdapter, billingApi2, v1Files, profileCase, withApi, FEATURES_ROOT, MODULE_COMPOSITION, TEST_FEATURES_ROOT, exampleModule, importOf, roleDirectories, inferDirectoryLayout, } from "./conformance-case-inputs.js";
2
+ export const laterConformanceCases = [
3
+ define("application-uses-an-internal-api", "Aggregate and internal-feature ownership", "Application code uses the curated internal API of another feature.", [], { ...withApi, imports: [importOf(f("orders", "application"), billingApi)] }),
4
+ define("domain-cannot-use-an-application-internal-api", "Aggregate and internal-feature ownership", "Domain code uses only the domain internal API of another feature.", ["layer-direction"], { ...withApi, imports: [importOf(f("orders", "domain"), billingApi)] }),
5
+ define("adapters-reach-siblings-through-the-core", "Aggregate and internal-feature ownership", "An adapter does not import another feature directly.", ["layer-direction"], {
6
+ files: [`${FEATURES_ROOT}/billing/adapters/gateway.ts`],
7
+ imports: [importOf(`${FEATURES_ROOT}/billing/adapters/gateway.ts`, f("orders", "public"))],
8
+ }),
9
+ define("undeclared-use-edge", "Sub-features: Edges", "With a declared feature graph, an undeclared use edge is rejected.", ["use-undeclared"], {
10
+ imports: [importOf(f("orders", "composition"), f("orders/discounts", "public"))],
11
+ input: { useEdges: [] },
12
+ }),
13
+ define("declared-use-edge", "Sub-features: Edges", "A declared use edge is accepted.", [], {
14
+ imports: [importOf(f("orders", "composition"), f("orders/discounts", "public"))],
15
+ input: { useEdges: [{ from: "orders", to: "orders/discounts" }] },
16
+ }),
17
+ define("declared-graph-cycle", "Sub-features: Dependency graph and cycles", "A cycle in the declared graph is rejected before any import exists.", ["feature-cycle"], {
18
+ input: {
19
+ useEdges: [
20
+ { from: "orders/pricing", to: "orders/discounts" },
21
+ { from: "orders/discounts", to: "orders/pricing" },
22
+ ],
23
+ },
24
+ }),
25
+ define("surface-without-a-feature", "Sub-features: Visibility", "A surface file that belongs to no feature is rejected.", ["surface-unowned"], {
26
+ input: {
27
+ surfaces: {
28
+ ...exampleModule().surfaces,
29
+ public: [...(exampleModule().surfaces?.public ?? []), MODULE_COMPOSITION],
30
+ },
31
+ },
32
+ }),
33
+ define("depth-warning", ex, "A feature past the declared depth is a warning, not a failure.", ["depth-warning"], { input: { depthWarning: 2 } }),
34
+ define("composition-contract-outside-composition", "Composition contracts", "A composition contract is composition code of its feature.", ["composition-contract-misplaced"], {
35
+ files: [`${orders}/application/wiring.ts`],
36
+ input: {
37
+ surfaces: {
38
+ ...exampleModule().surfaces,
39
+ compositionContract: [
40
+ ...(exampleModule().surfaces?.compositionContract ?? []),
41
+ `${orders}/application/wiring.ts`,
42
+ ],
43
+ },
44
+ },
45
+ }),
46
+ define("republication-of-another-surface", "Growth guardrails 13", "A republication re-exports the same surface of its parent, not the other one.", ["republication-mismatch"], {
47
+ imports: [importOf(f("orders", "public"), f("orders/pricing", "contract"), "runtime", true)],
48
+ }),
49
+ define("test-uses-the-internals-of-its-own-feature", "Test ownership", "A test of a sub-feature uses its own domain.", [], {
50
+ input: { testFiles: [discountsTest] },
51
+ imports: [importOf(discountsTest, f("orders/discounts", "domain"))],
52
+ }),
53
+ define("test-of-the-parent-uses-a-sub-feature-domain", "Test ownership", "A test in the test root of orders may not use the internals of orders/discounts.", ["deep-import"], {
54
+ input: { testFiles: [`${testRoot}/orders.test.ts`] },
55
+ imports: [importOf(`${testRoot}/orders.test.ts`, f("orders/discounts", "domain"))],
56
+ }),
57
+ define("test-uses-a-visible-sibling-entrypoint", "Test ownership", "A test of a sub-feature uses the public entrypoint of a visible sibling.", [], {
58
+ input: { testFiles: [discountsTest] },
59
+ imports: [importOf(discountsTest, f("orders/pricing", "public"))],
60
+ }),
61
+ define("test-of-another-feature-cannot-see-a-sub-feature", "Test ownership", "A test of billing may not use a sub-feature of orders.", ["not-visible"], {
62
+ input: { testFiles: [`${TEST_FEATURES_ROOT}/billing/billing.test.ts`] },
63
+ imports: [
64
+ importOf(`${TEST_FEATURES_ROOT}/billing/billing.test.ts`, f("orders/pricing", "public")),
65
+ ],
66
+ }),
67
+ define("test-uses-a-testing-surface", "Test ownership", "Test code uses the testing surface of a visible feature.", [], {
68
+ files: [billingKit],
69
+ input: {
70
+ testFiles: [discountsTest],
71
+ surfaces: { ...exampleModule().surfaces, testing: [billingKit] },
72
+ },
73
+ imports: [importOf(discountsTest, billingKit)],
74
+ }),
75
+ define("cycle-through-a-deep-import", "Sub-features: Dependency graph and cycles", "A deep import is rejected and still closes a cycle.", ["deep-import", "feature-cycle"], {
76
+ imports: [
77
+ importOf(f("orders/pricing", "composition"), f("orders/discounts", "domain")),
78
+ importOf(f("orders/discounts", "composition"), f("orders/pricing", "public")),
79
+ ],
80
+ }),
81
+ define("contracts-cannot-use-a-composition-contract", "Composition contracts", "Code of the contracts role never depends on a composition contract.", ["composition-contract-layer"], {
82
+ imports: [importOf(f("billing", "public"), f("orders", "contract"))],
83
+ }),
84
+ define("adapters-cannot-use-a-composition-contract", "Composition contracts", "Code of the adapters role never depends on a composition contract.", ["composition-contract-layer"], {
85
+ files: [`${FEATURES_ROOT}/billing/adapters/gateway.ts`],
86
+ imports: [importOf(`${FEATURES_ROOT}/billing/adapters/gateway.ts`, f("orders", "contract"))],
87
+ }),
88
+ define("module-code-outside-composition-cannot-use-a-composition-contract", "Composition contracts", "Only module-level composition may depend on a composition contract.", ["composition-contract-layer"], {
89
+ files: ["src/other.ts"],
90
+ imports: [importOf("src/other.ts", f("orders", "contract"))],
91
+ }),
92
+ define("module-code-outside-composition-cannot-wire-a-composition-surface", "Sub-features: Assembly", "Only module-level composition wires the composition surface of a top-level feature.", ["deep-import"], {
93
+ files: ["src/other.ts"],
94
+ imports: [importOf("src/other.ts", f("billing", "group"))],
95
+ }),
96
+ define("module-composition-uses-a-top-level-composition-contract", "Composition contracts", "Module composition depends on the composition contract of a top-level feature.", [], {
97
+ imports: [importOf(MODULE_COMPOSITION, f("orders", "contract"))],
98
+ }),
99
+ define("module-code-is-not-composition-unless-listed", "Composition contracts", "Without a listed module composition, module-level code may not depend on a composition contract or wire a composition surface.", ["composition-contract-layer", "deep-import", "deep-import"], {
100
+ input: { moduleComposition: [] },
101
+ imports: [importOf(MODULE_COMPOSITION, f("orders", "contract"))],
102
+ }),
103
+ {
104
+ id: "absent-module-composition-rejects",
105
+ source: "Composition contracts",
106
+ ok: false,
107
+ description: "Without any moduleComposition, module-level code is not composition.",
108
+ expect: ["composition-contract-layer", "deep-import", "deep-import"],
109
+ input: {
110
+ ...exampleModule(false),
111
+ imports: [...exampleModule().imports, importOf(MODULE_COMPOSITION, f("orders", "contract"))],
112
+ },
113
+ },
114
+ define("lateral-reexport-is-no-republication", "Growth guardrails 13", "A sibling cannot republish the contracts of another sibling.", ["republication-not-sub-feature"], {
115
+ imports: [
116
+ importOf(f("orders/pricing", "public"), f("orders/discounts", "public"), "runtime", true),
117
+ ],
118
+ }),
119
+ define("upward-reexport-is-no-republication", "Growth guardrails 13", "A sub-feature cannot republish the contracts of its parent.", ["republication-not-sub-feature"], {
120
+ imports: [importOf(f("orders/discounts", "public"), f("orders", "public"), "runtime", true)],
121
+ }),
122
+ define("leaking-republication-chain", "Growth guardrails 13", "A sibling re-export cannot be laundered through a declared republication.", ["republication-not-sub-feature"], {
123
+ imports: [
124
+ importOf(f("orders/pricing", "public"), f("orders/discounts", "public"), "runtime", true),
125
+ importOf(f("orders", "public"), f("orders/pricing", "public"), "runtime", true),
126
+ importOf(f("billing", "composition"), f("orders", "public")),
127
+ ],
128
+ input: { republications: [{ from: "orders", to: "orders/pricing", surface: "public" }] },
129
+ }),
130
+ define("colocated-test-uses-its-own-internals", "Test ownership", "A test beside its source belongs to the deepest feature and may use its internals.", [], {
131
+ input: { testFiles: [`${orders}/domain/model.test.ts`] },
132
+ imports: [importOf(`${orders}/domain/model.test.ts`, f("orders", "domain"))],
133
+ }),
134
+ define("colocated-test-uses-a-sub-feature-domain", "Test ownership", "A colocated test of a parent may not use the internals of its sub-feature.", ["deep-import"], {
135
+ input: { testFiles: [`${orders}/domain/model.test.ts`] },
136
+ imports: [importOf(`${orders}/domain/model.test.ts`, f("orders/discounts", "domain"))],
137
+ }),
138
+ define("application-cannot-wire-a-top-level-composition-surface", "Sub-features: Assembly", "Only composition code wires a composition surface.", ["deep-import"], {
139
+ imports: [importOf(f("billing", "application"), f("orders", "group"))],
140
+ }),
141
+ define("declared-use-edge-of-an-unknown-feature", "Sub-features: Edges", "A declared use edge names a feature that does not exist.", ["use-edge-invalid"], {
142
+ input: { useEdges: [{ from: "ghost", to: "orders" }] },
143
+ }),
144
+ define("declared-use-edge-to-an-invisible-feature", "Sub-features: Visibility", "A declared use edge cannot target a feature that is not visible.", ["not-visible"], {
145
+ input: { useEdges: [{ from: "billing", to: "orders/pricing" }] },
146
+ }),
147
+ define("type-only-import-does-not-wire", "Sub-features: Assembly", "A parent that only references the composition surface by type has not wired it.", ["assembly-missing"], {
148
+ drop: (record) => record.from === f("orders/discounts", "composition") && record.to === f(odCoupons, "group"),
149
+ imports: [importOf(f("orders/discounts", "composition"), f(odCoupons, "group"), type)],
150
+ }),
151
+ define("path-outside-the-repository", "Sub-features: Placement and layout", "A path that escapes the repository is reported and never trusted.", ["invalid-path"], { files: ["../outside.ts"] }),
152
+ {
153
+ id: "v1-features-directory-keeps-its-meaning",
154
+ source: "Sub-features: introduction",
155
+ ok: true,
156
+ expect: [],
157
+ description: "Without a declared sub-feature, a directory named features inside a feature keeps its v1 meaning.",
158
+ input: {
159
+ imports: [],
160
+ files: v1Files,
161
+ ...inferDirectoryLayout({ featuresRoot: FEATURES_ROOT, files: v1Files, roleDirectories }),
162
+ },
163
+ },
164
+ profileCase("profile-mapped-layout-conforms", [], [importOf(billingApi2, reportsApi)], "Roles mapped to files and to a directory with another name, in two feature roots, conform."),
165
+ profileCase("v1-reexport-is-an-ordinary-use", [], [{ ...importOf(billingApi2, reportsApi, "runtime", true) }], "Republication is a rule of modules with sub-features; in any other module a re-export is a use."),
166
+ profileCase("profile-mapped-adapter-direction", ["layer-direction"], [importOf(reportsAdapter, billingApi2)], "An adapter in a feature directory still reaches siblings only through its application core."),
167
+ profileCase("profile-mapped-deep-import", ["deep-import", "layer-direction"], [importOf(billingApi2, reportsAdapter)], "A file mapped to a role is not a public entrypoint unless the profile says so."),
168
+ profileCase("profile-mapped-cycle", ["feature-cycle", "load-cycle"], [importOf(billingApi2, reportsApi), importOf(reportsApi, billingApi2)], "Features under different roots form a cycle like any others."),
169
+ ];
170
+ //# sourceMappingURL=conformance-cases-later.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"conformance-cases-later.js","sourceRoot":"","sources":["../../../../src/features/conformance-fixtures/testing/conformance-cases-later.ts"],"names":[],"mappings":"AACA,OAAO,EACL,MAAM,EACN,CAAC,EACD,EAAE,EACF,IAAI,EACJ,MAAM,EACN,SAAS,EACT,UAA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D,iGAAiG,CAClG;IACD,WAAW,CACT,kCAAkC,EAClC,CAAC,iBAAiB,CAAC,EACnB,CAAC,QAAQ,CAAC,cAAc,EAAE,WAAW,CAAC,CAAC,EACvC,6FAA6F,CAC9F;IACD,WAAW,CACT,4BAA4B,EAC5B,CAAC,aAAa,EAAE,iBAAiB,CAAC,EAClC,CAAC,QAAQ,CAAC,WAAW,EAAE,cAAc,CAAC,CAAC,EACvC,gFAAgF,CACjF;IACD,WAAW,CACT,sBAAsB,EACtB,CAAC,eAAe,EAAE,YAAY,CAAC,EAC/B,CAAC,QAAQ,CAAC,WAAW,EAAE,UAAU,CAAC,EAAE,QAAQ,CAAC,UAAU,EAAE,WAAW,CAAC,CAAC,EACtE,8DAA8D,CAC/D;CACF,CAAC"}
@@ -1,18 +1,5 @@
1
- import { ERROR_CODES, WARNING_CODES } from '../../feature-model/domain/model.js';
2
- import type { DiagnosticCode, FeatureModuleInput, ImportMode, ImportRecord, LayerRole, Republication, RepublishedSurface, RoleRoot, SurfaceMap, UseEdge } from '../../feature-model/domain/model.js';
3
- export { ERROR_CODES, WARNING_CODES };
4
- export type { DiagnosticCode, FeatureModuleInput, ImportMode, ImportRecord, LayerRole, Republication, RepublishedSurface, RoleRoot, SurfaceMap, UseEdge };
5
- /** One fixture: a complete module description and the exact diagnostic codes the kernel must report for it. */
6
- export type ConformanceCase = Readonly<{
7
- id: string;
8
- /** Where Feature Module Standard v1.1 states the rule: a section name, with the example table or bullet it uses. */
9
- source: string;
10
- description: string;
11
- input: FeatureModuleInput;
12
- /** Sorted diagnostic codes, duplicates kept; empty when the module conforms. */
13
- expect: readonly DiagnosticCode[];
14
- /** False only when an error code is among `expect`; a warning does not fail. */
15
- ok: boolean;
16
- }>;
1
+ import type { ConformanceCase } from "./conformance-case-inputs.js";
2
+ export { ERROR_CODES, WARNING_CODES } from "./conformance-case-inputs.js";
3
+ export type { ConformanceCase, DiagnosticCode, FeatureModuleInput, ImportMode, ImportRecord, LayerRole, Republication, RepublishedSurface, RoleRoot, SurfaceMap, UseEdge, } from "./conformance-case-inputs.js";
17
4
  export declare const conformanceCases: readonly ConformanceCase[];
18
5
  //# sourceMappingURL=conformance-cases.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"conformance-cases.d.ts","sourceRoot":"","sources":["../../../../src/features/conformance-fixtures/testing/conformance-cases.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,WAAW,EAAE,aAAa,EAAE,MAAM,qCAAqC,CAAC;AACjF,OAAO,KAAK,EACV,cAAc,EAAE,kBAAkB,EAAE,UAAU,EAAE,YAAY,EAAE,SAAS,EAAE,aAAa,EAAE,kBAAkB,EAAE,QAAQ,EAAE,UAAU,EAAE,OAAO,EAC1I,MAAM,qCAAqC,CAAC;AAK7C,OAAO,EAAE,WAAW,EAAE,aAAa,EAAE,CAAC;AAEtC,YAAY,EAAE,cAAc,EAAE,kBAAkB,EAAE,UAAU,EAAE,YAAY,EAAE,SAAS,EAAE,aAAa,EAAE,kBAAkB,EAAE,QAAQ,EAAE,UAAU,EAAE,OAAO,EAAE,CAAC;AAE1J,+GAA+G;AAC/G,MAAM,MAAM,eAAe,GAAG,QAAQ,CAAC;IACrC,EAAE,EAAE,MAAM,CAAC;IACX,oHAAoH;IACpH,MAAM,EAAE,MAAM,CAAC;IACf,WAAW,EAAE,MAAM,CAAC;IACpB,KAAK,EAAE,kBAAkB,CAAC;IAC1B,gFAAgF;IAChF,MAAM,EAAE,SAAS,cAAc,EAAE,CAAC;IAClC,gFAAgF;IAChF,EAAE,EAAE,OAAO,CAAC;CACb,CAAC,CAAC;AAmDH,eAAO,MAAM,gBAAgB,EAAE,SAAS,eAAe,EA+LtD,CAAC"}
1
+ {"version":3,"file":"conformance-cases.d.ts","sourceRoot":"","sources":["../../../../src/features/conformance-fixtures/testing/conformance-cases.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,eAAe,EAAE,MAAM,8BAA8B,CAAC;AAcpE,OAAO,EAAE,WAAW,EAAE,aAAa,EAAE,MAAM,8BAA8B,CAAC;AAC1E,YAAY,EACV,eAAe,EACf,cAAc,EACd,kBAAkB,EAClB,UAAU,EACV,YAAY,EACZ,SAAS,EACT,aAAa,EACb,kBAAkB,EAClB,QAAQ,EACR,UAAU,EACV,OAAO,GACR,MAAM,8BAA8B,CAAC;AACtC,eAAO,MAAM,gBAAgB,EAAE,SAAS,eAAe,EA+UtD,CAAC"}