paleolimbot commented on code in PR #870:
URL: https://github.com/apache/arrow-adbc/pull/870#discussion_r1255833013


##########
c/driver/postgresql/postgresql_test.cc:
##########
@@ -638,6 +638,48 @@ TEST_F(PostgresStatementTest, UpdateInExecuteQuery) {
   }
 }
 
+TEST_F(PostgresStatementTest, BatchSizeHint) {
+  ASSERT_THAT(quirks()->EnsureSampleTable(&connection, "batch_size_hint_test", 
&error),
+              IsOkStatus(&error));
+  ASSERT_THAT(AdbcStatementNew(&connection, &statement, &error), 
IsOkStatus(&error));
+
+  ASSERT_EQ(AdbcStatementSetOption(&statement, 
"adbc.postgresql.batch_size_hint_bytes",
+                                   "-1", nullptr),
+            ADBC_STATUS_INVALID_ARGUMENT);
+  ASSERT_EQ(AdbcStatementSetOption(&statement, 
"adbc.postgresql.batch_size_hint_bytes",
+                                   "not a valid number", nullptr),
+            ADBC_STATUS_INVALID_ARGUMENT);
+
+  ASSERT_THAT(AdbcStatementSetOption(&statement, 
"adbc.postgresql.batch_size_hint_bytes",
+                                     "1", &error),

Review Comment:
   I added some comments to that test to explain what the `"1"` was doing 🙂 



-- 
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