Skip to content

Commit 718f7c1

Browse files
committed
fix web tests
1 parent 3769257 commit 718f7c1

1 file changed

Lines changed: 3 additions & 2 deletions

File tree

application/CohortManager/src/Web/app/lib/fetchExceptions.test.ts

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -136,6 +136,7 @@ describe("fetchExceptions", () => {
136136
mockAuth.mockResolvedValue({
137137
expires: new Date(Date.now() + 60_000).toISOString(),
138138
idToken: "dev-jwt-token",
139+
accessToken: "dev-access-token",
139140
user: {
140141
name: "Test User",
141142
email: null,
@@ -145,6 +146,7 @@ describe("fetchExceptions", () => {
145146
});
146147

147148
globalThis.fetch = jest.fn().mockResolvedValue({
149+
148150
ok: true,
149151
json: jest.fn().mockResolvedValue([]),
150152
headers: { get: jest.fn().mockReturnValue(null) },
@@ -157,8 +159,7 @@ describe("fetchExceptions", () => {
157159
expect.objectContaining({
158160
cache: "no-store",
159161
headers: {
160-
Authorization: "Bearer dev-jwt-token",
161-
},
162+
Authorization: "Bearer dev-jwt-token", "X-Access-Token": "dev-access-token", },
162163
})
163164
);
164165
});

0 commit comments

Comments
 (0)