Commit 62eb9ee
committed
Fix #11276: Scala.js: Take JUnit tests from superclasses/traits into account.
The Scala 2 code uses
owner.info.members.filter(m => m.isMethod && m.hasAnnotation(annot))
for the equivalent operation.
The code in Scala 3 used `decls` instead of `members`, which is
clearly incorrect. This commit fixes the discrepancy.
This was tested manually by making sure that
> sjsJUnitTests/testOnly org.scalajs.testsuite.javalib.util.ArrayListTest
runs 40 tests, and not just 1. It is not clear how to write
automated tests for this fix.1 parent 7aa0fb1 commit 62eb9ee
File tree
1 file changed
+5
-1
lines changed- compiler/src/dotty/tools/dotc/transform/sjs
1 file changed
+5
-1
lines changedLines changed: 5 additions & 1 deletion
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
304 | 304 | | |
305 | 305 | | |
306 | 306 | | |
307 | | - | |
| 307 | + | |
| 308 | + | |
| 309 | + | |
| 310 | + | |
| 311 | + | |
308 | 312 | | |
309 | 313 | | |
310 | 314 | | |
| |||
0 commit comments