Update the browser, editor, settings, and installer
This commit is contained in:
@@ -69,7 +69,11 @@ await page.addInitScript(() => {
|
||||
window.__TAURI_EVENT_PLUGIN_INTERNALS__ = { unregisterListener: (_event, id) => callbacks.delete(id) };
|
||||
});
|
||||
const section = page.getByRole('region', { name: 'Individual web data', exact: true });
|
||||
const profile = page.getByRole('combobox', { name: 'Profile', exact: true });
|
||||
const profile = page.getByRole('button', { name: 'Profile', exact: true });
|
||||
async function selectProfile(id) {
|
||||
await profile.click();
|
||||
await page.getByRole('menuitemradio', { name: id === 'work' ? 'Work' : 'Personal', exact: true }).click();
|
||||
}
|
||||
const kind = section.getByRole('combobox', { name: 'Web data type', exact: true });
|
||||
const filter = section.getByRole('searchbox', { name: 'Filter web data', exact: true });
|
||||
const refresh = section.getByRole('button', { name: 'Refresh', exact: true });
|
||||
@@ -114,7 +118,7 @@ try {
|
||||
await filter.fill('another.example/document');
|
||||
await section.getByRole('button', { name: 'Remove history entry https://another.example/document', exact: true }).waitFor();
|
||||
assert.equal(await section.locator('.entry').count(), 1);
|
||||
await profile.selectOption('work');
|
||||
await selectProfile('work');
|
||||
await settle();
|
||||
assert.equal(await filter.inputValue(), '', 'Profile changes clear the prior filter');
|
||||
await section.getByText('Work guide', { exact: true }).waitFor();
|
||||
@@ -126,7 +130,7 @@ try {
|
||||
await refresh.click();
|
||||
await pending('webData:work');
|
||||
assert.equal(await workCookie().isDisabled(), true);
|
||||
await profile.selectOption('user');
|
||||
await selectProfile('user');
|
||||
await settle();
|
||||
await release('webData:work');
|
||||
assert.equal(await workCookie().count(), 0);
|
||||
@@ -136,7 +140,7 @@ try {
|
||||
await hold('webData:user');
|
||||
await refresh.click();
|
||||
await pending('webData:user');
|
||||
await profile.selectOption('work');
|
||||
await selectProfile('work');
|
||||
await workCookie().waitFor();
|
||||
await settle();
|
||||
await release('webData:user', 'Stale personal error');
|
||||
@@ -147,11 +151,11 @@ try {
|
||||
await hold('removeCookie:work');
|
||||
await workCookie().click();
|
||||
await pending('removeCookie:work');
|
||||
await profile.selectOption('user');
|
||||
await selectProfile('user');
|
||||
await settle();
|
||||
const readsBefore = await page.evaluate(() => window.webDataTest.calls.filter(item => item.operation === 'webData').length);
|
||||
await release('removeCookie:work');
|
||||
assert.equal(await profile.inputValue(), 'user');
|
||||
assert.equal(await profile.innerText(), 'Personal');
|
||||
assert.equal(await section.locator('.entry').count(), 2);
|
||||
assert.equal(await page.evaluate(() => window.webDataTest.calls.filter(item => item.operation === 'webData').length), readsBefore);
|
||||
assert.equal(await page.evaluate(() => window.webDataTest.data.work.cookies.length), 0);
|
||||
|
||||
Reference in New Issue
Block a user