Skip to content

Commit

Permalink
update
Browse files Browse the repository at this point in the history
  • Loading branch information
ddcat1115 committed Dec 16, 2017
1 parent 4f6f20b commit 782fe9b
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions src/e2e/login.e2e.js
Original file line number Diff line number Diff line change
Expand Up @@ -8,15 +8,17 @@ describe('Login', () => {
});

it('should login with failure', async () => {
await page.type('#userName', 'mockuser')
await page.wait(5000)
.type('#userName', 'mockuser')
.type('#password', 'wrong_password')
.click('button[type="submit"]')
.wait('.ant-alert-error') // should display error
.end();
});

it('should login successfully', async () => {
const text = await page.type('#userName', 'admin')
const text = await page.wait(5000)
.type('#userName', 'admin')
.type('#password', '888888')
.click('button[type="submit"]')
.wait('.ant-layout-sider h1') // should display error
Expand Down

0 comments on commit 782fe9b

Please sign in to comment.