Thanks. I tried that now. So my pom.xml looks like

  <build>
    <plugins>
      <plugin>
        <groupId>org.jbehave</groupId>
        <artifactId>jbehave-maven-plugin</artifactId>
        <executions>
          <execution>
            <id>embeddable-stories</id>
            <phase>integration-test</phase>
            <configuration>
              <includes>
                <include>**/AnnotatedEmbedderUsingSpring.java</include>
              </includes>
              <ignoreFailureInStories>true</ignoreFailureInStories>
              <ignoreFailureInView>true</ignoreFailureInView>
            </configuration>
            <goals>
              <goal>run-stories-with-annotated-embedder</goal>
            </goals>
          </execution>
        </executions>
      </plugin>
    </plugins>
  </build>


Now the build fails with:

Reports view generated with 1 stories (of which 0 pending) containing
0 scenarios (of which 0 pending)
[INFO] ------------------------------------------------------------------------
[INFO] BUILD FAILURE
[INFO] ------------------------------------------------------------------------
[INFO] Total time: 4.163s
[INFO] Finished at: Wed Feb 29 17:14:00 EET 2012
[INFO] Final Memory: 16M/490M
[INFO] ------------------------------------------------------------------------
[ERROR] Failed to execute goal
org.jbehave:jbehave-maven-plugin:3.6-SNAPSHOT:run-stories-with-annotated-embedder
(embeddable-stories) on project jbehave-trader-spring-example: Failed
to run stories wi
th annotated embedder runner: Annotated embedder run failed with
runner org.jbehave.core.junit.spring.SpringAnnotatedEmbedderRunner@6d5998cb:
Story path 'org/jbehave/examples/trader/stories/after_scen
ario_outcome.story' not found by class loader
EmbedderClassLoader[urls=[/D:/projects/zzz/sandbox/jbehave-src/src/examples/trader-spring/target/classes/],parent=ClassRealm[plugin>org.jbehave:jbehave-m
aven-plugin:3.6-SNAPSHOT, parent:
sun.misc.Launcher$AppClassLoader@3093dee9]] -> [Help 1]


On Wed, Feb 29, 2012 at 5:02 PM, Mauro Talevi
<[email protected]> wrote:
> You need to change the maven goal as well to
> run-stories-with-annotated-embedder.
>
> Have a look at trader-annotations-example.
>
> Cheers
>
>
> On 29/02/2012 15:16, janne mattila wrote:
>>
>> I'm trying to get spring integration working by using annotations such
>> as @UsingSpring in my Stories-class. The annotations do not seem to do
>> anything, and my stories are found but 0 scenarios are run. If I do
>> not use the annotations, and implement createContext() manually as in
>> example org.jbehave.examples.trader.spring.TraderStoriesUsingSpring,
>> scenarios are run fine.
>>
>> I'm trying to figure out the correct configuration by looking at the
>> latest examples. Are the examples other than
>> "TraderStoriesUsingSpring" broken? For example
>>
>> AnnotatedEmbedderUsingSpring
>> AnnotatedEmbedderUsingSpringAndSteps
>> AnnotatedEmbedderUsingSpringNamespace
>>
>> If I change the example's pom.xml from
>>
>>                 <include>**/TraderStoriesUsingSpring.java</include>
>>
>> (which produces correct results) to for example
>>
>>                 <include>**/AnnotatedEmbedderUsingSpring.java</include>
>>
>> running jbehave-src\src\examples\trader-spring>mvn -s
>> ..\..\settings.xml clean install -Pexamples results in
>>
>> [INFO] Reports view generated with 0 stories (of which 0 pending)
>> containing 0 scenarios (of which 0 pending)
>>
>> ---------------------------------------------------------------------
>> To unsubscribe from this list, please visit:
>>
>>     http://xircles.codehaus.org/manage_email
>>
>>
>
>
> ---------------------------------------------------------------------
> To unsubscribe from this list, please visit:
>
>   http://xircles.codehaus.org/manage_email
>
>

---------------------------------------------------------------------
To unsubscribe from this list, please visit:

    http://xircles.codehaus.org/manage_email


Reply via email to