Skip to content

Commit

Permalink
Test db validate query
Browse files Browse the repository at this point in the history
  • Loading branch information
kartik4949 committed Dec 8, 2023
1 parent dd7589e commit 1329b8d
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions test/integration/test_ibis.py
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,7 @@
from superduperdb.backends.ibis.query import RawSQL, Table
from superduperdb.backends.local.artifacts import FileSystemArtifactStore
from superduperdb.backends.sqlalchemy.metadata import SQLAlchemyMetadata
from superduperdb.base import exceptions
from superduperdb.base.datalayer import Datalayer
from superduperdb.base.document import Document as D
from superduperdb.components.schema import Schema
Expand Down Expand Up @@ -190,6 +191,10 @@ def postprocess(x):
{'id': '4'},
]

# Test bad query
with pytest.raises(exceptions.QueryValidationError):
db.validate(q.gibberish_query())


def test_nested_query(ibis_sqllite_db):
db = ibis_sqllite_db
Expand Down

0 comments on commit 1329b8d

Please sign in to comment.