diff --git a/src/routes/_components/status/Notification.html b/src/routes/_components/status/Notification.html index 0864c66d..be6e3eb5 100644 --- a/src/routes/_components/status/Notification.html +++ b/src/routes/_components/status/Notification.html @@ -1,6 +1,6 @@ {#if status} {:else}
{ .pressKey('f') .expect(getNthFavorited(idx)).eql('false') }) + +test('Shortcut f toggles favorite status in notification', async t => { + let idx = 0 + await loginAsFoobar(t) + await t + .expect(getUrl()).eql('http://localhost:4002/') + .click(notificationsNavButton) + .expect(getUrl()).contains('/notifications') + .expect(getNthStatus(idx).exists).ok({ timeout: 30000 }) + .expect(getNthFavorited(idx)).eql('false') + .pressKey('j '.repeat(idx + 1)) + .expect(getNthStatus(idx).hasClass('status-active')).ok() + .pressKey('f') + .expect(getNthFavorited(idx)).eql('true') + .pressKey('f') + .expect(getNthFavorited(idx)).eql('false') +})