diff --git a/holidays/countries/thailand.py b/holidays/countries/thailand.py index 9ef2f7193..d14155c36 100644 --- a/holidays/countries/thailand.py +++ b/holidays/countries/thailand.py @@ -473,16 +473,20 @@ def _populate_public_holidays(self): # Got conferred with 'the Great' title in 2019 (B.E. 2562). if self._year >= 2017: - k_bhumibol_memorial = ( + if self._year >= 2023: + # HM King Bhumibol Adulyadej Memorial Day. + k_bhumibol_memorial = tr("วันนวมินทรมหาราช") + elif self._year >= 2019: # Anniversary for the Death of King Bhumibol Adulyadej the Great. - tr( + k_bhumibol_memorial = tr( "วันคล้ายวันสวรรคตพระบาทสมเด็จพระบรมชนกาธิเบศร " "มหาภูมิพลอดุลยเดชมหาราช บรมนาถบพิตร" ) - if self._year >= 2019 + else: # Anniversary for the Death of King Bhumibol Adulyadej. - else tr("วันคล้ายวันสวรรคตพระบาทสมเด็จพระปรมินทรมหาภูมิพลอดุลยเดช บรมนาถบพิตร") - ) + k_bhumibol_memorial = tr( + "วันคล้ายวันสวรรคตพระบาทสมเด็จพระปรมินทรมหาภูมิพลอดุลยเดช บรมนาถบพิตร" + ) self._add_observed(self._add_holiday_oct_13(k_bhumibol_memorial)) # วันปิยมหาราช @@ -501,26 +505,27 @@ def _populate_public_holidays(self): # Got conferred with 'the Great' title in 2019 (B.E. 2562). if self._year >= 1960: - k_bhumibol_bday = ( - # HM King Bhumibol Adulyadej's the Great's Birthday Anniversary. - tr( - "วันคล้ายวันเฉลิมพระชนมพรรษาพระบาทสมเด็จพระบรม" - "ชนกาธิเบศร มหาภูมิพลอดุลยเดชมหาราช บรมนาถบพิตร" + if self._year >= 2019: + k_bhumibol_bday = ( + # HM King Bhumibol Adulyadej's the Great's Birthday Anniversary. + tr( + "วันคล้ายวันเฉลิมพระชนมพรรษาพระบาทสมเด็จพระบรม" + "ชนกาธิเบศร มหาภูมิพลอดุลยเดชมหาราช บรมนาถบพิตร" + ) ) - if self._year >= 2019 - else ( + elif self._year >= 2016: + k_bhumibol_bday = ( # HM King Bhumibol Adulyadej Birthday Anniversary. tr( "วันคล้ายวันเฉลิมพระชนมพรรษา" "พระบาทสมเด็จพระปรมินทรมหาภูมิพลอดุลยเดช บรมนาถบพิตร" ) - if self._year >= 2016 + ) + else: + k_bhumibol_bday = ( # HM King Bhumibol Adulyadej Birthday Anniversary. - else tr( - "วันเฉลิมพระชนมพรรษาพระบาทสมเด็จพระปรมินทรมหาภูมิพลอดุลยเดช บรมนาถบพิตร" - ) + tr("วันเฉลิมพระชนมพรรษาพระบาทสมเด็จพระปรมินทรมหาภูมิพลอดุลยเดช บรมนาถบพิตร") ) - ) self._add_observed(self._add_holiday_dec_5(k_bhumibol_bday)) # วันพ่อแห่งชาติ @@ -784,8 +789,9 @@ def _populate_workday_holidays(self): # วันลอยกระทง # Status: In-Use. - # Loy Krathong - self._add_loy_krathong(tr("วันลอยกระทง")) + if self._year >= 1941: + # Loy Krathong + self._add_loy_krathong(tr("วันลอยกระทง")) class TH(Thailand): diff --git a/holidays/locale/en_US/LC_MESSAGES/TH.po b/holidays/locale/en_US/LC_MESSAGES/TH.po index fd244b5b3..70cb037bb 100644 --- a/holidays/locale/en_US/LC_MESSAGES/TH.po +++ b/holidays/locale/en_US/LC_MESSAGES/TH.po @@ -3,7 +3,7 @@ # msgid "" msgstr "" -"Project-Id-Version: Python Holidays 0.33\n" +"Project-Id-Version: Python Holidays 0.35\n" "POT-Creation-Date: 2023-03-18 15:58-0700\n" "PO-Revision-Date: \n" "Last-Translator: PPsyrius \n" @@ -240,3 +240,7 @@ msgstr "HM King Ramkamhaeng Memorial Day" #. Thai National Flag Day msgid "วันพระราชทานธงชาติไทย" msgstr "Thai National Flag Day" + +#. HM King Bhumibol Adulyadej Memorial Day. +msgid "วันนวมินทรมหาราช" +msgstr "HM King Bhumibol Adulyadej Memorial Day" diff --git a/holidays/locale/th/LC_MESSAGES/TH.po b/holidays/locale/th/LC_MESSAGES/TH.po index c7c0b7956..4e3fec505 100644 --- a/holidays/locale/th/LC_MESSAGES/TH.po +++ b/holidays/locale/th/LC_MESSAGES/TH.po @@ -3,7 +3,7 @@ # msgid "" msgstr "" -"Project-Id-Version: Python Holidays 0.33\n" +"Project-Id-Version: Python Holidays 0.35\n" "POT-Creation-Date: 2023-03-02 00:37+0700\n" "PO-Revision-Date: \n" "Last-Translator: PPsyrius \n" @@ -238,3 +238,7 @@ msgstr "" #. Thai National Flag Day msgid "วันพระราชทานธงชาติไทย" msgstr "" + +#. HM King Bhumibol Adulyadej Memorial Day. +msgid "วันนวมินทรมหาราช" +msgstr "" diff --git a/snapshots/countries/TH.json b/snapshots/countries/TH.json index 910cbd13d..38bda1c46 100644 --- a/snapshots/countries/TH.json +++ b/snapshots/countries/TH.json @@ -2029,7 +2029,7 @@ "2023-08-14": "HM Queen Sirikit The Queen Mother's Birthday (in lieu); National Mother's Day (in lieu)", "2023-08-18": "National Science Day", "2023-09-28": "Thai National Flag Day", - "2023-10-13": "HM King Bhumibol Adulyadej the Great Memorial Day", + "2023-10-13": "HM King Bhumibol Adulyadej Memorial Day", "2023-10-23": "HM King Chulalongkorn Memorial Day", "2023-11-27": "Loy Krathong", "2023-12-05": "HM King Bhumibol Adulyadej the Great's Birthday; National Day; National Father's Day", @@ -2066,8 +2066,8 @@ "2024-08-12": "HM Queen Sirikit The Queen Mother's Birthday; National Mother's Day", "2024-08-18": "National Science Day", "2024-09-28": "Thai National Flag Day", - "2024-10-13": "HM King Bhumibol Adulyadej the Great Memorial Day", - "2024-10-14": "HM King Bhumibol Adulyadej the Great Memorial Day (in lieu)", + "2024-10-13": "HM King Bhumibol Adulyadej Memorial Day", + "2024-10-14": "HM King Bhumibol Adulyadej Memorial Day (in lieu)", "2024-10-23": "HM King Chulalongkorn Memorial Day", "2024-11-15": "Loy Krathong", "2024-12-05": "HM King Bhumibol Adulyadej the Great's Birthday; National Day; National Father's Day", @@ -2101,7 +2101,7 @@ "2025-08-12": "HM Queen Sirikit The Queen Mother's Birthday; National Mother's Day", "2025-08-18": "National Science Day", "2025-09-28": "Thai National Flag Day", - "2025-10-13": "HM King Bhumibol Adulyadej the Great Memorial Day", + "2025-10-13": "HM King Bhumibol Adulyadej Memorial Day", "2025-10-23": "HM King Chulalongkorn Memorial Day", "2025-11-05": "Loy Krathong", "2025-12-05": "HM King Bhumibol Adulyadej the Great's Birthday; National Day; National Father's Day", @@ -2133,7 +2133,7 @@ "2026-08-12": "HM Queen Sirikit The Queen Mother's Birthday; National Mother's Day", "2026-08-18": "National Science Day", "2026-09-28": "Thai National Flag Day", - "2026-10-13": "HM King Bhumibol Adulyadej the Great Memorial Day", + "2026-10-13": "HM King Bhumibol Adulyadej Memorial Day", "2026-10-23": "HM King Chulalongkorn Memorial Day", "2026-11-24": "Loy Krathong", "2026-12-05": "HM King Bhumibol Adulyadej the Great's Birthday; National Day; National Father's Day", @@ -2168,7 +2168,7 @@ "2027-08-12": "HM Queen Sirikit The Queen Mother's Birthday; National Mother's Day", "2027-08-18": "National Science Day", "2027-09-28": "Thai National Flag Day", - "2027-10-13": "HM King Bhumibol Adulyadej the Great Memorial Day", + "2027-10-13": "HM King Bhumibol Adulyadej Memorial Day", "2027-10-23": "HM King Chulalongkorn Memorial Day", "2027-10-25": "HM King Chulalongkorn Memorial Day (in lieu)", "2027-11-13": "Loy Krathong", @@ -2205,7 +2205,7 @@ "2028-08-14": "HM Queen Sirikit The Queen Mother's Birthday (in lieu); National Mother's Day (in lieu)", "2028-08-18": "National Science Day", "2028-09-28": "Thai National Flag Day", - "2028-10-13": "HM King Bhumibol Adulyadej the Great Memorial Day", + "2028-10-13": "HM King Bhumibol Adulyadej Memorial Day", "2028-10-23": "HM King Chulalongkorn Memorial Day", "2028-11-01": "Loy Krathong", "2028-12-05": "HM King Bhumibol Adulyadej the Great's Birthday; National Day; National Father's Day", @@ -2242,8 +2242,8 @@ "2029-08-13": "HM Queen Sirikit The Queen Mother's Birthday (in lieu); National Mother's Day (in lieu)", "2029-08-18": "National Science Day", "2029-09-28": "Thai National Flag Day", - "2029-10-13": "HM King Bhumibol Adulyadej the Great Memorial Day", - "2029-10-15": "HM King Bhumibol Adulyadej the Great Memorial Day (in lieu)", + "2029-10-13": "HM King Bhumibol Adulyadej Memorial Day", + "2029-10-15": "HM King Bhumibol Adulyadej Memorial Day (in lieu)", "2029-10-23": "HM King Chulalongkorn Memorial Day", "2029-11-20": "Loy Krathong", "2029-12-05": "HM King Bhumibol Adulyadej the Great's Birthday; National Day; National Father's Day", @@ -2280,8 +2280,8 @@ "2030-08-12": "HM Queen Sirikit The Queen Mother's Birthday; National Mother's Day", "2030-08-18": "National Science Day", "2030-09-28": "Thai National Flag Day", - "2030-10-13": "HM King Bhumibol Adulyadej the Great Memorial Day", - "2030-10-14": "HM King Bhumibol Adulyadej the Great Memorial Day (in lieu)", + "2030-10-13": "HM King Bhumibol Adulyadej Memorial Day", + "2030-10-14": "HM King Bhumibol Adulyadej Memorial Day (in lieu)", "2030-10-23": "HM King Chulalongkorn Memorial Day", "2030-11-09": "Loy Krathong", "2030-12-05": "HM King Bhumibol Adulyadej the Great's Birthday; National Day; National Father's Day", @@ -2315,7 +2315,7 @@ "2031-08-12": "HM Queen Sirikit The Queen Mother's Birthday; National Mother's Day", "2031-08-18": "National Science Day", "2031-09-28": "Thai National Flag Day", - "2031-10-13": "HM King Bhumibol Adulyadej the Great Memorial Day", + "2031-10-13": "HM King Bhumibol Adulyadej Memorial Day", "2031-10-23": "HM King Chulalongkorn Memorial Day", "2031-11-28": "Loy Krathong", "2031-12-05": "HM King Bhumibol Adulyadej the Great's Birthday; National Day; National Father's Day", @@ -2348,7 +2348,7 @@ "2032-08-12": "HM Queen Sirikit The Queen Mother's Birthday; National Mother's Day", "2032-08-18": "National Science Day", "2032-09-28": "Thai National Flag Day", - "2032-10-13": "HM King Bhumibol Adulyadej the Great Memorial Day", + "2032-10-13": "HM King Bhumibol Adulyadej Memorial Day", "2032-10-23": "HM King Chulalongkorn Memorial Day", "2032-10-25": "HM King Chulalongkorn Memorial Day (in lieu)", "2032-11-17": "Loy Krathong", @@ -2383,7 +2383,7 @@ "2033-08-12": "HM Queen Sirikit The Queen Mother's Birthday; National Mother's Day", "2033-08-18": "National Science Day", "2033-09-28": "Thai National Flag Day", - "2033-10-13": "HM King Bhumibol Adulyadej the Great Memorial Day", + "2033-10-13": "HM King Bhumibol Adulyadej Memorial Day", "2033-10-23": "HM King Chulalongkorn Memorial Day", "2033-10-24": "HM King Chulalongkorn Memorial Day (in lieu)", "2033-11-06": "Loy Krathong", @@ -2422,7 +2422,7 @@ "2034-08-14": "HM Queen Sirikit The Queen Mother's Birthday (in lieu); National Mother's Day (in lieu)", "2034-08-18": "National Science Day", "2034-09-28": "Thai National Flag Day", - "2034-10-13": "HM King Bhumibol Adulyadej the Great Memorial Day", + "2034-10-13": "HM King Bhumibol Adulyadej Memorial Day", "2034-10-23": "HM King Chulalongkorn Memorial Day", "2034-11-25": "Loy Krathong", "2034-12-05": "HM King Bhumibol Adulyadej the Great's Birthday; National Day; National Father's Day", @@ -2459,8 +2459,8 @@ "2035-08-13": "HM Queen Sirikit The Queen Mother's Birthday (in lieu); National Mother's Day (in lieu)", "2035-08-18": "National Science Day", "2035-09-28": "Thai National Flag Day", - "2035-10-13": "HM King Bhumibol Adulyadej the Great Memorial Day", - "2035-10-15": "HM King Bhumibol Adulyadej the Great Memorial Day (in lieu)", + "2035-10-13": "HM King Bhumibol Adulyadej Memorial Day", + "2035-10-15": "HM King Bhumibol Adulyadej Memorial Day (in lieu)", "2035-10-23": "HM King Chulalongkorn Memorial Day", "2035-11-15": "Loy Krathong", "2035-12-05": "HM King Bhumibol Adulyadej the Great's Birthday; National Day; National Father's Day", @@ -2494,7 +2494,7 @@ "2036-08-12": "HM Queen Sirikit The Queen Mother's Birthday; National Mother's Day", "2036-08-18": "National Science Day", "2036-09-28": "Thai National Flag Day", - "2036-10-13": "HM King Bhumibol Adulyadej the Great Memorial Day", + "2036-10-13": "HM King Bhumibol Adulyadej Memorial Day", "2036-10-23": "HM King Chulalongkorn Memorial Day", "2036-11-03": "Loy Krathong", "2036-12-05": "HM King Bhumibol Adulyadej the Great's Birthday; National Day; National Father's Day", @@ -2525,7 +2525,7 @@ "2037-08-12": "HM Queen Sirikit The Queen Mother's Birthday; National Mother's Day", "2037-08-18": "National Science Day", "2037-09-28": "Thai National Flag Day", - "2037-10-13": "HM King Bhumibol Adulyadej the Great Memorial Day", + "2037-10-13": "HM King Bhumibol Adulyadej Memorial Day", "2037-10-23": "HM King Chulalongkorn Memorial Day", "2037-11-22": "Loy Krathong", "2037-12-05": "HM King Bhumibol Adulyadej the Great's Birthday; National Day; National Father's Day", @@ -2559,7 +2559,7 @@ "2038-08-12": "HM Queen Sirikit The Queen Mother's Birthday; National Mother's Day", "2038-08-18": "National Science Day", "2038-09-28": "Thai National Flag Day", - "2038-10-13": "HM King Bhumibol Adulyadej the Great Memorial Day", + "2038-10-13": "HM King Bhumibol Adulyadej Memorial Day", "2038-10-23": "HM King Chulalongkorn Memorial Day", "2038-10-25": "HM King Chulalongkorn Memorial Day (in lieu)", "2038-11-11": "Loy Krathong", @@ -2595,7 +2595,7 @@ "2039-08-12": "HM Queen Sirikit The Queen Mother's Birthday; National Mother's Day", "2039-08-18": "National Science Day", "2039-09-28": "Thai National Flag Day", - "2039-10-13": "HM King Bhumibol Adulyadej the Great Memorial Day", + "2039-10-13": "HM King Bhumibol Adulyadej Memorial Day", "2039-10-23": "HM King Chulalongkorn Memorial Day", "2039-10-24": "HM King Chulalongkorn Memorial Day (in lieu)", "2039-10-31": "Loy Krathong", @@ -2633,8 +2633,8 @@ "2040-08-13": "HM Queen Sirikit The Queen Mother's Birthday (in lieu); National Mother's Day (in lieu)", "2040-08-18": "National Science Day", "2040-09-28": "Thai National Flag Day", - "2040-10-13": "HM King Bhumibol Adulyadej the Great Memorial Day", - "2040-10-15": "HM King Bhumibol Adulyadej the Great Memorial Day (in lieu)", + "2040-10-13": "HM King Bhumibol Adulyadej Memorial Day", + "2040-10-15": "HM King Bhumibol Adulyadej Memorial Day (in lieu)", "2040-10-23": "HM King Chulalongkorn Memorial Day", "2040-11-18": "Loy Krathong", "2040-12-05": "HM King Bhumibol Adulyadej the Great's Birthday; National Day; National Father's Day", @@ -2670,8 +2670,8 @@ "2041-08-12": "HM Queen Sirikit The Queen Mother's Birthday; National Mother's Day", "2041-08-18": "National Science Day", "2041-09-28": "Thai National Flag Day", - "2041-10-13": "HM King Bhumibol Adulyadej the Great Memorial Day", - "2041-10-14": "HM King Bhumibol Adulyadej the Great Memorial Day (in lieu)", + "2041-10-13": "HM King Bhumibol Adulyadej Memorial Day", + "2041-10-14": "HM King Bhumibol Adulyadej Memorial Day (in lieu)", "2041-10-23": "HM King Chulalongkorn Memorial Day", "2041-11-07": "Loy Krathong", "2041-12-05": "HM King Bhumibol Adulyadej the Great's Birthday; National Day; National Father's Day", @@ -2704,7 +2704,7 @@ "2042-08-12": "HM Queen Sirikit The Queen Mother's Birthday; National Mother's Day", "2042-08-18": "National Science Day", "2042-09-28": "Thai National Flag Day", - "2042-10-13": "HM King Bhumibol Adulyadej the Great Memorial Day", + "2042-10-13": "HM King Bhumibol Adulyadej Memorial Day", "2042-10-23": "HM King Chulalongkorn Memorial Day", "2042-11-26": "Loy Krathong", "2042-12-05": "HM King Bhumibol Adulyadej the Great's Birthday; National Day; National Father's Day", @@ -2735,7 +2735,7 @@ "2043-08-12": "HM Queen Sirikit The Queen Mother's Birthday; National Mother's Day", "2043-08-18": "National Science Day", "2043-09-28": "Thai National Flag Day", - "2043-10-13": "HM King Bhumibol Adulyadej the Great Memorial Day", + "2043-10-13": "HM King Bhumibol Adulyadej Memorial Day", "2043-10-23": "HM King Chulalongkorn Memorial Day", "2043-11-16": "Loy Krathong", "2043-12-05": "HM King Bhumibol Adulyadej the Great's Birthday; National Day; National Father's Day", @@ -2770,7 +2770,7 @@ "2044-08-12": "HM Queen Sirikit The Queen Mother's Birthday; National Mother's Day", "2044-08-18": "National Science Day", "2044-09-28": "Thai National Flag Day", - "2044-10-13": "HM King Bhumibol Adulyadej the Great Memorial Day", + "2044-10-13": "HM King Bhumibol Adulyadej Memorial Day", "2044-10-23": "HM King Chulalongkorn Memorial Day", "2044-10-24": "HM King Chulalongkorn Memorial Day (in lieu)", "2044-11-04": "Loy Krathong", @@ -2807,7 +2807,7 @@ "2045-08-14": "HM Queen Sirikit The Queen Mother's Birthday (in lieu); National Mother's Day (in lieu)", "2045-08-18": "National Science Day", "2045-09-28": "Thai National Flag Day", - "2045-10-13": "HM King Bhumibol Adulyadej the Great Memorial Day", + "2045-10-13": "HM King Bhumibol Adulyadej Memorial Day", "2045-10-23": "HM King Chulalongkorn Memorial Day", "2045-11-23": "Loy Krathong", "2045-12-05": "HM King Bhumibol Adulyadej the Great's Birthday; National Day; National Father's Day", @@ -2844,8 +2844,8 @@ "2046-08-13": "HM Queen Sirikit The Queen Mother's Birthday (in lieu); National Mother's Day (in lieu)", "2046-08-18": "National Science Day", "2046-09-28": "Thai National Flag Day", - "2046-10-13": "HM King Bhumibol Adulyadej the Great Memorial Day", - "2046-10-15": "HM King Bhumibol Adulyadej the Great Memorial Day (in lieu)", + "2046-10-13": "HM King Bhumibol Adulyadej Memorial Day", + "2046-10-15": "HM King Bhumibol Adulyadej Memorial Day (in lieu)", "2046-10-23": "HM King Chulalongkorn Memorial Day", "2046-11-13": "Loy Krathong", "2046-12-05": "HM King Bhumibol Adulyadej the Great's Birthday; National Day; National Father's Day", @@ -2882,8 +2882,8 @@ "2047-08-12": "HM Queen Sirikit The Queen Mother's Birthday; National Mother's Day", "2047-08-18": "National Science Day", "2047-09-28": "Thai National Flag Day", - "2047-10-13": "HM King Bhumibol Adulyadej the Great Memorial Day", - "2047-10-14": "HM King Bhumibol Adulyadej the Great Memorial Day (in lieu)", + "2047-10-13": "HM King Bhumibol Adulyadej Memorial Day", + "2047-10-14": "HM King Bhumibol Adulyadej Memorial Day (in lieu)", "2047-10-23": "HM King Chulalongkorn Memorial Day", "2047-11-02": "Loy Krathong", "2047-12-05": "HM King Bhumibol Adulyadej the Great's Birthday; National Day; National Father's Day", @@ -2915,7 +2915,7 @@ "2048-08-12": "HM Queen Sirikit The Queen Mother's Birthday; National Mother's Day", "2048-08-18": "National Science Day", "2048-09-28": "Thai National Flag Day", - "2048-10-13": "HM King Bhumibol Adulyadej the Great Memorial Day", + "2048-10-13": "HM King Bhumibol Adulyadej Memorial Day", "2048-10-23": "HM King Chulalongkorn Memorial Day", "2048-11-20": "Loy Krathong", "2048-12-05": "HM King Bhumibol Adulyadej the Great's Birthday; National Day; National Father's Day", @@ -2949,7 +2949,7 @@ "2049-08-12": "HM Queen Sirikit The Queen Mother's Birthday; National Mother's Day", "2049-08-18": "National Science Day", "2049-09-28": "Thai National Flag Day", - "2049-10-13": "HM King Bhumibol Adulyadej the Great Memorial Day", + "2049-10-13": "HM King Bhumibol Adulyadej Memorial Day", "2049-10-23": "HM King Chulalongkorn Memorial Day", "2049-10-25": "HM King Chulalongkorn Memorial Day (in lieu)", "2049-11-09": "Loy Krathong", @@ -2985,7 +2985,7 @@ "2050-08-12": "HM Queen Sirikit The Queen Mother's Birthday; National Mother's Day", "2050-08-18": "National Science Day", "2050-09-28": "Thai National Flag Day", - "2050-10-13": "HM King Bhumibol Adulyadej the Great Memorial Day", + "2050-10-13": "HM King Bhumibol Adulyadej Memorial Day", "2050-10-23": "HM King Chulalongkorn Memorial Day", "2050-10-24": "HM King Chulalongkorn Memorial Day (in lieu)", "2050-11-28": "Loy Krathong", diff --git a/tests/countries/test_thailand.py b/tests/countries/test_thailand.py index ebe28e5bd..f6f9c5fb7 100644 --- a/tests/countries/test_thailand.py +++ b/tests/countries/test_thailand.py @@ -24,6 +24,11 @@ def test_country_aliases(self): def test_no_holidays(self): self.assertNoHolidays(Thailand(years=1940)) + self.assertNoHolidays(Thailand(years=1958, categories=(ARMED_FORCES,))) + self.assertNoHolidays(Thailand(years=1942, categories=(BANK,))) + self.assertNoHolidays(Thailand(years=1956, categories=(GOVERNMENT,))) + self.assertNoHolidays(Thailand(years=1956, categories=(SCHOOL,))) + self.assertNoHolidays(Thailand(years=1940, categories=(WORKDAY,))) def test_special_holidays(self): self.assertHoliday( @@ -353,13 +358,17 @@ def test_rama_ix_memorial_day(self): name_x = ( "วันคล้ายวันสวรรคตพระบาทสมเด็จพระบรมชนกาธิเบศร มหาภูมิพลอดุลยเดชมหาราช บรมนาถบพิตร" ) + name_x_memorial = "วันนวมินทรมหาราช" self.assertNoHoliday("2016-10-13") self.assertNoHolidayName(name_ix, 2016) - self.assertHolidayName(name_ix, (f"{year}-10-13" for year in range(2017, 2019))) self.assertNoHolidayName(name_x, range(1941, 2019)) - self.assertHolidayName(name_x, (f"{year}-10-13" for year in range(2019, 2058))) + self.assertNoHolidayName(name_x_memorial, range(1941, 2023)) + self.assertHolidayName(name_ix, (f"{year}-10-13" for year in range(2017, 2019))) + self.assertHolidayName(name_x, (f"{year}-10-13" for year in range(2019, 2023))) + self.assertHolidayName(name_x_memorial, (f"{year}-10-13" for year in range(2023, 2058))) self.assertNoHolidayName(name_ix, range(2019, 2058)) + self.assertNoHolidayName(name_x, range(2023, 2058)) self.assertNoNonObservedHoliday( "2018-10-15", @@ -395,17 +404,13 @@ def test_rama_ix_birthday(self): ) self.assertNoHoliday("1959-12-05") - self.assertNoHolidayName(name_reign, 1959) - self.assertNoHolidayName(name_dead, 1959) - self.assertNoHolidayName(name_great, 1959) - self.assertHolidayName(name_reign, (f"{year}-12-05" for year in range(1976, 2016))) + self.assertNoHolidayName(name_reign, range(1941, 1960)) self.assertNoHolidayName(name_dead, range(1941, 2016)) - self.assertNoHolidayName(name_great, range(1941, 2016)) + self.assertNoHolidayName(name_great, range(1941, 2019)) + self.assertHolidayName(name_reign, (f"{year}-12-05" for year in range(1976, 2016))) self.assertHolidayName(name_dead, (f"{year}-12-05" for year in range(2016, 2019))) - self.assertNoHolidayName(name_reign, range(2019, 2058)) - self.assertNoHolidayName(name_great, range(2016, 2019)) self.assertHolidayName(name_great, (f"{year}-12-05" for year in range(2019, 2058))) - self.assertNoHolidayName(name_reign, range(2019, 2058)) + self.assertNoHolidayName(name_reign, range(2016, 2058)) self.assertNoHolidayName(name_dead, range(2019, 2058)) self.assertNoNonObservedHoliday(