Skip to content

Commit

Permalink
Test cookie table sorting
Browse files Browse the repository at this point in the history
Bug: 394287937
Change-Id: I157b9089a55763bdac7d10e24ad5ec7647df59f3
Reviewed-on: https://chromium-review.googlesource.com/c/devtools/devtools-frontend/+/6288625
Commit-Queue: Philip Pfaffe <[email protected]>
Auto-Submit: Danil Somsikov <[email protected]>
Reviewed-by: Philip Pfaffe <[email protected]>
  • Loading branch information
danilsomsikov authored and Devtools-frontend LUCI CQ committed Feb 21, 2025
1 parent 81a0851 commit d03fb12
Showing 1 changed file with 28 additions and 0 deletions.
28 changes: 28 additions & 0 deletions test/e2e/application/cookies_test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -204,4 +204,32 @@ describe('The Application Tab', () => {
},
]);
});

it('can sort cookies', async () => {
expectError('Request CacheStorage.requestCacheNames failed. {"code":-32602,"message":"Invalid security origin"}');
await navigateToApplicationTab('cookies');

await navigateToCookiesForTopDomain();
const dataGrid = await waitFor('devtools-data-grid');
await click('th.name-column', {root: dataGrid});
await click('th.name-column', {root: dataGrid});
const dataGridRowValues = await waitForFunction(async () => {
const values = await getDataGridData('.storage-view table', ['name']);
return values.length === 4 && values[0].name === 'urlencoded' ? values : undefined;
});
assert.deepEqual(dataGridRowValues, [
{
name: 'urlencoded',
},
{
name: 'foo2',
},
{
name: 'foo',
},
{
name: '__Host-foo3',
},
]);
});
});

0 comments on commit d03fb12

Please sign in to comment.