Skip to content

Commit

Permalink
Fixed sqlsrv test
Browse files Browse the repository at this point in the history
  • Loading branch information
yitam committed Dec 19, 2019
1 parent 6896bb3 commit 0b3f113
Showing 1 changed file with 4 additions and 13 deletions.
17 changes: 4 additions & 13 deletions test/functional/sqlsrv/srv_1063_test_locale.php
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<?php

// This test is invoked by srv_1063_locale_configs.phpt
// require_once('MsCommon.inc');
require_once('MsCommon.inc');

$locale = ($_SERVER['argv'][1] ?? '');

Expand All @@ -23,21 +23,13 @@
echo strftime("%A", strtotime("12/25/2020")) . PHP_EOL;
echo strftime("%B", strtotime("12/25/2020")) . PHP_EOL;

// $conn = connect();
$server = 'sql-2k16-03.galaxy.ad';
$database = 'tempdb';
$uid = 'sa';
$pwd = 'Moonshine4me';

$conn = sqlsrv_connect($server, array('UID'=>$uid, 'PWD'=>$pwd, 'Database'=>$database));
$conn = connect();

$tableName = "[" . "srv1063" . $locale . "]";
// dropTable($conn, $tableName);
dropTable($conn, $tableName);

$pi = "3.14159";

sqlsrv_query($conn, "DROP TABLE $tableName");

$stmt = sqlsrv_query($conn, "CREATE TABLE $tableName (c1 FLOAT)");
if (!$stmt) {
fatalError("Failed to create test table $tableName");
Expand All @@ -60,8 +52,7 @@

sqlsrv_free_stmt($stmt);

// dropTable($conn, $tableName);
sqlsrv_query($conn, "DROP TABLE $tableName");
dropTable($conn, $tableName);

sqlsrv_close($conn);

Expand Down

0 comments on commit 0b3f113

Please sign in to comment.