| @@ 2655-2664 (lines=10) @@ | ||
| 2652 | /* END: Use Case */ |
|
| 2653 | ||
| 2654 | $actual = array(); |
|
| 2655 | foreach ($reloadedContent->getFields() as $field) { |
|
| 2656 | $actual[] = new Field( |
|
| 2657 | array( |
|
| 2658 | 'id' => 0, |
|
| 2659 | 'value' => ($field->value !== null ? true : null), // Actual value tested by FieldType integration tests |
|
| 2660 | 'languageCode' => $field->languageCode, |
|
| 2661 | 'fieldDefIdentifier' => $field->fieldDefIdentifier, |
|
| 2662 | ) |
|
| 2663 | ); |
|
| 2664 | } |
|
| 2665 | usort( |
|
| 2666 | $actual, |
|
| 2667 | function ($field1, $field2) { |
|
| @@ 6058-6068 (lines=11) @@ | ||
| 6055 | private function normalizeFields(array $fields) |
|
| 6056 | { |
|
| 6057 | $normalized = array(); |
|
| 6058 | foreach ($fields as $field) { |
|
| 6059 | $normalized[] = new Field( |
|
| 6060 | array( |
|
| 6061 | 'id' => 0, |
|
| 6062 | 'value' => ($field->value !== null ? true : null), |
|
| 6063 | 'languageCode' => $field->languageCode, |
|
| 6064 | 'fieldDefIdentifier' => $field->fieldDefIdentifier, |
|
| 6065 | 'fieldTypeIdentifier' => $field->fieldTypeIdentifier, |
|
| 6066 | ) |
|
| 6067 | ); |
|
| 6068 | } |
|
| 6069 | usort( |
|
| 6070 | $normalized, |
|
| 6071 | function ($field1, $field2) { |
|