octave-maintainers
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: automated (or otherwise) tests for graphics code?


From: David Bateman
Subject: Re: automated (or otherwise) tests for graphics code?
Date: Thu, 16 Oct 2008 21:28:46 +0100
User-agent: Mozilla-Thunderbird 2.0.0.16 (X11/20080724)

Ben Abbott wrote:

If the figure is closed before the assert, would that do the trick?

Ben


Yes and no.. Yes closing the figure will destroy this property. However if the test fails then you won't get to the piece of code to close the figure.. I hadn't thought of that before. How this is handled elsewhere in Octave, as each test is run in its own try/catch block is to do something like

%!test
%! figure (1)
%! set (gcf, "visibility", "off")

%!test
%! sombrero
%! colorbar
%! shading interp
%! shading flat
%! shading facted
%! assert (true)

%!test
%! ## Yet another graphics test

%!test
%! close (1)


D.

--
David Bateman                                address@hidden
35 rue Gambetta                              +33 1 46 04 02 18 (Home)
92100 Boulogne-Billancourt FRANCE            +33 6 72 01 06 33 (Mob)


reply via email to

[Prev in Thread] Current Thread [Next in Thread]