Recommendation question: not for admins and authors
CI / test (push) Successful in 2m38s
CI / build (push) Skipped
CI / deploy (push) Skipped

The team's answers would only blur the number.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_012vLHzh5qUhFtmJhzkcTbXL
This commit is contained in:
feco
2026-11-24 07:49:26 +00:00
co-authored by Claude Opus 5.5
parent e1dee3a20d
commit 6731955fce
3 changed files with 12 additions and 4 deletions
+6
View File
@@ -3946,6 +3946,12 @@ async fn the_recommendation_question_comes_once_after_two_contents(pool: PgPool)
}
assert_eq!(app.post("/v1/nps", Some(&bela), json!({"score": null})).await.status, StatusCode::NO_CONTENT);
assert_eq!(app.get("/v1/me", Some(&bela)).await.body["nps_due"], false);
// Not the team: an admin is not asked.
let admin_id = user_id(&app, &admin).await;
for _ in 0..2 {
analysis_row(&app, "tarot", None, admin_id, "done").await;
}
assert_eq!(app.get("/v1/me", Some(&admin)).await.body["nps_due"], false);
let r = app.get("/v1/admin/feedback/summary", Some(&admin)).await;
let nps = &r.body["nps"];
assert_eq!(