test: improve RoadmapRevision verification to use dynamic after value

Change RoadmapRevision check from hardcoded string to comparing against
the HTTP payload's `after` variable directly, proving the full chain:
HTTP payload `after` → scanner → bridge → job.RoadmapRevision.
This commit is contained in:
toki 2026-06-19 16:37:50 +09:00
parent d0d4c810ae
commit 83036e366b

View file

@ -232,8 +232,9 @@ func TestGitoHTTPWebhookDeliveryEnqueuesCreationSyncOnce(t *testing.T) {
job := enq.jobs[0]
// 10. Verify job content.
if job.RoadmapRevision != "abc123def456" {
t.Fatalf("RoadmapRevision: got %q, want %q", job.RoadmapRevision, "abc123def456")
// RoadmapRevision should match the HTTP payload's `after` value (passed through scanner).
if job.RoadmapRevision != after {
t.Fatalf("RoadmapRevision: got %q, want %q (HTTP payload `after`)", job.RoadmapRevision, after)
}
if job.Expected.WorkItemID != "wi-123" {
t.Fatalf("Expected.WorkItemID: got %q, want %q", job.Expected.WorkItemID, "wi-123")