agentic-workflow-manager 9.0.0 → 9.0.2
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.
|
@@ -19,8 +19,15 @@ const registryRemote = process.env.AWM_PUBLISHED_REGISTRY_REMOTE ?? 'https://git
|
|
|
19
19
|
// fail at the provenance assertion rather than silently describe.skip.
|
|
20
20
|
const enabled = Boolean(cliVersion && registryTag);
|
|
21
21
|
const acceptance = enabled ? describe : describe.skip;
|
|
22
|
+
// Windows resolves `npm` to `npm.cmd`; spawnSync can't execute a .cmd file
|
|
23
|
+
// directly without a shell — it fails to spawn (status: null) instead of
|
|
24
|
+
// running. git.exe and node.exe are real binaries and don't need this, so
|
|
25
|
+
// scope it narrowly: unconditional shell:true would also apply to the
|
|
26
|
+
// `node -e <script>` call below, and on POSIX Node's shell:true joins args
|
|
27
|
+
// with plain spaces (no escaping), which would corrupt that script argument.
|
|
22
28
|
function command(cwd, executable, args, env = process.env) {
|
|
23
|
-
|
|
29
|
+
const needsShell = process.platform === 'win32' && executable === 'npm';
|
|
30
|
+
return (0, child_process_1.spawnSync)(executable, args, { cwd, encoding: 'utf8', env, shell: needsShell });
|
|
24
31
|
}
|
|
25
32
|
/** Published evidence accepts only exact versions and immutable git tags. */
|
|
26
33
|
function assertImmutableArtifacts(version, tag, commit, remote) {
|
|
@@ -8,7 +8,6 @@ const path_1 = __importDefault(require("path"));
|
|
|
8
8
|
const child_process_1 = require("child_process");
|
|
9
9
|
const CLI_ROOT = path_1.default.resolve(__dirname, '../..');
|
|
10
10
|
const DIST_ENTRYPOINT = path_1.default.join(CLI_ROOT, 'dist', 'src', 'index.js');
|
|
11
|
-
const R3_MAJOR_VERSION = 8;
|
|
12
11
|
function readJson(file) {
|
|
13
12
|
return JSON.parse(fs_1.default.readFileSync(path_1.default.join(CLI_ROOT, file), 'utf8'));
|
|
14
13
|
}
|
|
@@ -22,13 +21,19 @@ function runCompiledCli(...args) {
|
|
|
22
21
|
return `${result.stdout}${result.stderr}`;
|
|
23
22
|
}
|
|
24
23
|
describe('R3 public major CLI release contract', () => {
|
|
25
|
-
|
|
24
|
+
// #92: the bump wrote only package.json, so the lockfile trailed by one
|
|
25
|
+
// version on EVERY release. This is the real invariant — package.json,
|
|
26
|
+
// package-lock.json, and its root entry must always agree. A hardcoded
|
|
27
|
+
// expected major (originally 8, from when this test was written) goes
|
|
28
|
+
// stale on every legitimate `!:`/BREAKING major bump and was never the
|
|
29
|
+
// actual contract, so it isn't asserted here.
|
|
30
|
+
it('retains a consistent version across package metadata and the lockfile root', () => {
|
|
26
31
|
const pkg = readJson('package.json');
|
|
27
32
|
const lock = readJson('package-lock.json');
|
|
28
33
|
const root = lock.packages[''];
|
|
29
34
|
const version = pkg.version;
|
|
30
35
|
expect(typeof version).toBe('string');
|
|
31
|
-
expect(version).toMatch(
|
|
36
|
+
expect(version).toMatch(/^\d+\.\d+\.\d+$/);
|
|
32
37
|
expect(lock.version).toBe(version);
|
|
33
38
|
expect(root.version).toBe(version);
|
|
34
39
|
});
|