Mercurial > octave
changeset 23508:4b38c9687331
Skip tests that require gnuplot when gnuplot is not installed (bug #36983)
* copyobj.m, graphics_toolkit.m, hgsave.m, legend.m: Make tests that require
gnuplot conditional on the runtime availability of the gnuplot program and
toolkit.
author | Mike Miller <mtmiller@octave.org> |
---|---|
date | Wed, 17 May 2017 18:55:37 -0700 |
parents | 7648014dccc6 |
children | 018fddb4a310 |
files | scripts/plot/appearance/legend.m scripts/plot/util/copyobj.m scripts/plot/util/graphics_toolkit.m scripts/plot/util/hgsave.m |
diffstat | 4 files changed, 4 insertions(+), 4 deletions(-) [+] |
line wrap: on
line diff
--- a/scripts/plot/appearance/legend.m Wed May 17 18:45:14 2017 -0700 +++ b/scripts/plot/appearance/legend.m Wed May 17 18:55:37 2017 -0700 @@ -1613,7 +1613,7 @@ %! legend ("Legend Text"); %! title ({"Multi-line", "titles", "are a", "problem", "See bug #39697"}); -%!test +%!testif ; any (strcmp ("gnuplot", available_graphics_toolkits ())) %! toolkit = graphics_toolkit ("gnuplot"); %! h = figure ("visible", "off"); %! unwind_protect
--- a/scripts/plot/util/copyobj.m Wed May 17 18:45:14 2017 -0700 +++ b/scripts/plot/util/copyobj.m Wed May 17 18:55:37 2017 -0700 @@ -169,7 +169,7 @@ %! set (hnew, "position", [scrn(3)/2, scrn(4)/2-pos(4)/2, pos(3:4)]); %! drawnow (); -%!testif HAVE_MAGICK +%!testif HAVE_MAGICK; any (strcmp ("gnuplot", available_graphics_toolkits ())) %! toolkit = graphics_toolkit (); %! graphics_toolkit ("gnuplot"); %! unwind_protect
--- a/scripts/plot/util/graphics_toolkit.m Wed May 17 18:45:14 2017 -0700 +++ b/scripts/plot/util/graphics_toolkit.m Wed May 17 18:55:37 2017 -0700 @@ -114,7 +114,7 @@ %! close (hf); %! end_unwind_protect -%!testif HAVE_OPENGL, HAVE_FLTK; have_window_system +%!testif HAVE_OPENGL, HAVE_FLTK; have_window_system && any (strcmp ("gnuplot", available_graphics_toolkits ())) %! old_toolkit = graphics_toolkit (); %! switch (old_toolkit) %! case {"gnuplot"}
--- a/scripts/plot/util/hgsave.m Wed May 17 18:45:14 2017 -0700 +++ b/scripts/plot/util/hgsave.m Wed May 17 18:55:37 2017 -0700 @@ -81,7 +81,7 @@ endfunction -%!testif HAVE_MAGICK +%!testif HAVE_MAGICK; any (strcmp ("gnuplot", available_graphics_toolkits ())) %! toolkit = graphics_toolkit (); %! graphics_toolkit ("gnuplot"); %! unwind_protect