Security News
Research
Data Theft Repackaged: A Case Study in Malicious Wrapper Packages on npm
The Socket Research Team breaks down a malicious wrapper package that uses obfuscation to harvest credentials and exfiltrate sensitive data.
escss-estest
Advanced tools
100% coverage makes your life easier.
npm install escss-estest
like a water filter
function foo() {
{
// unhappy path(throw error here, under {} to be organized)
}
// happy path
}
// operator mode
esTest(1, '<', 5)
esTest(5, '>', 1)
esTest(1, '<=', 5)
esTest(5, '>=', 1)
esTest(1, '!==', 2)
esTest(1, '===', 1)
esTest(1, '===', 100) // error
esTest(1, '===', 100, 'foo') // error & message
// type mode
esTest(1, 'number')
esTest(1n, 'bigint')
esTest('foo', 'string')
esTest(true, 'boolean')
esTest([], 'array')
esTest({}, 'object')
esTest(NaN, 'NaN')
esTest(null, 'null')
esTest(undefined, 'undefined')
esTest(Symbol(), 'symbol')
esTest(function () {}, 'function')
esTest(1, 'object') // error
esTest(1, 'object', 'foo') // error & message
// basic
function sum(a, b, enable) {
{
esTest(a, 'number')
esTest(b, 'number')
}
return a + b
}
// async / await
async function getData() {
const url = "https://jsonplaceholder.typicode.com/todos/1";
const response = await fetch(url);
const json = await response.json();
{
esTest(json.completed, 'boolean')
esTest(json.id, 'number')
esTest(json.title, 'string')
esTest(json.userId, 'number')
}
console.log(json);
}
Dual Licensing( Commercial or AGPL 3.0 ), see here to know more
FAQs
A runtime testing library inspired by TDD and TypeScript to achieve 100% coverage.
The npm package escss-estest receives a total of 67 weekly downloads. As such, escss-estest popularity was classified as not popular.
We found that escss-estest demonstrated a healthy version release cadence and project activity because the last version was released less than a year ago. It has 0 open source maintainers 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
Research
The Socket Research Team breaks down a malicious wrapper package that uses obfuscation to harvest credentials and exfiltrate sensitive data.
Research
Security News
Attackers used a malicious npm package typosquatting a popular ESLint plugin to steal sensitive data, execute commands, and exploit developer systems.
Security News
The Ultralytics' PyPI Package was compromised four times in one weekend through GitHub Actions cache poisoning and failure to rotate previously compromised API tokens.