ES6: Create Strings using Template Literals Template strings weren't used but I did!

ES6: Create Strings using Template Literals Template strings weren't used but I did!


As you can see in my code, I have used that Template String thing and successfully create an array containing what it wants but I just can’t pass the test with the error message “Invalid regular expression flags”.

What is going on??? Seriously, after I have proceeded to the ES6 section I kept having those feeling that I want to punch something… God!!!

const result = {
  success: ["max-length", "no-amd", "prefer-arrow-functions"],
  failure: ["no-var", "var-on-top", "linebreak"],
  skipped: ["id-blacklist", "no-dup-keys"]
function makeList(arr) {
  "use strict";

  // change code below this line
  const resultDisplayArray = => `<li class="text-warning">${x}</li>`);
  // change code above this line

  return resultDisplayArray;
 * makeList(result.failure) should return:
 * [ <li class="text-warning">no-var</li>,
 *   <li class="text-warning">var-on-top</li>, 
 *   <li class="text-warning">linebreak</li> ]
const resultDisplayArray = makeList(result.failure);


There is a known bug for the tests of this challenge. Your code is correct, but the tests are broken.


Thank you so much! And then I am so relieved! But is there anything to get my code pass the test???

And there’s another issue when test the answer it won’t react or do nothing unless you make it perfectly like the format in the internet.

So, I figure if there’s a “perfect” format for me to get the answer pass?

Ugh… this won’t make FreeCodeCamp look good if the problem remain unsolved, wish I am knowledgeable enough to help.


Not until the tests are fixed.


As much as I depressed about this fact but I figure if there’s a way for me to see the open source code of this “test” program and see if I can give my idea to assist fixing the bug, even I am still a novice? Thanks again! :slight_smile:


It has already been fixed but the fix hasn’t been integrated to our fcc production environment yet.


hmm… thanks for the reply first but does this mean the whole fcc test system still under construction? meaning a beta version? Still? Or just the whole system is not a beta anymore but require constantly improvement, which is also how modern software system works?

Sorry, for so many question, I have never been into a workplace nor I have the complete and correct understanding of how a software system works. Is that like, first forming the idea, then develop, then put to public, then maintain it forever until it’s out of user?

Anyway, what I have learnt right now is that the whole system contains minor bugs which require constantly fix(am I right?)

So, is there a timeline for the whole work process? Or just up to the timetable of each helpful member? When can I contribute to that? To be helpful, I mean.