Skip to content

Commit 240d05c

Browse files
committed
more tests
1 parent 7704f48 commit 240d05c

File tree

17 files changed

+51
-78
lines changed

17 files changed

+51
-78
lines changed

test/fixtures/test_input/about.md

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,4 @@
1+
---
2+
title: Hello
3+
---
4+
World.

test/fixtures/test_input/config.yml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
margin: 20
Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
<%= bar.is_bar %>
Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
is_bar: true

test/fixtures/test_input/foo/foo.ejs

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
<%= foo.is_foo %>
2+
<%= bar.bar.is_bar %>

test/fixtures/test_input/foo/foo.yml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
is_foo: true
Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
body {
2+
margin: <%= config.margin %>;
3+
}

test/fixtures/test_input/index.ejs

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,14 @@
1+
<!DOCTYPE html>
2+
<html><head><title><%= about.title %></title></head><body>
3+
<pre><code>
4+
about: <%= JSON.stringify(about) %>
5+
config: <%= JSON.stringify(config) %>
6+
root: <%= root === about.root && root === config.root && root === foo.root && root === foo.bar.root %>
7+
foo: <%= foo.foo.is_foo %> <%= Object.keys(foo).join() %>
8+
bar: <%= foo.bar.bar.is_bar %> <%= Object.keys(foo.bar).join() %>
9+
rootPath: <%= rootPath %>
10+
foo.rootPath: <%= foo.rootPath %>
11+
bar.rootPath: <%= foo.bar.rootPath %>
12+
bar.bar.rootPath: <%= foo.bar.bar.rootPath %>
13+
</code></pre>
14+
</body></html>
Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
true
Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
true
2+
true

0 commit comments

Comments
 (0)