diff options
author | Erich Eckner <git@eckner.net> | 2018-09-05 10:34:35 +0200 |
---|---|---|
committer | Erich Eckner <git@eckner.net> | 2018-09-05 10:34:35 +0200 |
commit | 93c72c41c261db78b13de9d37360a3dc43371c8d (patch) | |
tree | ebc4ffcdfc537fa801a2b5884a99de14e7fc731d /community/python-faker/PKGBUILD | |
parent | e7077f0ab72f09e4d630d44058f1008f3c670cf4 (diff) | |
download | packages-93c72c41c261db78b13de9d37360a3dc43371c8d.tar.xz |
community/python-faker: use sed instead of patch to remove future-century tests
Diffstat (limited to 'community/python-faker/PKGBUILD')
-rw-r--r-- | community/python-faker/PKGBUILD | 15 |
1 files changed, 9 insertions, 6 deletions
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" \ ' )" |