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

Full stack trace for assertEquals #782

Open
timothyklim opened this issue May 11, 2024 · 5 comments
Open

Full stack trace for assertEquals #782

timothyklim opened this issue May 11, 2024 · 5 comments

Comments

@timothyklim
Copy link

For assert I get full stack trace like

==> X xxx.XxxSpec.xxx  0.003s munit.FailException: assertion failed
    at munit.FunSuite.assert(FunSuite.scala:11)
    at xxx.XxxSpec.$init$$$anonfun$2$$anonfun$1(XxxSpec.scala:72)
    at scala.collection.IterableOnceOps.foreach(IterableOnce.scala:619)
    at scala.collection.IterableOnceOps.foreach$(IterableOnce.scala:617)
    at scala.collection.parallel.immutable.ParHashMap$ParHashMapIterator.foreach(ParHashMap.scala:78)
    at scala.collection.parallel.ParIterableLike$Foreach.leaf(ParIterableLike.scala:938)
    at scala.collection.parallel.Task.tryLeaf$$anonfun$1(Tasks.scala:52)
    at scala.util.control.Breaks$$anon$1.catchBreak(Breaks.scala:97)
    at scala.collection.parallel.Task.tryLeaf(Tasks.scala:56)
    at scala.collection.parallel.Task.tryLeaf$(Tasks.scala:21)
    at scala.collection.parallel.ParIterableLike$Foreach.tryLeaf(ParIterableLike.scala:935)
    at scala.collection.parallel.AdaptiveWorkStealingTasks$AWSTWrappedTask.internal(Tasks.scala:159)
    at scala.collection.parallel.AdaptiveWorkStealingTasks$AWSTWrappedTask.internal$(Tasks.scala:142)
    at scala.collection.parallel.AdaptiveWorkStealingForkJoinTasks$AWSFJTWrappedTask.internal(Tasks.scala:304)
    at scala.collection.parallel.AdaptiveWorkStealingTasks$AWSTWrappedTask.compute(Tasks.scala:149)
    at scala.collection.parallel.AdaptiveWorkStealingTasks$AWSTWrappedTask.compute$(Tasks.scala:142)
    at scala.collection.parallel.AdaptiveWorkStealingForkJoinTasks$AWSFJTWrappedTask.compute(Tasks.scala:304)
    at java.util.concurrent.RecursiveAction.exec(RecursiveAction.java:194)
    at java.util.concurrent.ForkJoinTask.doExec(ForkJoinTask.java:507)
    at java.util.concurrent.ForkJoinPool$WorkQueue.topLevelExec(ForkJoinPool.java:1491)
    at java.util.concurrent.ForkJoinPool.scan(ForkJoinPool.java:2073)
    at java.util.concurrent.ForkJoinPool.runWorker(ForkJoinPool.java:2035)
    at java.util.concurrent.ForkJoinWorkerThread.run(ForkJoinWorkerThread.java:187)

but for assertEquals I need to debug all asserts in all helpers because stack trace is a single line:

    at munit.Assertions.failComparison(Assertions.scala:278)
@mzuehlke
Copy link
Contributor

Which munit version are you using?

Could you verify if this is still the case with 1.0.0-RC1, please.

@timothyklim
Copy link
Author

Which munit version are you using?

Could you verify if this is still the case with 1.0.0-RC1, please.

I'm using 1.0.0-RC1.

@tgodzik
Copy link
Contributor

tgodzik commented May 12, 2024

As a workaround you can use -F option for running. In sbt added after -- for example:
sbt project/testOnly MySuite -- -F

Otherwise, looks like a but. But I don't think it's blocking 1.0.0.

@timothyklim

This comment was marked as resolved.

@timothyklim
Copy link
Author

As a workaround you can use -F option for running. In sbt added after -- for example: sbt project/testOnly MySuite -- -F

Otherwise, looks like a but. But I don't think it's blocking 1.0.0.

With -F the same result on 1.0.0 release.

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

No branches or pull requests

3 participants