Did I find the right examples for you? yes no      Crawl my project      Python Jobs

All Samples(6)  |  Call(4)  |  Derive(0)  |  Import(2)

src/c/o/cogent-1.5.3/tests/test_parse/test_cutg.py   cogent(Download)
#!/usr/bin/env python
"""Unit tests for the CUTG database parsers.
"""
from cogent.parse.cutg import CutgParser, CutgSpeciesParser, InfoFromLabel
from cogent.parse.record import RecordError
    def test_init(self):
        """CutgSpeciesParser should read records one at a time from lines"""
        recs = list(CutgSpeciesParser(sample_species))
        self.assertEqual(len(recs), 3)
        a, b, c = recs
            CutgSpeciesParser(sample_species[:-1]))
        #...but that it does work if we only have some of them
        recs = list(CutgSpeciesParser(sample_species[2:]))
        self.assertEqual(recs[0], b)
        self.assertEqual(len(list(CutgSpeciesParser(sample_species[1:],

src/p/y/pycogent-HEAD/tests/test_parse/test_cutg.py   pycogent(Download)
#!/usr/bin/env python
"""Unit tests for the CUTG database parsers.
"""
from cogent.parse.cutg import CutgParser, CutgSpeciesParser, InfoFromLabel
from cogent.parse.record import RecordError
    def test_init(self):
        """CutgSpeciesParser should read records one at a time from lines"""
        recs = list(CutgSpeciesParser(sample_species))
        self.assertEqual(len(recs), 3)
        a, b, c = recs
            CutgSpeciesParser(sample_species[:-1]))
        #...but that it does work if we only have some of them
        recs = list(CutgSpeciesParser(sample_species[2:]))
        self.assertEqual(recs[0], b)
        self.assertEqual(len(list(CutgSpeciesParser(sample_species[1:],