Help! You should assert that the element Span#dates exist and its count is 1

Tell us what’s happening:
// running tests
You should assert that the element span#dates exist and its count is 1.
// tests completed

console log:
:heavy_check_mark: Submit the surname “Colombo” in the HTML form (1260ms)
:heavy_check_mark: Submit the surname “Vespucci” in the HTML form (273ms)

25 passing (2s)

Your project link(s)

solution: https://replit.com/@javicoro991/boilerplate-mochachai#tests/2_functional-tests.js

Your browser information:

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

Challenge: Run Functional Tests Using a Headless Browser II

Link to the challenge:

Hello there,

This is the example from the previous lesson:

browser.assert.elements('span#dates', 1);

This is what you have:

browser.assert.element('span#dates', 1);

Also, you did not accurately follow the steps in this lesson:

The suiteSetup is not in the correct place, and will likely cause tests to fail.

Hope this helps

1 Like

Thanks!!! :laughing: :star_struck: this was the error : The suiteSetup is not in the correct place, and will likely cause tests to fail.

1 Like

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