From 37470051600d82f0c0d1b433f699c015b1d6b059 Mon Sep 17 00:00:00 2001 From: Ankur Sinha (Ankur Sinha Gmail) Date: Jan 03 2022 15:06:15 +0000 Subject: [PATCH 1/2] feat: set up for network dependent tests --- diff --git a/python-pooch.spec b/python-pooch.spec index ee13e77..a3690cd 100644 --- a/python-pooch.spec +++ b/python-pooch.spec @@ -1,3 +1,7 @@ +# Tests require network so disabled by default +# To run locally, use: fedpkg mockbuild --enable-network --with=network +%bcond_with network + Name: python-pooch Version: 1.5.2 Release: %autorelease @@ -9,7 +13,12 @@ Source0: %{pypi_source pooch} BuildArch: noarch BuildRequires: python3-devel +%if %{with network} BuildRequires: python3-pytest +BuildRequires: python3-paramiko +BuildRequires: python3-tqdm +BuildRequires: python3-xxhash +%endif %global _description %{expand: Pooch manages your Python library's sample data files: @@ -42,6 +51,10 @@ Summary: %{summary} %check %pyproject_check_import +%if %{with network} +# requires pytest-localftpserver which is not currently packaged in Fedora +%pytest -k "not ftp_downloader and not downloader_progressbar_ftp" +%endif %files -n python3-pooch -f %{pyproject_files} %doc README.* AUTHORS.* AUTHORSHIP.* CITATION.* CODE_OF_CONDUCT.* CONTRIBUTING.* MAINTENANCE.* From f1a1630df6337be6bdd43763d2fa0719f176466d Mon Sep 17 00:00:00 2001 From: Ankur Sinha (Ankur Sinha Gmail) Date: Jan 03 2022 15:12:04 +0000 Subject: [PATCH 2/2] feat: remove duplicate files --- diff --git a/python-pooch.spec b/python-pooch.spec index a3690cd..767aebc 100644 --- a/python-pooch.spec +++ b/python-pooch.spec @@ -57,8 +57,7 @@ Summary: %{summary} %endif %files -n python3-pooch -f %{pyproject_files} -%doc README.* AUTHORS.* AUTHORSHIP.* CITATION.* CODE_OF_CONDUCT.* CONTRIBUTING.* MAINTENANCE.* -%license LICENSE.* +%doc README.* CITATION.* CODE_OF_CONDUCT.* CONTRIBUTING.* MAINTENANCE.* %changelog %autochangelog