Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
11 changes: 7 additions & 4 deletions .travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,10 @@ env:
global:
- PYTHON_VERSION=2.7
matrix:
- TEST_ADD_STUDIES=False
- TEST_ADD_STUDIES=False COVER_PACKAGE=qiita_db
- TEST_ADD_STUDIES=False COVER_PACKAGE=qiita_pet
- TEST_ADD_STUDIES=False COVER_PACKAGE=qiita_core
- TEST_ADD_STUDIES=False COVER_PACKAGE=qiita_ware
- TEST_ADD_STUDIES=True
before_install:
- redis-server --version
Expand All @@ -27,7 +30,7 @@ install:
'pandas>=0.18' 'matplotlib>=1.1.0' 'scipy>0.13.0' 'numpy>=1.7' 'h5py>=2.3.1'
- source activate qiita
- pip install -U pip
- pip install sphinx sphinx-bootstrap-theme coveralls 'ipython[all]==2.4.1' nose-timer
- pip install sphinx sphinx-bootstrap-theme 'ipython[all]==2.4.1' nose-timer codecov
- travis_retry pip install . --process-dependency-links
- 'echo "backend: Agg" > matplotlibrc'
# Install the biom plugin so we can run the analysis tests
Expand Down Expand Up @@ -56,7 +59,7 @@ script:
- if [ ${TEST_ADD_STUDIES} == "True" ]; then test_data_studies/commands.sh ; fi
- if [ ${TEST_ADD_STUDIES} == "True" ]; then qiita-cron-job ; fi
- if [ ${TEST_ADD_STUDIES} == "False" ]; then qiita-test-install ; fi
- if [ ${TEST_ADD_STUDIES} == "False" ]; then nosetests --with-doctest --with-coverage --with-timer -v --cover-package=qiita_db,qiita_pet,qiita_core,qiita_ware; fi
- if [ ${TEST_ADD_STUDIES} == "False" ]; then nosetests $COVER_PACKAGE --with-doctest --with-coverage --with-timer -v --cover-package=$COVER_PACKAGE; fi
- flake8 qiita_* setup.py scripts/*
- ls -R /home/travis/miniconda3/envs/qiita/lib/python2.7/site-packages/qiita_pet/support_files/doc/
- qiita pet webserver
Expand All @@ -66,4 +69,4 @@ services:
- redis-server
- postgresql
after_success:
- if [ ${TEST_ADD_STUDIES} == "False" ]; then coveralls ; fi
- if [ ${TEST_ADD_STUDIES} == "False" ]; then codecov ; fi
4 changes: 2 additions & 2 deletions README.rst
Original file line number Diff line number Diff line change
Expand Up @@ -80,7 +80,7 @@ future.

.. |Build Status| image:: https://travis-ci.org/biocore/qiita.png?branch=master
:target: https://travis-ci.org/biocore/qiita
.. |Coverage Status| image:: https://coveralls.io/repos/biocore/qiita/badge.png?branch=master
:target: https://coveralls.io/r/biocore/qiita
.. |Coverage Status| image:: https://codecov.io/gh/biocore/qiita/branch/master/graph/badge.svg
:target: https://codecov.io/gh/biocore/qiita
.. |Gitter| image:: https://badges.gitter.im/Join%20Chat.svg
:target: https://gitter.im/biocore/qiita?utm_source=badge&utm_medium=badge&utm_campaign=pr-badge&utm_content=badge
4 changes: 4 additions & 0 deletions qiita_db/util.py
Original file line number Diff line number Diff line change
Expand Up @@ -821,6 +821,10 @@ def move_filepaths_to_upload_folder(study_id, filepaths):
"""
with qdb.sql_connection.TRN:
uploads_fp = join(get_mountpoint("uploads")[0][1], str(study_id))

if not exists(uploads_fp):
makedirs(uploads_fp)

path_builder = partial(join, uploads_fp)

# We can now go over and remove all the filepaths
Expand Down
4 changes: 2 additions & 2 deletions qiita_pet/test/test_download.py
Original file line number Diff line number Diff line change
Expand Up @@ -183,9 +183,9 @@ def test_download_raw_data(self):
self.assertEqual(response.code, 200)

exp = (
'- 0 /protected/raw_data/1_s_G1_L001_sequences.fastq.gz '
'- 58 /protected/raw_data/1_s_G1_L001_sequences.fastq.gz '
'raw_data/1_s_G1_L001_sequences.fastq.gz\n'
'- 0 /protected/raw_data/1_s_G1_L001_sequences_barcodes.fastq.gz '
'- 58 /protected/raw_data/1_s_G1_L001_sequences_barcodes.fastq.gz '
'raw_data/1_s_G1_L001_sequences_barcodes.fastq.gz\n'
'- 36615 /protected/templates/1_prep_1_qiime_[0-9]*-[0-9]*.txt '
'mapping_files/1_mapping_file.txt\n'
Expand Down
14 changes: 7 additions & 7 deletions qiita_ware/test/test_ebi.py
Original file line number Diff line number Diff line change
Expand Up @@ -45,13 +45,6 @@ def setUp(self):
self.study_id = None

def tearDown(self):
for f in self.files_to_remove:
if exists(f):
if isdir(f):
rmtree(f)
else:
remove(f)

if self.study_id and Study.exists("Test EBI study"):
study = Study(self.study_id)
for a in study.artifacts():
Expand All @@ -61,6 +54,13 @@ def tearDown(self):
SampleTemplate.delete(self.study_id)
Study.delete(self.study_id)

for f in self.files_to_remove:
if exists(f):
if isdir(f):
rmtree(f)
else:
remove(f)

def test_init(self):
artifact_id = 3
action = 'ADD'
Expand Down