Code Duplication    Length = 9-13 lines in 2 locations

tests/unit/DataObjectAnnotatorTest.php 2 locations

@@ 192-200 (lines=9) @@
189
    /**
190
     * Test that multiple annotation runs won't generate ducplicate docblocks
191
     */
192
    public function testNothingHasChangedAfterSecondAnnotation()
193
    {
194
        $classInfo = new AnnotateClassInfo(Team::class);
195
        $filePath = $classInfo->getClassFilePath();
196
        $original = file_get_contents($filePath);
197
        $firstRun = $this->annotator->getGeneratedFileContent($original, Team::class);
198
        $secondRun = $this->annotator->getGeneratedFileContent($firstRun, Team::class);
199
        $this->assertEquals($firstRun, $secondRun);
200
    }
201
202
    /**
203
     * Test that root (non-namespaced) classes get annotated
@@ 239-251 (lines=13) @@
236
    /**
237
     *
238
     */
239
    public function testTwoClassesInOneFile()
240
    {
241
        $classInfo = new AnnotateClassInfo(DoubleDataObjectInOneFile1::class);
242
        $filePath = $classInfo->getClassFilePath();
243
        $original = file_get_contents($filePath);
244
        $annotated = $this->annotator->getGeneratedFileContent($original, DoubleDataObjectInOneFile1::class);
245
246
        $this->assertContains('@property string $Title', $annotated);
247
248
        $annotated = $this->annotator->getGeneratedFileContent($annotated, DoubleDataObjectInOneFile2::class);
249
250
        $this->assertContains('@property string $Name', $annotated);
251
    }
252
253
    public function tearDown()
254
    {