Skip to content

Commit 1a2a1d2

Browse files
committed
Add a high-level test of query(), showing the resolution of #160
1 parent 75e3a17 commit 1a2a1d2

File tree

1 file changed

+5
-0
lines changed

1 file changed

+5
-0
lines changed

tests/nested_pandas/nestedframe/test_nestedframe.py

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -447,6 +447,11 @@ def test_query():
447447
# Check for the multi-layer error
448448
with pytest.raises(ValueError):
449449
base.query("a > 2 & nested.c > 1")
450+
# Create another nest in order to further test the multi-layer error
451+
base_2 = base.eval("nest2.c = nested.c + 1")
452+
assert len(base_2.nested_columns) == 2
453+
with pytest.raises(ValueError):
454+
base_2.query("nested.c > 1 & nest2.c > 2")
450455

451456
# Test nested queries
452457
nest_queried = base.query("nested.c > 1")

0 commit comments

Comments
 (0)