summaryrefslogtreecommitdiff
path: root/test
diff options
context:
space:
mode:
authorShaun McCance <shaunm@redhat.com>2020-01-26 17:51:32 +0100
committerShaun McCance <shaunm@redhat.com>2020-01-26 17:51:56 +0100
commit4e93595852f2c6679e3afa4da0933b0257c30b63 (patch)
tree41767c0dbf440093cad4eae2def9df3a6aad42e9 /test
parent612762d41be02981921546db37bcc0fc6bdcd715 (diff)
downloadyelp-xsl-4e93595852f2c6679e3afa4da0933b0257c30b63.tar.gz
Adding a syntax highlighter for Ducktype
Diffstat (limited to 'test')
-rw-r--r--test/syntax/code/ducktype33
-rw-r--r--test/syntax/dita.dita10
-rw-r--r--test/syntax/docbook.docbook8
-rw-r--r--test/syntax/mallard.page8
4 files changed, 59 insertions, 0 deletions
diff --git a/test/syntax/code/ducktype b/test/syntax/code/ducktype
new file mode 100644
index 00000000..234f80fd
--- /dev/null
+++ b/test/syntax/code/ducktype
@@ -0,0 +1,33 @@
+@ducktype/1.0
+@define foo bar
+
+= Hello world
+- Subtitle
+@title[type=link] Link title
+
+[note .tip style="tip"]
+You can use all sorts of semantic elements.
+
+Here is some $em[style=strong](inline) markup.
+Here is an $link[>page#sect](internal link).
+Here is an $link[>>http://example.com](external link).
+Here is $foo;.
+
+ [-] line comment
+
+That was a comment. So is this:
+
+ [--
+ block comment
+ [not markup]
+ --]
+
+== Section
+ [#sectid]
+
+[code python
+ type=python]
+ [[[
+ def this_is():
+ some_code()
+ ]]]
diff --git a/test/syntax/dita.dita b/test/syntax/dita.dita
index 2c87bb3c..c6c032fd 100644
--- a/test/syntax/dita.dita
+++ b/test/syntax/dita.dita
@@ -214,6 +214,16 @@ int main(char** argv) {
</body>
</topic>
+<topic id="ducktype">
+ <title>Ducktype</title>
+ <body>
+ <section>
+ <title><codeph>outputclass="ducktype"</codeph></title>
+ <codeblock outputclass="ducktype"><xi:include parse="text" href="code/ducktype"/></codeblock>
+ </section>
+ </body>
+</topic>
+
<topic id="erb">
<title>Embedded Ruby</title>
<body>
diff --git a/test/syntax/docbook.docbook b/test/syntax/docbook.docbook
index 8a7b1353..06dd96ae 100644
--- a/test/syntax/docbook.docbook
+++ b/test/syntax/docbook.docbook
@@ -182,6 +182,14 @@ int main(char** argv) {
</example>
</section>
+<section id="ducktype">
+ <title>Ducktype</title>
+ <example>
+ <title><code>language="ducktype"</code></title>
+ <programlisting language="ducktype"><xi:include parse="text" href="code/ducktype"/></programlisting>
+ </example>
+</section>
+
<section id="erb">
<title>Embedded Ruby</title>
<example>
diff --git a/test/syntax/mallard.page b/test/syntax/mallard.page
index fbe6fe53..8ba7f925 100644
--- a/test/syntax/mallard.page
+++ b/test/syntax/mallard.page
@@ -242,6 +242,14 @@ int main(char** argv) {
</listing>
</section>
+<section id="ducktype">
+ <title>Ducktype</title>
+ <listing ui:expanded="true">
+ <title><code>type="ducktype"</code></title>
+ <code type="ducktype"><xi:include parse="text" href="code/ducktype"/></code>
+ </listing>
+</section>
+
<section id="erb">
<title>Embedded Ruby</title>
<listing ui:expanded="false">