Skip to content

Commit

Permalink
add Japan Mountain day
Browse files Browse the repository at this point in the history
add Mountain day (山の日) into Japanese. It's available since 2016
ref.
http://ja.wikipedia.org/wiki/%E5%B1%B1%E3%81%AE%E6%97%A5

http://www.shugiin.go.jp/internet/itdb_annai.nsf/html/statics/housei/html/h-shuhou186.html
- "国民の祝日に関する法律の一部を改正する法律案"
  • Loading branch information
sasezaki committed Nov 27, 2014
1 parent 099041f commit 2c5799b
Show file tree
Hide file tree
Showing 3 changed files with 68 additions and 0 deletions.
20 changes: 20 additions & 0 deletions Date/Holidays/Driver/Japan.php
Expand Up @@ -155,6 +155,7 @@ function _buildHolidays()
$this->_buildGreeneryDay();
$this->_buildChildrensDay();
$this->_buildMarineDay();
$this->_buildMountainDay();
$this->_buildRespectfortheAgedDay();
$this->_buildAutumnalEquinoxDay();
$this->_buildHealthandSportsDay();
Expand Down Expand Up @@ -373,6 +374,25 @@ function _buildMarineDay()
}
}

/**
* build day of Mountain Day
*
* @access private
* @return void
*/
function _buildMountainDay()
{
$date = null;
if ($this->_year >= 2016) {
$date = $this->_year . '-08-11';
}
if (!is_null($date)) {
$this->_addHoliday('mountainDay',
$date,
'Mountain Day');
}
}

/**
* build day of Respect for the Aged Day
*
Expand Down
8 changes: 8 additions & 0 deletions lang/Japan/ja_JP.xml
Expand Up @@ -45,6 +45,10 @@
<internal-name>marineDay</internal-name>
<translation>海の日</translation>
</holiday>
<holiday>
<internal-name>mountainDay</internal-name>
<translation>山の日</translation>
</holiday>
<holiday>
<internal-name>respectfortheAgedDay</internal-name>
<translation>敬老の日</translation>
Expand Down Expand Up @@ -125,6 +129,10 @@
<internal-name>substituteHolidayFormarineDay</internal-name>
<translation>振替休日</translation>
</holiday>
<holiday>
<internal-name>substituteHolidayFormountainDay</internal-name>
<translation>振替休日</translation>
</holiday>
<holiday>
<internal-name>substituteHolidayForrespectfortheAgedDay</internal-name>
<translation>振替休日</translation>
Expand Down
40 changes: 40 additions & 0 deletions tests/Date_Holidays_Driver_Japan_TestSuite.php
Expand Up @@ -754,6 +754,7 @@ function setUp()
'2016-05-04' => true,
'2016-05-05' => true,
'2016-07-18' => true,
'2016-08-11' => true,
'2016-09-19' => true,
'2016-09-22' => true,
'2016-10-10' => true,
Expand All @@ -770,6 +771,7 @@ function setUp()
'2017-05-04' => true,
'2017-05-05' => true,
'2017-07-17' => true,
'2017-08-11' => true,
'2017-09-18' => true,
'2017-09-23' => true,
'2017-10-09' => true,
Expand All @@ -787,6 +789,7 @@ function setUp()
'2018-05-04' => true,
'2018-05-05' => true,
'2018-07-16' => true,
'2018-08-11' => true,
'2018-09-17' => true,
'2018-09-23' => true,
'2018-09-24' => true,
Expand All @@ -805,6 +808,8 @@ function setUp()
'2019-05-05' => true,
'2019-05-06' => true,
'2019-07-15' => true,
'2019-08-11' => true,
'2019-08-12' => true,
'2019-09-16' => true,
'2019-09-23' => true,
'2019-10-14' => true,
Expand All @@ -822,6 +827,7 @@ function setUp()
'2020-05-05' => true,
'2020-05-06' => true,
'2020-07-20' => true,
'2020-08-11' => true,
'2020-09-21' => true,
'2020-09-22' => true,
'2020-10-12' => true,
Expand All @@ -837,6 +843,7 @@ function setUp()
'2021-05-04' => true,
'2021-05-05' => true,
'2021-07-19' => true,
'2021-08-11' => true,
'2021-09-20' => true,
'2021-09-23' => true,
'2021-10-11' => true,
Expand All @@ -852,6 +859,7 @@ function setUp()
'2022-05-04' => true,
'2022-05-05' => true,
'2022-07-18' => true,
'2022-08-11' => true,
'2022-09-19' => true,
'2022-09-23' => true,
'2022-10-10' => true,
Expand All @@ -868,6 +876,7 @@ function setUp()
'2023-05-04' => true,
'2023-05-05' => true,
'2023-07-17' => true,
'2023-08-11' => true,
'2023-09-18' => true,
'2023-09-23' => true,
'2023-10-09' => true,
Expand All @@ -885,6 +894,8 @@ function setUp()
'2024-05-05' => true,
'2024-05-06' => true,
'2024-07-15' => true,
'2024-08-11' => true,
'2024-08-12' => true,
'2024-09-16' => true,
'2024-09-22' => true,
'2024-09-23' => true,
Expand All @@ -903,6 +914,7 @@ function setUp()
'2025-05-05' => true,
'2025-05-06' => true,
'2025-07-21' => true,
'2025-08-11' => true,
'2025-09-15' => true,
'2025-09-23' => true,
'2025-10-13' => true,
Expand All @@ -920,6 +932,7 @@ function setUp()
'2026-05-05' => true,
'2026-05-06' => true,
'2026-07-20' => true,
'2026-08-11' => true,
'2026-09-21' => true,
'2026-09-22' => true,
'2026-09-23' => true,
Expand All @@ -937,6 +950,7 @@ function setUp()
'2027-05-04' => true,
'2027-05-05' => true,
'2027-07-19' => true,
'2027-08-11' => true,
'2027-09-20' => true,
'2027-09-23' => true,
'2027-10-11' => true,
Expand All @@ -952,6 +966,7 @@ function setUp()
'2028-05-04' => true,
'2028-05-05' => true,
'2028-07-17' => true,
'2028-08-11' => true,
'2028-09-18' => true,
'2028-09-22' => true,
'2028-10-09' => true,
Expand All @@ -969,6 +984,7 @@ function setUp()
'2029-05-04' => true,
'2029-05-05' => true,
'2029-07-16' => true,
'2029-08-11' => true,
'2029-09-17' => true,
'2029-09-23' => true,
'2029-09-24' => true,
Expand All @@ -987,6 +1003,8 @@ function setUp()
'2030-05-05' => true,
'2030-05-06' => true,
'2030-07-15' => true,
'2030-08-11' => true,
'2030-08-12' => true,
'2030-09-16' => true,
'2030-09-23' => true,
'2030-10-14' => true,
Expand All @@ -1004,6 +1022,7 @@ function setUp()
'2031-05-05' => true,
'2031-05-06' => true,
'2031-07-21' => true,
'2031-08-11' => true,
'2031-09-15' => true,
'2031-09-23' => true,
'2031-10-13' => true,
Expand All @@ -1020,6 +1039,7 @@ function setUp()
'2032-05-04' => true,
'2032-05-05' => true,
'2032-07-19' => true,
'2032-08-11' => true,
'2032-09-20' => true,
'2032-09-21' => true,
'2032-09-22' => true,
Expand All @@ -1037,6 +1057,7 @@ function setUp()
'2033-05-04' => true,
'2033-05-05' => true,
'2033-07-18' => true,
'2033-08-11' => true,
'2033-09-19' => true,
'2033-09-23' => true,
'2033-10-10' => true,
Expand All @@ -1053,6 +1074,7 @@ function setUp()
'2034-05-04' => true,
'2034-05-05' => true,
'2034-07-17' => true,
'2034-08-11' => true,
'2034-09-18' => true,
'2034-09-23' => true,
'2034-10-09' => true,
Expand All @@ -1070,6 +1092,7 @@ function setUp()
'2035-05-04' => true,
'2035-05-05' => true,
'2035-07-16' => true,
'2035-08-11' => true,
'2035-09-17' => true,
'2035-09-23' => true,
'2035-09-24' => true,
Expand All @@ -1088,6 +1111,7 @@ function setUp()
'2036-05-05' => true,
'2036-05-06' => true,
'2036-07-21' => true,
'2036-08-11' => true,
'2036-09-15' => true,
'2036-09-22' => true,
'2036-10-13' => true,
Expand All @@ -1105,6 +1129,7 @@ function setUp()
'2037-05-05' => true,
'2037-05-06' => true,
'2037-07-20' => true,
'2037-08-11' => true,
'2037-09-21' => true,
'2037-09-22' => true,
'2037-09-23' => true,
Expand All @@ -1121,6 +1146,7 @@ function setUp()
'2038-05-04' => true,
'2038-05-05' => true,
'2038-07-19' => true,
'2038-08-11' => true,
'2038-09-20' => true,
'2038-09-23' => true,
'2038-10-11' => true,
Expand All @@ -1136,6 +1162,7 @@ function setUp()
'2039-05-04' => true,
'2039-05-05' => true,
'2039-07-18' => true,
'2039-08-11' => true,
'2039-09-19' => true,
'2039-09-23' => true,
'2039-10-10' => true,
Expand All @@ -1153,6 +1180,7 @@ function setUp()
'2040-05-04' => true,
'2040-05-05' => true,
'2040-07-16' => true,
'2040-08-11' => true,
'2040-09-17' => true,
'2040-09-22' => true,
'2040-10-08' => true,
Expand All @@ -1170,6 +1198,8 @@ function setUp()
'2041-05-05' => true,
'2041-05-06' => true,
'2041-07-15' => true,
'2041-08-11' => true,
'2041-08-12' => true,
'2041-09-16' => true,
'2041-09-23' => true,
'2041-10-14' => true,
Expand All @@ -1187,6 +1217,7 @@ function setUp()
'2042-05-05' => true,
'2042-05-06' => true,
'2042-07-21' => true,
'2042-08-11' => true,
'2042-09-15' => true,
'2042-09-23' => true,
'2042-10-13' => true,
Expand All @@ -1204,6 +1235,7 @@ function setUp()
'2043-05-05' => true,
'2043-05-06' => true,
'2043-07-20' => true,
'2043-08-11' => true,
'2043-09-21' => true,
'2043-09-22' => true,
'2043-09-23' => true,
Expand All @@ -1221,6 +1253,7 @@ function setUp()
'2044-05-04' => true,
'2044-05-05' => true,
'2044-07-18' => true,
'2044-08-11' => true,
'2044-09-19' => true,
'2044-09-22' => true,
'2044-10-10' => true,
Expand All @@ -1237,6 +1270,7 @@ function setUp()
'2045-05-04' => true,
'2045-05-05' => true,
'2045-07-17' => true,
'2045-08-11' => true,
'2045-09-18' => true,
'2045-09-22' => true,
'2045-10-09' => true,
Expand All @@ -1254,6 +1288,7 @@ function setUp()
'2046-05-04' => true,
'2046-05-05' => true,
'2046-07-16' => true,
'2046-08-11' => true,
'2046-09-17' => true,
'2046-09-23' => true,
'2046-09-24' => true,
Expand All @@ -1272,6 +1307,8 @@ function setUp()
'2047-05-05' => true,
'2047-05-06' => true,
'2047-07-15' => true,
'2047-08-11' => true,
'2047-08-12' => true,
'2047-09-16' => true,
'2047-09-23' => true,
'2047-10-14' => true,
Expand All @@ -1289,6 +1326,7 @@ function setUp()
'2048-05-05' => true,
'2048-05-06' => true,
'2048-07-20' => true,
'2048-08-11' => true,
'2048-09-21' => true,
'2048-09-22' => true,
'2048-10-12' => true,
Expand All @@ -1304,6 +1342,7 @@ function setUp()
'2049-05-04' => true,
'2049-05-05' => true,
'2049-07-19' => true,
'2049-08-11' => true,
'2049-09-20' => true,
'2049-09-21' => true,
'2049-09-22' => true,
Expand All @@ -1321,6 +1360,7 @@ function setUp()
'2050-05-04' => true,
'2050-05-05' => true,
'2050-07-18' => true,
'2050-08-11' => true,
'2050-09-19' => true,
'2050-09-23' => true,
'2050-10-10' => true,
Expand Down

0 comments on commit 2c5799b

Please sign in to comment.