MAPG-177 add tests for View\Parser

This commit is contained in:
bence committed 2020-06-28 22:55:15 +02:00
1 parent 34f0c92eb5
commit 149003250c
9 files changed
+194

No files matched your search

+22
View File
@@ -0,0 +1,22 @@
@css(test1.css)
@js(test1.js)
@js(test2_<?= $some['expression'] ?>)
@extra
<?php phpinfo() ?>
@endextra
@extends(parent)
@section(section1)
<div>Test HTML with @extends - section 1</div>
@endsection
@section(section2)
<div>Test HTML with @extends - section 2</div>
@endsection
@extra
<?php $a = 'test_string' ?>
EXTRA
@endextra
@@ -0,0 +1,5 @@
@extends(parent1)
@extends(parent2)
<div>Test HTML with multiple @extends</div>
@@ -0,0 +1,6 @@
@extends(parent)
@section(section1)
@section(section2)
<div>Test HTML with opening @section before previous closed</div>
@@ -0,0 +1,4 @@
@extends(parent)
<div>Test HTML with @endsection when no section is open</div>
@endsection
@@ -0,0 +1,3 @@
@section(section1)
<div>Test HTML with @section but without @extends</div>
+4
View File
@@ -0,0 +1,4 @@
@css(test.css)
@js(test.js)
@js(test_<?= $some['expression'] ?>)
<div>Test HTML with @css and @js</div>
+5
View File
@@ -0,0 +1,5 @@
@extends(parent)
@section(section1)
<div>Test HTML with @extends</div>
@endsection
@@ -0,0 +1 @@
<div>Test HTML without @extends</div>