public function testLoadContentTypeGroup() { $contentTypeService = $this->repository->getContentTypeService(); $groupCreate = $contentTypeService->newContentTypeGroupCreateStruct('new-group'); $groupCreate->creatorId = $this->repository->getCurrentUserReference()->getUserId(); $groupCreate->creationDate = new \DateTime(); // @todo uncomment when support for multilingual names and descriptions is added EZP-24776 //$groupCreate->mainLanguageCode = 'eng-GB'; //$groupCreate->names = array( 'eng-US' => 'A name.' ); //$groupCreate->descriptions = array( 'eng-US' => 'A description.' ); $storedGroup = $contentTypeService->createContentTypeGroup($groupCreate); /* BEGIN: Use Case */ $loadedGroup = $contentTypeService->loadContentTypeGroup($storedGroup->id); /* END: Use Case */ $this->assertInstanceOf('eZ\\Publish\\API\\Repository\\Values\\ContentType\\ContentTypeGroup', $loadedGroup); return array('expected' => $storedGroup, 'actual' => $loadedGroup); }