Skip to content

Commit

Permalink
MDL-54589 behat: Don't allow floating headers for behat
Browse files Browse the repository at this point in the history
  • Loading branch information
Rajesh Taneja committed Jun 20, 2016
1 parent fba0ac6 commit 6a51c58
Show file tree
Hide file tree
Showing 5 changed files with 18 additions and 5 deletions.
2 changes: 0 additions & 2 deletions grade/report/grader/tests/behat/ajax_grader.feature
Original file line number Diff line number Diff line change
Expand Up @@ -47,8 +47,6 @@ Feature: Using the AJAX grading feature of Grader report to update grades and fe
And the following config values are set as admin:
| grade_report_showaverages | 0 |
| grade_report_enableajax | 1 |
# Floating headers can fail to set value on some OS/Browsers, so do this test on large screens.
And I change window size to "large"

@javascript
Scenario: Use the grader report without editing, with AJAX on and quick feedback off
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -402,6 +402,11 @@ FloatingHeaders.prototype = {
return this;
}

if (M.cfg.behatsiterunning) {
// If the behat site is running we don't want floating elements.
return;
}

// Generate floating elements.
this._setupFloatingUserColumn();
this._setupFloatingUserHeader();
Expand Down

Large diffs are not rendered by default.

Original file line number Diff line number Diff line change
Expand Up @@ -402,6 +402,11 @@ FloatingHeaders.prototype = {
return this;
}

if (M.cfg.behatsiterunning) {
// If the behat site is running we don't want floating elements.
return;
}

// Generate floating elements.
this._setupFloatingUserColumn();
this._setupFloatingUserHeader();
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -259,6 +259,11 @@ FloatingHeaders.prototype = {
return this;
}

if (M.cfg.behatsiterunning) {
// If the behat site is running we don't want floating elements.
return;
}

// Generate floating elements.
this._setupFloatingUserColumn();
this._setupFloatingUserHeader();
Expand Down

0 comments on commit 6a51c58

Please sign in to comment.