mirror of
https://github.com/cpvalente/ontime.git
synced 2026-08-17 05:13:32 +00:00
refactor(settings): polish settings UI
This commit is contained in:
committed by
Carlos Valente
parent
f0c284b708
commit
24be49ef66
@@ -7,10 +7,11 @@ test('redirect', async ({ context }) => {
|
||||
await controllerPage.goto('/editor?settings=network__clients');
|
||||
await remotePage.goto('/timer');
|
||||
|
||||
await controllerPage.getByTestId('not-self-redirect').click();
|
||||
const remoteClient = controllerPage.getByRole('row').filter({ hasText: /\/timer/ });
|
||||
await remoteClient.getByTestId('not-self-redirect').click();
|
||||
await controllerPage.getByRole('textbox', { name: 'http://localhost:' }).click();
|
||||
await controllerPage.getByRole('textbox', { name: 'http://localhost:' }).fill('studio');
|
||||
await controllerPage.getByLabel('Redirect', { exact: true }).click();
|
||||
await controllerPage.getByRole('button', { name: 'Redirect to custom path' }).click();
|
||||
|
||||
await expect(remotePage.getByTestId('studio-view')).toBeVisible();
|
||||
});
|
||||
@@ -22,7 +23,11 @@ test('identify', async ({ context }) => {
|
||||
await controllerPage.goto('/editor?settings=network__clients');
|
||||
await remotePage.goto('/timer');
|
||||
|
||||
await controllerPage.getByTestId('not-self-identify').click();
|
||||
await controllerPage
|
||||
.getByRole('row')
|
||||
.filter({ hasText: /\/timer/ })
|
||||
.getByTestId('not-self-identify')
|
||||
.click();
|
||||
|
||||
await expect(remotePage.getByTestId('identify-overlay')).toBeVisible();
|
||||
});
|
||||
@@ -34,11 +39,19 @@ test('rename', async ({ context }) => {
|
||||
await controllerPage.goto('/editor?settings=network__clients');
|
||||
await remotePage.goto('/timer');
|
||||
|
||||
await controllerPage.getByTestId('not-self-rename').click();
|
||||
await controllerPage
|
||||
.getByRole('row')
|
||||
.filter({ hasText: /\/timer/ })
|
||||
.getByTestId('not-self-rename')
|
||||
.click();
|
||||
await controllerPage.getByPlaceholder('new name').click();
|
||||
await controllerPage.getByPlaceholder('new name').fill('test');
|
||||
await controllerPage.getByRole('button', { name: 'Submit' }).click();
|
||||
await controllerPage.getByTestId('not-self-identify').click();
|
||||
await controllerPage
|
||||
.getByRole('row')
|
||||
.filter({ hasText: /\/timer/ })
|
||||
.getByTestId('not-self-identify')
|
||||
.click();
|
||||
|
||||
await expect(remotePage.getByTestId('identify-overlay')).toContainText('test');
|
||||
});
|
||||
|
||||
Reference in New Issue
Block a user