(t *testing.T)
| 13 | ) |
| 14 | |
| 15 | func TestStdioHealthRequest(t *testing.T) { |
| 16 | s := makeTestServer(t) |
| 17 | |
| 18 | request := newRequest("test-001", "health", nil).toJSON(t) |
| 19 | response := executeRequest(t, s, request) |
| 20 | |
| 21 | expected := map[string]interface{}{ |
| 22 | "jsonrpc": "2.0", |
| 23 | "id": "test-001", |
| 24 | } |
| 25 | |
| 26 | if diff := compareJSON(expected, response); diff != "" { |
| 27 | t.Errorf("Response mismatch:\n%s", diff) |
| 28 | } |
| 29 | |
| 30 | // Verify it's a success response (has result, no error) |
| 31 | if response["result"] == nil { |
| 32 | t.Errorf("Expected result field, got nil") |
| 33 | } |
| 34 | if response["error"] != nil { |
| 35 | t.Errorf("Expected no error, got: %v", response["error"]) |
| 36 | } |
| 37 | } |
| 38 | |
| 39 | func TestAdminUsersAddAndList(t *testing.T) { |
| 40 | s := makeTestServer(t) |
nothing calls this directly
no test coverage detected