expectStatusAndScanCount(SCHEMA, I_NAME, iCount);
}
@Test
public void renameAllSchemasAndTablesParentDownWithRestartsBetween() throws Exception {
final TableName NEW_NAMES[] = { tableName("j","k"), tableName("l","m"),
tableName("n","o"), tableName("p","q") };
TableName curNames[] = { tableName(SCHEMA, C_NAME), tableName(SCHEMA, A_NAME),
tableName(SCHEMA, O_NAME), tableName(SCHEMA, I_NAME) };
createCTable();
createATable();
createOTable();
createITable();
final int COUNTS[] = { writeCRows(), writeARows(), writeORows(), writeIRows() };
for(int i = 0; i < NEW_NAMES.length; ++i) {
ddl().renameTable(session(), curNames[i], NEW_NAMES[i]);
curNames[i] = NEW_NAMES[i];
safeRestartTestServices();
for(int j = 0; j < curNames.length; ++j) {
TableName tn = curNames[j];
expectStatusAndScanCount(tn.getSchemaName(), tn.getTableName(), COUNTS[j]);
}
}
}