summaryrefslogtreecommitdiff
path: root/tests/test_autoescape/code.php
diff options
context:
space:
mode:
Diffstat (limited to 'tests/test_autoescape/code.php')
-rw-r--r--tests/test_autoescape/code.php7
1 files changed, 4 insertions, 3 deletions
diff --git a/tests/test_autoescape/code.php b/tests/test_autoescape/code.php
index 4f7c998..9f73700 100644
--- a/tests/test_autoescape/code.php
+++ b/tests/test_autoescape/code.php
@@ -2,13 +2,14 @@
use kch42\ste\STECore;
+$ste_initializer = function($sa) {
+ return new STECore($sa, STECore::ESCAPE_HTML);
+};
+
function test_func($ste) {
$ste->vars['test'] = 'foo"&<bar>';
$ste->register_tag('echoarg', function ($ste, $params, $sub) {
return $params['echo'];
});
-
- // Autoescaping enabled by default
- $ste->escape_method = STECore::ESCAPE_HTML;
}