Skip to content

Commit

Permalink
Update unit test case.
Browse files Browse the repository at this point in the history
  • Loading branch information
sangwinc committed Oct 29, 2023
1 parent f90ae20 commit 3353689
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 3 deletions.
6 changes: 3 additions & 3 deletions tests/helper.php
Original file line number Diff line number Diff line change
Expand Up @@ -3403,10 +3403,10 @@ public static function make_stack_question_lang_blocks() {
$q->questionvariables = "pt:5;ta2:(x-pt)^2";

$q->questiontext = '[[lang code="en,other"]] Give an example of a function \(f(x)\) with a stationary point ' .
'at \(x={@pt@}\).[/lang]][[lang code="da"]] Giv et eksempel på en funktion \(f(x)\) med et stationært ' .
'punkt ved \(x={@pt@}\). [[/lang]] [[input:ans1]][[validation:ans1]]';
'at \(x={@pt@}\).[[/lang]][[lang code="da"]] Giv et eksempel på en funktion \(f(x)\) med et stationært ' .
'punkt ved \(x={@pt@}\). [[/lang]] [[input:ans1]][[validation:ans1]][[feedback:prt1]]';

$q->specificfeedback = '[[feedback:prt1]]';
$q->specificfeedback = '';
$q->penalty = 0.35; // Non-zero and not the default.

$q->inputs['ans1'] = stack_input_factory::make(
Expand Down
2 changes: 2 additions & 0 deletions tests/walkthrough_adaptive_test.php
Original file line number Diff line number Diff line change
Expand Up @@ -4022,7 +4022,9 @@ public function test_lang_blocks_en() {
$this->check_current_state(question_state::$todo);
$this->check_current_mark(0);
$this->check_prt_score('prt1', 0.0, 0.35);
$this->check_response_summary('Seed: 1; ans1: x^3 [score]; prt1: # = 0 | prt1-1-F');
$this->check_answer_note('prt1', 'prt1-1-F');
$this->render();
$this->check_current_output(
new question_pattern_expectation('/Give an example of a function/'),
new question_pattern_expectation('/However, in your answer/'),
Expand Down

0 comments on commit 3353689

Please sign in to comment.