mirror of
https://github.com/kiwix/kiwix-js.git
synced 2025-08-03 11:16:38 -04:00
14 lines
561 B
JavaScript
14 lines
561 B
JavaScript
/* global fixture, test */
|
|
|
|
import { Selector } from 'testcafe'; // first import testcafe selectors
|
|
|
|
fixture`Start QUnit tests`// declare the fixture
|
|
.page`http://localhost:8080/tests/unit/`; // specify the start page
|
|
|
|
// then create a test and place your code within it
|
|
test('Check for success', async t => {
|
|
await t
|
|
// Use the assertion to check if actual header text equals expected text
|
|
.expect(Selector('#qunit-testresult-display').innerText, { timeout: 10000 }).match(/0\s+failed.+?0\s+skipped.+?0\s+todo/, { timeout: 7000 });
|
|
});
|