| 73 | } |
| 74 | |
| 75 | void ODBCTestBase::ConnectWithString(std::string connect_str) { |
| 76 | // Connect string |
| 77 | std::vector<SQLWCHAR> connect_str0(connect_str.begin(), connect_str.end()); |
| 78 | |
| 79 | SQLWCHAR out_str[kOdbcBufferSize]; |
| 80 | SQLSMALLINT out_str_len; |
| 81 | |
| 82 | // Connecting to ODBC server. |
| 83 | ASSERT_EQ(SQL_SUCCESS, |
| 84 | SQLDriverConnect(conn, NULL, &connect_str0[0], |
| 85 | static_cast<SQLSMALLINT>(connect_str0.size()), out_str, |
| 86 | kOdbcBufferSize, &out_str_len, SQL_DRIVER_NOPROMPT)) |
| 87 | << GetOdbcErrorMessage(SQL_HANDLE_DBC, conn); |
| 88 | } |
| 89 | |
| 90 | void ODBCTestBase::Disconnect() { |
| 91 | // Disconnect from ODBC |
no test coverage detected