TableDiff with list of pojos: camelcase convert of column names to field names #385

merged 1 commit into from Oct 8, 2012


None yet

3 participants

mbusik commented Sep 1, 2012


public void given_method(List<pojo> input) {

List<pojo> calculated;

public void then_phrase(DataTable expected) throws Throwable {

Diff fails, if column headers in the expected table are not written exactly the same as the field members of the pojo (even if expected and calculated are equal).

In contrast, in the @Given implementation cucumber does convert column headings to field names (camelCase).

It would be more consistent, if the same mapping rules were applied to the conversion DataDable <-> list of pojos

The present pull request contains a column header -> fieldname mapping in the ComplexTypeWriter used in the diff method.


This pull request passes (merged 154d458 into 2f3a115).

@aslakhellesoy aslakhellesoy merged commit 0ec5551 into cucumber:master Oct 8, 2012

1 check passed

Details default The Travis build passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment