ParameterConverter converter = new MethodReturningConverter(method, new SomeSteps());
assertThat(converter.accept(method.getReturnType()), is(true));
assertThat(converter.accept(WrongType.class), is(false));
assertThat(converter.accept(mock(Type.class)), is(false));
String value = "|col1|col2|\n|row11|row12|\n|row21|row22|\n";
ExamplesTable table = (ExamplesTable) converter.convertValue(value, ExamplesTable.class);
assertThat(table.getRowCount(), equalTo(2));
Map<String, String> row1 = table.getRow(0);
assertThat(row1.get("col1"), equalTo("row11"));
assertThat(row1.get("col2"), equalTo("row12"));
Map<String, String> row2 = table.getRow(1);