test(trust): red for #27 — stranger gating, open-request claim, directed claims

This commit is contained in:
Smokey committed 2026-10-28 05:46:38 -06:00
1 parent b43294341d
commit c23fcdd73c
3 files changed
+135 -2

No files matched your search

+4 -2
View File
@@ -32,8 +32,9 @@ func newRecordServer(t *testing.T) (*httptest.Server, *Server, *recordBrain) {
}
func TestConspiracyInvitesDistinctLenses(t *testing.T) {
ts, _, rb := newRecordServer(t)
ts, srv, rb := newRecordServer(t)
id := newNest(t, ts, "Lab", `"Hugin","Munin","Soot"`)
promote(srv, "Hugin", "Munin", "Soot") // earned the right to take open work
code, req := post(t, ts.URL+"/api/nests/"+id+"/messages",
`{"author":"owner","kind":"request","mode":"conspiracy","text":"is this launch risky"}`)
if code != http.StatusCreated || req["mode"] != "conspiracy" {
@@ -68,8 +69,9 @@ func TestConspiracyInvitesDistinctLenses(t *testing.T) {
}
func TestConspiracyInviteCapped(t *testing.T) {
ts, _, rb := newRecordServer(t)
ts, srv, rb := newRecordServer(t)
id := newNest(t, ts, "Wide", strings.Join(quoteAll(roster), ","))
promote(srv, roster...)
code, out := post(t, ts.URL+"/api/nests/"+id+"/messages",
`{"author":"owner","kind":"request","mode":"conspiracy","invited":4,"text":"risk"}`)
if code != http.StatusCreated {