@camunda/e2e-test-suite 0.0.1422 → 0.0.1424
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/fixtures/SM-8.7.d.ts +1 -0
- package/dist/fixtures/SM-8.7.js +35 -0
- package/package.json +1 -1
|
@@ -62,6 +62,7 @@ type PlaywrightFixtures = {
|
|
|
62
62
|
keycloakLoginPage: KeycloakLoginPage;
|
|
63
63
|
keycloakAdminPage: KeycloakAdminPage;
|
|
64
64
|
overrideTrackingScripts: void;
|
|
65
|
+
rewriteIdentityAssetsOnFirefox: void;
|
|
65
66
|
};
|
|
66
67
|
declare const test: import("@playwright/test").TestType<import("@playwright/test").PlaywrightTestArgs & import("@playwright/test").PlaywrightTestOptions & PlaywrightFixtures, import("@playwright/test").PlaywrightWorkerArgs & import("@playwright/test").PlaywrightWorkerOptions>;
|
|
67
68
|
export { test };
|
package/dist/fixtures/SM-8.7.js
CHANGED
|
@@ -160,5 +160,40 @@ const test = test_1.test.extend({
|
|
|
160
160
|
auto: true,
|
|
161
161
|
},
|
|
162
162
|
],
|
|
163
|
+
rewriteIdentityAssetsOnFirefox: [
|
|
164
|
+
async ({ context, browserName }, use) => {
|
|
165
|
+
// 8.7 Identity serves root-relative assets and relies on its service
|
|
166
|
+
// worker (frontend/public/serviceWorker.js) to prefix every same-origin,
|
|
167
|
+
// non-document request with /identity. Playwright's Firefox does not
|
|
168
|
+
// hand those requests to the service worker, so apply the same rewrite.
|
|
169
|
+
if (browserName === 'firefox') {
|
|
170
|
+
await context.route('**/*', async (route) => {
|
|
171
|
+
const request = route.request();
|
|
172
|
+
let frameUrl;
|
|
173
|
+
try {
|
|
174
|
+
frameUrl = new URL(request.frame().url());
|
|
175
|
+
}
|
|
176
|
+
catch {
|
|
177
|
+
frameUrl = undefined;
|
|
178
|
+
}
|
|
179
|
+
const requestUrl = new URL(request.url());
|
|
180
|
+
if (!frameUrl ||
|
|
181
|
+
request.isNavigationRequest() ||
|
|
182
|
+
frameUrl.origin !== requestUrl.origin ||
|
|
183
|
+
!frameUrl.pathname.startsWith('/identity')) {
|
|
184
|
+
await route.fallback();
|
|
185
|
+
return;
|
|
186
|
+
}
|
|
187
|
+
await route.continue({
|
|
188
|
+
url: `${requestUrl.origin}/identity${requestUrl.pathname}${requestUrl.search}`,
|
|
189
|
+
});
|
|
190
|
+
});
|
|
191
|
+
}
|
|
192
|
+
await use();
|
|
193
|
+
},
|
|
194
|
+
{
|
|
195
|
+
auto: true,
|
|
196
|
+
},
|
|
197
|
+
],
|
|
163
198
|
});
|
|
164
199
|
exports.test = test;
|