-
-
Notifications
You must be signed in to change notification settings - Fork 1.5k
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
ClasspathScanner#determineSubpackageName sometimes resolves to wrong subpackageName starting with '...' #2612
Comments
The URI https://github.com/jlrosa/testwithresources is wrong. Typo? |
@sormuras Sorry, I forgot that project is private. I will ask author to make it public. |
Hello @sormuras . Here the repository that can be used to reproduce the bug following steps above: |
sormuras
added a commit
that referenced
this issue
May 11, 2021
Fix `getRootUrisForPackage()` in class `ClasspathScanner` by looking for two "wordings" of a package name. For example, package `foo.bar` is expanded to `foo/bar` and `foo/bar/`. The latter allows find package `foo.bar` in a module called `foo.bar`, and not `foo`. Fixes #2500 Fixes #2600 Fixes #2612
7 tasks
Perfect timing, Alexei! I'll include it (or a similar check) in the PR I just submitted. |
sormuras
added a commit
that referenced
this issue
May 12, 2021
Fix `getRootUrisForPackage()` in class `ClasspathScanner` by looking for two "wordings" of a package name. For example, package `foo.bar` is expanded to `foo/bar` and `foo/bar/`. The latter allows find package `foo.bar` in a module called `foo.bar`, and not `foo`. This commit also ensures, that there's no regression (compared to #2531) by launching test runs using the standalone artifact with `--select-package` and `--scan-class-path`. Fixes #2500 Fixes #2600 Fixes #2612
marcphilipp
pushed a commit
that referenced
this issue
May 13, 2021
Fix `getRootUrisForPackage()` in class `ClasspathScanner` by looking for two "wordings" of a package name. For example, package `foo.bar` is expanded to `foo/bar` and `foo/bar/`. The latter allows find package `foo.bar` in a module called `foo.bar`, and not `foo`. This commit also ensures, that there's no regression (compared to #2531) by launching test runs using the standalone artifact with `--select-package` and `--scan-class-path`. Fixes #2500 Fixes #2600 Fixes #2612
runningcode
pushed a commit
to runningcode/junit5
that referenced
this issue
Feb 15, 2023
Fix `getRootUrisForPackage()` in class `ClasspathScanner` by looking for two "wordings" of a package name. For example, package `foo.bar` is expanded to `foo/bar` and `foo/bar/`. The latter allows find package `foo.bar` in a module called `foo.bar`, and not `foo`. This commit also ensures, that there's no regression (compared to junit-team#2531) by launching test runs using the standalone artifact with `--select-package` and `--scan-class-path`. Fixes junit-team#2500 Fixes junit-team#2600 Fixes junit-team#2612
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
This bug was introduced in JUnit
5.7.1
.5.7.0
have no such a problem.Example:
The bug is probaby due to commit #2531 (Fix package path computation in ClasspathScanner )
I got this bug because I use
ReflectionSupport#findAllClassesInPackage
inside my JUnit Jupiter plugin.Steps to reproduce
To reproduce the bug is quite a trick. So project https://github.com/jlrosa/testwithresources was created. Here the steps to do
mvn clean install
, and open the project in IDE.ClasspathScanner#processClassFileSafely
line 131.InjectResourcesTest
in debug mode.fullyQualifiedClassName
. It will be something like: "com.adelean.inject.resources.junit.jupiter....jupiter.WithJacksonMapper"Context
Deliverables
The text was updated successfully, but these errors were encountered: