I did not know that we were shipping tests already, that's awesome!! I'll hardcode the path for the ordination data and remove these few lines of code. Thanks for the info @Jorge-C


On Apr 7, 2014, at 12:08 PM, Jorge Cañardo Alastuey <notifications@github.com> wrote:

> In setup.py:
> 
> > +
> > +# add the tests & data to be able to do skbio.tests() from a(n) (I)Python shell
> > +tests = []
> > +for root, _, fnames in os.walk('skbio'):
> > +    try:
> > +        root = root.split('/', 1)[1]
> > +    except IndexError:
> > +        # nothing to gather at the root directory of skbio
> > +        continue
> > +    else:
> > +        for fname in fnames:
> > +            fp = os.path.join(root, fname)
> > +            # the filepath has to be either test data or a test suite
> > +            if any([e in fp for e in ['/data/', '/tests/', '/test/']]):
> > +                tests.append(os.path.join(root, fname))
> > +
> This is needed to include the data files, right? Are there more data files than the ones in ordination? If so, I'd consider directly hard coding them in package_data for now. (We should already be shipping tests as they have an __init__ file).
> 
> I would defer a more complex solution until we are expecting to ship more than a few folders of test data. BTW, a package that ships a lot of data is astropy. They chose to define a get_package_data function in each module. But it needs some scaffolding and it's too complex for the current problem.
> 
> —
> Reply to this email directly or view it on GitHub.
>