Move examples into the test fixtures.

This commit is contained in:
Justin Hileman
2012-03-26 19:05:08 -07:00
parent 99a5e9b14a
commit 1430b27f86
77 changed files with 7 additions and 10 deletions
@@ -0,0 +1,33 @@
<?php
class SectionsNested {
public $name = 'Little Mac';
public function enemies() {
return array(
array(
'name' => 'Von Kaiser',
'enemies' => array(
array('name' => 'Super Macho Man'),
array('name' => 'Piston Honda'),
array('name' => 'Mr. Sandman'),
)
),
array(
'name' => 'Mike Tyson',
'enemies' => array(
array('name' => 'Soda Popinski'),
array('name' => 'King Hippo'),
array('name' => 'Great Tiger'),
array('name' => 'Glass Joe'),
)
),
array(
'name' => 'Don Flamenco',
'enemies' => array(
array('name' => 'Bald Bull'),
)
),
);
}
}
@@ -0,0 +1,7 @@
Enemies of {{ name }}:
{{# enemies }}
{{ name }} ... who also has enemies:
{{# enemies }}
--> {{ name }}
{{/ enemies }}
{{/ enemies }}
@@ -0,0 +1,12 @@
Enemies of Little Mac:
Von Kaiser ... who also has enemies:
--> Super Macho Man
--> Piston Honda
--> Mr. Sandman
Mike Tyson ... who also has enemies:
--> Soda Popinski
--> King Hippo
--> Great Tiger
--> Glass Joe
Don Flamenco ... who also has enemies:
--> Bald Bull