From 93c72c41c261db78b13de9d37360a3dc43371c8d Mon Sep 17 00:00:00 2001 From: Erich Eckner Date: Wed, 5 Sep 2018 10:34:35 +0200 Subject: community/python-faker: use sed instead of patch to remove future-century tests --- community/python-faker/PKGBUILD | 15 +++++++++------ 1 file changed, 9 insertions(+), 6 deletions(-) (limited to 'community/python-faker/PKGBUILD') diff --git a/community/python-faker/PKGBUILD b/community/python-faker/PKGBUILD index 87168ec5..891d7841 100644 --- a/community/python-faker/PKGBUILD +++ b/community/python-faker/PKGBUILD @@ -1,15 +1,18 @@ # https://github.com/joke2k/faker/issues/408 # time-tests requiring 64 bit fail on i686 - obviously (year 2100 is not representable with 32 bits) -source+=('remove-century-tests.patch') -sha512sums+=('69d6c7685f49d28bc5a4ea952d6f0f6ab03e7c9956e338fc7e26d6a714de569641b82e95bb30de15b4598b6fbf3fb8e0a497fde2e28bd988fafbeb030bb24f91') - eval "$( declare -f prepare | \ sed ' /^{\s*$/a \ - cd "$srcdir"/faker-$pkgver\ - patch -p1 -i "$srcdir/remove-century-tests.patch"\ - cd "$srcdir" + sed -i '"'"'/\\.date_\\(time_\\)\\?this_century(.*) >= /d'"'"' "$srcdir/faker-$pkgver/tests/providers/test_date_time.py" \ + sed -i '"'"' \ + $! N; \ + /^\\(.\\+\\)\\n\\1$/ ! { \ + P; \ + D; \ + } \ + D; \ + '"'"' "$srcdir/faker-$pkgver/tests/providers/test_date_time.py" \ ' )" -- cgit v1.2.3-70-g09d2