Open jtchatchoua opened 8 years ago
private void checkDatas(TestContext testContext) throws Exception { ExpectedDataSetConfiguration expectedConfiguration = getExpectedConfiguration(testContext); if (expectedConfiguration != null) { IDataSet expectedDataSet = expectedConfiguration.getDataSet(); for (String tableName : expectedDataSet.getTableNames()) { IDataSet dataSet = dataReader.execute(testContext.getApplicationContext(), getExpectedConfiguration(testContext), tableName); String[] columnsToIgnore = expectedConfiguration.getColumnsToIgnore(); if (columnsToIgnore == null || columnsToIgnore.length == 0) {
`Assertion.assertEquals(expectedDataSet, dataSet);`
// When the dataset has more than one table, test fails when compare tableNames length. I think the code here should be Assertion.assertEquals(expectedDataSet.getTable(tableName), dataSet.getTable(tableName));
Assertion.assertEquals(expectedDataSet.getTable(tableName), dataSet.getTable(tableName));
} else { Assertion.assertEqualsIgnoreCols(expectedDataSet, dataSet, tableName, columnsToIgnore); } } }
private void checkDatas(TestContext testContext) throws Exception { ExpectedDataSetConfiguration expectedConfiguration = getExpectedConfiguration(testContext); if (expectedConfiguration != null) { IDataSet expectedDataSet = expectedConfiguration.getDataSet(); for (String tableName : expectedDataSet.getTableNames()) { IDataSet dataSet = dataReader.execute(testContext.getApplicationContext(), getExpectedConfiguration(testContext), tableName); String[] columnsToIgnore = expectedConfiguration.getColumnsToIgnore(); if (columnsToIgnore == null || columnsToIgnore.length == 0) {
// When the dataset has more than one table, test fails when compare tableNames length. I think the code here should be
Assertion.assertEquals(expectedDataSet.getTable(tableName), dataSet.getTable(tableName));