| @@ 2678-2687 (lines=10) @@ | ||
| 2675 | /* END: Use Case */ |
|
| 2676 | ||
| 2677 | $actual = array(); |
|
| 2678 | foreach ($reloadedContent->getFields() as $field) { |
|
| 2679 | $actual[] = new Field( |
|
| 2680 | array( |
|
| 2681 | 'id' => 0, |
|
| 2682 | 'value' => ($field->value !== null ? true : null), // Actual value tested by FieldType integration tests |
|
| 2683 | 'languageCode' => $field->languageCode, |
|
| 2684 | 'fieldDefIdentifier' => $field->fieldDefIdentifier, |
|
| 2685 | ) |
|
| 2686 | ); |
|
| 2687 | } |
|
| 2688 | usort( |
|
| 2689 | $actual, |
|
| 2690 | function ($field1, $field2) { |
|
| @@ 6141-6151 (lines=11) @@ | ||
| 6138 | private function normalizeFields(array $fields) |
|
| 6139 | { |
|
| 6140 | $normalized = array(); |
|
| 6141 | foreach ($fields as $field) { |
|
| 6142 | $normalized[] = new Field( |
|
| 6143 | array( |
|
| 6144 | 'id' => 0, |
|
| 6145 | 'value' => ($field->value !== null ? true : null), |
|
| 6146 | 'languageCode' => $field->languageCode, |
|
| 6147 | 'fieldDefIdentifier' => $field->fieldDefIdentifier, |
|
| 6148 | 'fieldTypeIdentifier' => $field->fieldTypeIdentifier, |
|
| 6149 | ) |
|
| 6150 | ); |
|
| 6151 | } |
|
| 6152 | usort( |
|
| 6153 | $normalized, |
|
| 6154 | function ($field1, $field2) { |
|