From c499cc69ef24bb8d2a9faff7ef07fcfec47b41b2 Mon Sep 17 00:00:00 2001 From: Tom Prince <tom.prince@private.storage> Date: Tue, 19 Oct 2021 15:19:35 -0600 Subject: [PATCH] Update shell.nix. --- shell.nix | 23 +++++++++++------------ tests.nix | 6 +++++- 2 files changed, 16 insertions(+), 13 deletions(-) diff --git a/shell.nix b/shell.nix index 82afac5..a8d9858 100644 --- a/shell.nix +++ b/shell.nix @@ -1,14 +1,13 @@ -{ pkgs ? import ./nixpkgs.nix { } }: let - zkapauthorizer = pkgs.callPackage ./default.nix { }; + sources = import nix/sources.nix; in - (pkgs.python27.buildEnv.override { - extraLibs = with pkgs.python27Packages; [ - fixtures - testtools - hypothesis - pyhamcrest - zkapauthorizer - ]; - ignoreCollisions = true; - }).env +{ pkgs ? import sources.release2015 {} }: + let + tests = pkgs.callPackage ./tests.nix {}; + in + pkgs.mkShell { + packages = [ + tests.python + pkgs.niv + ]; + } diff --git a/tests.nix b/tests.nix index 0ac16ac..1bbeb1c 100644 --- a/tests.nix +++ b/tests.nix @@ -27,7 +27,11 @@ in _.hypothesis.postUnpack = ""; }; in - pkgs.runCommand "zkapauthorizer-tests" {} '' + pkgs.runCommand "zkapauthorizer-tests" { + passthru = { + inherit python; + }; + } '' mkdir -p $out pushd ${zkapauthorizer.src} -- GitLab