mirror of
https://github.com/bec-project/bec_widgets.git
synced 2025-07-14 11:41:49 +02:00
refactor(figure): logic for .add_image and .image consolidated; logic for .add_plot and .plot consolidated
This commit is contained in:
@ -9,7 +9,7 @@ def test_rpc_waveform1d_custom_curve(rpc_server_figure):
|
||||
fig = BECFigure(rpc_server_figure)
|
||||
|
||||
ax = fig.add_plot()
|
||||
curve = ax.add_curve_custom([1, 2, 3], [1, 2, 3])
|
||||
curve = ax.plot(x=[1, 2, 3], y=[1, 2, 3])
|
||||
curve.set_color("red")
|
||||
curve = ax.curves[0]
|
||||
curve.set_color("blue")
|
||||
@ -24,7 +24,7 @@ def test_rpc_plotting_shortcuts_init_configs(rpc_server_figure, qtbot):
|
||||
plt = fig.plot(x_name="samx", y_name="bpm4i")
|
||||
im = fig.image("eiger")
|
||||
motor_map = fig.motor_map("samx", "samy")
|
||||
plt_z = fig.add_plot("samx", "samy", "bpm4i")
|
||||
plt_z = fig.add_plot(x_name="samx", y_name="samy", z_name="bpm4i")
|
||||
|
||||
# Checking if classes are correctly initialised
|
||||
assert len(fig.widgets) == 4
|
||||
|
Reference in New Issue
Block a user