testcafe: Failing tests `identifier 't' has already been declared` Jitsi

What is your Scenario?

Simple open Jitsi call page test

What is the Current behavior?

All the same, behavior as described here:

  • Identifier 't' has already been declared
  • page works when opened manually, no issues or errors were observed

What is the Expected behavior?

TestCafe should be able to render the app independent of the host scripts

What is your public website URL? (or attach your complete example)

https://meet.jit.si/testcafe_error

What is your TestCafe test code?

await t.navigateTo('https://meet.jit.si/testcafe_error');
await t.wait(500000);

Your complete configuration file

No response

Your complete test report

No response

Screenshots

Test: Screenshot 2021-12-29 at 15 19 33

Manual (everything works fine): Screenshot 2021-12-29 at 15 20 46

Steps to Reproduce

  1. https://meet.jit.si/testcafe_error
  2. Open the call page using testcafe

TestCafe version

1.18.1

Node.js version

14.15.4

Command-line arguments

testcafe --skip-js-errors --hostname localhost $NODE_DEBUG_OPTION “chrome --use-fake-ui-for-media-stream --use-fake-device-for-media-stream”

Browser name(s) and version(s)

Chrome 96

Platform(s) and version(s)

macOS 10.15.7

Other

No response

About this issue

  • Original URL
  • State: closed
  • Created 3 years ago
  • Comments: 22 (4 by maintainers)

Most upvoted comments

Hi @humanamburu,

TestCafe runs tests using the URL-rewritten proxy. This approach is good. However, there is a way to improve the stability and speed of test execution - the native browser automation API. We have a test execution mode uses native browser automation - we call it the Proxyless mode. In Proxyless mode, a few issues are already fixed. By the way, this issue was also fixed in Proxyless mode. This option is available in all interfaces:

// Command-line
testcafe chrome tests --experimental-proxyless

// Programmatic
const testcafe = await createTestCafe({ experimentalProxyless: true });
	
// Configuration file
{
   "experimentalProxyless": "true"
}	

Setup the testcafe@2.1.1-alpha.3 version and try running your tests in Proxyless mode. I look forward to your results. Note that at present it is an experimental mode. Also, the Proxyless mode is implemented only in Google Chrome. It will not work correctly if you run tests in a non-Chrome browser or in a combination of other browsers.

Hi @aal89

Thank you for the detailed information. We will investigate it.