Technical Documentation Page tests

My code works on my local lamp, but I can’t seem to figure out exactly what is being asked.
this is the error I get when I run the tests.

  1. Each element with the class of “main-section” should also have an id comprised of the innerText contained within it, with underscores in place of spaces. The id may include special characters if there are special characters in the respective innerText. (e.g. The that contains the header, “JavaScript & Java”, should have a corresponding id="JavaScript_&Java").
    Some “main-section” elements are missing the following ids (don’t forget to replace spaces with underscores!) : IF…ELSE_STATEMENT,WHILE
    (CONDITION)STATEMENT,FUNCTION_DECLARATIONS : expected 3 to equal 0
    AssertionError: Some “main-section” elements are missing the following ids (don’t forget to replace spaces with underscores!) : IF…ELSE_STATEMENT,WHILE
    (CONDITION)_STATEMENT,FUNCTION_DECLARATIONS : expected 3 to equal 0
    at Proxy.c (https://cdn.freecodecamp.org/testable-projects-fcc/v1/bundle.js:549:1881)

Here’s my code as it stands now.

this doesn’t seem something that requires support

I a moving your thread to #curriculum-help:certification-projects

Some "main-section" elements are missing the following ids (don't forget to replace spaces with underscores!) : IF...ELSE_STATEMENT,WHILE_(CONDITION)_STATEMENT,FUNCTION_DECLARATIONS

your code for these sections:


 <section class="main-section"  id="if...else">
            <header>
              if...else statement
            </header>

<section class="main-section" id="Whie_(conditon)_statement" >
                <header>
                  while (condition) statement
                </header>

              <section class="main-section" id="Functions_declarations" >
                <header >
                  Function declarations
                </header>

OK, Thank You.

The error message had me confused. Seemed like I was supposed to use Javascript_&_Java which I tried.

I originally had it all working using my own id’s, didn’t read the instructions close enough.

again thank you.

Sorry new to Free Code Camp and didn’t find the right catagory.

1 Like