Index: core/jbehave-core/src/java/org/jbehave/scenario/steps/ParameterConverters.java =================================================================== --- core/jbehave-core/src/java/org/jbehave/scenario/steps/ParameterConverters.java (revision 1391) +++ core/jbehave-core/src/java/org/jbehave/scenario/steps/ParameterConverters.java (working copy) @@ -179,6 +179,7 @@ } public Object convertValue(String value, Type type) { + if ("".equals(value)) return asList(); return trim(asList(value.split(valueSeparator))); } Index: core/jbehave-core/src/behaviour/org/jbehave/scenario/steps/ParameterConvertersBehaviour.java =================================================================== --- core/jbehave-core/src/behaviour/org/jbehave/scenario/steps/ParameterConvertersBehaviour.java (revision 1391) +++ core/jbehave-core/src/behaviour/org/jbehave/scenario/steps/ParameterConvertersBehaviour.java (working copy) @@ -70,6 +70,28 @@ ensureThat(list.get(3), equalTo(numberFormat.parse("8.00"))); } + @SuppressWarnings("unchecked") + @Test + public void shouldConvertCommaSeparatedValuesToListOfStrings() throws IntrospectionException { + ParameterConverters converters = new ParameterConverters(); + Type type = SomeSteps.methodFor("aMethodWithListOfStrings") + .getGenericParameterTypes()[0]; + List list = (List) converters.convert( + "a, string ", type); + ensureThat(list.get(0), equalTo("a")); + ensureThat(list.get(1), equalTo("string")); + } + + @SuppressWarnings("unchecked") + @Test + public void shouldConvertEmptyStringToEmptyListOfStrings() throws IntrospectionException { + ParameterConverters converters = new ParameterConverters(); + Type type = SomeSteps.methodFor("aMethodWithListOfStrings") + .getGenericParameterTypes()[0]; + List list = (List) converters.convert("", type); + ensureThat(list.isEmpty(), equalTo(true)); + } + @Test public void shouldConvertMultilineTableParameter() throws ParseException, IntrospectionException {