summaryrefslogtreecommitdiff
path: root/src/test/kotlin
diff options
context:
space:
mode:
Diffstat (limited to 'src/test/kotlin')
-rw-r--r--src/test/kotlin/moe/nea/blog/md/test/LinkTest.kt16
1 files changed, 16 insertions, 0 deletions
diff --git a/src/test/kotlin/moe/nea/blog/md/test/LinkTest.kt b/src/test/kotlin/moe/nea/blog/md/test/LinkTest.kt
index d476715..fbd1058 100644
--- a/src/test/kotlin/moe/nea/blog/md/test/LinkTest.kt
+++ b/src/test/kotlin/moe/nea/blog/md/test/LinkTest.kt
@@ -13,4 +13,20 @@ class LinkTest : MarkdownTest() {
assertInlineFormat("<link target=https://nea.moe><i>meee</i></link>", "[*meee*]( https://nea.moe )")
}
+ @Test
+ fun testBasicImage() {
+ assertInlineFormat(
+ "<image source=https://nea.moe/image.jxl>alt text <i>here</i></image>",
+ "![alt text *here*]( https://nea.moe/image.jxl )"
+ )
+ }
+
+ @Test
+ fun testImageLink() {
+ assertInlineFormat(
+ "<link target=https://nea.moe><image source=https://nea.moe/image.jxl></image></link>",
+ "[![]( https://nea.moe/image.jxl )](https://nea.moe)"
+ )
+ }
+
} \ No newline at end of file