Search in sources :

Example 11 with ResultSetCopier

use of org.apache.drill.exec.physical.resultSet.ResultSetCopier in project drill by apache.

the class TestResultSetCopier method testImmediateClose.

@Test
public void testImmediateClose() {
    ResultSetCopier copier = newCopier(new DataGen());
    // Close OK before things got started
    copier.close();
    // Second close is benign
    copier.close();
}
Also used : ResultSetCopier(org.apache.drill.exec.physical.resultSet.ResultSetCopier) SubOperatorTest(org.apache.drill.test.SubOperatorTest) Test(org.junit.Test)

Example 12 with ResultSetCopier

use of org.apache.drill.exec.physical.resultSet.ResultSetCopier in project drill by apache.

the class TestResultSetCopier method testCloseWithData.

@Test
public void testCloseWithData() {
    ResultSetCopier copier = newCopier(new DataGen());
    // Start batch, with data.
    copier.startOutputBatch();
    copier.nextInputBatch();
    copier.copyNextRow();
    // Close OK with input and output batch allocated.
    copier.close();
    // Second close is benign
    copier.close();
}
Also used : ResultSetCopier(org.apache.drill.exec.physical.resultSet.ResultSetCopier) SubOperatorTest(org.apache.drill.test.SubOperatorTest) Test(org.junit.Test)

Aggregations

ResultSetCopier (org.apache.drill.exec.physical.resultSet.ResultSetCopier)12 SubOperatorTest (org.apache.drill.test.SubOperatorTest)12 Test (org.junit.Test)12 RowSet (org.apache.drill.exec.physical.rowSet.RowSet)9 RowSetBuilder (org.apache.drill.exec.physical.rowSet.RowSetBuilder)2 RowSetComparison (org.apache.drill.test.rowSet.RowSetComparison)1