summaryrefslogtreecommitdiffstats
path: root/tests/helpers.py
diff options
context:
space:
mode:
Diffstat (limited to 'tests/helpers.py')
-rw-r--r--tests/helpers.py8
1 files changed, 8 insertions, 0 deletions
diff --git a/tests/helpers.py b/tests/helpers.py
index ad50483..2d200f6 100644
--- a/tests/helpers.py
+++ b/tests/helpers.py
@@ -45,6 +45,14 @@ def load_sql_fixture_pairs(filename):
yield meta, sql, expected
+def string_to_bool(string):
+ if string is None:
+ return False
+ if string in (True, False):
+ return string
+ return string and string.lower() in ("true", "1")
+
+
TPCH_SCHEMA = {
"lineitem": {
"l_orderkey": "uint64",