Code Duplication    Length = 18-18 lines in 2 locations

eZ/Publish/Core/Repository/Tests/Service/Integration/UserBase.php 2 locations

@@ 266-283 (lines=18) @@
263
     * @expectedException \eZ\Publish\API\Repository\Exceptions\NotFoundException
264
     * @covers \eZ\Publish\API\Repository\UserService::loadSubUserGroups
265
     */
266
    public function testLoadSubUserGroupsThrowsNotFoundException()
267
    {
268
        $userService = $this->repository->getUserService();
269
270
        $parentGroup = new UserGroup(
271
            array(
272
                'content' => new Content(
273
                    array(
274
                        'versionInfo' => new VersionInfo(
275
                            array('contentInfo' => new ContentInfo(array('id' => APIBaseTest::DB_INT_MAX)))
276
                        ),
277
                        'internalFields' => array(),
278
                    )
279
                ),
280
            )
281
        );
282
        $userService->loadSubUserGroups($parentGroup);
283
    }
284
285
    /**
286
     * Test deleting user group.
@@ 310-327 (lines=18) @@
307
     * @expectedException \eZ\Publish\API\Repository\Exceptions\NotFoundException
308
     * @covers \eZ\Publish\API\Repository\UserService::deleteUserGroup
309
     */
310
    public function testDeleteUserGroupThrowsNotFoundException()
311
    {
312
        $userService = $this->repository->getUserService();
313
314
        $userGroup = new UserGroup(
315
            array(
316
                'content' => new Content(
317
                    array(
318
                        'versionInfo' => new VersionInfo(
319
                            array('contentInfo' => new ContentInfo(array('id' => APIBaseTest::DB_INT_MAX)))
320
                        ),
321
                        'internalFields' => array(),
322
                    )
323
                ),
324
            )
325
        );
326
        $userService->deleteUserGroup($userGroup);
327
    }
328
329
    /**
330
     * Test moving a user group below another group.