Route local lane gate opens through edge bindings

This commit is contained in:
Jeppe Bundgaard
2026-06-30 13:52:12 +02:00
parent 3eafc597c6
commit ac7da807bd
2 changed files with 37 additions and 2 deletions
@@ -311,6 +311,12 @@ it('wires self-serve lane gate open endpoint', function (): void {
expect($moduleSelfServeRoute)->toContain('MAX_GATE_OPEN_TOGGLE_AFTER_SECONDS = 5');
expect($moduleSelfServeRoute)->toContain('self::requireMaxValue($toggle_after, self::MAX_GATE_OPEN_TOGGLE_AFTER_SECONDS);');
expect($moduleSelfServeRoute)->toContain('$lane->open($gate, $toggle_after)');
expect($moduleSelfServeRoute)->toContain('queueLocalLaneGateOpen($lane, $gate, $toggle_after)');
expect($moduleSelfServeRoute)->toContain('$this->requestedShellyTransportOverride() === \'local\'');
expect($moduleSelfServeRoute)->toContain('queueRelaySwitchBatch(');
expect($moduleSelfServeRoute)->toContain("'target' => \$gate->name");
expect($moduleSelfServeRoute)->toContain("'queued' => \$queued_gate_command !== null");
expect($moduleSelfServeRoute)->toContain('$queued_gate_command !== null ? 202 : 200');
expect($moduleSelfServeRoute)->toContain("'toggle_after' => \$toggle_after");
expect($moduleSelfServeRoute)->toContain('private function requestedRelayToggleAfter');
expect($moduleSelfServeRoute)->toContain('Failed to open self-serve lane gate');