-
Notifications
You must be signed in to change notification settings - Fork 6
Open
Labels
Description
This test will throw a syntax error because of the single quotes:
Feature: Imma feature
Background:
Given the SQL files in the path "/sql":
| file |
| testing_things.sql |
And their table dependencies:
| table |
| schema.table |
Scenario: Adopted customer
Given the existing table schema.table with date placeholders:
| name |
| This has 'quotes' |
When the given SQL files are executed and the result is returned
Then the result exactly matches:
| name |
| This has 'quotes' |
ERROR: syntax error at or near "quotes" squcumber-app | LINE 1: ...sert into schema.table (name) values ('This has 'quotes'')
where name is varchar(255)
in order to make the test pass, we need to escape the quotes
Feature: Imma feature
Background:
Given the SQL files in the path "/sql":
| file |
| testing_things.sql |
And their table dependencies:
| table |
| schema.table |
Scenario: Adopted customer
Given the existing table schema.table with date placeholders:
| name |
| This has ''quotes'' |
When the given SQL files are executed and the result is returned
Then the result exactly matches:
| name |
| This has 'quotes' |