Skip to content

Unit test fixes #1455

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

Merged
merged 4 commits into from
Aug 9, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 3 additions & 3 deletions test/functional/pdo_sqlsrv/pdo_1261_test_ascii_utf8.phpt
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ try {
ini_set('pdo_sqlsrv.log_severity', '2');
ini_set('error_log', $logFilepath);

$conn = new PDO("sqlsrv:Server=$server;Database=$databaseName;", $uid, $pwd);
$conn = new PDO("sqlsrv:Server=$server;Database=$databaseName;driver=$driver;", $uid, $pwd);
$conn->setAttribute(PDO::SQLSRV_ATTR_ENCODING, PDO::SQLSRV_ENCODING_SYSTEM);
$conn->setAttribute(PDO::ATTR_ERRMODE, PDO::ERRMODE_EXCEPTION);

Expand Down Expand Up @@ -50,8 +50,8 @@ array(1) {
}
[%s] pdo_sqlsrv_db_handle_factory: SQLSTATE = 01000
[%s] pdo_sqlsrv_db_handle_factory: error code = 5701
[%s] pdo_sqlsrv_db_handle_factory: message = [Microsoft][ODBC Driver 17 for SQL Server][SQL Server]Changed database context to '%s'.
[%s] pdo_sqlsrv_db_handle_factory: message = [Microsoft][ODBC Driver %s for SQL Server][SQL Server]Changed database context to '%s'.
[%s] pdo_sqlsrv_db_handle_factory: SQLSTATE = 01000
[%s] pdo_sqlsrv_db_handle_factory: error code = 5703
[%s] pdo_sqlsrv_db_handle_factory: message = [Microsoft][ODBC Driver 17 for SQL Server][SQL Server]Changed language setting to %s.
[%s] pdo_sqlsrv_db_handle_factory: message = [Microsoft][ODBC Driver %s for SQL Server][SQL Server]Changed language setting to %s.

5 changes: 1 addition & 4 deletions test/functional/pdo_sqlsrv/pdo_construct.phpt
Original file line number Diff line number Diff line change
Expand Up @@ -24,15 +24,12 @@ try {

$dsn = "ConnectionPooling = false;" .
"APP = whatever;" .
"LoginTimeout = 1;" .
"ApplicationIntent = ReadOnly;" .
"Encrypt = false;" .
"Failover_Partner = whatever;" .
"MultipleActiveResultSets = true;" .
"MultiSubnetFailover = NO;" .
"QuotedId = false;" .
"TraceFile = whatever;" .
"TraceOn = true;" .
"TransactionIsolation = " . PDO::SQLSRV_TXN_READ_UNCOMMITTED . ";" .
"TrustServerCertificate = false;" .
"WSID = whatever;";
Expand All @@ -53,4 +50,4 @@ array(3) {
[2]=>
string(58) "An unsupported attribute was designated on the PDO object."
}
Test Successful
Test Successful
3 changes: 0 additions & 3 deletions test/functional/pdo_sqlsrv/pdo_construct_conn_options.phpt
Original file line number Diff line number Diff line change
Expand Up @@ -10,15 +10,12 @@ require_once("MsCommon_mid-refactor.inc");
try {
$dsn = "ConnectionPooling = false;" .
"APP = whatever;" .
"LoginTimeout = 1;" .
"ApplicationIntent = ReadOnly;" .
"Encrypt = false;" .
"Failover_Partner = whatever;" .
"MultipleActiveResultSets = true;" .
"MultiSubnetFailover = NO;" .
"QuotedId = false;" .
"TraceFile = whatever;" .
"TraceOn = true;" .
"TrustServerCertificate = false;" .
"WSID = whatever;";
$conn = connect($dsn);
Expand Down
4 changes: 0 additions & 4 deletions test/functional/sqlsrv/sqlsrv_testConnection_unix.phpt
Original file line number Diff line number Diff line change
Expand Up @@ -73,8 +73,6 @@ if ((strtoupper(substr(php_uname('s'), 0, 3)) === 'WIN')) {
"LoginTimeout" => 120,
"MultipleActiveResultSets" => false,
"QuotedId" => false,
"TraceOn" => true,
"TraceFile" => "trace.odbc",
"TransactionIsolation" => SQLSRV_TXN_READ_COMMITTED,
"TrustServerCertificate" => 1,
"WSID" => "JAYKINT1" );
Expand All @@ -85,8 +83,6 @@ if ((strtoupper(substr(php_uname('s'), 0, 3)) === 'WIN')) {
"LoginTimeout" => 120,
"MultipleActiveResultSets" => false,
"QuotedId" => true,
"TraceOn" => true,
"TraceFile" => "trace.odbc",
"TransactionIsolation" => SQLSRV_TXN_READ_COMMITTED,
"TrustServerCertificate" => 1,
"WSID" => "JAYKINT1" );
Expand Down