mirror of https://github.com/mpastell/Weave.jl
fix terminology, reorder arguments
parent
785768c728
commit
9b2a1228cd
|
@ -1,5 +1,3 @@
|
||||||
# TODO: fix terminologies: `format_foo` -> `render_foo`
|
|
||||||
|
|
||||||
# fallback methods
|
# fallback methods
|
||||||
# ----------------
|
# ----------------
|
||||||
|
|
||||||
|
@ -21,17 +19,17 @@ function restore_header!(doc)
|
||||||
pushfirst!(doc.chunks, DocChunk(header_text, 0, 0))
|
pushfirst!(doc.chunks, DocChunk(header_text, 0, 0))
|
||||||
end
|
end
|
||||||
|
|
||||||
format_chunk(chunk::DocChunk, docformat) = join((format_inline(c) for c in chunk.content))
|
render_chunk(docformat::WeaveFormat, chunk::DocChunk) = join((render_inline(c) for c in chunk.content))
|
||||||
|
|
||||||
format_inline(inline::InlineText) = inline.content
|
render_inline(inline::InlineText) = inline.content
|
||||||
|
|
||||||
function format_inline(inline::InlineCode)
|
function render_inline(inline::InlineCode)
|
||||||
isempty(inline.rich_output) || return inline.rich_output
|
isempty(inline.rich_output) || return inline.rich_output
|
||||||
isempty(inline.figures) || return inline.figures[end]
|
isempty(inline.figures) || return inline.figures[end]
|
||||||
return inline.output
|
return inline.output
|
||||||
end
|
end
|
||||||
|
|
||||||
function format_chunk(chunk::CodeChunk, docformat)
|
function render_chunk(docformat::WeaveFormat, chunk::CodeChunk)
|
||||||
|
|
||||||
# Fill undefined options with format specific defaults
|
# Fill undefined options with format specific defaults
|
||||||
isnothing(chunk.options[:out_width]) && (chunk.options[:out_width] = docformat.out_width)
|
isnothing(chunk.options[:out_width]) && (chunk.options[:out_width] = docformat.out_width)
|
||||||
|
@ -44,7 +42,7 @@ function format_chunk(chunk::CodeChunk, docformat)
|
||||||
|
|
||||||
hasproperty(docformat, :indent) && (chunk.content = indent(chunk.content, docformat.indent))
|
hasproperty(docformat, :indent) && (chunk.content = indent(chunk.content, docformat.indent))
|
||||||
|
|
||||||
chunk.content = format_code(chunk.content, docformat)
|
chunk.content = render_code(docformat, chunk.content)
|
||||||
|
|
||||||
if !chunk.options[:eval]
|
if !chunk.options[:eval]
|
||||||
return if chunk.options[:echo]
|
return if chunk.options[:echo]
|
||||||
|
@ -55,7 +53,7 @@ function format_chunk(chunk::CodeChunk, docformat)
|
||||||
end
|
end
|
||||||
|
|
||||||
if chunk.options[:term]
|
if chunk.options[:term]
|
||||||
result = format_termchunk(chunk, docformat)
|
result = render_termchunk(docformat, chunk)
|
||||||
else
|
else
|
||||||
result = if chunk.options[:echo]
|
result = if chunk.options[:echo]
|
||||||
# Convert to output format and highlight (html, tex...) if needed
|
# Convert to output format and highlight (html, tex...) if needed
|
||||||
|
@ -73,10 +71,10 @@ function format_chunk(chunk::CodeChunk, docformat)
|
||||||
if chunk.options[:wrap]
|
if chunk.options[:wrap]
|
||||||
chunk.output =
|
chunk.output =
|
||||||
'\n' * wraplines(chunk.output, chunk.options[:line_width])
|
'\n' * wraplines(chunk.output, chunk.options[:line_width])
|
||||||
chunk.output = format_output(chunk.output, docformat)
|
chunk.output = render_output(docformat, chunk.output)
|
||||||
else
|
else
|
||||||
chunk.output = '\n' * rstrip(chunk.output)
|
chunk.output = '\n' * rstrip(chunk.output)
|
||||||
chunk.output = format_output(chunk.output, docformat)
|
chunk.output = render_output(docformat, chunk.output)
|
||||||
end
|
end
|
||||||
|
|
||||||
hasproperty(docformat, :indent) && (chunk.output = indent(chunk.output, docformat.indent))
|
hasproperty(docformat, :indent) && (chunk.output = indent(chunk.output, docformat.indent))
|
||||||
|
@ -91,13 +89,13 @@ function format_chunk(chunk::CodeChunk, docformat)
|
||||||
|
|
||||||
# Handle figures
|
# Handle figures
|
||||||
if chunk.options[:fig] && length(chunk.figures) > 0
|
if chunk.options[:fig] && length(chunk.figures) > 0
|
||||||
result *= formatfigures(chunk, docformat)
|
result *= render_figures(docformat, chunk)
|
||||||
end
|
end
|
||||||
|
|
||||||
return result
|
return result
|
||||||
end
|
end
|
||||||
|
|
||||||
format_code(code, docformat) = code
|
render_code(docformat::WeaveFormat, code) = code
|
||||||
|
|
||||||
indent(text, nindent) = join(map(x -> string(repeat(' ', nindent), x), split(text, '\n')), '\n')
|
indent(text, nindent) = join(map(x -> string(repeat(' ', nindent), x), split(text, '\n')), '\n')
|
||||||
|
|
||||||
|
@ -124,9 +122,9 @@ function wrapline(text, line_width = 75)
|
||||||
result *= text
|
result *= text
|
||||||
end
|
end
|
||||||
|
|
||||||
format_output(result, docformat) = result
|
render_output(docformat::WeaveFormat, output) = output
|
||||||
|
|
||||||
function format_termchunk(chunk, docformat)
|
function render_termchunk(docformat::WeaveFormat, chunk)
|
||||||
return if should_render(chunk)
|
return if should_render(chunk)
|
||||||
string(docformat.termstart, chunk.output, '\n', docformat.termend, '\n')
|
string(docformat.termstart, chunk.output, '\n', docformat.termend, '\n')
|
||||||
else
|
else
|
||||||
|
|
|
@ -3,10 +3,10 @@
|
||||||
|
|
||||||
abstract type HTMLFormat <: WeaveFormat end
|
abstract type HTMLFormat <: WeaveFormat end
|
||||||
|
|
||||||
format_code(code, docformat::HTMLFormat) =
|
render_code(docformat::HTMLFormat, code) =
|
||||||
highlight_code(MIME("text/html"), code, docformat.highlight_theme)
|
highlight_code(MIME("text/html"), code, docformat.highlight_theme)
|
||||||
|
|
||||||
format_termchunk(chunk, docformat::HTMLFormat) =
|
render_termchunk(docformat::HTMLFormat, chunk) =
|
||||||
should_render(chunk) ? highlight_term(MIME("text/html"), chunk.output, docformat.highlight_theme) : ""
|
should_render(chunk) ? highlight_term(MIME("text/html"), chunk.output, docformat.highlight_theme) : ""
|
||||||
|
|
||||||
# Julia markdown
|
# Julia markdown
|
||||||
|
@ -44,7 +44,7 @@ function set_format_options!(docformat::JMarkdown2HTML; template = nothing, css
|
||||||
end
|
end
|
||||||
|
|
||||||
# very similar to tex version of function
|
# very similar to tex version of function
|
||||||
function format_chunk(chunk::DocChunk, docformat::JMarkdown2HTML)
|
function render_chunk(docformat::JMarkdown2HTML, chunk::DocChunk)
|
||||||
out = IOBuffer()
|
out = IOBuffer()
|
||||||
io = IOBuffer()
|
io = IOBuffer()
|
||||||
for inline in chunk.content
|
for inline in chunk.content
|
||||||
|
@ -63,9 +63,9 @@ function format_chunk(chunk::DocChunk, docformat::JMarkdown2HTML)
|
||||||
return take2string!(out)
|
return take2string!(out)
|
||||||
end
|
end
|
||||||
|
|
||||||
format_output(result, docformat::JMarkdown2HTML) = Markdown.htmlesc(result)
|
render_output(docformat::JMarkdown2HTML, output) = Markdown.htmlesc(output)
|
||||||
|
|
||||||
function formatfigures(chunk, docformat::JMarkdown2HTML)
|
function render_figures(docformat::JMarkdown2HTML, chunk)
|
||||||
fignames = chunk.figures
|
fignames = chunk.figures
|
||||||
caption = chunk.options[:fig_cap]
|
caption = chunk.options[:fig_cap]
|
||||||
width = chunk.options[:out_width]
|
width = chunk.options[:out_width]
|
||||||
|
@ -156,4 +156,4 @@ function set_format_options!(docformat::Pandoc2HTML; template = nothing, css = n
|
||||||
docformat.pandoc_options = pandoc_options
|
docformat.pandoc_options = pandoc_options
|
||||||
end
|
end
|
||||||
|
|
||||||
formatfigures(chunk, docformat::Pandoc2HTML) = formatfigures(chunk, Pandoc())
|
render_figures(docformat::Pandoc2HTML, chunk) = render_figures(chunk, Pandoc())
|
||||||
|
|
|
@ -24,7 +24,7 @@ Base.@kwdef mutable struct GitHubMarkdown <: MarkdownFormat
|
||||||
end
|
end
|
||||||
register_format!("github", GitHubMarkdown())
|
register_format!("github", GitHubMarkdown())
|
||||||
|
|
||||||
function formatfigures(chunk, docformat::GitHubMarkdown)
|
function render_figures(docformat::GitHubMarkdown, chunk)
|
||||||
fignames = chunk.figures
|
fignames = chunk.figures
|
||||||
caption = chunk.options[:fig_cap]
|
caption = chunk.options[:fig_cap]
|
||||||
result = ""
|
result = ""
|
||||||
|
@ -70,7 +70,7 @@ Base.@kwdef mutable struct Hugo <: MarkdownFormat
|
||||||
end
|
end
|
||||||
register_format!("hugo", Hugo())
|
register_format!("hugo", Hugo())
|
||||||
|
|
||||||
function formatfigures(chunk, docformat::Hugo)
|
function render_figures(docformat::Hugo, chunk)
|
||||||
relpath = docformat.uglyURLs ? "" : ".."
|
relpath = docformat.uglyURLs ? "" : ".."
|
||||||
mapreduce(*, enumerate(chunk.figures), init = "") do (index, fig)
|
mapreduce(*, enumerate(chunk.figures), init = "") do (index, fig)
|
||||||
if index > 1
|
if index > 1
|
||||||
|
@ -107,7 +107,7 @@ Base.@kwdef mutable struct MultiMarkdown <: MarkdownFormat
|
||||||
end
|
end
|
||||||
register_format!("multimarkdown", MultiMarkdown())
|
register_format!("multimarkdown", MultiMarkdown())
|
||||||
|
|
||||||
function formatfigures(chunk, docformat::MultiMarkdown)
|
function render_figures(docformat::MultiMarkdown, chunk)
|
||||||
fignames = chunk.figures
|
fignames = chunk.figures
|
||||||
caption = chunk.options[:fig_cap]
|
caption = chunk.options[:fig_cap]
|
||||||
result = ""
|
result = ""
|
||||||
|
@ -143,7 +143,7 @@ end
|
||||||
|
|
||||||
abstract type PandocFormat <: MarkdownFormat end
|
abstract type PandocFormat <: MarkdownFormat end
|
||||||
|
|
||||||
function formatfigures(chunk, docformat::PandocFormat)
|
function render_figures(docformat::PandocFormat, chunk)
|
||||||
fignames = chunk.figures
|
fignames = chunk.figures
|
||||||
length(fignames) > 0 || (return "")
|
length(fignames) > 0 || (return "")
|
||||||
|
|
||||||
|
|
|
@ -19,10 +19,7 @@ function render_doc(doc::WeaveDoc)
|
||||||
restore_header!(doc)
|
restore_header!(doc)
|
||||||
|
|
||||||
docformat = doc.format
|
docformat = doc.format
|
||||||
lines = map(copy(doc.chunks)) do chunk
|
body = joinlines(render_chunk.(Ref(docformat), copy(doc.chunks)))
|
||||||
format_chunk(chunk, docformat)
|
|
||||||
end
|
|
||||||
body = join(lines, '\n')
|
|
||||||
return render_doc(docformat, body, doc)
|
return render_doc(docformat, body, doc)
|
||||||
end
|
end
|
||||||
|
|
||||||
|
|
|
@ -10,7 +10,7 @@ function set_format_options!(docformat::TexFormat; keep_unicode = false, templat
|
||||||
end
|
end
|
||||||
|
|
||||||
# very similar to export to html
|
# very similar to export to html
|
||||||
function format_chunk(chunk::DocChunk, docformat::TexFormat)
|
function render_chunk(docformat::TexFormat, chunk::DocChunk)
|
||||||
out = IOBuffer()
|
out = IOBuffer()
|
||||||
io = IOBuffer()
|
io = IOBuffer()
|
||||||
for inline in chunk.content
|
for inline in chunk.content
|
||||||
|
@ -30,11 +30,11 @@ function format_chunk(chunk::DocChunk, docformat::TexFormat)
|
||||||
return unicode2latex(docformat, out)
|
return unicode2latex(docformat, out)
|
||||||
end
|
end
|
||||||
|
|
||||||
format_output(result, docformat::TexFormat) = unicode2latex(docformat, result, true)
|
render_output(docformat::TexFormat, output) = unicode2latex(docformat, output, true)
|
||||||
|
|
||||||
format_code(code, docformat::TexFormat) = unicode2latex(docformat, code, true)
|
render_code(docformat::TexFormat, code) = unicode2latex(docformat, code, true)
|
||||||
|
|
||||||
format_termchunk(chunk, docformat::TexFormat) = string(docformat.termstart, chunk.output, docformat.termend, "\n")
|
render_termchunk(docformat::TexFormat, chunk) = string(docformat.termstart, chunk.output, docformat.termend, "\n")
|
||||||
|
|
||||||
# from julia symbols (e.g. "\bfhoge") to valid latex
|
# from julia symbols (e.g. "\bfhoge") to valid latex
|
||||||
const UNICODE2LATEX = let
|
const UNICODE2LATEX = let
|
||||||
|
@ -65,7 +65,7 @@ function unicode2latex(docformat::TexFormat, s, escape = false)
|
||||||
return s
|
return s
|
||||||
end
|
end
|
||||||
|
|
||||||
function formatfigures(chunk, docformat::TexFormat)
|
function render_figures(docformat::TexFormat, chunk)
|
||||||
fignames = chunk.figures
|
fignames = chunk.figures
|
||||||
caption = chunk.options[:fig_cap]
|
caption = chunk.options[:fig_cap]
|
||||||
width = chunk.options[:out_width]
|
width = chunk.options[:out_width]
|
||||||
|
@ -183,22 +183,22 @@ function set_format_options!(docformat::JMarkdownTexFormat; template = nothing,
|
||||||
docformat.keep_unicode |= keep_unicode
|
docformat.keep_unicode |= keep_unicode
|
||||||
end
|
end
|
||||||
|
|
||||||
function format_output(result, docformat::JMarkdownTexFormat)
|
function render_output(docformat::JMarkdownTexFormat, output)
|
||||||
# Highligts has some extra escaping defined, eg of $, ", ...
|
# Highligts has some extra escaping defined, eg of $, ", ...
|
||||||
result_escaped = sprint(
|
output_escaped = sprint(
|
||||||
(io, x) ->
|
(io, x) ->
|
||||||
Highlights.Format.escape(io, MIME("text/latex"), x, charescape = true),
|
Highlights.Format.escape(io, MIME("text/latex"), x, charescape = true),
|
||||||
result,
|
output,
|
||||||
)
|
)
|
||||||
return unicode2latex(docformat, result_escaped, true)
|
return unicode2latex(docformat, output_escaped, true)
|
||||||
end
|
end
|
||||||
|
|
||||||
function format_code(code, docformat::JMarkdownTexFormat)
|
function render_code(docformat::JMarkdownTexFormat, code)
|
||||||
ret = highlight_code(MIME("text/latex"), code, docformat.highlight_theme)
|
ret = highlight_code(MIME("text/latex"), code, docformat.highlight_theme)
|
||||||
unicode2latex(docformat, ret, false)
|
unicode2latex(docformat, ret, false)
|
||||||
end
|
end
|
||||||
|
|
||||||
format_termchunk(chunk, docformat::JMarkdownTexFormat) =
|
render_termchunk(docformat::JMarkdownTexFormat, chunk) =
|
||||||
should_render(chunk) ? highlight_term(MIME("text/latex"), chunk.output, docformat.highlight_theme) : ""
|
should_render(chunk) ? highlight_term(MIME("text/latex"), chunk.output, docformat.highlight_theme) : ""
|
||||||
|
|
||||||
function render_doc(docformat::JMarkdownTexFormat, body, doc)
|
function render_doc(docformat::JMarkdownTexFormat, body, doc)
|
||||||
|
|
|
@ -21,7 +21,7 @@ Base.@kwdef mutable struct Rest <: WeaveFormat
|
||||||
end
|
end
|
||||||
register_format!("rst", Rest())
|
register_format!("rst", Rest())
|
||||||
|
|
||||||
function formatfigures(chunk, docformat::Rest)
|
function render_figures(docformat::Rest, chunk)
|
||||||
fignames = chunk.figures
|
fignames = chunk.figures
|
||||||
caption = chunk.options[:fig_cap]
|
caption = chunk.options[:fig_cap]
|
||||||
width = chunk.options[:out_width]
|
width = chunk.options[:out_width]
|
||||||
|
@ -66,7 +66,7 @@ Base.@kwdef mutable struct AsciiDoc <: WeaveFormat
|
||||||
end
|
end
|
||||||
register_format!("asciidoc", AsciiDoc())
|
register_format!("asciidoc", AsciiDoc())
|
||||||
|
|
||||||
function formatfigures(chunk, docformat::AsciiDoc)
|
function render_figures(docformat::AsciiDoc, chunk)
|
||||||
fignames = chunk.figures
|
fignames = chunk.figures
|
||||||
caption = chunk.options[:fig_cap]
|
caption = chunk.options[:fig_cap]
|
||||||
width = chunk.options[:out_width]
|
width = chunk.options[:out_width]
|
||||||
|
|
|
@ -1,35 +0,0 @@
|
||||||
test_formatfigures(chunk, format) = Weave.formatfigures(chunk, get_format(format))
|
|
||||||
|
|
||||||
|
|
||||||
# Make a dummy codehunk with figure
|
|
||||||
chunk = Weave.CodeChunk("plot(x)", 1, 1, "", Dict())
|
|
||||||
options = merge(Weave.get_chunk_defaults(), chunk.options)
|
|
||||||
merge!(chunk.options, options)
|
|
||||||
chunk.figures = ["figs/figures_plot1.png"]
|
|
||||||
|
|
||||||
|
|
||||||
@test test_formatfigures(chunk, "md2tex") == "\\includegraphics{figs/figures_plot1.png}\n"
|
|
||||||
@test test_formatfigures(chunk, "texminted") == "\\includegraphics{figs/figures_plot1.png}\n"
|
|
||||||
@test test_formatfigures(chunk, "pandoc") == "![](figs/figures_plot1.png)\\ \n\n"
|
|
||||||
@test test_formatfigures(chunk, "github") == "![](figs/figures_plot1.png)\n"
|
|
||||||
@test test_formatfigures(chunk, "hugo") == "{{< figure src=\"../figs/figures_plot1.png\" >}}"
|
|
||||||
@test test_formatfigures(chunk, "multimarkdown") == "![][figs/figures_plot1.png]\n\n[figs/figures_plot1.png]: figs/figures_plot1.png \n"
|
|
||||||
@test test_formatfigures(chunk, "md2html") == "<img src=\"figs/figures_plot1.png\" />\n"
|
|
||||||
|
|
||||||
|
|
||||||
chunk.options[:out_width] = "100%"
|
|
||||||
@test test_formatfigures(chunk, "asciidoc") == "image::figs/figures_plot1.png[width=100%]\n"
|
|
||||||
@test test_formatfigures(chunk, "rst") == ".. image:: figs/figures_plot1.png\n :width: 100%\n\n"
|
|
||||||
|
|
||||||
|
|
||||||
chunk.options[:fig_cap] = "Nice plot"
|
|
||||||
@test test_formatfigures(chunk, "pandoc") == "![Nice plot](figs/figures_plot1.png){width=100%}\n"
|
|
||||||
@test test_formatfigures(chunk, "md2tex") == "\\begin{figure}[!h]\n\\center\n\\includegraphics[width=1.0\\linewidth]{figs/figures_plot1.png}\n\\caption{Nice plot}\n\\end{figure}\n"
|
|
||||||
@test test_formatfigures(chunk, "md2html") == "<figure>\n<img src=\"figs/figures_plot1.png\" width=\"100%\" />\n<figcaption>Nice plot</figcaption>\n</figure>\n"
|
|
||||||
@test test_formatfigures(chunk, "rst") == ".. figure:: figs/figures_plot1.png\n :width: 100%\n\n Nice plot\n\n"
|
|
||||||
@test test_formatfigures(chunk, "multimarkdown") == "![Nice plot][figs/figures_plot1.png]\n\n[figs/figures_plot1.png]: figs/figures_plot1.png width=100%\n"
|
|
||||||
@test test_formatfigures(chunk, "asciidoc") == "image::figs/figures_plot1.png[width=100%,title=\"Nice plot\"]"
|
|
||||||
|
|
||||||
|
|
||||||
chunk.options[:label] = "somefig"
|
|
||||||
@test test_formatfigures(chunk, "pandoc") == "![Nice plot](figs/figures_plot1.png){width=100% #fig:somefig}\n"
|
|
|
@ -0,0 +1,35 @@
|
||||||
|
test_render_figures(format, chunk) = Weave.render_figures(get_format(format), chunk)
|
||||||
|
|
||||||
|
|
||||||
|
# Make a dummy codehunk with figure
|
||||||
|
chunk = Weave.CodeChunk("plot(x)", 1, 1, "", Dict())
|
||||||
|
options = merge(Weave.get_chunk_defaults(), chunk.options)
|
||||||
|
merge!(chunk.options, options)
|
||||||
|
chunk.figures = ["figs/figures_plot1.png"]
|
||||||
|
|
||||||
|
|
||||||
|
@test test_render_figures("md2tex", chunk) == "\\includegraphics{figs/figures_plot1.png}\n"
|
||||||
|
@test test_render_figures("texminted", chunk) == "\\includegraphics{figs/figures_plot1.png}\n"
|
||||||
|
@test test_render_figures("pandoc", chunk) == "![](figs/figures_plot1.png)\\ \n\n"
|
||||||
|
@test test_render_figures("github", chunk) == "![](figs/figures_plot1.png)\n"
|
||||||
|
@test test_render_figures("hugo", chunk) == "{{< figure src=\"../figs/figures_plot1.png\" >}}"
|
||||||
|
@test test_render_figures("multimarkdown", chunk) == "![][figs/figures_plot1.png]\n\n[figs/figures_plot1.png]: figs/figures_plot1.png \n"
|
||||||
|
@test test_render_figures("md2html", chunk) == "<img src=\"figs/figures_plot1.png\" />\n"
|
||||||
|
|
||||||
|
|
||||||
|
chunk.options[:out_width] = "100%"
|
||||||
|
@test test_render_figures("asciidoc", chunk) == "image::figs/figures_plot1.png[width=100%]\n"
|
||||||
|
@test test_render_figures("rst", chunk) == ".. image:: figs/figures_plot1.png\n :width: 100%\n\n"
|
||||||
|
|
||||||
|
|
||||||
|
chunk.options[:fig_cap] = "Nice plot"
|
||||||
|
@test test_render_figures("pandoc", chunk) == "![Nice plot](figs/figures_plot1.png){width=100%}\n"
|
||||||
|
@test test_render_figures("md2tex", chunk) == "\\begin{figure}[!h]\n\\center\n\\includegraphics[width=1.0\\linewidth]{figs/figures_plot1.png}\n\\caption{Nice plot}\n\\end{figure}\n"
|
||||||
|
@test test_render_figures("md2html", chunk) == "<figure>\n<img src=\"figs/figures_plot1.png\" width=\"100%\" />\n<figcaption>Nice plot</figcaption>\n</figure>\n"
|
||||||
|
@test test_render_figures("rst", chunk) == ".. figure:: figs/figures_plot1.png\n :width: 100%\n\n Nice plot\n\n"
|
||||||
|
@test test_render_figures("multimarkdown", chunk) == "![Nice plot][figs/figures_plot1.png]\n\n[figs/figures_plot1.png]: figs/figures_plot1.png width=100%\n"
|
||||||
|
@test test_render_figures("asciidoc", chunk) == "image::figs/figures_plot1.png[width=100%,title=\"Nice plot\"]"
|
||||||
|
|
||||||
|
|
||||||
|
chunk.options[:label] = "somefig"
|
||||||
|
@test test_render_figures("pandoc", chunk) == "![Nice plot](figs/figures_plot1.png){width=100% #fig:somefig}\n"
|
|
@ -63,7 +63,7 @@ end
|
||||||
|
|
||||||
@testset "legacy" begin
|
@testset "legacy" begin
|
||||||
include("markdown_test.jl")
|
include("markdown_test.jl")
|
||||||
include("figureformatter_test.jl")
|
include("render_figures_test.jl")
|
||||||
include("cache_test.jl")
|
include("cache_test.jl")
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
Loading…
Reference in New Issue