Date: Tuesday, April 18, 2023 @ 18:12:35
  Author: jelle
Revision: 1447261

upgpkg: python-oslo-i18n 6.0.0-3: run tests succesfully

Added:
  python-oslo-i18n/trunk/fix-tests-extra-warning.patch
Modified:
  python-oslo-i18n/trunk/PKGBUILD

-------------------------------+
 PKGBUILD                      |   15 +++++++++++----
 fix-tests-extra-warning.patch |   13 +++++++++++++
 2 files changed, 24 insertions(+), 4 deletions(-)

Modified: PKGBUILD
===================================================================
--- PKGBUILD    2023-04-18 17:52:33 UTC (rev 1447260)
+++ PKGBUILD    2023-04-18 18:12:35 UTC (rev 1447261)
@@ -4,7 +4,7 @@
 pkgname=python-oslo-i18n
 pkgver=6.0.0
 _commit=03605c2db7d034ad6776b860d4928939ae7e3594
-pkgrel=2
+pkgrel=3
 pkgdesc="Oslo i18n library"
 arch=('any')
 url="https://pypi.python.org/pypi/oslo.i18n/$pkgver";
@@ -11,10 +11,17 @@
 license=('Apache')
 depends=('python-pbr')
 makedepends=('git')
-checkdepends=('python-oslotest' 'python-oslo-config')
-source=("git+https://github.com/openstack/oslo.i18n.git#commit=$_commit";)
-sha512sums=('SKIP')
+checkdepends=('python-oslotest' 'python-oslo-config' 'python-stestr' 
'python-testscenarios')
+source=("git+https://github.com/openstack/oslo.i18n.git#commit=$_commit";
+        "fix-tests-extra-warning.patch")
+sha512sums=('SKIP'
+            
'445b03985fafef0e4db856afe54772bb8b23b328f0a0166277c5aba9e899e2c6596737c45c11f0581fa3093853048134eac1c894227e88be463a4d0affe849e8')
 
+prepare() {
+  cd oslo.i18n
+  patch -Np1 -i ${srcdir}/fix-tests-extra-warning.patch
+}
+
 build() {
   cd oslo.i18n
   python setup.py build

Added: fix-tests-extra-warning.patch
===================================================================
--- fix-tests-extra-warning.patch                               (rev 0)
+++ fix-tests-extra-warning.patch       2023-04-18 18:12:35 UTC (rev 1447261)
@@ -0,0 +1,13 @@
+Only in oslo.i18n.new/oslo_i18n: __pycache__
+Only in oslo.i18n.new/oslo_i18n/tests: __pycache__
+diff -aur oslo.i18n.new/oslo_i18n/tests/test_message.py 
oslo.i18n/oslo_i18n/tests/test_message.py
+--- oslo.i18n.new/oslo_i18n/tests/test_message.py      2023-04-18 
19:52:48.773449094 +0200
++++ oslo.i18n/oslo_i18n/tests/test_message.py  2023-04-18 20:03:29.083036381 
+0200
+@@ -380,6 +380,7 @@
+ 
+         with warnings.catch_warnings(record=True) as w:
+             warnings.simplefilter("always")
++            warnings.filterwarnings("ignore", category=DeprecationWarning)
+             msg = _message.Message(message_with_params)
+             msg = msg % param
+             default_translation = message_with_params % param

Reply via email to