@@ -275,12 +275,12 @@ public function testEscapedArguments() {
275
275
);
276
276
}
277
277
278
- public function testControlWhitespace () {
278
+ public function testLoopWhitespace () {
279
279
$ this ->assertEquals (
280
280
'before[out:SingleItem.Test]after
281
281
beforeTestafter ' ,
282
- $ this ->render ('before<% control SingleItem %>$Test<% end_control %>after
283
- before<% control SingleItem %>Test<% end_control %>after ' )
282
+ $ this ->render ('before<% loop SingleItem %>$Test<% end_loop %>after
283
+ before<% loop SingleItem %>Test<% end_loop %>after ' )
284
284
);
285
285
286
286
// The control tags are removed from the output, but no whitespace
@@ -293,9 +293,9 @@ public function testControlWhitespace() {
293
293
294
294
after ' ,
295
295
$ this ->render ('before
296
- <% control SingleItem %>
296
+ <% loop SingleItem %>
297
297
$ItemOnItsOwnLine
298
- <% end_control %>
298
+ <% end_loop %>
299
299
after ' )
300
300
);
301
301
@@ -313,9 +313,9 @@ public function testControlWhitespace() {
313
313
314
314
after ' ,
315
315
$ this ->render ('before
316
- <% control Loop3 %>
316
+ <% loop Loop3 %>
317
317
$ItemOnItsOwnLine
318
- <% end_control %>
318
+ <% end_loop %>
319
319
after ' )
320
320
);
321
321
}
@@ -328,28 +328,28 @@ public function testControls() {
328
328
[out:Foo(Arg1).Item]
329
329
[out:Foo(Arg1,Arg2).Item]
330
330
[out:Foo(Arg1,Arg2,Arg3).Item] ' ,
331
- $ this ->render ('<% control Foo.Bar %>a{$Item}b<% end_control %>
332
- <% control Foo.Bar(Arg1) %>$Item<% end_control %>
333
- <% control Foo(Arg1) %>$Item<% end_control %>
334
- <% control Foo(Arg1, Arg2) %>$Item<% end_control %>
335
- <% control Foo(Arg1, Arg2, Arg3) %>$Item<% end_control %> ' )
331
+ $ this ->render ('<% with Foo.Bar %>a{$Item}b<% end_with %>
332
+ <% with Foo.Bar(Arg1) %>$Item<% end_with %>
333
+ <% with Foo(Arg1) %>$Item<% end_with %>
334
+ <% with Foo(Arg1, Arg2) %>$Item<% end_with %>
335
+ <% with Foo(Arg1, Arg2, Arg3) %>$Item<% end_with %> ' )
336
336
);
337
337
338
338
// Loop controls
339
339
$ this ->assertEquals ('a[out:Foo.Loop2.Item]ba[out:Foo.Loop2.Item]b ' ,
340
- $ this ->render ('<% control Foo.Loop2 %>a{$Item}b<% end_control %> ' ));
340
+ $ this ->render ('<% loop Foo.Loop2 %>a{$Item}b<% end_loop %> ' ));
341
341
342
342
$ this ->assertEquals ('[out:Foo.Loop2(Arg1).Item][out:Foo.Loop2(Arg1).Item] ' ,
343
- $ this ->render ('<% control Foo.Loop2(Arg1) %>$Item<% end_control %> ' ));
343
+ $ this ->render ('<% loop Foo.Loop2(Arg1) %>$Item<% end_loop %> ' ));
344
344
345
345
$ this ->assertEquals ('[out:Loop2(Arg1).Item][out:Loop2(Arg1).Item] ' ,
346
- $ this ->render ('<% control Loop2(Arg1) %>$Item<% end_control %> ' ));
346
+ $ this ->render ('<% loop Loop2(Arg1) %>$Item<% end_loop %> ' ));
347
347
348
348
$ this ->assertEquals ('[out:Loop2(Arg1,Arg2).Item][out:Loop2(Arg1,Arg2).Item] ' ,
349
- $ this ->render ('<% control Loop2(Arg1, Arg2) %>$Item<% end_control %> ' ));
349
+ $ this ->render ('<% loop Loop2(Arg1, Arg2) %>$Item<% end_loop %> ' ));
350
350
351
351
$ this ->assertEquals ('[out:Loop2(Arg1,Arg2,Arg3).Item][out:Loop2(Arg1,Arg2,Arg3).Item] ' ,
352
- $ this ->render ('<% control Loop2(Arg1, Arg2, Arg3) %>$Item<% end_control %> ' ));
352
+ $ this ->render ('<% loop Loop2(Arg1, Arg2, Arg3) %>$Item<% end_loop %> ' ));
353
353
354
354
}
355
355
0 commit comments