From 0f3217f352cad465a78bb3cddb0f664fcec19ddb Mon Sep 17 00:00:00 2001 From: Yaroslav Halchenko Date: Mon, 17 Apr 2017 10:24:30 -0400 Subject: [PATCH] "cherry-pick" a639f0b083c213bde4ff3dcfbbb9fbcab0dd55f8 (BF: specify explicit time offset not a time zone name to avoid needing tzdata during testing) --- ...9f0b083c213bde4ff3dcfbbb9fbcab0dd55f8.diff | 24 +++++++++++++++++++ debian/patches/series | 1 + 2 files changed, 25 insertions(+) create mode 100644 debian/patches/changeset_a639f0b083c213bde4ff3dcfbbb9fbcab0dd55f8.diff diff --git a/debian/patches/changeset_a639f0b083c213bde4ff3dcfbbb9fbcab0dd55f8.diff b/debian/patches/changeset_a639f0b083c213bde4ff3dcfbbb9fbcab0dd55f8.diff new file mode 100644 index 00000000..fd45cafc --- /dev/null +++ b/debian/patches/changeset_a639f0b083c213bde4ff3dcfbbb9fbcab0dd55f8.diff @@ -0,0 +1,24 @@ +From: Paul Brook +Subject: BF: specify explicit time offset not a time zone name to avoid needing tzdata during testing + +Origin: Debian +Bug-Debian: https://bugs.debian.org/855920 +Forwarded: https://github.com/fail2ban/fail2ban/pull/1754 +Applied-Upstream: yes +Last-Update: 2017-04-17 + + +--- a/fail2ban/tests/utils.py ++++ b/fail2ban/tests/utils.py +@@ -95,7 +95,10 @@ def setUpMyTime(): + # Set the time to a fixed, known value + # Sun Aug 14 12:00:00 CEST 2005 + # yoh: we need to adjust TZ to match the one used by Cyril so all the timestamps match +- os.environ['TZ'] = 'Europe/Zurich' ++ # This offset corresponds to Europe/Zurich timezone. Specifying it ++ # explicitly allows to avoid requiring tzdata package to be installed during ++ # testing. See https://bugs.debian.org/855920 for more information ++ os.environ['TZ'] = 'CET-01CEST-02,M3.5.0,M10.5.0' + time.tzset() + MyTime.setTime(1124013600) + diff --git a/debian/patches/series b/debian/patches/series index 7438f9f3..e6a8ca97 100644 --- a/debian/patches/series +++ b/debian/patches/series @@ -1,2 +1,3 @@ +changeset_a639f0b083c213bde4ff3dcfbbb9fbcab0dd55f8.diff deb_init_paths deb_manpages_reportbug