blob: baf805a69afca342251236413a93a2293647d1f3 (
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
32
33
34
35
|
<?php
/**
* Smarty PHPunit tests undefined Smarty special variable
*
* @author Uwe Tews
*/
/**
* class for undefined Smarty special variable tests
*
*
*
*
*/
class SmartyErrorTest extends PHPUnit_Smarty
{
public function setUp(): void
{
$this->setUpSmarty(__DIR__);
}
public function testInit()
{
$this->cleanDirs();
}
/**
* test undefined Smarty special variable
*/
public function testSmartyError() {
$this->expectException(\Smarty\Exception::class);
$this->expectExceptionMessage('$smarty.foo is not defined');
$this->assertEquals(\Smarty\Smarty::SMARTY_VERSION, $this->smarty->fetch('error.tpl'));
}
}
|