def test_parse_fasta_file(self):
        """ Properly returns dict from fasta data """

        fasta_data = ['>seq1 SAMPLE1', 'AAACGT', '>seq2', 'ACGGT']

        expected_fasta = {'seq1': 'AAACGT', 'seq2': 'ACGGT'}

        expected_order = ['seq1 SAMPLE1', 'seq2']

        actual_fasta, actual_order = parse_fasta_file(fasta_data)

        self.assertEqual(actual_fasta, expected_fasta)

        self.assertEqual(actual_order, expected_order)
Ejemplo n.º 2
0
    def test_parse_fasta_file(self):
        """ Properly returns dict from fasta data """

        fasta_data = ['>seq1 SAMPLE1', 'AAACGT', '>seq2', 'ACGGT']

        expected_fasta = {'seq1': 'AAACGT', 'seq2': 'ACGGT'}

        expected_order = ['seq1 SAMPLE1', 'seq2']

        actual_fasta, actual_order = parse_fasta_file(fasta_data)

        self.assertEqual(actual_fasta, expected_fasta)

        self.assertEqual(actual_order, expected_order)
    def test_parse_fasta_file(self):
        """ Properly returns dict from fasta data """

        fasta_data = [">seq1 SAMPLE1", "AAACGT", ">seq2", "ACGGT"]

        expected_fasta = {"seq1": "AAACGT", "seq2": "ACGGT"}

        expected_order = ["seq1 SAMPLE1", "seq2"]

        actual_fasta, actual_order = parse_fasta_file(fasta_data)

        self.assertEqual(actual_fasta, expected_fasta)

        self.assertEqual(actual_order, expected_order)