
Security News
Attackers Are Hunting High-Impact Node.js Maintainers in a Coordinated Social Engineering Campaign
Multiple high-impact npm maintainers confirm they have been targeted in the same social engineering campaign that compromised Axios.
A unit test case generator. It will intercept the methods of class and save the input and out to file.
A unit test case generator. It will intercept the methods of class and save the input and output to file.
tcgenis a tool that will primarily capture (and generate) the unit test cases for your methods of a class. It acts like interceptor on the method calls of instance created of the the class.
npm install --save-dev tcgen
{
"srcPath": "/the/path/where/your/application/code/exists",
"noClassFiles" : [
"index.js", "section.js", "fileNotToTest.js"
],
"outpath" : "/output/path/where/the/test/cases/will/be/generated"
}
Default values of this json goes as below
{
"srcPath": process.cwd(),
"noClassFiles" : [],
"outpath" : path.join(tmpdir, 'tcgen')
}
export TCGEN_CONFIG_PATH=/my/config/path
TCGEN_CONFIG_PATH=/my/config/path node my-node-app.js
Somewhere in your application, but before initializing any class.
if (process.env.ENV !== 'production') { // on production we should not load this
require('tcgen')
}
Or if you don't want to use env variable
if (process.env.ENV !== 'production') { //
new (require('tcgen'))(theConfigDefinedAbove)
}
FAQs
A unit test case generator. It will intercept the methods of class and save the input and out to file.
The npm package tcgen receives a total of 3 weekly downloads. As such, tcgen popularity was classified as not popular.
We found that tcgen demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 1 open source maintainer collaborating on the project.
Did you know?

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Security News
Multiple high-impact npm maintainers confirm they have been targeted in the same social engineering campaign that compromised Axios.

Security News
Axios compromise traced to social engineering, showing how attacks on maintainers can bypass controls and expose the broader software supply chain.

Security News
Node.js has paused its bug bounty program after funding ended, removing payouts for vulnerability reports but keeping its security process unchanged.