assertion-error
Advanced tools
Comparing version 2.0.0 to 2.0.1
{ | ||
"name": "assertion-error", | ||
"version": "2.0.0", | ||
"description": "Error constructor for test and validation frameworks that implements standardized AssertionError specification.", | ||
"author": "Jake Luer <jake@qualiancy.com> (http://qualiancy.com)", | ||
"license": "MIT", | ||
"types": "./dist/mod.d.ts", | ||
"keywords": [ | ||
"test", | ||
"assertion", | ||
"assertion-error" | ||
], | ||
"repository": { | ||
"type": "git", | ||
"url": "git@github.com:chaijs/assertion-error.git" | ||
}, | ||
"engines": { | ||
"node": ">=12" | ||
}, | ||
"files": [ | ||
"dist" | ||
], | ||
"type": "module", | ||
"module": "./dist/mod.js", | ||
"main": "./dist/mod.js", | ||
"scripts": { | ||
"build": "tsc", | ||
"pretest": "npm run build", | ||
"test": "NODE_ENV=test node ./test/index.js" | ||
}, | ||
"devDependencies": { | ||
"typescript": "^4.4.3" | ||
} | ||
"name": "assertion-error", | ||
"version": "2.0.1", | ||
"description": "Error constructor for test and validation frameworks that implements standardized AssertionError specification.", | ||
"author": "Jake Luer <jake@qualiancy.com> (http://qualiancy.com)", | ||
"license": "MIT", | ||
"types": "./index.d.ts", | ||
"keywords": [ | ||
"test", | ||
"assertion", | ||
"assertion-error" | ||
], | ||
"repository": { | ||
"type": "git", | ||
"url": "git@github.com:chaijs/assertion-error.git" | ||
}, | ||
"engines": { | ||
"node": ">=12" | ||
}, | ||
"files": [ | ||
"index.d.ts" | ||
], | ||
"type": "module", | ||
"module": "index.js", | ||
"main": "index.js", | ||
"scripts": { | ||
"build": "deno bundle mod.ts > index.js", | ||
"pretest": "rm -rf coverage/", | ||
"test": "deno test --coverage=coverage", | ||
"posttest": "deno coverage coverage --lcov > coverage/lcov.info && lcov --summary coverage/lcov.info" | ||
} | ||
} |
@@ -38,5 +38,5 @@ <p align=center> | ||
interface Result { | ||
name: 'AssertionError' | 'AssertionResult' | ||
ok: boolean | ||
toJSON(...args: unknown[]): Record<string, unknown> | ||
name: "AssertionError" | "AssertionResult"; | ||
ok: boolean; | ||
toJSON(...args: unknown[]): Record<string, unknown>; | ||
} | ||
@@ -46,3 +46,4 @@ ``` | ||
So if a function returns `AssertionResult | AssertionError` it is easy to check | ||
_which_ one is returned by checking either `.name` or `.ok`, or check `instanceof Error`. | ||
_which_ one is returned by checking either `.name` or `.ok`, or check | ||
`instanceof Error`. | ||
@@ -61,6 +62,10 @@ ## Installation | ||
`assertion_error` is available on [Deno.land](https://deno.land/x/assertion_error) | ||
`assertion_error` is available on | ||
[Deno.land](https://deno.land/x/assertion_error) | ||
```typescript | ||
import {AssertionError, AssertionResult} from 'https://deno.land/x/assertion_error@2.0.0/mod.ts' | ||
import { | ||
AssertionError, | ||
AssertionResult, | ||
} from "https://deno.land/x/assertion_error@2.0.0/mod.ts"; | ||
``` |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
No tests
QualityPackage does not have any tests. This is a strong signal of a poorly maintained or low quality package.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
New author
Supply chain riskA new npm collaborator published a version of the package for the first time. New collaborators are usually benign additions to a project, but do indicate a change to the security surface area of a package.
Found 1 instance in 1 package
5832
0
82
69
0
2