Skip to content

Fix the reproduction script for testFromTasty tests #4832

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

Conversation

nicolasstucki
Copy link
Contributor

For example a failure in a testFromTasty for tests/run/eff-dependent.scala will output the following report:

================================================================================
Test Report
================================================================================

1 suites passed, 1 failed, 2 total
    tests/run/eff-dependent.scala failed


Test 'tests/run/eff-dependent.scala' compiled with 0 error(s) and 0 warning(s),
the test can be reproduced by running:

  sbt "testFromTasty tests/run/eff-dependent.scala"

|Test '$title' compiled with $errors error(s) and $warnings warning(s),
|the test can be reproduced by running:
|
| sbt "testFromTasty $file"
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is the easiest way to reproduce but is it helpful for debugging? My experience is that when you run a test with vulpix and the compiler crashes then the exception is swallowed and I either need to look at the test log or run the compiler manually.

I often want to run the compiler manually outside vulpix and I would rather have the manual instructions. E.g:

> dotc -d tmp Foo.scala -some-options
> dotc Foo -classpath tmp -from-tasty -some-options

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The issue is that there is no way at this point to know which are the inputs (class names) of the second script. I will try to come up with something more precise but for now, it is more important to emit a report that gives a correct way to reproduce the error.

@nicolasstucki nicolasstucki force-pushed the fix-reproduction-instructions-for-from-tasty-tests branch from afc407a to a888cec Compare July 25, 2018 19:04
@nicolasstucki nicolasstucki force-pushed the fix-reproduction-instructions-for-from-tasty-tests branch from a888cec to 5edcee6 Compare July 25, 2018 19:07
@nicolasstucki nicolasstucki merged commit 6240daa into scala:master Jul 26, 2018
@allanrenucci allanrenucci deleted the fix-reproduction-instructions-for-from-tasty-tests branch July 26, 2018 11:18
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants