diff options
author | Tor Hedin Brønner <torhedinbronner@gmail.com> | 2019-02-20 21:43:02 +0100 |
---|---|---|
committer | GitHub <noreply@github.com> | 2019-02-20 21:43:02 +0100 |
commit | bba6de611a6b22062546c1d98b990028c957add9 (patch) | |
tree | 07ef207fe6525219f3854be0c340e7c50ec1484d /pkgs/development/python-modules | |
parent | 288f353cdbc1299063ac6015ba1e67c2a5cc228f (diff) | |
parent | d20ad56ca7a75d42b0cce2ee7833ae25977636e5 (diff) | |
download | nixlib-bba6de611a6b22062546c1d98b990028c957add9.tar nixlib-bba6de611a6b22062546c1d98b990028c957add9.tar.gz nixlib-bba6de611a6b22062546c1d98b990028c957add9.tar.bz2 nixlib-bba6de611a6b22062546c1d98b990028c957add9.tar.lz nixlib-bba6de611a6b22062546c1d98b990028c957add9.tar.xz nixlib-bba6de611a6b22062546c1d98b990028c957add9.tar.zst nixlib-bba6de611a6b22062546c1d98b990028c957add9.zip |
Merge pull request #56046 from callahad/bolt
Add and enable Bolt to support Thunderbolt 3 settings in GNOME
Diffstat (limited to 'pkgs/development/python-modules')
-rw-r--r-- | pkgs/development/python-modules/python-dbusmock/default.nix | 59 |
1 files changed, 59 insertions, 0 deletions
diff --git a/pkgs/development/python-modules/python-dbusmock/default.nix b/pkgs/development/python-modules/python-dbusmock/default.nix new file mode 100644 index 000000000000..bee0cab0a3f5 --- /dev/null +++ b/pkgs/development/python-modules/python-dbusmock/default.nix @@ -0,0 +1,59 @@ +{ lib, buildPythonPackage, fetchPypi, + nose, dbus, dbus-python, pygobject3, + which, pyflakes, pycodestyle, bluez, networkmanager +}: + +buildPythonPackage rec { + pname = "python-dbusmock"; + version = "0.18.1"; + + src = fetchPypi { + inherit pname version; + sha256 = "1hj02p65cic4jdc6a5xf1hx8j5icwy7dcrm5kg91lkjks4gwpg5h"; + }; + + prePatch = '' + sed -i -e 's|pyflakes3|pyflakes|g' tests/test_code.py; + ''; + + # TODO: Get the rest of these tests running? + # This is a mocking library used as a check dependency for a single derivation. + # That derivation's tests pass. Maybe not worth the effort to fix these... + NOSE_EXCLUDE = lib.concatStringsSep "," [ + "test_bluez4" # NixOS ships BlueZ5 + # These appear to fail because they're expecting to run in an Ubuntu chroot? + "test_everything" # BlueZ5 OBEX + "test_polkitd" + "test_consolekit" + "test_api" + "test_logind" + "test_notification_daemon" + "test_ofono" + "test_gnome_screensaver" + "test_cli" + "test_timedated" + "test_upower" + # Very slow, consider disabling? + # "test_networkmanager" + ]; + + checkInputs = [ + nose dbus dbus-python which pycodestyle pyflakes + pygobject3 bluez bluez.test networkmanager + ]; + + checkPhase = '' + runHook preCheck + export PATH="$PATH:${bluez.test}/test"; + nosetests -v + runHook postCheck + ''; + + meta = with lib; { + description = "Mock D-Bus objects for tests"; + homepage = https://github.com/martinpitt/python-dbusmock; + license = licenses.lgpl3Plus; + maintainers = with maintainers; [ callahad ]; + platforms = platforms.linux; + }; +} |