Skip to content

Commit

Permalink
add test
Browse files Browse the repository at this point in the history
  • Loading branch information
nulinspiratie committed Jun 4, 2024
1 parent 5fc7a4d commit ade4150
Showing 1 changed file with 7 additions and 0 deletions.
7 changes: 7 additions & 0 deletions tests/quam_base/referencing/test_reference_path.py
Original file line number Diff line number Diff line change
Expand Up @@ -52,3 +52,10 @@ def test_quam_list_reference():
assert (
root.quam_elem_list[1].test_str.get_reference() == "#/quam_elem_list/1/test_str"
)


def test_get_reference_attr():
component = QuamComponentTest(test_str="hi")
root = QuamRootTest(quam_elem=component, quam_elem_list=[])
assert component.get_reference() == "#/quam_elem"
assert component.get_reference("test_str") == "#/quam_elem/test_str"

0 comments on commit ade4150

Please sign in to comment.