Skip to content
Snippets Groups Projects
Commit 7123de81 authored by Timm Fitschen's avatar Timm Fitschen Committed by Florian Spreckelsen
Browse files

TST: Add tests for white-space issues #131 and #134

parent 73465d10
No related branches found
No related tags found
1 merge request!7Tests for multiple white space chars after `FROM`
......@@ -233,3 +233,27 @@ def test_issue_120():
permission="USE:AS_REFERENCE")
entity.update(flags={"ACL": None})
assert entity.messages["Warning", 1104][0] == "User Role does not exist."
def test_issue_134():
"""multiple white space characters after `FROM`"""
db.execute_query("SELECT pname FROM ename")
def test_issue_131():
"""white space befor unit with strange character"""
rt = db.RecordType(name="TestType").insert()
prop = db.Property(name="TestProp", datatype=db.INTEGER, unit="").insert()
rec = db.Record(name="TestRecord").add_property(
name=prop.name, value=101, unit="")
rec.add_parent(rt)
rec.insert()
result_ids = [ent.id for ent in db.execute_query(
"FIND Entity WITH {} > 100 €".format(prop.name))]
assert rec.id in result_ids
result_ids = [ent.id for ent in db.execute_query(
"FIND Entity WITH {} > 100.5 €".format(prop.name))]
assert rec.id in result_ids
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment