I have used conda build to successfully build packages for fftw and pyfftw. I am now trying to write a run_test.py routine to execute the tests in pyfftw as part of the build process. I wrote a run_test.py to run just one of the test files in pyfftw:
import os
path=os.environ.get('SRC_DIR')
execfile(path+'/test/test_pyfftw_real_backward.py')
At the end of the build, I get the following error:
Traceback (most recent call last):
File "/data/miniconda/conda-bld/test-tmp_dir/run_test.py", line 38, in <module>
execfile(path+'/test/test_pyfftw_real_backward.py')
File "/data/miniconda/conda-bld/work/pyFFTW-0.9.2/test/test_pyfftw_real_backward.py", line 24, in <module>
from .test_pyfftw_base import run_test_suites
ValueError: Attempted relative import in non-package
TESTS FAILED: pyfftw-0.9.2-np18py27_0
Do I add the files to the package? Or maybe copy the files to the test environment? I am actually at a loss on how to proceed. Any help would be appreciated.