@@ -28,7 +28,7 @@ public function testPrettyPrintDoesNotMakeSenseForNDJson()
2828
2929 public function testWriteString ()
3030 {
31- $ this ->output = $ this ->getMock ('React\Stream\WritableStreamInterface ' );
31+ $ this ->output = $ this ->getMockBuilder ('React\Stream\WritableStreamInterface ' )-> getMock ( );
3232 $ this ->output ->expects ($ this ->once ())->method ('isWritable ' )->willReturn (true );
3333 $ this ->encoder = new Encoder ($ this ->output );
3434
@@ -39,7 +39,7 @@ public function testWriteString()
3939
4040 public function testWriteNull ()
4141 {
42- $ this ->output = $ this ->getMock ('React\Stream\WritableStreamInterface ' );
42+ $ this ->output = $ this ->getMockBuilder ('React\Stream\WritableStreamInterface ' )-> getMock ( );
4343 $ this ->output ->expects ($ this ->once ())->method ('isWritable ' )->willReturn (true );
4444 $ this ->encoder = new Encoder ($ this ->output );
4545
@@ -50,7 +50,7 @@ public function testWriteNull()
5050
5151 public function testWriteInfiniteWillEmitErrorAndClose ()
5252 {
53- $ this ->output = $ this ->getMock ('React\Stream\WritableStreamInterface ' );
53+ $ this ->output = $ this ->getMockBuilder ('React\Stream\WritableStreamInterface ' )-> getMock ( );
5454 $ this ->output ->expects ($ this ->once ())->method ('isWritable ' )->willReturn (true );
5555 $ this ->encoder = new Encoder ($ this ->output );
5656
@@ -66,7 +66,7 @@ public function testWriteInfiniteWillEmitErrorAndClose()
6666
6767 public function testEndWithoutDataWillEndOutputWithoutData ()
6868 {
69- $ this ->output = $ this ->getMock ('React\Stream\WritableStreamInterface ' );
69+ $ this ->output = $ this ->getMockBuilder ('React\Stream\WritableStreamInterface ' )-> getMock ( );
7070 $ this ->output ->expects ($ this ->once ())->method ('isWritable ' )->willReturn (true );
7171 $ this ->encoder = new Encoder ($ this ->output );
7272
@@ -78,7 +78,7 @@ public function testEndWithoutDataWillEndOutputWithoutData()
7878
7979 public function testEndWithDataWillForwardDataAndEndOutputWithoutData ()
8080 {
81- $ this ->output = $ this ->getMock ('React\Stream\WritableStreamInterface ' );
81+ $ this ->output = $ this ->getMockBuilder ('React\Stream\WritableStreamInterface ' )-> getMock ( );
8282 $ this ->output ->expects ($ this ->once ())->method ('isWritable ' )->willReturn (true );
8383 $ this ->encoder = new Encoder ($ this ->output );
8484
@@ -106,7 +106,7 @@ public function testClosingOutputClosesEncoder()
106106
107107 public function testPassingClosedStreamToEncoderWillCloseImmediately ()
108108 {
109- $ this ->output = $ this ->getMock ('React\Stream\WritableStreamInterface ' );
109+ $ this ->output = $ this ->getMockBuilder ('React\Stream\WritableStreamInterface ' )-> getMock ( );
110110 $ this ->output ->expects ($ this ->once ())->method ('isWritable ' )->willReturn (false );
111111 $ this ->encoder = new Encoder ($ this ->output );
112112
@@ -115,7 +115,7 @@ public function testPassingClosedStreamToEncoderWillCloseImmediately()
115115
116116 public function testWritingToClosedStreamWillNotForwardData ()
117117 {
118- $ this ->output = $ this ->getMock ('React\Stream\WritableStreamInterface ' );
118+ $ this ->output = $ this ->getMockBuilder ('React\Stream\WritableStreamInterface ' )-> getMock ( );
119119 $ this ->output ->expects ($ this ->once ())->method ('isWritable ' )->willReturn (false );
120120 $ this ->encoder = new Encoder ($ this ->output );
121121
0 commit comments