-
Notifications
You must be signed in to change notification settings - Fork 1.2k
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
test(docs): improve style guide URL path test #641
Merged
Merged
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
shawnbot
changed the title
docs: improve URL style guide URL path test
docs: improve style guide URL path test
Jan 9, 2019
shawnbot
changed the title
docs: improve style guide URL path test
tests: improve style guide URL path test
Jan 9, 2019
shawnbot
changed the title
tests: improve style guide URL path test
test: improve style guide URL path test
Jan 9, 2019
shawnbot
changed the title
test: improve style guide URL path test
test(docs): improve style guide URL path test
Jan 9, 2019
This comment has been minimized.
This comment has been minimized.
jonrohan
approved these changes
Jan 9, 2019
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks ok to me
This was referenced Dec 13, 2022
This was referenced Dec 19, 2022
This was referenced Dec 27, 2022
This was referenced Jan 3, 2023
This was referenced Jan 10, 2023
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
This refactors our docs site
test
command to more intelligently list the Primer-specific paths from the Style Guide site with the ones in ourpages/css
directory.In a nutshell: Rather than hacking together a path list with the
file
command, there is a Node script that looks at a list of paths committed tobefore.txt
(or, if running locally, it looks for agithub/styleguide
checkout, builds the site, and generates a newbefore.txt
from the list of built paths — and compares it to the list of "pages" inpages/css
. The test script fails if there are paths in the former that don't exist in the latter, and which aren't accounted for by any "exceptions" (see below).Exceptions
Because we're changing some URLs, there are bound to be paths that don't match up. I thought it'd be good to explicitly list these in a way that's easy to understand, is testable, and helps us add the correct redirects from the styleguide when we're ready to decommission it. The
exceptions
object indocs/test/urls.js
does this, e.g. to account for the status key move in #635:This could be read as:
Once this PR passes CI, I think it's fair to say that we've accounted for most of the Primer pages in the style guide and "documented" any that aren't going to exist in the new site, checking off a bunch of boxes in #628. 🎉