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

Deprecate old test script commands #19893

Merged
merged 7 commits into from Oct 14, 2020

Conversation

@rickhanlonii
Copy link
Member

@rickhanlonii rickhanlonii commented Sep 23, 2020

Overview

These aliases have been replaced with the easier to use arguments like --debug and --prod and the aliases have been proxing to the new commands for awhile now.

Deprecating the aliases now to give people a chance to use the new commands directly before removing them later.

"test-build-devtools": "yarn test --build --project devtools",
"debug-test-build-devtools": "yarn test --debug --build --project devtools",
"debug-test-build-devtools": "yarn test --deprecated 'yarn test-build-devtools --debug'",

This comment has been minimized.

@rickhanlonii

rickhanlonii Sep 23, 2020
Author Member

In the end we'll have three base test commands:

  • test
  • test-www
  • test-build-devtools

This comment has been minimized.

@rickhanlonii

rickhanlonii Sep 23, 2020
Author Member

Well, we already only have three commands since the aliases proxy to them.

@codesandbox
Copy link

@codesandbox codesandbox bot commented Sep 23, 2020

This pull request is automatically built and testable in CodeSandbox.

To see build info of the built libraries, click here or the icon next to each commit SHA.

Latest deployment of this branch, based on commit 5229225:

Sandbox Source
React Configuration
Copy link
Member

@gaearon gaearon left a comment

Do we reference the old commands anywhere in the docs or PR template?

@sizebot
Copy link

@sizebot sizebot commented Sep 23, 2020

No significant bundle size changes to report.

Size changes (stable)

Generated by 🚫 dangerJS against 5229225

@sizebot
Copy link

@sizebot sizebot commented Sep 23, 2020

No significant bundle size changes to report.

Size changes (experimental)

Generated by 🚫 dangerJS against 5229225

@rickhanlonii
Copy link
Member Author

@rickhanlonii rickhanlonii commented Sep 23, 2020

@gaearon good thinking, updated the reference in this repo and I'll follow up with the changes to the website here.

@sebmarkbage
Copy link
Member

@sebmarkbage sebmarkbage commented Sep 23, 2020

Please update the CI command names. They should represent the command you have to run to repro the test failure. Although not sure how you’d tell someone to put a double dash.

Copy link
Member

@sebmarkbage sebmarkbage left a comment

Tbh this is a lot less discoverable (if we actually remove them). I always go to package JSON files in projects to find all the commands I might need to run.

Where is a single list of commands I need to run now?

@rickhanlonii
Copy link
Member Author

@rickhanlonii rickhanlonii commented Sep 23, 2020

Note that the only thing that's really changing between the aliases and the new commands is that --debug, --prod, --build and --variant are now options for each command instead of listing a subset of all permutations of the commands.

So instead of test, test-build, test-prod, and test-build-prod it's test [--build] [--prod]. The goal is to makes it easier to do what you want without searching through the aliases to find the right command. If you want to run the prod tests you add --prod, if you want to run the tests against the build, you add --build.

This also means you can easily test missing permutations. For example, we don't have a debug-test-prod-build.

For a list of all supported options, we have the help message:

Screen Shot 2020-09-23 at 12 10 11 PM

Does this help @sebmarkbage?

rickhanlonii added 3 commits Oct 7, 2020
@rickhanlonii
Copy link
Member Author

@rickhanlonii rickhanlonii commented Oct 7, 2020

Update: I added test-stable and test-www-classic so we now have a test script per release channel:

  • yarn test (experimental)
  • yarn test-stable (stable)
  • yarn test-www (www-modern)
  • yarn test-classic (www-classic)

I've also updated the circle test names to reflect the command that you would run to repro. I think we should give this a try and if we hate it we can re-evaluate.

rickhanlonii added 2 commits Oct 7, 2020
@rickhanlonii rickhanlonii requested review from gaearon and sebmarkbage Oct 8, 2020
@rickhanlonii rickhanlonii merged commit 8805873 into facebook:master Oct 14, 2020
34 checks passed
34 checks passed
Facebook CLA Check Contributor License Agreement is valid!
Details
ci/circleci: RELEASE_CHANNEL_stable_yarn_build Your tests passed on CircleCI!
Details
ci/circleci: RELEASE_CHANNEL_stable_yarn_lint_build Your tests passed on CircleCI!
Details
ci/circleci: RELEASE_CHANNEL_stable_yarn_test_dom_fixtures Your tests passed on CircleCI!
Details
ci/circleci: build_devtools_and_process_artifacts Your tests passed on CircleCI!
Details
ci/circleci: build_devtools_scheduling_profiler Your tests passed on CircleCI!
Details
ci/circleci: process_artifacts Your tests passed on CircleCI!
Details
ci/circleci: process_artifacts_experimental Your tests passed on CircleCI!
Details
ci/circleci: setup Your tests passed on CircleCI!
Details
ci/circleci: sizebot_experimental Your tests passed on CircleCI!
Details
ci/circleci: sizebot_stable Your tests passed on CircleCI!
Details
ci/circleci: yarn_build Your tests passed on CircleCI!
Details
ci/circleci: yarn_flow Your tests passed on CircleCI!
Details
ci/circleci: yarn_lint Your tests passed on CircleCI!
Details
ci/circleci: yarn_lint_build Your tests passed on CircleCI!
Details
ci/circleci: yarn_test Your tests passed on CircleCI!
Details
ci/circleci: yarn_test-classic Your tests passed on CircleCI!
Details
ci/circleci: yarn_test-classic_prod Your tests passed on CircleCI!
Details
ci/circleci: yarn_test-classic_prod_variant Your tests passed on CircleCI!
Details
ci/circleci: yarn_test-classic_variant Your tests passed on CircleCI!
Details
ci/circleci: yarn_test-stable Your tests passed on CircleCI!
Details
ci/circleci: yarn_test-stable_build Your tests passed on CircleCI!
Details
ci/circleci: yarn_test-stable_build_prod Your tests passed on CircleCI!
Details
ci/circleci: yarn_test-stable_persistent Your tests passed on CircleCI!
Details
ci/circleci: yarn_test-stable_prod Your tests passed on CircleCI!
Details
ci/circleci: yarn_test-www Your tests passed on CircleCI!
Details
ci/circleci: yarn_test-www_prod Your tests passed on CircleCI!
Details
ci/circleci: yarn_test-www_prod_variant Your tests passed on CircleCI!
Details
ci/circleci: yarn_test-www_variant Your tests passed on CircleCI!
Details
ci/circleci: yarn_test_build Your tests passed on CircleCI!
Details
ci/circleci: yarn_test_build_devtools Your tests passed on CircleCI!
Details
ci/circleci: yarn_test_build_prod Your tests passed on CircleCI!
Details
ci/circleci: yarn_test_prod Your tests passed on CircleCI!
Details
ci/codesandbox Building packages succeeded.
Details
@rickhanlonii rickhanlonii deleted the rickhanlonii:rh-deprecate-test-scripts branch Oct 14, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Linked issues

Successfully merging this pull request may close these issues.

None yet

5 participants