[Numpy-discussion] setting package path
Stefan van der Walt
stefan at sun.ac.za
Tue Feb 28 14:21:01 CST 2006
In numpytest.py, set_package_path is provided for handling path
changes while doing unit tests. It reads
""" Prepend package directory to sys.path.
set_package_path should be called from a test_file.py that
satisfies the following tree structure:
Then the first existing path name from the following list
is prepended to sys.path.
However, the line that supposedly calculates "somepath/.." is
d = os.path.dirname(os.path.dirname(os.path.abspath(testfile)))
which calculates "somepath". Which is wrong: the docstring, the code
or my interpretation?
More information about the Numpy-discussion