From: Michael Wallner Date: Wed, 19 Oct 2016 07:18:30 +0000 (+0000) Subject: tests: fix ndbm cleanup X-Git-Url: https://git.m6w6.name/?a=commitdiff_plain;h=e36f7cd568212baefd1d597adb25c0b040f66870;p=m6w6%2Fext-psi tests: fix ndbm cleanup --- diff --git a/tests/ndbm/ndbm001.phpt b/tests/ndbm/ndbm001.phpt index 27012be..2914bac 100644 --- a/tests/ndbm/ndbm001.phpt +++ b/tests/ndbm/ndbm001.phpt @@ -3,36 +3,36 @@ ndbm --INI-- psi.directory={PWD}:{PWD}/../../psi.d --SKIPIF-- - --FILE-- ===TEST=== -db = psi\dbm_open($file, $o, $m)) { throw new Exception(psi\strerror(psi\errno())); } } - + function __destruct() { psi\dbm_close($this->db); } - + function __set($k, $v) { return psi\dbm_store($this->db, [ - "dptr" => $k, + "dptr" => $k, "dsize" => strlen($k) ], [ "dptr" => $v, "dsize" => strlen($v) ], psi\DBM_REPLACE); } - + function __get($k) { $val = psi\dbm_fetch($this->db, [ "dptr" => $k, @@ -50,8 +50,8 @@ var_dump($db->key); ?> ===DONE=== --CLEAN-- - --EXPECT-- ===TEST===