start-command 0.32.0 → 0.32.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/CHANGELOG.md CHANGED
@@ -1,5 +1,11 @@
1
1
  # start-command
2
2
 
3
+ ## 0.32.1
4
+
5
+ ### Patch Changes
6
+
7
+ - 5568403: Keep Docker multi-network regression coverage hermetic while verifying the default bridge route.
8
+
3
9
  ## 0.32.0
4
10
 
5
11
  ### Minor Changes
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "start-command",
3
- "version": "0.32.0",
3
+ "version": "0.32.1",
4
4
  "description": "Gamification of coding, execute any command with ability to auto-report issues on GitHub",
5
5
  "main": "src/bin/cli.js",
6
6
  "exports": {
@@ -1,5 +1,5 @@
1
1
  #!/usr/bin/env bun
2
- /** Real-daemon integration coverage for Docker network isolation (issues #154, #156, #158). */
2
+ /** Real-daemon integration coverage for Docker network isolation (issues #154, #156, #158, #160). */
3
3
 
4
4
  const { after, before, describe, it } = require('node:test');
5
5
  const assert = require('assert');
@@ -10,6 +10,8 @@ const { runInDocker } = require('../src/lib/isolation');
10
10
  // Bun's `node:test` shim ignores a `describe`-level timeout, so every `it`
11
11
  // declares its own budget explicitly (issue #158).
12
12
  const TEST_TIMEOUT = 120000;
13
+ const MULTI_NETWORK_PROBE =
14
+ "ping -c 1 formal-ai && ping -c 1 formal-db && ip route | grep -q '^default '";
13
15
 
14
16
  const suffix = randomUUID().slice(0, 8);
15
17
  const network = `start-network-${suffix}`;
@@ -84,6 +86,13 @@ describe('Docker named network integration', () => {
84
86
  docker(['network', 'rm', network, secondNetwork]);
85
87
  });
86
88
 
89
+ it('keeps the multi-network probe hermetic', () => {
90
+ assert.doesNotMatch(MULTI_NETWORK_PROBE, /https?:\/\//);
91
+ assert.match(MULTI_NETWORK_PROBE, /formal-ai/);
92
+ assert.match(MULTI_NETWORK_PROBE, /formal-db/);
93
+ assert.match(MULTI_NETWORK_PROBE, /ip route/);
94
+ });
95
+
87
96
  it(
88
97
  'reaches a private sidecar on each of two networks',
89
98
  { timeout: TEST_TIMEOUT },
@@ -95,19 +104,18 @@ describe('Docker named network integration', () => {
95
104
  // Both endpoints are local, user-defined networks on purpose: probing a
96
105
  // public endpoint (previously `https://api.github.com`) made this test
97
106
  // fail whenever the shared runner IP hit the 60 requests/hour
98
- // unauthenticated GitHub API rate limit (issue #158).
99
- const joined = await runInDocker(
100
- 'ping -c 1 formal-ai && ping -c 1 formal-db',
101
- {
102
- image: 'alpine:3.23',
103
- session: connected,
104
- network,
105
- networks: [network, secondNetwork],
106
- detached: true,
107
- shell: 'sh',
108
- keepContainer: true,
109
- }
110
- );
107
+ // unauthenticated GitHub API rate limit. Checking the route table keeps
108
+ // the original assertion that the default bridge route survived without
109
+ // making the test depend on any internet service (issues #158, #160).
110
+ const joined = await runInDocker(MULTI_NETWORK_PROBE, {
111
+ image: 'alpine:3.23',
112
+ session: connected,
113
+ network: 'bridge',
114
+ networks: ['bridge', network, secondNetwork],
115
+ detached: true,
116
+ shell: 'sh',
117
+ keepContainer: true,
118
+ });
111
119
  assert.strictEqual(joined.success, true, joined.message);
112
120
  const joinedExit = docker(['wait', connected]);
113
121
  assert.strictEqual(joinedExit.status, 0, joinedExit.stderr);