Skip to content

Commit

Permalink
Support for python2.6. Should fix master for #127
Browse files Browse the repository at this point in the history
  • Loading branch information
mdshw5 committed Oct 11, 2017
1 parent e1d8d17 commit 63cf102
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 2 deletions.
1 change: 1 addition & 0 deletions .travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,7 @@ install:
- export PATH=$PATH:$PWD
- cd ..
before_script:
- if [ $(python --version) -lt 2.7 ]; then env pip install unittest2; fi
- if [ $(python --version) -gt 2.6 ]; then env pip install biopython; fi
- env python tests/data/download_gene_fasta.py
script: nosetests --with-coverage --cover-package=pyfaidx
Expand Down
7 changes: 5 additions & 2 deletions tests/test_Fasta_bgzip.py
Original file line number Diff line number Diff line change
@@ -1,7 +1,10 @@
import os
from pyfaidx import Fasta, Faidx, UnsupportedCompressionFormat, FetchError
from itertools import chain
from unittest import TestCase, expectedFailure
try:
from unittest import TestCase, expectedFailure
except ImportError:
from unittest2 import TestCase, expectedFailure # python2.6
from nose.tools import raises
from nose.plugins.skip import SkipTest

Expand All @@ -20,7 +23,7 @@ def tearDown(self):
os.remove('data/genes.fasta.gz.fai')
except EnvironmentError:
pass # some tests may delete this file

@expectedFailure
def test_build_issue_126(self):
""" Samtools BGZF index should be identical to pyfaidx BGZF index """
Expand Down

0 comments on commit 63cf102

Please sign in to comment.