feat: add --dev/--profile CLI profiles

This commit is contained in:
Peter Steinberger committed 2026-01-05 01:27:13 +01:00
1 parent f601dac30d
commit c6de1b1f7d
19 files changed
+516 -25

No files matched your search

+11
View File
@@ -64,6 +64,17 @@ describe("port allocation", () => {
expect(allocateCdpPort(usedPorts)).toBe(CDP_PORT_RANGE_START);
});
it("allocates within an explicit range", () => {
const usedPorts = new Set<number>();
expect(allocateCdpPort(usedPorts, { start: 20000, end: 20002 })).toBe(
20000,
);
usedPorts.add(20000);
expect(allocateCdpPort(usedPorts, { start: 20000, end: 20002 })).toBe(
20001,
);
});
it("skips used ports and returns next available", () => {
const usedPorts = new Set([CDP_PORT_RANGE_START, CDP_PORT_RANGE_START + 1]);
expect(allocateCdpPort(usedPorts)).toBe(CDP_PORT_RANGE_START + 2);