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