use pinned nixpkgs-unstable for the test driver
This commit is contained in:
parent
6fe647ecc4
commit
83863c03e5
|
@ -2,20 +2,14 @@ testArgs:
|
|||
|
||||
let
|
||||
pkgs = import <nixpkgs> { config = {}; overlays = []; };
|
||||
unstable = (import ../pkgs/nixpkgs-pinned.nix).nixpkgs-unstable;
|
||||
|
||||
# Stable nixpkgs doesn't yet include the Python testing framework.
|
||||
# Use unstable nixpkgs and patch it so that it uses stable nixpkgs for the VM
|
||||
# machine configuration.
|
||||
testingPkgs = let
|
||||
# unstable as of 2020-01-09
|
||||
rev = "9beb0d1ac2ebd6063efbdc4d3631f8ce137bbf90";
|
||||
src = builtins.fetchTarball {
|
||||
url = "https://github.com/nixos/nixpkgs-channels/archive/${rev}.tar.gz";
|
||||
sha256 = "1v95779di35qhrz70p2v27kmwm09h8pgh74i1wc72v0zp3bdrf50";
|
||||
};
|
||||
in
|
||||
testingPkgs =
|
||||
pkgs.runCommand "nixpkgs-testing" {} ''
|
||||
cp -r ${src} $out
|
||||
cp -r ${unstable} $out
|
||||
cd $out
|
||||
chmod +w -R .
|
||||
patch -p1 < ${./use-stable-pkgs.patch}
|
||||
|
|
|
@ -24,10 +24,7 @@ memoryMiB=${memoryMiB:-2048}
|
|||
|
||||
scriptDir=$(cd "${BASH_SOURCE[0]%/*}" && pwd)
|
||||
|
||||
getPkgs() {
|
||||
nix eval --raw -f "$scriptDir/../pkgs/nixpkgs-pinned.nix" $1
|
||||
}
|
||||
export NIX_PATH=nixpkgs=$(getPkgs nixpkgs):nixpkgs-unstable=$(getPkgs nixpkgs-unstable)
|
||||
export NIX_PATH=nixpkgs=$(nix eval --raw -f "$scriptDir/../pkgs/nixpkgs-pinned.nix" nixpkgs)
|
||||
|
||||
# Run the test. No temporary files are left on the host system.
|
||||
run() {
|
||||
|
|
Loading…
Reference in New Issue
Block a user