Пример #1
0
 def test_create_from_csv(self, patched_be):
     connect()
     f = Frame(CsvFile("dummy.csv", [('A', int32), ('B', int64)]))
     self.assertEqual(0, len(f))
     try:
         c = f['C']
         self.fail()
     except KeyError:
         pass
Пример #2
0
def get_simple_frame_abfgh():
    schema = [('A', int32),  ('B', int64), ('F', float32), ('G', float64), ('H', str)]
    f = Frame(CsvFile("dummy.csv", schema))
    connect()
    try:
        del _BaseFrame.schema
    except:
        pass
    setattr(f, "schema", schema)
    return f