Files
web2.0-frontend/tests/testcafe/404.test.ts
T
Aarni Halinen 2f045b462f Fix 404 test
2020-07-08 18:57:49 +03:00

17 lines
515 B
TypeScript

/**
* TestCafé test fixtures.
* This file is used by TestCafé to run end-to-end tests with chrome against the site.
* Tests are grouped into fixtures and fixtures into files.
*/
import { Selector } from "testcafe";
fixture`404 page renders and functions correctly`.page("http://localhost:3000/404");
test("Page contains the text 404", async t => {
/**
* Test if there is a favicon element on the page
*/
const elem = Selector("#not-found");
await t.expect(elem.textContent).contains("404");
});