Commit graph

99780 commits

Author SHA1 Message Date
Andrew Nicols
d5ff729197 MDL-70734 behat: Increase the WebDriver Curl timeout 2021-02-01 09:49:54 +08:00
Víctor Déniz
fb9419ec0b weekly release 3.11dev 2021-01-29 17:12:59 +00:00
Víctor Déniz
01af47f95d Merge branch 'install_311_STABLE' of https://git.in.moodle.com/amosbot/moodle-install into MOODLE_311_STABLE 2021-01-29 17:12:54 +00:00
Jake Dallimore
1cca977486 Merge branch 'MDL-66979-311-7' of git://github.com/andrewnicols/moodle into MOODLE_311_STABLE 2021-01-29 15:43:14 +08:00
Andrew Nicols
5a706a506c MDL-66979 behat: Mark some tests as being slow
Uses of the httpsreplace and customlang tools are known to be extremely
slow.

In our CI infrastructure on slwoer DBs, the customlang tool can take
over 90 seconds to load the page, whilst the httpsreplace tool can take
up to about 60 seconds.

These changes set appropriate timeout factors to increase the timeout
accordingly.
2021-01-29 14:18:51 +08:00
Andrew Nicols
3d89a661df MDL-66979 behat: Add a step to set a timeout factor for a test 2021-01-29 14:18:51 +08:00
Eloy Lafuente (stronk7)
909f1d7203 MDL-66979 behat: Goutte driver doesn't implement setTimeouts()
Also, change:

get_real_timeout(30000)

to:

get_real_timeout(30) * 1000

because the original functions are defined to use seconds, and
having the 1000 around will help us detecting cases in the case
of a hypothetical review of uses.
2021-01-29 14:18:45 +08:00
AMOS bot
39e785e4b0 Automatically generated installer lang files 2021-01-29 00:07:30 +00:00
Eloy Lafuente (stronk7)
01fd844e94 MDL-66979 behat: Goutte driver doesn't implement setTimeouts()
Also, change:

get_real_timeout(30000)

to:

get_real_timeout(30) * 1000

because the original functions are defined to use seconds, and
having the 1000 around will help us detecting cases in the case
of a hypothetical review of uses.
2021-01-28 17:12:05 +01:00
Eloy Lafuente (stronk7)
dc7b085229 Merge branch 'MDL-66979-311-7' of git://github.com/andrewnicols/moodle into MOODLE_311_STABLE 2021-01-28 09:08:53 +01:00
Andrew Nicols
e631b8c5e1 MDL-66979 behat: Set script timeout with timeout factor 2021-01-28 15:27:49 +08:00
Andrew Nicols
ec9bb74405 MDL-66979 behat: Correct selenium2 reference in config-dist 2021-01-28 15:08:10 +08:00
Andrew Nicols
7cff15dc4d MDL-66979 behat: Handle driver stop failure properly
An case was found where the webdriver stop() call could fail in an
AfterScenario hook, leading to a complete rerun if no other errors were
experienced.
2021-01-28 15:07:52 +08:00
Jun Pataleta
67ddc3a9a2 Merge branch 'MDL-70444-dashboard-reset-progress-311' of https://github.com/Peterburnett/moodle into MOODLE_311_STABLE 2021-01-28 09:53:56 +08:00
Andrew Nicols
0911cc0b1e Merge branch 'MDL-70048-311' of git://github.com/peterRd/moodle into MOODLE_311_STABLE 2021-01-28 08:04:22 +08:00
Peter Dias
384d1874ac MDL-70048 dropbox: Augmented unit tests to account for additional params 2021-01-28 07:32:20 +08:00
Peter Dias
0cc373fca6 MDL-70048 dropbox: Update the dropbox search URL.
- Update fetch_dropbox_data to allow different result nodes and version
- Update search to the new URL with new params
- Update the get entities function to account for the change in structure.
2021-01-28 07:32:20 +08:00
Víctor Déniz
40f7439381 Merge branch 'MDL-69816-311' of git://github.com/paulholden/moodle into MOODLE_311_STABLE 2021-01-27 18:23:12 +00:00
Víctor Déniz
c1f4d038d4 Merge branch 'MDL-70585-311' of git://github.com/paulholden/moodle into MOODLE_311_STABLE 2021-01-27 10:21:00 +00:00
AMOS bot
8194b3151c Automatically generated installer lang files 2021-01-27 00:07:30 +00:00
Eloy Lafuente (stronk7)
cdb14d91f7 Merge branch 'MDL-66979-311-7' of git://github.com/andrewnicols/moodle into MOODLE_311_STABLE 2021-01-26 22:44:11 +01:00
Víctor Déniz
d3e82b7640 Merge branch 'MDL-70528-311' of git://github.com/ilyatregubov/moodle into MOODLE_311_STABLE 2021-01-26 14:05:22 +00:00
Ilya Tregubov
f283de3d3e MDL-70528 h5pactivity: Fix block can't be added to h5pactivity page. 2021-01-26 15:44:26 +02:00
Víctor Déniz
88bb658169 Merge branch 'MDL-65135-311' of https://github.com/paulholden/moodle into MOODLE_311_STABLE 2021-01-25 15:06:00 +00:00
Peter Burnett
81b25fc274 MDL-70444 my: Improved robustness of bulk dashboard reset 2021-01-25 13:55:41 +10:00
Adrian Greeve
54b81d0f32 Merge branch 'MOODLE_311_MDL-69631-v3' of https://github.com/golenkovm/moodle into MOODLE_311_STABLE 2021-01-25 08:14:43 +08:00
Andrew Nicols
0bac7faf90 MDL-66979 behat: Warn about old behat.yml file location 2021-01-23 20:44:23 +08:00
AMOS bot
6dd97088db Automatically generated installer lang files 2021-01-23 00:07:28 +00:00
Paul Holden
4b01d3bea0 MDL-70585 course: deeper clean of path names in course export.
This fixes an issue on those systems that don't fully support unicode
characters within zip structures, which subsequently led to broken
links when browsing downloaded course content.
2021-01-22 08:15:25 +00:00
Andrew Nicols
19db0c4b44 MDL-66979 behat: Rename and warn on old config 2021-01-22 14:52:19 +08:00
Andrew Nicols
dd4693ac0c MDL-66979 behat: Uncomment step disabled for old firefox 2021-01-22 14:52:18 +08:00
Andrew Nicols
6704b2b5a4 MDL-66979 behat: Pad messaging drawer
This works around an issue highlighted by MDL-70411 whereby some of the
messaging links are covered by the scrollbar in Firefox on MacOS.
2021-01-22 14:52:18 +08:00
Andrew Nicols
d467f87bd7 MDL-66979 behat: Work around weird gradebook focus behaviour
I can't expand this one in a sane fashion but the older JS is doing some
weird and wonderful things with focus.

The only way I could get this to behave correctly was to move away from
the field, move back to it, and then move away again. Other combinations
failed in different browsers for different reasons.
2021-01-22 14:52:18 +08:00
Andrew Nicols
0bd971ebc0 MDL-66979 behat: availability field extends textarea
The availability behat field extends the textarea type, and therefore
needs to include this type.
2021-01-22 14:52:18 +08:00
Andrew Nicols
13c2654eb1 MDL-66979 behat: Improve chromeOptions configuration
Simplify the chromeOptions configuration to improve readability.
2021-01-22 14:52:18 +08:00
Andrew Nicols
a85f7f83b9 MDL-66979 question: Improve behat test reliability
Expand all fieldsets rather than individual fieldsets.

This can fail in some situations where the page moves as the first
fieldset opens and HTML transitions take effect. This causes subsequent
fieldsets to move after WebDriver has calculated the click target.
2021-01-22 14:52:18 +08:00
Andrew Nicols
c501f5fa25 MDL-66979 mod_assign: Stop clicking the user filters
Remove the documented hack which was re-opening a popup because it
"closes for some reason". It no longer randomly closes.
2021-01-22 14:52:18 +08:00
Andrew Nicols
3ab052e70d MDL-66979 behat: Switch to generators
These steps were creating content manually in an unnecessary fashion. I
had to debug some issues with features in these areas so took the time
to update them to make use of data generators, which are significantly
faster.
2021-01-22 14:52:18 +08:00
Andrew Nicols
f60b5ea4db MDL-66979 behat: Remove unused var 2021-01-22 14:52:18 +08:00
Andrew Nicols
ac88e330a6 MDL-66979 behat: Whitespace fix 2021-01-22 14:52:18 +08:00
Andrew Nicols
be9e3ebd34 MDL-66979 behat: Remove manually triggered events
Behat should not trigger Synthetic browser events. It is incorrect to do
so as the UI should be used to trigger events correctly.

The W3C WebDriver specification explicitly states when and where these
events will be triggered from (the browser) and therefore there is no
ambiguity and no need to synthetically trigger them from Behat.
2021-01-22 14:52:18 +08:00
Andrew Nicols
74a156c3d0 MDL-66979 group: Replace direct element interaction with steps
The W3C WebDriver leads to faster operation of individual steps which
highlights where WebDriver is moving to a new step faster than the
browser can process it.

The solution here is to use the `execute` function to interact with the
browsers as this makes use of the various wait and check steps.
2021-01-22 14:52:17 +08:00
Andrew Nicols
2c967d8d07 MDL-66979 behat: Remove unnecessary steps which fail
These steps were completely pointless and were failing with the W3C
Webdriver becuase focus was never on the Update Profile button in the
first place.

At a minimum we should remove the Focus change step as it not valid, but
the following step is also pointless.
2021-01-22 14:52:17 +08:00
Andrew Nicols
d2ceac9d3d MDL-66979 scorm: Increase behat window size
On Firefox there can be some issues with ensuring that all nodes are
visible in order to click them.

This is likely an upstream geckodriver bug and not one that can be
easily addressed across all of Moodle.

In this instance the "Next" button is just outside the Visible Window,
but it is in an iFrame which is fully visible. In this situation
Firefox is unable to click the button but does not error.
2021-01-22 14:52:17 +08:00
Andrew Nicols
45b0f89d87 MDL-66979 behat: Scroll nodes into view before hover
The W3C Specification does not require that a NodeElement be in the
current viewport before triggering a mouseOver. As a result the
mouseOver will generate an Exception because the element is not in the
viewport, and the X/Y co-ordinates are invalid.

To handle this the node is scrolled into view.
2021-01-22 14:52:17 +08:00
Andrew Nicols
a6512819b3 MDL-66979 behat: Fix window switching
Normalise switching of window contexts by setting the main window name
to a null.

Where the window has no name (null/empty), then the root context is
selected.
2021-01-22 14:52:17 +08:00
Andrew Nicols
740c2e80d8 MDL-66979 behat: Use tab to blur current focus
The focus should be on something, rather than removed.

The way in which focus removal works can lead to side effects.
2021-01-22 14:52:17 +08:00
Andrew Nicols
44d9f77cae MDL-66979 behat: Update passwordunmask form field control
Update the passwordunmask form field type for behat to interact with the
form element as a human would rather than via synthetic event triggers.
2021-01-22 14:52:17 +08:00
Andrew Nicols
076ec2766f MDL-66979 behat: iFrames must have a name for switchTo
The W3C WebDriver protocol supports switching of contexts using a named
context, and not the class asscoiated with that context.
2021-01-22 14:52:17 +08:00
Andrew Nicols
eb03e5c7b7 MDL-66979 mod_data: Improve behat chart data step
Charts data visibility is more reliable when checked via the
aria-expanded attribute.

The isVisible attribute can cause some failures under Firefox.
2021-01-22 14:52:17 +08:00