@memnexus-ai/mx-agent-cli 0.1.291 → 0.1.292
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/__tests__/config-fidelity-unreadable-fixture.d.ts +32 -0
- package/dist/__tests__/config-fidelity-unreadable-fixture.d.ts.map +1 -0
- package/dist/__tests__/config-fidelity-unreadable-fixture.js +37 -0
- package/dist/__tests__/config-fidelity-unreadable-fixture.js.map +1 -0
- package/dist/__tests__/config-fidelity.test.d.ts +16 -0
- package/dist/__tests__/config-fidelity.test.d.ts.map +1 -0
- package/dist/__tests__/config-fidelity.test.js +2546 -0
- package/dist/__tests__/config-fidelity.test.js.map +1 -0
- package/dist/__tests__/doctor-config-fidelity.test.d.ts +19 -0
- package/dist/__tests__/doctor-config-fidelity.test.d.ts.map +1 -0
- package/dist/__tests__/doctor-config-fidelity.test.js +324 -0
- package/dist/__tests__/doctor-config-fidelity.test.js.map +1 -0
- package/dist/commands/doctor.d.ts +46 -7
- package/dist/commands/doctor.d.ts.map +1 -1
- package/dist/commands/doctor.js +81 -9
- package/dist/commands/doctor.js.map +1 -1
- package/dist/commands/start.d.ts.map +1 -1
- package/dist/commands/start.js +56 -0
- package/dist/commands/start.js.map +1 -1
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +33 -9
- package/dist/index.js.map +1 -1
- package/dist/lib/config-fidelity.d.ts +500 -0
- package/dist/lib/config-fidelity.d.ts.map +1 -0
- package/dist/lib/config-fidelity.js +1713 -0
- package/dist/lib/config-fidelity.js.map +1 -0
- package/package.json +1 -1
|
@@ -0,0 +1,32 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Materializes the `unreadable/` config-fidelity fixture tree.
|
|
3
|
+
*
|
|
4
|
+
* WHY THIS EXISTS INSTEAD OF A COMMITTED FILE. The whole point of that tree is a
|
|
5
|
+
* deployed `.claude/settings.json` that does NOT parse — and a file that does not
|
|
6
|
+
* parse cannot be committed under a `*.json` name in this repository.
|
|
7
|
+
* `dev-tools/scripts/pr-baseline-check.sh` is the one required check that runs on
|
|
8
|
+
* EVERY pull request, and its second assertion is that every changed `*.json`
|
|
9
|
+
* file parses. It carries no fixture exemption, deliberately: a required check
|
|
10
|
+
* with a path-shaped escape hatch is a check with a hole in it, and the hole
|
|
11
|
+
* would be exactly the "deliberately malformed" shape someone would name a
|
|
12
|
+
* directory after. So the malformed bytes ship as `settings.json.invalid`, which
|
|
13
|
+
* is outside that glob, and this helper renames the file into place inside a
|
|
14
|
+
* TEMP COPY of the tree.
|
|
15
|
+
*
|
|
16
|
+
* The committed tree is never mutated — same rule as the other two pinned trees
|
|
17
|
+
* (see fixtures/config-fidelity/README.md). The caller owns `destRoot` and is
|
|
18
|
+
* responsible for removing it.
|
|
19
|
+
*
|
|
20
|
+
* If `settings.json.invalid` is ever missing the rename throws, so a fixture that
|
|
21
|
+
* has lost its malformed file fails loudly rather than degrading into "the
|
|
22
|
+
* deployed settings.json is simply absent" — a different state with a different
|
|
23
|
+
* verdict, which is precisely the distinction this fixture pins.
|
|
24
|
+
*/
|
|
25
|
+
/** The committed name of the malformed deployed settings file. */
|
|
26
|
+
export declare const UNPARSEABLE_SETTINGS_NAME = "settings.json.invalid";
|
|
27
|
+
export declare function materializeUnreadableFixture(destRoot: string): {
|
|
28
|
+
root: string;
|
|
29
|
+
source: string;
|
|
30
|
+
worktree: string;
|
|
31
|
+
};
|
|
32
|
+
//# sourceMappingURL=config-fidelity-unreadable-fixture.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"config-fidelity-unreadable-fixture.d.ts","sourceRoot":"","sources":["../../src/__tests__/config-fidelity-unreadable-fixture.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;GAuBG;AAQH,kEAAkE;AAClE,eAAO,MAAM,yBAAyB,0BAA0B,CAAC;AAEjE,wBAAgB,4BAA4B,CAAC,QAAQ,EAAE,MAAM,GAAG;IAC9D,IAAI,EAAE,MAAM,CAAC;IACb,MAAM,EAAE,MAAM,CAAC;IACf,QAAQ,EAAE,MAAM,CAAC;CAClB,CAKA"}
|
|
@@ -0,0 +1,37 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Materializes the `unreadable/` config-fidelity fixture tree.
|
|
3
|
+
*
|
|
4
|
+
* WHY THIS EXISTS INSTEAD OF A COMMITTED FILE. The whole point of that tree is a
|
|
5
|
+
* deployed `.claude/settings.json` that does NOT parse — and a file that does not
|
|
6
|
+
* parse cannot be committed under a `*.json` name in this repository.
|
|
7
|
+
* `dev-tools/scripts/pr-baseline-check.sh` is the one required check that runs on
|
|
8
|
+
* EVERY pull request, and its second assertion is that every changed `*.json`
|
|
9
|
+
* file parses. It carries no fixture exemption, deliberately: a required check
|
|
10
|
+
* with a path-shaped escape hatch is a check with a hole in it, and the hole
|
|
11
|
+
* would be exactly the "deliberately malformed" shape someone would name a
|
|
12
|
+
* directory after. So the malformed bytes ship as `settings.json.invalid`, which
|
|
13
|
+
* is outside that glob, and this helper renames the file into place inside a
|
|
14
|
+
* TEMP COPY of the tree.
|
|
15
|
+
*
|
|
16
|
+
* The committed tree is never mutated — same rule as the other two pinned trees
|
|
17
|
+
* (see fixtures/config-fidelity/README.md). The caller owns `destRoot` and is
|
|
18
|
+
* responsible for removing it.
|
|
19
|
+
*
|
|
20
|
+
* If `settings.json.invalid` is ever missing the rename throws, so a fixture that
|
|
21
|
+
* has lost its malformed file fails loudly rather than degrading into "the
|
|
22
|
+
* deployed settings.json is simply absent" — a different state with a different
|
|
23
|
+
* verdict, which is precisely the distinction this fixture pins.
|
|
24
|
+
*/
|
|
25
|
+
import { cpSync, renameSync } from 'fs';
|
|
26
|
+
import { dirname, join } from 'path';
|
|
27
|
+
import { fileURLToPath } from 'url';
|
|
28
|
+
const FIXTURES = join(dirname(fileURLToPath(import.meta.url)), 'fixtures', 'config-fidelity');
|
|
29
|
+
/** The committed name of the malformed deployed settings file. */
|
|
30
|
+
export const UNPARSEABLE_SETTINGS_NAME = 'settings.json.invalid';
|
|
31
|
+
export function materializeUnreadableFixture(destRoot) {
|
|
32
|
+
cpSync(join(FIXTURES, 'unreadable'), destRoot, { recursive: true });
|
|
33
|
+
const deployedDir = join(destRoot, 'worktree', '.claude');
|
|
34
|
+
renameSync(join(deployedDir, UNPARSEABLE_SETTINGS_NAME), join(deployedDir, 'settings.json'));
|
|
35
|
+
return { root: destRoot, source: join(destRoot, 'source'), worktree: join(destRoot, 'worktree') };
|
|
36
|
+
}
|
|
37
|
+
//# sourceMappingURL=config-fidelity-unreadable-fixture.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"config-fidelity-unreadable-fixture.js","sourceRoot":"","sources":["../../src/__tests__/config-fidelity-unreadable-fixture.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;GAuBG;AAEH,OAAO,EAAE,MAAM,EAAE,UAAU,EAAE,MAAM,IAAI,CAAC;AACxC,OAAO,EAAE,OAAO,EAAE,IAAI,EAAE,MAAM,MAAM,CAAC;AACrC,OAAO,EAAE,aAAa,EAAE,MAAM,KAAK,CAAC;AAEpC,MAAM,QAAQ,GAAG,IAAI,CAAC,OAAO,CAAC,aAAa,CAAC,MAAM,CAAC,IAAI,CAAC,GAAG,CAAC,CAAC,EAAE,UAAU,EAAE,iBAAiB,CAAC,CAAC;AAE9F,kEAAkE;AAClE,MAAM,CAAC,MAAM,yBAAyB,GAAG,uBAAuB,CAAC;AAEjE,MAAM,UAAU,4BAA4B,CAAC,QAAgB;IAK3D,MAAM,CAAC,IAAI,CAAC,QAAQ,EAAE,YAAY,CAAC,EAAE,QAAQ,EAAE,EAAE,SAAS,EAAE,IAAI,EAAE,CAAC,CAAC;IACpE,MAAM,WAAW,GAAG,IAAI,CAAC,QAAQ,EAAE,UAAU,EAAE,SAAS,CAAC,CAAC;IAC1D,UAAU,CAAC,IAAI,CAAC,WAAW,EAAE,yBAAyB,CAAC,EAAE,IAAI,CAAC,WAAW,EAAE,eAAe,CAAC,CAAC,CAAC;IAC7F,OAAO,EAAE,IAAI,EAAE,QAAQ,EAAE,MAAM,EAAE,IAAI,CAAC,QAAQ,EAAE,QAAQ,CAAC,EAAE,QAAQ,EAAE,IAAI,CAAC,QAAQ,EAAE,UAAU,CAAC,EAAE,CAAC;AACpG,CAAC"}
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Tests for the deployed-vs-source config fidelity assertion (config-fidelity.ts,
|
|
3
|
+
* A2 of the framework extraction, #5412).
|
|
4
|
+
*
|
|
5
|
+
* Real filesystem throughout, no mocks — the thing under test is a comparison of
|
|
6
|
+
* bytes on disk, and mocking the filesystem would test the mock. Three PINNED
|
|
7
|
+
* fixture trees live under fixtures/config-fidelity/ (see the README there);
|
|
8
|
+
* cases that need a mutated tree copy `clean/` into a temp dir and edit the copy.
|
|
9
|
+
*
|
|
10
|
+
* BOTH DIRECTIONS ARE MANDATORY. A suite that only proves the check goes red
|
|
11
|
+
* cannot distinguish a working gate from one that blocks everything, so every
|
|
12
|
+
* red case here has a green counterpart that differs by exactly the property
|
|
13
|
+
* being tested.
|
|
14
|
+
*/
|
|
15
|
+
export {};
|
|
16
|
+
//# sourceMappingURL=config-fidelity.test.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"config-fidelity.test.d.ts","sourceRoot":"","sources":["../../src/__tests__/config-fidelity.test.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;GAaG"}
|