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
>
>
>

Reply via email to