Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.
def test_reset_lora(mock_send, mock_hard_reset, lora):
"""Test reset lora command."""
lora.reset(Reset.LoRa)
mock_send.assert_called_once_with('reset=1')
mock_hard_reset.assert_not_called()
def test_reset_lora(runner, mock_rak811):
result = runner.invoke(cli, ['-v', 'reset', 'lora'])
mock_rak811.return_value.reset.assert_called_once_with(Reset.LoRa)
assert result.output.startswith('LoRa reset')