File: 11transactions.phpt

package info (click to toggle)
php-db 1.7.14-3
  • links: PTS, VCS
  • area: main
  • in suites: jessie, jessie-kfreebsd
  • size: 984 kB
  • ctags: 1,768
  • sloc: php: 6,933; pascal: 1,001; xml: 213; sh: 31; makefile: 13
file content (26 lines) | stat: -rwxr-xr-x 815 bytes parent folder | download | duplicates (2)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
--TEST--
DB_driver::transaction test
--INI--
error_reporting = 2047
--SKIPIF--
<?php
require_once dirname(__FILE__) . '/skipif.inc';
if (!$dbh->features['transactions']) {
    die('skip this driver does not support transactions');
}
?>
--FILE--
<?php
$needinnodb = true;
require_once dirname(__FILE__) . '/mktable.inc';
require_once dirname(__FILE__) . '/../transactions.inc';
?>
--EXPECT--
1) after autocommit: bing one.  ops=ok
2) before commit: bing one two three.  ops=ok
3) after commit: bing one two three.  ops=ok
4) before rollback: bing one two three four five.  ops=ok
5) after rollback: bing one two three.  ops=ok
6) before autocommit+rollback: bing one two three six seven.  ops=ok
7) after autocommit+rollback: bing one two three six seven.  ops=ok
8) testing that select doesn't disturbe opcount: ok