diff --git a/holidays/countries/belarus.py b/holidays/countries/belarus.py index c8ac62f82..f2b4e609f 100644 --- a/holidays/countries/belarus.py +++ b/holidays/countries/belarus.py @@ -11,7 +11,7 @@ from gettext import gettext as tr -from holidays.calendars.gregorian import GREGORIAN_CALENDAR +from holidays.calendars.gregorian import GREGORIAN_CALENDAR, JAN, MAR, APR, MAY, JUN, JUL, NOV, DEC from holidays.calendars.julian import JULIAN_CALENDAR from holidays.groups import ChristianHolidays, InternationalHolidays from holidays.holiday_base import HolidayBase @@ -24,11 +24,153 @@ class Belarus(HolidayBase, ChristianHolidays, InternationalHolidays): References: - http://president.gov.by/en/holidays_en/ - http://www.belarus.by/en/about-belarus/national-holidays + - http://laws.newsby.org/documents/ukazp/pos05/ukaz05806.htm + - http://president.gov.by/uploads/documents/2019/464uk.pdf + - https://ru.wikipedia.org/wiki/%D0%9F%D1%80%D0%B0%D0%B7%D0%B4%D0%BD%D0%B8%D0%BA%D0%B8_%D0%91%D0%B5%D0%BB%D0%BE%D1%80%D1%83%D1%81%D1%81%D0%B8%D0%B8 # noqa: E501 """ country = "BY" default_language = "be" supported_languages = ("be", "en_US") + # Date format (see strftime() Format Codes) + substituted_date_format = tr("%d.%m.%Y") + # Day off (substituted from %s). + substituted_label = tr("Выходны (перанесены з %s)") + substituted_holidays = { + 1998: ( + (JAN, 10, JAN, 2), + (APR, 25, APR, 27), + ), + 1999: ( + (JAN, 16, JAN, 8), + (APR, 17, APR, 19), + ), + 2000: ( + (MAY, 13, MAY, 8), + (NOV, 11, NOV, 6), + ), + 2001: ( + (JAN, 20, JAN, 2), + (MAR, 3, MAR, 9), + (APR, 21, APR, 23), + (APR, 28, APR, 30), + (JUL, 7, JUL, 2), + (DEC, 22, DEC, 24), + (DEC, 29, DEC, 31), + ), + 2002: ( + (JAN, 5, JAN, 2), + (MAY, 18, MAY, 10), + (NOV, 16, NOV, 8), + ), + 2003: ( + (JAN, 4, JAN, 6), + (MAY, 3, MAY, 5), + ), + 2004: ( + (JAN, 10, JAN, 2), + (JAN, 17, JAN, 5), + (JAN, 31, JAN, 6), + (APR, 17, APR, 19), + ), + 2005: (MAR, 12, MAR, 7), + 2006: ( + (JAN, 21, JAN, 2), + (MAY, 6, MAY, 8), + (NOV, 4, NOV, 6), + ), + 2007: ( + (2006, DEC, 30, JAN, 2), + (MAR, 17, MAR, 9), + (APR, 14, APR, 16), + (MAY, 5, APR, 30), + (JUL, 7, JUL, 2), + (DEC, 22, DEC, 24), + (DEC, 29, DEC, 31), + ), + 2008: ( + (JAN, 12, JAN, 2), + (MAY, 3, MAY, 5), + (JUN, 28, JUL, 4), + (DEC, 20, DEC, 26), + ), + 2009: ( + (JAN, 10, JAN, 2), + (APR, 25, APR, 27), + ), + 2010: ( + (JAN, 23, JAN, 8), + (APR, 17, APR, 12), + (MAY, 15, MAY, 10), + ), + 2011: ( + (MAR, 12, MAR, 7), + (MAY, 14, MAY, 2), + ), + 2012: ( + (MAR, 11, MAR, 9), + (APR, 28, APR, 23), + (JUN, 30, JUL, 2), + (DEC, 22, DEC, 24), + (DEC, 29, DEC, 31), + ), + 2013: ( + (JAN, 5, JAN, 2), + (MAY, 18, MAY, 10), + ), + 2014: ( + (JAN, 4, JAN, 2), + (JAN, 11, JAN, 6), + (MAY, 3, APR, 30), + (JUL, 12, JUL, 4), + (DEC, 20, DEC, 26), + ), + 2015: ( + (JAN, 10, JAN, 2), + (APR, 25, APR, 20), + ), + 2016: ( + (JAN, 16, JAN, 8), + (MAR, 5, MAR, 7), + ), + 2017: ( + (JAN, 21, JAN, 2), + (APR, 29, APR, 24), + (MAY, 6, MAY, 8), + (NOV, 4, NOV, 6), + ), + 2018: ( + (JAN, 20, JAN, 2), + (MAR, 3, MAR, 9), + (APR, 14, APR, 16), + (APR, 28, APR, 30), + (JUL, 7, JUL, 2), + (DEC, 22, DEC, 24), + (DEC, 29, DEC, 31), + ), + 2019: ( + (MAY, 4, MAY, 6), + (MAY, 11, MAY, 8), + (NOV, 16, NOV, 8), + ), + 2020: ( + (JAN, 4, JAN, 6), + (APR, 4, APR, 27), + ), + 2021: ( + (JAN, 16, JAN, 8), + (MAY, 15, MAY, 10), + ), + 2022: ( + (MAR, 12, MAR, 7), + (MAY, 14, MAY, 2), + ), + 2023: ( + (APR, 29, APR, 24), + (MAY, 13, MAY, 8), + (NOV, 11, NOV, 6), + ), + } def __init__(self, *args, **kwargs): ChristianHolidays.__init__(self, JULIAN_CALENDAR) @@ -36,9 +178,8 @@ def __init__(self, *args, **kwargs): super().__init__(*args, **kwargs) def _populate(self, year): - # The current set of holidays came into force in 1998. - # http://laws.newsby.org/documents/ukazp/pos05/ukaz05806.htm - if year <= 1998: + # The current set of holidays actual from 1998. + if year <= 1997: return None super()._populate(year) @@ -46,8 +187,6 @@ def _populate(self, year): # New Year's Day. self._add_new_years_day(tr("Новы год")) - # Jan 2nd is the national holiday (New Year) from 2020. - # http://president.gov.by/uploads/documents/2019/464uk.pdf if year >= 2020: self._add_new_years_day_two(tr("Новы год")) diff --git a/holidays/locale/be/LC_MESSAGES/BY.po b/holidays/locale/be/LC_MESSAGES/BY.po index eff56c9bc..fe7e9fa9c 100644 --- a/holidays/locale/be/LC_MESSAGES/BY.po +++ b/holidays/locale/be/LC_MESSAGES/BY.po @@ -3,18 +3,29 @@ # msgid "" msgstr "" -"Project-Id-Version: Python Holidays 0.20\n" +"Project-Id-Version: Python Holidays 0.34\n" "POT-Creation-Date: 2023-02-15 20:06-0800\n" -"PO-Revision-Date: 2023-02-16 08:45-0800\n" -"Last-Translator: Arkadii Yakovets \n" +"PO-Revision-Date: 2023-09-27 18:49+0300\n" +"Last-Translator: ~Jhellico \n" "Language-Team: Python Holidays localization team\n" "Language: be\n" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" +"Plural-Forms: nplurals=3; plural=(n%10==1 && n%100!=11 ? 0 : n%10>=2 && n%10<=4 && (n%100<12 || " +"n%100>14) ? 1 : 2);\n" "Generated-By: Lingua 4.15.0\n" "X-Generator: Poedit 3.2.2\n" +#. Date format (see strftime() Format Codes) +msgid "%d.%m.%Y" +msgstr "" + +#. Day off (substituted from %s). +#, c-format +msgid "Выходны (перанесены з %s)" +msgstr "" + #. New Year's Day. msgid "Новы год" msgstr "" diff --git a/holidays/locale/en_US/LC_MESSAGES/BY.po b/holidays/locale/en_US/LC_MESSAGES/BY.po index 72dc5ed1d..421e266bd 100644 --- a/holidays/locale/en_US/LC_MESSAGES/BY.po +++ b/holidays/locale/en_US/LC_MESSAGES/BY.po @@ -3,18 +3,28 @@ # msgid "" msgstr "" -"Project-Id-Version: Python Holidays 0.20\n" +"Project-Id-Version: Python Holidays 0.34\n" "POT-Creation-Date: 2023-02-15 20:06-0800\n" -"PO-Revision-Date: 2023-02-14 17:52-0800\n" -"Last-Translator: Arkadii Yakovets \n" +"PO-Revision-Date: 2023-09-27 18:50+0300\n" +"Last-Translator: ~Jhellico \n" "Language-Team: Python Holidays localization team\n" "Language: en_US\n" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" +"Plural-Forms: nplurals=2; plural=(n != 1);\n" "Generated-By: Lingua 4.15.0\n" "X-Generator: Poedit 3.2.2\n" +#. Date format (see strftime() Format Codes) +msgid "%d.%m.%Y" +msgstr "%m/%d/%Y" + +#. Day off (substituted from %s). +#, c-format +msgid "Выходны (перанесены з %s)" +msgstr "Day off (substituted from %s)" + #. New Year's Day. msgid "Новы год" msgstr "New Year's Day" diff --git a/snapshots/countries/BY.json b/snapshots/countries/BY.json index 8634a062d..8b3491216 100644 --- a/snapshots/countries/BY.json +++ b/snapshots/countries/BY.json @@ -1,7 +1,20 @@ { + "1998-01-01": "New Year's Day", + "1998-01-02": "Day off (substituted from 01/10/1998)", + "1998-01-07": "Orthodox Christmas Day", + "1998-03-08": "Women's Day", + "1998-04-27": "Day off (substituted from 04/25/1998)", + "1998-04-28": "Radunitsa", + "1998-05-01": "Labor Day", + "1998-05-09": "Victory Day", + "1998-07-03": "Independence Day (Republic Day)", + "1998-11-07": "October Revolution Day", + "1998-12-25": "Catholic Christmas Day", "1999-01-01": "New Year's Day", "1999-01-07": "Orthodox Christmas Day", + "1999-01-08": "Day off (substituted from 01/16/1999)", "1999-03-08": "Women's Day", + "1999-04-19": "Day off (substituted from 04/17/1999)", "1999-04-20": "Radunitsa", "1999-05-01": "Labor Day", "1999-05-09": "Victory Day", @@ -12,40 +25,58 @@ "2000-01-07": "Orthodox Christmas Day", "2000-03-08": "Women's Day", "2000-05-01": "Labor Day", + "2000-05-08": "Day off (substituted from 05/13/2000)", "2000-05-09": "Radunitsa; Victory Day", "2000-07-03": "Independence Day (Republic Day)", + "2000-11-06": "Day off (substituted from 11/11/2000)", "2000-11-07": "October Revolution Day", "2000-12-25": "Catholic Christmas Day", "2001-01-01": "New Year's Day", + "2001-01-02": "Day off (substituted from 01/20/2001)", "2001-01-07": "Orthodox Christmas Day", "2001-03-08": "Women's Day", + "2001-03-09": "Day off (substituted from 03/03/2001)", + "2001-04-23": "Day off (substituted from 04/21/2001)", "2001-04-24": "Radunitsa", + "2001-04-30": "Day off (substituted from 04/28/2001)", "2001-05-01": "Labor Day", "2001-05-09": "Victory Day", + "2001-07-02": "Day off (substituted from 07/07/2001)", "2001-07-03": "Independence Day (Republic Day)", "2001-11-07": "October Revolution Day", + "2001-12-24": "Day off (substituted from 12/22/2001)", "2001-12-25": "Catholic Christmas Day", + "2001-12-31": "Day off (substituted from 12/29/2001)", "2002-01-01": "New Year's Day", + "2002-01-02": "Day off (substituted from 01/05/2002)", "2002-01-07": "Orthodox Christmas Day", "2002-03-08": "Women's Day", "2002-05-01": "Labor Day", "2002-05-09": "Victory Day", + "2002-05-10": "Day off (substituted from 05/18/2002)", "2002-05-14": "Radunitsa", "2002-07-03": "Independence Day (Republic Day)", "2002-11-07": "October Revolution Day", + "2002-11-08": "Day off (substituted from 11/16/2002)", "2002-12-25": "Catholic Christmas Day", "2003-01-01": "New Year's Day", + "2003-01-06": "Day off (substituted from 01/04/2003)", "2003-01-07": "Orthodox Christmas Day", "2003-03-08": "Women's Day", "2003-05-01": "Labor Day", + "2003-05-05": "Day off (substituted from 05/03/2003)", "2003-05-06": "Radunitsa", "2003-05-09": "Victory Day", "2003-07-03": "Independence Day (Republic Day)", "2003-11-07": "October Revolution Day", "2003-12-25": "Catholic Christmas Day", "2004-01-01": "New Year's Day", + "2004-01-02": "Day off (substituted from 01/10/2004)", + "2004-01-05": "Day off (substituted from 01/17/2004)", + "2004-01-06": "Day off (substituted from 01/31/2004)", "2004-01-07": "Orthodox Christmas Day", "2004-03-08": "Women's Day", + "2004-04-19": "Day off (substituted from 04/17/2004)", "2004-04-20": "Radunitsa", "2004-05-01": "Labor Day", "2004-05-09": "Victory Day", @@ -54,6 +85,7 @@ "2004-12-25": "Catholic Christmas Day", "2005-01-01": "New Year's Day", "2005-01-07": "Orthodox Christmas Day", + "2005-03-07": "Day off (substituted from 03/12/2005)", "2005-03-08": "Women's Day", "2005-05-01": "Labor Day", "2005-05-09": "Victory Day", @@ -62,35 +94,51 @@ "2005-11-07": "October Revolution Day", "2005-12-25": "Catholic Christmas Day", "2006-01-01": "New Year's Day", + "2006-01-02": "Day off (substituted from 01/21/2006)", "2006-01-07": "Orthodox Christmas Day", "2006-03-08": "Women's Day", "2006-05-01": "Labor Day", "2006-05-02": "Radunitsa", + "2006-05-08": "Day off (substituted from 05/06/2006)", "2006-05-09": "Victory Day", "2006-07-03": "Independence Day (Republic Day)", + "2006-11-06": "Day off (substituted from 11/04/2006)", "2006-11-07": "October Revolution Day", "2006-12-25": "Catholic Christmas Day", "2007-01-01": "New Year's Day", + "2007-01-02": "Day off (substituted from 12/30/2006)", "2007-01-07": "Orthodox Christmas Day", "2007-03-08": "Women's Day", + "2007-03-09": "Day off (substituted from 03/17/2007)", + "2007-04-16": "Day off (substituted from 04/14/2007)", "2007-04-17": "Radunitsa", + "2007-04-30": "Day off (substituted from 05/05/2007)", "2007-05-01": "Labor Day", "2007-05-09": "Victory Day", + "2007-07-02": "Day off (substituted from 07/07/2007)", "2007-07-03": "Independence Day (Republic Day)", "2007-11-07": "October Revolution Day", + "2007-12-24": "Day off (substituted from 12/22/2007)", "2007-12-25": "Catholic Christmas Day", + "2007-12-31": "Day off (substituted from 12/29/2007)", "2008-01-01": "New Year's Day", + "2008-01-02": "Day off (substituted from 01/12/2008)", "2008-01-07": "Orthodox Christmas Day", "2008-03-08": "Women's Day", "2008-05-01": "Labor Day", + "2008-05-05": "Day off (substituted from 05/03/2008)", "2008-05-06": "Radunitsa", "2008-05-09": "Victory Day", "2008-07-03": "Independence Day (Republic Day)", + "2008-07-04": "Day off (substituted from 06/28/2008)", "2008-11-07": "October Revolution Day", "2008-12-25": "Catholic Christmas Day", + "2008-12-26": "Day off (substituted from 12/20/2008)", "2009-01-01": "New Year's Day", + "2009-01-02": "Day off (substituted from 01/10/2009)", "2009-01-07": "Orthodox Christmas Day", "2009-03-08": "Women's Day", + "2009-04-27": "Day off (substituted from 04/25/2009)", "2009-04-28": "Radunitsa", "2009-05-01": "Labor Day", "2009-05-09": "Victory Day", @@ -99,17 +147,22 @@ "2009-12-25": "Catholic Christmas Day", "2010-01-01": "New Year's Day", "2010-01-07": "Orthodox Christmas Day", + "2010-01-08": "Day off (substituted from 01/23/2010)", "2010-03-08": "Women's Day", + "2010-04-12": "Day off (substituted from 04/17/2010)", "2010-04-13": "Radunitsa", "2010-05-01": "Labor Day", "2010-05-09": "Victory Day", + "2010-05-10": "Day off (substituted from 05/15/2010)", "2010-07-03": "Independence Day (Republic Day)", "2010-11-07": "October Revolution Day", "2010-12-25": "Catholic Christmas Day", "2011-01-01": "New Year's Day", "2011-01-07": "Orthodox Christmas Day", + "2011-03-07": "Day off (substituted from 03/12/2011)", "2011-03-08": "Women's Day", "2011-05-01": "Labor Day", + "2011-05-02": "Day off (substituted from 05/14/2011)", "2011-05-03": "Radunitsa", "2011-05-09": "Victory Day", "2011-07-03": "Independence Day (Republic Day)", @@ -118,33 +171,47 @@ "2012-01-01": "New Year's Day", "2012-01-07": "Orthodox Christmas Day", "2012-03-08": "Women's Day", + "2012-03-09": "Day off (substituted from 03/11/2012)", + "2012-04-23": "Day off (substituted from 04/28/2012)", "2012-04-24": "Radunitsa", "2012-05-01": "Labor Day", "2012-05-09": "Victory Day", + "2012-07-02": "Day off (substituted from 06/30/2012)", "2012-07-03": "Independence Day (Republic Day)", "2012-11-07": "October Revolution Day", + "2012-12-24": "Day off (substituted from 12/22/2012)", "2012-12-25": "Catholic Christmas Day", + "2012-12-31": "Day off (substituted from 12/29/2012)", "2013-01-01": "New Year's Day", + "2013-01-02": "Day off (substituted from 01/05/2013)", "2013-01-07": "Orthodox Christmas Day", "2013-03-08": "Women's Day", "2013-05-01": "Labor Day", "2013-05-09": "Victory Day", + "2013-05-10": "Day off (substituted from 05/18/2013)", "2013-05-14": "Radunitsa", "2013-07-03": "Independence Day (Republic Day)", "2013-11-07": "October Revolution Day", "2013-12-25": "Catholic Christmas Day", "2014-01-01": "New Year's Day", + "2014-01-02": "Day off (substituted from 01/04/2014)", + "2014-01-06": "Day off (substituted from 01/11/2014)", "2014-01-07": "Orthodox Christmas Day", "2014-03-08": "Women's Day", "2014-04-29": "Radunitsa", + "2014-04-30": "Day off (substituted from 05/03/2014)", "2014-05-01": "Labor Day", "2014-05-09": "Victory Day", "2014-07-03": "Independence Day (Republic Day)", + "2014-07-04": "Day off (substituted from 07/12/2014)", "2014-11-07": "October Revolution Day", "2014-12-25": "Catholic Christmas Day", + "2014-12-26": "Day off (substituted from 12/20/2014)", "2015-01-01": "New Year's Day", + "2015-01-02": "Day off (substituted from 01/10/2015)", "2015-01-07": "Orthodox Christmas Day", "2015-03-08": "Women's Day", + "2015-04-20": "Day off (substituted from 04/25/2015)", "2015-04-21": "Radunitsa", "2015-05-01": "Labor Day", "2015-05-09": "Victory Day", @@ -153,6 +220,8 @@ "2015-12-25": "Catholic Christmas Day", "2016-01-01": "New Year's Day", "2016-01-07": "Orthodox Christmas Day", + "2016-01-08": "Day off (substituted from 01/16/2016)", + "2016-03-07": "Day off (substituted from 03/05/2016)", "2016-03-08": "Women's Day", "2016-05-01": "Labor Day", "2016-05-09": "Victory Day", @@ -161,36 +230,52 @@ "2016-11-07": "October Revolution Day", "2016-12-25": "Catholic Christmas Day", "2017-01-01": "New Year's Day", + "2017-01-02": "Day off (substituted from 01/21/2017)", "2017-01-07": "Orthodox Christmas Day", "2017-03-08": "Women's Day", + "2017-04-24": "Day off (substituted from 04/29/2017)", "2017-04-25": "Radunitsa", "2017-05-01": "Labor Day", + "2017-05-08": "Day off (substituted from 05/06/2017)", "2017-05-09": "Victory Day", "2017-07-03": "Independence Day (Republic Day)", + "2017-11-06": "Day off (substituted from 11/04/2017)", "2017-11-07": "October Revolution Day", "2017-12-25": "Catholic Christmas Day", "2018-01-01": "New Year's Day", + "2018-01-02": "Day off (substituted from 01/20/2018)", "2018-01-07": "Orthodox Christmas Day", "2018-03-08": "Women's Day", + "2018-03-09": "Day off (substituted from 03/03/2018)", + "2018-04-16": "Day off (substituted from 04/14/2018)", "2018-04-17": "Radunitsa", + "2018-04-30": "Day off (substituted from 04/28/2018)", "2018-05-01": "Labor Day", "2018-05-09": "Victory Day", + "2018-07-02": "Day off (substituted from 07/07/2018)", "2018-07-03": "Independence Day (Republic Day)", "2018-11-07": "October Revolution Day", + "2018-12-24": "Day off (substituted from 12/22/2018)", "2018-12-25": "Catholic Christmas Day", + "2018-12-31": "Day off (substituted from 12/29/2018)", "2019-01-01": "New Year's Day", "2019-01-07": "Orthodox Christmas Day", "2019-03-08": "Women's Day", "2019-05-01": "Labor Day", + "2019-05-06": "Day off (substituted from 05/04/2019)", "2019-05-07": "Radunitsa", + "2019-05-08": "Day off (substituted from 05/11/2019)", "2019-05-09": "Victory Day", "2019-07-03": "Independence Day (Republic Day)", "2019-11-07": "October Revolution Day", + "2019-11-08": "Day off (substituted from 11/16/2019)", "2019-12-25": "Catholic Christmas Day", "2020-01-01": "New Year's Day", "2020-01-02": "New Year's Day", + "2020-01-06": "Day off (substituted from 01/04/2020)", "2020-01-07": "Orthodox Christmas Day", "2020-03-08": "Women's Day", + "2020-04-27": "Day off (substituted from 04/04/2020)", "2020-04-28": "Radunitsa", "2020-05-01": "Labor Day", "2020-05-09": "Victory Day", @@ -200,9 +285,11 @@ "2021-01-01": "New Year's Day", "2021-01-02": "New Year's Day", "2021-01-07": "Orthodox Christmas Day", + "2021-01-08": "Day off (substituted from 01/16/2021)", "2021-03-08": "Women's Day", "2021-05-01": "Labor Day", "2021-05-09": "Victory Day", + "2021-05-10": "Day off (substituted from 05/15/2021)", "2021-05-11": "Radunitsa", "2021-07-03": "Independence Day (Republic Day)", "2021-11-07": "October Revolution Day", @@ -210,8 +297,10 @@ "2022-01-01": "New Year's Day", "2022-01-02": "New Year's Day", "2022-01-07": "Orthodox Christmas Day", + "2022-03-07": "Day off (substituted from 03/12/2022)", "2022-03-08": "Women's Day", "2022-05-01": "Labor Day", + "2022-05-02": "Day off (substituted from 05/14/2022)", "2022-05-03": "Radunitsa", "2022-05-09": "Victory Day", "2022-07-03": "Independence Day (Republic Day)", @@ -221,10 +310,13 @@ "2023-01-02": "New Year's Day", "2023-01-07": "Orthodox Christmas Day", "2023-03-08": "Women's Day", + "2023-04-24": "Day off (substituted from 04/29/2023)", "2023-04-25": "Radunitsa", "2023-05-01": "Labor Day", + "2023-05-08": "Day off (substituted from 05/13/2023)", "2023-05-09": "Victory Day", "2023-07-03": "Independence Day (Republic Day)", + "2023-11-06": "Day off (substituted from 11/11/2023)", "2023-11-07": "October Revolution Day", "2023-12-25": "Catholic Christmas Day", "2024-01-01": "New Year's Day", diff --git a/tests/countries/test_belarus.py b/tests/countries/test_belarus.py index eac61e880..811750aec 100644 --- a/tests/countries/test_belarus.py +++ b/tests/countries/test_belarus.py @@ -21,6 +21,9 @@ def setUpClass(cls): def test_country_aliases(self): self.assertCountryAliases(Belarus, BY, BLR) + def test_no_holidays(self): + self.assertNoHolidays(Belarus(years=1997)) + def test_2018(self): # http://calendar.by/procal.php?year=2018 # https://www.officeholidays.com/countries/belarus/index.php @@ -71,22 +74,105 @@ def test_radunitsa(self): "2030-05-07", ) - def test_pre_1998(self): - self.assertNoHoliday("1997-07-03") + def test_substituted(self): + self.assertHoliday( + "1998-01-02", + "1998-04-27", + "1999-01-08", + "1999-04-19", + "2000-05-08", + "2000-11-06", + "2001-01-02", + "2001-03-09", + "2001-04-23", + "2001-04-30", + "2001-07-02", + "2001-12-24", + "2001-12-31", + "2002-01-02", + "2002-05-10", + "2002-11-08", + "2003-01-06", + "2003-05-05", + "2004-01-02", + "2004-01-05", + "2004-01-06", + "2004-04-19", + "2005-03-07", + "2006-01-02", + "2006-05-08", + "2006-11-06", + "2007-01-02", + "2007-03-09", + "2007-04-16", + "2007-04-30", + "2007-07-02", + "2007-12-24", + "2007-12-31", + "2008-01-02", + "2008-05-05", + "2008-07-04", + "2008-12-26", + "2009-01-02", + "2009-04-27", + "2010-01-08", + "2010-04-12", + "2010-05-10", + "2011-03-07", + "2011-05-02", + "2012-03-09", + "2012-04-23", + "2012-07-02", + "2012-12-24", + "2012-12-31", + "2013-01-02", + "2013-05-10", + "2014-01-02", + "2014-01-06", + "2014-04-30", + "2014-07-04", + "2014-12-26", + "2015-01-02", + "2015-04-20", + "2016-01-08", + "2016-03-07", + "2017-01-02", + "2017-04-24", + "2017-05-08", + "2017-11-06", + "2018-01-02", + "2018-03-09", + "2018-04-16", + "2018-04-30", + "2018-07-02", + "2018-12-24", + "2018-12-31", + "2019-05-06", + "2019-05-08", + "2019-11-08", + "2020-01-06", + "2020-04-27", + "2021-01-08", + "2021-05-10", + "2022-03-07", + "2022-05-02", + "2023-04-24", + "2023-05-08", + "2023-11-06", + ) def test_l10n_default(self): self.assertLocalizedHolidays( ("2022-01-01", "Новы год"), ("2022-01-02", "Новы год"), ("2022-01-07", "Нараджэнне Хрыстова (праваслаўнае Раство)"), + ("2022-03-07", "Выходны (перанесены з 12.03.2022)"), ("2022-03-08", "Дзень жанчын"), ("2022-05-01", "Свята працы"), + ("2022-05-02", "Выходны (перанесены з 14.05.2022)"), ("2022-05-03", "Радаўніца"), ("2022-05-09", "Дзень Перамогі"), - ( - "2022-07-03", - "Дзень Незалежнасці Рэспублікі Беларусь (Дзень Рэспублікі)", - ), + ("2022-07-03", "Дзень Незалежнасці Рэспублікі Беларусь (Дзень Рэспублікі)"), ("2022-11-07", "Дзень Кастрычніцкай рэвалюцыі"), ("2022-12-25", "Нараджэнне Хрыстова (каталіцкае Раство)"), ) @@ -97,8 +183,10 @@ def test_l10n_en_us(self): ("2022-01-01", "New Year's Day"), ("2022-01-02", "New Year's Day"), ("2022-01-07", "Orthodox Christmas Day"), + ("2022-03-07", "Day off (substituted from 03/12/2022)"), ("2022-03-08", "Women's Day"), ("2022-05-01", "Labor Day"), + ("2022-05-02", "Day off (substituted from 05/14/2022)"), ("2022-05-03", "Radunitsa"), ("2022-05-09", "Victory Day"), ("2022-07-03", "Independence Day (Republic Day)"),