babel / babylon

PSA: moved into babel/babel as @babel/parser -->

Home Page:https://github.com/babel/babel/tree/master/packages/babel-parser

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Warning if tests fail that if you need to generate fixtures.

zoecarver opened this issue · comments

If the tests fail (yarn run test-only), warn the user that you need to run a command that will delete the expected.json so that the tests pass.

Proposal

Error

$ babylon(master): yarn run test-only

yarn run v0.27.5
$ ava

  4240 passed
  1 failed
  112 skipped

  index › flow/typecasts/yield

  /Users/user/Developer/babylon/clean_up/babylon/test/helpers/runFixtureTests.js:21

   20:               name + "/" + task.actual.filename + ": " + er…
   21:             t.fail(message);
   22:           }

  flow/typecasts/yield/actual.js: [] != undefined (comments)
error Command failed with exit code 1.
info Visit https://yarnpkg.com/en/docs/cli/run for documentation about this command.

After an error like this warn user that they may need to delete expected.json, or have a command for doing this.

Command

The command for fixing this could be something like babylon-remove-broken-expected-json. It could be an alias that would just remove all failing expected.json files.


  • Create Alias to remove all failing expected.json files
  • Add suggestion to error message
  • Update Documentation
commented

Hey @pudility! We really appreciate you taking the time to report an issue. The collaborators
on this project attempt to help as many people as possible, but we're a limited number of volunteers,
so it's possible this won't be addressed swiftly.

If you need any help, or just have general Babel or JavaScript questions, we have a vibrant Slack
community that typically always has someone willing to help. You can sign-up here
for an invite.

This issue has been moved to babel/babel#6673.