diff --git a/test/errors_test.jl b/test/errors_test.jl index 6f95d9d..2a284fa 100644 --- a/test/errors_test.jl +++ b/test/errors_test.jl @@ -24,7 +24,10 @@ p1 = Weave.parse_doc(s1, "markdown") doc = Weave.WeaveDoc("dummy1.jmd", p1, Dict()) doc1 = Weave.run(doc, doctype = "pandoc") -@test doc1.chunks[1].output == "Error: ArgumentError: Package NonExisting not found in current path:\n - Run `Pkg.add(\"NonExisting\")` to install the NonExisting package.\n\n" +doc1.chunks[1].output + +@test doc1.chunks[1].output == "Error: ArgumentError: Package NonExisting not found in current path:\n- Run `Pkg.add(\"NonExisting\")` to install the NonExisting package.\n\n" + @test doc1.chunks[2].output == "Error: syntax: incomplete: premature end of input\n" @test doc1.chunks[3].output == "\njulia> plot(x)\nError: UndefVarError: plot not defined\n\njulia> y = 10\n10\n\njulia> print(y\nError: syntax: incomplete: premature end of input\n" @@ -32,7 +35,7 @@ doc1 = Weave.run(doc, doctype = "pandoc") doc = Weave.WeaveDoc("dummy1.jmd", p1, Dict()) doc3 = Weave.run(doc, doctype = "md2html") -@test doc3.chunks[1].rich_output == "
\nERROR: ArgumentError: Package NonExisting not found in current path:\n - Run `Pkg.add("NonExisting")` to install the NonExisting package.\n\n
\n" +@test doc3.chunks[1].rich_output == "
\nERROR: ArgumentError: Package NonExisting not found in current path:\n- Run `Pkg.add("NonExisting")` to install the NonExisting package.\n\n
\n" @test doc3.chunks[2].rich_output == "
\nERROR: syntax: incomplete: premature end of input\n
\n" @test doc3.chunks[3].output == "\njulia> plot(x)\nError: UndefVarError: plot not defined\n\njulia> y = 10\n10\n\njulia> print(y\nError: syntax: incomplete: premature end of input\n" @test doc3.chunks[3].rich_output == ""