Add test for favorites page
This commit is contained in:
parent
3ceec890e3
commit
906628e348
1 changed files with 16 additions and 0 deletions
16
frontend/tests/acceptance/favorites.js
Normal file
16
frontend/tests/acceptance/favorites.js
Normal file
|
@ -0,0 +1,16 @@
|
|||
import { Selector } from 'testcafe';
|
||||
import testcafeconfig from './testcafeconfig';
|
||||
import Page from "./page-model";
|
||||
|
||||
fixture`Test favorites page`
|
||||
.page `localhost:2342/photos`;
|
||||
|
||||
const page = new Page();
|
||||
|
||||
test('See favorites', async t => {
|
||||
await t
|
||||
.hover(Selector('div[class="v-image__image v-image__image--cover"]').nth(0))
|
||||
.click(Selector('button.p-photo-like'))
|
||||
.navigateTo("../favorites")
|
||||
.expect(Selector('div.v-image__image').visible).ok();
|
||||
});
|
Loading…
Reference in a new issue