StringListConverter converts an empty String to a one element List instead of
an empty List
-------------------------------------------------------------------------------------------
Key: JBEHAVE-211
URL: http://jira.codehaus.org/browse/JBEHAVE-211
Project: JBehave
Issue Type: Bug
Components: Core
Affects Versions: 2.3.2
Reporter: Cyril Ledru
Priority: Minor
Attachments: stringListConverter.patch
Given a textual step:
{code}
Then string is ''
{code}
the following test will fail:
{code}
@Then("string is '$params'")
public void empty(List<String> params) {
ensureThat(params.isEmpty(), equalTo(true));
}
{code}
A more likely scenario would be a table example:
{code}
Scenario: <Guess> marks as <Mark>
Given the secret r,g,y,b
When I guess [Guess]
Then I should get [Mark]
Examples:
|Guess|Mark|
|c,c,c,c||
|b,c,c,c|m|
{code}
where the first row would fail if Mark were compared to an empty List.
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
http://jira.codehaus.org/secure/Administrators.jspa
-
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