Skip to content

Commit

Permalink
Stripping tabs and new lines from sql
Browse files Browse the repository at this point in the history
  • Loading branch information
Digant C Kasundra committed May 8, 2015
1 parent 2b71f1c commit 3ed3ccb
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion tests/model_tests/fixtures.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
import pytest
import re

from hermes import models

Expand Down Expand Up @@ -27,4 +28,5 @@ def sample_data1(db_engine):
sql_file = open('tests/sample_data/sample_data1.sql')
sql = sql_file.read()
for statement in sql.split(";"):
db_engine.execute(statement)
scrubbed = re.sub(r'[\t\n]', ' ', statement)
db_engine.execute(scrubbed)

0 comments on commit 3ed3ccb

Please sign in to comment.