| @@ 2494-2503 (lines=10) @@ | ||
| 2491 | /* END: Use Case */ |
|
| 2492 | ||
| 2493 | $actual = array(); |
|
| 2494 | foreach ($reloadedContent->getFields() as $field) { |
|
| 2495 | $actual[] = new Field( |
|
| 2496 | array( |
|
| 2497 | 'id' => 0, |
|
| 2498 | 'value' => ($field->value !== null ? true : null), // Actual value tested by FieldType integration tests |
|
| 2499 | 'languageCode' => $field->languageCode, |
|
| 2500 | 'fieldDefIdentifier' => $field->fieldDefIdentifier, |
|
| 2501 | ) |
|
| 2502 | ); |
|
| 2503 | } |
|
| 2504 | usort( |
|
| 2505 | $actual, |
|
| 2506 | function ($field1, $field2) { |
|
| @@ 5466-5475 (lines=10) @@ | ||
| 5463 | private function normalizeFields(array $fields) |
|
| 5464 | { |
|
| 5465 | $normalized = array(); |
|
| 5466 | foreach ($fields as $field) { |
|
| 5467 | $normalized[] = new Field( |
|
| 5468 | array( |
|
| 5469 | 'id' => 0, |
|
| 5470 | 'value' => ($field->value !== null ? true : null), |
|
| 5471 | 'languageCode' => $field->languageCode, |
|
| 5472 | 'fieldDefIdentifier' => $field->fieldDefIdentifier, |
|
| 5473 | ) |
|
| 5474 | ); |
|
| 5475 | } |
|
| 5476 | usort( |
|
| 5477 | $normalized, |
|
| 5478 | function ($field1, $field2) { |
|