diff --git a/holidays/countries/cambodia.py b/holidays/countries/cambodia.py index a74e1a8f6..365d5c452 100644 --- a/holidays/countries/cambodia.py +++ b/holidays/countries/cambodia.py @@ -12,7 +12,7 @@ from gettext import gettext as tr -from holidays.calendars.gregorian import MAY, AUG, SEP, _timedelta +from holidays.calendars.gregorian import APR, MAY, AUG, SEP, _timedelta from holidays.calendars.thai import KHMER_CALENDAR from holidays.groups import InternationalHolidays, StaticHolidays, ThaiCalendarHolidays from holidays.holiday_base import HolidayBase @@ -86,12 +86,25 @@ def _populate_public_holidays(self): # ពិធីបុណ្យចូលឆ្នាំថ្មីប្រពៃណីជាតិ # Status: In-Use. - # Usually falls on April 13th except for 2017-2018 and 2021-2023 for years 2001-2050. + # Usually falls on April 13th except for 2017-2018, 2021-2023, 2025-2027, 2029-2031 + # for years 2001-2050. if self._year != 2020: # Khmer New Year's Day sangkranta = tr("ពិធីបុណ្យចូលឆ្នាំថ្មីប្រពៃណីជាតិ") - sangkranta_years_apr_14 = {2017, 2018, 2021, 2022, 2023} + sangkranta_years_apr_14 = { + 2017, + 2018, + 2021, + 2022, + 2023, + 2025, + 2026, + 2027, + 2029, + 2030, + 2031, + } dt = ( self._add_holiday_apr_14(sangkranta) if self._year in sangkranta_years_apr_14 @@ -284,6 +297,9 @@ class CambodiaStaticHolidays: # Special Public Holiday special_in_lieu_holidays = tr("ថ្ងៃឈប់សម្រាកសងជំនួស") + # Khmer New Year's Day + sangkranta = tr("ពិធីបុណ្យចូលឆ្នាំថ្មីប្រពៃណីជាតិ") + special_public_holidays = { 2016: ( (MAY, 2, special_in_lieu_holidays), @@ -299,4 +315,5 @@ class CambodiaStaticHolidays: (AUG, 20, sangkranta_in_lieu_covid), (AUG, 21, sangkranta_in_lieu_covid), ), + 2024: (APR, 16, sangkranta), } diff --git a/snapshots/countries/KH_COMMON.json b/snapshots/countries/KH_COMMON.json index f01fb02e1..ddf1f0c49 100644 --- a/snapshots/countries/KH_COMMON.json +++ b/snapshots/countries/KH_COMMON.json @@ -724,6 +724,7 @@ "2024-04-13": "Khmer New Year's Day", "2024-04-14": "Khmer New Year's Day", "2024-04-15": "Khmer New Year's Day", + "2024-04-16": "Khmer New Year's Day", "2024-05-01": "International Labor Day", "2024-05-14": "HM King Norodom Sihamoni's Birthday", "2024-05-22": "Visaka Bochea Day", @@ -742,9 +743,9 @@ "2025-01-01": "International New Year Day", "2025-01-07": "Day of Victory over the Genocidal Regime", "2025-03-08": "International Women's Rights Day", - "2025-04-13": "Khmer New Year's Day", "2025-04-14": "Khmer New Year's Day", "2025-04-15": "Khmer New Year's Day", + "2025-04-16": "Khmer New Year's Day", "2025-05-01": "International Labor Day", "2025-05-11": "Visaka Bochea Day", "2025-05-14": "HM King Norodom Sihamoni's Birthday", @@ -763,9 +764,9 @@ "2026-01-01": "International New Year Day", "2026-01-07": "Day of Victory over the Genocidal Regime", "2026-03-08": "International Women's Rights Day", - "2026-04-13": "Khmer New Year's Day", "2026-04-14": "Khmer New Year's Day", "2026-04-15": "Khmer New Year's Day", + "2026-04-16": "Khmer New Year's Day", "2026-05-01": "International Labor Day; Visaka Bochea Day", "2026-05-05": "Royal Ploughing Ceremony", "2026-05-14": "HM King Norodom Sihamoni's Birthday", @@ -783,9 +784,9 @@ "2027-01-01": "International New Year Day", "2027-01-07": "Day of Victory over the Genocidal Regime", "2027-03-08": "International Women's Rights Day", - "2027-04-13": "Khmer New Year's Day", "2027-04-14": "Khmer New Year's Day", "2027-04-15": "Khmer New Year's Day", + "2027-04-16": "Khmer New Year's Day", "2027-05-01": "International Labor Day", "2027-05-14": "HM King Norodom Sihamoni's Birthday", "2027-05-20": "Visaka Bochea Day", @@ -825,9 +826,9 @@ "2029-01-01": "International New Year Day", "2029-01-07": "Day of Victory over the Genocidal Regime", "2029-03-08": "International Women's Rights Day", - "2029-04-13": "Khmer New Year's Day", "2029-04-14": "Khmer New Year's Day", "2029-04-15": "Khmer New Year's Day", + "2029-04-16": "Khmer New Year's Day", "2029-04-27": "Visaka Bochea Day", "2029-05-01": "International Labor Day; Royal Ploughing Ceremony", "2029-05-14": "HM King Norodom Sihamoni's Birthday", @@ -845,9 +846,9 @@ "2030-01-01": "International New Year Day", "2030-01-07": "Day of Victory over the Genocidal Regime", "2030-03-08": "International Women's Rights Day", - "2030-04-13": "Khmer New Year's Day", "2030-04-14": "Khmer New Year's Day", "2030-04-15": "Khmer New Year's Day", + "2030-04-16": "Khmer New Year's Day", "2030-05-01": "International Labor Day", "2030-05-14": "HM King Norodom Sihamoni's Birthday", "2030-05-16": "Visaka Bochea Day", @@ -865,9 +866,9 @@ "2031-01-01": "International New Year Day", "2031-01-07": "Day of Victory over the Genocidal Regime", "2031-03-08": "International Women's Rights Day", - "2031-04-13": "Khmer New Year's Day", "2031-04-14": "Khmer New Year's Day", "2031-04-15": "Khmer New Year's Day", + "2031-04-16": "Khmer New Year's Day", "2031-05-01": "International Labor Day", "2031-05-05": "Visaka Bochea Day", "2031-05-09": "Royal Ploughing Ceremony", diff --git a/tests/countries/test_cambodia.py b/tests/countries/test_cambodia.py index 70132f6fd..0910fc0a6 100644 --- a/tests/countries/test_cambodia.py +++ b/tests/countries/test_cambodia.py @@ -39,6 +39,7 @@ def test_special_holidays(self): "2020-08-19", "2020-08-20", "2020-08-21", + "2024-04-16", ) def test_2022(self): @@ -139,7 +140,19 @@ def test_day_of_victory_over_genocidal_regime(self): ) def test_sangkranta(self): - sangkranta_years_apr14 = {2017, 2018, 2021, 2022, 2023} + sangkranta_years_apr14 = { + 2017, + 2018, + 2021, + 2022, + 2023, + 2025, + 2026, + 2027, + 2029, + 2030, + 2031, + } for year in set(range(1993, 2058)).difference({2020}): if year in sangkranta_years_apr14: self.assertHoliday(f"{year}-04-14", f"{year}-04-15", f"{year}-04-16")