Code Duplication    Length = 12-15 lines in 3 locations

tests/Statistics/TrackTest.php 3 locations

@@ 11-22 (lines=12) @@
8
9
class TrackTest extends BaseTest
10
{
11
    public function testEvent()
12
    {
13
        $track = $this->getTrack();
14
15
        $this->assertCount(0, $this->orm->source(Occurrence::class));
16
        $this->assertCount(0, $this->orm->source(Event::class));
17
18
        $track->event('some-event', 1.23);
19
20
        $this->assertCount(1, $this->orm->source(Occurrence::class));
21
        $this->assertCount(1, $this->orm->source(Event::class));
22
    }
23
24
    public function testEvents()
25
    {
@@ 24-38 (lines=15) @@
21
        $this->assertCount(1, $this->orm->source(Event::class));
22
    }
23
24
    public function testEvents()
25
    {
26
        $track = $this->getTrack();
27
28
        $this->assertCount(0, $this->orm->source(Occurrence::class));
29
        $this->assertCount(0, $this->orm->source(Event::class));
30
31
        $track->events([
32
            'some-event'  => 1.23,
33
            'some-event2' => 2.34
34
        ]);
35
36
        $this->assertCount(1, $this->orm->source(Occurrence::class));
37
        $this->assertCount(2, $this->orm->source(Event::class));
38
    }
39
40
    public function testEmptyEvents()
41
    {
@@ 40-51 (lines=12) @@
37
        $this->assertCount(2, $this->orm->source(Event::class));
38
    }
39
40
    public function testEmptyEvents()
41
    {
42
        $track = $this->getTrack();
43
44
        $this->assertCount(0, $this->orm->source(Occurrence::class));
45
        $this->assertCount(0, $this->orm->source(Event::class));
46
47
        $track->events([]);
48
49
        $this->assertCount(0, $this->orm->source(Occurrence::class));
50
        $this->assertCount(0, $this->orm->source(Event::class));
51
    }
52
53
    public function testEventInc()
54
    {