Unable to run Cucumber feature
I've just installed the community edition of IntelliJ and the Cucumber integration. When I try to run a feature, I get the error below. How do I fix this? I have cucumber-core 2.0.1 and gherkin 4.1.3.
Thanks.
Exception in thread "main" java.lang.NoClassDefFoundError: gherkin/formatter/Formatter
at java.lang.ClassLoader.defineClass1(Native Method)
at java.lang.ClassLoader.defineClass(ClassLoader.java:763)
at java.security.SecureClassLoader.defineClass(SecureClassLoader.java:142)
at java.net.URLClassLoader.defineClass(URLClassLoader.java:467)
at java.net.URLClassLoader.access$100(URLClassLoader.java:73)
at java.net.URLClassLoader$1.run(URLClassLoader.java:368)
at java.net.URLClassLoader$1.run(URLClassLoader.java:362)
at java.security.AccessController.doPrivileged(Native Method)
at java.net.URLClassLoader.findClass(URLClassLoader.java:361)
at java.lang.ClassLoader.loadClass(ClassLoader.java:424)
at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:335)
at java.lang.ClassLoader.loadClass(ClassLoader.java:357)
at cucumber.runtime.formatter.PluginFactory.loadClass(PluginFactory.java:170)
at cucumber.runtime.formatter.PluginFactory.pluginClass(PluginFactory.java:162)
at cucumber.runtime.formatter.PluginFactory.getPluginClass(PluginFactory.java:214)
at cucumber.runtime.formatter.PluginFactory.isFormatterName(PluginFactory.java:192)
at cucumber.runtime.RuntimeOptions$ParsedPluginData.addPluginName(RuntimeOptions.java:472)
at cucumber.runtime.RuntimeOptions.parse(RuntimeOptions.java:156)
at cucumber.runtime.RuntimeOptions.<init>(RuntimeOptions.java:114)
at cucumber.runtime.RuntimeOptions.<init>(RuntimeOptions.java:107)
at cucumber.runtime.RuntimeOptions.<init>(RuntimeOptions.java:99)
at cucumber.api.cli.Main.run(Main.java:31)
at cucumber.api.cli.Main.main(Main.java:18)
Caused by: java.lang.ClassNotFoundException: gherkin.formatter.Formatter
at java.net.URLClassLoader.findClass(URLClassLoader.java:381)
at java.lang.ClassLoader.loadClass(ClassLoader.java:424)
at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:335)
at java.lang.ClassLoader.loadClass(ClassLoader.java:357)
... 23 more
Please sign in to leave a comment.
It's a known issue, please follow https://youtrack.jetbrains.com/issue/IDEA-179579 for updates.
Thanks. No workaround?
See https://youtrack.jetbrains.com/issue/IDEA-179579#comment=27-2472835 for the workaround.