@@ -96,8 +96,8 @@ public function testPHP_PASSTHRU_script()
9696 public function testPHP_QUOTE_php ()
9797 {
9898 $ this ->smarty ->setPhpHandling (Smarty::PHP_QUOTE );
99- $ content = $ this ->smarty ->fetch ("string:qa<?php echo 'hello world'; ?>qe " );
100- $ this ->assertEquals ("qa<?php echo 'hello world'; ?>qe " , $ content , 'qoute <?php ?> ' );
99+ $ content = $ this ->smarty ->fetch ("string:qa<?php echo 'hello world'; \n echo ' multiline'; ?>qe " );
100+ $ this ->assertEquals ("qa<?php echo 'hello world'; \n echo ' multiline'; ?>qe " , $ content , 'qoute <?php ?> ' );
101101 }
102102 /**
103103 * test <%...%> tag
@@ -135,9 +135,9 @@ public function testPHP_ALLOW_php()
135135 public function testPHP_ALLOW_asp ()
136136 {
137137 $ this ->smartyBC ->setPhpHandling (Smarty::PHP_ALLOW );
138- $ content = $ this ->smartyBC ->fetch ("string:aa <% echo 'hello world';%> ae " );
138+ $ content = $ this ->smartyBC ->fetch ("string:aa <% echo 'hello world'; \n echo ' multiline'; %> ae " );
139139 if (ini_get ('asp_tags ' )) {
140- $ this ->assertEquals ('aa hello world ae ' , $ content , 'allow <% %> ' );
140+ $ this ->assertEquals ('aa hello world multiline ae ' , $ content , 'allow <% %> ' );
141141 } else {
142142 $ this ->assertEquals ("aa <% echo 'hello world';%> ae " , $ content , 'allow asp disabled <% %> ' );
143143 }
@@ -149,8 +149,8 @@ public function testPHP_ALLOW_asp()
149149 public function testPHP_ALLOW_script ()
150150 {
151151 $ this ->smartyBC ->setPhpHandling (Smarty::PHP_ALLOW );
152- $ content = $ this ->smartyBC ->fetch ("string:aa <script language='php'> echo 'hello world';</script> ae " );
153- $ this ->assertEquals ('aa hello world ae ' , $ content , "allow <script language='php'> " );
152+ $ content = $ this ->smartyBC ->fetch ("string:aa <script language='php'> echo 'hello world'; \n echo ' multiline'; </script> ae " );
153+ $ this ->assertEquals ('aa hello world multiline ae ' , $ content , "allow <script language='php'> " );
154154 }
155155 /**
156156 * test <?php...\> tag
@@ -159,8 +159,8 @@ public function testPHP_ALLOW_script()
159159 public function testPHP_ALLOW_php2 ()
160160 {
161161 $ this ->smartyBC ->setPhpHandling (Smarty::PHP_ALLOW );
162- $ content = $ this ->smartyBC ->fetch ("string:aa <?php echo '<?php'; ?> ae " );
163- $ this ->assertEquals ('aa <?php ae ' , $ content );
162+ $ content = $ this ->smartyBC ->fetch ("string:aa <?php echo '<?php'; \n echo ' ?>'; ?> ae " );
163+ $ this ->assertEquals ('aa <?php ?> ae ' , $ content );
164164 }
165165 /**
166166 * test <?php...\> tag
0 commit comments