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

TypeError: Class constructor FuzzRunner cannot be invoked without 'new' #742

Open
Shama-Ugale opened this issue Jan 5, 2024 · 2 comments

Comments

@Shama-Ugale
Copy link

Here is my package.json

{
"name": "jest-integration-example",
"scripts": {
"test": "jest",
"fuzz": "JAZZER_FUZZ=1 jest",
"coverage": "jest --coverage"
},
"devDependencies": {
"@jazzer.js/core": "^2.1.0",
"@jazzer.js/jest-runner": "^1.1.0",
"jest": "29.3.1"
},
"jest": {
"projects": [
{
"displayName": "test"
},
{
"displayName": {
"name": "Jazzer.js",
"color": "cyan"
},
"testMatch": [
"/**/*.fuzz.js"
],
"testRunner": "@jazzer.js/jest-runner"
}
]
}
}

and I am running the command "npm run fuzz", and get the below error

npm run coverage

coverage
jest --coverage

PASS test ./workerGoldenReference.test.js
PASS test ./integration.test.js
FAIL Jazzer.js ./worker.fuzz.js
● Test suite failed to run

TypeError: Class constructor FuzzRunner cannot be invoked without 'new'

  at runTestInternal (node_modules/jest-runner/build/runTest.js:367:22)

FAIL Jazzer.js ./integration.fuzz.js
● Test suite failed to run

TypeError: Class constructor FuzzRunner cannot be invoked without 'new'

  at runTestInternal (node_modules/jest-runner/build/runTest.js:367:22)

----------|---------|----------|---------|---------|-------------------

File % Stmts % Branch % Funcs % Lines Uncovered Line #s
All files 0 0 0 0
---------- --------- ---------- --------- --------- -------------------
Test Suites: 2 failed, 2 passed, 4 total
Tests: 8 passed, 8 total
Snapshots: 0 total
Time: 0.741 s, estimated 1 s
Ran all test suites in 2 projects.
@fmeum fmeum transferred this issue from CodeIntelligenceTesting/jazzer Jan 5, 2024
@fmeum
Copy link

fmeum commented Jan 5, 2024

@Shama-Ugale I moved the issue to Jazzer.js (from Jazzer).

@bertschneider
Copy link
Contributor

Your dependencies don't align. Please try out only adding "@jazzer.js/jest-runner": "^2.1.0" to your project.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants