Add a default sr-only section heading in order to prevent having an
empty heading for the quiz section which is not good for accessibility.
Plus:
- There's also an existing issue where filters are never applied to
section headings on load. This has been fixed in this commit as well.
- Button role added for the edit section button which enables it to
take advantage of the theme highlighting when it receives focus.
I thought about renaming the class to just plain attempt, but I
acutally think quiz_attempt makes it clearer what this is. Also
not changing the name massively reduces the pain for everyone
updating their code (including me right now!)
Code should just directly use moodle_execption.
Note, some of the existing uses (in web services) were passing a
literal message, not a language string identifier, but I decided
now was not the time to try to fix that.
Webservice doesn't need to set the page URL. Hence,
any function that requires a page URL will raise debugging output.
The patch fixes it by adding a fake URL for the webservice.
The patch also removed assertDebuggingCalled because it is no longer needed.
* As a student I should only be able to access the next question or the current question
* The API should not show more than the current question
* Once the quiz is previewed we can see the question in any order (existing behaviour)
* Related to ticket MDL-71728
Co-authored-by: Rajneel Totaram <rjnlfj@yahoo.com>
Co-authored-by: Tim Hunt <t.j.hunt@open.ac.uk>
Secondary nav previously had to be in my_plugin\local\views\secondary; this
location continues to work but is deprecated. The new location is
my_plugin\navigation\views\secondary.
This got lost in the 4.0 question bank work.
We are trying to phase out qtype_random, that is where the old
code and lang strings for describing random questions is, so
OK to add back a call to it. When we get better qbank filtering
we can replace this again.
Note, the asserts in the Behat were copied from my 3.11, checkout,
to really verify we are restoring the previous behaviour.
I think that, because how PHP works, the MDL-74255 bug (lack
of explode) generally does not break anything, which is why
no tests failed. Still. Good to fix.