Skip to content

Commit c597b02

Browse files
committed
chore: fix test
1 parent 83d60bc commit c597b02

File tree

1 file changed

+5
-3
lines changed

1 file changed

+5
-3
lines changed

src/consistency.test.ts

+5-3
Original file line numberDiff line numberDiff line change
@@ -152,6 +152,7 @@ describe('Consistency configuration', () => {
152152
cool: true,
153153
functions: ['edge', 'serverless'],
154154
}
155+
const mockRegion = 'us-east-1'
155156
const headers = {
156157
etag: '123456789',
157158
'x-amz-meta-user': `b64;${base64Encode(mockMetadata)}`,
@@ -160,17 +161,17 @@ describe('Consistency configuration', () => {
160161
.get({
161162
headers: { authorization: `Bearer ${edgeToken}` },
162163
response: new Response(value),
163-
url: `${uncachedEdgeURL}/${siteID}/deploy:${deployID}/${key}`,
164+
url: `${uncachedEdgeURL}/region:${mockRegion}/${siteID}/deploy:${deployID}/${key}`,
164165
})
165166
.head({
166167
headers: { authorization: `Bearer ${edgeToken}` },
167168
response: new Response(null, { headers }),
168-
url: `${uncachedEdgeURL}/${siteID}/deploy:${deployID}/${key}`,
169+
url: `${uncachedEdgeURL}/region:${mockRegion}/${siteID}/deploy:${deployID}/${key}`,
169170
})
170171
.get({
171172
headers: { authorization: `Bearer ${edgeToken}` },
172173
response: new Response(value, { headers }),
173-
url: `${uncachedEdgeURL}/${siteID}/deploy:${deployID}/${key}`,
174+
url: `${uncachedEdgeURL}/region:${mockRegion}/${siteID}/deploy:${deployID}/${key}`,
174175
})
175176

176177
globalThis.fetch = mockStore.fetch
@@ -179,6 +180,7 @@ describe('Consistency configuration', () => {
179180
consistency: 'strong',
180181
edgeURL,
181182
deployID,
183+
region: mockRegion,
182184
token: edgeToken,
183185
siteID,
184186
uncachedEdgeURL,

0 commit comments

Comments
 (0)