Please create a Jira issue at https://jira.codehaus.org/browse/JBEHAVE and attach your latest version of the project.
Please provide details of mvn -v too in the Jira issue. I'll try it out on Windows as well. On 04/06/2010 15:40, Joseph DelCioppio wrote: > I changed to C:\Workspace, but no difference. I am at work and > working on windoze. I can get SSH access to my linux box at home and > might try it there to see if it changes anything. > > On Fri, Jun 4, 2010 at 10:33 AM, Mauro Talevi > <[email protected] <mailto:[email protected]>> wrote: > > I'm guessing the problem is due to the spaces in the classpath > entries. Could you try working with a workspace that does not > use "Documents and Settings", eg c:\workspace? > > On 04/06/2010 15:30, Joseph DelCioppio wrote: >> Hmmm, ok that leaves me with this output: >> >> [INFO] [jar:jar {execution: default-jar}] >> [INFO] Building jar: C:\Documents and >> >> Settings\josephd.ESLTEMP-DOMAIN\Workspace\proview\target\proview-1.0-SNAPSHOT.jar >> [INFO] [jbehave:run-scenarios {execution: run-scenarios-found}] >> [INFO] Running scenario >> com.electrostandards.prod.scenarios.ProviewStartsInOfflineMode >> [WARNING] Failure in running scenario >> com.electrostandards.prod.scenarios.ProviewStartsInOfflineMode >> org.jbehave.scenario.errors.ScenarioNotFoundException: Path >> >> 'com/electrostandards/prod/scenarios/proview_starts_in_offline_mode.scenario' >> could not be found by classloader >> [org.jbehave.scenario.ScenarioClassLoader urls=[/C:/Documents and >> Settings/josephd.ESLTEMP-DOMAIN/Workspace/proview/target/test-classes/, >> /C:/Documents and >> Settings/josephd.ESLTEMP-DOMAIN/Workspace/proview/target/classes/, >> junit-dep-4.4.jar, >> hamcrest-core-1.1.jar, freemarker-2.3.16.jar, >> jbehave-core-2.5.8.jar, commons-lang-2.4.jar, >> commons-collections-3.2.1.jar, commons-io-1.4.jar, >> swing-worker-1.1.jar, filters-2.0.235.jar, swingx-1.6.jar, >> tyburn-1.1.jar]] >> at >> >> org.jbehave.scenario.parser.ClasspathScenarioDefiner.loadInputStreamFor(ClasspathScenarioDefiner.java:60) >> at >> >> org.jbehave.scenario.parser.ClasspathScenarioDefiner.loadScenarioDefinitionsFor(ClasspathScenarioDefiner.java:48) >> at >> org.jbehave.scenario.ScenarioRunner.run(ScenarioRunner.java:39) >> at >> >> org.jbehave.scenario.AbstractScenario.runScenario(AbstractScenario.java:75) >> at >> org.jbehave.scenario.JUnitScenario.runScenario(JUnitScenario.java:54) >> at >> org.jbehave.mojo.ScenarioRunnerMojo.execute(ScenarioRunnerMojo.java:36) >> at >> >> org.apache.maven.plugin.DefaultPluginManager.executeMojo(DefaultPluginManager.java:490) >> at >> >> org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoals(DefaultLifecycleExecutor.java:694) >> at >> >> org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoalWithLifecycle(DefaultLifecycleExecutor.java:556) >> at >> >> org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoal(DefaultLifecycleExecutor.java:535) >> at >> >> org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoalAndHandleFailures(DefaultLifecycleExecutor.java:387) >> at >> >> org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeTaskSegments(DefaultLifecycleExecutor.java:348) >> at >> >> org.apache.maven.lifecycle.DefaultLifecycleExecutor.execute(DefaultLifecycleExecutor.java:180) >> at >> org.apache.maven.DefaultMaven.doExecute(DefaultMaven.java:328) >> at >> org.apache.maven.DefaultMaven.execute(DefaultMaven.java:138) >> at org.apache.maven.cli.MavenCli.main(MavenCli.java:362) >> at >> org.apache.maven.cli.compat.CompatibleMain.main(CompatibleMain.java:60) >> at sun.reflect.NativeMethodAccessorImpl.invoke0(Native >> Method) >> at >> >> sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39) >> at >> >> sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25) >> at java.lang.reflect.Method.invoke(Method.java:597) >> at >> org.codehaus.classworlds.Launcher.launchEnhanced(Launcher.java:315) >> at >> org.codehaus.classworlds.Launcher.launch(Launcher.java:255) >> at >> org.codehaus.classworlds.Launcher.mainWithExitCode(Launcher.java:430) >> at org.codehaus.classworlds.Launcher.main(Launcher.java:375) >> [INFO] Running scenario >> com.electrostandards.prod.scenarios.UserConnectsToTarget >> [WARNING] Failure in running scenario >> com.electrostandards.prod.scenarios.UserConnectsToTarget >> org.jbehave.scenario.errors.ScenarioNotFoundException: Path >> 'com/electrostandards/prod/scenarios/user_connects_to_target.scenario' >> could not be found by classloader >> [org.jbehave.scenario.ScenarioClassLoader urls=[/C:/Documents and >> Settings/josephd.ESLTEMP-DOMAIN/Workspace/proview/target/test-classes/, >> /C:/Documents >> and Settings/josephd.ESLTEMP-DOMAIN/Workspace/proview/target/classes/, >> junit-dep-4.4.jar, hamcrest-core-1.1.jar, freemarker-2.3.16.jar, >> jbehave-core-2.5.8.jar, commons-lang-2.4.jar, >> commons-collections-3.2.1.jar, commons-io-1.4.jar, >> swing-worker-1.1.jar, filters-2.0.235.jar, swingx-1.6.jar, >> tyburn-1.1.jar]] >> at >> >> org.jbehave.scenario.parser.ClasspathScenarioDefiner.loadInputStreamFor(ClasspathScenarioDefiner.java:60) >> at >> >> org.jbehave.scenario.parser.ClasspathScenarioDefiner.loadScenarioDefinitionsFor(ClasspathScenarioDefiner.java:48) >> at >> org.jbehave.scenario.ScenarioRunner.run(ScenarioRunner.java:39) >> at >> >> org.jbehave.scenario.AbstractScenario.runScenario(AbstractScenario.java:75) >> at >> org.jbehave.scenario.JUnitScenario.runScenario(JUnitScenario.java:54) >> at >> org.jbehave.mojo.ScenarioRunnerMojo.execute(ScenarioRunnerMojo.java:36) >> at >> >> org.apache.maven.plugin.DefaultPluginManager.executeMojo(DefaultPluginManager.java:490) >> at >> >> org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoals(DefaultLifecycleExecutor.java:694) >> at >> >> org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoalWithLifecycle(DefaultLifecycleExecutor.java:556) >> at >> >> org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoal(DefaultLifecycleExecutor.java:535) >> at >> >> org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoalAndHandleFailures(DefaultLifecycleExecutor.java:387) >> at >> >> org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeTaskSegments(DefaultLifecycleExecutor.java:348) >> at >> >> org.apache.maven.lifecycle.DefaultLifecycleExecutor.execute(DefaultLifecycleExecutor.java:180) >> at >> org.apache.maven.DefaultMaven.doExecute(DefaultMaven.java:328) >> at >> org.apache.maven.DefaultMaven.execute(DefaultMaven.java:138) >> at org.apache.maven.cli.MavenCli.main(MavenCli.java:362) >> at >> org.apache.maven.cli.compat.CompatibleMain.main(CompatibleMain.java:60) >> at sun.reflect.NativeMethodAccessorImpl.invoke0(Native >> Method) >> at >> >> sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39) >> at >> >> sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25) >> at java.lang.reflect.Method.invoke(Method.java:597) >> at >> org.codehaus.classworlds.Launcher.launchEnhanced(Launcher.java:315) >> at >> org.codehaus.classworlds.Launcher.launch(Launcher.java:255) >> at >> org.codehaus.classworlds.Launcher.mainWithExitCode(Launcher.java:430) >> at org.codehaus.classworlds.Launcher.main(Launcher.java:375) >> [INFO] Running scenario >> com.electrostandards.prod.scenarios.UserSelectsCommunicationsPort >> [WARNING] Failure in running scenario >> com.electrostandards.prod.scenarios.UserSelectsCommunicationsPort >> org.jbehave.scenario.errors.ScenarioNotFoundException: Path >> >> 'com/electrostandards/prod/scenarios/user_selects_communications_port.scenario' >> could not be found by classloader >> [org.jbehave.scenario.ScenarioClassLoader urls=[/C:/Documents and >> Settings/josephd.ESLTEMP-DOMAIN/Workspace/proview/target/test-classes/, >> /C:/Documents and >> Settings/josephd.ESLTEMP-DOMAIN/Workspace/proview/target/classes/, >> junit-dep-4.4.jar, >> hamcrest-core-1.1.jar, freemarker-2.3.16.jar, >> jbehave-core-2.5.8.jar, commons-lang-2.4.jar, >> commons-collections-3.2.1.jar, commons-io-1.4.jar, >> swing-worker-1.1.jar, filters-2.0.235.jar, swingx-1.6.jar, >> tyburn-1.1.jar]] >> at >> >> org.jbehave.scenario.parser.ClasspathScenarioDefiner.loadInputStreamFor(ClasspathScenarioDefiner.java:60) >> at >> >> org.jbehave.scenario.parser.ClasspathScenarioDefiner.loadScenarioDefinitionsFor(ClasspathScenarioDefiner.java:48) >> at >> org.jbehave.scenario.ScenarioRunner.run(ScenarioRunner.java:39) >> at >> >> org.jbehave.scenario.AbstractScenario.runScenario(AbstractScenario.java:75) >> at >> org.jbehave.scenario.JUnitScenario.runScenario(JUnitScenario.java:54) >> at >> org.jbehave.mojo.ScenarioRunnerMojo.execute(ScenarioRunnerMojo.java:36) >> at >> >> org.apache.maven.plugin.DefaultPluginManager.executeMojo(DefaultPluginManager.java:490) >> at >> >> org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoals(DefaultLifecycleExecutor.java:694) >> at >> >> org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoalWithLifecycle(DefaultLifecycleExecutor.java:556) >> at >> >> org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoal(DefaultLifecycleExecutor.java:535) >> at >> >> org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoalAndHandleFailures(DefaultLifecycleExecutor.java:387) >> at >> >> org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeTaskSegments(DefaultLifecycleExecutor.java:348) >> at >> >> org.apache.maven.lifecycle.DefaultLifecycleExecutor.execute(DefaultLifecycleExecutor.java:180) >> at >> org.apache.maven.DefaultMaven.doExecute(DefaultMaven.java:328) >> at >> org.apache.maven.DefaultMaven.execute(DefaultMaven.java:138) >> at org.apache.maven.cli.MavenCli.main(MavenCli.java:362) >> at >> org.apache.maven.cli.compat.CompatibleMain.main(CompatibleMain.java:60) >> at sun.reflect.NativeMethodAccessorImpl.invoke0(Native >> Method) >> at >> >> sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39) >> at >> >> sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25) >> at java.lang.reflect.Method.invoke(Method.java:597) >> at >> org.codehaus.classworlds.Launcher.launchEnhanced(Launcher.java:315) >> at >> org.codehaus.classworlds.Launcher.launch(Launcher.java:255) >> at >> org.codehaus.classworlds.Launcher.mainWithExitCode(Launcher.java:430) >> at org.codehaus.classworlds.Launcher.main(Launcher.java:375) >> >> Which says to me that there is a problem with finding the scenarios? >> >> I'm running JDK 1.6_20 and Maven 2.2.1 with JBehave 2.5.8 for the >> record. >> >> Joe >> >> On Fri, Jun 4, 2010 at 10:20 AM, Mauro Talevi >> <[email protected] <mailto:[email protected]>> >> wrote: >> >> Hi, >> >> that means that when it tried and failed to instantiate the >> scenario class >> com.electrostandards.prod.scenarios.ProviewStartsInOfflineMode. >> The scenario class must have a public default constructor (no >> args) or a single ClassLoader arg (only if the >> classLoaderInjected flag is true). >> In your case, if seems that you have the flag set to true >> (the default in 2.x, will be changed in 3.x as unnecessary >> anymore in most cases) and you need to set it to false. >> >> If setting the flag does not fix it, run mvn -e to get full >> stack trace. Odd that I could run your example. >> >> What Java/Maven versions are you using, ie can you provide >> the output of mvn -v please? >> >> Cheers >> >> On 04/06/2010 15:01, Joseph DelCioppio wrote: >>> Mauro, >>> >>> Thanks, but now I've got one question. When I follow your >>> instructions I am now faced with the following errors: >>> >>> [INFO] [jar:jar {execution: default-jar}] >>> [INFO] [jbehave:run-scenarios {execution: run-scenarios-found}] >>> [INFO] >>> >>> ------------------------------------------------------------------------ >>> [ERROR] BUILD ERROR >>> [INFO] >>> >>> ------------------------------------------------------------------------ >>> [INFO] Failed to instantiate scenario >>> 'com.electrostandards.prod.scenarios.ProviewStartsInOfflineMode' >>> >>> Embedded error: JBehave is trying to instantiate your >>> Scenario class >>> 'com.electrostandards.prod.scenarios.ProviewStartsInOfflineMode' >>> with a ClassLoader as a parameter. If this is wrong, change >>> the Maven configuration for the plugin to include >>> <classLoaderInjected>false</classLoaderInjected> >>> >>> com.electrostandards.prod.scenarios.ProviewStartsInOfflineMode.<init>(java.lang.ClassLoader) >>> [INFO] >>> >>> ------------------------------------------------------------------------ >>> [INFO] For more information, run Maven with the -e switch >>> [INFO] >>> >>> ------------------------------------------------------------------------ >>> [INFO] Total time: 8 seconds >>> [INFO] Finished at: Fri Jun 04 09:59:51 EDT 2010 >>> [INFO] Final Memory: 15M/36M >>> [INFO] >>> >>> ------------------------------------------------------------------------ >>> >>> That file clearly exists, I am missing something here? >>> >>> Joe >>> >>> On Thu, Jun 3, 2010 at 4:58 PM, Mauro Talevi >>> <[email protected] >>> <mailto:[email protected]>> wrote: >>> >>> Hi Joseph, >>> >>> your scenario classes have the wrong package >>> declaration, it should be >>> com.electrostandards.prod.scenarios to match the >>> directory structure. >>> that's why they cannot be instantiated. this should >>> show as an error >>> in you IDE as well. >>> >>> also, make sure TextFieldEmpty class is moved to another >>> package or it >>> will fail if you try to run all classes in the package >>> as scenarios. >>> >>> Cheers >>> >>> On 03/06/2010 19:17, Joseph DelCioppio wrote: >>> > Guys, >>> > >>> > I'm new to jBehave although I do have experience doing >>> BDD in Ruby. >>> > I've got a project that I can't seem to build, and >>> I'm hoping someone >>> > could help me figure out why I'm seeing what I'm seeing. >>> > >>> > Every time I try to run mvn integration-test, I get >>> the following >>> > error: Failed to instantiate scenario >>> > >>> 'com.electrostandards.prod.scenarios.ProviewStartsInOfflineMode' >>> > >>> > I'm hoping someone can help me here and with that in >>> mind I've posted >>> > my project at this url: >>> > http://www.mediafire.com/file/jtmmodfmzwn/proview.zip >>> > >>> > The only non-external dependency is tyburn, which you >>> can install with >>> > this command: >>> > >>> > mvn install:file-install -DgroupId=org.lunivore >>> -DartifactId=tyburn >>> > -Dversion=1.1 -Dfile=${Location where you unzipped my >>> > project}/tools/tyburn-1.1.jar >>> > >>> > Here's hoping somebody can help. >>> > >>> > Thanks, >>> > >>> > Joe >>> >>> >>> >>> --------------------------------------------------------------------- >>> To unsubscribe from this list, please visit: >>> >>> http://xircles.codehaus.org/manage_email >>> >>> >>> >> >> > >
