uwetews
2015-12-30 22:27:16 +01:00
parent d0f29ae730
commit e390da71e2
2 changed files with 13 additions and 0 deletions

View File

@@ -93,6 +93,14 @@ class CompilePhpTest extends PHPUnit_Smarty
$content = $this->smartyBC->fetch("string:aa {php no cache} echo 'hallo'; {/php} ae");
}
/**
* Test regression that plugin names starting with 'php' do work
*/
public function testPHPfooPlugin()
{
$this->smarty->addPluginsDir("./PHPunitplugins/");
$this->assertEquals('phptest okay', $this->smarty->fetch('string:{phptest}'));
}
public function data()
{

View File

@@ -0,0 +1,5 @@
<?php
function smarty_function_phptest($params,$smarty)
{
return 'phptest okay';
}