From 59531c002e7879779f483e1618bfb04205ad3b65 Mon Sep 17 00:00:00 2001 From: Simon Broda Date: Thu, 10 Sep 2020 11:48:53 +0200 Subject: [PATCH] Get tests to pass on 1.6 (again...) --- test/runtests.jl | 10 +++++++--- 1 file changed, 7 insertions(+), 3 deletions(-) diff --git a/test/runtests.jl b/test/runtests.jl index 3ada8d4..2b39409 100644 --- a/test/runtests.jl +++ b/test/runtests.jl @@ -19,7 +19,11 @@ end Random.seed!(1) spec = TGARCH{1,1,1}([1., .05, .9, .01]); str = sprint(show, spec) - @test startswith(str, "TGARCH{1,1,1} specification.\n\n─────────────────────────────────\n ω γ₁ β₁ α₁\n─────────────────────────────────\nParameters: 1.0 0.05 0.9 0.01\n─────────────────────────────────\n") + if VERSION < v"1.5.5" + @test startswith(str, "TGARCH{1,1,1} specification.\n\n─────────────────────────────────\n ω γ₁ β₁ α₁\n─────────────────────────────────\nParameters: 1.0 0.05 0.9 0.01\n─────────────────────────────────\n") + else + @test startswith(str, "TGARCH{1, 1, 1} specification.\n\n─────────────────────────────────\n ω γ₁ β₁ α₁\n─────────────────────────────────\nParameters: 1.0 0.05 0.9 0.01\n─────────────────────────────────\n") + end am = simulate(spec, T); am = selectmodel(TGARCH, am.data; meanspec=NoIntercept(), show_trace=true, maxlags=2) @test all(isapprox.(coef(am), [0.9439667311150648 @@ -67,7 +71,7 @@ end if VERSION < v"1.5.5" @test startswith(str, "\nTGARCH{0,1,1}") else - @test startswith(str, "\nGARCH{1,1}") + @test startswith(str, "\nGARCH{1, 1}") end fit!(am2) @test isfitted(am2) == true @@ -76,7 +80,7 @@ end if VERSION < v"1.5.5" @test startswith(str, "\nTGARCH{0,1,1}") else - @test startswith(str, "\nGARCH{1,1}") + @test startswith(str, "\nGARCH{1, 1}") end am3 = fit(am2) @test isfitted(am3) == true