86-row call table checked against Google discovery documents, typed services, local approval ledger, live read-only tests, /agent/registry demo. Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
21 lines
851 B
C++
21 lines
851 B
C++
// Route: GET /agent/registry/approvals and /audit (local state)
|
|
#include "support/GoogleRig.hpp"
|
|
#include <cstdlib>
|
|
|
|
using namespace molo::example::test;
|
|
using molo::example::fw::Method;
|
|
|
|
int main() {
|
|
GoogleRig rig(false);
|
|
Fixture f(rig.client);
|
|
auto a = f.client->get("/agent/registry/approvals");
|
|
check(a.status == 200 && contains(a.body, "\"scope\":\"local\"") && contains(a.body, "\"approvals\":[]"),
|
|
"empty local ledger");
|
|
auto l = f.client->get("/agent/registry/audit");
|
|
check(l.status == 200 && contains(l.body, "\"entries\":[]") && contains(l.body, "\"dropped\":0"),
|
|
"empty audit trail");
|
|
check(f.client->post("/agent/registry/approvals").status == 405, "approvals post is 405");
|
|
check(f.client->post("/agent/registry/audit").status == 405, "audit post is 405");
|
|
return finish("agent/registry/approvals");
|
|
}
|