Exemplo n.º 1
0
 def test_custom_delimiter(self):
     q = SimpleQueryFactory(sql='select 1, 2')
     exporter = CSVExporter(query=q)
     res = exporter.get_output(delim='|')
     self.assertEqual(res, '1|2\r\n1|2\r\n')
Exemplo n.º 2
0
 def test_custom_delimiter(self):
     q = SimpleQueryFactory(sql="select 1, 2")
     exporter = CSVExporter(query=q)
     res = exporter.get_output(delim="|")
     self.assertEqual(res, "1|2\r\n1|2\r\n")
Exemplo n.º 3
0
 def test_custom_delimiter(self):
     q = SimpleQueryFactory(sql='select 1, 2')
     exporter = CSVExporter(query=q)
     res = exporter.get_output(delim='|')
     self.assertEqual(res, '1|2\r\n1|2\r\n')
 def test_writing_bom(self):
     q = SimpleQueryFactory(sql='select 1, 2')
     exporter = CSVExporter(query=q)
     res = exporter.get_output()
     self.assertEqual(res, '\ufeff1,2\r\n1,2\r\n')