| @@ 2617-2626 (lines=10) @@ | ||
| 2614 | /* END: Use Case */ |
|
| 2615 | ||
| 2616 | $actual = array(); |
|
| 2617 | foreach ($reloadedContent->getFields() as $field) { |
|
| 2618 | $actual[] = new Field( |
|
| 2619 | array( |
|
| 2620 | 'id' => 0, |
|
| 2621 | 'value' => ($field->value !== null ? true : null), // Actual value tested by FieldType integration tests |
|
| 2622 | 'languageCode' => $field->languageCode, |
|
| 2623 | 'fieldDefIdentifier' => $field->fieldDefIdentifier, |
|
| 2624 | ) |
|
| 2625 | ); |
|
| 2626 | } |
|
| 2627 | usort( |
|
| 2628 | $actual, |
|
| 2629 | function ($field1, $field2) { |
|
| @@ 6020-6030 (lines=11) @@ | ||
| 6017 | private function normalizeFields(array $fields) |
|
| 6018 | { |
|
| 6019 | $normalized = array(); |
|
| 6020 | foreach ($fields as $field) { |
|
| 6021 | $normalized[] = new Field( |
|
| 6022 | array( |
|
| 6023 | 'id' => 0, |
|
| 6024 | 'value' => ($field->value !== null ? true : null), |
|
| 6025 | 'languageCode' => $field->languageCode, |
|
| 6026 | 'fieldDefIdentifier' => $field->fieldDefIdentifier, |
|
| 6027 | 'fieldTypeIdentifier' => $field->fieldTypeIdentifier, |
|
| 6028 | ) |
|
| 6029 | ); |
|
| 6030 | } |
|
| 6031 | usort( |
|
| 6032 | $normalized, |
|
| 6033 | function ($field1, $field2) { |
|