Run Functional Tests Using a Headless Browser - validation

Tell us what’s happening:
I have used the suggested format for this exercise all validations pass but project not passing.

My project link is


code is as follows

   // #5
  test('Submit the surname "Colombo" in the HTML form', function (done) {
  browser.fill('surname', 'Colombo').then(() => {
    browser.pressButton('submit', () => {
      browser.assert.text('span#name', 'Cristoforo');
      browser.assert.text('span#surname', 'Colombo');
      browser.assert.elements('span#dates', 1);

Your browser information:

User Agent is: Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/92.0.4515.159 Safari/537.36

Challenge: Run Functional Tests Using a Headless Browser

Link to the challenge:

Any feedback, suggestions or input would be great, thank you

1 Like

Do you have any errors in the node console after starting project and running tests on start?

1 Like

Hello there,

It appears you have not followed this instruction from the previous lesson:

Within tests/2_functional-tests.js , immediately after the Browser declaration, add your project URL to the site property of the variable:

Hope this helps

1 Like


Thank you I went back, reviewed and corrected this setup. I now pass all validations for the browser and seem to be hitting a brick wall with text element. I have reviewed zombie.js assertion notes as well. All seems correct unless I am missing something


1 Like

From the boilerplate, you appear to have deleted this test:

This causes the freeCodeCamp tests to be offset - looking at the 6th test, instead of the 5th:

Hope this helps

Hi, Thank you,

I thought I did not need that section of code, you showed me otherwise.

Thank you for the feedback and assistance.

All complete and both of the last two steps of the challenges have validated and all 25 tests were passed in completion. :laughing: :laughing:

1 Like

This topic was automatically closed 182 days after the last reply. New replies are no longer allowed.