Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
  • Loading branch information
joocer committed Aug 31, 2024
1 parent feeedfc commit b1c2793
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -53,9 +53,17 @@ def build_literal_node(value: Any, root: Node, suggested_type: OrsoTypes):
if hasattr(value, "as_py"):
value = value.as_py()

if value is None:
# Matching None has complications
root.value = None
root.node_type = NodeType.LITERAL
root.type = OrsoTypes.NULL
root.left = None
root.right = None
return root

# Define a mapping of types to OrsoTypes
type_mapping = {
None: OrsoTypes.NULL,
bool: OrsoTypes.BOOLEAN,
numpy.bool_: OrsoTypes.BOOLEAN,
str: OrsoTypes.VARCHAR,
Expand Down
2 changes: 1 addition & 1 deletion tests/sql_battery/test_results_battery.py
Original file line number Diff line number Diff line change
Expand Up @@ -71,7 +71,7 @@ def test_results_tests(test):

start_suite = time.monotonic_ns()

width = shutil.get_terminal_size((80, 20))[0] - 40
width = shutil.get_terminal_size((80, 20))[0] - 42

passed = 0
failed = 0
Expand Down

0 comments on commit b1c2793

Please sign in to comment.