Add Playwright tests for live site authentication and race page loading
- Introduced `auth.setup.js` to handle authentication against the live site and store the session state. - Created `live-race.spec.js` to test loading a live race page with an authenticated session, including cookie validation. - Added utility functions in `live-site-test-utils.js` for managing authentication, dismissing cookie banners, and checking UI states. - Included a temporary JSON file for live state inspection. - Updated deployment manifest to reflect new and modified files. - Implemented `_inc_faceai_identity.jsp` for managing FaceAI identity cookies and included it in relevant JSP files. - Added language management JavaScript in `lang.js`. - Adjusted `fotoCR-en.jsp` and `fotoCR.jsp` to include the FaceAI identity logic. - Created a tarball for staging deployment.
This commit is contained in:
parent
9f56dfba1d
commit
1d1bccdae6
23 changed files with 4358 additions and 11 deletions
12
faceai/tests/live-site/auth.setup.js
Normal file
12
faceai/tests/live-site/auth.setup.js
Normal file
|
|
@ -0,0 +1,12 @@
|
|||
const { test } = require('@playwright/test');
|
||||
const {
|
||||
AUTH_FILE,
|
||||
ensureAuthDirectory,
|
||||
performLiveLogin
|
||||
} = require('./live-site-test-utils');
|
||||
|
||||
test('authenticate against the live site', async ({ page }) => {
|
||||
ensureAuthDirectory();
|
||||
await performLiveLogin(page);
|
||||
await page.context().storageState({ path: AUTH_FILE });
|
||||
});
|
||||
Loading…
Add table
Add a link
Reference in a new issue