Merge pull request #3916 from dpalou/MOBILE-4173

MOBILE-4173 behat: Don't hardcode webserver in embedded PDF test
main
Noel De Martin 2024-01-31 11:34:27 +01:00 committed by GitHub
commit a8ffee0010
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
1 changed files with 2 additions and 3 deletions

View File

@ -59,13 +59,12 @@ Feature: It opens files properly.
Then I should find "This file may not work as expected on this device" in the app
Scenario: Open a PDF embedded using an iframe
# Using http://webserver directly because $WWWROOT cannot be used in generators or when creating the page manually.
Given the following "activities" exist:
| activity | idnumber | course | name | content |
| page | page1 | C1 | Page with embedded PDF | <iframe src="http://webserver/local/moodleappbehat/fixtures/dummy.pdf" width="100%" height="500"></iframe> |
| page | page1 | C1 | Page with embedded PDF | <iframe src="#wwwroot#/local/moodleappbehat/fixtures/dummy.pdf" width="100%" height="500"></iframe> |
| page | page2 | C1 | Page with embedded web | <iframe src="https://moodle.org" width="100%" height="500" data-open-external="true"></iframe> |
And the following config values are set as admin:
| custommenuitems | PDF item\|http://webserver/local/moodleappbehat/fixtures/dummy.pdf\|embedded | tool_mobile |
| custommenuitems | PDF item\|#wwwroot#/local/moodleappbehat/fixtures/dummy.pdf\|embedded | tool_mobile |
And I entered the course "Course 1" as "student1" in the app
When I press "Page with embedded PDF" in the app