Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/reydvires/wrap-assert
This package will take wrap the assert console for mini test
https://github.com/reydvires/wrap-assert
Last synced: about 5 hours ago
JSON representation
This package will take wrap the assert console for mini test
- Host: GitHub
- URL: https://github.com/reydvires/wrap-assert
- Owner: ReydVires
- Created: 2021-01-04T01:48:24.000Z (almost 4 years ago)
- Default Branch: develop
- Last Pushed: 2021-01-04T05:23:32.000Z (almost 4 years ago)
- Last Synced: 2024-04-24T20:14:22.944Z (7 months ago)
- Language: JavaScript
- Size: 7.81 KB
- Stars: 0
- Watchers: 2
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# wrap-assert
An assert wrapper for mini test.
## usage (commonJS)
```javascript
const assert = require("wrap-assert");const label = "Equation";
const test = 10 > 8;
assert(test === true, label); // Output: Equation test is pass ✅
assert(!test, label); // Output: Equation test is fail ❌
```## method
`assert(value [, label] [, failMessage])`
- value: boolean
- label?: string
- failMessage?: stringNPM Package: [Link](https://npmjs.com/package/wrap-assert)