mirror of
https://github.com/vale981/poetry2nix
synced 2025-03-05 17:21:39 -05:00
test: patch test to use poetry-core
This commit is contained in:
parent
c17f130f3b
commit
bad8f08a2c
2 changed files with 16 additions and 4 deletions
|
@ -73,7 +73,7 @@ in
|
|||
fastapi-utils = callTest ./fastapi-utils { };
|
||||
awscli = callTest ./awscli { };
|
||||
aiopath = callTest ./aiopath { };
|
||||
# BROKEN fetched-projectdir = callTest ./fetched-projectdir { };
|
||||
fetched-projectdir = callTest ./fetched-projectdir { };
|
||||
assorted-pkgs = callTest ./assorted-pkgs { };
|
||||
watchfiles = callTest ./watchfiles { };
|
||||
sqlalchemy = callTest ./sqlalchemy { };
|
||||
|
|
|
@ -1,11 +1,23 @@
|
|||
{ poetry2nix, python39, fetchFromGitHub }:
|
||||
{ pkgs, poetry2nix, python39, fetchFromGitHub }:
|
||||
|
||||
poetry2nix.mkPoetryApplication {
|
||||
projectDir = fetchFromGitHub {
|
||||
let
|
||||
rawProjectDir = fetchFromGitHub {
|
||||
owner = "nix-community";
|
||||
repo = "pynixutil";
|
||||
rev = "d27d778dc9109227b927ab88fedb2e3c2d6a7265";
|
||||
sha256 = "sha256-+Ey384Nz6hvDZAA5OYO0EAGkGjY9Kz4134CRIMjEeyg=";
|
||||
};
|
||||
# patch the project dir to use poetry-core instead of poetry
|
||||
projectDir = pkgs.runCommand "pyproject-dir" { } ''
|
||||
mkdir -p $out
|
||||
cp -r ${rawProjectDir}/* $out
|
||||
sed \
|
||||
-i $out/pyproject.toml \
|
||||
-e 's/poetry>=0\.12/poetry-core/g' \
|
||||
-e 's/poetry\.masonry/poetry.core.masonry/g'
|
||||
'';
|
||||
in
|
||||
poetry2nix.mkPoetryApplication {
|
||||
inherit projectDir;
|
||||
python = python39;
|
||||
}
|
||||
|
|
Loading…
Add table
Reference in a new issue