Skip to content

Commit

Permalink
Task_id to material_id in xas tests (#366)
Browse files Browse the repository at this point in the history
  • Loading branch information
munrojm committed Aug 20, 2021
1 parent 30d5c1c commit b37c334
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions tests/xas/test_query_operators.py
Original file line number Diff line number Diff line change
Expand Up @@ -34,14 +34,14 @@ def test_xas_operator():
def test_xas_task_id_operator():
op = XASTaskIDQuery()

assert op.query(task_ids="mp-149, mp-13") == {
"criteria": {"task_id": {"$in": ["mp-149", "mp-13"]}}
assert op.query(material_ids="mp-149, mp-13") == {
"criteria": {"material_id": {"$in": ["mp-149", "mp-13"]}}
}

with ScratchDir("."):
dumpfn(op, "temp.json")
new_op = loadfn("temp.json")

assert new_op.query(task_ids="mp-149, mp-13") == {
"criteria": {"task_id": {"$in": ["mp-149", "mp-13"]}}
assert new_op.query(material_ids="mp-149, mp-13") == {
"criteria": {"material_id": {"$in": ["mp-149", "mp-13"]}}
}

0 comments on commit b37c334

Please sign in to comment.