1
0
mirror of https://github.com/bec-project/bec_widgets.git synced 2026-04-07 01:07:54 +02:00

tests(e2e): wait for the plotting to finish before checking the data

This commit is contained in:
2025-01-09 11:15:43 +01:00
parent 54e64c9f10
commit b4a240e463
3 changed files with 39 additions and 10 deletions

View File

@@ -224,3 +224,11 @@ DEVICES = [
Positioner("test", limits=[-10, 10], read_value=2.0),
Device("test_device"),
]
def check_remote_data_size(widget, plot_name, num_elements):
"""
Check if the remote data has the correct number of elements.
Used in the qtbot.waitUntil function.
"""
return len(widget.get_all_data()[plot_name]["x"]) == num_elements