@japa/expect
Advanced tools
+4
-7
@@ -22,3 +22,3 @@ "use strict"; | ||
| Context.getter('expect', () => expect_1.default, true); | ||
| Test.dispose(function (_, hasError, errors) { | ||
| Test.dispose(function (_, hasError) { | ||
| if (hasError) { | ||
@@ -28,8 +28,5 @@ return; | ||
| const jestErrors = expect_1.default.extractExpectedAssertionsErrors(); | ||
| jestErrors.forEach((jestError) => { | ||
| errors.push({ | ||
| phase: 'test', | ||
| error: jestError.error, | ||
| }); | ||
| }); | ||
| if (jestErrors.length) { | ||
| throw jestErrors[0].error; | ||
| } | ||
| }); | ||
@@ -36,0 +33,0 @@ }; |
+2
-2
| { | ||
| "name": "@japa/expect", | ||
| "version": "1.0.0", | ||
| "version": "1.0.1", | ||
| "description": "Assertion package built on top of Jest expect", | ||
@@ -43,3 +43,3 @@ "main": "build/index.js", | ||
| "del-cli": "^4.0.1", | ||
| "eslint": "^8.7.0", | ||
| "eslint": "^8.8.0", | ||
| "eslint-config-prettier": "^8.3.0", | ||
@@ -46,0 +46,0 @@ "eslint-plugin-adonis": "^2.1.0", |
7065
-1.49%43
-6.52%