def test_rna_fasta_format_to_dna_fasta_format(self):
     # transform RNA to DNA (reverse transcribe)
     input, obs = self.transform_format(RNAFASTAFormat, DNAFASTAFormat,
                                        'derep-test-rna.fasta')
     self.assertIsInstance(obs, DNAFASTAFormat)
     # load expected DNA seqs (already reverse transcribed)
     exp = self.dna_seqs
     # convert to DNAIterator to iterate over seqs, confirm that
     # reverse transcription occurred as expected.
     obs = _read_dna_fasta(str(obs))
     for observed, expected in zip(obs, exp):
         self.assertEqual(observed, expected)
Esempio n. 2
0
def _7(data: RNAFASTAFormat) -> DNAIterator:
    converted_dna = _rna_to_dna(str(data))
    generator = _read_dna_fasta(str(converted_dna))
    return DNAIterator(generator)