[arch-commits] Commit in python-portend/trunk (PKGBUILD)

Thore Bödecker foxxx0 at archlinux.org
Mon Nov 16 09:40:20 UTC 2020


    Date: Monday, November 16, 2020 @ 09:40:19
  Author: foxxx0
Revision: 755177

upgpkg: python-portend 2.6-3: disable irrelevant tests, directly invoke pytest, fixes FS#68511

Modified:
  python-portend/trunk/PKGBUILD

----------+
 PKGBUILD |   18 +++++++++++++++++-
 1 file changed, 17 insertions(+), 1 deletion(-)

Modified: PKGBUILD
===================================================================
--- PKGBUILD	2020-11-16 09:26:56 UTC (rev 755176)
+++ PKGBUILD	2020-11-16 09:40:19 UTC (rev 755177)
@@ -12,11 +12,26 @@
 depends=('python' 'python-tempora')
 makedepends=('python-setuptools' 'python-setuptools-scm' 'python-tox'
              'python-tempora')
+checkdepends=('python-pytest')
 source=("https://files.pythonhosted.org/packages/source/${_pkgbase:0:1}/${_pkgbase}/${_pkgbase}-${pkgver}.tar.gz"
         'LICENSE')
 sha512sums=('9e53c668ba9d0ddb2e92d9b4c97d2b8a4d858a6fc44123414ee3c8ac433f51f50a4773ee08f85bb134e49aeace2a17baffd32962d36df0b19b505a2c6634bf7e'
             '1106afed483b7258e4ae89c5d9459c3834412b31aac90169725ed62d2ab44f61f6f79e894d4c9e4d8bd99e14530ab778df2187784f0b25eaab86d312fad68944')
 
+prepare() {
+    cd "${srcdir}/${_pkgbase}-${pkgver}"
+    # remove linting/style tests, not relevant for downstream packaging
+    for pointless_flag in \
+      --flake8 \
+      --black \
+      --cov \
+      --cov-append \
+      --doctest-modules
+    do
+      sed -i "s/${pointless_flag}//g" pytest.ini
+    done
+}
+
 build() {
     # setuptools wont find version from git tag
     export SETUPTOOLS_SCM_PRETEND_VERSION="${pkgver}"
@@ -26,7 +41,8 @@
 
 check() {
     cd "${srcdir}/${_pkgbase}-${pkgver}"
-    tox
+    # tox
+    py.test -vvv -s -ra --showlocals --noconftest .
 }
 
 package() {



More information about the arch-commits mailing list