-
Notifications
You must be signed in to change notification settings - Fork 97
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
refactor(r): Improve testing for ADBC 1.1 features in R bindings #1214
Conversation
4e225cb
to
102807e
Compare
…functions intended to be used from C
608c12c
to
1fccb0f
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
went through the C/C++ code, left some comments / questions / nitpicks. in general it looks good to me though
|
||
explicit Error(const char* message) : Error(std::string(message)) {} | ||
|
||
Error(const std::string& message, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
also explicit
?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think this one doesn't need it because there's two arguments to the constructor?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
fair point, we aren't using default args for the second argument so you're right.
This PR implements option setting/getting in the "void" driver and implements tests for the full grid of set/get by string/bytes/integer/double by database/connection/statement. The error detail information was also not implemented in the dummy driver and so couldn't be tested (so there is an implementation of that here).
Implementing a driver that actually did this was sufficient work that I did some rather heavy abstraction to make it easier to write. That abstraction is not unlike a "driver framework" except it is (1) not complete, since the void driver only needs options methods and (2) doesn't provide any result helpers (building streams, etc.). It might be worth porting the driver base to be more general but for now I'd like to keep it constrained to what I need to test in R.
Closes #1126.