#11899: Simplify some very long doctests
---------------------------+------------------------------------------------
Reporter: jdemeyer | Owner: mvngu
Type: enhancement | Status: new
Priority: minor | Milestone: sage-4.7.3
Component: doctest | Keywords:
Work_issues: | Upstream: N/A
Reviewer: | Author:
Merged: | Dependencies:
---------------------------+------------------------------------------------
Comment(by leif):
Replying to [comment:2 jdemeyer]:
> Replying to [comment:1 leif]:
> > We should IMHO make it such that the timeouts for doctests (perhaps
optionally, or in addition) do not refer to wall but actual CPU time [...]
>
> In principle I agree, but I don't think that is implementable in a good
and portable way.
We could use `setrlimit()` in `sage-doctest.py` (which tests just a single
file, i.e., each doctested file has its own instance), or add appropriate
code (e.g. setting `SIGALRM`, and checking the consumed CPU time with
`getrusage()`) to the generated temporary files with the examples that get
run by Python. Emitting such extra code could be optional, too.
As a first step, we could in addition print the CPU time a doctest (of a
complete file) took, by using `getrusage()` in `sage-test.py` / `sage-
ptest.py`
--
Ticket URL: <http://trac.sagemath.org/sage_trac/ticket/11899#comment:5>
Sage <http://www.sagemath.org>
Sage: Creating a Viable Open Source Alternative to Magma, Maple, Mathematica,
and MATLAB
--
You received this message because you are subscribed to the Google Groups
"sage-trac" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to
[email protected].
For more options, visit this group at
http://groups.google.com/group/sage-trac?hl=en.