Back to index

python-biopython  1.60
Public Member Functions
test_SeqIO_index.OldIndexTest Class Reference

List of all members.

Public Member Functions

def test_old
def test_old_format
def test_old_format_wrong
def test_old_files
def test_old_files_wrong
def test_old_files_wrong2

Detailed Description

Testing a pre-built index (make sure cross platform etc).

>>> from Bio import SeqIO
>>> d = SeqIO.index_db("triple_sff.idx", ["E3MFGYR02_no_manifest.sff", "greek.sff", "paired.sff"], "sff")
>>> len(d)

Definition at line 52 of file

Member Function Documentation

Load existing index with no options.

Definition at line 60 of file

00061         def test_old(self):
00062             """Load existing index with no options."""
00063             d = SeqIO.index_db("Roche/triple_sff.idx")
00064             self.assertEqual(54, len(d))

Load existing index with correct files.

Definition at line 75 of file

00076         def test_old_files(self):
00077             """Load existing index with correct files."""
00078             d = SeqIO.index_db("Roche/triple_sff.idx",
00079                                ["E3MFGYR02_no_manifest.sff", "greek.sff", "paired.sff"])
00080             self.assertEqual(54, len(d))

Load existing index with wrong files.

Definition at line 81 of file

00082         def test_old_files_wrong(self):
00083             """Load existing index with wrong files."""
00084             self.assertRaises(ValueError, SeqIO.index_db,
00085                               "Roche/triple_sff.idx", ["a.sff", "b.sff", "c.sff"])

Load existing index with wrong number of files.

Definition at line 86 of file

00087         def test_old_files_wrong2(self):
00088             """Load existing index with wrong number of files."""
00089             self.assertRaises(ValueError, SeqIO.index_db,
00090                               "Roche/triple_sff.idx",
00091                               ["E3MFGYR02_no_manifest.sff", "greek.sff"])

Load existing index with correct format.

Definition at line 65 of file

00066         def test_old_format(self):
00067             """Load existing index with correct format."""
00068             d = SeqIO.index_db("Roche/triple_sff.idx", format="sff")
00069             self.assertEqual(54, len(d))

Load existing index with wrong format.

Definition at line 70 of file

00071         def test_old_format_wrong(self):
00072             """Load existing index with wrong format."""
00073             self.assertRaises(ValueError, SeqIO.index_db,
00074                               "Roche/triple_sff.idx", format="fasta")

The documentation for this class was generated from the following file: