CodePen Test Suite Question

Hi All,
I’m enjoying the new challenges for Responsive Web Design.

I ran it on CodePen with the Test Suite and it gave me Green X - I passed yes?

But it said 15/17. There are only 16 User Stories - what did I miss?

Is it possible to find what is missing on our projects? Even though I passed, I thought did all of the user stories.

Are there other criteria that I was not aware of?

Thank you in advance…

My Survey Form is at

click on the red “Tests 15/17” button and it will show you a full report.
You failed the “If I enter an email that is not formatted correctly, I will see an HTML5 validation error.” and you failed the “Inside the form element, I am presented with a button with id=“submit” to submit all my inputs”.

hope this helps.

Thank you. I did look there.

I have the html5 markup a in html lines 21 - 22 as:
“label id=“email-label” class=“col-form-label” for=“email-label”>Email Address * "
“input type=“text” id=“email” placeholder=” There will be no spam” required /"

I have the button with id=“submit” in line 101 of html:
“button type=“button” id=“submit” class=“btn btn-info” data-toggle=“modal” data-target=”#koniModal"> Submit "

Can you please tell me where I went wrong?

Hi you should try with type = " submit" rather than a type = “button” and if it still dont solve your problem try with input markup rather than a button

the first error details say:
AssertionError: Email field should be HTML5 validated : expected ‘text’ to equal ‘email’

so it is saying that instead of type=“text” the unit test was expecting “email”

looking at the detail for the second error we see:
AssertionError: Your button’s type attribute should have a value of “submit” : expected ‘button’ to equal ‘submit’

So @dexter_dhiraz was correct.
Consider this a good exercise for you to learn how to read error messages and attempt to handle them. Hope this helps.

1 Like

Thank you both so much!

Yes, I now pass at 100%. But what was the 17th test when there were only 16 User Stories?

And yes, it is good practice on fixing these errors.

It counts as 17 because there are 16 Content tests plus 1 Technology Stack test. (take a closer look at the report…)
Way to go on passing them all!

I will take a closer look.

Thank you :slight_smile: