mirror of
https://github.com/trezor/trezor-wallet
synced 2025-02-10 23:22:40 +00:00
Add base test env
This commit is contained in:
parent
e750fc2da6
commit
f5556d09c5
@ -92,6 +92,8 @@
|
||||
"babel-preset-env": "^1.6.0",
|
||||
"babel-preset-jest": "^23.2.0",
|
||||
"babel-preset-react": "^6.24.1",
|
||||
"cypress": "^3.1.4",
|
||||
"cypress-image-snapshot": "^3.0.0",
|
||||
"eslint": "^4",
|
||||
"eslint-config-airbnb": "^17.0.0",
|
||||
"eslint-import-resolver-babel-module": "^4.0.0",
|
||||
|
24
test/integration/landingPage.js
Normal file
24
test/integration/landingPage.js
Normal file
@ -0,0 +1,24 @@
|
||||
describe('Landing Page', () => {
|
||||
beforeEach(() => {
|
||||
cy.visit('http://localhost:8081/#/');
|
||||
cy.get('[data-test=beta-disclaimer-button]').click();
|
||||
});
|
||||
|
||||
it('top menu', () => {
|
||||
cy.get('[data-test=top-menu]')
|
||||
.should('be.visible')
|
||||
.matchImageSnapshot();
|
||||
});
|
||||
|
||||
it('main text', () => {
|
||||
cy.get('[data-test=landing-main-title]')
|
||||
.should('be.visible')
|
||||
.matchImageSnapshot();
|
||||
});
|
||||
|
||||
it('footer', () => {
|
||||
cy.get('[data-test=footer]')
|
||||
.should('be.visible')
|
||||
.matchImageSnapshot();
|
||||
});
|
||||
});
|
7
test/plugins/index.js
Normal file
7
test/plugins/index.js
Normal file
@ -0,0 +1,7 @@
|
||||
const {
|
||||
addMatchImageSnapshotPlugin,
|
||||
} = require('cypress-image-snapshot/plugin');
|
||||
|
||||
module.exports = (on) => {
|
||||
addMatchImageSnapshotPlugin(on);
|
||||
};
|
BIN
test/snapshots/landingPage.js/Landing Page -- footer.snap.png
Normal file
BIN
test/snapshots/landingPage.js/Landing Page -- footer.snap.png
Normal file
Binary file not shown.
After Width: | Height: | Size: 12 KiB |
BIN
test/snapshots/landingPage.js/Landing Page -- main text.snap.png
Normal file
BIN
test/snapshots/landingPage.js/Landing Page -- main text.snap.png
Normal file
Binary file not shown.
After Width: | Height: | Size: 69 KiB |
BIN
test/snapshots/landingPage.js/Landing Page -- top menu.snap.png
Normal file
BIN
test/snapshots/landingPage.js/Landing Page -- top menu.snap.png
Normal file
Binary file not shown.
After Width: | Height: | Size: 13 KiB |
3
test/support/commands.js
Normal file
3
test/support/commands.js
Normal file
@ -0,0 +1,3 @@
|
||||
import { addMatchImageSnapshotCommand } from 'cypress-image-snapshot/command';
|
||||
|
||||
addMatchImageSnapshotCommand();
|
1
test/support/index.js
Normal file
1
test/support/index.js
Normal file
@ -0,0 +1 @@
|
||||
import './commands';
|
Loading…
Reference in New Issue
Block a user