File tree Expand file tree Collapse file tree 1 file changed +14
-0
lines changed
Expand file tree Collapse file tree 1 file changed +14
-0
lines changed Original file line number Diff line number Diff line change @@ -831,6 +831,20 @@ def test_multi_function_invalid_name_raises(dci: DummyChannelInstrument) -> None
831831 dci .channels .multi_function ("nonexistent_func" )
832832
833833
834+ def test_multi_function_on_empty_channel_tuple_raises (
835+ empty_instrument : Instrument ,
836+ ) -> None :
837+ """Test that multi_function raises AttributeError on empty channel tuple."""
838+ channels = ChannelTuple (empty_instrument , "channels" , chan_type = DummyChannel )
839+ empty_instrument .add_submodule ("channels" , channels )
840+
841+ with pytest .raises (
842+ AttributeError ,
843+ match = "'ChannelTuple' object has no callable or function 'temperature'" ,
844+ ):
845+ channels .multi_function ("temperature" )
846+
847+
834848def _verify_multiparam_data (data ) -> None :
835849 assert "multi_setpoint_param_this_setpoint_set" in data .arrays .keys ()
836850 assert_array_equal (
You can’t perform that action at this time.
0 commit comments