2
0
mirror of https://github.com/inventree/InvenTree.git synced 2025-07-02 03:30:54 +00:00

[UI] Web Prefix (#9334)

* [UI] Change default web prefix

- Adjust default from "platform" to "web"
- Much more standard prefix

* Cleanup

* Fixes for playwright tests

* Fix unit tests

* Refactor base_url into getBaseUrl
This commit is contained in:
Oliver
2025-03-20 00:12:52 +11:00
committed by GitHub
parent 832d884c85
commit 662a0b275e
38 changed files with 80 additions and 98 deletions

View File

@ -11,11 +11,11 @@ export const doLogin = async (page, username?: string, password?: string) => {
await navigate(page, logoutUrl);
await expect(page).toHaveTitle(/^InvenTree.*$/);
await page.waitForURL('**/platform/login');
await page.waitForURL('**/web/login');
await page.getByLabel('username').fill(username);
await page.getByLabel('password').fill(password);
await page.getByRole('button', { name: 'Log in' }).click();
await page.waitForURL('**/platform/home');
await page.waitForURL('**/web/home');
await page.waitForTimeout(250);
};
@ -33,7 +33,7 @@ export const doQuickLogin = async (
url = url ?? baseUrl;
await navigate(page, `${url}/login?login=${username}&password=${password}`);
await page.waitForURL('**/platform/home');
await page.waitForURL('**/web/home');
await page.getByLabel('navigation-menu').waitFor({ timeout: 5000 });
await page.getByText(/InvenTree Demo Server -/).waitFor();
@ -45,5 +45,5 @@ export const doQuickLogin = async (
export const doLogout = async (page) => {
await navigate(page, 'logout');
await page.waitForURL('**/platform/login');
await page.waitForURL('**/web/login');
};