eZ\Publish\Core\Repository\Tests\Service\Integration\ContentTypeBase::testCopyContentTypeWithSecondArgument PHP Method

testCopyContentTypeWithSecondArgument() public method

Test for the copyContentType() method.
    public function testCopyContentTypeWithSecondArgument()
    {
        $time = time();
        /* BEGIN: Use Case */
        $user = $this->getStubbedUser(14);
        $this->repository->setCurrentUser($user);
        $contentTypeService = $this->repository->getContentTypeService();
        $commentType = $contentTypeService->loadContentTypeByIdentifier('comment');
        $copiedCommentType = $contentTypeService->copyContentType($commentType, $user);
        /* END: Use Case */
        return array('originalType' => $commentType, 'copiedType' => $copiedCommentType, 'time' => $time, 'userId' => $user->id);
    }
ContentTypeBase