Closed fred104 closed 1 year ago
Hi @fred104,
Thank you for the shared example. I've reproduced the issue.
Hi @fred104,
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 @fred104,
This issue is not reproduced with combination of testcafe@3.0.1
and the Google Chrome browser. Feel free to reopen this issue if you encounter it in other browsers.
What is your Scenario?
I'd like to test a page which has the following partial content. This content will be transformed by hammerhead with incorrect output which cause runtime javascript syntax errors.
What is the Current behavior?
When starting the test, there is an error in browser console.
The content would be transformed to:
You can see the structure is different from the original one.
]]>
is moved before the//-->
.What is the Expected behavior?
The content should be transformed with correct structure:
What is your public website URL? (or attach your complete example)
https://codesandbox.io/s/jovial-glitter-4o6e1f?file=/index.html
What is your TestCafe test code?
Your complete configuration file
No response
Your complete test report
Screenshots
No response
Steps to Reproduce
TestCafe version
1.9.1
Node.js version
18.12.0
Command-line arguments
testcafe chrome test.ts
Browser name(s) and version(s)
No response
Platform(s) and version(s)
No response
Other
No response