Skip to content

Commit 8412642

Browse files
committed
Fix misplaced done() calls in tests
Bug: T177764
1 parent 9d3d515 commit 8412642

File tree

2 files changed

+4
-8
lines changed

2 files changed

+4
-8
lines changed

tests/src/valueFormatters/valueFormatters.tests.js

Lines changed: 2 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -98,7 +98,6 @@
9898
inputDetailMsg = typeof formatInput === 'string'
9999
? 'for input "' + formatInput + '" '
100100
: '',
101-
request,
102101
done = assert.async();
103102

104103
if( $.isArray( expected ) ) {
@@ -136,16 +135,14 @@
136135
'Returned DataValue ' + inputDetailMsg + 'is equal to the expected '
137136
+ 'DataValue.'
138137
);
139-
140138
} )
141139
.fail( function( errorMessage ) {
142140
assert.ok(
143141
false,
144142
'Formatting ' + inputDetailMsg + 'failed: ' + errorMessage
145143
);
146-
} );
147-
148-
done();
144+
} )
145+
.always( done );
149146
} );
150147
}
151148

tests/src/valueParsers/valueParsers.tests.js

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -124,9 +124,8 @@
124124
} )
125125
.fail( function( errorMessage ) {
126126
assert.ok( false, 'parsing ' + inputDetailMsg + 'failed: ' + errorMessage );
127-
} );
128-
129-
done();
127+
} )
128+
.always( done );
130129
} );
131130
}
132131

0 commit comments

Comments
 (0)