File tree 1 file changed +5
-5
lines changed
1 file changed +5
-5
lines changed Original file line number Diff line number Diff line change @@ -76,7 +76,7 @@ function toArray(callback) {
76
76
77
77
function fromArray ( list ) {
78
78
const r = new Readable ( { objectMode : true } ) ;
79
- r . _read = common . noop ;
79
+ r . _read = common . mustNotCall ( ) ;
80
80
list . forEach ( function ( chunk ) {
81
81
r . push ( chunk ) ;
82
82
} ) ;
@@ -164,7 +164,7 @@ test('can read strings as objects', function(t) {
164
164
const r = new Readable ( {
165
165
objectMode : true
166
166
} ) ;
167
- r . _read = common . noop ;
167
+ r . _read = common . mustNotCall ( ) ;
168
168
const list = [ 'one' , 'two' , 'three' ] ;
169
169
list . forEach ( function ( str ) {
170
170
r . push ( str ) ;
@@ -182,7 +182,7 @@ test('read(0) for object streams', function(t) {
182
182
const r = new Readable ( {
183
183
objectMode : true
184
184
} ) ;
185
- r . _read = common . noop ;
185
+ r . _read = common . mustNotCall ( ) ;
186
186
187
187
r . push ( 'foobar' ) ;
188
188
r . push ( null ) ;
@@ -198,7 +198,7 @@ test('falsey values', function(t) {
198
198
const r = new Readable ( {
199
199
objectMode : true
200
200
} ) ;
201
- r . _read = common . noop ;
201
+ r . _read = common . mustNotCall ( ) ;
202
202
203
203
r . push ( false ) ;
204
204
r . push ( 0 ) ;
@@ -249,7 +249,7 @@ test('high watermark push', function(t) {
249
249
highWaterMark : 6 ,
250
250
objectMode : true
251
251
} ) ;
252
- r . _read = common . noop ;
252
+ r . _read = common . mustNotCall ( ) ;
253
253
for ( let i = 0 ; i < 6 ; i ++ ) {
254
254
const bool = r . push ( i ) ;
255
255
assert . strictEqual ( bool , i !== 5 ) ;
You can’t perform that action at this time.
0 commit comments