added test for pdo construct without server specified

This commit is contained in:
v-kaywon 2017-04-04 12:35:08 -07:00
parent 4ff9aae585
commit 65c79ef344

View file

@ -0,0 +1,22 @@
--TEST--
Test PDO::__Construct without specifying the Server
--SKIPIF--
--FILE--
<?php
require_once("autonomous_setup.php");
try
{
$database = "tempdb";
// Try to connect with no server specific
@$conn = new PDO( "sqlsrv:Database = $database", $username, $password );
}
catch( PDOException $e ) {
print_r( ($e->errorInfo)[2] );
}
?>
--EXPECT--
Server keyword was not specified in the DSN string.