[Numpy-discussion] tests in distutils/exec_command.py

Zbyszek Szmek zbyszek@in.waw...
Sat Apr 26 11:53:30 CDT 2008

while looking at test coverage statistics published Stéfan van der Walt
at http://mentat.za.net/numpy/coverage/, I noticed that the 
least-covered file, numpy/distutils/exec_command.py has it's own 
test routines, e.g.:
def test_svn(**kws):
    s,o = exec_command(['svn','status'],**kws)
    assert s,(s,o)
    print 'svn ok'

called as 
if __name__ == "__main__":

The sense of this test seems reversed (svn status runs just fine):
Traceback (most recent call last):
  File "numpy/distutils/exec_command.py", line 591, in <module>
  File "numpy/distutils/exec_command.py", line 567, in test_svn
    assert s,(s,o)
AssertionError: (0, '')

Should the test be cleaned up and moved into a seperate file in 
numpy/distutils/tests/ ?


More information about the Numpy-discussion mailing list