Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- import PageObject, {
- clickable,
- fillable,
- text,
- visitable
- } from 'frontend/tests/page-object';
- export default PageObject.create({
- visit: visitable('/'),
- username: fillable('#username'),
- password: fillable('#password'),
- submit: clickable('button'),
- error: text('.errors'),
- loginSuccessfully() {
- return this.username('admin')
- .password('secret')
- .submit();
- },
- loginFailed() {
- return this.username('admin')
- .password('invalid')
- .submit();
- }
- });
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement