[ 
https://issues.apache.org/jira/browse/SUREFIRE-1563?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16599582#comment-16599582
 ] 

Robert Scholte commented on SUREFIRE-1563:
------------------------------------------

If it would be a module-info, it would put everything back on the modulepath, I 
don't like that. However... we could make a {{class-info.java}} (a bit weird, 
it is not for 1 class, but for 1 classpath) and exclude it for compilation. 
It'll just be a file to parse. 
But again, users will need to know about this and I'm afraid that won't happen. 
People need to learn the module system, but you still cannot become Java 9 
certified AFAIK.
IMHO the best we can do is add information where the JRE is missing some hints.

> NoClassDefFoundError for JPMS modules with "require static"
> -----------------------------------------------------------
>
>                 Key: SUREFIRE-1563
>                 URL: https://issues.apache.org/jira/browse/SUREFIRE-1563
>             Project: Maven Surefire
>          Issue Type: Bug
>          Components: Maven Surefire Plugin
>    Affects Versions: 2.22.0
>            Reporter: Simone Bordet
>            Priority: Major
>         Attachments: maven-jpms.tgz
>
>
> When a Maven module has a {{module-info.java}} that contains a {{requires 
> static}}, Surefire throws {{NoClassDefFoundError}} when running the tests for 
> that Maven module.
> If the dependency is declared only as {{required}} (no {{static}}), then the 
> tests run fine.
> Attached a reproducible project.



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)

Reply via email to