Remove unnecessary assert messages from testString in curriculum challenges
See original GitHub issueThis issue will serve as a way to track all the work needed to remove the unnecessary assert messages from the yaml testString. For all challenges which only have a text for each testString assert (most of the front-end challenges), we can simply remove the message argument, because the text is used for displaying both in the tests frame and in the fake console.
Any PRs created for this issue will only affect English curriculum files and only change two things:
- Replace existing
textwith assert message argument value if the assert message gives a better test message and remove the assert message argument from thetestString. - When both the
text and the assert message argument values match, just remove the assert message argument from thetestString`.
I have created a script which should capture all of the applicable tests. I will create PRs for only the following sections which are known to not have multiple assert messages in the testString per single text tests. I will limit the number of files per PR to make review easier on GitHub.
At the time of this issue’s creation, there is only one open PR https://github.com/freeCodeCamp/freeCodeCamp/pull/35770 (waiting on final approval before being merged), which will need to have it’s testString assert message arguments reviewed/removed.
- Responsive Web Design - PRs: #36405, #36406, #36407
- JavaScript Algorithms And Data Structures - PRs: #36401, #36402, #36403, #36404
- Front End Libraries - PRs: #36408, #36409
- Data Visualization - PR #36424
- Coding Interview Prep - PRs: #36410, #36412, #36415, #36416, #36417, #36418, #36419, #36420, #36421
Issue Analytics
- State:
- Created 4 years ago
- Comments:13 (13 by maintainers)

Top Related StackOverflow Question
I think the only ones worth looking at all are the ones without solutions. If they have solutions
npm run testwill complain if the syntax is wrong or they suddenly start giving the wrong answers.It is not that they are errors. It is just that they would not be removed (which does not hurt anything).