Fix comp. with 5.3

This commit is contained in:
bzick 2016-06-09 14:30:20 +03:00
parent e357a38946
commit a910b71a81

View File

@ -262,10 +262,11 @@ class AccessorTest extends TestCase
*/ */
public function testCallbackAccessor() { public function testCallbackAccessor() {
$index = 1; $index = 1;
$this->fenom->addAccessorCallback('index', function($name, $template, $vars) use (&$index) { $test = $this;
$this->assertInstanceOf('Fenom\Render', $template); $this->fenom->addAccessorCallback('index', function($name, $template, $vars) use (&$index, $test) {
$this->assertSame(1, $vars['one']); $test->assertInstanceOf('Fenom\Render', $template);
$this->assertSame('index', $name); $test->assertSame(1, $vars['one']);
$test->assertSame('index', $name);
return $index++; return $index++;
}); });