Skip to content
Permalink
Browse files

- added tests for back action

:goose:
  • Loading branch information...
maZahaca committed Dec 7, 2018
1 parent 04f4784 commit 84fafe7930b4d491dc68d4e86b78ec6b1cd85d94
Showing with 35 additions and 0 deletions.
  1. +35 −0 test/integration/actions/actions.test.js
@@ -1082,6 +1082,41 @@ describe('Actions', () => {
});
});

describe('ActionBack', () => {
test('perform', async () => {
setServerResponse([
{
route: '/',
html: `<a href="/test">test</a>`
},
{
route: '/test',
html: `<a href="#">nothing</a>`,
}
]);
const parser = new Parser({
environment: new ChromeEnvironment({ url }),
});
const result = await parser.parse({
actions: [
{
type: 'click',
scope: 'a',
waitFor: 'page',
},
{
type: 'back',
},
],
rules: {
scope: 'a'
},
});

expect(result).toEqual('test');
});
});

// describe('ActionSnapshot', () => {
// test('making page snapshot', async () => {
// setServerResponse({

0 comments on commit 84fafe7

Please sign in to comment.
You can’t perform that action at this time.