Zihao Yu commented on Bug JBEHAVE-853

story1.story

This is a test story

Narrative:
In order to do some test
As a user
I want to be able to use jbehave

Scenario: User should know how to download jbehave

Meta:
@id story1scenario1

Given a user
When he is asked to download jbehave
Then he should know how to do it

Story1Steps.java

import org.jbehave.core.annotations.Given;
import org.jbehave.core.annotations.Then;
import org.jbehave.core.annotations.When;

import static org.junit.Assert.assertEquals;

public class Story1Steps {

    @Given("a user")
    public void setUser() {
        assertEquals("user", "user");
    }

    @When("he is asked to download jbehave")
    public void downloadJbehave() {
        assertEquals("jbehave", "jbehave");
    }

    @Then("he should know how to do it")
    public void isDownloaded() {
        assertEquals("downloaded", "downloaded");
    }

}

After running jbehave maven task,
story1.xml

<narrative keyword="Narrative:">
  <inOrderTo keyword="In order to">do some test</inOrderTo>
  <asA keyword="As a">user</asA>
  <iWantTo keyword="I want to">be able to use jbehave</iWantTo>
</narrative>
<story path="story1.story" title="This is a test story">
  <scenario keyword="Scenario:" title="User should know how to download jbehave">
    <step outcome="successful">Given a user</step>
    <step outcome="successful">When he is asked to download jbehave</step>
    <step outcome="successful">Then he should know how to do it</step>
  </scenario>
</story>

Jenkins throws exception,

[xUnit] [ERROR] - Conversion error Error to convert - A file not found
ERROR: Publisher org.jenkinsci.plugins.xunit.XUnitPublisher aborted due to exception
hudson.util.IOException2: There are some problems during the conversion into JUnit reports: 
	at com.thalesgroup.hudson.plugins.xunit.service.XUnitTransformer.invoke(XUnitTransformer.java:164)

Jenkins log,

INFO: [xUnit] - Converting '/Users/zyu/.jenkins/jobs/jbehave-poc/workspace/target/jbehave/story1.xml' .
[Fatal Error] :6:2: The markup in the document following the root element must be well-formed.
com.thalesgroup.hudson.plugins.xunit.exception.XUnitException: Conversion error Error to convert - A file not found
        at com.thalesgroup.hudson.plugins.xunit.service.XUnitConversionService.convert(XUnitConversionService.java:89)
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators.
For more information on JIRA, see: http://www.atlassian.com/software/jira
--------------------------------------------------------------------- To unsubscribe from this list, please visit: http://xircles.codehaus.org/manage_email

Reply via email to