@omg-dev/sandbox 0.4.31 → 0.4.33

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/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@omg-dev/sandbox",
3
- "version": "0.4.31",
3
+ "version": "0.4.33",
4
4
  "type": "module",
5
5
  "exports": {
6
6
  ".": {
@@ -148,19 +148,30 @@ describe("sandbox templates", () => {
148
148
 
149
149
  test("LFG owns every runtime dependency and zero-config transport default", () => {
150
150
  const lfg = agentTemplates.lfg;
151
- expect(templateVersionRef(lfg)).toBe("agent-lfg-v30");
151
+ expect(templateVersionRef(lfg)).toBe("agent-lfg-v33");
152
152
  expect(lfg.install).toContainEqual(apt.packages(["tmux"]));
153
153
  expect(lfg.checks).toContainEqual(check.command("tmux"));
154
+ expect(lfg.checks).toContainEqual(check.file("/home/user/lfg/omg-start.sh"));
155
+ expect(lfg.start?.command).toBe("exec /home/user/lfg/omg-start.sh");
154
156
  expect(lfg.start?.env?.LIVE_TRANSPORT).toBe("ws");
155
157
  expect(lfg.start?.readiness?.port).toBe(8766);
156
158
  expect(templateRuntimeContract(lfg, templateVersionRef(lfg))).toEqual({
157
- immutableRef: "agent-lfg-v30",
159
+ immutableRef: "agent-lfg-v33",
158
160
  restoreKind: "full_rootfs",
159
161
  startCommand: "exec /home/user/.omg/template/bootstrap.sh",
160
162
  readinessPort: 8766,
161
163
  readinessPath: "/",
162
164
  ports: [8766, 5173],
163
165
  });
166
+
167
+ const commands = lfg.install
168
+ .filter((step): step is Extract<typeof step, { kind: "run" }> => step.kind === "run")
169
+ .map((step) => step.command);
170
+ const startScript = commands.find((command) => command.includes("OMG_START_EOF"));
171
+ expect(startScript).toBeDefined();
172
+ expect(startScript!).toContain("LFG_CONNECT_EVENTS=1");
173
+ expect(startScript!).toContain("relay-credentials.json");
174
+ expect(startScript!).toContain("trap cleanup EXIT INT TERM");
164
175
  });
165
176
 
166
177
  test("LFG bakes the react-ts scaffold into /home/user/project at bake time", () => {
@@ -177,7 +188,7 @@ describe("sandbox templates", () => {
177
188
  .filter((step): step is Extract<typeof step, { kind: "run" }> => step.kind === "run")
178
189
  .map((step) => step.command);
179
190
  expect(commands.some((c) => c.includes("recipe.sh"))).toBe(true);
180
- expect(lfg.metadata?.lfgRelease).toBe("v0.1.164");
191
+ expect(lfg.metadata?.lfgRelease).toBe("v0.1.167");
181
192
  const lfgInstall = commands.find((c) => c.includes("bun install --production"));
182
193
  expect(lfgInstall).toBeDefined();
183
194
  expect(lfgInstall!).not.toContain("delete manifest.workspaces");