Code Duplication    Length = 11-11 lines in 4 locations

Test/OutputStreamWriterTest.php 4 locations

@@ 165-175 (lines=11) @@
162
     * コンソールに書き込みができること
163
     * @test
164
     */
165
    public function okConsoleWrite()
166
    {
167
        $stream = new ConsoleOutputStream();
168
        $writer = new OutputStreamWriter($stream);
169
        $writer->write("test");
170
        $writer->write("test");
171
        $writer->flush();
172
        $writer->close();
173
174
        $this->expectOutputString("testtest");
175
    }
176
177
    /**
178
     * 正常系
@@ 182-192 (lines=11) @@
179
     * offset指定でコンソールに書き込めること
180
     * @test
181
     */
182
    public function okConsoleWriteOffset()
183
    {
184
        $stream = new ConsoleOutputStream();
185
        $writer = new OutputStreamWriter($stream);
186
        $writer->write("123");
187
        $writer->write("123456", 3);
188
        $writer->flush();
189
        $writer->close();
190
191
        $this->expectOutputString("123456");
192
    }
193
194
    /**
195
     * 正常系
@@ 199-209 (lines=11) @@
196
     * Length指定でコンソールに書き込みができること
197
     * @test
198
     */
199
    public function okConsoleWriteLength()
200
    {
201
        $stream = new ConsoleOutputStream();
202
        $writer = new OutputStreamWriter($stream);
203
        $writer->write("123");
204
        $writer->write("123456789", null, 3);
205
        $writer->flush();
206
        $writer->close();
207
208
        $this->expectOutputString("123123");
209
    }
210
211
    /**
212
     * 正常系
@@ 216-226 (lines=11) @@
213
     * Offset,Length指定でコンソールに書き込みができること
214
     * @test
215
     */
216
    public function okConsoleWriteOffsetLength()
217
    {
218
        $stream = new ConsoleOutputStream();
219
        $writer = new OutputStreamWriter($stream);
220
        $writer->write("123");
221
        $writer->write("123456789", 3, 3);
222
        $writer->flush();
223
        $writer->close();
224
225
        $this->expectOutputString("123456");
226
    }
227
228
    /**
229
     * 異常系