Code Duplication    Length = 15-16 lines in 2 locations

tests/Feature/CaffeineTest.php 2 locations

@@ 26-40 (lines=15) @@
23
        $response->assertSee($expectedResult);
24
    }
25
26
    public function testSuccessfulDrip()
27
    {
28
        $dripRoute = config('genealabs-laravel-caffeine.route', 'genealabs/laravel-caffeine/drip');
29
        $html = $this->get(route('genealabs-laravel-caffeine.tests.form'))
30
            ->getContent();
31
        $matches = [];
32
        preg_match('/<meta name="csrf-token" content="(.*?)">/', $html, $matches);
33
        $csrfToken = $matches[1];
34
35
        $response = $this->get($dripRoute, [
36
            '_token' => $csrfToken,
37
        ]);
38
39
        $response->assertStatus(204);
40
    }
41
42
    public function testExpiredDrip()
43
    {
@@ 42-57 (lines=16) @@
39
        $response->assertStatus(204);
40
    }
41
42
    public function testExpiredDrip()
43
    {
44
        $dripRoute = config(
45
            'genealabs-laravel-caffeine.dripInterval',
46
            'genealabs/laravel-caffeine/drip'
47
        );
48
        $html = $this->get(route('genealabs-laravel-caffeine.tests.form'))
49
            ->getContent();
50
        $matches = [];
51
        preg_match(
52
            '/<meta name="csrf-token" content="(.*?)">/',
53
            $html,
54
            $matches
55
        );
56
        $csrfToken = $matches[1];
57
58
        app('session')->flush();
59
        $response = $this->get($dripRoute, [
60
            '_token' => $csrfToken,