2016-11-03 13:13:50 +01:00
|
|
|
using Weave
|
2016-04-27 21:02:20 +02:00
|
|
|
using Base.Test
|
|
|
|
|
|
|
|
function pljtest(source, resfile, doctype)
|
2016-11-01 14:23:14 +01:00
|
|
|
weave("documents/$source", out_path = "documents/plotsjl/$resfile", doctype=doctype)
|
2016-11-03 11:30:49 +01:00
|
|
|
result = readstring(open("documents/plotsjl/$resfile"))
|
|
|
|
ref = readstring(open("documents/plotsjl/$resfile.ref"))
|
2016-04-27 21:02:20 +02:00
|
|
|
@test result == ref
|
|
|
|
end
|
|
|
|
|
|
|
|
pljtest("plotsjl_test.jmd", "plotsjl_test.md", "pandoc")
|
|
|
|
pljtest("plotsjl_test.jmd", "plotsjl_test.tex", "tex")
|