Skip to content

Commit da8ca46

Browse files
committed
[Refactor] generalize error message from calling .end more than once
1 parent faa51b5 commit da8ca46

File tree

2 files changed

+3
-3
lines changed

2 files changed

+3
-3
lines changed

lib/test.js

+1-1
Original file line numberDiff line numberDiff line change
@@ -151,7 +151,7 @@ Test.prototype.end = function (err) {
151151
}
152152

153153
if (this.calledEnd) {
154-
this.fail('.end() called twice');
154+
this.fail('.end() already called');
155155
}
156156
this.calledEnd = true;
157157
this._end();

test/double_end.js

+2-2
Original file line numberDiff line numberDiff line change
@@ -39,12 +39,12 @@ test(function (t) {
3939
'TAP version 13',
4040
'# double end',
4141
'ok 1 should be equal',
42-
'not ok 2 .end() called twice',
42+
'not ok 2 .end() already called',
4343
' ---',
4444
' operator: fail',
4545
' ' + atExpected,
4646
' stack: |-',
47-
' Error: .end() called twice',
47+
' Error: .end() already called',
4848
' [... stack stripped ...]',
4949
' ' + stackExpected,
5050
' [... stack stripped ...]',

0 commit comments

Comments
 (0)