Skip to content
Snippets Groups Projects
Verified Commit d3280bfd authored by Daniel Hornung's avatar Daniel Hornung
Browse files

TEST: Test for server issue #253

Value in string queries may not start with large number of digits.
parent 9a8d417b
No related branches found
No related tags found
No related merge requests found
Pipeline #48218 failed
......@@ -1483,6 +1483,7 @@ def test_235_long_name():
assert not isinstance(exc, db.HTTPServerError)
# TODO more specific error should be asserted
@pytest.mark.xfail(reason="https://gitlab.com/linkahead/linkahead-server/-/issues/248")
def test_248():
"""Querying for entities with property fails if using ID."""
......@@ -1491,3 +1492,16 @@ def test_248():
rec = db.Record().add_parent(rt).add_property(prop, value=23).insert()
results = db.execute_query(f"FIND Entity with {prop.id}")
assert len(results) == 1
@pytest.mark.xfail(reason="https://gitlab.com/linkahead/linkahead-server/-/issues/253")
def test_253():
"""Value in string queries may not start with large number of digits."""
test_strings = [
"0123456789",
"hello" + "0123456789" * 5 + "world",
"0123456789" * 5 + "world",
]
for string in test_strings:
results = db.execute_query(f"FIND Entity with prop={string}")
assert len(results) == 0
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment