[ https://issues.apache.org/jira/browse/SUREFIRE-1563?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17007141#comment-17007141 ]
Tibor Digana edited comment on SUREFIRE-1563 at 1/3/20 12:35 AM: ----------------------------------------------------------------- [~scolebou...@joda.org] We agreed with [~rfscholte] that we will not stick to a proprietary solutions with {{module-info.test}} as the runtime of main module. We should use plugin's style to patch {{module-info}} similar to what another {{fabric8}} plugin does where dockerfile is patched and here it can be similar principal, see [#comment-16990869]. Then the user has to write the main descriptor only once and optional patch with {{add-modules}} or {{open-modules}} in the POM. The users have to read the documentation in any case if it is any IDE or Maven. If the plugin fails, the fork config may print the hint that everybody expects (FAQ link or so). was (Author: tibor17): [~scolebou...@joda.org] We agreed with [~rfscholte] that we will not stick to a proprietary solutions with {{module-info.test}} as the runtime of main module. We should use plugin's style to patch {{module-info}} similar to what another {{fabric8}} plugin does where dockerfile is patched and here it can be similar principal, see #comment-16990869. Then the user has to write the main descriptor only once and optional patch with {{add-modules}} or {{open-modules}} in the POM. The users have to read the documentation in any case if it is any IDE or Maven. If the plugin fails, the fork config may print the hint that everybody expects (FAQ link or so). > 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 > Assignee: Olivier Lamy > 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 (v8.3.4#803005)