xref: /php-src/ext/dba/tests/dba_db4_009.phpt (revision eddab740)
1--TEST--
2DBA DB4 Multiple File Creation Test
3--EXTENSIONS--
4dba
5--SKIPIF--
6<?php
7require_once __DIR__ . '/setup/setup_dba_tests.inc';
8check_skip('db4');
9?>
10--FILE--
11<?php
12$handler = "db4";
13echo "database handler: $handler\n";
14$db_file1 = __DIR__.'/test1.dbm';
15$db_file2 = __DIR__.'/test2.dbm';
16$db_file1 = dba_open($db_file1, "n", $handler);
17$db_file2 = dba_open($db_file2, "n", $handler);
18var_dump(dba_list());
19dba_close($db_file1);
20dba_close($db_file2);
21
22?>
23--CLEAN--
24<?php
25$db_filename1 = __DIR__.'/test1.dbm';
26$db_filename2 = __DIR__.'/test2.dbm';
27@unlink($db_filename1);
28@unlink($db_filename2);
29?>
30--EXPECTF--
31database handler: db4
32array(2) {
33  [%d]=>
34  string(%d) "%stest1.dbm"
35  [%d]=>
36  string(%d) "%stest2.dbm"
37}
38