2020-08-20 17:08:02 +00:00
|
|
|
{ lib
|
|
|
|
, fetchFromGitHub
|
2022-12-17 10:02:37 +00:00
|
|
|
, python3
|
2020-08-20 17:08:02 +00:00
|
|
|
}:
|
|
|
|
|
2022-12-17 10:02:37 +00:00
|
|
|
python3.pkgs.buildPythonApplication rec {
|
2020-08-20 17:08:02 +00:00
|
|
|
pname = "terraform-compliance";
|
2024-04-21 15:54:59 +00:00
|
|
|
version = "1.3.48";
|
2022-12-17 10:02:37 +00:00
|
|
|
format = "setuptools";
|
2020-08-20 17:08:02 +00:00
|
|
|
|
|
|
|
src = fetchFromGitHub {
|
2022-12-17 10:02:37 +00:00
|
|
|
owner = "terraform-compliance";
|
|
|
|
repo = "cli";
|
|
|
|
rev = "refs/tags/${version}";
|
2024-04-21 15:54:59 +00:00
|
|
|
sha256 = "sha256-2nf/EJcC4KYTBItByX47UqTSs2EOgsUAgRbLEdB4Iyg=";
|
2020-08-20 17:08:02 +00:00
|
|
|
};
|
|
|
|
|
2020-09-25 04:45:31 +00:00
|
|
|
postPatch = ''
|
|
|
|
substituteInPlace setup.py \
|
2022-12-17 10:02:37 +00:00
|
|
|
--replace "IPython==7.16.1" "IPython" \
|
2023-10-09 19:29:22 +00:00
|
|
|
--replace "diskcache==5.1.0" "diskcache>=5.1.0" \
|
|
|
|
--replace "radish-bdd==0.13.1" "radish-bdd" \
|
2020-09-25 04:45:31 +00:00
|
|
|
'';
|
|
|
|
|
2022-12-17 10:02:37 +00:00
|
|
|
propagatedBuildInputs = with python3.pkgs; [
|
|
|
|
diskcache
|
2020-08-20 17:08:02 +00:00
|
|
|
emoji
|
|
|
|
filetype
|
2022-12-17 10:02:37 +00:00
|
|
|
gitpython
|
2020-08-20 17:08:02 +00:00
|
|
|
ipython
|
|
|
|
junit-xml
|
|
|
|
lxml
|
|
|
|
mock
|
|
|
|
netaddr
|
|
|
|
radish-bdd
|
|
|
|
semver
|
2023-10-09 19:29:22 +00:00
|
|
|
orjson
|
2020-08-20 17:08:02 +00:00
|
|
|
];
|
|
|
|
|
2023-02-02 18:25:31 +00:00
|
|
|
nativeCheckInputs = with python3.pkgs; [
|
2022-12-17 10:02:37 +00:00
|
|
|
pytestCheckHook
|
|
|
|
];
|
|
|
|
|
|
|
|
disabledTests = [
|
|
|
|
"test_which_success"
|
|
|
|
"test_readable_plan_file_is_not_json"
|
|
|
|
];
|
|
|
|
|
|
|
|
pythonImportsCheck = [
|
|
|
|
"terraform_compliance"
|
|
|
|
];
|
|
|
|
|
2020-08-20 17:08:02 +00:00
|
|
|
meta = with lib; {
|
|
|
|
description = "BDD test framework for terraform";
|
2024-04-21 15:54:59 +00:00
|
|
|
mainProgram = "terraform-compliance";
|
2022-12-17 10:02:37 +00:00
|
|
|
homepage = "https://github.com/terraform-compliance/cli";
|
|
|
|
changelog = "https://github.com/terraform-compliance/cli/releases/tag/${version}";
|
2020-08-20 17:08:02 +00:00
|
|
|
license = licenses.mit;
|
2023-10-09 19:29:22 +00:00
|
|
|
maintainers = with maintainers; [ kalbasit kashw2 ];
|
2020-08-20 17:08:02 +00:00
|
|
|
};
|
|
|
|
}
|