Skip to content

Commit 2daf730

Browse files
author
Ard Biesheuvel
committed
Don't rely on OS-based authentication (as it is not supported under Win32)
1 parent de56cc5 commit 2daf730

File tree

1 file changed

+8
-2
lines changed

1 file changed

+8
-2
lines changed

ext/interbase/tests/interbase.inc

Lines changed: 8 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,14 +2,20 @@
22

33
srand((double)microtime()*1000000);
44

5+
$user = 'SYSDBA';
6+
$password = 'masterkey';
7+
ini_set('ibase.default_user',$user);
8+
ini_set('ibase.default_password',$password);
9+
510
/* we need just the generated name, not the file itself */
611
unlink($test_base = tempnam('/tmp',"php_ibase_test"));
712

813
function init_db()
914
{
10-
global $test_base;
15+
global $test_base, $user, $password;
1116

12-
$test_db = ibase_query("CREATE DATABASE \"$test_base\"");
17+
$test_db = ibase_query(sprintf("CREATE DATABASE '%s' USER '%s' PASSWORD '%s'",
18+
$test_base, $user, $password));
1319
$tr = ibase_trans($test_db);
1420
ibase_query($tr,"create table test1 (i integer, c varchar(100))");
1521
ibase_commit_ret($tr);

0 commit comments

Comments
 (0)