Unverified Commit c85eef94 authored by Martin Weinelt's avatar Martin Weinelt
Browse files

python310Packages.bimmer-connected: provide test responses

in the package output, as home-assistant tests rely on them.

Also enable more tests by providing pytest-asyncio.
parent de5fa879
Loading
Loading
Loading
Loading
+12 −0
Original line number Diff line number Diff line
@@ -7,9 +7,12 @@
, httpx
, pycryptodome
, pyjwt
, pytest-asyncio
, pytestCheckHook
, python
, respx
, time-machine
, tzdata
}:

buildPythonPackage rec {
@@ -39,12 +42,21 @@ buildPythonPackage rec {
    pyjwt
  ];

  postInstall = ''
    cp -R bimmer_connected/tests/responses $out/${python.sitePackages}/bimmer_connected/tests/
  '';

  nativeCheckInputs = [
    pytest-asyncio
    pytestCheckHook
    respx
    time-machine
  ];

  preCheck = ''
    export TZDIR=${tzdata}/${python.sitePackages}/tzdata/zoneinfo
  '';

  pythonImportsCheck = [
    "bimmer_connected"
  ];