Back to index

python-biopython  1.60
Public Member Functions
test_TogoWS.TogoConvert Class Reference

List of all members.

Public Member Functions

def test_invalid_format
def test_genbank_to_fasta
def test_genbank_to_embl

Detailed Description

Conversion tests.

Definition at line 470 of file test_TogoWS.py.


Member Function Documentation

Conversion of GenBank to EMBL.

Definition at line 489 of file test_TogoWS.py.

00489 
00490     def test_genbank_to_embl(self):
00491         """Conversion of GenBank to EMBL."""
00492         filename = "GenBank/NC_005816.gb"
00493         old = SeqIO.read(filename, "gb")
00494         new = SeqIO.read(TogoWS.convert(open(filename), "genbank", "embl"), "embl")
00495         self.assertEqual(str(old.seq), str(new.seq))

Here is the call graph for this function:

Conversion of GenBank to FASTA.

Definition at line 482 of file test_TogoWS.py.

00482 
00483     def test_genbank_to_fasta(self):
00484         """Conversion of GenBank to FASTA."""
00485         filename = "GenBank/NC_005816.gb"
00486         old = SeqIO.read(filename, "gb")
00487         new = SeqIO.read(TogoWS.convert(open(filename), "genbank", "fasta"), "fasta")
00488         self.assertEqual(str(old.seq), str(new.seq))

Here is the call graph for this function:

Check convert file format checking.

Definition at line 473 of file test_TogoWS.py.

00473 
00474     def test_invalid_format(self):
00475         """Check convert file format checking."""
00476         self.assertRaises(ValueError, TogoWS.convert,
00477                           StringIO("PLACEHOLDER"),
00478                           "genbank", "invalid_for_testing")
00479         self.assertRaises(ValueError, TogoWS.convert,
00480                           StringIO("PLACEHOLDER"),
00481                           "invalid_for_testing", "fasta")


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