aboutsummaryrefslogtreecommitdiff
path: root/test
diff options
context:
space:
mode:
authorIlya Ryzhenkov <orangy@jetbrains.com>2014-12-15 20:54:16 +0300
committerIlya Ryzhenkov <orangy@jetbrains.com>2014-12-15 20:54:16 +0300
commitc9ca0d86e810ac7240b249b145810f6862a58e93 (patch)
tree3ec593c2bcb6e54b9c5732b47445c5404caf09a1 /test
parentbf6696b193d6a08d1d6c79d4c8e2a0564a286d7e (diff)
downloaddokka-c9ca0d86e810ac7240b249b145810f6862a58e93.tar.gz
dokka-c9ca0d86e810ac7240b249b145810f6862a58e93.tar.bz2
dokka-c9ca0d86e810ac7240b249b145810f6862a58e93.zip
Migrate to non-PsiBuilder fully-featured markdown parser.
Diffstat (limited to 'test')
-rw-r--r--test/src/markdown/ParserTest.kt23
1 files changed, 20 insertions, 3 deletions
diff --git a/test/src/markdown/ParserTest.kt b/test/src/markdown/ParserTest.kt
index 201708c6..16892f23 100644
--- a/test/src/markdown/ParserTest.kt
+++ b/test/src/markdown/ParserTest.kt
@@ -2,13 +2,13 @@ package org.jetbrains.dokka.tests
import org.junit.Test
import org.jetbrains.dokka
-import org.jetbrains.dokka.MarkdownProcessor
import org.jetbrains.dokka.toTestString
import org.jetbrains.dokka.toHtml
+import org.jetbrains.dokka.parseMarkdown
public class ParserTest {
fun runTestFor(text : String) {
- val markdownTree = MarkdownProcessor.parse(text)
+ val markdownTree = parseMarkdown(text)
println(markdownTree.toTestString())
println(markdownTree.toHtml())
}
@@ -85,7 +85,7 @@ number two
}
Test fun directive() {
- runTestFor("A text {code with.another.value} with directive")
+ runTestFor("A text \${code with.another.value} with directive")
}
Test fun emphAndEmptySection() {
@@ -119,5 +119,22 @@ number two
"Plain text \$summary:")
}
+ val b = "$"
+ Test fun pair() {
+ runTestFor(
+ """Represents a generic pair of two values.
+
+There is no meaning attached to values in this class, it can be used for any purpose.
+Pair exhibits value semantics, i.e. two pairs are equal if both components are equal.
+
+An example of decomposing it into values:
+${b}{code test.tuples.PairTest.pairMultiAssignment}
+
+${b}constructor: Creates new instance of [Pair]
+${b}first: First value
+${b}second: Second value""""
+ )
+ }
+
}