Date: Tuesday, April 11, 2023 @ 19:21:01
  Author: dvzrv
Revision: 1444752

archrelease: copy trunk to community-staging-any

Added:
  python-pytest-socket/repos/community-staging-any/PKGBUILD
    (from rev 1444751, python-pytest-socket/trunk/PKGBUILD)
Deleted:
  python-pytest-socket/repos/community-staging-any/PKGBUILD

----------+
 PKGBUILD |  100 +++++++++++++++++++++++++++++++++++++------------------------
 1 file changed, 61 insertions(+), 39 deletions(-)

Deleted: PKGBUILD
===================================================================
--- PKGBUILD    2023-04-11 19:20:50 UTC (rev 1444751)
+++ PKGBUILD    2023-04-11 19:21:01 UTC (rev 1444752)
@@ -1,39 +0,0 @@
-# Maintainer: Felix Yan <[email protected]>
-
-_name=pytest-socket
-pkgname=python-pytest-socket
-pkgver=0.6.0
-pkgrel=2
-pkgdesc='Pytest Plugin to disable socket calls during tests'
-arch=('any')
-license=('MIT')
-url='https://github.com/miketheman/pytest-socket'
-depends=('python-pytest')
-makedepends=('python-build' 'python-installer' 'python-poetry-core' 
'python-wheel')
-checkdepends=('python-asynctest' 'python-pytest-cov' 'python-pytest-flake8' 
'python-pytest-httpbin'
-              'python-httpx' 'python-requests' 'python-starlette')
-source=("https://github.com/miketheman/pytest-socket/archive/$pkgver/$pkgname-$pkgver.tar.gz";)
-sha512sums=('b70ab9fe3c41a707f16b6ae23d45e07238d03a731b3f99b794a6707303cd0301b75360ea164b7de48e9f2d56b5544e2da39373ba14a3b0fc20ef03afce03ab03')
-
-build() {
-  cd $_name-$pkgver
-  python -m build --wheel --no-isolation
-}
-
-check() {
-  local site_packages=$(python -c "import site; 
print(site.getsitepackages()[0])")
-
-  cd $_name-$pkgver
-  # install to temporary location, as importlib is used
-  python -m installer --destdir=test_dir dist/*.whl
-  export PYTHONPATH="test_dir/$site_packages:$PYTHONPATH"
-  pytest -vv
-}
-
-package() {
-  cd $_name-$pkgver
-  python -m installer --destdir="$pkgdir" dist/*.whl
-  install -vDm644 LICENSE -t "$pkgdir"/usr/share/licenses/$pkgname/
-}
-
-# vim:set ts=2 sw=2 et:

Copied: python-pytest-socket/repos/community-staging-any/PKGBUILD (from rev 
1444751, python-pytest-socket/trunk/PKGBUILD)
===================================================================
--- PKGBUILD                            (rev 0)
+++ PKGBUILD    2023-04-11 19:21:01 UTC (rev 1444752)
@@ -0,0 +1,61 @@
+# Maintainer:
+# Contributor: Felix Yan <[email protected]>
+
+_name=pytest-socket
+pkgname=python-pytest-socket
+pkgver=0.6.0
+pkgrel=3
+pkgdesc='Pytest Plugin to disable socket calls during tests'
+arch=(any)
+license=(MIT)
+url="https://github.com/miketheman/pytest-socket";
+depends=(
+  python
+  python-pytest
+)
+makedepends=(
+  python-build
+  python-installer
+  python-poetry-core
+  python-wheel
+)
+checkdepends=(
+  python-asynctest
+  python-httpx
+  python-pytest-cov
+  python-pytest-flake8
+  python-pytest-httpbin
+  python-requests
+  python-starlette
+)
+source=($url/archive/$pkgver/$pkgname-$pkgver.tar.gz)
+sha512sums=('b70ab9fe3c41a707f16b6ae23d45e07238d03a731b3f99b794a6707303cd0301b75360ea164b7de48e9f2d56b5544e2da39373ba14a3b0fc20ef03afce03ab03')
+b2sums=('640ce9d047ee422221ac4b707aa8a36b1c9dbeb4e8f9dc138270cbe9e5e04ece849b7308e092c1a6fc67c0c92a48f99aea41db535ad45d87ee87d18e0b6c9607')
+
+build() {
+  cd $_name-$pkgver
+  python -m build --wheel --no-isolation
+}
+
+check() {
+  local pytest_options=(
+    -vv
+    # https://github.com/miketheman/pytest-socket/issues/161
+    --deselect tests/test_async.py::test_asynctest
+  )
+  local site_packages=$(python -c "import site; 
print(site.getsitepackages()[0])")
+
+  cd $_name-$pkgver
+  # install to temporary location, as importlib is used
+  python -m installer --destdir=test_dir dist/*.whl
+  export PYTHONPATH="test_dir/$site_packages:$PYTHONPATH"
+  pytest "${pytest_options[@]}"
+}
+
+package() {
+  cd $_name-$pkgver
+  python -m installer --destdir="$pkgdir" dist/*.whl
+  install -vDm644 LICENSE -t "$pkgdir"/usr/share/licenses/$pkgname/
+}
+
+# vim:set ts=2 sw=2 et:

Reply via email to