diff --git a/README.rst b/README.rst index 3ba8704aa..fef3a6653 100644 --- a/README.rst +++ b/README.rst @@ -146,7 +146,7 @@ Available Countries .. _ISO 639-1 code: https://en.wikipedia.org/wiki/List_of_ISO_639-1_codes .. _ISO 639-2 code: https://en.wikipedia.org/wiki/List_of_ISO_639-2_codes -We currently support 153 country codes. The standard way to refer to a country +We currently support 154 country codes. The standard way to refer to a country is by using its `ISO 3166-1 alpha-2 code`_, the same used for domain names, and for a subdivision its `ISO 3166-2 code`_. Some countries have common or foreign names or abbreviations as aliases for their subdivisions. These are defined in @@ -345,6 +345,11 @@ All other default values are highlighted with bold: - - en_US, **es**, uk - + * - Congo + - CG + - + - en_US, **fr** + - * - Costa Rica - CR - diff --git a/holidays/countries/__init__.py b/holidays/countries/__init__.py index a88651ad8..45d8d335a 100644 --- a/holidays/countries/__init__.py +++ b/holidays/countries/__init__.py @@ -45,6 +45,7 @@ from .chile import Chile, CL, CHL from .china import China, CN, CHN from .colombia import Colombia, CO, COL +from .congo import Congo, CG, COG from .costa_rica import CostaRica, CR, CRI from .croatia import Croatia, HR, HRV from .cuba import Cuba, CU, CUB diff --git a/holidays/countries/congo.py b/holidays/countries/congo.py new file mode 100644 index 000000000..7604302e8 --- /dev/null +++ b/holidays/countries/congo.py @@ -0,0 +1,82 @@ +# holidays +# -------- +# A fast, efficient Python library for generating country, province and state +# specific sets of holidays on the fly. It aims to make determining whether a +# specific date is a holiday as fast and flexible as possible. +# +# Authors: Vacanza Team and individual contributors (see AUTHORS file) +# dr-prodigy (c) 2017-2023 +# ryanss (c) 2014-2017 +# Website: https://github.com/vacanza/python-holidays +# License: MIT (see LICENSE file) + +from gettext import gettext as tr + +from holidays.groups import ChristianHolidays, InternationalHolidays +from holidays.holiday_base import HolidayBase + + +class Congo(HolidayBase, ChristianHolidays, InternationalHolidays): + """ + References: + - Loi N° 2-94: + - http://mokili.free.fr/jours_feries.php + - Loi N° l8-20l0: + - https://www.finances.gouv.cg/sites/default/files/documents/n¯18-2010%20du%2027%20novembre%202010.PDF + + Cross-Checked With: + - https://en.wikipedia.org/wiki/Public_holidays_in_the_Republic_of_the_Congo + """ + + country = "CG" + default_language = "fr" + supported_languages = ("en_US", "fr") + + def __init__(self, *args, **kwargs) -> None: + ChristianHolidays.__init__(self) + InternationalHolidays.__init__(self) + super().__init__(*args, **kwargs) + + def _populate_public_holidays(self): + # Loi N° 2-94 of 1 March 1994 + if self._year <= 1993: + return None + + # New Year's Day. + self._add_new_years_day(tr("Jour de l'An")) + + # Easter Monday. + self._add_easter_monday(tr("Lundi de Pâques")) + + # Labor Day. + self._add_labor_day(tr("Fête du Travail")) + + # Ascension Day. + self._add_ascension_thursday(tr("Ascension")) + + # Whit Monday. + self._add_whit_monday(tr("Lundi de Pentecôte")) + + # Reconciliation Day. + self._add_holiday_jun_10(tr("Fête de la Réconciliation")) + + # National Day. + self._add_holiday_aug_15(tr("Fête Nationale")) + + # All Saints' Day. + self._add_all_saints_day(tr("Toussaint")) + + if self._year >= 2010: + # Republic Day. + self._add_holiday_nov_28(tr("Jour de la République")) + + # Christmas Day. + self._add_christmas_day(tr("Noël")) + + +class CG(Congo): + pass + + +class COG(Congo): + pass diff --git a/holidays/locale/en_US/LC_MESSAGES/CG.po b/holidays/locale/en_US/LC_MESSAGES/CG.po new file mode 100644 index 000000000..6eadbba5f --- /dev/null +++ b/holidays/locale/en_US/LC_MESSAGES/CG.po @@ -0,0 +1,67 @@ +# holidays +# -------- +# A fast, efficient Python library for generating country, province and state +# specific sets of holidays on the fly. It aims to make determining whether a +# specific date is a holiday as fast and flexible as possible. +# +# Authors: Vacanza Team and individual contributors (see AUTHORS file) +# dr-prodigy (c) 2017-2023 +# ryanss (c) 2014-2017 +# Website: https://github.com/vacanza/python-holidays +# License: MIT (see LICENSE file) +# +# Congo holidays en_US localization. +# +msgid "" +msgstr "" +"Project-Id-Version: Python Holidays 0.58\n" +"POT-Creation-Date: 2024-10-04 18:14+0700\n" +"PO-Revision-Date: 2024-10-04 18:17+0700\n" +"Last-Translator: PPsyrius \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" +"Generated-By: Lingva 5.0.3\n" +"X-Generator: Poedit 3.5\n" + +#. New Year's Day. +msgid "Jour de l'An" +msgstr "New Year's Day" + +#. Easter Monday. +msgid "Lundi de Pâques" +msgstr "Easter Monday" + +#. Labor Day. +msgid "Fête du Travail" +msgstr "Labor Day" + +#. Ascension Day. +msgid "Ascension" +msgstr "Ascension Day" + +#. Whit Monday. +msgid "Lundi de Pentecôte" +msgstr "Whit Monday" + +#. Reconciliation Day. +msgid "Fête de la Réconciliation" +msgstr "Reconciliation Day" + +#. National Day. +msgid "Fête Nationale" +msgstr "National Day" + +#. All Saints' Day. +msgid "Toussaint" +msgstr "All Saints' Day" + +#. Republic Day. +msgid "Jour de la République" +msgstr "Republic Day" + +#. Christmas Day. +msgid "Noël" +msgstr "Christmas Day" diff --git a/holidays/locale/fr/LC_MESSAGES/CG.po b/holidays/locale/fr/LC_MESSAGES/CG.po new file mode 100644 index 000000000..aaa5ec0d2 --- /dev/null +++ b/holidays/locale/fr/LC_MESSAGES/CG.po @@ -0,0 +1,67 @@ +# holidays +# -------- +# A fast, efficient Python library for generating country, province and state +# specific sets of holidays on the fly. It aims to make determining whether a +# specific date is a holiday as fast and flexible as possible. +# +# Authors: Vacanza Team and individual contributors (see AUTHORS file) +# dr-prodigy (c) 2017-2023 +# ryanss (c) 2014-2017 +# Website: https://github.com/vacanza/python-holidays +# License: MIT (see LICENSE file) +# +# Congo holidays. +# +msgid "" +msgstr "" +"Project-Id-Version: Python Holidays 0.58\n" +"POT-Creation-Date: 2024-10-04 18:14+0700\n" +"PO-Revision-Date: 2024-10-04 18:17+0700\n" +"Last-Translator: PPsyrius \n" +"Language-Team: Python Holidays Localization Team\n" +"Language: fr\n" +"MIME-Version: 1.0\n" +"Content-Type: text/plain; charset=UTF-8\n" +"Content-Transfer-Encoding: 8bit\n" +"Generated-By: Lingva 5.0.3\n" +"X-Generator: Poedit 3.5\n" + +#. New Year's Day. +msgid "Jour de l'An" +msgstr "" + +#. Easter Monday. +msgid "Lundi de Pâques" +msgstr "" + +#. Labor Day. +msgid "Fête du Travail" +msgstr "" + +#. Ascension Day. +msgid "Ascension" +msgstr "" + +#. Whit Monday. +msgid "Lundi de Pentecôte" +msgstr "" + +#. Reconciliation Day. +msgid "Fête de la Réconciliation" +msgstr "" + +#. National Day. +msgid "Fête Nationale" +msgstr "" + +#. All Saints' Day. +msgid "Toussaint" +msgstr "" + +#. Republic Day. +msgid "Jour de la République" +msgstr "" + +#. Christmas Day. +msgid "Noël" +msgstr "" diff --git a/holidays/registry.py b/holidays/registry.py index 25919d8e3..e23a712f7 100644 --- a/holidays/registry.py +++ b/holidays/registry.py @@ -52,6 +52,7 @@ "chile": ("Chile", "CL", "CHL"), "china": ("China", "CN", "CHN"), "colombia": ("Colombia", "CO", "COL"), + "congo": ("Congo", "CG", "COG"), "costa_rica": ("CostaRica", "CR", "CRI"), "croatia": ("Croatia", "HR", "HRV"), "cuba": ("Cuba", "CU", "CUB"), diff --git a/snapshots/countries/CG_COMMON.json b/snapshots/countries/CG_COMMON.json new file mode 100644 index 000000000..f8a00a67b --- /dev/null +++ b/snapshots/countries/CG_COMMON.json @@ -0,0 +1,552 @@ +{ + "1994-01-01": "New Year's Day", + "1994-04-04": "Easter Monday", + "1994-05-01": "Labor Day", + "1994-05-12": "Ascension Day", + "1994-05-23": "Whit Monday", + "1994-06-10": "Reconciliation Day", + "1994-08-15": "National Day", + "1994-11-01": "All Saints' Day", + "1994-12-25": "Christmas Day", + "1995-01-01": "New Year's Day", + "1995-04-17": "Easter Monday", + "1995-05-01": "Labor Day", + "1995-05-25": "Ascension Day", + "1995-06-05": "Whit Monday", + "1995-06-10": "Reconciliation Day", + "1995-08-15": "National Day", + "1995-11-01": "All Saints' Day", + "1995-12-25": "Christmas Day", + "1996-01-01": "New Year's Day", + "1996-04-08": "Easter Monday", + "1996-05-01": "Labor Day", + "1996-05-16": "Ascension Day", + "1996-05-27": "Whit Monday", + "1996-06-10": "Reconciliation Day", + "1996-08-15": "National Day", + "1996-11-01": "All Saints' Day", + "1996-12-25": "Christmas Day", + "1997-01-01": "New Year's Day", + "1997-03-31": "Easter Monday", + "1997-05-01": "Labor Day", + "1997-05-08": "Ascension Day", + "1997-05-19": "Whit Monday", + "1997-06-10": "Reconciliation Day", + "1997-08-15": "National Day", + "1997-11-01": "All Saints' Day", + "1997-12-25": "Christmas Day", + "1998-01-01": "New Year's Day", + "1998-04-13": "Easter Monday", + "1998-05-01": "Labor Day", + "1998-05-21": "Ascension Day", + "1998-06-01": "Whit Monday", + "1998-06-10": "Reconciliation Day", + "1998-08-15": "National Day", + "1998-11-01": "All Saints' Day", + "1998-12-25": "Christmas Day", + "1999-01-01": "New Year's Day", + "1999-04-05": "Easter Monday", + "1999-05-01": "Labor Day", + "1999-05-13": "Ascension Day", + "1999-05-24": "Whit Monday", + "1999-06-10": "Reconciliation Day", + "1999-08-15": "National Day", + "1999-11-01": "All Saints' Day", + "1999-12-25": "Christmas Day", + "2000-01-01": "New Year's Day", + "2000-04-24": "Easter Monday", + "2000-05-01": "Labor Day", + "2000-06-01": "Ascension Day", + "2000-06-10": "Reconciliation Day", + "2000-06-12": "Whit Monday", + "2000-08-15": "National Day", + "2000-11-01": "All Saints' Day", + "2000-12-25": "Christmas Day", + "2001-01-01": "New Year's Day", + "2001-04-16": "Easter Monday", + "2001-05-01": "Labor Day", + "2001-05-24": "Ascension Day", + "2001-06-04": "Whit Monday", + "2001-06-10": "Reconciliation Day", + "2001-08-15": "National Day", + "2001-11-01": "All Saints' Day", + "2001-12-25": "Christmas Day", + "2002-01-01": "New Year's Day", + "2002-04-01": "Easter Monday", + "2002-05-01": "Labor Day", + "2002-05-09": "Ascension Day", + "2002-05-20": "Whit Monday", + "2002-06-10": "Reconciliation Day", + "2002-08-15": "National Day", + "2002-11-01": "All Saints' Day", + "2002-12-25": "Christmas Day", + "2003-01-01": "New Year's Day", + "2003-04-21": "Easter Monday", + "2003-05-01": "Labor Day", + "2003-05-29": "Ascension Day", + "2003-06-09": "Whit Monday", + "2003-06-10": "Reconciliation Day", + "2003-08-15": "National Day", + "2003-11-01": "All Saints' Day", + "2003-12-25": "Christmas Day", + "2004-01-01": "New Year's Day", + "2004-04-12": "Easter Monday", + "2004-05-01": "Labor Day", + "2004-05-20": "Ascension Day", + "2004-05-31": "Whit Monday", + "2004-06-10": "Reconciliation Day", + "2004-08-15": "National Day", + "2004-11-01": "All Saints' Day", + "2004-12-25": "Christmas Day", + "2005-01-01": "New Year's Day", + "2005-03-28": "Easter Monday", + "2005-05-01": "Labor Day", + "2005-05-05": "Ascension Day", + "2005-05-16": "Whit Monday", + "2005-06-10": "Reconciliation Day", + "2005-08-15": "National Day", + "2005-11-01": "All Saints' Day", + "2005-12-25": "Christmas Day", + "2006-01-01": "New Year's Day", + "2006-04-17": "Easter Monday", + "2006-05-01": "Labor Day", + "2006-05-25": "Ascension Day", + "2006-06-05": "Whit Monday", + "2006-06-10": "Reconciliation Day", + "2006-08-15": "National Day", + "2006-11-01": "All Saints' Day", + "2006-12-25": "Christmas Day", + "2007-01-01": "New Year's Day", + "2007-04-09": "Easter Monday", + "2007-05-01": "Labor Day", + "2007-05-17": "Ascension Day", + "2007-05-28": "Whit Monday", + "2007-06-10": "Reconciliation Day", + "2007-08-15": "National Day", + "2007-11-01": "All Saints' Day", + "2007-12-25": "Christmas Day", + "2008-01-01": "New Year's Day", + "2008-03-24": "Easter Monday", + "2008-05-01": "Ascension Day; Labor Day", + "2008-05-12": "Whit Monday", + "2008-06-10": "Reconciliation Day", + "2008-08-15": "National Day", + "2008-11-01": "All Saints' Day", + "2008-12-25": "Christmas Day", + "2009-01-01": "New Year's Day", + "2009-04-13": "Easter Monday", + "2009-05-01": "Labor Day", + "2009-05-21": "Ascension Day", + "2009-06-01": "Whit Monday", + "2009-06-10": "Reconciliation Day", + "2009-08-15": "National Day", + "2009-11-01": "All Saints' Day", + "2009-12-25": "Christmas Day", + "2010-01-01": "New Year's Day", + "2010-04-05": "Easter Monday", + "2010-05-01": "Labor Day", + "2010-05-13": "Ascension Day", + "2010-05-24": "Whit Monday", + "2010-06-10": "Reconciliation Day", + "2010-08-15": "National Day", + "2010-11-01": "All Saints' Day", + "2010-11-28": "Republic Day", + "2010-12-25": "Christmas Day", + "2011-01-01": "New Year's Day", + "2011-04-25": "Easter Monday", + "2011-05-01": "Labor Day", + "2011-06-02": "Ascension Day", + "2011-06-10": "Reconciliation Day", + "2011-06-13": "Whit Monday", + "2011-08-15": "National Day", + "2011-11-01": "All Saints' Day", + "2011-11-28": "Republic Day", + "2011-12-25": "Christmas Day", + "2012-01-01": "New Year's Day", + "2012-04-09": "Easter Monday", + "2012-05-01": "Labor Day", + "2012-05-17": "Ascension Day", + "2012-05-28": "Whit Monday", + "2012-06-10": "Reconciliation Day", + "2012-08-15": "National Day", + "2012-11-01": "All Saints' Day", + "2012-11-28": "Republic Day", + "2012-12-25": "Christmas Day", + "2013-01-01": "New Year's Day", + "2013-04-01": "Easter Monday", + "2013-05-01": "Labor Day", + "2013-05-09": "Ascension Day", + "2013-05-20": "Whit Monday", + "2013-06-10": "Reconciliation Day", + "2013-08-15": "National Day", + "2013-11-01": "All Saints' Day", + "2013-11-28": "Republic Day", + "2013-12-25": "Christmas Day", + "2014-01-01": "New Year's Day", + "2014-04-21": "Easter Monday", + "2014-05-01": "Labor Day", + "2014-05-29": "Ascension Day", + "2014-06-09": "Whit Monday", + "2014-06-10": "Reconciliation Day", + "2014-08-15": "National Day", + "2014-11-01": "All Saints' Day", + "2014-11-28": "Republic Day", + "2014-12-25": "Christmas Day", + "2015-01-01": "New Year's Day", + "2015-04-06": "Easter Monday", + "2015-05-01": "Labor Day", + "2015-05-14": "Ascension Day", + "2015-05-25": "Whit Monday", + "2015-06-10": "Reconciliation Day", + "2015-08-15": "National Day", + "2015-11-01": "All Saints' Day", + "2015-11-28": "Republic Day", + "2015-12-25": "Christmas Day", + "2016-01-01": "New Year's Day", + "2016-03-28": "Easter Monday", + "2016-05-01": "Labor Day", + "2016-05-05": "Ascension Day", + "2016-05-16": "Whit Monday", + "2016-06-10": "Reconciliation Day", + "2016-08-15": "National Day", + "2016-11-01": "All Saints' Day", + "2016-11-28": "Republic Day", + "2016-12-25": "Christmas Day", + "2017-01-01": "New Year's Day", + "2017-04-17": "Easter Monday", + "2017-05-01": "Labor Day", + "2017-05-25": "Ascension Day", + "2017-06-05": "Whit Monday", + "2017-06-10": "Reconciliation Day", + "2017-08-15": "National Day", + "2017-11-01": "All Saints' Day", + "2017-11-28": "Republic Day", + "2017-12-25": "Christmas Day", + "2018-01-01": "New Year's Day", + "2018-04-02": "Easter Monday", + "2018-05-01": "Labor Day", + "2018-05-10": "Ascension Day", + "2018-05-21": "Whit Monday", + "2018-06-10": "Reconciliation Day", + "2018-08-15": "National Day", + "2018-11-01": "All Saints' Day", + "2018-11-28": "Republic Day", + "2018-12-25": "Christmas Day", + "2019-01-01": "New Year's Day", + "2019-04-22": "Easter Monday", + "2019-05-01": "Labor Day", + "2019-05-30": "Ascension Day", + "2019-06-10": "Reconciliation Day; Whit Monday", + "2019-08-15": "National Day", + "2019-11-01": "All Saints' Day", + "2019-11-28": "Republic Day", + "2019-12-25": "Christmas Day", + "2020-01-01": "New Year's Day", + "2020-04-13": "Easter Monday", + "2020-05-01": "Labor Day", + "2020-05-21": "Ascension Day", + "2020-06-01": "Whit Monday", + "2020-06-10": "Reconciliation Day", + "2020-08-15": "National Day", + "2020-11-01": "All Saints' Day", + "2020-11-28": "Republic Day", + "2020-12-25": "Christmas Day", + "2021-01-01": "New Year's Day", + "2021-04-05": "Easter Monday", + "2021-05-01": "Labor Day", + "2021-05-13": "Ascension Day", + "2021-05-24": "Whit Monday", + "2021-06-10": "Reconciliation Day", + "2021-08-15": "National Day", + "2021-11-01": "All Saints' Day", + "2021-11-28": "Republic Day", + "2021-12-25": "Christmas Day", + "2022-01-01": "New Year's Day", + "2022-04-18": "Easter Monday", + "2022-05-01": "Labor Day", + "2022-05-26": "Ascension Day", + "2022-06-06": "Whit Monday", + "2022-06-10": "Reconciliation Day", + "2022-08-15": "National Day", + "2022-11-01": "All Saints' Day", + "2022-11-28": "Republic Day", + "2022-12-25": "Christmas Day", + "2023-01-01": "New Year's Day", + "2023-04-10": "Easter Monday", + "2023-05-01": "Labor Day", + "2023-05-18": "Ascension Day", + "2023-05-29": "Whit Monday", + "2023-06-10": "Reconciliation Day", + "2023-08-15": "National Day", + "2023-11-01": "All Saints' Day", + "2023-11-28": "Republic Day", + "2023-12-25": "Christmas Day", + "2024-01-01": "New Year's Day", + "2024-04-01": "Easter Monday", + "2024-05-01": "Labor Day", + "2024-05-09": "Ascension Day", + "2024-05-20": "Whit Monday", + "2024-06-10": "Reconciliation Day", + "2024-08-15": "National Day", + "2024-11-01": "All Saints' Day", + "2024-11-28": "Republic Day", + "2024-12-25": "Christmas Day", + "2025-01-01": "New Year's Day", + "2025-04-21": "Easter Monday", + "2025-05-01": "Labor Day", + "2025-05-29": "Ascension Day", + "2025-06-09": "Whit Monday", + "2025-06-10": "Reconciliation Day", + "2025-08-15": "National Day", + "2025-11-01": "All Saints' Day", + "2025-11-28": "Republic Day", + "2025-12-25": "Christmas Day", + "2026-01-01": "New Year's Day", + "2026-04-06": "Easter Monday", + "2026-05-01": "Labor Day", + "2026-05-14": "Ascension Day", + "2026-05-25": "Whit Monday", + "2026-06-10": "Reconciliation Day", + "2026-08-15": "National Day", + "2026-11-01": "All Saints' Day", + "2026-11-28": "Republic Day", + "2026-12-25": "Christmas Day", + "2027-01-01": "New Year's Day", + "2027-03-29": "Easter Monday", + "2027-05-01": "Labor Day", + "2027-05-06": "Ascension Day", + "2027-05-17": "Whit Monday", + "2027-06-10": "Reconciliation Day", + "2027-08-15": "National Day", + "2027-11-01": "All Saints' Day", + "2027-11-28": "Republic Day", + "2027-12-25": "Christmas Day", + "2028-01-01": "New Year's Day", + "2028-04-17": "Easter Monday", + "2028-05-01": "Labor Day", + "2028-05-25": "Ascension Day", + "2028-06-05": "Whit Monday", + "2028-06-10": "Reconciliation Day", + "2028-08-15": "National Day", + "2028-11-01": "All Saints' Day", + "2028-11-28": "Republic Day", + "2028-12-25": "Christmas Day", + "2029-01-01": "New Year's Day", + "2029-04-02": "Easter Monday", + "2029-05-01": "Labor Day", + "2029-05-10": "Ascension Day", + "2029-05-21": "Whit Monday", + "2029-06-10": "Reconciliation Day", + "2029-08-15": "National Day", + "2029-11-01": "All Saints' Day", + "2029-11-28": "Republic Day", + "2029-12-25": "Christmas Day", + "2030-01-01": "New Year's Day", + "2030-04-22": "Easter Monday", + "2030-05-01": "Labor Day", + "2030-05-30": "Ascension Day", + "2030-06-10": "Reconciliation Day; Whit Monday", + "2030-08-15": "National Day", + "2030-11-01": "All Saints' Day", + "2030-11-28": "Republic Day", + "2030-12-25": "Christmas Day", + "2031-01-01": "New Year's Day", + "2031-04-14": "Easter Monday", + "2031-05-01": "Labor Day", + "2031-05-22": "Ascension Day", + "2031-06-02": "Whit Monday", + "2031-06-10": "Reconciliation Day", + "2031-08-15": "National Day", + "2031-11-01": "All Saints' Day", + "2031-11-28": "Republic Day", + "2031-12-25": "Christmas Day", + "2032-01-01": "New Year's Day", + "2032-03-29": "Easter Monday", + "2032-05-01": "Labor Day", + "2032-05-06": "Ascension Day", + "2032-05-17": "Whit Monday", + "2032-06-10": "Reconciliation Day", + "2032-08-15": "National Day", + "2032-11-01": "All Saints' Day", + "2032-11-28": "Republic Day", + "2032-12-25": "Christmas Day", + "2033-01-01": "New Year's Day", + "2033-04-18": "Easter Monday", + "2033-05-01": "Labor Day", + "2033-05-26": "Ascension Day", + "2033-06-06": "Whit Monday", + "2033-06-10": "Reconciliation Day", + "2033-08-15": "National Day", + "2033-11-01": "All Saints' Day", + "2033-11-28": "Republic Day", + "2033-12-25": "Christmas Day", + "2034-01-01": "New Year's Day", + "2034-04-10": "Easter Monday", + "2034-05-01": "Labor Day", + "2034-05-18": "Ascension Day", + "2034-05-29": "Whit Monday", + "2034-06-10": "Reconciliation Day", + "2034-08-15": "National Day", + "2034-11-01": "All Saints' Day", + "2034-11-28": "Republic Day", + "2034-12-25": "Christmas Day", + "2035-01-01": "New Year's Day", + "2035-03-26": "Easter Monday", + "2035-05-01": "Labor Day", + "2035-05-03": "Ascension Day", + "2035-05-14": "Whit Monday", + "2035-06-10": "Reconciliation Day", + "2035-08-15": "National Day", + "2035-11-01": "All Saints' Day", + "2035-11-28": "Republic Day", + "2035-12-25": "Christmas Day", + "2036-01-01": "New Year's Day", + "2036-04-14": "Easter Monday", + "2036-05-01": "Labor Day", + "2036-05-22": "Ascension Day", + "2036-06-02": "Whit Monday", + "2036-06-10": "Reconciliation Day", + "2036-08-15": "National Day", + "2036-11-01": "All Saints' Day", + "2036-11-28": "Republic Day", + "2036-12-25": "Christmas Day", + "2037-01-01": "New Year's Day", + "2037-04-06": "Easter Monday", + "2037-05-01": "Labor Day", + "2037-05-14": "Ascension Day", + "2037-05-25": "Whit Monday", + "2037-06-10": "Reconciliation Day", + "2037-08-15": "National Day", + "2037-11-01": "All Saints' Day", + "2037-11-28": "Republic Day", + "2037-12-25": "Christmas Day", + "2038-01-01": "New Year's Day", + "2038-04-26": "Easter Monday", + "2038-05-01": "Labor Day", + "2038-06-03": "Ascension Day", + "2038-06-10": "Reconciliation Day", + "2038-06-14": "Whit Monday", + "2038-08-15": "National Day", + "2038-11-01": "All Saints' Day", + "2038-11-28": "Republic Day", + "2038-12-25": "Christmas Day", + "2039-01-01": "New Year's Day", + "2039-04-11": "Easter Monday", + "2039-05-01": "Labor Day", + "2039-05-19": "Ascension Day", + "2039-05-30": "Whit Monday", + "2039-06-10": "Reconciliation Day", + "2039-08-15": "National Day", + "2039-11-01": "All Saints' Day", + "2039-11-28": "Republic Day", + "2039-12-25": "Christmas Day", + "2040-01-01": "New Year's Day", + "2040-04-02": "Easter Monday", + "2040-05-01": "Labor Day", + "2040-05-10": "Ascension Day", + "2040-05-21": "Whit Monday", + "2040-06-10": "Reconciliation Day", + "2040-08-15": "National Day", + "2040-11-01": "All Saints' Day", + "2040-11-28": "Republic Day", + "2040-12-25": "Christmas Day", + "2041-01-01": "New Year's Day", + "2041-04-22": "Easter Monday", + "2041-05-01": "Labor Day", + "2041-05-30": "Ascension Day", + "2041-06-10": "Reconciliation Day; Whit Monday", + "2041-08-15": "National Day", + "2041-11-01": "All Saints' Day", + "2041-11-28": "Republic Day", + "2041-12-25": "Christmas Day", + "2042-01-01": "New Year's Day", + "2042-04-07": "Easter Monday", + "2042-05-01": "Labor Day", + "2042-05-15": "Ascension Day", + "2042-05-26": "Whit Monday", + "2042-06-10": "Reconciliation Day", + "2042-08-15": "National Day", + "2042-11-01": "All Saints' Day", + "2042-11-28": "Republic Day", + "2042-12-25": "Christmas Day", + "2043-01-01": "New Year's Day", + "2043-03-30": "Easter Monday", + "2043-05-01": "Labor Day", + "2043-05-07": "Ascension Day", + "2043-05-18": "Whit Monday", + "2043-06-10": "Reconciliation Day", + "2043-08-15": "National Day", + "2043-11-01": "All Saints' Day", + "2043-11-28": "Republic Day", + "2043-12-25": "Christmas Day", + "2044-01-01": "New Year's Day", + "2044-04-18": "Easter Monday", + "2044-05-01": "Labor Day", + "2044-05-26": "Ascension Day", + "2044-06-06": "Whit Monday", + "2044-06-10": "Reconciliation Day", + "2044-08-15": "National Day", + "2044-11-01": "All Saints' Day", + "2044-11-28": "Republic Day", + "2044-12-25": "Christmas Day", + "2045-01-01": "New Year's Day", + "2045-04-10": "Easter Monday", + "2045-05-01": "Labor Day", + "2045-05-18": "Ascension Day", + "2045-05-29": "Whit Monday", + "2045-06-10": "Reconciliation Day", + "2045-08-15": "National Day", + "2045-11-01": "All Saints' Day", + "2045-11-28": "Republic Day", + "2045-12-25": "Christmas Day", + "2046-01-01": "New Year's Day", + "2046-03-26": "Easter Monday", + "2046-05-01": "Labor Day", + "2046-05-03": "Ascension Day", + "2046-05-14": "Whit Monday", + "2046-06-10": "Reconciliation Day", + "2046-08-15": "National Day", + "2046-11-01": "All Saints' Day", + "2046-11-28": "Republic Day", + "2046-12-25": "Christmas Day", + "2047-01-01": "New Year's Day", + "2047-04-15": "Easter Monday", + "2047-05-01": "Labor Day", + "2047-05-23": "Ascension Day", + "2047-06-03": "Whit Monday", + "2047-06-10": "Reconciliation Day", + "2047-08-15": "National Day", + "2047-11-01": "All Saints' Day", + "2047-11-28": "Republic Day", + "2047-12-25": "Christmas Day", + "2048-01-01": "New Year's Day", + "2048-04-06": "Easter Monday", + "2048-05-01": "Labor Day", + "2048-05-14": "Ascension Day", + "2048-05-25": "Whit Monday", + "2048-06-10": "Reconciliation Day", + "2048-08-15": "National Day", + "2048-11-01": "All Saints' Day", + "2048-11-28": "Republic Day", + "2048-12-25": "Christmas Day", + "2049-01-01": "New Year's Day", + "2049-04-19": "Easter Monday", + "2049-05-01": "Labor Day", + "2049-05-27": "Ascension Day", + "2049-06-07": "Whit Monday", + "2049-06-10": "Reconciliation Day", + "2049-08-15": "National Day", + "2049-11-01": "All Saints' Day", + "2049-11-28": "Republic Day", + "2049-12-25": "Christmas Day", + "2050-01-01": "New Year's Day", + "2050-04-11": "Easter Monday", + "2050-05-01": "Labor Day", + "2050-05-19": "Ascension Day", + "2050-05-30": "Whit Monday", + "2050-06-10": "Reconciliation Day", + "2050-08-15": "National Day", + "2050-11-01": "All Saints' Day", + "2050-11-28": "Republic Day", + "2050-12-25": "Christmas Day" +} diff --git a/tests/countries/test_congo.py b/tests/countries/test_congo.py new file mode 100644 index 000000000..2c8dd165e --- /dev/null +++ b/tests/countries/test_congo.py @@ -0,0 +1,143 @@ +# holidays +# -------- +# A fast, efficient Python library for generating country, province and state +# specific sets of holidays on the fly. It aims to make determining whether a +# specific date is a holiday as fast and flexible as possible. +# +# Authors: Vacanza Team and individual contributors (see AUTHORS file) +# dr-prodigy (c) 2017-2023 +# ryanss (c) 2014-2017 +# Website: https://github.com/vacanza/python-holidays +# License: MIT (see LICENSE file) + +from unittest import TestCase + +from holidays.countries.congo import Congo, CG, COG +from tests.common import CommonCountryTests + + +class TestCongo(CommonCountryTests, TestCase): + @classmethod + def setUpClass(cls): + super().setUpClass(Congo) + + def test_country_aliases(self): + self.assertAliases(Congo, CG, COG) + + def test_no_holidays(self): + self.assertNoHolidays(Congo(years=1993)) + + def test_republic_day(self): + self.assertHoliday( + "2010-11-28", + "2015-11-28", + "2016-11-28", + "2017-11-28", + "2024-11-28", + ) + self.assertNoHolidayName("Jour de la République", 2009) + + def test_2006(self): + # http://mokili.free.fr/jours_feries.php + self.assertHolidays( + ("2006-01-01", "Jour de l'An"), + ("2006-04-17", "Lundi de Pâques"), + ("2006-05-01", "Fête du Travail"), + ("2006-05-25", "Ascension"), + ("2006-06-05", "Lundi de Pentecôte"), + ("2006-06-10", "Fête de la Réconciliation"), + ("2006-08-15", "Fête Nationale"), + ("2006-11-01", "Toussaint"), + ("2006-12-25", "Noël"), + ) + + def test_2010(self): + # http://mokili.free.fr/jours_feries.php + self.assertHolidays( + ("2010-01-01", "Jour de l'An"), + ("2010-04-05", "Lundi de Pâques"), + ("2010-05-01", "Fête du Travail"), + ("2010-05-13", "Ascension"), + ("2010-05-24", "Lundi de Pentecôte"), + ("2010-06-10", "Fête de la Réconciliation"), + ("2010-08-15", "Fête Nationale"), + ("2010-11-01", "Toussaint"), + ("2010-11-28", "Jour de la République"), + ("2010-12-25", "Noël"), + ) + + def test_2015(self): + # http://mokili.free.fr/jours_feries.php + self.assertHolidays( + ("2015-01-01", "Jour de l'An"), + ("2015-04-06", "Lundi de Pâques"), + ("2015-05-01", "Fête du Travail"), + ("2015-05-14", "Ascension"), + ("2015-05-25", "Lundi de Pentecôte"), + ("2015-06-10", "Fête de la Réconciliation"), + ("2015-08-15", "Fête Nationale"), + ("2015-11-01", "Toussaint"), + ("2015-11-28", "Jour de la République"), + ("2015-12-25", "Noël"), + ) + + def test_2016(self): + # http://mokili.free.fr/jours_feries.php + self.assertHolidays( + ("2016-01-01", "Jour de l'An"), + ("2016-03-28", "Lundi de Pâques"), + ("2016-05-01", "Fête du Travail"), + ("2016-05-05", "Ascension"), + ("2016-05-16", "Lundi de Pentecôte"), + ("2016-06-10", "Fête de la Réconciliation"), + ("2016-08-15", "Fête Nationale"), + ("2016-11-01", "Toussaint"), + ("2016-11-28", "Jour de la République"), + ("2016-12-25", "Noël"), + ) + + def test_2017(self): + # http://mokili.free.fr/jours_feries.php + self.assertHolidays( + ("2017-01-01", "Jour de l'An"), + ("2017-04-17", "Lundi de Pâques"), + ("2017-05-01", "Fête du Travail"), + ("2017-05-25", "Ascension"), + ("2017-06-05", "Lundi de Pentecôte"), + ("2017-06-10", "Fête de la Réconciliation"), + ("2017-08-15", "Fête Nationale"), + ("2017-11-01", "Toussaint"), + ("2017-11-28", "Jour de la République"), + ("2017-12-25", "Noël"), + ) + + def test_l10n_default(self): + # http://mokili.free.fr/jours_feries.php + self.assertLocalizedHolidays( + ("2024-01-01", "Jour de l'An"), + ("2024-04-01", "Lundi de Pâques"), + ("2024-05-01", "Fête du Travail"), + ("2024-05-09", "Ascension"), + ("2024-05-20", "Lundi de Pentecôte"), + ("2024-06-10", "Fête de la Réconciliation"), + ("2024-08-15", "Fête Nationale"), + ("2024-11-01", "Toussaint"), + ("2024-11-28", "Jour de la République"), + ("2024-12-25", "Noël"), + ) + + def test_l10n_en_us(self): + # http://mokili.free.fr/jours_feries.php + self.assertLocalizedHolidays( + "en_US", + ("2024-01-01", "New Year's Day"), + ("2024-04-01", "Easter Monday"), + ("2024-05-01", "Labor Day"), + ("2024-05-09", "Ascension Day"), + ("2024-05-20", "Whit Monday"), + ("2024-06-10", "Reconciliation Day"), + ("2024-08-15", "National Day"), + ("2024-11-01", "All Saints' Day"), + ("2024-11-28", "Republic Day"), + ("2024-12-25", "Christmas Day"), + )