Code Duplication    Length = 16-16 lines in 2 locations

eZ/Publish/Core/Persistence/Cache/Tests/InMemory/InMemoryCacheTest.php 2 locations

@@ 63-78 (lines=16) @@
60
        $this->assertNull($this->cache->get('first'));
61
    }
62
63
    public function testGetBySecondaryIndex(): void
64
    {
65
        $this->assertNull($this->cache->get('first'));
66
        $this->assertNull($this->cache->get('secondary'));
67
68
        $obj = new \stdClass();
69
        $this->cache->setMulti([$obj], static function ($o) { return ['first', 'secondary']; });
70
71
        $this->assertSame($obj, $this->cache->get('first'));
72
        $this->assertSame($obj, $this->cache->get('secondary'));
73
74
        // Test TTL
75
        $GLOBALS['override_time'] = \microtime(true) + 4;
76
        $this->assertNull($this->cache->get('first'));
77
        $this->assertNull($this->cache->get('secondary'));
78
    }
79
80
    public function testGetByList(): void
81
    {
@@ 80-95 (lines=16) @@
77
        $this->assertNull($this->cache->get('secondary'));
78
    }
79
80
    public function testGetByList(): void
81
    {
82
        $this->assertNull($this->cache->get('first'));
83
        $this->assertNull($this->cache->get('list'));
84
85
        $obj = new \stdClass();
86
        $this->cache->setMulti([$obj], static function ($o) { return ['first']; }, 'list');
87
88
        $this->assertSame($obj, $this->cache->get('first'));
89
        $this->assertSame([$obj], $this->cache->get('list'));
90
91
        // Test TTL
92
        $GLOBALS['override_time'] = \microtime(true) + 4;
93
        $this->assertNull($this->cache->get('first'));
94
        $this->assertNull($this->cache->get('list'));
95
    }
96
97
    public function testDeleted(): void
98
    {