Add testcafe
This commit is contained in:
parent
062bb48078
commit
1db8ae0d01
2 changed files with 14 additions and 0 deletions
1
.gitignore
vendored
1
.gitignore
vendored
|
@ -15,6 +15,7 @@
|
|||
!.plop
|
||||
!.pylintrc
|
||||
!.travis*
|
||||
!.testcafe
|
||||
!.tx
|
||||
*.css
|
||||
*.log
|
||||
|
|
13
.testcafe/exampleTest.js
Normal file
13
.testcafe/exampleTest.js
Normal file
|
@ -0,0 +1,13 @@
|
|||
import { Selector } from "testcafe";
|
||||
|
||||
fixture("Example test").page("http://localhost:8000/dashboard/next");
|
||||
|
||||
test("User can log in", async t => {
|
||||
await t
|
||||
.typeText('[name="email"]', "admin@example.com")
|
||||
.typeText('[name="password"]', "admin")
|
||||
.click('[type="submit"]');
|
||||
|
||||
const header = await Selector('[data-tc="home-header"]').exists;
|
||||
await t.expect(header).ok();
|
||||
});
|
Loading…
Reference in a new issue