#12415: Update doctesting framework
-------------------------------------------------------------------------------------------------------------------------+
       Reporter:  robertwb                                                      
                                         |         Owner:  mvngu         
           Type:  enhancement                                                   
                                         |        Status:  needs_review  
       Priority:  major                                                         
                                         |     Milestone:  sage-5.1      
      Component:  doctest                                                       
                                         |    Resolution:                
       Keywords:                                                                
                                         |   Work issues:                
Report Upstream:  N/A                                                           
                                         |     Reviewers:  Jeroen Demeyer
        Authors:  David Roe, Robert Bradshaw                                    
                                         |     Merged in:                
   Dependencies:  #13147,#13146, #13145, #12723, #12392, #12393, #12395, 
#12396, #12397, #12381, #12382, #12383, #12384  |      Stopgaps:                
-------------------------------------------------------------------------------------------------------------------------+

Comment (by jdemeyer):

 Some more doctest failures:
 {{{
 sage -t devel/sage/doc/common/__init__.py
     [0 tests, 0.0 s]
 sage -t devel/sage/doc/common/build_optiUsage: sage -docbuild [OPTIONS]
 DOCUMENT (FORMAT | COMMAND)

 sage-runtests: error: no such option: -p
 ons.py
     [0 tests, 0.0 s]
 sage -t devel/sage/doc/common/builder.py
     Bad exit: 2
 Tests run before process failed:

 sage -t devel/sage/doc/common/conf.py
     [0 tests, 0.0 s]
 }}}

 {{{
 sage -t devel/sage/doc/de/tutorial/interactive_shell.rst
     Error: TAB character found at line 656
     [8 tests, 0.2 s]
 sage -t devel/sage/doc/en/tutorial/interactive_shell.rst
     [8 tests, 0.2 s]
 sage -t devel/sage/doc/en/bordeaux_2008/birds_other.rst
     [26 tests,
 5.2**********************************************************************
 File "interfaces", line 331, in interfaces
 Failed example:
     maxima.plot3d("[cos(x)*(3 + y*cos(x/2)), sin(x)*(3 + y*cos(x/2)),\
       y*sin(x/2)]", "[x, -4, 4]", "[y, -4, 4]",\
       '[plot_format, openmath]') # not tested
 Exception raised:
     Traceback (most recent call last):
       File "/release/merger/sage-5.1.beta5-12415/local/lib/python2.7/site-
 packages/sage/doctest/forker.py", line 590, in _run
         compileflags, 1)
       File "<doctest interfaces[0]>", line 2
         maxima.plot3d("[cos(x)*(3 + y*cos(x/2)), sin(x)*(3 + y*cos(x/2)),\
       y*sin(x/2)]", "[x, -4, 4]", "[y, -4, 4]",\

                                                  ^
     SyntaxError: unexpected character after line continuation character
 **********************************************************************
 1 items had failures:
    1 of  57 in interfaces
 ***Test Failed*** 1 failures.
 **********************************************************************
 File "interfaces", line 318, in interfaces
 Failed example:
     maxima.plot3d("[cos(x)*(3 + y*cos(x/2)), sin(x)*(3 + y*cos(x/2)),\
       y*sin(x/2)]", "[x, -4, 4]", "[y, -4, 4]",\
       '[plot_format, openmath]') # not tested
 Exception raised:
     Traceback (most recent call last):
       File "/release/merger/sage-5.1.beta5-12415/local/lib/python2.7/site-
 packages/sage/doctest/forker.py", line 590, in _run
         compileflags, 1)
       File "<doctest interfaces[0]>", line 2
         maxima.plot3d("[cos(x)*(3 + y*cos(x/2)), sin(x)*(3 + y*cos(x/2)),\
       y*sin(x/2)]", "[x, -4, 4]", "[y, -4, 4]",\

                                                  ^
     SyntaxError: unexpected character after line continuation character
 **********************************************************************
 1 items had failures:
    1 of  57 in interfaces
 ***Test Failed*** 1 failures.
  s]
 sage -t devel/sage/doc/fr/tutorial/interactive_shell.rst
     [8 tests, 0.2 s]
 }}}
 (why is the filename simply "interfaces")

 {{{
 sage -t devel/sage/doc/en/reference/probability.rst
     [0 tests, 0.0 s]
 sage -t
 de**********************************************************************
 File "programming", line 620, in programming
 Failed example:
     for i in range(5):
 Exception raised:
     Traceback (most recent call last):
       File "/release/merger/sage-5.1.beta5-12415/local/lib/python2.7/site-
 packages/sage/doctest/forker.py", line 590, in _run
         compileflags, 1)
       File "<doctest programming[0]>", line 1
         for i in range(5):
                          ^
     SyntaxError: unexpected EOF while parsing
 **********************************************************************
 1 items had failures:
    1 of 113 in programming
 ***Test Failed*** 1 failures.
 }}}

 {{{
 sage -t devel/sage/doc/en/reference/rings_standard.rst
     [0 tests, 0.0 s]
 sage -t
 
devel/sage/doc/en/reference/combinat/root_syste**********************************************************************
 File "programming", line 578, in programming
 Failed example:
     for i in range(5):
 Exception raised:
     Traceback (most recent call last):
       File "/release/merger/sage-5.1.beta5-12415/local/lib/python2.7/site-
 packages/sage/doctest/forker.py", line 590, in _run
         compileflags, 1)
       File "<doctest programming[0]>", line 1
         for i in range(5):
                          ^
     SyntaxError: unexpected EOF while parsing
 **********************************************************************
 1 items had failures:
    1 of 113 in programming
 ***Test Failed*** 1 failures.
 ms.rst
     [0 tests, 0.0 s]
 }}}

 {{{
 sage -t devel/sage/sage/databases/odlyzko.py
     [0 tests, 0.0 s]
 sag**********************************************************************
 File "sage.doctest.reporting", line 93, in
 sage.doctest.reporting.DocTestReporter.report
 Failed example:
     DTR.report(FDS, True, 0, None, "Output so far...")
 Expected:
     sage -t .../devel/sage/sage/doctest/reporting.py
         Timed out!
     Output so far...
 Got:
     sage -t
 /release/merger/sage-5.1.beta5-12415/devel/sage/sage/doctest/reporting.py
         Timed out!
     Tests run before process froze:
     Output so far...
 **********************************************************************
 File "sage.doctest.reporting", line 102, in
 sage.doctest.reporting.DocTestReporter.report
 Failed example:
     DTR.report(FDS, False, 3, None, "Output before bad exit")
 Expected:
     sage -t .../devel/sage/sage/doctest/reporting.py
         Bad exit: 3
     Output before bad exit
 Got:
     sage -t
 /release/merger/sage-5.1.beta5-12415/devel/sage/sage/doctest/reporting.py
         Bad exit: 3
     Tests run before process failed:
     Output before bad exit
 **********************************************************************
 File "sage.doctest.reporting", line 215, in
 sage.doctest.reporting.DocTestReporter.finalize
 Failed example:
     DTR.report(FDS, True, 0, None, "Output so far...")
 Expected:
     sage -t .../devel/sage/sage/doctest/reporting.py
         Timed out!
     Output so far...
 Got:
     sage -t
 /release/merger/sage-5.1.beta5-12415/devel/sage/sage/doctest/reporting.py
         Timed out!
     Tests run before process froze:
     Output so far...
 **********************************************************************
 File "sage.doctest.reporting", line 219, in
 sage.doctest.reporting.DocTestReporter.finalize
 Failed example:
     DTR.report(FDS, False, 3, None, "Output before bad exit")
 Expected:
     sage -t .../devel/sage/sage/doctest/reporting.py
         Bad exit: 3
     Output before bad exit
 Got:
     sage -t
 /release/merger/sage-5.1.beta5-12415/devel/sage/sage/doctest/reporting.py
         Bad exit: 3
     Tests run before process failed:
     Output before bad exit
 **********************************************************************
 2 items had failures:
    2 of  26 in sage.doctest.reporting.DocTestReporter.finalize
    2 of  23 in sage.doctest.reporting.DocTestReporter.report
 ***Test Failed*** 4 failures.
 e -t devel/sage/sage/databases/sloane.py
     [1 tests, 0.1 s]
 }}}

 {{{
 sage -t devel/sage/sage/ext/cdefs.pxi
     [0 tests, 0.0 s]
 sage -t
 
devel/sage/sage/docte**********************************************************************
 File "sage.doctest.control", line 252, in
 sage.doctest.control.DocTestController.add_files
 Failed example:
     DC = DocTestController(DD, [])
 Exception raised:
     Traceback (most recent call last):
       File "/release/merger/sage-5.1.beta5-12415/local/lib/python2.7/site-
 packages/sage/doctest/forker.py", line 591, in _run
         self.execute(example, compiled, test.globs)
       File "/release/merger/sage-5.1.beta5-12415/local/lib/python2.7/site-
 packages/sage/doctest/forker.py", line 873, in execute
         exec compiled in globs
       File "<doctest
 sage.doctest.control.DocTestController.add_files[2]>", line 1, in <module>
         DC = DocTestController(DD, [])
       File "/release/merger/sage-5.1.beta5-12415/local/lib/python2.7/site-
 packages/sage/doctest/control.py", line 132, in __init__
         print "Unable to open logfile at %s\nProceeding without
 logging."%(self.logfile)
     AttributeError: 'DocTestController' object has no attribute 'logfile'
 **********************************************************************
 }}}

 {{{
 sage -t devel/sage/sage/misc/profiler.py
     [0 tests, 0.0 s]
 sage -t
 
devel/sage/**********************************************************************
 File "sage.matrix.benchmark", line 11, in sage.matrix.benchmark
 Failed example:
     print "starting"; b.report([b.det_ZZ], 'Test', systems=['sage'])
 Expected:
     starting...
     ======================================================================
               Test
     ======================================================================
     ...
     ======================================================================
 Got:
     Linux sage.math.washington.edu 2.6.24-28-server #1 SMP Fri Feb 11
 18:08:32 UTC 2011 x86_64 GNU/Linux
     starting
     ======================================================================
               Test
     ======================================================================
     <BLANKLINE>
     <BLANKLINE>
     ----------------------------------------------------------------------
     Dense integer determinant over ZZ.
         Given an n x n matrix A over ZZ with random entries
         between min and max, inclusive, compute det(A).
     <BLANKLINE>
         INPUT:
     <BLANKLINE>
         - ``n`` - matrix dimension (default: ``200``)
         - ``min`` - minimal value for entries of matrix (default: ``1``)
         - ``max`` - maximal value for entries of matrix (default: ``100``)
         - ``system`` - either 'sage' or 'magma' (default: 'sage')
     <BLANKLINE>
         EXAMPLES::
     <BLANKLINE>
             sage: import sage.matrix.benchmark as b
             sage: ts = b.det_ZZ(200)
             sage: tm = b.det_ZZ(200, system='magma')  # optional - magma
                sage
               1.370
     ======================================================================
 **********************************************************************
 }}}

-- 
Ticket URL: <http://trac.sagemath.org/sage_trac/ticket/12415#comment:56>
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.

Reply via email to