Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Unable to run tests with legacy API when installing TestCafe with yarn #7341

Closed
felis2803 opened this issue Oct 21, 2022 · 1 comment
Closed
Labels
TYPE: bug The described behavior is considered as wrong (bug).

Comments

@felis2803
Copy link
Contributor

felis2803 commented Oct 21, 2022

What is your Scenario?

  1. Install TestCafe with yarn.
  2. Try running tests with the legacy API.

What is the Current behavior?

Tests are not being run.

What is the Expected behavior?

The tests should run.

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

Irrelevant.

What is your TestCafe test code?

Irrelevant.

Your complete configuration file

Missing.

Your complete test report

 Running tests in:
 - Chrome 106.0.0.0 / Windows 10

 Simple test
Error: Cannot set headers after they are sent to the client
    at new NodeError (node:internal/errors:388:5)
    at ServerResponse.setHeader (node:_http_outgoing:603:11)
    at ServerResponse.writeHead (node:_http_server:314:21)
    at RequestPipelineContext.sendResponseHeaders (C:\projects\testcafe-temp-6\node_modules\testcafe-hammerhead\lib\request-pipeline\context.js:353:13)
    at Array.sendProxyResponse (C:\projects\testcafe-temp-6\node_modules\testcafe-hammerhead\lib\request-pipeline\stages.js:131:13)
    at processTicksAndRejections (node:internal/process/task_queues:95:5)
    at run (C:\projects\testcafe-temp-6\node_modules\testcafe-hammerhead\lib\request-pipeline\index.js:20:9) {
  code: 'ERR_HTTP_HEADERS_SENT'
}
TypeError: testRun.addError is not a function
    at C:\projects\testcafe-temp-6\node_modules\testcafe\src\utils\handle-errors.js:17:17
    at Array.forEach (<anonymous>)
    at handleTestRunError (C:\projects\testcafe-temp-6\node_modules\testcafe\src\utils\handle-errors.js:16:33)
    at handleError (C:\projects\testcafe-temp-6\node_modules\testcafe\src\utils\handle-errors.js:25:9)
    at handleUnexpectedError (C:\projects\testcafe-temp-6\node_modules\testcafe\src\utils\handle-errors.js:57:9)
    at process.<anonymous> (C:\projects\testcafe-temp-6\node_modules\testcafe\src\utils\handle-errors.js:65:43)
    at process.emit (node:events:537:28)
    at process.emit (node:domain:482:12)
    at emit (node:internal/process/promises:149:20)
    at processPromiseRejections (node:internal/process/promises:283:27)
    at processTicksAndRejections (node:internal/process/task_queues:96:32)

Steps to Reproduce

  1. git clone https://github.com/felis2803/testcafe-temp-6.git
  2. cd testcafe-temp-6
  3. yarn install
  4. node index.js

TestCafe version

2.0.1

Node.js version

18.5.0

Command-line arguments

Missing.

Browser name(s) and version(s)

Irrelevant.

Platform(s) and version(s)

Windows 10

@felis2803 felis2803 added the TYPE: bug The described behavior is considered as wrong (bug). label Oct 21, 2022
@miherlosev
Copy link
Collaborator

Duplicate of #7710

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
TYPE: bug The described behavior is considered as wrong (bug).
Projects
None yet
Development

No branches or pull requests

2 participants