From 5367a231123e2179aadca8c1836da0f14d3faebf Mon Sep 17 00:00:00 2001 From: Karel De Smet Date: Mon, 21 Dec 2020 18:12:53 +0100 Subject: [PATCH] #1396: Fixed assertions for toBeLevelxxx() functions (#1397) Co-authored-by: Liyas Thomas --- helpers/postwomanTesting.js | 8 ++++---- pages/index.vue | 2 +- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/helpers/postwomanTesting.js b/helpers/postwomanTesting.js index 30d0bb8d4..1de644e94 100644 --- a/helpers/postwomanTesting.js +++ b/helpers/postwomanTesting.js @@ -113,7 +113,7 @@ class Expectation { if (Number.isNaN(code)) { return this._fail(`Expected 200-level status but could not parse value ${this.expectValue}`) } - return this._satisfies(code >= 200 && code < 300) + return this._satisfies(code >= 200 && code < 300, true) ? this._pass() : this._fail(this._fmtNot(`Expected ${this.expectValue} to (not)be 200-level status`)) } @@ -122,7 +122,7 @@ class Expectation { if (Number.isNaN(code)) { return this._fail(`Expected 300-level status but could not parse value ${this.expectValue}`) } - return this._satisfies(code >= 300 && code < 400) + return this._satisfies(code >= 300 && code < 400, true) ? this._pass() : this._fail(this._fmtNot(`Expected ${this.expectValue} to (not)be 300-level status`)) } @@ -131,7 +131,7 @@ class Expectation { if (Number.isNaN(code)) { return this._fail(`Expected 400-level status but could not parse value ${this.expectValue}`) } - return this._satisfies(code >= 400 && code < 500) + return this._satisfies(code >= 400 && code < 500, true) ? this._pass() : this._fail(this._fmtNot(`Expected ${this.expectValue} to (not)be 400-level status`)) } @@ -140,7 +140,7 @@ class Expectation { if (Number.isNaN(code)) { return this._fail(`Expected 500-level status but could not parse value ${this.expectValue}`) } - return this._satisfies(code >= 500 && code < 600) + return this._satisfies(code >= 500 && code < 600, true) ? this._pass() : this._fail(this._fmtNot(`Expected ${this.expectValue} to (not)be 500-level status`)) } diff --git a/pages/index.vue b/pages/index.vue index c9c8cc456..b94691971 100644 --- a/pages/index.vue +++ b/pages/index.vue @@ -603,7 +603,7 @@