Code Duplication    Length = 9-10 lines in 2 locations

AwsS3V3AdapterTest.php 2 locations

@@ 131-140 (lines=10) @@
128
    /**
129
     * @test
130
     */
131
    public function failing_to_delete_while_moving(): void
132
    {
133
        $adapter = $this->adapter();
134
        $adapter->write('source.txt', 'contents to be copied', new Config());
135
        static::$stubS3Client->failOnNextCopy();
136
137
        $this->expectException(UnableToMoveFile::class);
138
139
        $adapter->move('source.txt', 'destination.txt', new Config());
140
    }
141
142
143
@@ 147-155 (lines=9) @@
144
    /**
145
     * @test
146
     */
147
    public function failing_to_write_a_file(): void
148
    {
149
        $adapter = $this->adapter();
150
        static::$stubS3Client->throwDuringUpload(new RuntimeException('Oh no'));
151
152
        $this->expectException(UnableToWriteFile::class);
153
154
        $adapter->write('path.txt', 'contents', new Config());
155
    }
156
157
    /**
158
     * @test