Code Duplication    Length = 25-25 lines in 2 locations

src/Graviton/CoreBundle/Tests/Controller/ModuleControllerTest.php 1 location

@@ 174-198 (lines=25) @@
171
    /**
172
     * @return array
173
     */
174
    public function findByAppRefProvider()
175
    {
176
        return [
177
            'find all tablet records' => [
178
                'app.$ref',
179
                'http://localhost/core/app/tablet',
180
                5
181
            ],
182
            'find a linked record when searching for ref' => [
183
                'app.$ref',
184
                'http://localhost/core/app/admin',
185
                1
186
            ],
187
            'find nothing when searching for inextistant (and unlinked) ref' => [
188
                'app.$ref',
189
                'http://localhost/core/app/inexistant',
190
                0
191
            ],
192
            'return nothing when searching with incomplete ref' => [
193
                'app.$ref',
194
                'http://localhost/core/app',
195
                0
196
            ],
197
        ];
198
    }
199
200
    /**
201
     * Apply RQL operators to extref fields

src/Graviton/CoreBundle/Tests/Controller/ShowcaseControllerTest.php 1 location

@@ 936-960 (lines=25) @@
933
    /**
934
     * @return array
935
     */
936
    public function findByExtrefProvider()
937
    {
938
        return [
939
            'find a linked record when searching for "tablet" ref by array field' => [
940
                'nestedApps.0.$ref',
941
                'http://localhost/core/app/tablet',
942
                1
943
            ],
944
            'find a linked record when searching for "admin" ref by array field' => [
945
                'nestedApps.0.$ref',
946
                'http://localhost/core/app/admin',
947
                1
948
            ],
949
            'find nothing when searching for inextistant (and unlinked) ref by array field' => [
950
                'nestedApps.0.$ref',
951
                'http://localhost/core/app/inexistant',
952
                0
953
            ],
954
            'return nothing when searching with incomplete ref by array field' => [
955
                'nestedApps.0.$ref',
956
                'http://localhost/core/app',
957
                0
958
            ],
959
        ];
960
    }
961
}
962