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

All Samples(10)  |  Call(8)  |  Derive(0)  |  Import(2)

src/c/o/cogent-1.5.3/tests/test_parse/test_record_finder.py   cogent(Download)
 
from cogent.parse.record import RecordError
from cogent.parse.record_finder import DelimitedRecordFinder, \
    LabeledRecordFinder, LineGrouper, TailedRecordFinder
from cogent.util.unit_test import TestCase, main
                    'ghi',
                ]
        c = LineGrouper(2)
        self.assertEqual(list(c(good)), [['>abc', 'def'],['>efg','ghi']])
        c = LineGrouper(1)
        self.assertEqual(list(c(good)), [['>abc'], ['def'],['>efg'],['ghi']])
        c = LineGrouper(4)
        self.assertEqual(list(c(good)), [['>abc', 'def','>efg','ghi']])
        #shouldn't work if not evenly divisible
        c = LineGrouper(3)

src/p/y/pycogent-HEAD/tests/test_parse/test_record_finder.py   pycogent(Download)
 
from cogent.parse.record import RecordError
from cogent.parse.record_finder import DelimitedRecordFinder, \
    LabeledRecordFinder, LineGrouper, TailedRecordFinder
from cogent.util.unit_test import TestCase, main
                    'ghi',
                ]
        c = LineGrouper(2)
        self.assertEqual(list(c(good)), [['>abc', 'def'],['>efg','ghi']])
        c = LineGrouper(1)
        self.assertEqual(list(c(good)), [['>abc'], ['def'],['>efg'],['ghi']])
        c = LineGrouper(4)
        self.assertEqual(list(c(good)), [['>abc', 'def','>efg','ghi']])
        #shouldn't work if not evenly divisible
        c = LineGrouper(3)