From 99b5a99e64ddf3f16ec0908cfcf4cf56b6cb75cd Mon Sep 17 00:00:00 2001 From: Edmund Farrow <edmund.farrow@ed.ac.uk> Date: Thu, 18 Jul 2024 14:59:48 +0100 Subject: [PATCH] default-test - Use same text for API --- api/controller/TestController.php | 2 +- api/public/bulktest.php | 2 +- lang/en/qtype_stack.php | 2 -- 3 files changed, 2 insertions(+), 4 deletions(-) diff --git a/api/controller/TestController.php b/api/controller/TestController.php index ccf2ad7c1..1f60dada4 100644 --- a/api/controller/TestController.php +++ b/api/controller/TestController.php @@ -194,7 +194,7 @@ class TestController { $passes = 1; } else { $fails = 1; - $message = stack_string('default_test_fail'); + $message = stack_string('defaulttestfail'); } } diff --git a/api/public/bulktest.php b/api/public/bulktest.php index 08c1b84e6..a50e7f4b4 100644 --- a/api/public/bulktest.php +++ b/api/public/bulktest.php @@ -160,7 +160,7 @@ require_login(); } } if (!json.istests && json.results[seed].passes == 1) { - resultHtml += '<p class="feedback passed">' + '<?php echo stack_string('default_test_pass')?>' + '</p>'; + resultHtml += '<p class="feedback passed">' + '<?php echo stack_string('defaulttestpass')?>' + '</p>'; } // Display seed level messages - will be exceptions. if (json.results[seed].messages) { diff --git a/lang/en/qtype_stack.php b/lang/en/qtype_stack.php index 7265141ba..072b01484 100644 --- a/lang/en/qtype_stack.php +++ b/lang/en/qtype_stack.php @@ -1530,8 +1530,6 @@ $string['castext_error_unevaluated'] = 'This text content was never evaluated.'; -$string['default_test_fail'] = 'Default test using the model answers does not return a score of 1.'; -$string['default_test_pass'] = 'Default test using the model answers returns a score of 1.'; // API strings. $string['api_choose_file'] = 'Please select a question file'; $string['api_choose_folder'] = 'Choose a STACK folder'; -- GitLab