Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Broken Tests on challenge Basic CSS: Use Attribute Selectors to Style Elements #38329

Closed
svjmtn opened this issue Mar 7, 2020 · 10 comments · Fixed by #38330
Closed

Broken Tests on challenge Basic CSS: Use Attribute Selectors to Style Elements #38329

svjmtn opened this issue Mar 7, 2020 · 10 comments · Fixed by #38330
Labels
scope: curriculum Lessons, Challenges, Projects and other Curricular Content in curriculum directory.

Comments

@svjmtn
Copy link

svjmtn commented Mar 7, 2020

Describe your problem and how to reproduce it:
This is expected to work, and it works in the preview.
There is a space before and after the = symbol.

  [type = 'checkbox'] {
    margin-top: 10px;
    margin-bottom: 15px;
  }

It fails tests with this error, although it is expected to pass.

// running tests
The type attribute selector should be used to select the checkboxes.

The same code without the spaces passes.

Add a Link to the page with the problem:
https://www.freecodecamp.org/learn/responsive-web-design/basic-css/use-attribute-selectors-to-style-elements

Tell us about your browser and operating system:

  • Browser Name: Google Chrome
  • Browser Version: 79.0.3945.130
  • Operating System: Fedora 31

If possible, add a screenshot here (you can drag and drop, png, jpg, gif, etc. in this box):

@svjmtn svjmtn added scope: curriculum Lessons, Challenges, Projects and other Curricular Content in curriculum directory. status: waiting triage This issue needs help from moderators and users to reproduce and confirm its validity and fix. labels Mar 7, 2020
@ShaunSHamilton
Copy link
Member

Whilst I agree there is no reason the tests should not pass, I think it is important to note that having space on either side of the = is not good syntax, and could cause issue with integration with SASS. HTML is just so forgiving.
https://developer.mozilla.org/en-US/docs/Web/CSS/Attribute_selectors

@svjmtn
Copy link
Author

svjmtn commented Mar 10, 2020

Oh, I didn't know that wasn't good practice. It would be nice if it was mentioned in the lesson. I agree, if it's not good practice then, it would be best to fail the test and mention such an error message.

@moT01
Copy link
Member

moT01 commented Mar 11, 2020

I don't think it's necessary to point out the best practices here. This is the basic css section so if it's valid css, it should pass the tests. I think just adjusting the one test would be enough. Here's the file

@moT01 moT01 added first timers only Open for anyone doing contributions for first time. You do not need permission to work on these. help wanted Open for all. You do not need permission to work on these. and removed status: waiting triage This issue needs help from moderators and users to reproduce and confirm its validity and fix. labels Mar 26, 2020
@jaredwils
Copy link
Contributor

could I possibly work on this issue?

@moT01
Copy link
Member

moT01 commented Mar 31, 2020

go for it @jaredwils

jaredwils added a commit to jaredwils/freeCodeCamp that referenced this issue Apr 19, 2020
…heckbox' to allow a coorect answer (freeCodeCamp#38329)

Co-Authored-By: Denice Veluz <deniceysis.veluz20@myhunter.cuny.edu>
@kshashwat007
Copy link

Hi, Wanted to ask if its possible to work on this issue?

@ahmaxed
Copy link
Member

ahmaxed commented Jun 8, 2020

@kshashwat007, please go ahead 👍. No assignment is necessary as described in our contribution docs. The first comprehensive PR will be considered for review.

@moT01 moT01 added status: fix in progress and removed first timers only Open for anyone doing contributions for first time. You do not need permission to work on these. help wanted Open for all. You do not need permission to work on these. labels Jun 8, 2020
@moT01
Copy link
Member

moT01 commented Jun 8, 2020

There's an actually an open PR to fix this @kshashwat007. I would look for another issue.

@FiberesimaJoseph

This comment has been minimized.

@Gabriel-J3sus

This comment has been minimized.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
scope: curriculum Lessons, Challenges, Projects and other Curricular Content in curriculum directory.
Projects
None yet
8 participants