Skip to content

Commit 25f46d5

Browse files
committed
pass behat with pgsql?
1 parent b26d143 commit 25f46d5

File tree

2 files changed

+8
-3
lines changed

2 files changed

+8
-3
lines changed

classes/local/table/interaction_remaining_table.php

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -82,7 +82,11 @@ public function __construct($uniqueid, $courseids) {
8282
if (count($triggers) > 0) {
8383
$processor = new \tool_lifecycle\processor();
8484
$recordset = $processor->get_course_recordset($triggers);
85-
$this->trigger2courses[$tool->triggerid] = $recordset;
85+
$courses = [];
86+
foreach ($recordset as $element) {
87+
$courses[] = $element->id;
88+
}
89+
$this->trigger2courses[$tool->triggerid] = $courses;
8690
}
8791
}
8892
}
@@ -170,7 +174,7 @@ public function col_tools($row) {
170174
// Check if 'this' course is included in course set.
171175
$found = false;
172176
foreach ($this->trigger2courses[$tool->triggerid] as $element) {
173-
if ($row->courseid === $element->id) {
177+
if ($row->courseid === $element) {
174178
// Course is included in course set of automatic trigger(s).
175179
$found = true;
176180
break;

tests/behat/manual_and_automatic_trigger.feature renamed to tests/behat/trigger_combination.feature

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
@tool @tool_lifecycle @manual_trigger
2-
Feature: Combine triggers with and operation and test view and actions
2+
Feature: Combine triggers with 'and' operation and test view and actions
33

44
Background:
55
Given the following "users" exist:
@@ -31,6 +31,7 @@ Feature: Combine triggers with and operation and test view and actions
3131

3232
@javascript
3333
Scenario: Combine manual trigger with automatic categories trigger (backup and course deletion)
34+
# => category archive is excluded, so course ArchCourse shall not be deleted
3435
Given I log in as "admin"
3536
And I am on workflowdrafts page
3637
And I click on "Create new workflow" "link"

0 commit comments

Comments
 (0)