async def test_get_hvac_history(vehicle: RenaultVehicle, mocked_responses: aioresponses) -> None: """Test get_hvac_history.""" fixtures.inject_get_hvac_history(mocked_responses, "202010", "202011", "month") assert await vehicle.get_hvac_history( start=datetime(2020, 10, 1), end=datetime(2020, 11, 15), period="month", )
def test_hvac_history_month(mocked_responses: aioresponses, cli_runner: CliRunner) -> None: """It exits with a status code of zero.""" initialise_credential_store(include_account_id=True, include_vin=True) fixtures.inject_get_hvac_history(mocked_responses, start="202011", end="202011", period="month") result = cli_runner.invoke( __main__.main, "hvac history --from 2020-11-01 --to 2020-11-30") assert result.exit_code == 0, result.exception expected_output = "{}\n" assert expected_output == result.output