From f9b9b5a7687ff3754de32881e9c54672a7992810 Mon Sep 17 00:00:00 2001 From: Tinmarino Date: Sat, 18 Apr 2020 14:10:05 -0400 Subject: [PATCH] Test: plaintext html magic --- test/convert_default_html.vader | 59 +++++++++++++++++++++++++++++++++ 1 file changed, 59 insertions(+) create mode 100644 test/convert_default_html.vader diff --git a/test/convert_default_html.vader b/test/convert_default_html.vader new file mode 100644 index 0000000..c145f69 --- /dev/null +++ b/test/convert_default_html.vader @@ -0,0 +1,59 @@ +Include: vader_includes/vader_setup.vader + +Execute (Copy Wiki's Resources): + Log "Start: Copy Resources" + call CopyResources() + +Given (Void): + +Execute (Edit TestHtml Wiki): + edit $HOME/testwiki/TestHtml.wiki + AssertEqual $HOME . '/testwiki/TestHtml.wiki', expand('%') + AssertEqual 'default', vimwiki#vars#get_wikilocal('syntax') + AssertEqual 0, vimwiki#vars#get_bufferlocal('wiki_nr') + +Do (Markdwon with %plainhtml): + :edit $HOME/testwiki/TestHtml.wiki\ + i%plainhtml
\ + my paragraph\ + %plainhtml
\\ + :set bt=\ + :write\ + +Execute (Save and Convert to html): + edit $HOME/testwiki/TestHtml.wiki + Vimwiki2HTML + +Given (Void): + +Do (Get Html body): + :read $HOME/html/default/TestHtml.html\ +# Goto body + gg/\ +# Copy in b + "bdat +# Delete All + ggdG +# Paste body + "bP +# Remove last line + Gdd +# Save (Not necessary) + :write + + + +Expect (Plain Html): +# the whole default html file should be here as a base + the modifications +# from "Given" + + +
+

+ my paragraph +

+
+ + + +Include: vader_includes/vader_teardown.vader