From 6895eaab4972b5a786999a9bcf023655a5973a3e Mon Sep 17 00:00:00 2001 From: openhands Date: Fri, 16 Oct 2026 18:05:29 +0200 Subject: [PATCH] style(test): use literal header access --- e2e/imaging/avatar-endpoint.spec.ts | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/e2e/imaging/avatar-endpoint.spec.ts b/e2e/imaging/avatar-endpoint.spec.ts index 17ca9d9a..4d6f2099 100644 --- a/e2e/imaging/avatar-endpoint.spec.ts +++ b/e2e/imaging/avatar-endpoint.spec.ts @@ -81,7 +81,7 @@ test("answers conditional requests with 304", async ({ request }) => { avatarPath({ img_format: "png" }), ); expect(first.status()).toBe(200); - const etag = first.headers()["etag"]; + const etag = first.headers().etag; expect(etag).toBeTruthy(); const second = await getThroughEdge( @@ -92,7 +92,7 @@ test("answers conditional requests with 304", async ({ request }) => { }, ); expect(second.status()).toBe(304); - expect(second.headers()["etag"]).toBe(etag); + expect(second.headers().etag).toBe(etag); }); test("serves the rendered avatar behind permissive CORS", async ({ @@ -175,7 +175,7 @@ test("the badge endpoint serves an image and revalidates", async ({ expect(first.status()).toBe(200); expect(first.headers()["content-type"]).toContain("image/"); expect(first.headers()["access-control-allow-origin"]).toBe("*"); - const etag = first.headers()["etag"]; + const etag = first.headers().etag; expect(etag).toBeTruthy(); const second = await getThroughEdge(request, "/api/imaging/badge?code=ADM", {