mirror of
https://github.com/moodle/moodle.git
synced 2025-01-18 22:08:20 +01:00
MDL-55074 behat: Click on the internal div to ensure driver don't click at wrong node
This commit is contained in:
parent
7f8c9bb852
commit
eb1335c63c
@ -309,9 +309,10 @@ class behat_gradingform_rubric extends behat_base {
|
||||
$levelnode = $this->find('xpath', $selectedlevelxpath);
|
||||
|
||||
// Using in_array() as there are only a few elements.
|
||||
if (!in_array('checked', explode(' ', $levelnode->getAttribute('class')))) {
|
||||
if (!$levelnode->hasClass('checked')) {
|
||||
$levelnodexpath = $selectedlevelxpath . "//div[contains(concat(' ', normalize-space(@class), ' '), ' score ')]";
|
||||
$this->execute('behat_general::i_click_on_in_the',
|
||||
array($selectedlevelxpath, "xpath_element", $this->escape($name), "table_row")
|
||||
array($levelnodexpath, "xpath_element", $this->escape($name), "table_row")
|
||||
);
|
||||
}
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user