Code Duplication    Length = 12-14 lines in 2 locations

tests/BasketTest.php 2 locations

@@ 346-357 (lines=12) @@
343
        $this->assertEmpty($contents);
344
    }
345
346
    public function testItemToArray()
347
    {
348
        $actualId = $this->basket->insert([
349
            'id'       => 'foo',
350
            'name'     => 'bar',
351
            'price'    => 100,
352
            'quantity' => 1,
353
            'weight'   => 200,
354
        ]);
355
356
        $this->assertTrue(is_array($this->basket->item($actualId)->toArray()));
357
    }
358
359
    public function testbasketToArray()
360
    {
@@ 359-372 (lines=14) @@
356
        $this->assertTrue(is_array($this->basket->item($actualId)->toArray()));
357
    }
358
359
    public function testbasketToArray()
360
    {
361
        $this->basket->insert([
362
            'id'       => 'foo',
363
            'name'     => 'bar',
364
            'price'    => 100,
365
            'quantity' => 1,
366
            'weight'   => 200,
367
        ]);
368
369
        foreach ($this->basket->contents(true) as $item) {
370
            $this->assertTrue(is_array($item));
371
        }
372
    }
373
374
    public function testTax()
375
    {