Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion tests/AdminPluginTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -68,7 +68,7 @@ public function testTheRegisteredLoopbackGateRefusesInTheDeclaredLocale(): void
$gate = $container->get(LoopbackOnlyMiddleware::class);
self::assertInstanceOf(LoopbackOnlyMiddleware::class, $gate);

$lan = (new \Nyholm\Psr7\ServerRequest('GET', '/milpa/admin', [], null, '1.1', ['REMOTE_ADDR' => '192.168.1.47']))
$lan = (new \Nyholm\Psr7\ServerRequest('GET', '/milpa/admin', [], null, '1.1', ['REMOTE_ADDR' => '192.0.2.47']))
->withHeader('Accept', 'text/html');
$refused = $gate->process($lan, new class () implements \Psr\Http\Server\RequestHandlerInterface {
public function handle(\Psr\Http\Message\ServerRequestInterface $request): \Psr\Http\Message\ResponseInterface
Expand Down
4 changes: 2 additions & 2 deletions tests/Data/DevToolsSourceTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -308,7 +308,7 @@ public function testTheTimelineIsWhatTheProjectorPaintsPlusTheAuditFactsItLeaves
['debt', 'admitted_intent_skip — operation=hola:greet', []],
['evidence', 'operation_ok hola:greet', []],
['trial', 'make:crud · exit 0 · ws-1', []],
['operation', 'make:crud · rod@cli/rod@passkey · sha256:args', ['verified']],
['operation', 'make:crud · operator@cli/operator@passkey · sha256:args', ['verified']],
], $painted, 'model_returned is not painted (the projector says so); the audit facts are');
foreach ($run['events'] as $event) {
self::assertIsInt($event['seq']);
Expand Down Expand Up @@ -626,7 +626,7 @@ private static function seed(InMemoryEventStore $events, SessionStore $store): v
self::signal($events, 's-run', 'admitted_intent_skip', ['operation' => 'hola:greet']);
$store->recordEvidence('s-run', Evidence::operationOk('e1', 'hola:greet', null, 'exit 0'));
$store->recordTrialRun('s-run', ['workspace' => 'ws-1', 'operation' => 'make:crud', 'arguments_digest' => 'abc', 'bounds' => [], 'exit' => 0, 'report' => [], 'output_digest' => 'x']);
$store->recordExecution('s-run', 'make:crud', new Principal('rod', true), 'cli', ['principal' => 'rod', 'provenance' => 'passkey', 'session' => null], 'sha256:args');
$store->recordExecution('s-run', 'make:crud', new Principal('operator', true), 'cli', ['principal' => 'operator', 'provenance' => 'passkey', 'session' => null], 'sha256:args');

$store->start('s-wait', 'a second goal');
$store->ask('s-wait', new PendingQuestion('q1', 'Which target?', ['a', 'b'], null, null, 'target_not_named'));
Expand Down
4 changes: 2 additions & 2 deletions tests/Rendering/AdminHtmlRendererTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -695,7 +695,7 @@ public function testDevToolsDrillDownPaintsTheHeaderTheWayBackAndTheTimelineWith
['seq' => 5, 'when' => null, 'kind' => 'waiting', 'detail' => 'waiting on a human', 'flags' => []],
['seq' => 6, 'when' => '2026-09-04T14:02:11Z', 'kind' => 'closure', 'detail' => 'todo t1 done without evidence; t2 open', 'flags' => ['unverified']],
['seq' => 7, 'when' => '2026-09-04T14:02:12Z', 'kind' => 'mystery', 'detail' => '', 'flags' => ['verified']],
['seq' => 8, 'when' => '2026-09-04T14:02:13Z', 'kind' => 'operation', 'detail' => 'make:crud · rod@cli/rod@passkey · sha256:args', 'flags' => ['verified']],
['seq' => 8, 'when' => '2026-09-04T14:02:13Z', 'kind' => 'operation', 'detail' => 'make:crud · operator@cli/operator@passkey · sha256:args', 'flags' => ['verified']],
['seq' => 9, 'when' => '2026-09-04T14:02:14Z', 'kind' => 'sequence-paused', 'detail' => 'seq-1 · 1/3', 'flags' => []],
['seq' => 10, 'when' => '2026-09-04T14:02:15Z', 'kind' => 'sequence-resumed', 'detail' => 'seq-1', 'flags' => []],
'garbage',
Expand All @@ -717,7 +717,7 @@ public function testDevToolsDrillDownPaintsTheHeaderTheWayBackAndTheTimelineWith
self::assertStringContainsString('<tr><td>—</td><td>decision pending</td><td>waiting on a human</td></tr>', $html);
self::assertStringContainsString('<td>closure verdict <span class="mui-badge mui-badge--danger">unverified</span></td><td>todo t1 done without evidence; t2 open</td>', $html);
self::assertStringContainsString('<td>mystery <span class="mui-badge mui-badge--success">verified</span></td><td></td>', $html, 'a kind the catalog lacks is painted as it came');
self::assertStringContainsString('<td>operation executed <span class="mui-badge mui-badge--success">verified</span></td><td>make:crud · rod@cli/rod@passkey · sha256:args</td>', $html);
self::assertStringContainsString('<td>operation executed <span class="mui-badge mui-badge--success">verified</span></td><td>make:crud · operator@cli/operator@passkey · sha256:args</td>', $html);
self::assertStringContainsString('<td>sequence paused</td><td>seq-1 · 1/3</td>', $html);
self::assertStringContainsString('<td>sequence resumed</td><td>seq-1</td>', $html);
self::assertSame(10, substr_count($html, '<tr><td>'), 'garbage rows are skipped');
Expand Down
Loading