From 9bac6a0d322aa662b8a6e0c8db8404d2e29b20f6 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?S=C3=A9bastien=20Villemot?= Date: Tue, 14 Jan 2020 11:49:41 +0100 Subject: [PATCH] Octave compatibility fix: skip some tests under Octave 5.1, due to a bug in ordeig --- .../stochastic_purely_forward.mod | 6 ++++++ .../stochastic_purely_forward_with_static.mod | 7 +++++++ 2 files changed, 13 insertions(+) diff --git a/tests/stochastic_purely_forward/stochastic_purely_forward.mod b/tests/stochastic_purely_forward/stochastic_purely_forward.mod index 1fd41ccb6..6dd03fcaf 100644 --- a/tests/stochastic_purely_forward/stochastic_purely_forward.mod +++ b/tests/stochastic_purely_forward/stochastic_purely_forward.mod @@ -19,9 +19,15 @@ end; steady; check; +% Skip test under Octave 5.1 +% ordeig() is buggy in that version (but is fixed in later ones; and in older +% ones it is absent, so we use our replacement) +if ~isoctave || octave_ver_less_than('5.1') || ~octave_ver_less_than('5.2') + stoch_simul(periods=0, irf=30, order=1); stoch_simul(periods=2000, irf=30, order=1); stoch_simul(periods=0, irf=30, order=1,hp_filter=1600); stoch_simul(periods=2000, irf=30, order=1,hp_filter=1600); +end diff --git a/tests/stochastic_purely_forward/stochastic_purely_forward_with_static.mod b/tests/stochastic_purely_forward/stochastic_purely_forward_with_static.mod index 537416bad..8622d890f 100644 --- a/tests/stochastic_purely_forward/stochastic_purely_forward_with_static.mod +++ b/tests/stochastic_purely_forward/stochastic_purely_forward_with_static.mod @@ -20,8 +20,15 @@ end; steady; check; +% Skip test under Octave 5.1 +% ordeig() is buggy in that version (but is fixed in later ones; and in older +% ones it is absent, so we use our replacement) +if ~isoctave || octave_ver_less_than('5.1') || ~octave_ver_less_than('5.2') + stoch_simul(periods=0, irf=30, order=1); stoch_simul(periods=2000, irf=30, order=1); stoch_simul(periods=0, irf=30, order=1,hp_filter=1600); stoch_simul(periods=2000, irf=30, order=1,hp_filter=1600); + +end