mirror of
https://github.com/RuoJi6/ARTEX.git
synced 2026-10-27 17:03:49 +08:00
fix: display task intelligence content directly
This commit is contained in:
1 parent
d70dd15e11
commit
bd787f8883
6 files changed
+69
-90
No files matched your search
@@ -32,12 +32,12 @@ func TestIntelligenceHTTPSettingsAndScope(t *testing.T) {
|
||||
}
|
||||
base := fmt.Sprintf("/api/tasks/%d/intelligence", taskID)
|
||||
r := request("GET", base, "")
|
||||
if r.Code != 200 || strings.Contains(r.Body.String(), in.Content) || strings.Contains(r.Body.String(), in.Evidence) {
|
||||
t.Fatalf("list leaked secret: %d %s", r.Code, r.Body)
|
||||
if r.Code != 200 || !strings.Contains(r.Body.String(), in.Content) || !strings.Contains(r.Body.String(), in.Evidence) {
|
||||
t.Fatalf("list omitted content or evidence: %d %s", r.Code, r.Body)
|
||||
}
|
||||
r = request("GET", fmt.Sprintf("%s/%d", base, item.ID), "")
|
||||
if r.Code != 200 || !strings.Contains(r.Body.String(), in.Content) {
|
||||
t.Fatal("explicit reveal failed", r.Code, r.Body)
|
||||
t.Fatal("detail content missing", r.Code, r.Body)
|
||||
}
|
||||
if r = request("PATCH", fmt.Sprintf("%s/%d", base, item.ID), `{"status":"verified"}`); r.Code != 200 {
|
||||
t.Fatal(r.Code, r.Body)
|
||||
|
||||
Reference in new issue
Block a user