summaryrefslogtreecommitdiffhomepage
path: root/caddyhttp/markdown/testdata
diff options
context:
space:
mode:
Diffstat (limited to 'caddyhttp/markdown/testdata')
-rw-r--r--caddyhttp/markdown/testdata/blog/test.md14
-rw-r--r--caddyhttp/markdown/testdata/docflags/template.txt2
-rw-r--r--caddyhttp/markdown/testdata/docflags/test.md4
-rw-r--r--caddyhttp/markdown/testdata/header.html1
-rw-r--r--caddyhttp/markdown/testdata/log/test.md14
-rw-r--r--caddyhttp/markdown/testdata/markdown_tpl.html11
-rw-r--r--caddyhttp/markdown/testdata/og/first.md5
-rw-r--r--caddyhttp/markdown/testdata/tpl_with_include.html11
8 files changed, 62 insertions, 0 deletions
diff --git a/caddyhttp/markdown/testdata/blog/test.md b/caddyhttp/markdown/testdata/blog/test.md
new file mode 100644
index 000000000..93f07a493
--- /dev/null
+++ b/caddyhttp/markdown/testdata/blog/test.md
@@ -0,0 +1,14 @@
+---
+title: Markdown test 1
+sitename: A Caddy website
+---
+
+## Welcome on the blog
+
+Body
+
+``` go
+func getTrue() bool {
+ return true
+}
+```
diff --git a/caddyhttp/markdown/testdata/docflags/template.txt b/caddyhttp/markdown/testdata/docflags/template.txt
new file mode 100644
index 000000000..2b001388f
--- /dev/null
+++ b/caddyhttp/markdown/testdata/docflags/template.txt
@@ -0,0 +1,2 @@
+Doc.var_string {{.Doc.var_string}}
+Doc.var_bool {{.Doc.var_bool}}
diff --git a/caddyhttp/markdown/testdata/docflags/test.md b/caddyhttp/markdown/testdata/docflags/test.md
new file mode 100644
index 000000000..64ca7f78d
--- /dev/null
+++ b/caddyhttp/markdown/testdata/docflags/test.md
@@ -0,0 +1,4 @@
+---
+var_string: hello
+var_bool: true
+---
diff --git a/caddyhttp/markdown/testdata/header.html b/caddyhttp/markdown/testdata/header.html
new file mode 100644
index 000000000..cfbdc75b5
--- /dev/null
+++ b/caddyhttp/markdown/testdata/header.html
@@ -0,0 +1 @@
+<h1>Header for: {{.Doc.title}}</h1> \ No newline at end of file
diff --git a/caddyhttp/markdown/testdata/log/test.md b/caddyhttp/markdown/testdata/log/test.md
new file mode 100644
index 000000000..476ab3015
--- /dev/null
+++ b/caddyhttp/markdown/testdata/log/test.md
@@ -0,0 +1,14 @@
+---
+title: Markdown test 2
+sitename: A Caddy website
+---
+
+## Welcome on the blog
+
+Body
+
+``` go
+func getTrue() bool {
+ return true
+}
+```
diff --git a/caddyhttp/markdown/testdata/markdown_tpl.html b/caddyhttp/markdown/testdata/markdown_tpl.html
new file mode 100644
index 000000000..7c6978500
--- /dev/null
+++ b/caddyhttp/markdown/testdata/markdown_tpl.html
@@ -0,0 +1,11 @@
+<!DOCTYPE html>
+<html>
+<head>
+<title>{{.Doc.title}}</title>
+</head>
+<body>
+{{.Include "header.html"}}
+Welcome to {{.Doc.sitename}}!
+{{.Doc.body}}
+</body>
+</html>
diff --git a/caddyhttp/markdown/testdata/og/first.md b/caddyhttp/markdown/testdata/og/first.md
new file mode 100644
index 000000000..4d7a4251f
--- /dev/null
+++ b/caddyhttp/markdown/testdata/og/first.md
@@ -0,0 +1,5 @@
+---
+title: first_post
+sitename: title
+---
+# Test h1
diff --git a/caddyhttp/markdown/testdata/tpl_with_include.html b/caddyhttp/markdown/testdata/tpl_with_include.html
new file mode 100644
index 000000000..68cc986cf
--- /dev/null
+++ b/caddyhttp/markdown/testdata/tpl_with_include.html
@@ -0,0 +1,11 @@
+<!DOCTYPE html>
+<html>
+ <head>
+ <title>{{.Doc.title}}</title>
+ </head>
+ <body>
+ Welcome to {{.Doc.sitename}}!
+ <br><br>
+ {{.Doc.body}}
+ </body>
+</html>