ITable tableBefore = createOrderedTable(tableName, columnNames[0]); assertEquals("row count before", 3, tableBefore.getRowCount());
assertEquals("array lenght", tableNames.length, tableRowCount.length); for (int i = 0; i < tableNames.length; i++) { ITable tableBefore = createOrderedTable(tableNames[i], primaryKey); assertEquals("row count before", tableRowCount[i], tableBefore.getRowCount()); }
    public void testExecute() throws Exception    {        String tableName = "PK_TABLE";        String[] columnNames = {"PK0", "PK1", "PK2", "NORMAL0", "NORMAL1"};        int updatedRow = 1;        int insertedRow = 3;        IDataSet xmlDataSet = new FlatXmlDataSet(                new FileInputStream("src/xml/refreshOperationTest.xml"));        // verify table before        ITable tableBefore = createOrderedTable(tableName, columnNames[0]);        assertEquals("row count before", 3, tableBefore.getRowCount());        DatabaseOperation.REFRESH.execute(_connection, xmlDataSet);        // verify table after        IDataSet expectedDataSet = new FlatXmlDataSet(                new FileInputStream("src/xml/refreshOperationTestExpected.xml"));        ITable expectedTable = expectedDataSet.getTable("PK_TABLE");        ITable tableAfter = createOrderedTable(tableName, columnNames[0]);        DataSetUtils.assertEquals(expectedTable, tableAfter);    }