mardi 11 août 2020

Property 'openWindow' does not exist on type 'TestController'

In my test I click on an element and then the new window is opened. But what I need is to check request from the previous window.

I was trying to do this:

https://devexpress.github.io/testcafe/documentation/reference/test-api/testcontroller/openwindow.html

import { Selector } from 'testcafe';

fixture `Example page`
    .page `http://www.example.com/`;

test('Open the TestCafe website', async t => {
    await t
        .openWindow('http://devexpress.github.io/testcafe')
        .openWindow('./documentation');

    const localWebsite = await t.openWindow('file://path/to/my/website');
});

but I got this error:

Property 'openWindow' does not exist on type 'TestController'.

Aucun commentaire:

Enregistrer un commentaire