Proyectos de Subversion Moodle

Rev

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

Rev 1 Rev 11
Línea 28... Línea 28...
28
 */
28
 */
29
class legacy_polyfill_test extends \advanced_testcase {
29
class legacy_polyfill_test extends \advanced_testcase {
30
    /**
30
    /**
31
     * Test that the core_grading\privacy\legacy_polyfill works and that the static _export_gradingform_instance_data can be called.
31
     * Test that the core_grading\privacy\legacy_polyfill works and that the static _export_gradingform_instance_data can be called.
32
     */
32
     */
33
    public function test_export_gradingform_instance_data() {
33
    public function test_export_gradingform_instance_data(): void {
34
        $context = \context_system::instance();
34
        $context = \context_system::instance();
Línea 35... Línea 35...
35
 
35
 
36
        $mock = $this->createMock(test_gradingform_legacy_polyfill_mock_wrapper::class);
36
        $mock = $this->createMock(test_gradingform_legacy_polyfill_mock_wrapper::class);
37
        $mock->expects($this->once())
37
        $mock->expects($this->once())
Línea 43... Línea 43...
43
    }
43
    }
Línea 44... Línea 44...
44
 
44
 
45
    /**
45
    /**
46
     * Test for _get_metadata shim.
46
     * Test for _get_metadata shim.
47
     */
47
     */
48
    public function test_get_metadata() {
48
    public function test_get_metadata(): void {
49
        $collection = new \core_privacy\local\metadata\collection('core_gradingform');
49
        $collection = new \core_privacy\local\metadata\collection('core_gradingform');
50
        $this->assertSame($collection, test_legacy_polyfill_gradingform_provider::get_metadata($collection));
50
        $this->assertSame($collection, test_legacy_polyfill_gradingform_provider::get_metadata($collection));
Línea 51... Línea 51...
51
    }
51
    }
52
 
52
 
53
    /**
53
    /**
54
     * Test the _delete_gradingform_for_instances shim.
54
     * Test the _delete_gradingform_for_instances shim.
55
     */
55
     */
Línea 56... Línea 56...
56
    public function test_delete_gradingform_for_instances() {
56
    public function test_delete_gradingform_for_instances(): void {
57
        $context = \context_system::instance();
57
        $context = \context_system::instance();
58
 
58