|
@@ 2527-2539 (lines=13) @@
|
| 2524 |
|
self::assertCount(1, $contentTypes); |
| 2525 |
|
|
| 2526 |
|
$contentTypeGroups = $contentTypeDraft->getContentTypeGroups(); |
| 2527 |
|
foreach ($contentTypeGroups as $contentTypeGroup) { |
| 2528 |
|
$contentTypes = $contentTypeService->loadContentTypes($contentTypeGroup); |
| 2529 |
|
// check if not published Content Type does not exist on published Content Types list |
| 2530 |
|
self::assertNotContains( |
| 2531 |
|
$contentTypeDraft->id, |
| 2532 |
|
array_map( |
| 2533 |
|
function (ContentType $contentType) { |
| 2534 |
|
return $contentType->id; |
| 2535 |
|
}, |
| 2536 |
|
$contentTypes |
| 2537 |
|
) |
| 2538 |
|
); |
| 2539 |
|
} |
| 2540 |
|
|
| 2541 |
|
$contentTypeService->publishContentTypeDraft($contentTypeDraft); |
| 2542 |
|
|
|
@@ 2548-2560 (lines=13) @@
|
| 2545 |
|
self::assertArrayHasKey($contentTypeDraft->id, $contentTypes); |
| 2546 |
|
self::assertCount(2, $contentTypes); |
| 2547 |
|
|
| 2548 |
|
foreach ($contentTypeGroups as $contentTypeGroup) { |
| 2549 |
|
$contentTypes = $contentTypeService->loadContentTypes($contentTypeGroup); |
| 2550 |
|
// check if published Content is available in published Content Types list |
| 2551 |
|
self::assertContains( |
| 2552 |
|
$contentTypeDraft->id, |
| 2553 |
|
array_map( |
| 2554 |
|
function (ContentType $contentType) { |
| 2555 |
|
return $contentType->id; |
| 2556 |
|
}, |
| 2557 |
|
$contentTypes |
| 2558 |
|
) |
| 2559 |
|
); |
| 2560 |
|
} |
| 2561 |
|
} |
| 2562 |
|
|
| 2563 |
|
/** |