def _bind_to_strand(self, strand): for idx, symbol in enumerate(strand): if Base.get_base_by_symbol(symbol) == self.binding_preference: return WorkingEnzyme(strand=strand, pos=idx)
def test_can_get_base_by_symbol(self): expected_base = Base.adenine self.assertEqual(Base.get_base_by_symbol('A'), expected_base)