def test_malign(self):
self.setUpPhylotyper(aa=False)
tmpfiles = [ os.path.join(self.test_dir, 'tmp1.fasta'),
os.path.join(self.test_dir, 'tmp2.fasta')
]
tmpfile = os.path.join(self.test_dir, 'tmp_saln.fasta')
aln = SeqAligner(self.configObj)
aln.malign(self.subtype_options['input'], tmpfiles, tmpfile)
lengths = []
tmpfiles.append(tmpfile)
for f in tmpfiles:
seqs = SeqIO.parse(open(f, 'r'),'fasta')
lengths.append(len(str(seqs.next().seq)))
self.assertEqual(lengths[0]+lengths[1], lengths[2])
## TODO Add test for new multi amino acid/dna
评论列表
文章目录