File: sql_ident.phpt

package info (click to toggle)
php-log 1.13.2-2
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid, trixie
  • size: 496 kB
  • sloc: php: 1,917; xml: 593; makefile: 11; sql: 8
file content (27 lines) | stat: -rw-r--r-- 482 bytes parent folder | download | duplicates (4)
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
27
--TEST--
Log: SQL setIdent()
--SKIPIF--
<?php

require_once 'PEAR/Registry.php';
$registry = new PEAR_Registry();

if (!$registry->packageExists('DB')) die("skip\n");
--INI--
date.timezone=UTC
--FILE--
<?php

require_once 'Log.php';

$ident = '12345678901234567890';

$logger = Log::singleton('sql', 'log_table', $ident, array('dsn' => ''));
echo $logger->getIdent() . "\n";

$logger->setIdent($ident);
echo $logger->getIdent() . "\n";

--EXPECT--
1234567890123456
1234567890123456