diff --git a/client/src/templates/Challenges/components/test-suite.css b/client/src/templates/Challenges/components/test-suite.css index c75947094e..cdb38ac9be 100644 --- a/client/src/templates/Challenges/components/test-suite.css +++ b/client/src/templates/Challenges/components/test-suite.css @@ -19,6 +19,10 @@ padding: 5px 10px; } +.test-output p { + margin: 0; +} + .test-status-icon { display: flex; align-items: center; diff --git a/tools/challenge-md-parser/__snapshots__/tests-to-data.test.js.snap b/tools/challenge-md-parser/__snapshots__/tests-to-data.test.js.snap index 500209cb91..4ddbb5c4d9 100644 --- a/tools/challenge-md-parser/__snapshots__/tests-to-data.test.js.snap +++ b/tools/challenge-md-parser/__snapshots__/tests-to-data.test.js.snap @@ -5,7 +5,7 @@ Object { "tests": Array [ Object { "testString": "assert.isTrue((/hello(\\\\s)+world/gi).test($('h1').text()), 'Your h1 element should have the text \\"Hello World\\".');", - "text": "Your h1 element should have the text \\"Hello World\\".", + "text": "

Your h1 element should have the text \\"Hello World\\".

", }, ], } diff --git a/tools/challenge-md-parser/tests-to-data.js b/tools/challenge-md-parser/tests-to-data.js index a22072c2c4..06c8388efc 100644 --- a/tools/challenge-md-parser/tests-to-data.js +++ b/tools/challenge-md-parser/tests-to-data.js @@ -34,6 +34,12 @@ function plugin() { ); tests.question.text = mdToHTML(tests.question.text); } + if (tests.tests) { + tests.tests = tests.tests.map(({ text, testString }) => ({ + text: mdToHTML(text), + testString + })); + } file.data = { ...file.data, ...tests