mirror of
https://github.com/openclaw/openclaw.git
synced 2026-04-09 08:11:09 +00:00
fix(gateway): fail closed on unresolved discovery endpoints
This commit is contained in:
@@ -444,13 +444,13 @@ describe("gateway discover routing helpers", () => {
|
||||
expect(pickGatewayPort(beacon)).toBe(18789);
|
||||
});
|
||||
|
||||
it("falls back to TXT host/port when resolve data is missing", () => {
|
||||
it("fails closed when resolve data is missing", () => {
|
||||
const beacon: GatewayBonjourBeacon = {
|
||||
instanceName: "Test",
|
||||
lanHost: "test-host.local",
|
||||
gatewayPort: 18789,
|
||||
};
|
||||
expect(pickBeaconHost(beacon)).toBe("test-host.local");
|
||||
expect(pickGatewayPort(beacon)).toBe(18789);
|
||||
expect(pickBeaconHost(beacon)).toBeNull();
|
||||
expect(pickGatewayPort(beacon)).toBeNull();
|
||||
});
|
||||
});
|
||||
|
||||
Reference in New Issue
Block a user