Proyectos de Subversion Moodle

Rev

Rev 1 | Mostrar el archivo completo | | | Autoría | Ultima modificación | Ver Log |

Rev 1 Rev 11
Línea 27... Línea 27...
27
 */
27
 */
28
class entities_sorter_test extends \advanced_testcase {
28
class entities_sorter_test extends \advanced_testcase {
29
    /**
29
    /**
30
     * Test the entity returns expected values.
30
     * Test the entity returns expected values.
31
     */
31
     */
32
    public function test_entity_sort_into_children() {
32
    public function test_entity_sort_into_children(): void {
33
        $this->resetAfterTest();
33
        $this->resetAfterTest();
34
        $sorter = new sorter_entity(
34
        $sorter = new sorter_entity(
35
            function($entity) {
35
            function($entity) {
36
                return $entity['id'];
36
                return $entity['id'];
37
            },
37
            },
Línea 57... Línea 57...
57
    }
57
    }
Línea 58... Línea 58...
58
 
58
 
59
    /**
59
    /**
60
     * Test the entity returns expected values.
60
     * Test the entity returns expected values.
61
     */
61
     */
62
    public function test_entity_flatten_children() {
62
    public function test_entity_flatten_children(): void {
63
        $this->resetAfterTest();
63
        $this->resetAfterTest();
64
        $sorter = new sorter_entity(
64
        $sorter = new sorter_entity(
65
            function($entity) {
65
            function($entity) {
66
                return $entity['id'];
66
                return $entity['id'];