-
Functional Test
-
Minor
-
Moodle 4.0
-
None
Note: This test must be carried out with a browser supporting drag and drop (Chrome, Firefox, Safari, Edge)
- As administrator, visit Settings > Site admin > Plugins > Activity modules > Label and verify the box 'media drag and drop' setting is ticked.
- Make a note of the max width and height for dragged and dropped images (default 400).
- As a teacher in a course with the editing turned on, drag an image (.jpg/.png/.gif/.svg) onto the course page. using an image larger than the max dimensions set.
- Verify that you are asked whether you want to add the image to the course page or create a file resource. Choose "add media to course page".
- Verify that the image appears embedded in a label.
- Refresh the page and ensure the image is still embedded.
- Verify the image has been resized to the max dimensions checked in step 2.
- Using the label edit icons, verify that the image can be moved, hidden, modified and deleted.
- As admin, visit Settings > Site admin > plugins > activity modules > label and disable (remove the tick from) the 'media drag and drop' setting.
- Drag and drop another image.
- Verify that this time the image is uploaded immediately as a resource with no offer to add to the course page.
- Repeat the test with other browsers supporting drag and drop.