Skip to content

Commit 99ba814

Browse files
authored
Handle both partial and full values for config parameters (#179)
* Handle when we have both partial and full values for config parameters * Handle all valid calls through async_bulk_set_partial_config_parameters * switch warning to info * lint * fix mypy * fix test * style * reduce number of variables * reduce num variables * update comment
1 parent bc83bdb commit 99ba814

File tree

4 files changed

+1173
-14
lines changed

4 files changed

+1173
-14
lines changed

test/conftest.py

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -69,6 +69,12 @@ def unparseable_json_string_value_state_fixture():
6969
return json.loads(load_fixture("unparseable_json_string_value_state.json"))
7070

7171

72+
@pytest.fixture(name="partial_and_full_parameter_state", scope="session")
73+
def partial_and_full_parameter_state_fixture():
74+
"""Load the node that has both partial and full parameters state fixture data."""
75+
return json.loads(load_fixture("partial_and_full_parameter_state.json"))
76+
77+
7278
@pytest.fixture(name="client_session")
7379
def client_session_fixture(ws_client):
7480
"""Mock an aiohttp client session."""
@@ -340,3 +346,11 @@ def ring_keypad_fixture(driver, ring_keypad_state):
340346
node = Node(driver.client, ring_keypad_state)
341347
driver.controller.nodes[node.node_id] = node
342348
return node
349+
350+
351+
@pytest.fixture(name="partial_and_full_parameter")
352+
def partial_and_full_parameter_fixture(driver, partial_and_full_parameter_state):
353+
"""Mock a node that has both partial and full parameters."""
354+
node = Node(driver.client, partial_and_full_parameter_state)
355+
driver.controller.nodes[node.node_id] = node
356+
return node

0 commit comments

Comments
 (0)