public function testUpdateContentTypeDraftThrowsInvalidArgumentExceptionDuplicateIdentifier() { $contentTypeDraft = $this->createDraftContentType(); /* BEGIN: Use Case */ // $contentTypeDraft contains a ContentTypeDraft with identifier 'blog-post' $contentTypeService = $this->repository->getContentTypeService(); $typeUpdate = $contentTypeService->newContentTypeUpdateStruct(); $typeUpdate->identifier = 'folder'; // Throws exception, since type "folder" already exists $contentTypeService->updateContentTypeDraft($contentTypeDraft, $typeUpdate); /* END: Use Case */ }