mirror of
https://github.com/vale981/poetry2nix
synced 2025-03-04 16:51:40 -05:00
Regression test
This commit is contained in:
parent
74303472ac
commit
b66fcd00c5
6 changed files with 175 additions and 0 deletions
|
@ -52,6 +52,7 @@ builtins.removeAttrs
|
|||
ansible-molecule = callTest ./ansible-molecule { };
|
||||
mk-poetry-packages = callTest ./mk-poetry-packages { };
|
||||
markupsafe2 = callTest ./markupsafe2 { };
|
||||
pendulum = callTest ./pendulum { };
|
||||
|
||||
# Test building poetry
|
||||
inherit poetry;
|
||||
|
|
73
tests/pendulum/.circleci/config.yml
Normal file
73
tests/pendulum/.circleci/config.yml
Normal file
|
@ -0,0 +1,73 @@
|
|||
|
||||
version: 2.1
|
||||
|
||||
workflows:
|
||||
version: 2
|
||||
|
||||
workflow:
|
||||
jobs:
|
||||
- Linux
|
||||
- MacOS
|
||||
|
||||
jobs:
|
||||
|
||||
Linux:
|
||||
docker:
|
||||
- image: nixos/nix
|
||||
|
||||
steps:
|
||||
|
||||
- checkout
|
||||
|
||||
- run:
|
||||
name: Build
|
||||
command: |
|
||||
nix-shell --run "python --version"
|
||||
|
||||
MacOS:
|
||||
macos:
|
||||
xcode: 11.4.1
|
||||
|
||||
steps:
|
||||
|
||||
- run:
|
||||
name: Install Nix
|
||||
command: |
|
||||
# Nix installation adapted from
|
||||
# https://github.com/cachix/install-nix-action/blob/master/lib/install-nix.sh
|
||||
set -euo pipefail
|
||||
|
||||
# This paragraph's steps are copied from
|
||||
# https://github.com/NixOS/nix/blob/26fcab53e05ce66f5533f0f07ed13d727a891c8d/scripts/create-darwin-volume.sh
|
||||
echo nix | sudo tee -a /etc/synthetic.conf
|
||||
/System/Library/Filesystems/apfs.fs/Contents/Resources/apfs.util -B
|
||||
disk=$(diskutil info -plist / | xpath "/plist/dict/key[text()='ParentWholeDisk']/following-sibling::string[1]/text()" 2>/dev/null)
|
||||
sudo diskutil apfs addVolume "$disk" APFS 'Nix Store' -mountpoint /nix
|
||||
|
||||
# Can't be bothered to get a daemon installation to work, so we'll
|
||||
# just do a single-user installation instead.
|
||||
sudo diskutil enableOwnership /nix
|
||||
sudo chown -R "$(whoami)" /nix
|
||||
|
||||
sh <(curl -sS --retry 5 --retry-connrefused -L https://nixos.org/nix/install) </dev/null --no-channel-add
|
||||
|
||||
# Disable spotlight indexing of /nix to speed up performance
|
||||
sudo mdutil -i off /nix
|
||||
|
||||
sudo mkdir -p /etc/nix
|
||||
echo "max-jobs = auto" | sudo tee -a /etc/nix/nix.conf
|
||||
|
||||
# macOS needs certificates hints
|
||||
cert_file=/nix/var/nix/profiles/per-user/$(whoami)/profile/etc/ssl/certs/ca-bundle.crt
|
||||
echo "export NIX_SSL_CERT_FILE=$cert_file" >> $BASH_ENV
|
||||
|
||||
# Set paths
|
||||
echo "export PATH=/nix/var/nix/profiles/per-user/$(whoami)/profile/bin:\$PATH" >> $BASH_ENV
|
||||
|
||||
- checkout
|
||||
|
||||
- run:
|
||||
name: Build
|
||||
command: |
|
||||
nix-shell --run "python --version"
|
||||
|
6
tests/pendulum/default.nix
Normal file
6
tests/pendulum/default.nix
Normal file
|
@ -0,0 +1,6 @@
|
|||
{ lib, poetry2nix, runCommand }:
|
||||
poetry2nix.mkPoetryApplication {
|
||||
pyproject = ./pyproject.toml;
|
||||
poetrylock = ./poetry.lock;
|
||||
src = lib.cleanSource ./.;
|
||||
}
|
80
tests/pendulum/poetry.lock
generated
Normal file
80
tests/pendulum/poetry.lock
generated
Normal file
|
@ -0,0 +1,80 @@
|
|||
[[package]]
|
||||
name = "pendulum"
|
||||
version = "2.1.2"
|
||||
description = "Python datetimes made easy"
|
||||
category = "main"
|
||||
optional = false
|
||||
python-versions = ">=2.7, !=3.0.*, !=3.1.*, !=3.2.*, !=3.3.*, !=3.4.*"
|
||||
|
||||
[package.dependencies]
|
||||
python-dateutil = ">=2.6,<3.0"
|
||||
pytzdata = ">=2020.1"
|
||||
|
||||
[[package]]
|
||||
name = "python-dateutil"
|
||||
version = "2.8.1"
|
||||
description = "Extensions to the standard Python datetime module"
|
||||
category = "main"
|
||||
optional = false
|
||||
python-versions = "!=3.0.*,!=3.1.*,!=3.2.*,>=2.7"
|
||||
|
||||
[package.dependencies]
|
||||
six = ">=1.5"
|
||||
|
||||
[[package]]
|
||||
name = "pytzdata"
|
||||
version = "2020.1"
|
||||
description = "The Olson timezone database for Python."
|
||||
category = "main"
|
||||
optional = false
|
||||
python-versions = ">=2.7, !=3.0.*, !=3.1.*, !=3.2.*, !=3.3.*"
|
||||
|
||||
[[package]]
|
||||
name = "six"
|
||||
version = "1.16.0"
|
||||
description = "Python 2 and 3 compatibility utilities"
|
||||
category = "main"
|
||||
optional = false
|
||||
python-versions = ">=2.7, !=3.0.*, !=3.1.*, !=3.2.*"
|
||||
|
||||
[metadata]
|
||||
lock-version = "1.1"
|
||||
python-versions = "^3.8"
|
||||
content-hash = "a890f17c417c63530209c6497568c96aade4ea2907432e17128ce009fd0ba3f3"
|
||||
|
||||
[metadata.files]
|
||||
pendulum = [
|
||||
{file = "pendulum-2.1.2-cp27-cp27m-macosx_10_15_x86_64.whl", hash = "sha256:b6c352f4bd32dff1ea7066bd31ad0f71f8d8100b9ff709fb343f3b86cee43efe"},
|
||||
{file = "pendulum-2.1.2-cp27-cp27m-win_amd64.whl", hash = "sha256:318f72f62e8e23cd6660dbafe1e346950281a9aed144b5c596b2ddabc1d19739"},
|
||||
{file = "pendulum-2.1.2-cp35-cp35m-macosx_10_15_x86_64.whl", hash = "sha256:0731f0c661a3cb779d398803655494893c9f581f6488048b3fb629c2342b5394"},
|
||||
{file = "pendulum-2.1.2-cp35-cp35m-manylinux1_i686.whl", hash = "sha256:3481fad1dc3f6f6738bd575a951d3c15d4b4ce7c82dce37cf8ac1483fde6e8b0"},
|
||||
{file = "pendulum-2.1.2-cp35-cp35m-manylinux1_x86_64.whl", hash = "sha256:9702069c694306297ed362ce7e3c1ef8404ac8ede39f9b28b7c1a7ad8c3959e3"},
|
||||
{file = "pendulum-2.1.2-cp35-cp35m-win_amd64.whl", hash = "sha256:fb53ffa0085002ddd43b6ca61a7b34f2d4d7c3ed66f931fe599e1a531b42af9b"},
|
||||
{file = "pendulum-2.1.2-cp36-cp36m-macosx_10_15_x86_64.whl", hash = "sha256:c501749fdd3d6f9e726086bf0cd4437281ed47e7bca132ddb522f86a1645d360"},
|
||||
{file = "pendulum-2.1.2-cp36-cp36m-manylinux1_i686.whl", hash = "sha256:c807a578a532eeb226150d5006f156632df2cc8c5693d778324b43ff8c515dd0"},
|
||||
{file = "pendulum-2.1.2-cp36-cp36m-manylinux1_x86_64.whl", hash = "sha256:2d1619a721df661e506eff8db8614016f0720ac171fe80dda1333ee44e684087"},
|
||||
{file = "pendulum-2.1.2-cp36-cp36m-win_amd64.whl", hash = "sha256:f888f2d2909a414680a29ae74d0592758f2b9fcdee3549887779cd4055e975db"},
|
||||
{file = "pendulum-2.1.2-cp37-cp37m-macosx_10_15_x86_64.whl", hash = "sha256:e95d329384717c7bf627bf27e204bc3b15c8238fa8d9d9781d93712776c14002"},
|
||||
{file = "pendulum-2.1.2-cp37-cp37m-manylinux1_i686.whl", hash = "sha256:4c9c689747f39d0d02a9f94fcee737b34a5773803a64a5fdb046ee9cac7442c5"},
|
||||
{file = "pendulum-2.1.2-cp37-cp37m-manylinux1_x86_64.whl", hash = "sha256:1245cd0075a3c6d889f581f6325dd8404aca5884dea7223a5566c38aab94642b"},
|
||||
{file = "pendulum-2.1.2-cp37-cp37m-win_amd64.whl", hash = "sha256:db0a40d8bcd27b4fb46676e8eb3c732c67a5a5e6bfab8927028224fbced0b40b"},
|
||||
{file = "pendulum-2.1.2-cp38-cp38-macosx_10_15_x86_64.whl", hash = "sha256:f5e236e7730cab1644e1b87aca3d2ff3e375a608542e90fe25685dae46310116"},
|
||||
{file = "pendulum-2.1.2-cp38-cp38-manylinux1_i686.whl", hash = "sha256:de42ea3e2943171a9e95141f2eecf972480636e8e484ccffaf1e833929e9e052"},
|
||||
{file = "pendulum-2.1.2-cp38-cp38-manylinux1_x86_64.whl", hash = "sha256:7c5ec650cb4bec4c63a89a0242cc8c3cebcec92fcfe937c417ba18277d8560be"},
|
||||
{file = "pendulum-2.1.2-cp38-cp38-win_amd64.whl", hash = "sha256:33fb61601083f3eb1d15edeb45274f73c63b3c44a8524703dc143f4212bf3269"},
|
||||
{file = "pendulum-2.1.2-cp39-cp39-manylinux1_i686.whl", hash = "sha256:29c40a6f2942376185728c9a0347d7c0f07905638c83007e1d262781f1e6953a"},
|
||||
{file = "pendulum-2.1.2-cp39-cp39-manylinux1_x86_64.whl", hash = "sha256:94b1fc947bfe38579b28e1cccb36f7e28a15e841f30384b5ad6c5e31055c85d7"},
|
||||
{file = "pendulum-2.1.2.tar.gz", hash = "sha256:b06a0ca1bfe41c990bbf0c029f0b6501a7f2ec4e38bfec730712015e8860f207"},
|
||||
]
|
||||
python-dateutil = [
|
||||
{file = "python-dateutil-2.8.1.tar.gz", hash = "sha256:73ebfe9dbf22e832286dafa60473e4cd239f8592f699aa5adaf10050e6e1823c"},
|
||||
{file = "python_dateutil-2.8.1-py2.py3-none-any.whl", hash = "sha256:75bb3f31ea686f1197762692a9ee6a7550b59fc6ca3a1f4b5d7e32fb98e2da2a"},
|
||||
]
|
||||
pytzdata = [
|
||||
{file = "pytzdata-2020.1-py2.py3-none-any.whl", hash = "sha256:e1e14750bcf95016381e4d472bad004eef710f2d6417240904070b3d6654485f"},
|
||||
{file = "pytzdata-2020.1.tar.gz", hash = "sha256:3efa13b335a00a8de1d345ae41ec78dd11c9f8807f522d39850f2dd828681540"},
|
||||
]
|
||||
six = [
|
||||
{file = "six-1.16.0-py2.py3-none-any.whl", hash = "sha256:8abb2f1d86890a2dfb989f9a77cfcfd3e47c2a354b01111771326f8aa26e0254"},
|
||||
{file = "six-1.16.0.tar.gz", hash = "sha256:1e61c37477a1626458e36f7b1d82aa5c9b094fa4802892072e49de9c60c4c926"},
|
||||
]
|
15
tests/pendulum/pyproject.toml
Normal file
15
tests/pendulum/pyproject.toml
Normal file
|
@ -0,0 +1,15 @@
|
|||
[tool.poetry]
|
||||
name = "test_pendulum"
|
||||
version = "0.1.0"
|
||||
description = ""
|
||||
authors = []
|
||||
|
||||
[tool.poetry.dependencies]
|
||||
python = "^3.8"
|
||||
pendulum = "^2.1.2"
|
||||
|
||||
[tool.poetry.dev-dependencies]
|
||||
|
||||
[build-system]
|
||||
requires = ["poetry>=0.12"]
|
||||
build-backend = "poetry.masonry.api"
|
0
tests/pendulum/test_pendulum.py
Normal file
0
tests/pendulum/test_pendulum.py
Normal file
Loading…
Add table
Reference in a new issue