2018-02-01 21:30:26 +00:00
|
|
|
{ lib
|
|
|
|
, buildPythonPackage
|
|
|
|
, fetchPypi
|
2018-07-24 16:28:26 +01:00
|
|
|
, wrapt
|
2018-02-01 21:30:26 +00:00
|
|
|
, pyserial
|
|
|
|
, nose
|
2018-07-24 16:28:26 +01:00
|
|
|
, mock
|
|
|
|
, pytest
|
|
|
|
, pytest-timeout }:
|
2018-02-01 21:30:26 +00:00
|
|
|
|
|
|
|
buildPythonPackage rec {
|
|
|
|
pname = "python-can";
|
2018-07-22 11:06:03 +01:00
|
|
|
version = "2.2.1";
|
2018-02-01 21:30:26 +00:00
|
|
|
|
|
|
|
src = fetchPypi {
|
|
|
|
inherit pname version;
|
2018-07-22 11:06:03 +01:00
|
|
|
sha256 = "b5e93b2ee32bdd597d9d908afe5171c402a04c9678ba47b60f33506738b1375b";
|
2018-02-01 21:30:26 +00:00
|
|
|
};
|
|
|
|
|
2018-07-24 16:28:26 +01:00
|
|
|
propagatedBuildInputs = [ wrapt pyserial ];
|
|
|
|
checkInputs = [ nose mock pytest pytest-timeout ];
|
|
|
|
|
|
|
|
checkPhase = ''
|
|
|
|
pytest -k "not test_writer_and_reader \
|
|
|
|
and not test_reader \
|
|
|
|
and not test_socketcan_on_ci_server"
|
|
|
|
'';
|
2018-02-01 21:30:26 +00:00
|
|
|
|
|
|
|
meta = with lib; {
|
|
|
|
homepage = https://github.com/hardbyte/python-can;
|
|
|
|
description = "CAN support for Python";
|
|
|
|
license = licenses.lgpl3;
|
|
|
|
maintainers = with maintainers; [ sorki ];
|
|
|
|
};
|
|
|
|
}
|