zixi-bwang commented on a change in pull request #11931:
URL: https://github.com/apache/arrow/pull/11931#discussion_r768380708



##########
File path: csharp/test/Apache.Arrow.Tests/ArrowFileReaderTests.cs
##########
@@ -155,5 +157,19 @@ public async Task TestReadMultipleRecordBatchAsync()
                 ArrowReaderVerifier.CompareBatches(originalBatch1, readBatch3);
             }
         }
+
+        [Fact]
+        public void TestRecordBatchBasics()
+        {
+            RecordBatch recordBatch = TestData.CreateSampleRecordBatch(length: 
1);
+            Assert.Throws<ArgumentOutOfRangeException>(() => new 
RecordBatch(recordBatch.Schema, recordBatch.Arrays, -1));
+
+            var col1 = recordBatch.Column(0);
+            var col2 = recordBatch.Column("list0");
+            ArrowReaderVerifier.CompareArrays(col1, col2);
+
+            recordBatch.Dispose();

Review comment:
       The reason I was calling Dispose() directly is because it seems the 
Dispose() function was not covered in the unit testing, so by calling it 
directly, I thought it could increase the code coverage.




-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]


Reply via email to