Skip to content

Coverage tests not filtered when running testCompilation #14968

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

Closed
nicolasstucki opened this issue Apr 19, 2022 · 0 comments · Fixed by #14969
Closed

Coverage tests not filtered when running testCompilation #14968

nicolasstucki opened this issue Apr 19, 2022 · 0 comments · Fixed by #14969

Comments

@nicolasstucki
Copy link
Contributor

Compiler version

7db4121

Minimized example

In the dotty project

sbt> scala3-bootstrapped/testCompilation thisTestDoesNotExist
...
info] Test run dotty.tools.dotc.coverage.CoverageTests started
[info] Test dotty.tools.dotc.coverage.CoverageTests.checkInstrumentedRuns started
No files matched "thisTestDoesNotExist" in test                                 
[error] Test dotty.tools.dotc.coverage.CoverageTests.checkInstrumentedRuns failed: java.nio.file.NoSuchFileException: /var/folders/gl/4_k_l76n3pq17f7zxm0v6v_w0000gn/T/coverage3235155365295970741/scoverage.coverage, took 0.011 sec
[error]     at sun.nio.fs.UnixException.translateToIOException(UnixException.java:86)
[error]     at sun.nio.fs.UnixException.rethrowAsIOException(UnixException.java:102)
[error]     at sun.nio.fs.UnixException.rethrowAsIOException(UnixException.java:107)
[error]     at sun.nio.fs.UnixFileSystemProvider.newByteChannel(UnixFileSystemProvider.java:214)
[error]     at java.nio.file.Files.newByteChannel(Files.java:361)
[error]     at java.nio.file.Files.newByteChannel(Files.java:407)
[error]     at java.nio.file.spi.FileSystemProvider.newInputStream(FileSystemProvider.java:384)
[error]     at java.nio.file.Files.newInputStream(Files.java:152)
[error]     at java.nio.file.Files.newBufferedReader(Files.java:2784)
[error]     at java.nio.file.Files.readAllLines(Files.java:3202)
[error]     at java.nio.file.Files.readAllLines(Files.java:3242)
[error]     at dotty.tools.dotc.coverage.CoverageTests.checkCoverageIn$$anonfun$2(CoverageTests.scala:55)
[error]     at java.util.stream.ForEachOps$ForEachOp$OfRef.accept(ForEachOps.java:183)
[error]     at java.util.stream.ReferencePipeline$2$1.accept(ReferencePipeline.java:175)
[error]     at java.util.stream.ReferencePipeline$3$1.accept(ReferencePipeline.java:193)
[error]     at java.util.Iterator.forEachRemaining(Iterator.java:116)
[error]     at java.util.Spliterators$IteratorSpliterator.forEachRemaining(Spliterators.java:1801)
[error]     at java.util.stream.AbstractPipeline.copyInto(AbstractPipeline.java:482)
[error]     at java.util.stream.AbstractPipeline.wrapAndCopyInto(AbstractPipeline.java:472)
[error]     at java.util.stream.ForEachOps$ForEachOp.evaluateSequential(ForEachOps.java:150)
[error]     at java.util.stream.ForEachOps$ForEachOp$OfRef.evaluateSequential(ForEachOps.java:173)
[error]     at java.util.stream.AbstractPipeline.evaluate(AbstractPipeline.java:234)
[error]     at java.util.stream.ReferencePipeline.forEach(ReferencePipeline.java:485)
[error]     at dotty.tools.dotc.coverage.CoverageTests.checkCoverageIn(CoverageTests.scala:63)
[error]     at dotty.tools.dotc.coverage.CoverageTests.checkInstrumentedRuns(CoverageTests.scala:32)
[error]     ...
...

Expectation

The test should not attempt to run because it should be filtered

nicolasstucki added a commit to dotty-staging/dotty that referenced this issue Apr 19, 2022
michelou pushed a commit to michelou/scala3 that referenced this issue Apr 25, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant