blob: 15d00e39c7e7e6961b798fb6a2e2d7905d6334ad (
plain)
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
28
29
30
31
|
<?php
Prado::using('System.Data.SqlMap.TSqlMapConfig');
/**
* @package System.Data.SqlMap
*/
class StatementExtendsTest extends PHPUnit_Framework_TestCase
{
protected $sqlmap;
function setup()
{
$config = new TSqlMapConfig();
$config->ConfigFile = dirname(__FILE__).'/maps/tests.xml';
$this->sqlmap = $config->getClient();
}
function test_extends1()
{
$manager = $this->sqlmap->SqlMapManager;
$sql = $manager->getMappedStatement('test')->getSqlString();
$this->assertPattern('/img_request/', $sql);
$this->assertNoPattern('/img_progress/', $sql);
$sql2 = $manager->getMappedStatement('GetAllProgress')->getSqlString();
$this->assertPattern('/img_request/', $sql2);
$this->assertPattern('/img_progress/', $sql2);
}
}
|