Date: Saturday, October 29, 2022 @ 16:05:19
  Author: yan12125
Revision: 1339001

python-aws-xray-sdk: fix building with newer deps

Modified:
  python-aws-xray-sdk/trunk/PKGBUILD

----------+
 PKGBUILD |   18 +++++++++++++-----
 1 file changed, 13 insertions(+), 5 deletions(-)

Modified: PKGBUILD
===================================================================
--- PKGBUILD    2022-10-29 16:00:34 UTC (rev 1339000)
+++ PKGBUILD    2022-10-29 16:05:19 UTC (rev 1339001)
@@ -18,7 +18,7 @@
             python-pg8000 python-psycopg2 python-pymongo python-pymysql
             python-pynamodb python-requests python-sqlalchemy)
 makedepends=(python-setuptools ${optdepends[@]})
-checkdepends=(python-pytest python-pytest-aiohttp python-testing.postgresql
+checkdepends=(python-pytest python-pytest-asyncio python-pytest-aiohttp 
python-testing.postgresql
               python-webtest python-django-fake-model python-mock 
python-pytest-benchmark)
 # Not using PyPI source tarball as it does not include tests
 
source=("https://github.com/aws/aws-xray-sdk-python/archive/$pkgver/$pkgname-$pkgver.tar.gz";
@@ -38,6 +38,11 @@
 
   # https://github.com/aws/aws-xray-sdk-python/issues/321
   patch -Np1 -i ../python310.diff
+
+  cat > pytest.ini <<EOF
+[pytest]
+asyncio_mode = auto
+EOF
 }
 
 build() {
@@ -53,10 +58,13 @@
   export AWS_SECRET_ACCESS_KEY=fake_key
   export AWS_ACCESS_KEY_ID=fake_id
 
-  # the test suite for pymysql uses testing.mysqld, which is not
-  # compatible with MariaDB
-  # https://github.com/tk0miya/testing.mysqld/issues/3
-  pytest -v tests --ignore tests/ext/pymysql
+  # * the test suite for aiohttp uses test_client fixture, which is
+  #   dropped in the latest pytest-aiohttp
+  # * the test suite for pymysql uses testing.mysqld, which is not
+  #   compatible with MariaDB [1]
+  # [1] https://github.com/tk0miya/testing.mysqld/issues/3
+  pytest -v tests --ignore tests/ext/aiohttp \
+                  --ignore tests/ext/pymysql
 }
 
 package() {

Reply via email to