Skip to content

Commit

Permalink
Branch for Moodle 4.3
Browse files Browse the repository at this point in the history
  • Loading branch information
lucaboesch committed Mar 14, 2024
1 parent 4cd91bc commit 12ad081
Show file tree
Hide file tree
Showing 4 changed files with 8 additions and 4 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,7 @@ jobs:

steps:
- name: Checkout
uses: actions/checkout@v3
uses: actions/checkout@v4
with:
path: plugin

Expand Down
2 changes: 2 additions & 0 deletions externallib.php
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,8 @@

namespace mod_questionnaire;

defined('MOODLE_INTERNAL') || die();

require_once($CFG->libdir . '/externallib.php');

use external_api;
Expand Down
4 changes: 2 additions & 2 deletions tests/behat/questionnaire_activity_completion.feature
Original file line number Diff line number Diff line change
Expand Up @@ -108,8 +108,8 @@ Feature: View activity completion information in the questionnaire activity
Then I should see "Are you still in School?"
And I should see "Select one choice"
And I should see "Enter some text"
And I set the field with xpath "//input[@type='radio' and @id='auto-rb0001']" to "1"
And I set the field with xpath "//input[@type='radio' and @id='auto-rb0005']" to "1"
And I set the field "Yes" to "1"
And I set the field "Three" to "1"
And I press "Submit questionnaire"
Then I should see "Thank you for completing this Questionnaire."
And I press "Continue"
Expand Down
4 changes: 3 additions & 1 deletion tests/csvexport_test.php
Original file line number Diff line number Diff line change
Expand Up @@ -90,6 +90,8 @@ public function test_csvexport() {

/**
* Tests the CSV export with identity fields and anonymous questionnaires.
*
* @covers ::csvexport
*/
public function test_csvexport_identity_fields() {
global $DB;
Expand Down Expand Up @@ -148,7 +150,7 @@ private function do_test_csvexport_identity_fields($course, $cm, $user, $roleid,
assign_capability('moodle/site:viewuseridentity', CAP_ALLOW, $roleid, $context);

// Generate CSV output.
$questionnaire = new questionnaire($course, $cm, $item->id);
$questionnaire = new \questionnaire($course, $cm, $item->id);
$output = $questionnaire->generate_csv(0, '', '', 0, 0, 1);

$this->assertNotNull($output);
Expand Down

0 comments on commit 12ad081

Please sign in to comment.