8173717: jlink --help fails with missing "plugin.opt.plugin-module-path" key in resource bundle

Reviewed-by: mchung, alanb
This commit is contained in:
Athijegannathan Sundararajan 2017-02-01 15:12:03 +05:30
parent 7e2dd137c3
commit b19ab1ef8f
3 changed files with 8 additions and 7 deletions

View File

@ -227,12 +227,6 @@ public final class TaskHelper {
addOrderedPluginOptions(plugin, optionsSeen);
}
}
mainOptions.add(new PluginOption(false,
(task, opt, arg) -> {
// This option is handled prior
// to have the options parsed.
},
false, "--plugin-module-path"));
mainOptions.add(new PluginOption(true, (task, opt, arg) -> {
for (Plugin plugin : plugins) {
if (plugin.getName().equals(arg)) {

View File

@ -28,7 +28,7 @@ Usage: {0} <options> --module-path <modulepath> --add-modules <mods> --output\n\
\<path> use --help for a list of possible options
main.usage=\
Usage: {0} <options> --module-path <modulepath> --add-modules <mods> --output
Usage: {0} <options> --module-path <modulepath> --add-modules <mods> --output\n\
\<path> Possible options include:
error.prefix=Error:

View File

@ -284,6 +284,13 @@ public class JLinkTest {
helper.generateDefaultJModule(moduleName, "composite2");
helper.generateDefaultImage(userOptions, moduleName).assertFailure("Error: orphan argument: bar");
}
// basic check for --help - JDK-8173717
{
JImageGenerator.getJLinkTask()
.option("--help")
.call().assertSuccess();
}
}
private static void testCompress(Helper helper, String moduleName, String... userOptions) throws IOException {