From 8646a0ff631aba62ddfeb06defdc4c7615f67aa9 Mon Sep 17 00:00:00 2001 From: "Thomas A. Christensen II" <25492070+MillironX@users.noreply.github.com> Date: Tue, 5 Apr 2022 16:10:48 -0500 Subject: [PATCH] Refactor capuring pretty strings into its own function Signed-off-by: Thomas A. Christensen II <25492070+MillironX@users.noreply.github.com> --- test/runtests.jl | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/test/runtests.jl b/test/runtests.jl index c5cca0d..833416f 100644 --- a/test/runtests.jl +++ b/test/runtests.jl @@ -7,6 +7,8 @@ using Test # Set up doctests DocMeta.setdocmeta!(Kelpie, :DocTestSetup, :(using Kelpie); recursive=true) +prettystring(xml) = @capture_out prettyprint(xml) + # Set up the Bootstrap 5.1.3 starter template in EzXML nodes function bootstrap_starter() # Create the nodes @@ -76,7 +78,7 @@ function bootstrap_starter() link!(html_node, body_node) link!(doc_node, html_node) - return @capture_out prettyprint(doc_node) + return prettystring(doc_node) end #function # Set up the Zurb Foundation 6.7.4 starter template in EzXML nodes @@ -163,7 +165,7 @@ function foundation_template() link!(html_node, body_node) link!(doc_node, html_node) - return @capture_out prettyprint(doc_node) + return prettystring(doc_node) end #function @testset "Kelpie.jl" begin