'alveolata', 'sections' => [ [ 'name' => 'structures', 'sections' => [ [ 'name' => 'list', 'sections' => [ [ 'name' => 'map', 'cases' => [ [ 'name' => 'positive', 'procedure' => function ($assert) { $subject = \alveolata\structures\list_make([2,3,5,7]); $result_actual = \alveolata\structures\list_map($subject, function ($x) {return ($x * 2);}); $result_expected = \alveolata\structures\list_make([4,6,10,14]); $assert->equal( \alveolata\structures\list_collate( function ($x, $y) {return ($x === $y);}, $result_actual, $result_expected ), true ); } ], [ 'name' => 'negative_length', 'procedure' => function ($assert) { $subject = \alveolata\structures\list_make([2,3,5,7]); $result_actual = \alveolata\structures\list_map($subject, function ($x) {return ($x * 2);}); $result_expected = \alveolata\structures\list_make([4,6,10]); $assert->equal( \alveolata\structures\list_collate( function ($x, $y) {return ($x === $y);}, $result_actual, $result_expected ), false ); } ], [ 'name' => 'negative_element', 'procedure' => function ($assert) { $subject = \alveolata\structures\list_make([2,3,5,7]); $result_actual = \alveolata\structures\list_map($subject, function ($x) {return ($x * 2);}); $result_expected = \alveolata\structures\list_make([4,6,9,14]); $assert->equal( \alveolata\structures\list_collate( function ($x, $y) {return ($x === $y);}, $result_actual, $result_expected ), false ); } ], ] ], ] ], ] ] ] ] );