Weave.jl/test/rich_output.jl

17 lines
610 B
Julia
Raw Normal View History

2016-11-03 13:13:50 +01:00
using Weave
using Test
function mmtest(source, resfile, doctype)
2018-07-25 22:24:25 +02:00
weave("documents/$source", out_path = "documents/multimedia/$resfile", mod=:sandbox,
doctype=doctype, template = "templates/mini.tpl")
result = read("documents/multimedia/$resfile", String)
ref = read("documents/multimedia/$resfile.ref", String)
@test result == ref
2017-03-14 20:27:26 +01:00
rm("documents/multimedia/$resfile")
end
2018-07-24 10:46:04 +02:00
mmtest("rich_output.jmd", "rich_output.html", "md2html")
mmtest("rich_output.jmd", "rich_output.md", "pandoc")
mmtest("rich_output.jmd", "rich_output.tex", "tex")
mmtest("rich_output.jmd", "rich_output.github", "github")