[arch-commits] Commit in python-pytest-socket/repos/community-any (PKGBUILD PKGBUILD)
Felix Yan
felixonmars at archlinux.org
Fri Dec 25 12:04:39 UTC 2020
Date: Friday, December 25, 2020 @ 12:04:39
Author: felixonmars
Revision: 790123
archrelease: copy trunk to community-any
Added:
python-pytest-socket/repos/community-any/PKGBUILD
(from rev 790118, python-pytest-socket/trunk/PKGBUILD)
Deleted:
python-pytest-socket/repos/community-any/PKGBUILD
----------+
PKGBUILD | 84 +++++++++++++++++++++++++++++++------------------------------
1 file changed, 44 insertions(+), 40 deletions(-)
Deleted: PKGBUILD
===================================================================
--- PKGBUILD 2020-12-25 12:04:38 UTC (rev 790122)
+++ PKGBUILD 2020-12-25 12:04:39 UTC (rev 790123)
@@ -1,40 +0,0 @@
-# Maintainer: Felix Yan <felixonmars at archlinux.org>
-
-pkgname=python-pytest-socket
-pkgver=0.3.5
-pkgrel=1
-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-dephell')
-checkdepends=('python-pytest-cov' 'python-pytest-flake8' 'python-pytest-httpbin')
-source=("https://github.com/miketheman/pytest-socket/archive/$pkgver/$pkgname-$pkgver.tar.gz")
-sha512sums=('9f62c2cdc07721dc707fb84f736dbdeed8264a775d9b477802295409a2abfafad88ee5bf2bb94a305659e81f80b8d6a0486e589b0a0100ab4523ad6d4c12849a')
-
-prepare() {
- cd pytest-socket-$pkgver
- dephell deps convert --from pyproject.toml --to setup.py
-}
-
-build() {
- cd pytest-socket-$pkgver
- python setup.py build
-}
-
-check() {
- # Hack entry points by installing it
-
- cd pytest-socket-$pkgver
- python setup.py install --root="$PWD/tmp_install" --optimize=1
- PYTHONPATH="$PWD/tmp_install/usr/lib/python3.9/site-packages:$PYTHONPATH" pytest --deselect setup.py
- }
-
-package() {
- cd pytest-socket-$pkgver
- python setup.py install --root="$pkgdir" --optimize=1
- install -D -m644 LICENSE "$pkgdir"/usr/share/licenses/$pkgname/LICENSE
-}
-
-# vim:set ts=2 sw=2 et:
Copied: python-pytest-socket/repos/community-any/PKGBUILD (from rev 790118, python-pytest-socket/trunk/PKGBUILD)
===================================================================
--- PKGBUILD (rev 0)
+++ PKGBUILD 2020-12-25 12:04:39 UTC (rev 790123)
@@ -0,0 +1,44 @@
+# Maintainer: Felix Yan <felixonmars at archlinux.org>
+
+pkgname=python-pytest-socket
+pkgver=0.3.5
+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-dephell')
+checkdepends=('python-pytest-cov' 'python-pytest-flake8' 'python-pytest-httpbin')
+source=("https://github.com/miketheman/pytest-socket/archive/$pkgver/$pkgname-$pkgver.tar.gz")
+sha512sums=('9f62c2cdc07721dc707fb84f736dbdeed8264a775d9b477802295409a2abfafad88ee5bf2bb94a305659e81f80b8d6a0486e589b0a0100ab4523ad6d4c12849a')
+
+prepare() {
+ cd pytest-socket-$pkgver
+ dephell deps convert --from pyproject.toml --to setup.py
+
+ # dephell does not generate py_modules into setup.py, so the resulting installation is missing
+ # the module source code itself. Patching it here as a workaround until we fix it properly.
+ sed -i '/license=/a \ py_modules=["pytest_socket"],' setup.py
+}
+
+build() {
+ cd pytest-socket-$pkgver
+ python setup.py build
+}
+
+check() {
+ # Hack entry points by installing it
+
+ cd pytest-socket-$pkgver
+ python setup.py install --root="$PWD/tmp_install" --optimize=1
+ PYTHONPATH="$PWD/tmp_install/usr/lib/python3.9/site-packages:$PYTHONPATH" pytest --deselect setup.py
+ }
+
+package() {
+ cd pytest-socket-$pkgver
+ python setup.py install --root="$pkgdir" --optimize=1
+ install -D -m644 LICENSE "$pkgdir"/usr/share/licenses/$pkgname/LICENSE
+}
+
+# vim:set ts=2 sw=2 et:
More information about the arch-commits
mailing list