MDL-66999 theme_boost: @extend phpunit fixes
authorBas Brands <bas@moodle.com>
Wed, 27 Nov 2019 12:38:09 +0000 (13:38 +0100)
committerBas Brands <bas@moodle.com>
Thu, 12 Dec 2019 10:27:59 +0000 (11:27 +0100)
question/behaviour/adaptive/tests/mark_display_test.php

index 738d5ac..5a91a25 100644 (file)
@@ -58,7 +58,7 @@ class qbehaviour_adaptive_mark_display_test extends basic_testcase {
     }
 
     public function test_correct_no_penalty() {
-        $this->assertEquals('<div class="correctness correct">' . get_string('correct', 'question') . '</div>' .
+        $this->assertEquals('<div class="correctness badge correct">' . get_string('correct', 'question') . '</div>' .
                 '<div class="gradingdetails">' .
                 get_string('gradingdetails', 'qbehaviour_adaptive',
                         array('cur' => '1.00', 'raw' => '1.00', 'max' => '1.00')) . '</div>',
@@ -67,8 +67,8 @@ class qbehaviour_adaptive_mark_display_test extends basic_testcase {
     }
 
     public function test_partial_first_try() {
-        $this->assertEquals('<div class="correctness partiallycorrect">' . get_string('partiallycorrect', 'question') . '</div>' .
-                '<div class="gradingdetails">' .
+        $this->assertEquals('<div class="correctness badge partiallycorrect">' . get_string('partiallycorrect', 'question') .
+                '</div><div class="gradingdetails">' .
                 get_string('gradingdetails', 'qbehaviour_adaptive',
                         array('cur' => '0.50', 'raw' => '0.50', 'max' => '1.00')) . ' ' .
                 get_string('gradingdetailspenalty', 'qbehaviour_adaptive', '0.10') . '</div>',
@@ -78,8 +78,8 @@ class qbehaviour_adaptive_mark_display_test extends basic_testcase {
 
     public function test_partial_second_try() {
         $mark = array('cur' => '0.80', 'raw' => '0.90', 'max' => '1.00');
-        $this->assertEquals('<div class="correctness partiallycorrect">' . get_string('partiallycorrect', 'question') . '</div>' .
-                '<div class="gradingdetails">' .
+        $this->assertEquals('<div class="correctness badge partiallycorrect">' . get_string('partiallycorrect', 'question') .
+                '</div><div class="gradingdetails">' .
                 get_string('gradingdetails', 'qbehaviour_adaptive', $mark) . ' ' .
                 get_string('gradingdetailsadjustment', 'qbehaviour_adaptive', $mark) . ' ' .
                 get_string('gradingdetailspenalty', 'qbehaviour_adaptive', '0.10') . ' ' .
@@ -90,8 +90,8 @@ class qbehaviour_adaptive_mark_display_test extends basic_testcase {
 
     public function test_correct_third_try() {
         $mark = array('cur' => '0.80', 'raw' => '1.00', 'max' => '1.00');
-        $this->assertEquals('<div class="correctness partiallycorrect">' . get_string('partiallycorrect', 'question') . '</div>' .
-                '<div class="gradingdetails">' .
+        $this->assertEquals('<div class="correctness badge partiallycorrect">' . get_string('partiallycorrect', 'question') .
+                '</div><div class="gradingdetails">' .
                 get_string('gradingdetails', 'qbehaviour_adaptive', $mark) . ' ' .
                 get_string('gradingdetailsadjustment', 'qbehaviour_adaptive', $mark) . '</div>',
                 $this->renderer->render_adaptive_marks(new qbehaviour_adaptive_mark_details(
@@ -100,8 +100,8 @@ class qbehaviour_adaptive_mark_display_test extends basic_testcase {
 
     public function test_correct_third_try_if_we_dont_increase_penalties_for_wrong() {
         $mark = array('cur' => '0.80', 'raw' => '1.00', 'max' => '1.00');
-        $this->assertEquals('<div class="correctness partiallycorrect">' . get_string('partiallycorrect', 'question') . '</div>' .
-                '<div class="gradingdetails">' .
+        $this->assertEquals('<div class="correctness badge partiallycorrect">' . get_string('partiallycorrect', 'question') .
+                '</div><div class="gradingdetails">' .
                 get_string('gradingdetails', 'qbehaviour_adaptive', $mark) . ' ' .
                 get_string('gradingdetailsadjustment', 'qbehaviour_adaptive', $mark) . '</div>',
                 $this->renderer->render_adaptive_marks(new qbehaviour_adaptive_mark_details(