use of org.joda.time.YearMonth in project serenity-jbehave by serenity-bdd.
the class MonthYearConversionSteps method thenTheParameterShouldBeConvertedToAYearMonthWithAValueOf.
@Then("the parameter should be converted to a YearMonth with a value of <expectedValue>")
public void thenTheParameterShouldBeConvertedToAYearMonthWithAValueOf(String expectedValue) {
YearMonth expectedYearMonthValue = new YearMonth(expectedValue);
assertThat(yearMonthParameter).isEqualTo(expectedYearMonthValue);
}
use of org.joda.time.YearMonth in project serenity-jbehave by serenity-bdd.
the class YearMonthListConverter method convertValue.
public Object convertValue(String value, Type type) {
System.out.println(type);
Type argumentType = argumentType(type);
List<String> values = trim(asList(value.split(valueSeparator)));
List<YearMonth> times = new ArrayList<>();
for (String string : values) {
times.add((YearMonth) yearMonthConverter.convertValue(string, argumentType));
}
return times;
}
Aggregations