From 87af609a6f4c16748681d25b3e339a1dd37588eb Mon Sep 17 00:00:00 2001 From: O01eg Date: Sat, 9 Feb 2019 12:25:02 +0300 Subject: [PATCH 1/2] Add test case for https://github.com/JuliaPlots/Plots.jl/issues/1904 --- test/runtests.jl | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/test/runtests.jl b/test/runtests.jl index 1587d1bb..906c5804 100644 --- a/test/runtests.jl +++ b/test/runtests.jl @@ -33,7 +33,12 @@ end @test backend() == Plots.UnicodePlotsBackend() # lets just make sure it runs without error - @test isa(plot(rand(10)), Plots.Plot) == true + p = plot(rand(10)) + @test isa(p, Plots.Plot) == true + @test isa(display(p), Nothing) == true + p = bar(randn(10)) + @test isa(p, Plots.Plot) == true + @test isa(display(p), Nothing) == true end # The plotlyjs testimages return a connection error on travis: From 3a2b6296ac64f04770c9b440785f80c2b4d57ad5 Mon Sep 17 00:00:00 2001 From: O01eg Date: Sat, 9 Feb 2019 12:38:57 +0300 Subject: [PATCH 2/2] Fix UndefVarError: series not defined --- src/backends/unicodeplots.jl | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/backends/unicodeplots.jl b/src/backends/unicodeplots.jl index 370c9a87..a2e677c5 100644 --- a/src/backends/unicodeplots.jl +++ b/src/backends/unicodeplots.jl @@ -116,7 +116,7 @@ function addUnicodeSeries!(o, plotattributes::KW, addlegend::Bool, xlim, ylim) x, y = if st == :straightline straightline_data(plotattributes) elseif st == :shape - shape_data(series) + shape_data(plotattributes) else [collect(float(plotattributes[s])) for s in (:x, :y)] end