Releases: azuyalabs/yasumi
v1.7.0
A new release was long overdue and v1.7.0 has some nice enhancements... Four new countries have been added (Latvia, Lithuania, Hungary and Switzerland) making the total of holiday providers 96! (31 countries and 65 sub-regions).
Instead of giving the country name as a parameter, you can now also use the ISO3166_2 code to instantiate a Holiday object, which in some cases makes more sense. Also, all filters implement the Countable interface so you can use the ->count() method, which will return the correct number of (filtered) holidays.
Heads up! v1.7.0 will be the last release supporting PHP5.x. PHP7 has been out for a long time and Yasumi can definitely benefit from the new features in PHP7. Likely the PHP7 only branch will start as v2.0.0.
As always a big thanks to all the contributors!
Implemented enhancements:
- Holiday Provider for Latvia. #70 (lukosius)
- Holiday Provider for Lithuania. #67 (lukosius)
- Holiday Provider for Hungary. #57 (AronNovak)
- Holiday Provider for Switzerland. #56 (qligier)
- All filters implement the Countable interface allowing you to use the ->count() method. #77
- Sometimes it is more convenient to be able to create a Yasumi instance by ISO3166 code rather than Yasumi's Holiday Provider name. A new function createByISO3166_2 has been added to allow for that. #62 (huehnerhose)
- Missing translations (de_DE) for Easter Sunday and Whitsunday. #60 (IceShack)
- Made calculate method public and use of proper camel casing. #73 (patrickreck)
- Upgraded Faker Library to version 1.7
- Renamed the holiday type NATIONAL to OFFICIAL. Subregions may have official holidays and the name NATIONAL doesn't suit these situations. #65
- Upgraded PHP-CS-Fixer to version 2.6
Resolved Issues:
- Corrected Geneva (Switzerland) unit test to ensure some holidays that are established at a particular year are handled as such.
- Repentance Day is an official holiday in Saxony (Germany) #63
- Corrected the Easter Sunday translation for Austria (de_AT) #66
- Corrected Hungary unit test to ensure holidays that are established at a particular year are handled as such.
- Added missing Summer Bank Holiday for the United Kingdom. #64
v1.6.1
This bugfix release addresses some minor annoying issues, so unfortunately no new features this time.
Implemented enhancements:
- Moved Reformation Day to Christian Holidays as it is not only celebrated in Germany.
- Added missing unit tests for the German Unit Day for each German state.
Resolved issues:
- Fixed Christmas Day and Boxing Day for the United Kingdom. A substitute bank holiday is now created for both Christmas and Boxing Day when either of those days fall on a weekend. #48 (joshuabaker)
- Renamed 'en_US' translation for the Second Christmas Day (from ‘Boxing Day’ to ‘Second Christmas Day’: Boxing Day concept does not exist in the US). #53 (AngelinCalu)
- Created fallback calculation of the easter_days function in case the PHP extension 'calendar' is not loaded. #55 (stelgenhof)
- Added missing unit tests for Reformation Day as in 2017 it is celebrated in all German states for its 500th anniversary.
- Changed Travis configuration to use Composer-installed phpunit to avoid if any issues arise with globally installed phpunit.
v1.6.0
We start the new year with a new release, in which we welcome Austria, Ireland, Romania and South Africa to the Yasumi family. Also Yasumi hit the 8000 mark in the first week of 2017: over 8000 times Yasumi has been installed already!
Again, thank you all for your contributions and fixes!
Implemented enhancements:
- Added Holiday Provider for Romania. #52 (AngelinCalu)
- Added Holiday Provider for Ireland. stelgenhof
- Added Holiday Provider for South Africa. stelgenhof
- Added Holiday Provider for Austria. stelgenhof
- Refactored the calculation of Orthodox Easter using the function from ChristianHolidays.php. #47 (AngelinCalu)
- Added 'en_US' translations for the Polish Independence Day and Constitution Day. #45 (AngelinCalu)
Resolved issues:
- The parameters of the
isHoliday
andisWorkingDay
methods now allow for classes that derive from DateTime (like the very popular Carbon class). #49 (stelgenhof)
v1.5.0
Being occupied with other projects is good but has the side effect some others don't get the attention they deserve (sorry Yasumi). However, happy to announce a new release of Yasumi with 4 new countries added and holiday providers for all the German states.
Yasumi now supports 62 holiday providers (23 countries and 39 sub-regions) and has over 1500 unit tests ensuring all holidays are calculated correctly.
Big thanks to all the contributors making Yasumi better and more complete!
Implemented enhancements:
- Added Holiday Provider for Australia (and the sub-region of Victoria). #38 (brucealdridge)
- Added Holiday Provider for Portugal. #44 (rvelhote)
- Added Holiday Provider for Ukraine. #41 (madmis)
- Added Holiday Providers for all 16 German States. #34 (stelgenhof)
- Added Holiday Provider for Croatia. #32 (karlomikus)
- Possibility to retrieve the next or previous working day within a defined number of days from today #39 (brucealdridge)
- You can now also use your own holiday providers in addition to the included holiday providers. A very helpful improvement if Yasumi does not include your provider (yet), but you want to use yours! #29 (navarr)
Resolved issues:
- Carnival Day in Brazil was incorrectly set to be 47 days after Easter. Carnival Day begins Friday before Ash Wednesday (51 days to Easter). #36 (icaroce)
- All Saints Day for Finland was incorrectly set for November 1st. The correct date is Saturday between 31 Oct and 6 Nov, similar to Sweden. #43 (stelgenhof)
v1.4.0
Implemented enhancements:
- Added Holiday Provider for Brazil. #21 (dorianneto)
- Added Holiday Provider for the Czech Republic. #26 (dfridrich)
- Added Holiday Provider for the United Kingdom. #23
- Add Welsh language (spoken in Wales, UK) translations for the holidays in the United Kingdom #25 (meigwilym)
- All Holiday Provider must now implement a code that will identify it. Typically this is the ISO3166 code
corresponding to the respective country or subregion. This can help for purposes such as translations or interfacing
with other API's for example. - To determine a set of holidays between two dates you can now use the aptly named 'between()' method.
Resolved issues:
- Fixed an issue with the unit test for the 'getProviders' method failing on Windows. Hardcoded unix-style directory separators have been replaced by DIRECTORY_SEPARATOR. #30 (navarr)
- Corrected a typo in the English translation for 敬老の日 (Japan) #22 (navarr)
- Fixed issue that the unit tests in 'YasumiTest' (methods 'next' and 'previous') didn't cover the situations that the limits are exceeded. #28
v1.3.0
Implemented enhancements:
- Added Holiday Provider for Poland. #18 (mpdx)
- Added Holiday Provider for New Zealand. #13 (badams)
- Added Holiday Provider for Greece. #10 (sebdesign)
- Added Holiday Provider for Germany. #9 (eaglefsd)
- Added translations ('fr_FR', 'fr_BE') for Belgium National day #864d250 (R2c)
- Sorted all translations in the translation files alphabetically (descending).
- Added missing English ('en_US') translations for the Christian holidays 'Immaculate Conception', 'Maundy Thursday',
'St. Georges Day', 'St. John's Day', 'St. Josephs Day' and 'St. Stephens Day'. - Added Test Interface class to ensure the unit tests contain a some minimal assertions.
- Refactoring and cleanup of all unit tests.
Resolved issues:
- Fixed issue for Sweden as All Saints Day was always calculated to be on November 1st. However the holiday has always
been celebrated on a Saturday (between October 31 and November 6th). - Fixed the getProviders as it was not able to load Holiday Providers defined in (sub) regions #5879133 (R2c)
- Fixed issue that it was possible for the AbstractProvider class to be loaded as a Holiday Provider #9678bc4 (R2c)
- Corrected incorrect pathname reference *BaseTestCase.php files ("Test" -> "test).
- Fixed issue for France as Good Friday and St. Stephens Day were defined as official holidays. These aren't national
holidays and are only observed in the French departments Moselle, Bas-Rhin and Haut-Rhin. With this fix, these
holidays have been removed from the France Holiday providers and new providers for the departments Moselle, Bas-Rhin
and Haut-Rhin are added. #17 (R2c) - Updated locales list based on CLDR version 29. Removed locales of which the region identifier is not specified.
- Fixed issue for Sweden as Midsummer's Day (st. Johns Day) was always calculated to be on June 24th. However the
holiday has always been celebrated on a Saturday (between June 20 and June 26). - Fixed base test for some Spain/LaRioja as some holidays have been established only in a particular year, causing
false failures in the unit tests. - Running php-cs-fixer fix . --level=psr2 generated a massive list of changes, and broke unit tests. Added a custom
.php_cs config file to adhere to the PSR-2 Coding Standards and resolve this issue. In addition the php-cs-fixer
command to has been added to composer to run the fixers and on the CI server (Travis), meaning PR’s will need to be
PSR2 compliant before they can be merged. If any files do not pass, the build fails. #15 #16 (badams) - Accidentally the timezone for Norway was set to "Europe/Copenhagen". This has been corrected to "Europe/Oslo". #11 #12 (badams)
- Fixed issue for Finland as Midsummer's Day (st. Johns Day) was always calculated to be on June 24th. However since
1955, the holiday has always been celebrated on a Saturday (between June 20 and June 26).
v1.2.0
Implemented enhancements:
- Added Holiday Provider for Denmark
- Added Holiday Provider for Norway
- Added Holiday Provider for Sweden
- Added Holiday Provider for Finland
- New function 'isWorkingDay' added that determines whether a date represents a working day or not. A working day is
considered a date that is neither a holiday nor falls into the weekend. - Refactoring and cleanup of unit tests
Closed issues:
- The Vernal Equinox Day and Autumnal Equinox Day in Japan were excluded from having it substituted for another day in
case these days would fall on the weekend. - Fixed tests for some holiday providers as some holidays have been established only in a particular year, causing
false failures in the unit tests.
v1.1.0
Implemented enhancements:
- Added Spain Holiday Driver (including the autonomous communities Andalusia, Aragon, Asturias, Balearic Islands,
Basque Country, Canary Islands, Cantabria, Castile and León, Castilla-La Mancha, Ceuta, Community of Madrid,
Extremadura, Galicia, La Rioja, Melilla, Navarre, Region of Murcia, Valencian Community) - Added Corpus Christi, St. Joseph's Day, Maundy Thursday, St. George's Day, St. John's Day to the common Christian
Holidays. - Updated some English, Italian, French and Dutch translations.
- Created separate tests for holidays that are substituted on different days.
- Moved all other holiday calculations in Netherlands and France to individual methods.
- Allow for name spaced holiday providers.
- Added test for translation of Ash Wednesday and Valentinesday in the Netherlands.
- Added test to check whether all holidays for a Holiday Provider are defined by the respective provider class.
- Removed support for PHP 5.4. Minimum version is now 5.5. PHP 7.0 is known to work however in Travis CI still allowed
to fail
Closed issues:
- Fixed issue for Japan where substituted holidays had same date as the original holidays.
v1.0.0
Welcome to the first public version of Yasumi! Yasumi is an easy PHP library to help you calculate the dates and names of holidays and other special celebrations from various countries/states.