-
Notifications
You must be signed in to change notification settings - Fork 3.9k
GH-46575: [C++][FlightRPC] Add Diagnostic tests #47764
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
base: main
Are you sure you want to change the base?
Conversation
Requires SQLDriverConnect Implementation Co-authored-by: rscales <[email protected]>
|
||
namespace arrow::flight::sql::odbc { | ||
|
||
TYPED_TEST(FlightSQLODBCTestBase, TestSQLGetDiagFieldWForConnectFailure) { |
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.
Same comment here, we can subclass the base fixture and create a specific fixture for this file.
// Allocate an environment handle | ||
SQLRETURN ret = SQLAllocEnv(&env); | ||
|
||
EXPECT_EQ(SQL_SUCCESS, ret); |
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.
The test will continue even if EXPECT_ fails. Usually these kinds of checks should be ASSERT.
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.
It would be more concise to just ASSERT_EQ(SQL_SUCCESS, SQLAllocEnv(&env))
and so on.
// Test is disabled because driver manager on Windows does not pass through SQL_NTS | ||
// This test case can be potentially used on macOS/Linux | ||
GTEST_SKIP(); |
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.
If the test name starts with DISABLED_, GTest will ignore the test automatically
Rationale for this change
Putting the tests for diagnostics in a separate PR from #47763, because non-diagnostic ODBC APIs are required to get diagnostics.
What changes are included in this PR?
Are these changes tested?
Will be tested in CI when PR is ready for review
Are there any user-facing changes?
No