On Apr 10, 9:50 am, Jeroen Demeyer <[email protected]> wrote:
> On 2012-04-10 16:53, John Cremona wrote:> How should I deal with a doctest 
> which produces a DeprecationWarning?
>
> I would say that a doctest should not produce a deprecation warning.
>
> The point of deprecations is usually that whatever you are doing should
> be done in a different way.  It should be easy to change the test such
> that it doesn't use anything deprecated.  If it's not easy, then that
> feature probably should not be deprecated.

And what about doctests of deprecated functions? It seems to me that
they should stay as is until the function is deleted. Replacing its
doctests with the new style using other functions seems kind of weird
to me. I was actually putting "# random output (warning)" in such
cases, keeping the code intact, but ideally I think these tests must
be tested precisely to ensure that the deprecated way still works
until that functionality is completely removed.

-- 
To post to this group, send an email to [email protected]
To unsubscribe from this group, send an email to 
[email protected]
For more options, visit this group at http://groups.google.com/group/sage-devel
URL: http://www.sagemath.org

Reply via email to