[ https://issues.apache.org/jira/browse/SUREFIRE-1563?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16599077#comment-16599077 ]
Simone Bordet commented on SUREFIRE-1563: ----------------------------------------- My understanding of this issue after discussion is that nothing will be done because I can easily customize Surefire's argLine by manually adding --add-modules for those I need. For the record, I also encountered a case where I needed to open the module because the tests used a reflection library to reflect the classes in the module. Again this was solved by customizing Surefire argLine by adding --add-opens. If the understanding above is correct, then I guess this issue can be closed without further work. Thanks! > 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)