mirror of
https://github.com/immich-app/immich.git
synced 2025-12-20 09:15:35 +03:00
refactor(web): asset viewer actions (#11449)
* refactor(web): asset viewer actions * motion photo slot and more refactoring
This commit is contained in:
@@ -10,6 +10,9 @@ test.describe('Asset Viewer Navbar', () => {
|
||||
utils.initSdk();
|
||||
await utils.resetDatabase();
|
||||
admin = await utils.adminSetup();
|
||||
});
|
||||
|
||||
test.beforeEach(async () => {
|
||||
asset = await utils.createAsset(admin.accessToken);
|
||||
});
|
||||
|
||||
@@ -49,4 +52,14 @@ test.describe('Asset Viewer Navbar', () => {
|
||||
}
|
||||
});
|
||||
});
|
||||
|
||||
test.describe('actions', () => {
|
||||
test('favorite asset with shortcut', async ({ context, page }) => {
|
||||
await utils.setAuthCookies(context, admin.accessToken);
|
||||
await page.goto(`/photos/${asset.id}`);
|
||||
await page.waitForSelector('#immich-asset-viewer');
|
||||
await page.keyboard.press('f');
|
||||
await expect(page.locator('#notification-list').getByTestId('message')).toHaveText('Added to favorites');
|
||||
});
|
||||
});
|
||||
});
|
||||
|
||||
Reference in New Issue
Block a user