Ejemplo n.º 1
0
 def test_get_by_flow(self):
     flow_id = 1
     name = 'test_table'
     columns = [{'name': 'test', 'type': 'STRING'}]
     email = '*****@*****.**'
     in_flow = Flow.create(flow_id, name, columns, email)
     flow = Flow.get_by_flow(flow_id)
     self.assertEquals(in_flow.id, flow.id)
Ejemplo n.º 2
0
 def test_get_by_flow(self):
     flow_id = 1
     name = 'test_table'
     columns = [{'name': 'test', 'type': 'STRING'}]
     email = '*****@*****.**'
     in_flow = Flow.create(flow_id, name, columns, email)
     flow = Flow.get_by_flow(flow_id)
     self.assertEquals(in_flow.id, flow.id)
Ejemplo n.º 3
0
 def test_create(self):
     flow_id = 1
     name = 'test_table'
     columns = [{'name': 'test', 'type': 'STRING'}]
     email = '*****@*****.**'
     flow = Flow.create(flow_id, name, columns, email)
     assert flow in db.session
     self.assertEquals(flow.email, email)
     self.assertEquals(flow.flow_id, flow_id)
     self.assertEquals(eval(flow.ft_columns), [x.get('name') for x in columns])
Ejemplo n.º 4
0
 def test_create(self):
     flow_id = 1
     name = 'test_table'
     columns = [{'name': 'test', 'type': 'STRING'}]
     email = '*****@*****.**'
     flow = Flow.create(flow_id, name, columns, email)
     assert flow in db.session
     self.assertEquals(flow.email, email)
     self.assertEquals(flow.flow_id, flow_id)
     self.assertEquals(eval(flow.ft_columns),
                       [x.get('name') for x in columns])