From ceeb8fd35b94356f731c10deca60a733668595ca Mon Sep 17 00:00:00 2001 From: Jakub Wojtyra <87640400+jwojtyra-aterian@users.noreply.github.com> Date: Wed, 2 Feb 2022 14:31:36 +0100 Subject: [PATCH 001/142] Fix BC break add missing method `ProviderInterface::getHolidays` (#277) --- src/Yasumi/ProviderInterface.php | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/src/Yasumi/ProviderInterface.php b/src/Yasumi/ProviderInterface.php index 73754848e..83ae7f7a9 100755 --- a/src/Yasumi/ProviderInterface.php +++ b/src/Yasumi/ProviderInterface.php @@ -70,4 +70,11 @@ public function isWorkingDay(\DateTimeInterface $date): bool; * @throws \InvalidArgumentException when the given name is blank or empty */ public function getHoliday(string $key): ?Holiday; + + /** + * Gets all the holidays defined by this holiday provider (for the given year). + * + * @return Holiday[] list of all holidays defined for the given year + */ + public function getHolidays(): array; } From e4df3af07ba01929719d07a83838c36f3018877a Mon Sep 17 00:00:00 2001 From: Sacha Telgenhof Date: Thu, 3 Feb 2022 00:37:18 +0900 Subject: [PATCH 002/142] Included tests in the statistical analysis. Added the type of the array return type. --- phpstan.neon.dist | 1 + tests/Australia/AnzacDayTest.php | 2 +- tests/Australia/AustraliaDayTest.php | 4 +- .../CanberraDayTest.php | 2 +- .../EasterSaturdayTest.php | 2 +- .../EasterSundayTest.php | 2 +- .../LabourDayTest.php | 2 +- .../QueensBirthdayTest.php | 2 +- .../ReconciliationDayTest.php | 2 +- tests/Australia/BoxingDayTest.php | 2 +- tests/Australia/ChristmasDayTest.php | 2 +- tests/Australia/EasterMondayTest.php | 4 +- tests/Australia/GoodFridayTest.php | 2 +- .../NewSouthWales/BankHolidayTest.php | 2 +- .../NewSouthWales/EasterSaturdayTest.php | 2 +- .../NewSouthWales/EasterSundayTest.php | 2 +- .../Australia/NewSouthWales/LabourDayTest.php | 2 +- .../NewSouthWales/QueensBirthdayTest.php | 2 +- tests/Australia/NewYearsDayTest.php | 2 +- .../NorthernTerritory/EasterSaturdayTest.php | 2 +- .../NorthernTerritory/MayDayTest.php | 2 +- .../NorthernTerritory/PicnicDayTest.php | 2 +- .../NorthernTerritory/QueensBirthdayTest.php | 2 +- .../Queensland/Brisbane/PeoplesDayTest.php | 2 +- tests/Australia/Queensland/LabourDayTest.php | 2 +- .../Queensland/QueensBirthdayTest.php | 2 +- .../SouthAustralia/AdelaideCupDayTest.php | 2 +- .../SouthAustralia/ChristmasDayTest.php | 2 +- .../SouthAustralia/EasterSaturdayTest.php | 2 +- .../SouthAustralia/LabourDayTest.php | 2 +- .../SouthAustralia/ProclamationDayTest.php | 2 +- .../SouthAustralia/QueensBirthdayTest.php | 2 +- .../CentralNorth/DevonportShowTest.php | 2 +- tests/Australia/Tasmania/EightHourDayTest.php | 2 +- .../FlindersIsland/FlindersIslandShowTest.php | 2 +- .../KingIsland/KingIslandShowTest.php | 2 +- .../Tasmania/Northeast/LauncestonShowTest.php | 2 +- .../Tasmania/Northwest/BurnieShowTest.php | 2 +- .../Northwest/CircularHead/AGFESTTest.php | 2 +- .../Australia/Tasmania/QueensBirthdayTest.php | 2 +- .../Australia/Tasmania/RecreationDayTest.php | 2 +- .../Tasmania/South/HobartShowTest.php | 2 +- .../South/Southeast/HobartRegattaTest.php | 2 +- .../Victoria/AFLGrandFinalFridayTest.php | 2 +- .../Australia/Victoria/EasterSaturdayTest.php | 2 +- tests/Australia/Victoria/EasterSundayTest.php | 2 +- tests/Australia/Victoria/LabourDayTest.php | 2 +- .../Victoria/MelbourneCupDayTest.php | 2 +- .../Australia/Victoria/QueensBirthdayTest.php | 2 +- .../WesternAustralia/LabourDayTest.php | 2 +- .../WesternAustralia/QueensBirthdayTest.php | 2 +- .../WesternAustraliaDayTest.php | 2 +- tests/Austria/AllSaintsDayTest.php | 2 +- tests/Austria/AssumptionOfMaryTest.php | 2 +- tests/Austria/Burgenland/stMartinsDayTest.php | 2 +- tests/Austria/Carinthia/PlebisciteDayTest.php | 2 +- tests/Austria/Carinthia/StJosephsDayTest.php | 2 +- tests/Austria/ChristmasTest.php | 2 +- tests/Austria/EpiphanyTest.php | 2 +- tests/Austria/ImmaculateConceptionTest.php | 2 +- tests/Austria/InternationalWorkersDayTest.php | 2 +- .../LowerAustria/StLeopoldsDayTest.php | 2 +- tests/Austria/NewYearsDayTest.php | 2 +- tests/Austria/Salzburg/StRupertsDayTest.php | 2 +- tests/Austria/SecondChristmasDayTest.php | 2 +- tests/Austria/Styria/StJosephsDayTest.php | 2 +- tests/Austria/Tyrol/StJosephsDayTest.php | 2 +- .../UpperAustria/StFloriansDayTest.php | 2 +- tests/Austria/Vienna/StLeopoldsDayTest.php | 2 +- tests/Austria/Vorarlberg/StJosephsDayTest.php | 2 +- tests/Base/TypographyTest.php | 2 + tests/Base/WeekendTest.php | 4 ++ tests/Base/YasumiWorkdayTest.php | 6 +++ tests/Belgium/AllSaintsDayTest.php | 2 +- tests/Belgium/ArmisticeDayTest.php | 2 +- tests/Belgium/AssumptionOfMaryTest.php | 2 +- tests/Belgium/ChristmasTest.php | 2 +- tests/Belgium/InternationalWorkersDayTest.php | 2 +- tests/Belgium/NationalDayTest.php | 2 +- tests/Belgium/NewYearsDayTest.php | 2 +- tests/Bosnia/ChristmasDayTest.php | 2 +- tests/Bosnia/DayAfterNewYearsDay.php | 2 +- tests/Bosnia/InternationalWorkersDayTest.php | 2 +- tests/Bosnia/NewYearsDayTest.php | 2 +- tests/Bosnia/OrthodoxChristmasDay.php | 2 + tests/Bosnia/SecondLabourDay.php | 2 +- tests/Croatia/AllSaintsDayTest.php | 2 +- tests/Croatia/AssumptionOfMaryTest.php | 2 +- tests/Croatia/ChristmasDayTest.php | 2 +- tests/Croatia/EpiphanyTest.php | 2 +- tests/Croatia/InternationalWorkersDayTest.php | 2 +- tests/Croatia/NewYearsDayTest.php | 2 +- tests/Croatia/StStephensDayTest.php | 2 +- tests/CzechRepublic/ChristmasDayTest.php | 2 +- tests/CzechRepublic/ChristmasEveTest.php | 2 +- tests/CzechRepublic/CzechStateHoodDayTest.php | 2 +- .../IndependentCzechoslovakStateDayTest.php | 2 +- .../InternationalWorkersDayTest.php | 2 +- tests/CzechRepublic/JanHusDayTest.php | 2 +- tests/CzechRepublic/NewYearsDayTest.php | 2 +- .../RenewalOfIndependentCzechStateDayTest.php | 2 +- .../SaintsCyrilAndMethodiusDayTest.php | 2 +- .../CzechRepublic/SecondChristmasDayTest.php | 2 +- .../StruggleForFreedomAndDemocracyDayTest.php | 2 +- .../CzechRepublic/VictoryInEuropeDayTest.php | 2 +- tests/Denmark/ChristmasDayTest.php | 2 +- tests/Denmark/ChristmasEveTest.php | 2 +- tests/Denmark/InternationalWorkersDayTest.php | 2 +- tests/Denmark/NewYearsDayTest.php | 2 +- tests/Denmark/NewYearsEveTest.php | 2 +- tests/Denmark/SecondChristmasDayTest.php | 2 +- tests/Estonia/ChristmasDayTest.php | 2 + tests/Estonia/ChristmasEveDayTest.php | 2 + tests/Estonia/EasterDayTest.php | 2 + tests/Estonia/GoodFridayDayTest.php | 2 + tests/Estonia/InternationalWorkersDayTest.php | 2 + tests/Estonia/NewYearsDayTest.php | 2 + tests/Estonia/PentecostTest.php | 2 + tests/Estonia/SecondChristmasDayTest.php | 2 + tests/Estonia/StJohnsDayTest.php | 2 + tests/Finland/AllSaintsDayTest.php | 2 +- tests/Finland/ChristmasDayTest.php | 2 +- tests/Finland/EpiphanyTest.php | 2 +- tests/Finland/InternationalWorkersDayTest.php | 2 +- tests/Finland/NewYearsDayTest.php | 2 +- tests/Finland/SecondChristmasDayTest.php | 2 +- tests/France/AllSaintsDayTest.php | 2 +- tests/France/AssumptionOfMaryTest.php | 2 +- tests/France/BasRhin/stStephensDayTest.php | 2 +- tests/France/ChristmasDayTest.php | 2 +- tests/France/HautRhin/stStephensDayTest.php | 2 +- tests/France/InternationalWorkersDayTest.php | 2 +- tests/France/Moselle/stStephensDayTest.php | 2 +- tests/France/NewYearsDayTest.php | 2 +- tests/Georgia/InternationalWomensDayTest.php | 2 +- tests/Georgia/MtskhetobaDayTest.php | 2 +- tests/Georgia/NewYearsDayTest.php | 2 +- tests/Georgia/OrthodoxChristmasDayTest.php | 2 +- tests/Georgia/OrthodoxEpiphanyDayTest.php | 2 +- tests/Georgia/SecondNewYearDayTest.php | 2 +- tests/Georgia/StAndrewsDayTest.php | 2 +- tests/Georgia/StGeorgesDayTest.php | 2 +- tests/Georgia/StMarysDayTest.php | 2 +- tests/Georgia/VictoryDayTest.php | 2 +- .../BadenWurttemberg/AllSaintsDayTest.php | 2 +- .../Germany/BadenWurttemberg/EpiphanyTest.php | 2 +- tests/Germany/Bavaria/AllSaintsDayTest.php | 2 +- tests/Germany/Bavaria/EpiphanyTest.php | 2 +- .../Brandenburg/ReformationDayTest.php | 2 +- tests/Germany/Bremen/ReformationDayTest.php | 2 +- tests/Germany/ChristmasTest.php | 2 +- .../Germany/Hamburg/DayOfReformationTest.php | 2 +- tests/Germany/InternationalWorkersDayTest.php | 2 +- .../LowerSaxony/ReformationDayTest.php | 2 +- .../ReformationDayTest.php | 2 +- tests/Germany/NewYearsDayTest.php | 2 +- tests/Germany/NewYearsEveTest.php | 2 +- .../NorthRhineWestphalia/AllSaintsDayTest.php | 2 +- .../RhinelandPalatinate/AllSaintsDayTest.php | 2 +- tests/Germany/Saarland/AllSaintsDayTest.php | 2 +- .../Germany/Saarland/AssumptionOfMaryTest.php | 2 +- tests/Germany/Saxony/ReformationDayTest.php | 2 +- tests/Germany/SaxonyAnhalt/EpiphanyTest.php | 2 +- .../SaxonyAnhalt/ReformationDayTest.php | 2 +- .../SchleswigHolstein/ReformationDayTest.php | 2 +- tests/Germany/SecondChristmasDayTest.php | 2 +- .../Germany/Thuringia/ReformationDayTest.php | 2 +- .../Thuringia/WorldChildrensDayTest.php | 2 +- tests/Greece/AnnunciationTest.php | 2 +- tests/Greece/AssumptionOfMaryTest.php | 2 +- tests/Greece/ChristmasDayTest.php | 2 +- tests/Greece/EpiphanyTest.php | 2 +- tests/Greece/InternationalWorkersDayTest.php | 2 +- tests/Greece/NewYearsDayTest.php | 2 +- tests/Greece/ThreeHolyHierarchsTest.php | 2 +- tests/Hungary/AllSaintsDayTest.php | 2 +- tests/Hungary/ChristmasTest.php | 2 +- tests/Hungary/InternationalWorkersDayTest.php | 2 +- tests/Hungary/NewYearsDayTest.php | 2 +- tests/Hungary/SecondChristmasDayTest.php | 2 +- tests/Ireland/AugustHolidayTest.php | 2 +- tests/Ireland/ChristmasDayTest.php | 2 +- tests/Ireland/EasterMondayTest.php | 2 +- tests/Ireland/EasterTest.php | 2 +- tests/Ireland/GoodFridayTest.php | 2 +- tests/Ireland/JuneHolidayTest.php | 2 +- tests/Ireland/MayDayTest.php | 2 +- tests/Ireland/NewYearsDayTest.php | 2 +- tests/Ireland/OctoberHolidayTest.php | 2 +- tests/Ireland/PentecostTest.php | 2 +- tests/Ireland/StPatricksDayTest.php | 2 +- tests/Ireland/StStephensDayTest.php | 2 +- tests/Ireland/pentecostMondayTest.php | 2 +- tests/Italy/AllSaintsDayTest.php | 2 +- tests/Italy/AssumptionOfMaryTest.php | 2 +- tests/Italy/ChristmasTest.php | 2 +- tests/Italy/EpiphanyTest.php | 2 +- tests/Italy/ImmaculateConceptionTest.php | 2 +- tests/Italy/InternationalWorkersDayTest.php | 2 +- tests/Italy/NewYearsDayTest.php | 2 +- tests/Italy/stStephensDayTest.php | 2 +- tests/Japan/AutumnalEquinoxDayTest.php | 2 +- tests/Japan/VernalEquinoxDayTest.php | 2 +- tests/Latvia/ChristmasDayTest.php | 2 + tests/Latvia/ChristmasEveDayTest.php | 2 + tests/Latvia/EasterDayTest.php | 2 + tests/Latvia/EasterMondayDayTest.php | 2 + tests/Latvia/GoodFridayDayTest.php | 2 + tests/Latvia/InternationalWorkersDayTest.php | 2 + tests/Latvia/MidsummerEveDayTest.php | 2 + tests/Latvia/NewYearsDayTest.php | 2 + tests/Latvia/NewYearsEveDayTest.php | 2 + ...oclamationOfTheRepublicOfLatviaDayTest.php | 2 + .../RestorationOfIndependenceDayTest.php | 2 + tests/Latvia/SecondChristmasDayTest.php | 2 + tests/Latvia/StJohnsDayTest.php | 2 + tests/Lithuania/AllSaintsDayTest.php | 2 + tests/Lithuania/AssumptionOfMaryDayTest.php | 2 + tests/Lithuania/ChristmasDayTest.php | 2 + tests/Lithuania/ChristmasEveDayTest.php | 2 + tests/Lithuania/EasterDayTest.php | 2 + tests/Lithuania/EasterMondayDayTest.php | 2 + .../Lithuania/InternationalWorkersDayTest.php | 2 + tests/Lithuania/NewYearsDayTest.php | 2 + tests/Lithuania/SecondChristmasDayTest.php | 2 + tests/Lithuania/StJohnsDayTest.php | 2 + tests/Luxembourg/AllSaintsDayTest.php | 2 +- tests/Luxembourg/AssumptionOfMaryTest.php | 2 +- tests/Luxembourg/ChristmasDayTest.php | 2 +- .../InternationalWorkersDayTest.php | 2 +- tests/Luxembourg/NationalDayTest.php | 2 +- tests/Luxembourg/NewYearsDayTest.php | 2 +- tests/Luxembourg/SecondChristmasDayTest.php | 2 +- tests/Netherlands/ChristmasDayTest.php | 2 +- tests/Netherlands/EpiphanyTest.php | 2 +- tests/Netherlands/HalloweenTest.php | 2 +- .../InternationalWorkersDayTest.php | 2 +- tests/Netherlands/NewYearsDayTest.php | 2 +- tests/Netherlands/ValentinesDayTest.php | 2 +- tests/Netherlands/secondChristmasdayTest.php | 2 +- tests/Netherlands/stMartinsDayTest.php | 2 +- tests/Netherlands/stNicholasDayTest.php | 2 +- tests/NewZealand/AnzacDayTest.php | 2 +- tests/NewZealand/BoxingDayTest.php | 2 +- tests/NewZealand/ChristmasDayTest.php | 2 +- tests/NewZealand/DayAfterNewYearsDayTest.php | 2 +- tests/NewZealand/EasterMondayTest.php | 2 +- tests/NewZealand/GoodFridayTest.php | 2 +- tests/NewZealand/LabourDayTest.php | 2 +- tests/NewZealand/NewYearsDayTest.php | 2 +- tests/NewZealand/QueensBirthdayTest.php | 2 +- tests/NewZealand/WaitangiDayTest.php | 2 +- tests/Norway/ChristmasDayTest.php | 2 +- tests/Norway/InternationalWorkersDayTest.php | 2 +- tests/Norway/NewYearsDayTest.php | 2 +- tests/Norway/SecondChristmasDayTest.php | 2 +- tests/Poland/AllSaintsDayTest.php | 2 +- tests/Poland/AssumptionOfMaryTest.php | 2 +- tests/Poland/ChristmasTest.php | 2 +- tests/Poland/EpiphanyTest.php | 2 +- tests/Poland/InternationalWorkersDayTest.php | 2 +- tests/Poland/NewYearsDayTest.php | 2 +- tests/Poland/SecondChristmasDayTest.php | 2 +- tests/Portugal/AssumptionOfMaryTest.php | 2 +- tests/Portugal/ChristmasTest.php | 2 +- tests/Portugal/ImmaculateConceptionTest.php | 2 +- .../Portugal/InternationalWorkersDayTest.php | 2 +- tests/Portugal/NewYearsDayTest.php | 2 +- tests/Portugal/PortugueseRepublicDayTest.php | 3 ++ tests/Romania/ChristmasDayTest.php | 2 +- tests/Romania/DayAfterNewYearsDayTest.php | 2 +- tests/Romania/InternationalWorkersDayTest.php | 2 +- tests/Romania/NewYearsDayTest.php | 2 +- tests/Romania/SecondChristmasDayTest.php | 2 +- tests/Russia/InternationalWomensDayTest.php | 2 + tests/Russia/NewYearHolidaysDay2Test.php | 2 + tests/Russia/NewYearHolidaysDay3Test.php | 2 + tests/Russia/NewYearHolidaysDay4Test.php | 2 + tests/Russia/NewYearHolidaysDay5Test.php | 2 + tests/Russia/NewYearHolidaysDay6Test.php | 2 + tests/Russia/NewYearHolidaysDay8Test.php | 2 + tests/Russia/NewYearsDayTest.php | 2 + tests/Russia/OrthodoxChristmasDayTest.php | 2 + tests/Russia/SpringAndLabourDayTest.php | 2 + tests/Russia/VictoryDayTest.php | 2 + tests/Slovakia/AllSaintsDayTest.php | 2 +- tests/Slovakia/ChristmasDayTest.php | 2 +- tests/Slovakia/ChristmasEveTest.php | 2 +- tests/Slovakia/EasterMondayTest.php | 2 +- tests/Slovakia/EpiphanyTest.php | 2 +- tests/Slovakia/GoodFridayTest.php | 2 +- .../Slovakia/InternationalWorkersDayTest.php | 2 +- tests/Slovakia/OurLadyOfSorrowsDayTest.php | 2 +- .../SaintsCyrilAndMethodiusDayTest.php | 2 +- tests/Slovakia/SecondChristmasDayTest.php | 2 +- tests/Slovakia/SlovakConstitutionDayTest.php | 2 +- tests/Slovakia/SlovakIndependeceDayTest.php | 2 +- .../SlovakNationalUprisingDayTest.php | 2 +- .../StruggleForFreedomAndDemocracyDayTest.php | 2 +- tests/Slovakia/VictoryInEuropeDayTest.php | 2 +- tests/SouthAfrica/ChristmasDayTest.php | 2 +- tests/SouthAfrica/FamilyDayTest.php | 2 +- tests/SouthAfrica/FreedomDayTest.php | 2 +- tests/SouthAfrica/GoodFridayTest.php | 2 +- tests/SouthAfrica/HeritageDayTest.php | 2 +- tests/SouthAfrica/HumanRightsDayTest.php | 2 +- tests/SouthAfrica/NationalWomensDayTest.php | 2 +- tests/SouthAfrica/NewYearsDayTest.php | 2 +- tests/SouthAfrica/ReconciliationDayTest.php | 2 +- tests/SouthAfrica/SecondChristmasDayTest.php | 2 +- tests/SouthAfrica/WorkersDayTest.php | 2 +- tests/SouthAfrica/YouthDayTest.php | 2 +- tests/Spain/AllSaintsDayTest.php | 2 +- tests/Spain/AssumptionOfMaryTest.php | 2 +- tests/Spain/Catalonia/stJohnsDayTest.php | 2 +- tests/Spain/ChristmasTest.php | 2 +- tests/Spain/EpiphanyTest.php | 2 +- tests/Spain/ImmaculateConceptionTest.php | 2 +- tests/Spain/InternationalWorkersDayTest.php | 2 +- tests/Spain/NewYearsDayTest.php | 2 +- tests/Spain/ValentinesDayTest.php | 2 +- tests/Spain/stJosephsDayTest.php | 2 +- tests/Sweden/AllSaintsDayTest.php | 2 +- tests/Sweden/AllSaintsEveTest.php | 2 +- tests/Sweden/ChristmasDayTest.php | 2 +- tests/Sweden/ChristmasEveTest.php | 2 +- tests/Sweden/EpiphanyEveTest.php | 2 +- tests/Sweden/EpiphanyTest.php | 2 +- tests/Sweden/InternationalWorkersDayTest.php | 2 +- tests/Sweden/NewYearsDayTest.php | 2 +- tests/Sweden/NewYearsEveTest.php | 2 +- tests/Sweden/SecondChristmasDayTest.php | 2 +- tests/Sweden/WalpurgisEveTest.php | 2 +- tests/Switzerland/Aargau/ChristmasDayTest.php | 2 +- tests/Switzerland/Aargau/NewYearsDayTest.php | 2 +- .../ChristmasDayTest.php | 2 +- .../AppenzellAusserrhoden/NewYearsDayTest.php | 2 +- .../StStephensDayTest.php | 2 +- .../AppenzellInnerrhoden/AllSaintsDayTest.php | 2 +- .../AssumptionOfMaryTest.php | 2 +- .../AppenzellInnerrhoden/ChristmasDayTest.php | 2 +- .../ImmaculateConceptionTest.php | 2 +- .../AppenzellInnerrhoden/NewYearsDayTest.php | 2 +- .../StStephensDayTest.php | 2 +- .../BaselLandschaft/ChristmasDayTest.php | 2 +- .../BaselLandschaft/NewYearsDayTest.php | 2 +- .../BaselLandschaft/StStephensDayTest.php | 2 +- .../BaselLandschaft/WorkersDayTest.php | 2 +- .../BaselStadt/ChristmasDayTest.php | 2 +- .../BaselStadt/NewYearsDayTest.php | 2 +- .../BaselStadt/StStephensDayTest.php | 2 +- .../Switzerland/BaselStadt/WorkersDayTest.php | 2 +- tests/Switzerland/Bern/ChristmasDayTest.php | 2 +- tests/Switzerland/Bern/NewYearsDayTest.php | 2 +- tests/Switzerland/Bern/StStephensDayTest.php | 2 +- .../Switzerland/Fribourg/AllSaintsDayTest.php | 2 +- .../Fribourg/AssumptionOfMaryTest.php | 2 +- .../Switzerland/Fribourg/ChristmasDayTest.php | 2 +- .../Fribourg/ImmaculateConceptionTest.php | 2 +- .../Switzerland/Fribourg/NewYearsDayTest.php | 2 +- tests/Switzerland/Geneva/ChristmasDayTest.php | 2 +- tests/Switzerland/Geneva/NewYearsDayTest.php | 2 +- tests/Switzerland/Glarus/AllSaintsDayTest.php | 2 +- tests/Switzerland/Glarus/ChristmasDayTest.php | 2 +- tests/Switzerland/Glarus/NewYearsDayTest.php | 2 +- .../Switzerland/Glarus/StStephensDayTest.php | 2 +- .../Switzerland/Grisons/ChristmasDayTest.php | 2 +- tests/Switzerland/Grisons/NewYearsDayTest.php | 2 +- .../Switzerland/Grisons/StStephensDayTest.php | 2 +- tests/Switzerland/Jura/AllSaintsDayTest.php | 2 +- .../Switzerland/Jura/AssumptionOfMaryTest.php | 2 +- tests/Switzerland/Jura/ChristmasDayTest.php | 2 +- tests/Switzerland/Jura/NewYearsDayTest.php | 2 +- tests/Switzerland/Jura/WorkersDayTest.php | 2 +- .../Switzerland/Lucerne/AllSaintsDayTest.php | 2 +- .../Lucerne/AssumptionOfMaryTest.php | 2 +- .../Switzerland/Lucerne/ChristmasDayTest.php | 2 +- .../Lucerne/ImmaculateConceptionTest.php | 2 +- tests/Switzerland/Lucerne/NewYearsDayTest.php | 2 +- .../Switzerland/Lucerne/StStephensDayTest.php | 2 +- .../Neuchatel/ChristmasDayTest.php | 2 +- .../Switzerland/Neuchatel/NewYearsDayTest.php | 2 +- .../Switzerland/Neuchatel/WorkersDayTest.php | 2 +- .../Nidwalden/AllSaintsDayTest.php | 2 +- .../Nidwalden/AssumptionOfMaryTest.php | 2 +- .../Nidwalden/ChristmasDayTest.php | 2 +- .../Nidwalden/ImmaculateConceptionTest.php | 2 +- .../Switzerland/Nidwalden/NewYearsDayTest.php | 2 +- .../Switzerland/Nidwalden/StJosephDayTest.php | 2 +- .../Nidwalden/StStephensDayTest.php | 2 +- .../Switzerland/Obwalden/AllSaintsDayTest.php | 2 +- .../Obwalden/AssumptionOfMaryTest.php | 2 +- .../Switzerland/Obwalden/ChristmasDayTest.php | 2 +- .../Obwalden/ImmaculateConceptionTest.php | 2 +- .../Switzerland/Obwalden/NewYearsDayTest.php | 2 +- .../Obwalden/StStephensDayTest.php | 2 +- .../Schaffhausen/ChristmasDayTest.php | 2 +- .../Schaffhausen/NewYearsDayTest.php | 2 +- .../Schaffhausen/StStephensDayTest.php | 2 +- .../Schaffhausen/WorkersDayTest.php | 2 +- tests/Switzerland/Schwyz/AllSaintsDayTest.php | 2 +- .../Schwyz/AssumptionOfMaryTest.php | 2 +- tests/Switzerland/Schwyz/ChristmasDayTest.php | 2 +- tests/Switzerland/Schwyz/EpiphanyTest.php | 2 +- .../Schwyz/ImmaculateConceptionTest.php | 2 +- tests/Switzerland/Schwyz/NewYearsDayTest.php | 2 +- tests/Switzerland/Schwyz/StJosephDayTest.php | 2 +- .../Switzerland/Schwyz/StStephensDayTest.php | 2 +- .../Solothurn/ChristmasDayTest.php | 2 +- .../Switzerland/Solothurn/NewYearsDayTest.php | 2 +- .../Switzerland/StGallen/AllSaintsDayTest.php | 2 +- .../Switzerland/StGallen/ChristmasDayTest.php | 2 +- .../Switzerland/StGallen/NewYearsDayTest.php | 2 +- .../StGallen/StStephensDayTest.php | 2 +- .../Switzerland/Thurgau/ChristmasDayTest.php | 2 +- tests/Switzerland/Thurgau/NewYearsDayTest.php | 2 +- .../Switzerland/Thurgau/StStephensDayTest.php | 2 +- tests/Switzerland/Thurgau/WorkersDayTest.php | 2 +- tests/Switzerland/Ticino/AllSaintsDayTest.php | 2 +- .../Ticino/AssumptionOfMaryTest.php | 2 +- tests/Switzerland/Ticino/ChristmasDayTest.php | 2 +- tests/Switzerland/Ticino/EpiphanyTest.php | 2 +- .../Ticino/ImmaculateConceptionTest.php | 2 +- tests/Switzerland/Ticino/NewYearsDayTest.php | 2 +- tests/Switzerland/Ticino/StJosephDayTest.php | 2 +- tests/Switzerland/Ticino/StPeterPaulTest.php | 2 +- .../Switzerland/Ticino/StStephensDayTest.php | 2 +- tests/Switzerland/Ticino/WorkersDayTest.php | 2 +- tests/Switzerland/Uri/AllSaintsDayTest.php | 2 +- .../Switzerland/Uri/AssumptionOfMaryTest.php | 2 +- tests/Switzerland/Uri/ChristmasDayTest.php | 2 +- tests/Switzerland/Uri/EpiphanyTest.php | 2 +- .../Uri/ImmaculateConceptionTest.php | 2 +- tests/Switzerland/Uri/NewYearsDayTest.php | 2 +- tests/Switzerland/Uri/StJosephDayTest.php | 2 +- tests/Switzerland/Uri/StStephensDayTest.php | 2 +- tests/Switzerland/Valais/AllSaintsDayTest.php | 2 +- .../Valais/AssumptionOfMaryTest.php | 2 +- tests/Switzerland/Valais/ChristmasDayTest.php | 2 +- .../Valais/ImmaculateConceptionTest.php | 2 +- tests/Switzerland/Valais/NewYearsDayTest.php | 2 +- tests/Switzerland/Valais/StJosephDayTest.php | 2 +- tests/Switzerland/Vaud/ChristmasDayTest.php | 2 +- tests/Switzerland/Vaud/NewYearsDayTest.php | 2 +- tests/Switzerland/Zug/AllSaintsDayTest.php | 2 +- .../Switzerland/Zug/AssumptionOfMaryTest.php | 2 +- tests/Switzerland/Zug/ChristmasDayTest.php | 2 +- .../Zug/ImmaculateConceptionTest.php | 2 +- tests/Switzerland/Zug/NewYearsDayTest.php | 2 +- tests/Switzerland/Zug/StStephensDayTest.php | 2 +- tests/Switzerland/Zurich/ChristmasDayTest.php | 2 +- tests/Switzerland/Zurich/NewYearsDayTest.php | 2 +- .../Switzerland/Zurich/StStephensDayTest.php | 2 +- tests/Switzerland/Zurich/WorkersDayTest.php | 2 +- tests/Turkey/LabourDayTest.php | 2 +- tests/Turkey/NewYearsDayTest.php | 2 +- tests/Ukraine/CatholicChristmasDayTest.php | 2 +- tests/Ukraine/ChristmasDayTest.php | 2 +- tests/Ukraine/InternationalWomensDayTest.php | 2 +- tests/Ukraine/InternationalWorkersDayTest.php | 2 +- tests/Ukraine/NewYearsDayTest.php | 2 +- .../SecondInternationalWorkersDayTest.php | 2 +- tests/Ukraine/VictoryDayTest.php | 2 +- tests/UnitedKingdom/BoxingDayTest.php | 2 +- tests/UnitedKingdom/ChristmasDayTest.php | 2 +- tests/UnitedKingdom/EasterMondayTest.php | 2 +- tests/UnitedKingdom/England/BoxingDayTest.php | 2 +- .../England/ChristmasDayTest.php | 2 +- .../England/EasterMondayTest.php | 2 +- .../UnitedKingdom/England/NewYearsDayTest.php | 2 +- tests/UnitedKingdom/NewYearsDayTest.php | 2 +- .../NorthernIreland/BattleOfTheBoyneTest.php | 2 +- .../NorthernIreland/BoxingDayTest.php | 2 +- .../NorthernIreland/ChristmasDayTest.php | 2 +- .../NorthernIreland/EasterMondayTest.php | 2 +- .../NorthernIreland/NewYearsDayTest.php | 2 +- .../NorthernIreland/StPatricksDayTest.php | 2 +- .../UnitedKingdom/Scotland/BoxingDayTest.php | 2 +- .../Scotland/ChristmasDayTest.php | 2 +- .../Scotland/NewYearsDayTest.php | 2 +- .../Scotland/SecondNewYearsDayTest.php | 2 +- .../Scotland/StAndrewsDayTest.php | 2 +- tests/UnitedKingdom/Wales/BoxingDayTest.php | 2 +- .../UnitedKingdom/Wales/ChristmasDayTest.php | 2 +- .../UnitedKingdom/Wales/EasterMondayTest.php | 2 +- tests/UnitedKingdom/Wales/NewYearsDayTest.php | 2 +- tests/YasumiBase.php | 42 +++++++++---------- 487 files changed, 564 insertions(+), 460 deletions(-) diff --git a/phpstan.neon.dist b/phpstan.neon.dist index 2faf82185..d5383d22d 100644 --- a/phpstan.neon.dist +++ b/phpstan.neon.dist @@ -2,6 +2,7 @@ parameters: level: 6 paths: - src + - tests ignoreErrors: - message: '#Comparison operation "<=" between [0-9]+ and int<[0-9]+, max> is always true.#' diff --git a/tests/Australia/AnzacDayTest.php b/tests/Australia/AnzacDayTest.php index 48bcd652e..429cb3c0d 100644 --- a/tests/Australia/AnzacDayTest.php +++ b/tests/Australia/AnzacDayTest.php @@ -70,7 +70,7 @@ public function testNotHoliday(): void /** * Returns a list of test dates. * - * @return array list of test dates for the holiday defined in this test + * @return array list of test dates for the holiday defined in this test */ public function HolidayDataProvider(): array { diff --git a/tests/Australia/AustraliaDayTest.php b/tests/Australia/AustraliaDayTest.php index 09ab06f8a..2461499c7 100644 --- a/tests/Australia/AustraliaDayTest.php +++ b/tests/Australia/AustraliaDayTest.php @@ -103,7 +103,7 @@ public function testHolidayType(): void /** * Returns a list of random test dates used for assertion of the holiday defined in this test. * - * @return array list of test dates for the holiday defined in this test + * @return array list of test dates for the holiday defined in this test * * @throws Exception */ @@ -115,7 +115,7 @@ public function HolidayDataProvider(): array /** * Returns a list of test dates. * - * @return array list of test dates for the holiday defined in this test + * @return array list of test dates for the holiday defined in this test */ public function SubstituteHolidayDataProvider(): array { diff --git a/tests/Australia/AustralianCapitalTerritory/CanberraDayTest.php b/tests/Australia/AustralianCapitalTerritory/CanberraDayTest.php index 1d997a368..2fa82fc2c 100644 --- a/tests/Australia/AustralianCapitalTerritory/CanberraDayTest.php +++ b/tests/Australia/AustralianCapitalTerritory/CanberraDayTest.php @@ -60,7 +60,7 @@ public function testHoliday(int $year, string $expected): void /** * Returns a list of test dates. * - * @return array list of test dates for the holiday defined in this test + * @return array list of test dates for the holiday defined in this test */ public function HolidayDataProvider(): array { diff --git a/tests/Australia/AustralianCapitalTerritory/EasterSaturdayTest.php b/tests/Australia/AustralianCapitalTerritory/EasterSaturdayTest.php index 26ca10416..103b15d7d 100644 --- a/tests/Australia/AustralianCapitalTerritory/EasterSaturdayTest.php +++ b/tests/Australia/AustralianCapitalTerritory/EasterSaturdayTest.php @@ -56,7 +56,7 @@ public function testHoliday(int $year, string $expected): void /** * Returns a list of test dates. * - * @return array list of test dates for the holiday defined in this test + * @return array list of test dates for the holiday defined in this test * * @throws Exception */ diff --git a/tests/Australia/AustralianCapitalTerritory/EasterSundayTest.php b/tests/Australia/AustralianCapitalTerritory/EasterSundayTest.php index fb73a78d9..6ac520c26 100644 --- a/tests/Australia/AustralianCapitalTerritory/EasterSundayTest.php +++ b/tests/Australia/AustralianCapitalTerritory/EasterSundayTest.php @@ -55,7 +55,7 @@ public function testHoliday(int $year, string $expected): void /** * Returns a list of test dates. * - * @return array list of test dates for the holiday defined in this test + * @return array list of test dates for the holiday defined in this test * * @throws Exception */ diff --git a/tests/Australia/AustralianCapitalTerritory/LabourDayTest.php b/tests/Australia/AustralianCapitalTerritory/LabourDayTest.php index 9bdd92a33..45393245b 100644 --- a/tests/Australia/AustralianCapitalTerritory/LabourDayTest.php +++ b/tests/Australia/AustralianCapitalTerritory/LabourDayTest.php @@ -55,7 +55,7 @@ public function testHoliday(int $year, string $expected): void /** * Returns a list of test dates. * - * @return array list of test dates for the holiday defined in this test + * @return array list of test dates for the holiday defined in this test */ public function HolidayDataProvider(): array { diff --git a/tests/Australia/AustralianCapitalTerritory/QueensBirthdayTest.php b/tests/Australia/AustralianCapitalTerritory/QueensBirthdayTest.php index f946e0c25..bc88b9d1d 100644 --- a/tests/Australia/AustralianCapitalTerritory/QueensBirthdayTest.php +++ b/tests/Australia/AustralianCapitalTerritory/QueensBirthdayTest.php @@ -60,7 +60,7 @@ public function testHoliday(int $year, string $expected): void /** * Returns a list of test dates. * - * @return array list of test dates for the holiday defined in this test + * @return array list of test dates for the holiday defined in this test */ public function HolidayDataProvider(): array { diff --git a/tests/Australia/AustralianCapitalTerritory/ReconciliationDayTest.php b/tests/Australia/AustralianCapitalTerritory/ReconciliationDayTest.php index 0b78f2ba2..b92043159 100644 --- a/tests/Australia/AustralianCapitalTerritory/ReconciliationDayTest.php +++ b/tests/Australia/AustralianCapitalTerritory/ReconciliationDayTest.php @@ -60,7 +60,7 @@ public function testHoliday(int $year, string $expected): void /** * Returns a list of test dates. * - * @return array list of test dates for the holiday defined in this test + * @return array list of test dates for the holiday defined in this test */ public function HolidayDataProvider(): array { diff --git a/tests/Australia/BoxingDayTest.php b/tests/Australia/BoxingDayTest.php index b04ed1771..85d5fe3d3 100644 --- a/tests/Australia/BoxingDayTest.php +++ b/tests/Australia/BoxingDayTest.php @@ -71,7 +71,7 @@ public function testHoliday(int $year, string $expected, ?string $expectedExtra) /** * Returns a list of test dates. * - * @return array list of test dates for the holiday defined in this test + * @return array list of test dates for the holiday defined in this test */ public function HolidayDataProvider(): array { diff --git a/tests/Australia/ChristmasDayTest.php b/tests/Australia/ChristmasDayTest.php index b5543624d..c03dbab0a 100644 --- a/tests/Australia/ChristmasDayTest.php +++ b/tests/Australia/ChristmasDayTest.php @@ -71,7 +71,7 @@ public function testHoliday(int $year, string $expected, ?string $expectedExtra) /** * Returns a list of test dates. * - * @return array list of test dates for the holiday defined in this test + * @return array list of test dates for the holiday defined in this test */ public function HolidayDataProvider(): array { diff --git a/tests/Australia/EasterMondayTest.php b/tests/Australia/EasterMondayTest.php index cb915f5f3..68fc8b0a1 100644 --- a/tests/Australia/EasterMondayTest.php +++ b/tests/Australia/EasterMondayTest.php @@ -78,7 +78,7 @@ public function testHoliday2(int $year, string $expected): void /** * Returns a list of test dates. * - * @return array list of test dates for the holiday defined in this test + * @return array list of test dates for the holiday defined in this test * * @throws Exception */ @@ -100,7 +100,7 @@ public function HolidayDataProvider(): array /** * Returns a list of test dates. * - * @return array list of test dates for the holiday defined in this test + * @return array list of test dates for the holiday defined in this test */ public function HolidayDataProvider2(): array { diff --git a/tests/Australia/GoodFridayTest.php b/tests/Australia/GoodFridayTest.php index fa61c14f9..2d586fba0 100644 --- a/tests/Australia/GoodFridayTest.php +++ b/tests/Australia/GoodFridayTest.php @@ -56,7 +56,7 @@ public function testHoliday(int $year, string $expected): void /** * Returns a list of test dates. * - * @return array list of test dates for the holiday defined in this test + * @return array list of test dates for the holiday defined in this test * * @throws Exception */ diff --git a/tests/Australia/NewSouthWales/BankHolidayTest.php b/tests/Australia/NewSouthWales/BankHolidayTest.php index c88ce413f..c9b74de45 100644 --- a/tests/Australia/NewSouthWales/BankHolidayTest.php +++ b/tests/Australia/NewSouthWales/BankHolidayTest.php @@ -55,7 +55,7 @@ public function testHoliday(int $year, string $expected): void /** * Returns a list of test dates. * - * @return array list of test dates for the holiday defined in this test + * @return array list of test dates for the holiday defined in this test */ public function HolidayDataProvider(): array { diff --git a/tests/Australia/NewSouthWales/EasterSaturdayTest.php b/tests/Australia/NewSouthWales/EasterSaturdayTest.php index 8886a4472..3e4c2ce89 100644 --- a/tests/Australia/NewSouthWales/EasterSaturdayTest.php +++ b/tests/Australia/NewSouthWales/EasterSaturdayTest.php @@ -56,7 +56,7 @@ public function testHoliday(int $year, string $expected): void /** * Returns a list of test dates. * - * @return array list of test dates for the holiday defined in this test + * @return array list of test dates for the holiday defined in this test * * @throws Exception */ diff --git a/tests/Australia/NewSouthWales/EasterSundayTest.php b/tests/Australia/NewSouthWales/EasterSundayTest.php index bd73133ec..94d833652 100644 --- a/tests/Australia/NewSouthWales/EasterSundayTest.php +++ b/tests/Australia/NewSouthWales/EasterSundayTest.php @@ -55,7 +55,7 @@ public function testHoliday(int $year, string $expected): void /** * Returns a list of test dates. * - * @return array list of test dates for the holiday defined in this test + * @return array list of test dates for the holiday defined in this test * * @throws Exception */ diff --git a/tests/Australia/NewSouthWales/LabourDayTest.php b/tests/Australia/NewSouthWales/LabourDayTest.php index 05951e516..1fab61ada 100644 --- a/tests/Australia/NewSouthWales/LabourDayTest.php +++ b/tests/Australia/NewSouthWales/LabourDayTest.php @@ -55,7 +55,7 @@ public function testHoliday(int $year, string $expected): void /** * Returns a list of test dates. * - * @return array list of test dates for the holiday defined in this test + * @return array list of test dates for the holiday defined in this test */ public function HolidayDataProvider(): array { diff --git a/tests/Australia/NewSouthWales/QueensBirthdayTest.php b/tests/Australia/NewSouthWales/QueensBirthdayTest.php index bbcf37040..cf7277beb 100644 --- a/tests/Australia/NewSouthWales/QueensBirthdayTest.php +++ b/tests/Australia/NewSouthWales/QueensBirthdayTest.php @@ -60,7 +60,7 @@ public function testHoliday(int $year, string $expected): void /** * Returns a list of test dates. * - * @return array list of test dates for the holiday defined in this test + * @return array list of test dates for the holiday defined in this test */ public function HolidayDataProvider(): array { diff --git a/tests/Australia/NewYearsDayTest.php b/tests/Australia/NewYearsDayTest.php index 4e1178d95..c0622cbb4 100644 --- a/tests/Australia/NewYearsDayTest.php +++ b/tests/Australia/NewYearsDayTest.php @@ -71,7 +71,7 @@ public function testHoliday(int $year, string $expected, ?string $expectedExtra) /** * Returns a list of test dates. * - * @return array list of test dates for the holiday defined in this test + * @return array list of test dates for the holiday defined in this test */ public function HolidayDataProvider(): array { diff --git a/tests/Australia/NorthernTerritory/EasterSaturdayTest.php b/tests/Australia/NorthernTerritory/EasterSaturdayTest.php index 9e9714a3e..da8294475 100644 --- a/tests/Australia/NorthernTerritory/EasterSaturdayTest.php +++ b/tests/Australia/NorthernTerritory/EasterSaturdayTest.php @@ -56,7 +56,7 @@ public function testHoliday(int $year, string $expected): void /** * Returns a list of test dates. * - * @return array list of test dates for the holiday defined in this test + * @return array list of test dates for the holiday defined in this test * * @throws Exception */ diff --git a/tests/Australia/NorthernTerritory/MayDayTest.php b/tests/Australia/NorthernTerritory/MayDayTest.php index ebabeaf41..1547cb287 100644 --- a/tests/Australia/NorthernTerritory/MayDayTest.php +++ b/tests/Australia/NorthernTerritory/MayDayTest.php @@ -55,7 +55,7 @@ public function testHoliday(int $year, string $expected): void /** * Returns a list of test dates. * - * @return array list of test dates for the holiday defined in this test + * @return array list of test dates for the holiday defined in this test */ public function HolidayDataProvider(): array { diff --git a/tests/Australia/NorthernTerritory/PicnicDayTest.php b/tests/Australia/NorthernTerritory/PicnicDayTest.php index 6ba24c77c..868c30ed2 100644 --- a/tests/Australia/NorthernTerritory/PicnicDayTest.php +++ b/tests/Australia/NorthernTerritory/PicnicDayTest.php @@ -55,7 +55,7 @@ public function testHoliday(int $year, string $expected): void /** * Returns a list of test dates. * - * @return array list of test dates for the holiday defined in this test + * @return array list of test dates for the holiday defined in this test */ public function HolidayDataProvider(): array { diff --git a/tests/Australia/NorthernTerritory/QueensBirthdayTest.php b/tests/Australia/NorthernTerritory/QueensBirthdayTest.php index e83294147..094742b5c 100644 --- a/tests/Australia/NorthernTerritory/QueensBirthdayTest.php +++ b/tests/Australia/NorthernTerritory/QueensBirthdayTest.php @@ -60,7 +60,7 @@ public function testHoliday(int $year, string $expected): void /** * Returns a list of test dates. * - * @return array list of test dates for the holiday defined in this test + * @return array list of test dates for the holiday defined in this test */ public function HolidayDataProvider(): array { diff --git a/tests/Australia/Queensland/Brisbane/PeoplesDayTest.php b/tests/Australia/Queensland/Brisbane/PeoplesDayTest.php index fa82eb1bf..3d9089eba 100644 --- a/tests/Australia/Queensland/Brisbane/PeoplesDayTest.php +++ b/tests/Australia/Queensland/Brisbane/PeoplesDayTest.php @@ -55,7 +55,7 @@ public function testHoliday(int $year, string $expected): void /** * Returns a list of test dates. * - * @return array list of test dates for the holiday defined in this test + * @return array list of test dates for the holiday defined in this test */ public function HolidayDataProvider(): array { diff --git a/tests/Australia/Queensland/LabourDayTest.php b/tests/Australia/Queensland/LabourDayTest.php index 7fd6e0679..9eddbda8c 100644 --- a/tests/Australia/Queensland/LabourDayTest.php +++ b/tests/Australia/Queensland/LabourDayTest.php @@ -55,7 +55,7 @@ public function testHoliday(int $year, string $expected): void /** * Returns a list of test dates. * - * @return array list of test dates for the holiday defined in this test + * @return array list of test dates for the holiday defined in this test */ public function HolidayDataProvider(): array { diff --git a/tests/Australia/Queensland/QueensBirthdayTest.php b/tests/Australia/Queensland/QueensBirthdayTest.php index d1ee1f7b0..199c7cef3 100644 --- a/tests/Australia/Queensland/QueensBirthdayTest.php +++ b/tests/Australia/Queensland/QueensBirthdayTest.php @@ -60,7 +60,7 @@ public function testHoliday(int $year, string $expected): void /** * Returns a list of test dates. * - * @return array list of test dates for the holiday defined in this test + * @return array list of test dates for the holiday defined in this test */ public function HolidayDataProvider(): array { diff --git a/tests/Australia/SouthAustralia/AdelaideCupDayTest.php b/tests/Australia/SouthAustralia/AdelaideCupDayTest.php index 8e84883dd..ca06dae3e 100644 --- a/tests/Australia/SouthAustralia/AdelaideCupDayTest.php +++ b/tests/Australia/SouthAustralia/AdelaideCupDayTest.php @@ -60,7 +60,7 @@ public function testHoliday(int $year, string $expected): void /** * Returns a list of test dates. * - * @return array list of test dates for the holiday defined in this test + * @return array list of test dates for the holiday defined in this test */ public function HolidayDataProvider(): array { diff --git a/tests/Australia/SouthAustralia/ChristmasDayTest.php b/tests/Australia/SouthAustralia/ChristmasDayTest.php index 261d6992f..901f77531 100644 --- a/tests/Australia/SouthAustralia/ChristmasDayTest.php +++ b/tests/Australia/SouthAustralia/ChristmasDayTest.php @@ -71,7 +71,7 @@ public function testHoliday(int $year, string $expected, ?string $expectedExtra) /** * Returns a list of test dates. * - * @return array list of test dates for the holiday defined in this test + * @return array list of test dates for the holiday defined in this test */ public function HolidayDataProvider(): array { diff --git a/tests/Australia/SouthAustralia/EasterSaturdayTest.php b/tests/Australia/SouthAustralia/EasterSaturdayTest.php index 1d5af8746..be452f2c6 100644 --- a/tests/Australia/SouthAustralia/EasterSaturdayTest.php +++ b/tests/Australia/SouthAustralia/EasterSaturdayTest.php @@ -56,7 +56,7 @@ public function testHoliday(int $year, string $expected): void /** * Returns a list of test dates. * - * @return array list of test dates for the holiday defined in this test + * @return array list of test dates for the holiday defined in this test * * @throws Exception */ diff --git a/tests/Australia/SouthAustralia/LabourDayTest.php b/tests/Australia/SouthAustralia/LabourDayTest.php index 73f7f8db0..4562a36b6 100644 --- a/tests/Australia/SouthAustralia/LabourDayTest.php +++ b/tests/Australia/SouthAustralia/LabourDayTest.php @@ -55,7 +55,7 @@ public function testHoliday(int $year, string $expected): void /** * Returns a list of test dates. * - * @return array list of test dates for the holiday defined in this test + * @return array list of test dates for the holiday defined in this test */ public function HolidayDataProvider(): array { diff --git a/tests/Australia/SouthAustralia/ProclamationDayTest.php b/tests/Australia/SouthAustralia/ProclamationDayTest.php index 77a849a05..b31eb4de1 100644 --- a/tests/Australia/SouthAustralia/ProclamationDayTest.php +++ b/tests/Australia/SouthAustralia/ProclamationDayTest.php @@ -55,7 +55,7 @@ public function testHoliday(int $year, string $expected): void /** * Returns a list of test dates. * - * @return array list of test dates for the holiday defined in this test + * @return array list of test dates for the holiday defined in this test */ public function HolidayDataProvider(): array { diff --git a/tests/Australia/SouthAustralia/QueensBirthdayTest.php b/tests/Australia/SouthAustralia/QueensBirthdayTest.php index 8a83852f4..9db861703 100644 --- a/tests/Australia/SouthAustralia/QueensBirthdayTest.php +++ b/tests/Australia/SouthAustralia/QueensBirthdayTest.php @@ -60,7 +60,7 @@ public function testHoliday(int $year, string $expected): void /** * Returns a list of test dates. * - * @return array list of test dates for the holiday defined in this test + * @return array list of test dates for the holiday defined in this test */ public function HolidayDataProvider(): array { diff --git a/tests/Australia/Tasmania/CentralNorth/DevonportShowTest.php b/tests/Australia/Tasmania/CentralNorth/DevonportShowTest.php index bd8ac6842..461adfc2d 100644 --- a/tests/Australia/Tasmania/CentralNorth/DevonportShowTest.php +++ b/tests/Australia/Tasmania/CentralNorth/DevonportShowTest.php @@ -55,7 +55,7 @@ public function testHoliday(int $year, string $expected): void /** * Returns a list of test dates. * - * @return array list of test dates for the holiday defined in this test + * @return array list of test dates for the holiday defined in this test */ public function HolidayDataProvider(): array { diff --git a/tests/Australia/Tasmania/EightHourDayTest.php b/tests/Australia/Tasmania/EightHourDayTest.php index 5f93bc5a5..e56d0fcc8 100644 --- a/tests/Australia/Tasmania/EightHourDayTest.php +++ b/tests/Australia/Tasmania/EightHourDayTest.php @@ -55,7 +55,7 @@ public function testHoliday(int $year, string $expected): void /** * Returns a list of test dates. * - * @return array list of test dates for the holiday defined in this test + * @return array list of test dates for the holiday defined in this test */ public function HolidayDataProvider(): array { diff --git a/tests/Australia/Tasmania/FlindersIsland/FlindersIslandShowTest.php b/tests/Australia/Tasmania/FlindersIsland/FlindersIslandShowTest.php index 5ded66c62..b33fcc1e0 100644 --- a/tests/Australia/Tasmania/FlindersIsland/FlindersIslandShowTest.php +++ b/tests/Australia/Tasmania/FlindersIsland/FlindersIslandShowTest.php @@ -55,7 +55,7 @@ public function testHoliday(int $year, string $expected): void /** * Returns a list of test dates. * - * @return array list of test dates for the holiday defined in this test + * @return array list of test dates for the holiday defined in this test */ public function HolidayDataProvider(): array { diff --git a/tests/Australia/Tasmania/KingIsland/KingIslandShowTest.php b/tests/Australia/Tasmania/KingIsland/KingIslandShowTest.php index 73a007b2e..943a95dd9 100644 --- a/tests/Australia/Tasmania/KingIsland/KingIslandShowTest.php +++ b/tests/Australia/Tasmania/KingIsland/KingIslandShowTest.php @@ -55,7 +55,7 @@ public function testHoliday(int $year, string $expected): void /** * Returns a list of test dates. * - * @return array list of test dates for the holiday defined in this test + * @return array list of test dates for the holiday defined in this test */ public function HolidayDataProvider(): array { diff --git a/tests/Australia/Tasmania/Northeast/LauncestonShowTest.php b/tests/Australia/Tasmania/Northeast/LauncestonShowTest.php index 936f9f5ec..aba05fe83 100644 --- a/tests/Australia/Tasmania/Northeast/LauncestonShowTest.php +++ b/tests/Australia/Tasmania/Northeast/LauncestonShowTest.php @@ -55,7 +55,7 @@ public function testHoliday(int $year, string $expected): void /** * Returns a list of test dates. * - * @return array list of test dates for the holiday defined in this test + * @return array list of test dates for the holiday defined in this test */ public function HolidayDataProvider(): array { diff --git a/tests/Australia/Tasmania/Northwest/BurnieShowTest.php b/tests/Australia/Tasmania/Northwest/BurnieShowTest.php index 132827b39..527785c2a 100644 --- a/tests/Australia/Tasmania/Northwest/BurnieShowTest.php +++ b/tests/Australia/Tasmania/Northwest/BurnieShowTest.php @@ -55,7 +55,7 @@ public function testHoliday(int $year, string $expected): void /** * Returns a list of test dates. * - * @return array list of test dates for the holiday defined in this test + * @return array list of test dates for the holiday defined in this test */ public function HolidayDataProvider(): array { diff --git a/tests/Australia/Tasmania/Northwest/CircularHead/AGFESTTest.php b/tests/Australia/Tasmania/Northwest/CircularHead/AGFESTTest.php index 8aab4c5cd..e723744ae 100644 --- a/tests/Australia/Tasmania/Northwest/CircularHead/AGFESTTest.php +++ b/tests/Australia/Tasmania/Northwest/CircularHead/AGFESTTest.php @@ -55,7 +55,7 @@ public function testHoliday(int $year, string $expected): void /** * Returns a list of test dates. * - * @return array list of test dates for the holiday defined in this test + * @return array list of test dates for the holiday defined in this test */ public function HolidayDataProvider(): array { diff --git a/tests/Australia/Tasmania/QueensBirthdayTest.php b/tests/Australia/Tasmania/QueensBirthdayTest.php index e6672897d..ca6f4a709 100644 --- a/tests/Australia/Tasmania/QueensBirthdayTest.php +++ b/tests/Australia/Tasmania/QueensBirthdayTest.php @@ -60,7 +60,7 @@ public function testHoliday(int $year, string $expected): void /** * Returns a list of test dates. * - * @return array list of test dates for the holiday defined in this test + * @return array list of test dates for the holiday defined in this test */ public function HolidayDataProvider(): array { diff --git a/tests/Australia/Tasmania/RecreationDayTest.php b/tests/Australia/Tasmania/RecreationDayTest.php index f6fbe4441..ded75ec5a 100644 --- a/tests/Australia/Tasmania/RecreationDayTest.php +++ b/tests/Australia/Tasmania/RecreationDayTest.php @@ -55,7 +55,7 @@ public function testHoliday(int $year, string $expected): void /** * Returns a list of test dates. * - * @return array list of test dates for the holiday defined in this test + * @return array list of test dates for the holiday defined in this test */ public function HolidayDataProvider(): array { diff --git a/tests/Australia/Tasmania/South/HobartShowTest.php b/tests/Australia/Tasmania/South/HobartShowTest.php index 233d65a15..d2b4bde9b 100644 --- a/tests/Australia/Tasmania/South/HobartShowTest.php +++ b/tests/Australia/Tasmania/South/HobartShowTest.php @@ -55,7 +55,7 @@ public function testHoliday(int $year, string $expected): void /** * Returns a list of test dates. * - * @return array list of test dates for the holiday defined in this test + * @return array list of test dates for the holiday defined in this test */ public function HolidayDataProvider(): array { diff --git a/tests/Australia/Tasmania/South/Southeast/HobartRegattaTest.php b/tests/Australia/Tasmania/South/Southeast/HobartRegattaTest.php index 5da6997a7..ed8ac69c3 100644 --- a/tests/Australia/Tasmania/South/Southeast/HobartRegattaTest.php +++ b/tests/Australia/Tasmania/South/Southeast/HobartRegattaTest.php @@ -55,7 +55,7 @@ public function testHoliday(int $year, string $expected): void /** * Returns a list of test dates. * - * @return array list of test dates for the holiday defined in this test + * @return array list of test dates for the holiday defined in this test */ public function HolidayDataProvider(): array { diff --git a/tests/Australia/Victoria/AFLGrandFinalFridayTest.php b/tests/Australia/Victoria/AFLGrandFinalFridayTest.php index 4ca20039e..2fdceaca2 100644 --- a/tests/Australia/Victoria/AFLGrandFinalFridayTest.php +++ b/tests/Australia/Victoria/AFLGrandFinalFridayTest.php @@ -98,7 +98,7 @@ public function testNotHoliday(): void /** * Returns a list of test dates. * - * @return array list of test dates for the holiday defined in this test + * @return array list of test dates for the holiday defined in this test */ public function HolidayDataProvider(): array { diff --git a/tests/Australia/Victoria/EasterSaturdayTest.php b/tests/Australia/Victoria/EasterSaturdayTest.php index 84c3ecc2b..7c24a3ca9 100644 --- a/tests/Australia/Victoria/EasterSaturdayTest.php +++ b/tests/Australia/Victoria/EasterSaturdayTest.php @@ -56,7 +56,7 @@ public function testHoliday(int $year, string $expected): void /** * Returns a list of test dates. * - * @return array list of test dates for the holiday defined in this test + * @return array list of test dates for the holiday defined in this test * * @throws Exception */ diff --git a/tests/Australia/Victoria/EasterSundayTest.php b/tests/Australia/Victoria/EasterSundayTest.php index 1ebe813a6..33ed6cec3 100644 --- a/tests/Australia/Victoria/EasterSundayTest.php +++ b/tests/Australia/Victoria/EasterSundayTest.php @@ -55,7 +55,7 @@ public function testHoliday(int $year, string $expected): void /** * Returns a list of test dates. * - * @return array list of test dates for the holiday defined in this test + * @return array list of test dates for the holiday defined in this test * * @throws Exception */ diff --git a/tests/Australia/Victoria/LabourDayTest.php b/tests/Australia/Victoria/LabourDayTest.php index 390eb8bf2..0bb0b40e6 100644 --- a/tests/Australia/Victoria/LabourDayTest.php +++ b/tests/Australia/Victoria/LabourDayTest.php @@ -55,7 +55,7 @@ public function testHoliday(int $year, string $expected): void /** * Returns a list of test dates. * - * @return array list of test dates for the holiday defined in this test + * @return array list of test dates for the holiday defined in this test */ public function HolidayDataProvider(): array { diff --git a/tests/Australia/Victoria/MelbourneCupDayTest.php b/tests/Australia/Victoria/MelbourneCupDayTest.php index a7b166f35..130864c8a 100644 --- a/tests/Australia/Victoria/MelbourneCupDayTest.php +++ b/tests/Australia/Victoria/MelbourneCupDayTest.php @@ -60,7 +60,7 @@ public function testHoliday(int $year, string $expected): void /** * Returns a list of test dates. * - * @return array list of test dates for the holiday defined in this test + * @return array list of test dates for the holiday defined in this test */ public function HolidayDataProvider(): array { diff --git a/tests/Australia/Victoria/QueensBirthdayTest.php b/tests/Australia/Victoria/QueensBirthdayTest.php index 11b6cd7aa..e56c77223 100644 --- a/tests/Australia/Victoria/QueensBirthdayTest.php +++ b/tests/Australia/Victoria/QueensBirthdayTest.php @@ -60,7 +60,7 @@ public function testHoliday(int $year, string $expected): void /** * Returns a list of test dates. * - * @return array list of test dates for the holiday defined in this test + * @return array list of test dates for the holiday defined in this test */ public function HolidayDataProvider(): array { diff --git a/tests/Australia/WesternAustralia/LabourDayTest.php b/tests/Australia/WesternAustralia/LabourDayTest.php index 153179d63..9422ab63d 100644 --- a/tests/Australia/WesternAustralia/LabourDayTest.php +++ b/tests/Australia/WesternAustralia/LabourDayTest.php @@ -55,7 +55,7 @@ public function testHoliday(int $year, string $expected): void /** * Returns a list of test dates. * - * @return array list of test dates for the holiday defined in this test + * @return array list of test dates for the holiday defined in this test */ public function HolidayDataProvider(): array { diff --git a/tests/Australia/WesternAustralia/QueensBirthdayTest.php b/tests/Australia/WesternAustralia/QueensBirthdayTest.php index a3f2c79aa..aa50f3a85 100644 --- a/tests/Australia/WesternAustralia/QueensBirthdayTest.php +++ b/tests/Australia/WesternAustralia/QueensBirthdayTest.php @@ -60,7 +60,7 @@ public function testHoliday(int $year, string $expected): void /** * Returns a list of test dates. * - * @return array list of test dates for the holiday defined in this test + * @return array list of test dates for the holiday defined in this test */ public function HolidayDataProvider(): array { diff --git a/tests/Australia/WesternAustralia/WesternAustraliaDayTest.php b/tests/Australia/WesternAustralia/WesternAustraliaDayTest.php index 2c7fded4c..a58c0e515 100644 --- a/tests/Australia/WesternAustralia/WesternAustraliaDayTest.php +++ b/tests/Australia/WesternAustralia/WesternAustraliaDayTest.php @@ -55,7 +55,7 @@ public function testHoliday(int $year, string $expected): void /** * Returns a list of test dates. * - * @return array list of test dates for the holiday defined in this test + * @return array list of test dates for the holiday defined in this test */ public function HolidayDataProvider(): array { diff --git a/tests/Austria/AllSaintsDayTest.php b/tests/Austria/AllSaintsDayTest.php index 13579e2ee..e8032d2a0 100644 --- a/tests/Austria/AllSaintsDayTest.php +++ b/tests/Austria/AllSaintsDayTest.php @@ -48,7 +48,7 @@ public function testHoliday(int $year, DateTime $expected): void /** * Returns a list of random test dates used for assertion of the holiday defined in this test. * - * @return array list of test dates for the holiday defined in this test + * @return array list of test dates for the holiday defined in this test * * @throws Exception */ diff --git a/tests/Austria/AssumptionOfMaryTest.php b/tests/Austria/AssumptionOfMaryTest.php index 6e30aac47..c31d8569c 100644 --- a/tests/Austria/AssumptionOfMaryTest.php +++ b/tests/Austria/AssumptionOfMaryTest.php @@ -48,7 +48,7 @@ public function testHoliday(int $year, DateTime $expected): void /** * Returns a list of random test dates used for assertion of the holiday defined in this test. * - * @return array list of test dates for the day of the holiday defined in this test + * @return array list of test dates for the holiday defined in this test * * @throws Exception */ diff --git a/tests/Austria/Burgenland/stMartinsDayTest.php b/tests/Austria/Burgenland/stMartinsDayTest.php index 72bd26a27..0bb8ce04c 100644 --- a/tests/Austria/Burgenland/stMartinsDayTest.php +++ b/tests/Austria/Burgenland/stMartinsDayTest.php @@ -48,7 +48,7 @@ public function teststMartinsDay(int $year, DateTime $expected): void /** * Returns a list of random test dates used for assertion of Saint Martins Day. * - * @return array list of test dates for Saint Martins Day + * @return array list of test dates for Saint Martins Day * * @throws Exception */ diff --git a/tests/Austria/Carinthia/PlebisciteDayTest.php b/tests/Austria/Carinthia/PlebisciteDayTest.php index 4241d288a..ea0bda51c 100644 --- a/tests/Austria/Carinthia/PlebisciteDayTest.php +++ b/tests/Austria/Carinthia/PlebisciteDayTest.php @@ -54,7 +54,7 @@ public function testPlebisciteDay(int $year, DateTime $expected): void /** * Returns a list of random test dates used for assertion of Plebiscite Day. * - * @return array list of test dates for Plebiscite Day + * @return array list of test dates for Plebiscite Day * * @throws Exception */ diff --git a/tests/Austria/Carinthia/StJosephsDayTest.php b/tests/Austria/Carinthia/StJosephsDayTest.php index 1ac72f817..6504849f7 100644 --- a/tests/Austria/Carinthia/StJosephsDayTest.php +++ b/tests/Austria/Carinthia/StJosephsDayTest.php @@ -48,7 +48,7 @@ public function testStJosephsDay(int $year, DateTime $expected): void /** * Returns a list of random test dates used for assertion of St. Joseph's Day. * - * @return array list of test dates for St. Joseph's Day. + * @return array list of test dates for St. Joseph's Day. * * @throws Exception */ diff --git a/tests/Austria/ChristmasTest.php b/tests/Austria/ChristmasTest.php index 7c243fd5f..10c5eae0e 100644 --- a/tests/Austria/ChristmasTest.php +++ b/tests/Austria/ChristmasTest.php @@ -48,7 +48,7 @@ public function testHoliday(int $year, DateTime $expected): void /** * Returns a list of random test dates used for assertion of the holiday defined in this test. * - * @return array list of test dates for the holiday defined in this test + * @return array list of test dates for the holiday defined in this test * * @throws Exception */ diff --git a/tests/Austria/EpiphanyTest.php b/tests/Austria/EpiphanyTest.php index 28bc7b759..911541038 100644 --- a/tests/Austria/EpiphanyTest.php +++ b/tests/Austria/EpiphanyTest.php @@ -48,7 +48,7 @@ public function testHoliday(int $year, DateTime $expected): void /** * Returns a list of random test dates used for assertion of the holiday defined in this test. * - * @return array list of test dates for the day of the holiday defined in this test + * @return array list of test dates for the holiday defined in this test * * @throws Exception */ diff --git a/tests/Austria/ImmaculateConceptionTest.php b/tests/Austria/ImmaculateConceptionTest.php index 15c4e12cd..e508ecb96 100644 --- a/tests/Austria/ImmaculateConceptionTest.php +++ b/tests/Austria/ImmaculateConceptionTest.php @@ -48,7 +48,7 @@ public function testHoliday(int $year, DateTime $expected): void /** * Returns a list of random test dates used for assertion of the holiday defined in this test. * - * @return array list of test dates for the day of the holiday defined in this test + * @return array list of test dates for the holiday defined in this test * * @throws Exception */ diff --git a/tests/Austria/InternationalWorkersDayTest.php b/tests/Austria/InternationalWorkersDayTest.php index b3da186d9..771d48d4f 100644 --- a/tests/Austria/InternationalWorkersDayTest.php +++ b/tests/Austria/InternationalWorkersDayTest.php @@ -48,7 +48,7 @@ public function testHoliday(int $year, DateTime $expected): void /** * Returns a list of random test dates used for assertion of the holiday defined in this test. * - * @return array list of test dates for the day of the holiday defined in this test + * @return array list of test dates for the holiday defined in this test * * @throws Exception */ diff --git a/tests/Austria/LowerAustria/StLeopoldsDayTest.php b/tests/Austria/LowerAustria/StLeopoldsDayTest.php index 39bea4a69..5436b7c84 100644 --- a/tests/Austria/LowerAustria/StLeopoldsDayTest.php +++ b/tests/Austria/LowerAustria/StLeopoldsDayTest.php @@ -54,7 +54,7 @@ public function testStLeopoldsDay(int $year, DateTime $expected): void /** * Returns a list of random test dates used for assertion of Saint Leopold's Day. * - * @return array list of test dates for Saint Leopold's Day + * @return array list of test dates for Saint Leopold's Day * * @throws Exception */ diff --git a/tests/Austria/NewYearsDayTest.php b/tests/Austria/NewYearsDayTest.php index 65c2111f1..79e578fe2 100644 --- a/tests/Austria/NewYearsDayTest.php +++ b/tests/Austria/NewYearsDayTest.php @@ -48,7 +48,7 @@ public function testHoliday(int $year, DateTime $expected): void /** * Returns a list of random test dates used for assertion of the holiday defined in this test. * - * @return array list of test dates for the holiday defined in this test + * @return array list of test dates for the holiday defined in this test * * @throws Exception */ diff --git a/tests/Austria/Salzburg/StRupertsDayTest.php b/tests/Austria/Salzburg/StRupertsDayTest.php index ce32e822c..b723e0a1b 100644 --- a/tests/Austria/Salzburg/StRupertsDayTest.php +++ b/tests/Austria/Salzburg/StRupertsDayTest.php @@ -48,7 +48,7 @@ public function testStRupertsDay(int $year, DateTime $expected): void /** * Returns a list of random test dates used for assertion of Saint Rupert's Day. * - * @return array list of test dates for Saint Rupert's Day + * @return array list of test dates for Saint Rupert's Day * * @throws Exception */ diff --git a/tests/Austria/SecondChristmasDayTest.php b/tests/Austria/SecondChristmasDayTest.php index 438b37c48..582855b89 100644 --- a/tests/Austria/SecondChristmasDayTest.php +++ b/tests/Austria/SecondChristmasDayTest.php @@ -48,7 +48,7 @@ public function testHoliday(int $year, DateTime $expected): void /** * Returns a list of random test dates used for assertion of the holiday defined in this test. * - * @return array list of test dates for the holiday defined in this test + * @return array list of test dates for the holiday defined in this test * * @throws Exception */ diff --git a/tests/Austria/Styria/StJosephsDayTest.php b/tests/Austria/Styria/StJosephsDayTest.php index 090095778..935e2abf9 100644 --- a/tests/Austria/Styria/StJosephsDayTest.php +++ b/tests/Austria/Styria/StJosephsDayTest.php @@ -48,7 +48,7 @@ public function testStJosephsDay(int $year, DateTime $expected): void /** * Returns a list of random test dates used for assertion of St. Joseph's Day. * - * @return array list of test dates for St. Joseph's Day. + * @return array list of test dates for St. Joseph's Day. * * @throws Exception */ diff --git a/tests/Austria/Tyrol/StJosephsDayTest.php b/tests/Austria/Tyrol/StJosephsDayTest.php index 567aa662b..a5eae304c 100644 --- a/tests/Austria/Tyrol/StJosephsDayTest.php +++ b/tests/Austria/Tyrol/StJosephsDayTest.php @@ -48,7 +48,7 @@ public function testStJosephsDay(int $year, DateTime $expected): void /** * Returns a list of random test dates used for assertion of St. Joseph's Day. * - * @return array list of test dates for St. Joseph's Day. + * @return array list of test dates for St. Joseph's Day. * * @throws Exception */ diff --git a/tests/Austria/UpperAustria/StFloriansDayTest.php b/tests/Austria/UpperAustria/StFloriansDayTest.php index ea884ad4c..d5e9db4f7 100644 --- a/tests/Austria/UpperAustria/StFloriansDayTest.php +++ b/tests/Austria/UpperAustria/StFloriansDayTest.php @@ -48,7 +48,7 @@ public function testStFloriansDay(int $year, DateTime $expected): void /** * Returns a list of random test dates used for assertion of Saint Florian's Day. * - * @return array list of test dates for Saint Florian's Day + * @return array list of test dates for Saint Florian's Day * * @throws Exception */ diff --git a/tests/Austria/Vienna/StLeopoldsDayTest.php b/tests/Austria/Vienna/StLeopoldsDayTest.php index 261eea595..a40e0cf1d 100644 --- a/tests/Austria/Vienna/StLeopoldsDayTest.php +++ b/tests/Austria/Vienna/StLeopoldsDayTest.php @@ -54,7 +54,7 @@ public function testStLeopoldsDay(int $year, DateTime $expected): void /** * Returns a list of random test dates used for assertion of Saint Leopold's Day. * - * @return array list of test dates for Saint Leopold's Day + * @return array list of test dates for Saint Leopold's Day * * @throws Exception */ diff --git a/tests/Austria/Vorarlberg/StJosephsDayTest.php b/tests/Austria/Vorarlberg/StJosephsDayTest.php index d1b08d0a0..ff2e21227 100644 --- a/tests/Austria/Vorarlberg/StJosephsDayTest.php +++ b/tests/Austria/Vorarlberg/StJosephsDayTest.php @@ -48,7 +48,7 @@ public function testStJosephsDay(int $year, DateTime $expected): void /** * Returns a list of random test dates used for assertion of St. Joseph's Day. * - * @return array list of test dates for St. Joseph's Day. + * @return array list of test dates for St. Joseph's Day. * * @throws Exception */ diff --git a/tests/Base/TypographyTest.php b/tests/Base/TypographyTest.php index ccdd52dd5..b6f3b22c0 100644 --- a/tests/Base/TypographyTest.php +++ b/tests/Base/TypographyTest.php @@ -49,6 +49,8 @@ public function testTranslations(string $name, string $class, string $key, strin /** * Provides test data for testProvider(). * + * @return array list of test translations + * * @throws \ReflectionException */ public function translationProvider(): array diff --git a/tests/Base/WeekendTest.php b/tests/Base/WeekendTest.php index 182e965df..8a2695b7d 100644 --- a/tests/Base/WeekendTest.php +++ b/tests/Base/WeekendTest.php @@ -48,6 +48,8 @@ public function testWeekendDay(\DateTimeImmutable $date): void } /** + * @return array list of test dates that are considered a weekend date + * * @throws \Exception */ public function dataProviderWeekendDays(): array @@ -90,6 +92,8 @@ public function testNonWeekendDay(\DateTimeImmutable $date): void } /** + * @return array list of test dates that are considered not a weekend date + * * @throws \Exception */ public function dataProviderNonWeekendDays(): array diff --git a/tests/Base/YasumiWorkdayTest.php b/tests/Base/YasumiWorkdayTest.php index f626f1101..4a46b505d 100644 --- a/tests/Base/YasumiWorkdayTest.php +++ b/tests/Base/YasumiWorkdayTest.php @@ -161,6 +161,9 @@ public function testWorkDayIsNextYear(string $start, int $workdays, string $expe self::assertEquals($expectedNext, $nextWorkingDay->format(self::FORMAT_DATE)); } + /** + * @return array list of test dates that are considered working days the next year + */ public function dataProviderWorkDayNextYear(): array { return [ @@ -195,6 +198,9 @@ public function testWorkDayIsPreviousYear(string $start, int $workdays, string $ self::assertEquals($expectedNext, $previousWorkingDay->format(self::FORMAT_DATE)); } + /** + * @return array list of test dates that are considered working days the previous year + */ public function dataProviderWorkDayPreviousYear(): array { return [ diff --git a/tests/Belgium/AllSaintsDayTest.php b/tests/Belgium/AllSaintsDayTest.php index 618b06697..2d9bd2255 100644 --- a/tests/Belgium/AllSaintsDayTest.php +++ b/tests/Belgium/AllSaintsDayTest.php @@ -48,7 +48,7 @@ public function testHoliday(int $year, DateTime $expected): void /** * Returns a list of random test dates used for assertion of the holiday defined in this test. * - * @return array list of test dates for the holiday defined in this test + * @return array list of test dates for the holiday defined in this test * * @throws Exception */ diff --git a/tests/Belgium/ArmisticeDayTest.php b/tests/Belgium/ArmisticeDayTest.php index f20462363..fbffaad1d 100644 --- a/tests/Belgium/ArmisticeDayTest.php +++ b/tests/Belgium/ArmisticeDayTest.php @@ -48,7 +48,7 @@ public function testHoliday(int $year, DateTime $expected): void /** * Returns a list of random test dates used for assertion of the holiday defined in this test. * - * @return array list of test dates for the holiday defined in this test + * @return array list of test dates for the holiday defined in this test * * @throws Exception */ diff --git a/tests/Belgium/AssumptionOfMaryTest.php b/tests/Belgium/AssumptionOfMaryTest.php index 549afb17f..2f11ee542 100644 --- a/tests/Belgium/AssumptionOfMaryTest.php +++ b/tests/Belgium/AssumptionOfMaryTest.php @@ -48,7 +48,7 @@ public function testHoliday(int $year, DateTime $expected): void /** * Returns a list of random test dates used for assertion of the holiday defined in this test. * - * @return array list of test dates for the holiday defined in this test + * @return array list of test dates for the holiday defined in this test * * @throws Exception */ diff --git a/tests/Belgium/ChristmasTest.php b/tests/Belgium/ChristmasTest.php index 655962ded..abacc016e 100644 --- a/tests/Belgium/ChristmasTest.php +++ b/tests/Belgium/ChristmasTest.php @@ -48,7 +48,7 @@ public function testHoliday(int $year, DateTime $expected): void /** * Returns a list of random test dates used for assertion of the holiday defined in this test. * - * @return array list of test dates for the holiday defined in this test + * @return array list of test dates for the holiday defined in this test * * @throws Exception */ diff --git a/tests/Belgium/InternationalWorkersDayTest.php b/tests/Belgium/InternationalWorkersDayTest.php index fb1b2dbb5..d5a8640fb 100644 --- a/tests/Belgium/InternationalWorkersDayTest.php +++ b/tests/Belgium/InternationalWorkersDayTest.php @@ -48,7 +48,7 @@ public function testHoliday(int $year, DateTime $expected): void /** * Returns a list of random test dates used for assertion of the holiday defined in this test. * - * @return array list of test dates for the holiday defined in this test + * @return array list of test dates for the holiday defined in this test * * @throws Exception */ diff --git a/tests/Belgium/NationalDayTest.php b/tests/Belgium/NationalDayTest.php index fa70f1a51..b3d6c7086 100644 --- a/tests/Belgium/NationalDayTest.php +++ b/tests/Belgium/NationalDayTest.php @@ -48,7 +48,7 @@ public function testHoliday(int $year, DateTime $expected): void /** * Returns a list of random test dates used for assertion of the holiday defined in this test. * - * @return array list of test dates for the holiday defined in this test + * @return array list of test dates for the holiday defined in this test * * @throws Exception */ diff --git a/tests/Belgium/NewYearsDayTest.php b/tests/Belgium/NewYearsDayTest.php index 4d8de94d1..713975296 100644 --- a/tests/Belgium/NewYearsDayTest.php +++ b/tests/Belgium/NewYearsDayTest.php @@ -48,7 +48,7 @@ public function testHoliday(int $year, DateTime $expected): void /** * Returns a list of random test dates used for assertion of the holiday defined in this test. * - * @return array list of test dates for the holiday defined in this test + * @return array list of test dates for the holiday defined in this test * * @throws Exception */ diff --git a/tests/Bosnia/ChristmasDayTest.php b/tests/Bosnia/ChristmasDayTest.php index e4c1195fd..5fdd54db6 100644 --- a/tests/Bosnia/ChristmasDayTest.php +++ b/tests/Bosnia/ChristmasDayTest.php @@ -48,7 +48,7 @@ public function testHoliday(int $year, DateTime $expected): void /** * Returns a list of random test dates used for assertion of the holiday defined in this test. * - * @return array list of test dates for the holiday defined in this test + * @return array list of test dates for the holiday defined in this test * * @throws Exception */ diff --git a/tests/Bosnia/DayAfterNewYearsDay.php b/tests/Bosnia/DayAfterNewYearsDay.php index 4f214f8cc..ffef673f6 100644 --- a/tests/Bosnia/DayAfterNewYearsDay.php +++ b/tests/Bosnia/DayAfterNewYearsDay.php @@ -48,7 +48,7 @@ public function testHoliday(int $year, DateTime $expected): void /** * Returns a list of random test dates used for assertion of the holiday defined in this test. * - * @return array list of test dates for the holiday defined in this test + * @return array list of test dates for the holiday defined in this test * * @throws Exception */ diff --git a/tests/Bosnia/InternationalWorkersDayTest.php b/tests/Bosnia/InternationalWorkersDayTest.php index aed695158..2230e07de 100644 --- a/tests/Bosnia/InternationalWorkersDayTest.php +++ b/tests/Bosnia/InternationalWorkersDayTest.php @@ -73,7 +73,7 @@ public function testHolidayType(): void /** * Returns a list of random test dates used for assertion of the holiday defined in this test. * - * @return array list of test dates for the holiday defined in this test + * @return array list of test dates for the holiday defined in this test * * @throws Exception */ diff --git a/tests/Bosnia/NewYearsDayTest.php b/tests/Bosnia/NewYearsDayTest.php index f0a7ac3ec..36dd23b96 100644 --- a/tests/Bosnia/NewYearsDayTest.php +++ b/tests/Bosnia/NewYearsDayTest.php @@ -48,7 +48,7 @@ public function testHoliday(int $year, DateTime $expected): void /** * Returns a list of random test dates used for assertion of the holiday defined in this test. * - * @return array list of test dates for the holiday defined in this test + * @return array list of test dates for the holiday defined in this test * * @throws Exception */ diff --git a/tests/Bosnia/OrthodoxChristmasDay.php b/tests/Bosnia/OrthodoxChristmasDay.php index 2ed5e63ac..eccde76df 100644 --- a/tests/Bosnia/OrthodoxChristmasDay.php +++ b/tests/Bosnia/OrthodoxChristmasDay.php @@ -31,6 +31,8 @@ class OrthodoxChristmasDay extends BosniaBaseTestCase implements HolidayTestCase public const HOLIDAY = 'orthodoxChristmasDay'; /** + * @return array list of test dates for the holiday defined in this test + * * @throws Exception */ public function holidayDataProvider(): array diff --git a/tests/Bosnia/SecondLabourDay.php b/tests/Bosnia/SecondLabourDay.php index 0c3389364..6790237a2 100644 --- a/tests/Bosnia/SecondLabourDay.php +++ b/tests/Bosnia/SecondLabourDay.php @@ -73,7 +73,7 @@ public function testHolidayType(): void /** * Returns a list of random test dates used for assertion of the holiday defined in this test. * - * @return array list of test dates for the holiday defined in this test + * @return array list of test dates for the holiday defined in this test * * @throws Exception */ diff --git a/tests/Croatia/AllSaintsDayTest.php b/tests/Croatia/AllSaintsDayTest.php index 580bd8467..32eebfb8b 100644 --- a/tests/Croatia/AllSaintsDayTest.php +++ b/tests/Croatia/AllSaintsDayTest.php @@ -48,7 +48,7 @@ public function testHoliday(int $year, DateTime $expected): void /** * Returns a list of random test dates used for assertion of the holiday defined in this test. * - * @return array list of test dates for the holiday defined in this test + * @return array list of test dates for the holiday defined in this test * * @throws Exception */ diff --git a/tests/Croatia/AssumptionOfMaryTest.php b/tests/Croatia/AssumptionOfMaryTest.php index 13e9a14b0..19697fe5a 100644 --- a/tests/Croatia/AssumptionOfMaryTest.php +++ b/tests/Croatia/AssumptionOfMaryTest.php @@ -48,7 +48,7 @@ public function testHoliday(int $year, DateTime $expected): void /** * Returns a list of random test dates used for assertion of the holiday defined in this test. * - * @return array list of test dates for the holiday defined in this test + * @return array list of test dates for the holiday defined in this test * * @throws Exception */ diff --git a/tests/Croatia/ChristmasDayTest.php b/tests/Croatia/ChristmasDayTest.php index f880d080e..48b2f62b0 100644 --- a/tests/Croatia/ChristmasDayTest.php +++ b/tests/Croatia/ChristmasDayTest.php @@ -48,7 +48,7 @@ public function testHoliday(int $year, DateTime $expected): void /** * Returns a list of random test dates used for assertion of the holiday defined in this test. * - * @return array list of test dates for the holiday defined in this test + * @return array list of test dates for the holiday defined in this test * * @throws Exception */ diff --git a/tests/Croatia/EpiphanyTest.php b/tests/Croatia/EpiphanyTest.php index 26c6e29bc..35b1b16d5 100644 --- a/tests/Croatia/EpiphanyTest.php +++ b/tests/Croatia/EpiphanyTest.php @@ -48,7 +48,7 @@ public function testHoliday(int $year, DateTime $expected): void /** * Returns a list of random test dates used for assertion of the holiday defined in this test. * - * @return array list of test dates for the holiday defined in this test + * @return array list of test dates for the holiday defined in this test * * @throws Exception */ diff --git a/tests/Croatia/InternationalWorkersDayTest.php b/tests/Croatia/InternationalWorkersDayTest.php index 3b46ad045..fd81ac3e9 100644 --- a/tests/Croatia/InternationalWorkersDayTest.php +++ b/tests/Croatia/InternationalWorkersDayTest.php @@ -73,7 +73,7 @@ public function testHolidayType(): void /** * Returns a list of random test dates used for assertion of the holiday defined in this test. * - * @return array list of test dates for the holiday defined in this test + * @return array list of test dates for the holiday defined in this test * * @throws Exception */ diff --git a/tests/Croatia/NewYearsDayTest.php b/tests/Croatia/NewYearsDayTest.php index 26027b6a5..43661610e 100644 --- a/tests/Croatia/NewYearsDayTest.php +++ b/tests/Croatia/NewYearsDayTest.php @@ -48,7 +48,7 @@ public function testHoliday(int $year, DateTime $expected): void /** * Returns a list of random test dates used for assertion of the holiday defined in this test. * - * @return array list of test dates for the holiday defined in this test + * @return array list of test dates for the holiday defined in this test * * @throws Exception */ diff --git a/tests/Croatia/StStephensDayTest.php b/tests/Croatia/StStephensDayTest.php index d9bc68e24..ae5171375 100644 --- a/tests/Croatia/StStephensDayTest.php +++ b/tests/Croatia/StStephensDayTest.php @@ -48,7 +48,7 @@ public function teststStephensDay(int $year, DateTime $expected): void /** * Returns a list of random test dates used for assertion of St. Stephen's Day. * - * @return array list of test dates for St. Stephen's Day + * @return array list of test dates for St. Stephen's Day * * @throws Exception */ diff --git a/tests/CzechRepublic/ChristmasDayTest.php b/tests/CzechRepublic/ChristmasDayTest.php index 2e01f5617..4dc6247d0 100644 --- a/tests/CzechRepublic/ChristmasDayTest.php +++ b/tests/CzechRepublic/ChristmasDayTest.php @@ -52,7 +52,7 @@ public function testChristmasDay(int $year, DateTime $expected): void /** * Returns a list of random test dates used for assertion of the holiday defined in this test. * - * @return array list of test dates for the holiday defined in this test + * @return array list of test dates for the holiday defined in this test * * @throws Exception */ diff --git a/tests/CzechRepublic/ChristmasEveTest.php b/tests/CzechRepublic/ChristmasEveTest.php index 496949858..f9cd7ac53 100644 --- a/tests/CzechRepublic/ChristmasEveTest.php +++ b/tests/CzechRepublic/ChristmasEveTest.php @@ -52,7 +52,7 @@ public function testChristmasDay(int $year, DateTime $expected): void /** * Returns a list of random test dates used for assertion of the holiday defined in this test. * - * @return array list of test dates for the holiday defined in this test + * @return array list of test dates for the holiday defined in this test * * @throws Exception */ diff --git a/tests/CzechRepublic/CzechStateHoodDayTest.php b/tests/CzechRepublic/CzechStateHoodDayTest.php index fbd0d6ab9..721f22bec 100644 --- a/tests/CzechRepublic/CzechStateHoodDayTest.php +++ b/tests/CzechRepublic/CzechStateHoodDayTest.php @@ -52,7 +52,7 @@ public function testHoliday(int $year, DateTime $expected): void /** * Returns a list of random test dates used for assertion of the holiday defined in this test. * - * @return array list of test dates for the holiday defined in this test + * @return array list of test dates for the holiday defined in this test * * @throws Exception */ diff --git a/tests/CzechRepublic/IndependentCzechoslovakStateDayTest.php b/tests/CzechRepublic/IndependentCzechoslovakStateDayTest.php index 0866727e2..cbce326ce 100644 --- a/tests/CzechRepublic/IndependentCzechoslovakStateDayTest.php +++ b/tests/CzechRepublic/IndependentCzechoslovakStateDayTest.php @@ -48,7 +48,7 @@ public function testHoliday(int $year, DateTime $expected): void /** * Returns a list of random test dates used for assertion of the holiday defined in this test. * - * @return array list of test dates for the holiday defined in this test + * @return array list of test dates for the holiday defined in this test * * @throws Exception */ diff --git a/tests/CzechRepublic/InternationalWorkersDayTest.php b/tests/CzechRepublic/InternationalWorkersDayTest.php index df82b5588..f9bdb32fd 100644 --- a/tests/CzechRepublic/InternationalWorkersDayTest.php +++ b/tests/CzechRepublic/InternationalWorkersDayTest.php @@ -77,7 +77,7 @@ public function testHolidayType(): void /** * Returns a list of random test dates used for assertion of the holiday defined in this test. * - * @return array list of test dates for the holiday defined in this test + * @return array list of test dates for the holiday defined in this test * * @throws Exception */ diff --git a/tests/CzechRepublic/JanHusDayTest.php b/tests/CzechRepublic/JanHusDayTest.php index ddb5295b3..a276145b4 100644 --- a/tests/CzechRepublic/JanHusDayTest.php +++ b/tests/CzechRepublic/JanHusDayTest.php @@ -48,7 +48,7 @@ public function testHoliday(int $year, DateTime $expected): void /** * Returns a list of random test dates used for assertion of the holiday defined in this test. * - * @return array list of test dates for the holiday defined in this test + * @return array list of test dates for the holiday defined in this test * * @throws Exception */ diff --git a/tests/CzechRepublic/NewYearsDayTest.php b/tests/CzechRepublic/NewYearsDayTest.php index fd93181dc..081d5b135 100644 --- a/tests/CzechRepublic/NewYearsDayTest.php +++ b/tests/CzechRepublic/NewYearsDayTest.php @@ -52,7 +52,7 @@ public function testHoliday(int $year, DateTime $expected): void /** * Returns a list of random test dates used for assertion of the holiday defined in this test. * - * @return array list of test dates for the holiday defined in this test + * @return array list of test dates for the holiday defined in this test * * @throws Exception */ diff --git a/tests/CzechRepublic/RenewalOfIndependentCzechStateDayTest.php b/tests/CzechRepublic/RenewalOfIndependentCzechStateDayTest.php index 3171b7df2..e951b1a5a 100644 --- a/tests/CzechRepublic/RenewalOfIndependentCzechStateDayTest.php +++ b/tests/CzechRepublic/RenewalOfIndependentCzechStateDayTest.php @@ -51,7 +51,7 @@ public function testHoliday(int $year, DateTime $expected): void /** * Returns a list of random test dates used for assertion of the holiday defined in this test. * - * @return array list of test dates for the holiday defined in this test + * @return array list of test dates for the holiday defined in this test * * @throws Exception */ diff --git a/tests/CzechRepublic/SaintsCyrilAndMethodiusDayTest.php b/tests/CzechRepublic/SaintsCyrilAndMethodiusDayTest.php index c14da0ff5..937f89015 100644 --- a/tests/CzechRepublic/SaintsCyrilAndMethodiusDayTest.php +++ b/tests/CzechRepublic/SaintsCyrilAndMethodiusDayTest.php @@ -52,7 +52,7 @@ public function testHoliday(int $year, DateTime $expected): void /** * Returns a list of random test dates used for assertion of the holiday defined in this test. * - * @return array list of test dates for the holiday defined in this test + * @return array list of test dates for the holiday defined in this test * * @throws Exception */ diff --git a/tests/CzechRepublic/SecondChristmasDayTest.php b/tests/CzechRepublic/SecondChristmasDayTest.php index 90fc97b12..94f152f2e 100644 --- a/tests/CzechRepublic/SecondChristmasDayTest.php +++ b/tests/CzechRepublic/SecondChristmasDayTest.php @@ -52,7 +52,7 @@ public function testHoliday(int $year, DateTime $expected): void /** * Returns a list of random test dates used for assertion of the holiday defined in this test. * - * @return array list of test dates for the holiday defined in this test + * @return array list of test dates for the holiday defined in this test * * @throws Exception */ diff --git a/tests/CzechRepublic/StruggleForFreedomAndDemocracyDayTest.php b/tests/CzechRepublic/StruggleForFreedomAndDemocracyDayTest.php index c35fe2c67..31e15f7e9 100644 --- a/tests/CzechRepublic/StruggleForFreedomAndDemocracyDayTest.php +++ b/tests/CzechRepublic/StruggleForFreedomAndDemocracyDayTest.php @@ -48,7 +48,7 @@ public function testHoliday(int $year, DateTime $expected): void /** * Returns a list of random test dates used for assertion of the holiday defined in this test. * - * @return array list of test dates for the holiday defined in this test + * @return array list of test dates for the holiday defined in this test * * @throws Exception */ diff --git a/tests/CzechRepublic/VictoryInEuropeDayTest.php b/tests/CzechRepublic/VictoryInEuropeDayTest.php index d6d02aa36..fa1dcd128 100644 --- a/tests/CzechRepublic/VictoryInEuropeDayTest.php +++ b/tests/CzechRepublic/VictoryInEuropeDayTest.php @@ -52,7 +52,7 @@ public function testHoliday(int $year, DateTime $expected): void /** * Returns a list of random test dates used for assertion of the holiday defined in this test. * - * @return array list of test dates for the holiday defined in this test + * @return array list of test dates for the holiday defined in this test * * @throws Exception */ diff --git a/tests/Denmark/ChristmasDayTest.php b/tests/Denmark/ChristmasDayTest.php index 0e1869ea9..da84ebb2e 100644 --- a/tests/Denmark/ChristmasDayTest.php +++ b/tests/Denmark/ChristmasDayTest.php @@ -48,7 +48,7 @@ public function testHoliday(int $year, DateTime $expected): void /** * Returns a list of random test dates used for assertion of the holiday defined in this test. * - * @return array list of test dates for the holiday defined in this test + * @return array list of test dates for the holiday defined in this test * * @throws Exception */ diff --git a/tests/Denmark/ChristmasEveTest.php b/tests/Denmark/ChristmasEveTest.php index 6a6961b58..8cdeeeb91 100644 --- a/tests/Denmark/ChristmasEveTest.php +++ b/tests/Denmark/ChristmasEveTest.php @@ -48,7 +48,7 @@ public function testHoliday(int $year, DateTime $expected): void /** * Returns a list of random test dates used for assertion of the holiday defined in this test. * - * @return array list of test dates for the holiday defined in this test + * @return array list of test dates for the holiday defined in this test * * @throws Exception */ diff --git a/tests/Denmark/InternationalWorkersDayTest.php b/tests/Denmark/InternationalWorkersDayTest.php index a285a0425..8a6ed9686 100644 --- a/tests/Denmark/InternationalWorkersDayTest.php +++ b/tests/Denmark/InternationalWorkersDayTest.php @@ -48,7 +48,7 @@ public function testInternationalWorkersDay(int $year, DateTime $expected): void /** * Returns a list of random test dates used for assertion of International Workers' Day. * - * @return array list of test dates for International Workers' Day + * @return array list of test dates for International Workers' Day * * @throws Exception */ diff --git a/tests/Denmark/NewYearsDayTest.php b/tests/Denmark/NewYearsDayTest.php index 1d4290197..e844f4c1d 100644 --- a/tests/Denmark/NewYearsDayTest.php +++ b/tests/Denmark/NewYearsDayTest.php @@ -48,7 +48,7 @@ public function testHoliday(int $year, DateTime $expected): void /** * Returns a list of random test dates used for assertion of the holiday defined in this test. * - * @return array list of test dates for the holiday defined in this test + * @return array list of test dates for the holiday defined in this test * * @throws Exception */ diff --git a/tests/Denmark/NewYearsEveTest.php b/tests/Denmark/NewYearsEveTest.php index 955bfb3e1..b16335eda 100644 --- a/tests/Denmark/NewYearsEveTest.php +++ b/tests/Denmark/NewYearsEveTest.php @@ -48,7 +48,7 @@ public function testHoliday(int $year, DateTime $expected): void /** * Returns a list of random test dates used for assertion of the holiday defined in this test. * - * @return array list of test dates for the holiday defined in this test + * @return array list of test dates for the holiday defined in this test * * @throws Exception */ diff --git a/tests/Denmark/SecondChristmasDayTest.php b/tests/Denmark/SecondChristmasDayTest.php index 678928845..6d93a34f9 100644 --- a/tests/Denmark/SecondChristmasDayTest.php +++ b/tests/Denmark/SecondChristmasDayTest.php @@ -48,7 +48,7 @@ public function testHoliday(int $year, DateTime $expected): void /** * Returns a list of random test dates used for assertion of the holiday defined in this test. * - * @return array list of test dates for the holiday defined in this test + * @return array list of test dates for the holiday defined in this test * * @throws Exception */ diff --git a/tests/Estonia/ChristmasDayTest.php b/tests/Estonia/ChristmasDayTest.php index 091cb53a9..5aadd5ff9 100644 --- a/tests/Estonia/ChristmasDayTest.php +++ b/tests/Estonia/ChristmasDayTest.php @@ -34,6 +34,8 @@ class ChristmasDayTest extends EstoniaBaseTestCase implements HolidayTestCase public const HOLIDAY = 'christmasDay'; /** + * @return array list of test dates for the holiday defined in this test + * * @throws Exception */ public function holidayDataProvider(): array diff --git a/tests/Estonia/ChristmasEveDayTest.php b/tests/Estonia/ChristmasEveDayTest.php index 4198750b6..bdddf9630 100644 --- a/tests/Estonia/ChristmasEveDayTest.php +++ b/tests/Estonia/ChristmasEveDayTest.php @@ -34,6 +34,8 @@ class ChristmasEveDayTest extends EstoniaBaseTestCase implements HolidayTestCase public const HOLIDAY = 'christmasEve'; /** + * @return array list of test dates for the holiday defined in this test + * * @throws Exception */ public function holidayDataProvider(): array diff --git a/tests/Estonia/EasterDayTest.php b/tests/Estonia/EasterDayTest.php index 166d01949..b37d453a0 100644 --- a/tests/Estonia/EasterDayTest.php +++ b/tests/Estonia/EasterDayTest.php @@ -35,6 +35,8 @@ class EasterDayTest extends EstoniaBaseTestCase implements HolidayTestCase public const HOLIDAY = 'easter'; /** + * @return array list of test dates for the holiday defined in this test + * * @throws Exception */ public function holidayDataProvider(): array diff --git a/tests/Estonia/GoodFridayDayTest.php b/tests/Estonia/GoodFridayDayTest.php index 87ac7574a..adb757569 100644 --- a/tests/Estonia/GoodFridayDayTest.php +++ b/tests/Estonia/GoodFridayDayTest.php @@ -35,6 +35,8 @@ class GoodFridayDayTest extends EstoniaBaseTestCase implements HolidayTestCase public const HOLIDAY = 'goodFriday'; /** + * @return array list of test dates for the holiday defined in this test + * * @throws Exception */ public function holidayDataProvider(): array diff --git a/tests/Estonia/InternationalWorkersDayTest.php b/tests/Estonia/InternationalWorkersDayTest.php index dd20c54a2..0f6f8ff6e 100644 --- a/tests/Estonia/InternationalWorkersDayTest.php +++ b/tests/Estonia/InternationalWorkersDayTest.php @@ -34,6 +34,8 @@ class InternationalWorkersDayTest extends EstoniaBaseTestCase implements Holiday public const HOLIDAY = 'internationalWorkersDay'; /** + * @return array list of test dates for the holiday defined in this test + * * @throws Exception */ public function holidayDataProvider(): array diff --git a/tests/Estonia/NewYearsDayTest.php b/tests/Estonia/NewYearsDayTest.php index e9cb9cbee..6be904b9d 100644 --- a/tests/Estonia/NewYearsDayTest.php +++ b/tests/Estonia/NewYearsDayTest.php @@ -34,6 +34,8 @@ class NewYearsDayTest extends EstoniaBaseTestCase implements HolidayTestCase public const HOLIDAY = 'newYearsDay'; /** + * @return array list of test dates for the holiday defined in this test + * * @throws Exception */ public function holidayDataProvider(): array diff --git a/tests/Estonia/PentecostTest.php b/tests/Estonia/PentecostTest.php index 118c5da78..5dc27dab7 100644 --- a/tests/Estonia/PentecostTest.php +++ b/tests/Estonia/PentecostTest.php @@ -35,6 +35,8 @@ class PentecostTest extends EstoniaBaseTestCase implements HolidayTestCase public const HOLIDAY = 'pentecost'; /** + * @return array list of test dates for the holiday defined in this test + * * @throws Exception */ public function holidayDataProvider(): array diff --git a/tests/Estonia/SecondChristmasDayTest.php b/tests/Estonia/SecondChristmasDayTest.php index 71810c769..39780fe8f 100644 --- a/tests/Estonia/SecondChristmasDayTest.php +++ b/tests/Estonia/SecondChristmasDayTest.php @@ -34,6 +34,8 @@ class SecondChristmasDayTest extends EstoniaBaseTestCase implements HolidayTestC public const HOLIDAY = 'secondChristmasDay'; /** + * @return array list of test dates for the holiday defined in this test + * * @throws Exception */ public function holidayDataProvider(): array diff --git a/tests/Estonia/StJohnsDayTest.php b/tests/Estonia/StJohnsDayTest.php index 290307606..4b443670a 100644 --- a/tests/Estonia/StJohnsDayTest.php +++ b/tests/Estonia/StJohnsDayTest.php @@ -34,6 +34,8 @@ class StJohnsDayTest extends EstoniaBaseTestCase implements HolidayTestCase public const HOLIDAY = 'stJohnsDay'; /** + * @return array list of test dates for the holiday defined in this test + * * @throws Exception */ public function holidayDataProvider(): array diff --git a/tests/Finland/AllSaintsDayTest.php b/tests/Finland/AllSaintsDayTest.php index 577913abe..60b944f89 100644 --- a/tests/Finland/AllSaintsDayTest.php +++ b/tests/Finland/AllSaintsDayTest.php @@ -50,7 +50,7 @@ public function testHoliday(int $year, DateTime $expected): void /** * Returns a list of random test dates used for assertion of the holiday defined in this test. * - * @return array list of test dates for the holiday defined in this test + * @return array list of test dates for the holiday defined in this test * * @throws Exception */ diff --git a/tests/Finland/ChristmasDayTest.php b/tests/Finland/ChristmasDayTest.php index b8ec6de84..263bf9dc9 100644 --- a/tests/Finland/ChristmasDayTest.php +++ b/tests/Finland/ChristmasDayTest.php @@ -48,7 +48,7 @@ public function testHoliday(int $year, DateTime $expected): void /** * Returns a list of random test dates used for assertion of the holiday defined in this test. * - * @return array list of test dates for the holiday defined in this test + * @return array list of test dates for the holiday defined in this test * * @throws Exception */ diff --git a/tests/Finland/EpiphanyTest.php b/tests/Finland/EpiphanyTest.php index f0e44d674..a66273efc 100644 --- a/tests/Finland/EpiphanyTest.php +++ b/tests/Finland/EpiphanyTest.php @@ -48,7 +48,7 @@ public function testHoliday(int $year, DateTime $expected): void /** * Returns a list of random test dates used for assertion of the holiday defined in this test. * - * @return array list of test dates for the holiday defined in this test + * @return array list of test dates for the holiday defined in this test * * @throws Exception */ diff --git a/tests/Finland/InternationalWorkersDayTest.php b/tests/Finland/InternationalWorkersDayTest.php index c35742127..1734c8238 100644 --- a/tests/Finland/InternationalWorkersDayTest.php +++ b/tests/Finland/InternationalWorkersDayTest.php @@ -73,7 +73,7 @@ public function testHolidayType(): void /** * Returns a list of random test dates used for assertion of the holiday defined in this test. * - * @return array list of test dates for the holiday defined in this test + * @return array list of test dates for the holiday defined in this test * * @throws Exception */ diff --git a/tests/Finland/NewYearsDayTest.php b/tests/Finland/NewYearsDayTest.php index 068aa1717..71c16aca5 100644 --- a/tests/Finland/NewYearsDayTest.php +++ b/tests/Finland/NewYearsDayTest.php @@ -48,7 +48,7 @@ public function testHoliday(int $year, DateTime $expected): void /** * Returns a list of random test dates used for assertion of the holiday defined in this test. * - * @return array list of test dates for the holiday defined in this test + * @return array list of test dates for the holiday defined in this test * * @throws Exception */ diff --git a/tests/Finland/SecondChristmasDayTest.php b/tests/Finland/SecondChristmasDayTest.php index 246c26068..f64bf1e3c 100644 --- a/tests/Finland/SecondChristmasDayTest.php +++ b/tests/Finland/SecondChristmasDayTest.php @@ -48,7 +48,7 @@ public function testHoliday(int $year, DateTime $expected): void /** * Returns a list of random test dates used for assertion of the holiday defined in this test. * - * @return array list of test dates for the holiday defined in this test + * @return array list of test dates for the holiday defined in this test * * @throws Exception */ diff --git a/tests/France/AllSaintsDayTest.php b/tests/France/AllSaintsDayTest.php index c78ee5151..70d28516b 100644 --- a/tests/France/AllSaintsDayTest.php +++ b/tests/France/AllSaintsDayTest.php @@ -73,7 +73,7 @@ public function testHolidayType(): void /** * Returns a list of random test dates used for assertion of All Saints' Day. * - * @return array list of test dates for All Saints' Day + * @return array list of test dates for All Saints' Day * * @throws Exception */ diff --git a/tests/France/AssumptionOfMaryTest.php b/tests/France/AssumptionOfMaryTest.php index 6de074804..6448fd9da 100644 --- a/tests/France/AssumptionOfMaryTest.php +++ b/tests/France/AssumptionOfMaryTest.php @@ -73,7 +73,7 @@ public function testHolidayType(): void /** * Returns a list of random test dates used for assertion of the day of the Assumption of Mary. * - * @return array list of test dates for the day of the Assumption of Mary + * @return array list of test dates for the day of the Assumption of Mary * * @throws Exception */ diff --git a/tests/France/BasRhin/stStephensDayTest.php b/tests/France/BasRhin/stStephensDayTest.php index c51777bcb..0e1c09764 100644 --- a/tests/France/BasRhin/stStephensDayTest.php +++ b/tests/France/BasRhin/stStephensDayTest.php @@ -48,7 +48,7 @@ public function testHoliday(int $year, DateTime $expected): void /** * Returns a list of random test dates used for assertion of the holiday defined in this test. * - * @return array list of test dates for the holiday defined in this test + * @return array list of test dates for the holiday defined in this test * * @throws Exception */ diff --git a/tests/France/ChristmasDayTest.php b/tests/France/ChristmasDayTest.php index a32d39000..93132590c 100644 --- a/tests/France/ChristmasDayTest.php +++ b/tests/France/ChristmasDayTest.php @@ -48,7 +48,7 @@ public function testChristmasDay(int $year, DateTime $expected): void /** * Returns a list of random test dates used for assertion of Christmas Day. * - * @return array list of test dates for Christmas Day + * @return array list of test dates for Christmas Day * * @throws Exception */ diff --git a/tests/France/HautRhin/stStephensDayTest.php b/tests/France/HautRhin/stStephensDayTest.php index 7d57039ac..76a82e6c8 100644 --- a/tests/France/HautRhin/stStephensDayTest.php +++ b/tests/France/HautRhin/stStephensDayTest.php @@ -48,7 +48,7 @@ public function testHoliday(int $year, DateTime $expected): void /** * Returns a list of random test dates used for assertion of the holiday defined in this test. * - * @return array list of test dates for the holiday defined in this test + * @return array list of test dates for the holiday defined in this test * * @throws Exception */ diff --git a/tests/France/InternationalWorkersDayTest.php b/tests/France/InternationalWorkersDayTest.php index 1d962eb9d..bd94a58ea 100644 --- a/tests/France/InternationalWorkersDayTest.php +++ b/tests/France/InternationalWorkersDayTest.php @@ -73,7 +73,7 @@ public function testHolidayType(): void /** * Returns a list of random test dates used for assertion of International Workers' Day. * - * @return array list of test dates for International Workers' Day + * @return array list of test dates for International Workers' Day * * @throws Exception */ diff --git a/tests/France/Moselle/stStephensDayTest.php b/tests/France/Moselle/stStephensDayTest.php index 439be3ced..559020362 100644 --- a/tests/France/Moselle/stStephensDayTest.php +++ b/tests/France/Moselle/stStephensDayTest.php @@ -48,7 +48,7 @@ public function testHoliday(int $year, DateTime $expected): void /** * Returns a list of random test dates used for assertion of the holiday defined in this test. * - * @return array list of test dates for the holiday defined in this test + * @return array list of test dates for the holiday defined in this test * * @throws Exception */ diff --git a/tests/France/NewYearsDayTest.php b/tests/France/NewYearsDayTest.php index 7dce92684..d87bb62f5 100644 --- a/tests/France/NewYearsDayTest.php +++ b/tests/France/NewYearsDayTest.php @@ -73,7 +73,7 @@ public function testHolidayType(): void /** * Returns a list of random test dates used for assertion of New Years Day. * - * @return array list of test dates for New Years Day + * @return array list of test dates for New Years Day * * @throws Exception */ diff --git a/tests/Georgia/InternationalWomensDayTest.php b/tests/Georgia/InternationalWomensDayTest.php index d79a5704c..43edbaf15 100644 --- a/tests/Georgia/InternationalWomensDayTest.php +++ b/tests/Georgia/InternationalWomensDayTest.php @@ -41,7 +41,7 @@ public function testHoliday(int $year, DateTime $expected): void /** * Returns a list of random test dates used for assertion of the holiday defined in this test. * - * @return array list of test dates for the holiday defined in this test + * @return array list of test dates for the holiday defined in this test * * @throws Exception */ diff --git a/tests/Georgia/MtskhetobaDayTest.php b/tests/Georgia/MtskhetobaDayTest.php index 1af9ff2e0..76e9ea612 100644 --- a/tests/Georgia/MtskhetobaDayTest.php +++ b/tests/Georgia/MtskhetobaDayTest.php @@ -41,7 +41,7 @@ public function testHoliday(int $year, DateTime $expected): void /** * Returns a list of random test dates used for assertion of the holiday defined in this test. * - * @return array list of test dates for the holiday defined in this test + * @return array list of test dates for the holiday defined in this test * * @throws Exception */ diff --git a/tests/Georgia/NewYearsDayTest.php b/tests/Georgia/NewYearsDayTest.php index 269db3c52..601ea55d7 100644 --- a/tests/Georgia/NewYearsDayTest.php +++ b/tests/Georgia/NewYearsDayTest.php @@ -41,7 +41,7 @@ public function testHoliday(int $year, DateTime $expected): void /** * Returns a list of random test dates used for assertion of the holiday defined in this test. * - * @return array list of test dates for the holiday defined in this test + * @return array list of test dates for the holiday defined in this test * * @throws Exception */ diff --git a/tests/Georgia/OrthodoxChristmasDayTest.php b/tests/Georgia/OrthodoxChristmasDayTest.php index 2aa786d90..4cfc569b7 100644 --- a/tests/Georgia/OrthodoxChristmasDayTest.php +++ b/tests/Georgia/OrthodoxChristmasDayTest.php @@ -41,7 +41,7 @@ public function testHoliday(int $year, DateTime $expected): void /** * Returns a list of random test dates used for assertion of the holiday defined in this test. * - * @return array list of test dates for the holiday defined in this test + * @return array list of test dates for the holiday defined in this test * * @throws Exception */ diff --git a/tests/Georgia/OrthodoxEpiphanyDayTest.php b/tests/Georgia/OrthodoxEpiphanyDayTest.php index 5d788be6e..022aa469d 100644 --- a/tests/Georgia/OrthodoxEpiphanyDayTest.php +++ b/tests/Georgia/OrthodoxEpiphanyDayTest.php @@ -41,7 +41,7 @@ public function testHoliday(int $year, DateTime $expected): void /** * Returns a list of random test dates used for assertion of the holiday defined in this test. * - * @return array list of test dates for the holiday defined in this test + * @return array list of test dates for the holiday defined in this test * * @throws Exception */ diff --git a/tests/Georgia/SecondNewYearDayTest.php b/tests/Georgia/SecondNewYearDayTest.php index 332122cea..c5aaf49c5 100644 --- a/tests/Georgia/SecondNewYearDayTest.php +++ b/tests/Georgia/SecondNewYearDayTest.php @@ -41,7 +41,7 @@ public function testHoliday(int $year, DateTime $expected): void /** * Returns a list of random test dates used for assertion of the holiday defined in this test. * - * @return array list of test dates for the holiday defined in this test + * @return array list of test dates for the holiday defined in this test * * @throws Exception */ diff --git a/tests/Georgia/StAndrewsDayTest.php b/tests/Georgia/StAndrewsDayTest.php index 366fd2e57..44c3c3521 100644 --- a/tests/Georgia/StAndrewsDayTest.php +++ b/tests/Georgia/StAndrewsDayTest.php @@ -41,7 +41,7 @@ public function testHoliday(int $year, DateTime $expected): void /** * Returns a list of random test dates used for assertion of the holiday defined in this test. * - * @return array list of test dates for the holiday defined in this test + * @return array list of test dates for the holiday defined in this test * * @throws Exception */ diff --git a/tests/Georgia/StGeorgesDayTest.php b/tests/Georgia/StGeorgesDayTest.php index b52ddb52e..eb5529115 100644 --- a/tests/Georgia/StGeorgesDayTest.php +++ b/tests/Georgia/StGeorgesDayTest.php @@ -41,7 +41,7 @@ public function testHoliday(int $year, DateTime $expected): void /** * Returns a list of random test dates used for assertion of the holiday defined in this test. * - * @return array list of test dates for the holiday defined in this test + * @return array list of test dates for the holiday defined in this test * * @throws Exception */ diff --git a/tests/Georgia/StMarysDayTest.php b/tests/Georgia/StMarysDayTest.php index 4e9685f02..77f7c3ee9 100644 --- a/tests/Georgia/StMarysDayTest.php +++ b/tests/Georgia/StMarysDayTest.php @@ -41,7 +41,7 @@ public function testHoliday(int $year, DateTime $expected): void /** * Returns a list of random test dates used for assertion of the holiday defined in this test. * - * @return array list of test dates for the holiday defined in this test + * @return array list of test dates for the holiday defined in this test * * @throws Exception */ diff --git a/tests/Georgia/VictoryDayTest.php b/tests/Georgia/VictoryDayTest.php index ef56d84c2..12d8822d0 100644 --- a/tests/Georgia/VictoryDayTest.php +++ b/tests/Georgia/VictoryDayTest.php @@ -41,7 +41,7 @@ public function testHoliday(int $year, DateTime $expected): void /** * Returns a list of random test dates used for assertion of the holiday defined in this test. * - * @return array list of test dates for the holiday defined in this test + * @return array list of test dates for the holiday defined in this test * * @throws Exception */ diff --git a/tests/Germany/BadenWurttemberg/AllSaintsDayTest.php b/tests/Germany/BadenWurttemberg/AllSaintsDayTest.php index 7a6db7fe5..1def6b656 100644 --- a/tests/Germany/BadenWurttemberg/AllSaintsDayTest.php +++ b/tests/Germany/BadenWurttemberg/AllSaintsDayTest.php @@ -48,7 +48,7 @@ public function testHoliday(int $year, DateTime $expected): void /** * Returns a list of random test dates used for assertion of the holiday defined in this test. * - * @return array list of test dates for the holiday defined in this test + * @return array list of test dates for the holiday defined in this test * * @throws Exception */ diff --git a/tests/Germany/BadenWurttemberg/EpiphanyTest.php b/tests/Germany/BadenWurttemberg/EpiphanyTest.php index 254dc7b15..b9d418ddf 100644 --- a/tests/Germany/BadenWurttemberg/EpiphanyTest.php +++ b/tests/Germany/BadenWurttemberg/EpiphanyTest.php @@ -48,7 +48,7 @@ public function testHoliday(int $year, DateTime $expected): void /** * Returns a list of random test dates used for assertion of the holiday defined in this test. * - * @return array list of test dates for the day of the holiday defined in this test + * @return array list of test dates for the holiday defined in this test * * @throws Exception */ diff --git a/tests/Germany/Bavaria/AllSaintsDayTest.php b/tests/Germany/Bavaria/AllSaintsDayTest.php index 80f7be042..d5caef2c0 100644 --- a/tests/Germany/Bavaria/AllSaintsDayTest.php +++ b/tests/Germany/Bavaria/AllSaintsDayTest.php @@ -48,7 +48,7 @@ public function testHoliday(int $year, DateTime $expected): void /** * Returns a list of random test dates used for assertion of the holiday defined in this test. * - * @return array list of test dates for the holiday defined in this test + * @return array list of test dates for the holiday defined in this test * * @throws Exception */ diff --git a/tests/Germany/Bavaria/EpiphanyTest.php b/tests/Germany/Bavaria/EpiphanyTest.php index 50ba9182b..997e250d5 100644 --- a/tests/Germany/Bavaria/EpiphanyTest.php +++ b/tests/Germany/Bavaria/EpiphanyTest.php @@ -48,7 +48,7 @@ public function testHoliday(int $year, DateTime $expected): void /** * Returns a list of random test dates used for assertion of the holiday defined in this test. * - * @return array list of test dates for the day of the holiday defined in this test + * @return array list of test dates for the holiday defined in this test * * @throws Exception */ diff --git a/tests/Germany/Brandenburg/ReformationDayTest.php b/tests/Germany/Brandenburg/ReformationDayTest.php index 29c0658c0..50736d85c 100644 --- a/tests/Germany/Brandenburg/ReformationDayTest.php +++ b/tests/Germany/Brandenburg/ReformationDayTest.php @@ -54,7 +54,7 @@ public function testHoliday(int $year, DateTime $expected): void /** * Returns a list of random test dates used for assertion of the holiday defined in this test. * - * @return array list of test dates for the holiday defined in this test + * @return array list of test dates for the holiday defined in this test * * @throws Exception */ diff --git a/tests/Germany/Bremen/ReformationDayTest.php b/tests/Germany/Bremen/ReformationDayTest.php index e06af97c9..9a399fade 100644 --- a/tests/Germany/Bremen/ReformationDayTest.php +++ b/tests/Germany/Bremen/ReformationDayTest.php @@ -54,7 +54,7 @@ public function testHoliday(int $year, DateTime $expected): void /** * Returns a list of random test dates used for assertion of the holiday defined in this test. * - * @return array list of test dates for the holiday defined in this test + * @return array list of test dates for the holiday defined in this test * * @throws Exception */ diff --git a/tests/Germany/ChristmasTest.php b/tests/Germany/ChristmasTest.php index 07f2877a6..dd4da91cb 100644 --- a/tests/Germany/ChristmasTest.php +++ b/tests/Germany/ChristmasTest.php @@ -48,7 +48,7 @@ public function testChristmasDay(int $year, DateTime $expected): void /** * Returns a list of random test dates used for assertion of the holiday defined in this test. * - * @return array list of test dates for the holiday defined in this test + * @return array list of test dates for the holiday defined in this test * * @throws Exception */ diff --git a/tests/Germany/Hamburg/DayOfReformationTest.php b/tests/Germany/Hamburg/DayOfReformationTest.php index 838e8cb3e..f17ec8d0b 100644 --- a/tests/Germany/Hamburg/DayOfReformationTest.php +++ b/tests/Germany/Hamburg/DayOfReformationTest.php @@ -54,7 +54,7 @@ public function testHoliday(int $year, DateTime $expected): void /** * Returns a list of random test dates used for assertion of the holiday defined in this test. * - * @return array list of test dates for the holiday defined in this test + * @return array list of test dates for the holiday defined in this test * * @throws Exception */ diff --git a/tests/Germany/InternationalWorkersDayTest.php b/tests/Germany/InternationalWorkersDayTest.php index c6f610643..ff8312ade 100644 --- a/tests/Germany/InternationalWorkersDayTest.php +++ b/tests/Germany/InternationalWorkersDayTest.php @@ -73,7 +73,7 @@ public function testHolidayType(): void /** * Returns a list of random test dates used for assertion of the holiday defined in this test. * - * @return array list of test dates for the holiday defined in this test + * @return array list of test dates for the holiday defined in this test * * @throws Exception */ diff --git a/tests/Germany/LowerSaxony/ReformationDayTest.php b/tests/Germany/LowerSaxony/ReformationDayTest.php index 3374eab95..4b6b2fc6b 100644 --- a/tests/Germany/LowerSaxony/ReformationDayTest.php +++ b/tests/Germany/LowerSaxony/ReformationDayTest.php @@ -54,7 +54,7 @@ public function testHoliday(int $year, DateTime $expected): void /** * Returns a list of random test dates used for assertion of the holiday defined in this test. * - * @return array list of test dates for the holiday defined in this test + * @return array list of test dates for the holiday defined in this test * * @throws Exception */ diff --git a/tests/Germany/MecklenburgWesternPomerania/ReformationDayTest.php b/tests/Germany/MecklenburgWesternPomerania/ReformationDayTest.php index 68a81e2fc..368b6e098 100644 --- a/tests/Germany/MecklenburgWesternPomerania/ReformationDayTest.php +++ b/tests/Germany/MecklenburgWesternPomerania/ReformationDayTest.php @@ -39,7 +39,7 @@ class ReformationDayTest extends MecklenburgWesternPomeraniaBaseTestCase impleme /** * Returns a list of random test dates used for assertion of the holiday defined in this test. * - * @return array list of test dates for the holiday defined in this test + * @return array list of test dates for the holiday defined in this test * * @throws Exception */ diff --git a/tests/Germany/NewYearsDayTest.php b/tests/Germany/NewYearsDayTest.php index 00b370e3f..ce226496a 100644 --- a/tests/Germany/NewYearsDayTest.php +++ b/tests/Germany/NewYearsDayTest.php @@ -48,7 +48,7 @@ public function testHoliday(int $year, DateTime $expected): void /** * Returns a list of random test dates used for assertion of the holiday defined in this test. * - * @return array list of test dates for the holiday defined in this test + * @return array list of test dates for the holiday defined in this test * * @throws Exception */ diff --git a/tests/Germany/NewYearsEveTest.php b/tests/Germany/NewYearsEveTest.php index a42d000f4..64e5c9b06 100644 --- a/tests/Germany/NewYearsEveTest.php +++ b/tests/Germany/NewYearsEveTest.php @@ -48,7 +48,7 @@ public function testHoliday(int $year, DateTime $expected): void /** * Returns a list of random test dates used for assertion of the holiday defined in this test. * - * @return array list of test dates for the holiday defined in this test + * @return array list of test dates for the holiday defined in this test * * @throws Exception */ diff --git a/tests/Germany/NorthRhineWestphalia/AllSaintsDayTest.php b/tests/Germany/NorthRhineWestphalia/AllSaintsDayTest.php index 4c346b57e..25a33a18a 100644 --- a/tests/Germany/NorthRhineWestphalia/AllSaintsDayTest.php +++ b/tests/Germany/NorthRhineWestphalia/AllSaintsDayTest.php @@ -48,7 +48,7 @@ public function testHoliday(int $year, DateTime $expected): void /** * Returns a list of random test dates used for assertion of the holiday defined in this test. * - * @return array list of test dates for the holiday defined in this test + * @return array list of test dates for the holiday defined in this test * * @throws Exception */ diff --git a/tests/Germany/RhinelandPalatinate/AllSaintsDayTest.php b/tests/Germany/RhinelandPalatinate/AllSaintsDayTest.php index 2ab9e52aa..cbfd274be 100644 --- a/tests/Germany/RhinelandPalatinate/AllSaintsDayTest.php +++ b/tests/Germany/RhinelandPalatinate/AllSaintsDayTest.php @@ -48,7 +48,7 @@ public function testHoliday(int $year, DateTime $expected): void /** * Returns a list of random test dates used for assertion of the holiday defined in this test. * - * @return array list of test dates for the holiday defined in this test + * @return array list of test dates for the holiday defined in this test * * @throws Exception */ diff --git a/tests/Germany/Saarland/AllSaintsDayTest.php b/tests/Germany/Saarland/AllSaintsDayTest.php index ac5819e0d..d4d5fc1db 100644 --- a/tests/Germany/Saarland/AllSaintsDayTest.php +++ b/tests/Germany/Saarland/AllSaintsDayTest.php @@ -48,7 +48,7 @@ public function testHoliday(int $year, DateTime $expected): void /** * Returns a list of random test dates used for assertion of the holiday defined in this test. * - * @return array list of test dates for the holiday defined in this test + * @return array list of test dates for the holiday defined in this test * * @throws Exception */ diff --git a/tests/Germany/Saarland/AssumptionOfMaryTest.php b/tests/Germany/Saarland/AssumptionOfMaryTest.php index a86130098..78f70797d 100644 --- a/tests/Germany/Saarland/AssumptionOfMaryTest.php +++ b/tests/Germany/Saarland/AssumptionOfMaryTest.php @@ -48,7 +48,7 @@ public function testHoliday(int $year, DateTime $expected): void /** * Returns a list of random test dates used for assertion of the holiday defined in this test. * - * @return array list of test dates for the holiday defined in this test + * @return array list of test dates for the holiday defined in this test * * @throws Exception */ diff --git a/tests/Germany/Saxony/ReformationDayTest.php b/tests/Germany/Saxony/ReformationDayTest.php index 393243a2e..c89b88ca0 100644 --- a/tests/Germany/Saxony/ReformationDayTest.php +++ b/tests/Germany/Saxony/ReformationDayTest.php @@ -54,7 +54,7 @@ public function testHoliday(int $year, DateTime $expected): void /** * Returns a list of random test dates used for assertion of the holiday defined in this test. * - * @return array list of test dates for the holiday defined in this test + * @return array list of test dates for the holiday defined in this test * * @throws Exception */ diff --git a/tests/Germany/SaxonyAnhalt/EpiphanyTest.php b/tests/Germany/SaxonyAnhalt/EpiphanyTest.php index e1968ac96..8b637ba86 100644 --- a/tests/Germany/SaxonyAnhalt/EpiphanyTest.php +++ b/tests/Germany/SaxonyAnhalt/EpiphanyTest.php @@ -48,7 +48,7 @@ public function testHoliday(int $year, DateTime $expected): void /** * Returns a list of random test dates used for assertion of the holiday defined in this test. * - * @return array list of test dates for the day of the holiday defined in this test + * @return array list of test dates for the holiday defined in this test * * @throws Exception */ diff --git a/tests/Germany/SaxonyAnhalt/ReformationDayTest.php b/tests/Germany/SaxonyAnhalt/ReformationDayTest.php index dbec24d74..f840dbf16 100644 --- a/tests/Germany/SaxonyAnhalt/ReformationDayTest.php +++ b/tests/Germany/SaxonyAnhalt/ReformationDayTest.php @@ -54,7 +54,7 @@ public function testHoliday(int $year, DateTime $expected): void /** * Returns a list of random test dates used for assertion of the holiday defined in this test. * - * @return array list of test dates for the holiday defined in this test + * @return array list of test dates for the holiday defined in this test * * @throws Exception */ diff --git a/tests/Germany/SchleswigHolstein/ReformationDayTest.php b/tests/Germany/SchleswigHolstein/ReformationDayTest.php index 03767debb..09c4909c8 100644 --- a/tests/Germany/SchleswigHolstein/ReformationDayTest.php +++ b/tests/Germany/SchleswigHolstein/ReformationDayTest.php @@ -54,7 +54,7 @@ public function testHoliday(int $year, DateTime $expected): void /** * Returns a list of random test dates used for assertion of the holiday defined in this test. * - * @return array list of test dates for the holiday defined in this test + * @return array list of test dates for the holiday defined in this test * * @throws Exception */ diff --git a/tests/Germany/SecondChristmasDayTest.php b/tests/Germany/SecondChristmasDayTest.php index b4b819b10..13eb7d195 100644 --- a/tests/Germany/SecondChristmasDayTest.php +++ b/tests/Germany/SecondChristmasDayTest.php @@ -48,7 +48,7 @@ public function testHoliday(int $year, DateTime $expected): void /** * Returns a list of random test dates used for assertion of the holiday defined in this test. * - * @return array list of test dates for the holiday defined in this test + * @return array list of test dates for the holiday defined in this test * * @throws Exception */ diff --git a/tests/Germany/Thuringia/ReformationDayTest.php b/tests/Germany/Thuringia/ReformationDayTest.php index 1bc00a392..d750bbad2 100644 --- a/tests/Germany/Thuringia/ReformationDayTest.php +++ b/tests/Germany/Thuringia/ReformationDayTest.php @@ -54,7 +54,7 @@ public function testHoliday(int $year, DateTime $expected): void /** * Returns a list of random test dates used for assertion of the holiday defined in this test. * - * @return array list of test dates for the holiday defined in this test + * @return array list of test dates for the holiday defined in this test * * @throws Exception */ diff --git a/tests/Germany/Thuringia/WorldChildrensDayTest.php b/tests/Germany/Thuringia/WorldChildrensDayTest.php index 6141fb6ab..fb1f90e74 100644 --- a/tests/Germany/Thuringia/WorldChildrensDayTest.php +++ b/tests/Germany/Thuringia/WorldChildrensDayTest.php @@ -54,7 +54,7 @@ public function testHoliday(int $year, DateTime $expected): void /** * Returns a list of random test dates used for assertion of the holiday defined in this test. * - * @return array list of test dates for the holiday defined in this test + * @return array list of test dates for the holiday defined in this test * * @throws Exception */ diff --git a/tests/Greece/AnnunciationTest.php b/tests/Greece/AnnunciationTest.php index e3a664e79..97a960d63 100644 --- a/tests/Greece/AnnunciationTest.php +++ b/tests/Greece/AnnunciationTest.php @@ -48,7 +48,7 @@ public function testHoliday(int $year, DateTime $expected): void /** * Returns a list of random test dates used for assertion of the holiday defined in this test. * - * @return array list of test dates for the holiday defined in this test + * @return array list of test dates for the holiday defined in this test * * @throws Exception */ diff --git a/tests/Greece/AssumptionOfMaryTest.php b/tests/Greece/AssumptionOfMaryTest.php index 38a321417..5f246e201 100644 --- a/tests/Greece/AssumptionOfMaryTest.php +++ b/tests/Greece/AssumptionOfMaryTest.php @@ -48,7 +48,7 @@ public function testHoliday(int $year, DateTime $expected): void /** * Returns a list of random test dates used for assertion of the holiday defined in this test. * - * @return array list of test dates for the holiday defined in this test + * @return array list of test dates for the holiday defined in this test * * @throws Exception */ diff --git a/tests/Greece/ChristmasDayTest.php b/tests/Greece/ChristmasDayTest.php index f7e6e60ec..1fcf452e3 100644 --- a/tests/Greece/ChristmasDayTest.php +++ b/tests/Greece/ChristmasDayTest.php @@ -48,7 +48,7 @@ public function testHoliday(int $year, DateTime $expected): void /** * Returns a list of random test dates used for assertion of the holiday defined in this test. * - * @return array list of test dates for the holiday defined in this test + * @return array list of test dates for the holiday defined in this test * * @throws Exception */ diff --git a/tests/Greece/EpiphanyTest.php b/tests/Greece/EpiphanyTest.php index b73ba79e8..c9b973e42 100644 --- a/tests/Greece/EpiphanyTest.php +++ b/tests/Greece/EpiphanyTest.php @@ -48,7 +48,7 @@ public function testHoliday(int $year, DateTime $expected): void /** * Returns a list of random test dates used for assertion of the holiday defined in this test. * - * @return array list of test dates for the holiday defined in this test + * @return array list of test dates for the holiday defined in this test * * @throws Exception */ diff --git a/tests/Greece/InternationalWorkersDayTest.php b/tests/Greece/InternationalWorkersDayTest.php index 3b30e9528..da146b5a3 100644 --- a/tests/Greece/InternationalWorkersDayTest.php +++ b/tests/Greece/InternationalWorkersDayTest.php @@ -73,7 +73,7 @@ public function testHolidayType(): void /** * Returns a list of random test dates used for assertion of the holiday defined in this test. * - * @return array list of test dates for the holiday defined in this test + * @return array list of test dates for the holiday defined in this test * * @throws Exception */ diff --git a/tests/Greece/NewYearsDayTest.php b/tests/Greece/NewYearsDayTest.php index c2e8ec7dc..6be5a507c 100644 --- a/tests/Greece/NewYearsDayTest.php +++ b/tests/Greece/NewYearsDayTest.php @@ -73,7 +73,7 @@ public function testHolidayType(): void /** * Returns a list of random test dates used for assertion of the holiday defined in this test. * - * @return array list of test dates for the holiday defined in this test + * @return array list of test dates for the holiday defined in this test * * @throws Exception */ diff --git a/tests/Greece/ThreeHolyHierarchsTest.php b/tests/Greece/ThreeHolyHierarchsTest.php index eae7698b8..8d8a7ab36 100644 --- a/tests/Greece/ThreeHolyHierarchsTest.php +++ b/tests/Greece/ThreeHolyHierarchsTest.php @@ -48,7 +48,7 @@ public function testHoliday(int $year, DateTime $expected): void /** * Returns a list of random test dates used for assertion of the holiday defined in this test. * - * @return array list of test dates for the holiday defined in this test + * @return array list of test dates for the holiday defined in this test * * @throws Exception */ diff --git a/tests/Hungary/AllSaintsDayTest.php b/tests/Hungary/AllSaintsDayTest.php index 35f85c4c1..d2dc4fd3e 100644 --- a/tests/Hungary/AllSaintsDayTest.php +++ b/tests/Hungary/AllSaintsDayTest.php @@ -48,7 +48,7 @@ public function testHoliday(int $year, DateTime $expected): void /** * Returns a list of random test dates used for assertion of the holiday defined in this test. * - * @return array list of test dates for the holiday defined in this test + * @return array list of test dates for the holiday defined in this test * * @throws Exception */ diff --git a/tests/Hungary/ChristmasTest.php b/tests/Hungary/ChristmasTest.php index c459b593d..ed3f7d5e7 100644 --- a/tests/Hungary/ChristmasTest.php +++ b/tests/Hungary/ChristmasTest.php @@ -48,7 +48,7 @@ public function testHoliday(int $year, DateTime $expected): void /** * Returns a list of random test dates used for assertion of the holiday defined in this test. * - * @return array list of test dates for the holiday defined in this test + * @return array list of test dates for the holiday defined in this test * * @throws Exception */ diff --git a/tests/Hungary/InternationalWorkersDayTest.php b/tests/Hungary/InternationalWorkersDayTest.php index 116161df1..6665d4a5f 100644 --- a/tests/Hungary/InternationalWorkersDayTest.php +++ b/tests/Hungary/InternationalWorkersDayTest.php @@ -48,7 +48,7 @@ public function testHoliday(int $year, DateTime $expected): void /** * Returns a list of random test dates used for assertion of the holiday defined in this test. * - * @return array list of test dates for the day of the holiday defined in this test + * @return array list of test dates for the holiday defined in this test * * @throws Exception */ diff --git a/tests/Hungary/NewYearsDayTest.php b/tests/Hungary/NewYearsDayTest.php index 8b8cd3e57..f04a1c451 100644 --- a/tests/Hungary/NewYearsDayTest.php +++ b/tests/Hungary/NewYearsDayTest.php @@ -48,7 +48,7 @@ public function testHoliday(int $year, DateTime $expected): void /** * Returns a list of random test dates used for assertion of the holiday defined in this test. * - * @return array list of test dates for the holiday defined in this test + * @return array list of test dates for the holiday defined in this test * * @throws Exception */ diff --git a/tests/Hungary/SecondChristmasDayTest.php b/tests/Hungary/SecondChristmasDayTest.php index 01ab9eb04..48e2c5a8a 100644 --- a/tests/Hungary/SecondChristmasDayTest.php +++ b/tests/Hungary/SecondChristmasDayTest.php @@ -48,7 +48,7 @@ public function testHoliday(int $year, DateTime $expected): void /** * Returns a list of random test dates used for assertion of the holiday defined in this test. * - * @return array list of test dates for the holiday defined in this test + * @return array list of test dates for the holiday defined in this test * * @throws Exception */ diff --git a/tests/Ireland/AugustHolidayTest.php b/tests/Ireland/AugustHolidayTest.php index 18b78e383..d3d8e89ae 100644 --- a/tests/Ireland/AugustHolidayTest.php +++ b/tests/Ireland/AugustHolidayTest.php @@ -56,7 +56,7 @@ public function testHoliday(int $year, string $expected): void /** * Returns a list of test dates. * - * @return array list of test dates for the holiday defined in this test + * @return array list of test dates for the holiday defined in this test * * @throws Exception */ diff --git a/tests/Ireland/ChristmasDayTest.php b/tests/Ireland/ChristmasDayTest.php index 74196e2e7..fbacaa90e 100644 --- a/tests/Ireland/ChristmasDayTest.php +++ b/tests/Ireland/ChristmasDayTest.php @@ -56,7 +56,7 @@ public function testHoliday(int $year, string $expected): void /** * Returns a list of random test dates used for assertion of the holiday defined in this test. * - * @return array list of test dates for the holiday defined in this test + * @return array list of test dates for the holiday defined in this test * * @throws Exception */ diff --git a/tests/Ireland/EasterMondayTest.php b/tests/Ireland/EasterMondayTest.php index fb681c971..288c3a5a2 100644 --- a/tests/Ireland/EasterMondayTest.php +++ b/tests/Ireland/EasterMondayTest.php @@ -56,7 +56,7 @@ public function testHoliday(int $year, string $expected): void /** * Returns a list of test dates. * - * @return array list of test dates for the holiday defined in this test + * @return array list of test dates for the holiday defined in this test * * @throws Exception */ diff --git a/tests/Ireland/EasterTest.php b/tests/Ireland/EasterTest.php index 31482138b..d67e648cc 100644 --- a/tests/Ireland/EasterTest.php +++ b/tests/Ireland/EasterTest.php @@ -55,7 +55,7 @@ public function testHoliday(int $year, string $expected): void /** * Returns a list of test dates. * - * @return array list of test dates for the holiday defined in this test + * @return array list of test dates for the holiday defined in this test * * @throws Exception */ diff --git a/tests/Ireland/GoodFridayTest.php b/tests/Ireland/GoodFridayTest.php index 40a1203d9..ea83651b8 100644 --- a/tests/Ireland/GoodFridayTest.php +++ b/tests/Ireland/GoodFridayTest.php @@ -56,7 +56,7 @@ public function testHoliday(int $year, string $expected): void /** * Returns a list of random test dates used for assertion of the holiday defined in this test. * - * @return array list of test dates for the holiday defined in this test + * @return array list of test dates for the holiday defined in this test * * @throws Exception */ diff --git a/tests/Ireland/JuneHolidayTest.php b/tests/Ireland/JuneHolidayTest.php index 2bf25296e..53dd8cd30 100644 --- a/tests/Ireland/JuneHolidayTest.php +++ b/tests/Ireland/JuneHolidayTest.php @@ -61,7 +61,7 @@ public function testHoliday(int $year, string $expected): void /** * Returns a list of test dates. * - * @return array list of test dates for the holiday defined in this test + * @return array list of test dates for the holiday defined in this test * * @throws Exception */ diff --git a/tests/Ireland/MayDayTest.php b/tests/Ireland/MayDayTest.php index b6e5f655a..71e553a1a 100644 --- a/tests/Ireland/MayDayTest.php +++ b/tests/Ireland/MayDayTest.php @@ -61,7 +61,7 @@ public function testHoliday(int $year, string $expected): void /** * Returns a list of test dates. * - * @return array list of test dates for the holiday defined in this test + * @return array list of test dates for the holiday defined in this test * * @throws Exception */ diff --git a/tests/Ireland/NewYearsDayTest.php b/tests/Ireland/NewYearsDayTest.php index 1d72380ab..c1c22ae78 100644 --- a/tests/Ireland/NewYearsDayTest.php +++ b/tests/Ireland/NewYearsDayTest.php @@ -61,7 +61,7 @@ public function testHoliday(int $year, string $expected): void /** * Returns a list of random test dates used for assertion of the holiday defined in this test. * - * @return array list of test dates for the holiday defined in this test + * @return array list of test dates for the holiday defined in this test * * @throws Exception */ diff --git a/tests/Ireland/OctoberHolidayTest.php b/tests/Ireland/OctoberHolidayTest.php index 62a48a31d..f5eaaa55a 100644 --- a/tests/Ireland/OctoberHolidayTest.php +++ b/tests/Ireland/OctoberHolidayTest.php @@ -61,7 +61,7 @@ public function testHoliday(int $year, string $expected): void /** * Returns a list of test dates. * - * @return array list of test dates for the holiday defined in this test + * @return array list of test dates for the holiday defined in this test * * @throws Exception */ diff --git a/tests/Ireland/PentecostTest.php b/tests/Ireland/PentecostTest.php index 5d560850a..5ff81dbc4 100644 --- a/tests/Ireland/PentecostTest.php +++ b/tests/Ireland/PentecostTest.php @@ -56,7 +56,7 @@ public function testHoliday(int $year, string $expected): void /** * Returns a list of random test dates used for assertion of the holiday defined in this test. * - * @return array list of test dates for the holiday defined in this test + * @return array list of test dates for the holiday defined in this test * * @throws Exception */ diff --git a/tests/Ireland/StPatricksDayTest.php b/tests/Ireland/StPatricksDayTest.php index 25c6a16fe..24cca4d57 100644 --- a/tests/Ireland/StPatricksDayTest.php +++ b/tests/Ireland/StPatricksDayTest.php @@ -61,7 +61,7 @@ public function testHoliday(int $year, string $expected): void /** * Returns a list of random test dates used for assertion of the holiday defined in this test. * - * @return array list of test dates for the holiday defined in this test + * @return array list of test dates for the holiday defined in this test * * @throws Exception */ diff --git a/tests/Ireland/StStephensDayTest.php b/tests/Ireland/StStephensDayTest.php index d4f5939d4..dc654abce 100644 --- a/tests/Ireland/StStephensDayTest.php +++ b/tests/Ireland/StStephensDayTest.php @@ -56,7 +56,7 @@ public function testHoliday(int $year, string $expected): void /** * Returns a list of random test dates used for assertion of the holiday defined in this test. * - * @return array list of test dates for the holiday defined in this test + * @return array list of test dates for the holiday defined in this test * * @throws Exception */ diff --git a/tests/Ireland/pentecostMondayTest.php b/tests/Ireland/pentecostMondayTest.php index bf47459cf..5a859f746 100644 --- a/tests/Ireland/pentecostMondayTest.php +++ b/tests/Ireland/pentecostMondayTest.php @@ -61,7 +61,7 @@ public function testHoliday(int $year, string $expected): void /** * Returns a list of random test dates used for assertion of the holiday defined in this test. * - * @return array list of test dates for the holiday defined in this test + * @return array list of test dates for the holiday defined in this test * * @throws Exception */ diff --git a/tests/Italy/AllSaintsDayTest.php b/tests/Italy/AllSaintsDayTest.php index 897d1931a..2a67908b3 100644 --- a/tests/Italy/AllSaintsDayTest.php +++ b/tests/Italy/AllSaintsDayTest.php @@ -48,7 +48,7 @@ public function testAssumptionOfMary(int $year, DateTime $expected): void /** * Returns a list of random test dates used for assertion of All Saints' Day. * - * @return array list of test dates for All Saints' Day + * @return array list of test dates for All Saints' Day * * @throws Exception */ diff --git a/tests/Italy/AssumptionOfMaryTest.php b/tests/Italy/AssumptionOfMaryTest.php index c0784d0cf..74c5e1558 100644 --- a/tests/Italy/AssumptionOfMaryTest.php +++ b/tests/Italy/AssumptionOfMaryTest.php @@ -48,7 +48,7 @@ public function testAssumptionOfMary(int $year, DateTime $expected): void /** * Returns a list of random test dates used for assertion of the day of the Assumption of Mary. * - * @return array list of test dates for the day of the Assumption of Mary + * @return array list of test dates for the day of the Assumption of Mary * * @throws Exception */ diff --git a/tests/Italy/ChristmasTest.php b/tests/Italy/ChristmasTest.php index b587483dd..cf365feac 100644 --- a/tests/Italy/ChristmasTest.php +++ b/tests/Italy/ChristmasTest.php @@ -48,7 +48,7 @@ public function testChristmasDay(int $year, DateTime $expected): void /** * Returns a list of random test dates used for assertion of Christmas Day. * - * @return array list of test dates for Christmas Day + * @return array list of test dates for Christmas Day * * @throws Exception */ diff --git a/tests/Italy/EpiphanyTest.php b/tests/Italy/EpiphanyTest.php index 65b9dab0b..b5bec4d86 100644 --- a/tests/Italy/EpiphanyTest.php +++ b/tests/Italy/EpiphanyTest.php @@ -48,7 +48,7 @@ public function testEpiphany(int $year, DateTime $expected): void /** * Returns a list of random test dates used for assertion of Epiphany. * - * @return array list of test dates for Epiphany + * @return array list of test dates for Epiphany * * @throws Exception */ diff --git a/tests/Italy/ImmaculateConceptionTest.php b/tests/Italy/ImmaculateConceptionTest.php index 0e63b489e..735d0f3ca 100644 --- a/tests/Italy/ImmaculateConceptionTest.php +++ b/tests/Italy/ImmaculateConceptionTest.php @@ -48,7 +48,7 @@ public function testImmaculateConception(int $year, DateTime $expected): void /** * Returns a list of random test dates used for assertion of the day of Immaculate Conception. * - * @return array list of test dates for the day of Immaculate Conception + * @return array list of test dates for the day of Immaculate Conception * * @throws Exception */ diff --git a/tests/Italy/InternationalWorkersDayTest.php b/tests/Italy/InternationalWorkersDayTest.php index 5e0c78834..aedfeb4f3 100644 --- a/tests/Italy/InternationalWorkersDayTest.php +++ b/tests/Italy/InternationalWorkersDayTest.php @@ -48,7 +48,7 @@ public function testInternationalWorkersDay(int $year, DateTime $expected): void /** * Returns a list of random test dates used for assertion of International Workers' Day. * - * @return array list of test dates for International Workers' Day + * @return array list of test dates for International Workers' Day * * @throws Exception */ diff --git a/tests/Italy/NewYearsDayTest.php b/tests/Italy/NewYearsDayTest.php index ded8bb194..5e1875602 100644 --- a/tests/Italy/NewYearsDayTest.php +++ b/tests/Italy/NewYearsDayTest.php @@ -48,7 +48,7 @@ public function testNewYearsDay(int $year, DateTime $expected): void /** * Returns a list of random test dates used for assertion of New Years Day. * - * @return array list of test dates for New Years Day + * @return array list of test dates for New Years Day * * @throws Exception */ diff --git a/tests/Italy/stStephensDayTest.php b/tests/Italy/stStephensDayTest.php index 918138e98..83fe92e53 100644 --- a/tests/Italy/stStephensDayTest.php +++ b/tests/Italy/stStephensDayTest.php @@ -48,7 +48,7 @@ public function teststStephensDay(int $year, DateTime $expected): void /** * Returns a list of random test dates used for assertion of St. Stephen's Day. * - * @return array list of test dates for St. Stephen's Day + * @return array list of test dates for St. Stephen's Day * * @throws Exception */ diff --git a/tests/Japan/AutumnalEquinoxDayTest.php b/tests/Japan/AutumnalEquinoxDayTest.php index f480ab92c..d1931c739 100644 --- a/tests/Japan/AutumnalEquinoxDayTest.php +++ b/tests/Japan/AutumnalEquinoxDayTest.php @@ -79,7 +79,7 @@ public function testAutumnalEquinoxDayBetween1948And2150(int $year, int $month, /** * Returns a list of all Japanese Autumnal Equinox holidays used for assertions. * - * @return array list of Japanese Autumnal Equinox holidays + * @return array list of test dates for the holiday defined in this test */ public function autumnalEquinoxHolidaysProvider(): array { diff --git a/tests/Japan/VernalEquinoxDayTest.php b/tests/Japan/VernalEquinoxDayTest.php index 332df9e8e..cdc015e03 100644 --- a/tests/Japan/VernalEquinoxDayTest.php +++ b/tests/Japan/VernalEquinoxDayTest.php @@ -79,7 +79,7 @@ public function testVernalEquinoxDayBetween1948And2150(int $year, int $month, in /** * Returns a list of all Japanese Vernal Equinox holidays used for assertions. * - * @return array list of Japanese Vernal Equinox holidays + * @return array list of test dates for the holiday defined in this test */ public function vernalEquinoxHolidaysProvider(): array { diff --git a/tests/Latvia/ChristmasDayTest.php b/tests/Latvia/ChristmasDayTest.php index 4a1be1a82..61257cb51 100644 --- a/tests/Latvia/ChristmasDayTest.php +++ b/tests/Latvia/ChristmasDayTest.php @@ -34,6 +34,8 @@ class ChristmasDayTest extends LatviaBaseTestCase implements HolidayTestCase public const HOLIDAY = 'christmasDay'; /** + * @return array list of test dates for the holiday defined in this test + * * @throws Exception */ public function holidayDataProvider(): array diff --git a/tests/Latvia/ChristmasEveDayTest.php b/tests/Latvia/ChristmasEveDayTest.php index e26f7ec65..cf1665771 100644 --- a/tests/Latvia/ChristmasEveDayTest.php +++ b/tests/Latvia/ChristmasEveDayTest.php @@ -34,6 +34,8 @@ class ChristmasEveDayTest extends LatviaBaseTestCase implements HolidayTestCase public const HOLIDAY = 'christmasEve'; /** + * @return array list of test dates for the holiday defined in this test + * * @throws Exception */ public function holidayDataProvider(): array diff --git a/tests/Latvia/EasterDayTest.php b/tests/Latvia/EasterDayTest.php index f997a4c38..05a464e60 100644 --- a/tests/Latvia/EasterDayTest.php +++ b/tests/Latvia/EasterDayTest.php @@ -35,6 +35,8 @@ class EasterDayTest extends LatviaBaseTestCase implements HolidayTestCase public const HOLIDAY = 'easter'; /** + * @return array list of test dates for the holiday defined in this test + * * @throws Exception */ public function holidayDataProvider(): array diff --git a/tests/Latvia/EasterMondayDayTest.php b/tests/Latvia/EasterMondayDayTest.php index 6f8b4dd24..76e8595d2 100644 --- a/tests/Latvia/EasterMondayDayTest.php +++ b/tests/Latvia/EasterMondayDayTest.php @@ -35,6 +35,8 @@ class EasterMondayDayTest extends LatviaBaseTestCase implements HolidayTestCase public const HOLIDAY = 'easterMonday'; /** + * @return array list of test dates for the holiday defined in this test + * * @throws Exception */ public function holidayDataProvider(): array diff --git a/tests/Latvia/GoodFridayDayTest.php b/tests/Latvia/GoodFridayDayTest.php index a62d51e9e..66c02497b 100644 --- a/tests/Latvia/GoodFridayDayTest.php +++ b/tests/Latvia/GoodFridayDayTest.php @@ -35,6 +35,8 @@ class GoodFridayDayTest extends LatviaBaseTestCase implements HolidayTestCase public const HOLIDAY = 'goodFriday'; /** + * @return array list of test dates for the holiday defined in this test + * * @throws Exception */ public function holidayDataProvider(): array diff --git a/tests/Latvia/InternationalWorkersDayTest.php b/tests/Latvia/InternationalWorkersDayTest.php index 01c59ac4f..5d6161566 100644 --- a/tests/Latvia/InternationalWorkersDayTest.php +++ b/tests/Latvia/InternationalWorkersDayTest.php @@ -34,6 +34,8 @@ class InternationalWorkersDayTest extends LatviaBaseTestCase implements HolidayT public const HOLIDAY = 'internationalWorkersDay'; /** + * @return array list of test dates for the holiday defined in this test + * * @throws Exception */ public function holidayDataProvider(): array diff --git a/tests/Latvia/MidsummerEveDayTest.php b/tests/Latvia/MidsummerEveDayTest.php index 2efc2262e..e2a6ac2a6 100644 --- a/tests/Latvia/MidsummerEveDayTest.php +++ b/tests/Latvia/MidsummerEveDayTest.php @@ -34,6 +34,8 @@ class MidsummerEveDayTest extends LatviaBaseTestCase implements HolidayTestCase public const HOLIDAY = 'midsummerEveDay'; /** + * @return array list of test dates for the holiday defined in this test + * * @throws Exception */ public function holidayDataProvider(): array diff --git a/tests/Latvia/NewYearsDayTest.php b/tests/Latvia/NewYearsDayTest.php index db7462582..04caa1309 100644 --- a/tests/Latvia/NewYearsDayTest.php +++ b/tests/Latvia/NewYearsDayTest.php @@ -34,6 +34,8 @@ class NewYearsDayTest extends LatviaBaseTestCase implements HolidayTestCase public const HOLIDAY = 'newYearsDay'; /** + * @return array list of test dates for the holiday defined in this test + * * @throws Exception */ public function holidayDataProvider(): array diff --git a/tests/Latvia/NewYearsEveDayTest.php b/tests/Latvia/NewYearsEveDayTest.php index 003e7bd7b..b37c24e69 100644 --- a/tests/Latvia/NewYearsEveDayTest.php +++ b/tests/Latvia/NewYearsEveDayTest.php @@ -34,6 +34,8 @@ class NewYearsEveDayTest extends LatviaBaseTestCase implements HolidayTestCase public const HOLIDAY = 'newYearsEve'; /** + * @return array list of test dates for the holiday defined in this test + * * @throws Exception */ public function holidayDataProvider(): array diff --git a/tests/Latvia/ProclamationOfTheRepublicOfLatviaDayTest.php b/tests/Latvia/ProclamationOfTheRepublicOfLatviaDayTest.php index 16a8fb447..3f6e6f577 100644 --- a/tests/Latvia/ProclamationOfTheRepublicOfLatviaDayTest.php +++ b/tests/Latvia/ProclamationOfTheRepublicOfLatviaDayTest.php @@ -50,6 +50,8 @@ public function testNotHoliday(): void } /** + * @return array list of test dates for the holiday defined in this test + * * @throws Exception */ public function holidayDataProvider(): array diff --git a/tests/Latvia/RestorationOfIndependenceDayTest.php b/tests/Latvia/RestorationOfIndependenceDayTest.php index f201a4479..1011987cb 100644 --- a/tests/Latvia/RestorationOfIndependenceDayTest.php +++ b/tests/Latvia/RestorationOfIndependenceDayTest.php @@ -50,6 +50,8 @@ public function testNotHoliday(): void } /** + * @return array list of test dates for the holiday defined in this test + * * @throws Exception */ public function holidayDataProvider(): array diff --git a/tests/Latvia/SecondChristmasDayTest.php b/tests/Latvia/SecondChristmasDayTest.php index 3f03e31b5..b6f8e5d76 100644 --- a/tests/Latvia/SecondChristmasDayTest.php +++ b/tests/Latvia/SecondChristmasDayTest.php @@ -34,6 +34,8 @@ class SecondChristmasDayTest extends LatviaBaseTestCase implements HolidayTestCa public const HOLIDAY = 'secondChristmasDay'; /** + * @return array list of test dates for the holiday defined in this test + * * @throws Exception */ public function holidayDataProvider(): array diff --git a/tests/Latvia/StJohnsDayTest.php b/tests/Latvia/StJohnsDayTest.php index daf71dd61..db3d67077 100644 --- a/tests/Latvia/StJohnsDayTest.php +++ b/tests/Latvia/StJohnsDayTest.php @@ -34,6 +34,8 @@ class StJohnsDayTest extends LatviaBaseTestCase implements HolidayTestCase public const HOLIDAY = 'stJohnsDay'; /** + * @return array list of test dates for the holiday defined in this test + * * @throws Exception */ public function holidayDataProvider(): array diff --git a/tests/Lithuania/AllSaintsDayTest.php b/tests/Lithuania/AllSaintsDayTest.php index a43f7f778..5438552f2 100644 --- a/tests/Lithuania/AllSaintsDayTest.php +++ b/tests/Lithuania/AllSaintsDayTest.php @@ -34,6 +34,8 @@ class AllSaintsDayTest extends LithuaniaBaseTestCase implements HolidayTestCase public const HOLIDAY = 'allSaintsDay'; /** + * @return array list of test dates for the holiday defined in this test + * * @throws Exception */ public function holidayDataProvider(): array diff --git a/tests/Lithuania/AssumptionOfMaryDayTest.php b/tests/Lithuania/AssumptionOfMaryDayTest.php index dcc56b2eb..9073f0cf7 100644 --- a/tests/Lithuania/AssumptionOfMaryDayTest.php +++ b/tests/Lithuania/AssumptionOfMaryDayTest.php @@ -34,6 +34,8 @@ class AssumptionOfMaryDayTest extends LithuaniaBaseTestCase implements HolidayTe public const HOLIDAY = 'assumptionOfMary'; /** + * @return array list of test dates for the holiday defined in this test + * * @throws Exception */ public function holidayDataProvider(): array diff --git a/tests/Lithuania/ChristmasDayTest.php b/tests/Lithuania/ChristmasDayTest.php index 77120c4f4..85343e6f1 100644 --- a/tests/Lithuania/ChristmasDayTest.php +++ b/tests/Lithuania/ChristmasDayTest.php @@ -34,6 +34,8 @@ class ChristmasDayTest extends LithuaniaBaseTestCase implements HolidayTestCase public const HOLIDAY = 'christmasDay'; /** + * @return array list of test dates for the holiday defined in this test + * * @throws Exception */ public function holidayDataProvider(): array diff --git a/tests/Lithuania/ChristmasEveDayTest.php b/tests/Lithuania/ChristmasEveDayTest.php index c803e3e28..4794ac8c2 100644 --- a/tests/Lithuania/ChristmasEveDayTest.php +++ b/tests/Lithuania/ChristmasEveDayTest.php @@ -34,6 +34,8 @@ class ChristmasEveDayTest extends LithuaniaBaseTestCase implements HolidayTestCa public const HOLIDAY = 'christmasEve'; /** + * @return array list of test dates for the holiday defined in this test + * * @throws Exception */ public function holidayDataProvider(): array diff --git a/tests/Lithuania/EasterDayTest.php b/tests/Lithuania/EasterDayTest.php index e6eb0edf2..4196a7798 100644 --- a/tests/Lithuania/EasterDayTest.php +++ b/tests/Lithuania/EasterDayTest.php @@ -35,6 +35,8 @@ class EasterDayTest extends LithuaniaBaseTestCase implements HolidayTestCase public const HOLIDAY = 'easter'; /** + * @return array list of test dates for the holiday defined in this test + * * @throws Exception */ public function holidayDataProvider(): array diff --git a/tests/Lithuania/EasterMondayDayTest.php b/tests/Lithuania/EasterMondayDayTest.php index 55654a943..f8c31e50c 100644 --- a/tests/Lithuania/EasterMondayDayTest.php +++ b/tests/Lithuania/EasterMondayDayTest.php @@ -35,6 +35,8 @@ class EasterMondayDayTest extends LithuaniaBaseTestCase implements HolidayTestCa public const HOLIDAY = 'easterMonday'; /** + * @return array list of test dates for the holiday defined in this test + * * @throws Exception */ public function holidayDataProvider(): array diff --git a/tests/Lithuania/InternationalWorkersDayTest.php b/tests/Lithuania/InternationalWorkersDayTest.php index 838833339..aae7d5ed6 100644 --- a/tests/Lithuania/InternationalWorkersDayTest.php +++ b/tests/Lithuania/InternationalWorkersDayTest.php @@ -34,6 +34,8 @@ class InternationalWorkersDayTest extends LithuaniaBaseTestCase implements Holid public const HOLIDAY = 'internationalWorkersDay'; /** + * @return array list of test dates for the holiday defined in this test + * * @throws Exception */ public function holidayDataProvider(): array diff --git a/tests/Lithuania/NewYearsDayTest.php b/tests/Lithuania/NewYearsDayTest.php index 2a159e726..00fa10092 100644 --- a/tests/Lithuania/NewYearsDayTest.php +++ b/tests/Lithuania/NewYearsDayTest.php @@ -34,6 +34,8 @@ class NewYearsDayTest extends LithuaniaBaseTestCase implements HolidayTestCase public const HOLIDAY = 'newYearsDay'; /** + * @return array list of test dates for the holiday defined in this test + * * @throws Exception */ public function holidayDataProvider(): array diff --git a/tests/Lithuania/SecondChristmasDayTest.php b/tests/Lithuania/SecondChristmasDayTest.php index 4980750b2..b05554e21 100644 --- a/tests/Lithuania/SecondChristmasDayTest.php +++ b/tests/Lithuania/SecondChristmasDayTest.php @@ -34,6 +34,8 @@ class SecondChristmasDayTest extends LithuaniaBaseTestCase implements HolidayTes public const HOLIDAY = 'secondChristmasDay'; /** + * @return array list of test dates for the holiday defined in this test + * * @throws Exception */ public function holidayDataProvider(): array diff --git a/tests/Lithuania/StJohnsDayTest.php b/tests/Lithuania/StJohnsDayTest.php index 8affc1f7f..392bff7b5 100644 --- a/tests/Lithuania/StJohnsDayTest.php +++ b/tests/Lithuania/StJohnsDayTest.php @@ -34,6 +34,8 @@ class StJohnsDayTest extends LithuaniaBaseTestCase implements HolidayTestCase public const HOLIDAY = 'stJohnsDay'; /** + * @return array list of test dates for the holiday defined in this test + * * @throws Exception */ public function holidayDataProvider(): array diff --git a/tests/Luxembourg/AllSaintsDayTest.php b/tests/Luxembourg/AllSaintsDayTest.php index 1c7f25897..44a388f8a 100644 --- a/tests/Luxembourg/AllSaintsDayTest.php +++ b/tests/Luxembourg/AllSaintsDayTest.php @@ -73,7 +73,7 @@ public function testHolidayType(): void /** * Returns a list of random test dates used for assertion of All Saints' Day. * - * @return array list of test dates for All Saints' Day + * @return array list of test dates for All Saints' Day * * @throws Exception */ diff --git a/tests/Luxembourg/AssumptionOfMaryTest.php b/tests/Luxembourg/AssumptionOfMaryTest.php index b7f39db4b..f611451cd 100644 --- a/tests/Luxembourg/AssumptionOfMaryTest.php +++ b/tests/Luxembourg/AssumptionOfMaryTest.php @@ -48,7 +48,7 @@ public function testHoliday(int $year, DateTime $expected): void /** * Returns a list of random test dates used for assertion of the holiday defined in this test. * - * @return array list of test dates for the holiday defined in this test + * @return array list of test dates for the holiday defined in this test * * @throws Exception */ diff --git a/tests/Luxembourg/ChristmasDayTest.php b/tests/Luxembourg/ChristmasDayTest.php index cdc59359c..cbb6cc9c4 100644 --- a/tests/Luxembourg/ChristmasDayTest.php +++ b/tests/Luxembourg/ChristmasDayTest.php @@ -48,7 +48,7 @@ public function testChristmasDay(int $year, DateTime $expected): void /** * Returns a list of random test dates used for assertion of Christmas Day. * - * @return array list of test dates for Christmas Day + * @return array list of test dates for Christmas Day * * @throws Exception */ diff --git a/tests/Luxembourg/InternationalWorkersDayTest.php b/tests/Luxembourg/InternationalWorkersDayTest.php index 23c99e0ba..9838ef820 100644 --- a/tests/Luxembourg/InternationalWorkersDayTest.php +++ b/tests/Luxembourg/InternationalWorkersDayTest.php @@ -73,7 +73,7 @@ public function testHolidayType(): void /** * Returns a list of random test dates used for assertion of International Workers' Day. * - * @return array list of test dates for International Workers' Day + * @return array list of test dates for International Workers' Day * * @throws Exception */ diff --git a/tests/Luxembourg/NationalDayTest.php b/tests/Luxembourg/NationalDayTest.php index 611908d44..6b586e173 100644 --- a/tests/Luxembourg/NationalDayTest.php +++ b/tests/Luxembourg/NationalDayTest.php @@ -48,7 +48,7 @@ public function testHoliday(int $year, DateTime $expected): void /** * Returns a list of random test dates used for assertion of the holiday defined in this test. * - * @return array list of test dates for the holiday defined in this test + * @return array list of test dates for the holiday defined in this test * * @throws Exception */ diff --git a/tests/Luxembourg/NewYearsDayTest.php b/tests/Luxembourg/NewYearsDayTest.php index 2a23fffb2..ab90746f7 100644 --- a/tests/Luxembourg/NewYearsDayTest.php +++ b/tests/Luxembourg/NewYearsDayTest.php @@ -73,7 +73,7 @@ public function testHolidayType(): void /** * Returns a list of random test dates used for assertion of New Years Day. * - * @return array list of test dates for New Years Day + * @return array list of test dates for New Years Day * * @throws Exception */ diff --git a/tests/Luxembourg/SecondChristmasDayTest.php b/tests/Luxembourg/SecondChristmasDayTest.php index d545babc7..65b03ebf5 100644 --- a/tests/Luxembourg/SecondChristmasDayTest.php +++ b/tests/Luxembourg/SecondChristmasDayTest.php @@ -48,7 +48,7 @@ public function testHoliday(int $year, DateTime $expected): void /** * Returns a list of random test dates used for assertion of the holiday defined in this test. * - * @return array list of test dates for the holiday defined in this test + * @return array list of test dates for the holiday defined in this test * * @throws Exception */ diff --git a/tests/Netherlands/ChristmasDayTest.php b/tests/Netherlands/ChristmasDayTest.php index 1f5e77695..95e0e8936 100644 --- a/tests/Netherlands/ChristmasDayTest.php +++ b/tests/Netherlands/ChristmasDayTest.php @@ -48,7 +48,7 @@ public function testHoliday(int $year, DateTime $expected): void /** * Returns a list of random test dates used for assertion of the holiday defined in this test. * - * @return array list of test dates for the holiday defined in this test + * @return array list of test dates for the holiday defined in this test * * @throws Exception */ diff --git a/tests/Netherlands/EpiphanyTest.php b/tests/Netherlands/EpiphanyTest.php index e212782d2..b18d77e09 100644 --- a/tests/Netherlands/EpiphanyTest.php +++ b/tests/Netherlands/EpiphanyTest.php @@ -48,7 +48,7 @@ public function testEpiphany(int $year, DateTime $expected): void /** * Returns a list of random test dates used for assertion of Epiphany. * - * @return array list of test dates for Epiphany + * @return array list of test dates for Epiphany * * @throws Exception */ diff --git a/tests/Netherlands/HalloweenTest.php b/tests/Netherlands/HalloweenTest.php index 8d2e8d3a3..c8d8d9d79 100644 --- a/tests/Netherlands/HalloweenTest.php +++ b/tests/Netherlands/HalloweenTest.php @@ -48,7 +48,7 @@ public function testHoliday(int $year, DateTime $expected): void /** * Returns a list of random test dates used for assertion of Halloween. * - * @return array list of test dates for Halloween + * @return array list of test dates for Halloween * * @throws Exception */ diff --git a/tests/Netherlands/InternationalWorkersDayTest.php b/tests/Netherlands/InternationalWorkersDayTest.php index 2a43d55ab..1f47024d4 100644 --- a/tests/Netherlands/InternationalWorkersDayTest.php +++ b/tests/Netherlands/InternationalWorkersDayTest.php @@ -48,7 +48,7 @@ public function testInternationalWorkersDay(int $year, DateTime $expected): void /** * Returns a list of random test dates used for assertion of International Workers' Day. * - * @return array list of test dates for International Workers' Day + * @return array list of test dates for International Workers' Day * * @throws Exception */ diff --git a/tests/Netherlands/NewYearsDayTest.php b/tests/Netherlands/NewYearsDayTest.php index 5cb5c308f..66eb9b681 100644 --- a/tests/Netherlands/NewYearsDayTest.php +++ b/tests/Netherlands/NewYearsDayTest.php @@ -48,7 +48,7 @@ public function testNewYearsDay(int $year, DateTime $expected): void /** * Returns a list of random test dates used for assertion of New Years Day. * - * @return array list of test dates for New Years Day + * @return array list of test dates for New Years Day * * @throws Exception */ diff --git a/tests/Netherlands/ValentinesDayTest.php b/tests/Netherlands/ValentinesDayTest.php index 0110d0702..4bb8b2a3b 100644 --- a/tests/Netherlands/ValentinesDayTest.php +++ b/tests/Netherlands/ValentinesDayTest.php @@ -48,7 +48,7 @@ public function testValentinesDay(int $year, DateTime $expected): void /** * Returns a list of random test dates used for assertion of Valentines Day. * - * @return array list of test dates for Valentines Day + * @return array list of test dates for Valentines Day * * @throws Exception */ diff --git a/tests/Netherlands/secondChristmasdayTest.php b/tests/Netherlands/secondChristmasdayTest.php index a596dc7c9..218effec2 100644 --- a/tests/Netherlands/secondChristmasdayTest.php +++ b/tests/Netherlands/secondChristmasdayTest.php @@ -48,7 +48,7 @@ public function testHoliday(int $year, DateTime $expected): void /** * Returns a list of random test dates used for assertion of the holiday defined in this test. * - * @return array list of test dates for the holiday defined in this test + * @return array list of test dates for the holiday defined in this test * * @throws Exception */ diff --git a/tests/Netherlands/stMartinsDayTest.php b/tests/Netherlands/stMartinsDayTest.php index c6ffe1466..5aeecdd96 100644 --- a/tests/Netherlands/stMartinsDayTest.php +++ b/tests/Netherlands/stMartinsDayTest.php @@ -48,7 +48,7 @@ public function teststMartinsDay(int $year, DateTime $expected): void /** * Returns a list of random test dates used for assertion of Sint Martins Day. * - * @return array list of test dates for Sint Martins Day + * @return array list of test dates for Sint Martins Day * * @throws Exception */ diff --git a/tests/Netherlands/stNicholasDayTest.php b/tests/Netherlands/stNicholasDayTest.php index d05f3d308..e816f5139 100644 --- a/tests/Netherlands/stNicholasDayTest.php +++ b/tests/Netherlands/stNicholasDayTest.php @@ -48,7 +48,7 @@ public function teststNicholasDay(int $year, DateTime $expected): void /** * Returns a list of random test dates used for assertion of Sint Nicholas Day. * - * @return array list of test dates for Sint Nicholas Day + * @return array list of test dates for Sint Nicholas Day * * @throws Exception */ diff --git a/tests/NewZealand/AnzacDayTest.php b/tests/NewZealand/AnzacDayTest.php index c14c66111..e1d321e35 100644 --- a/tests/NewZealand/AnzacDayTest.php +++ b/tests/NewZealand/AnzacDayTest.php @@ -70,7 +70,7 @@ public function testNotHoliday(): void /** * Returns a list of test dates. * - * @return array list of test dates for the holiday defined in this test + * @return array list of test dates for the holiday defined in this test * * @throws Exception */ diff --git a/tests/NewZealand/BoxingDayTest.php b/tests/NewZealand/BoxingDayTest.php index 4a70b6b4f..939b8819d 100644 --- a/tests/NewZealand/BoxingDayTest.php +++ b/tests/NewZealand/BoxingDayTest.php @@ -56,7 +56,7 @@ public function testHoliday(int $year, string $expected): void /** * Returns a list of test dates. * - * @return array list of test dates for the holiday defined in this test + * @return array list of test dates for the holiday defined in this test * * @throws Exception */ diff --git a/tests/NewZealand/ChristmasDayTest.php b/tests/NewZealand/ChristmasDayTest.php index d5430dfa0..895701da2 100644 --- a/tests/NewZealand/ChristmasDayTest.php +++ b/tests/NewZealand/ChristmasDayTest.php @@ -56,7 +56,7 @@ public function testHoliday(int $year, string $expected): void /** * Returns a list of test dates. * - * @return array list of test dates for the holiday defined in this test + * @return array list of test dates for the holiday defined in this test * * @throws Exception */ diff --git a/tests/NewZealand/DayAfterNewYearsDayTest.php b/tests/NewZealand/DayAfterNewYearsDayTest.php index e845eabcb..1efaca72a 100644 --- a/tests/NewZealand/DayAfterNewYearsDayTest.php +++ b/tests/NewZealand/DayAfterNewYearsDayTest.php @@ -81,7 +81,7 @@ public function testHolidayType(): void /** * Returns a list of test dates. * - * @return array list of test dates for the holiday defined in this test + * @return array list of test dates for the holiday defined in this test * * @throws Exception */ diff --git a/tests/NewZealand/EasterMondayTest.php b/tests/NewZealand/EasterMondayTest.php index d84fb09c2..5d41f6461 100644 --- a/tests/NewZealand/EasterMondayTest.php +++ b/tests/NewZealand/EasterMondayTest.php @@ -56,7 +56,7 @@ public function testHoliday(int $year, string $expected): void /** * Returns a list of test dates. * - * @return array list of test dates for the holiday defined in this test + * @return array list of test dates for the holiday defined in this test * * @throws Exception */ diff --git a/tests/NewZealand/GoodFridayTest.php b/tests/NewZealand/GoodFridayTest.php index de93445a0..80ac99751 100644 --- a/tests/NewZealand/GoodFridayTest.php +++ b/tests/NewZealand/GoodFridayTest.php @@ -56,7 +56,7 @@ public function testHoliday(int $year, string $expected): void /** * Returns a list of test dates. * - * @return array list of test dates for the holiday defined in this test + * @return array list of test dates for the holiday defined in this test * * @throws Exception */ diff --git a/tests/NewZealand/LabourDayTest.php b/tests/NewZealand/LabourDayTest.php index 91c9ec0ad..dbd5d4464 100644 --- a/tests/NewZealand/LabourDayTest.php +++ b/tests/NewZealand/LabourDayTest.php @@ -70,7 +70,7 @@ public function testNotHoliday(): void /** * Returns a list of test dates. * - * @return array list of test dates for the holiday defined in this test + * @return array list of test dates for the holiday defined in this test * * @throws Exception */ diff --git a/tests/NewZealand/NewYearsDayTest.php b/tests/NewZealand/NewYearsDayTest.php index 979d67a0f..57d251a18 100644 --- a/tests/NewZealand/NewYearsDayTest.php +++ b/tests/NewZealand/NewYearsDayTest.php @@ -56,7 +56,7 @@ public function testHoliday(int $year, string $expected): void /** * Returns a list of test dates. * - * @return array list of test dates for the holiday defined in this test + * @return array list of test dates for the holiday defined in this test * * @throws Exception */ diff --git a/tests/NewZealand/QueensBirthdayTest.php b/tests/NewZealand/QueensBirthdayTest.php index 46e7e999d..1d0b5e2c2 100644 --- a/tests/NewZealand/QueensBirthdayTest.php +++ b/tests/NewZealand/QueensBirthdayTest.php @@ -64,7 +64,7 @@ public function testNotHoliday(): void /** * Returns a list of test dates. * - * @return array list of test dates for the holiday defined in this test + * @return array list of test dates for the holiday defined in this test * * @throws Exception */ diff --git a/tests/NewZealand/WaitangiDayTest.php b/tests/NewZealand/WaitangiDayTest.php index 695974971..85a9188b3 100644 --- a/tests/NewZealand/WaitangiDayTest.php +++ b/tests/NewZealand/WaitangiDayTest.php @@ -100,7 +100,7 @@ public function testHolidayType(): void /** * Returns a list of test dates. * - * @return array list of test dates for the holiday defined in this test + * @return array list of test dates for the holiday defined in this test * * @throws Exception */ diff --git a/tests/Norway/ChristmasDayTest.php b/tests/Norway/ChristmasDayTest.php index 069fbe93c..a867d0ee5 100644 --- a/tests/Norway/ChristmasDayTest.php +++ b/tests/Norway/ChristmasDayTest.php @@ -48,7 +48,7 @@ public function testHoliday(int $year, DateTime $expected): void /** * Returns a list of random test dates used for assertion of the holiday defined in this test. * - * @return array list of test dates for the holiday defined in this test + * @return array list of test dates for the holiday defined in this test * * @throws Exception */ diff --git a/tests/Norway/InternationalWorkersDayTest.php b/tests/Norway/InternationalWorkersDayTest.php index a7de3128f..64fb62ed3 100644 --- a/tests/Norway/InternationalWorkersDayTest.php +++ b/tests/Norway/InternationalWorkersDayTest.php @@ -73,7 +73,7 @@ public function testHolidayType(): void /** * Returns a list of random test dates used for assertion of International Workers' Day. * - * @return array list of test dates for International Workers' Day + * @return array list of test dates for International Workers' Day * * @throws Exception */ diff --git a/tests/Norway/NewYearsDayTest.php b/tests/Norway/NewYearsDayTest.php index f71bfcd15..acbe32565 100644 --- a/tests/Norway/NewYearsDayTest.php +++ b/tests/Norway/NewYearsDayTest.php @@ -48,7 +48,7 @@ public function testHoliday(int $year, DateTime $expected): void /** * Returns a list of random test dates used for assertion of the holiday defined in this test. * - * @return array list of test dates for the holiday defined in this test + * @return array list of test dates for the holiday defined in this test * * @throws Exception */ diff --git a/tests/Norway/SecondChristmasDayTest.php b/tests/Norway/SecondChristmasDayTest.php index ba0cc4e0b..dcabc13c5 100644 --- a/tests/Norway/SecondChristmasDayTest.php +++ b/tests/Norway/SecondChristmasDayTest.php @@ -48,7 +48,7 @@ public function testHoliday(int $year, DateTime $expected): void /** * Returns a list of random test dates used for assertion of the holiday defined in this test. * - * @return array list of test dates for the holiday defined in this test + * @return array list of test dates for the holiday defined in this test * * @throws Exception */ diff --git a/tests/Poland/AllSaintsDayTest.php b/tests/Poland/AllSaintsDayTest.php index 0c361b020..05932e8fe 100644 --- a/tests/Poland/AllSaintsDayTest.php +++ b/tests/Poland/AllSaintsDayTest.php @@ -48,7 +48,7 @@ public function testHoliday(int $year, DateTime $expected): void /** * Returns a list of random test dates used for assertion of the holiday defined in this test. * - * @return array list of test dates for the holiday defined in this test + * @return array list of test dates for the holiday defined in this test * * @throws Exception */ diff --git a/tests/Poland/AssumptionOfMaryTest.php b/tests/Poland/AssumptionOfMaryTest.php index 6d1432994..1030ee8da 100644 --- a/tests/Poland/AssumptionOfMaryTest.php +++ b/tests/Poland/AssumptionOfMaryTest.php @@ -48,7 +48,7 @@ public function testHoliday(int $year, DateTime $expected): void /** * Returns a list of random test dates used for assertion of the holiday defined in this test. * - * @return array list of test dates for the day of the holiday defined in this test + * @return array list of test dates for the holiday defined in this test * * @throws Exception */ diff --git a/tests/Poland/ChristmasTest.php b/tests/Poland/ChristmasTest.php index 6e6d19324..8285fffde 100644 --- a/tests/Poland/ChristmasTest.php +++ b/tests/Poland/ChristmasTest.php @@ -48,7 +48,7 @@ public function testChristmasDay(int $year, DateTime $expected): void /** * Returns a list of random test dates used for assertion of Christmas Day. * - * @return array list of test dates for Christmas Day + * @return array list of test dates for Christmas Day * * @throws Exception */ diff --git a/tests/Poland/EpiphanyTest.php b/tests/Poland/EpiphanyTest.php index 2c57f56ea..ec64bd019 100644 --- a/tests/Poland/EpiphanyTest.php +++ b/tests/Poland/EpiphanyTest.php @@ -48,7 +48,7 @@ public function testEpiphany(int $year, DateTime $expected): void /** * Returns a list of random test dates used for assertion of Epiphany. * - * @return array list of test dates for Epiphany + * @return array list of test dates for Epiphany * * @throws Exception */ diff --git a/tests/Poland/InternationalWorkersDayTest.php b/tests/Poland/InternationalWorkersDayTest.php index 3b3dfbf12..2c4f08536 100644 --- a/tests/Poland/InternationalWorkersDayTest.php +++ b/tests/Poland/InternationalWorkersDayTest.php @@ -73,7 +73,7 @@ public function testHolidayType(): void /** * Returns a list of random test dates used for assertion of International Workers' Day. * - * @return array list of test dates for International Workers' Day + * @return array list of test dates for International Workers' Day * * @throws Exception */ diff --git a/tests/Poland/NewYearsDayTest.php b/tests/Poland/NewYearsDayTest.php index 73d104cc4..eb42740e5 100644 --- a/tests/Poland/NewYearsDayTest.php +++ b/tests/Poland/NewYearsDayTest.php @@ -48,7 +48,7 @@ public function testHoliday(int $year, DateTime $expected): void /** * Returns a list of random test dates used for assertion of the holiday defined in this test. * - * @return array list of test dates for the holiday defined in this test + * @return array list of test dates for the holiday defined in this test * * @throws Exception */ diff --git a/tests/Poland/SecondChristmasDayTest.php b/tests/Poland/SecondChristmasDayTest.php index 358f31e89..364ff76ba 100644 --- a/tests/Poland/SecondChristmasDayTest.php +++ b/tests/Poland/SecondChristmasDayTest.php @@ -48,7 +48,7 @@ public function testHoliday(int $year, DateTime $expected): void /** * Returns a list of random test dates used for assertion of the holiday defined in this test. * - * @return array list of test dates for the holiday defined in this test + * @return array list of test dates for the holiday defined in this test * * @throws Exception */ diff --git a/tests/Portugal/AssumptionOfMaryTest.php b/tests/Portugal/AssumptionOfMaryTest.php index 925fbd98b..e6bc4060e 100644 --- a/tests/Portugal/AssumptionOfMaryTest.php +++ b/tests/Portugal/AssumptionOfMaryTest.php @@ -48,7 +48,7 @@ public function testHoliday(int $year, DateTime $expected): void /** * Returns a list of random test dates used for assertion of the holiday defined in this test. * - * @return array list of test dates for the day of the holiday defined in this test + * @return array list of test dates for the holiday defined in this test * * @throws Exception */ diff --git a/tests/Portugal/ChristmasTest.php b/tests/Portugal/ChristmasTest.php index e3a219b60..eabff06f8 100644 --- a/tests/Portugal/ChristmasTest.php +++ b/tests/Portugal/ChristmasTest.php @@ -48,7 +48,7 @@ public function testChristmasDay(int $year, DateTime $expected): void /** * Returns a list of random test dates used for assertion of Christmas Day. * - * @return array list of test dates for Christmas Day + * @return array list of test dates for Christmas Day * * @throws Exception */ diff --git a/tests/Portugal/ImmaculateConceptionTest.php b/tests/Portugal/ImmaculateConceptionTest.php index da636f883..3127130b6 100644 --- a/tests/Portugal/ImmaculateConceptionTest.php +++ b/tests/Portugal/ImmaculateConceptionTest.php @@ -48,7 +48,7 @@ public function testHoliday(int $year, DateTime $expected): void /** * Returns a list of random test dates used for assertion of the holiday defined in this test. * - * @return array list of test dates for the day of the holiday defined in this test + * @return array list of test dates for the holiday defined in this test * * @throws Exception */ diff --git a/tests/Portugal/InternationalWorkersDayTest.php b/tests/Portugal/InternationalWorkersDayTest.php index dab456d8a..7a1dbac55 100644 --- a/tests/Portugal/InternationalWorkersDayTest.php +++ b/tests/Portugal/InternationalWorkersDayTest.php @@ -73,7 +73,7 @@ public function testHolidayType(): void /** * Returns a list of random test dates used for assertion of International Workers' Day. * - * @return array list of test dates for International Workers' Day + * @return array list of test dates for International Workers' Day * * @throws Exception */ diff --git a/tests/Portugal/NewYearsDayTest.php b/tests/Portugal/NewYearsDayTest.php index 764bbcf8b..f8fe56a36 100644 --- a/tests/Portugal/NewYearsDayTest.php +++ b/tests/Portugal/NewYearsDayTest.php @@ -48,7 +48,7 @@ public function testHoliday(int $year, DateTime $expected): void /** * Returns a list of random test dates used for assertion of the holiday defined in this test. * - * @return array list of test dates for the holiday defined in this test + * @return array list of test dates for the holiday defined in this test * * @throws Exception */ diff --git a/tests/Portugal/PortugueseRepublicDayTest.php b/tests/Portugal/PortugueseRepublicDayTest.php index 1b50cd446..e70ea6ba7 100644 --- a/tests/Portugal/PortugueseRepublicDayTest.php +++ b/tests/Portugal/PortugueseRepublicDayTest.php @@ -124,6 +124,9 @@ public function testHolidayType(): void } } + /** + * @return \Generator + */ private function randomEstablishedYear(): \Generator { yield $this->generateRandomYear(self::ESTABLISHMENT_YEAR, self::HOLIDAY_YEAR_SUSPENDED - 1); diff --git a/tests/Romania/ChristmasDayTest.php b/tests/Romania/ChristmasDayTest.php index 12b96ec3b..3ac3d95b9 100644 --- a/tests/Romania/ChristmasDayTest.php +++ b/tests/Romania/ChristmasDayTest.php @@ -48,7 +48,7 @@ public function testHoliday(int $year, DateTime $expected): void /** * Returns a list of random test dates used for assertion of the holiday defined in this test. * - * @return array list of test dates for the holiday defined in this test + * @return array list of test dates for the holiday defined in this test * * @throws Exception */ diff --git a/tests/Romania/DayAfterNewYearsDayTest.php b/tests/Romania/DayAfterNewYearsDayTest.php index 4e0cdc9de..4f3287b71 100644 --- a/tests/Romania/DayAfterNewYearsDayTest.php +++ b/tests/Romania/DayAfterNewYearsDayTest.php @@ -48,7 +48,7 @@ public function testHoliday(int $year, DateTime $expected): void /** * Returns a list of random test dates used for assertion of the holiday defined in this test. * - * @return array list of test dates for the holiday defined in this test + * @return array list of test dates for the holiday defined in this test * * @throws Exception */ diff --git a/tests/Romania/InternationalWorkersDayTest.php b/tests/Romania/InternationalWorkersDayTest.php index f7e544303..9688f852b 100755 --- a/tests/Romania/InternationalWorkersDayTest.php +++ b/tests/Romania/InternationalWorkersDayTest.php @@ -73,7 +73,7 @@ public function testHolidayType(): void /** * Returns a list of random test dates used for assertion of International Workers' Day. * - * @return array list of test dates for International Workers' Day + * @return array list of test dates for International Workers' Day * * @throws Exception */ diff --git a/tests/Romania/NewYearsDayTest.php b/tests/Romania/NewYearsDayTest.php index 19e0ae449..7364e5666 100644 --- a/tests/Romania/NewYearsDayTest.php +++ b/tests/Romania/NewYearsDayTest.php @@ -48,7 +48,7 @@ public function testHoliday(int $year, DateTime $expected): void /** * Returns a list of random test dates used for assertion of the holiday defined in this test. * - * @return array list of test dates for the holiday defined in this test + * @return array list of test dates for the holiday defined in this test * * @throws Exception */ diff --git a/tests/Romania/SecondChristmasDayTest.php b/tests/Romania/SecondChristmasDayTest.php index 5f4d0514b..70ccfc7fb 100644 --- a/tests/Romania/SecondChristmasDayTest.php +++ b/tests/Romania/SecondChristmasDayTest.php @@ -48,7 +48,7 @@ public function testHoliday(int $year, DateTime $expected): void /** * Returns a list of random test dates used for assertion of the holiday defined in this test. * - * @return array list of test dates for the holiday defined in this test + * @return array list of test dates for the holiday defined in this test * * @throws Exception */ diff --git a/tests/Russia/InternationalWomensDayTest.php b/tests/Russia/InternationalWomensDayTest.php index 6fdfe19a4..0e176fc74 100644 --- a/tests/Russia/InternationalWomensDayTest.php +++ b/tests/Russia/InternationalWomensDayTest.php @@ -34,6 +34,8 @@ class InternationalWomensDayTest extends RussiaBaseTestCase implements HolidayTe public const HOLIDAY = 'internationalWomensDay'; /** + * @return array list of test dates for the holiday defined in this test + * * @throws Exception */ public function holidayDataProvider(): array diff --git a/tests/Russia/NewYearHolidaysDay2Test.php b/tests/Russia/NewYearHolidaysDay2Test.php index 612e8b17d..e8a5294cc 100644 --- a/tests/Russia/NewYearHolidaysDay2Test.php +++ b/tests/Russia/NewYearHolidaysDay2Test.php @@ -34,6 +34,8 @@ class NewYearHolidaysDay2Test extends RussiaBaseTestCase implements HolidayTestC public const HOLIDAY = 'newYearHolidaysDay2'; /** + * @return array list of test dates for the holiday defined in this test + * * @throws Exception */ public function holidayDataProvider(): array diff --git a/tests/Russia/NewYearHolidaysDay3Test.php b/tests/Russia/NewYearHolidaysDay3Test.php index 392383a6a..202deec1f 100644 --- a/tests/Russia/NewYearHolidaysDay3Test.php +++ b/tests/Russia/NewYearHolidaysDay3Test.php @@ -34,6 +34,8 @@ class NewYearHolidaysDay3Test extends RussiaBaseTestCase implements HolidayTestC public const HOLIDAY = 'newYearHolidaysDay3'; /** + * @return array list of test dates for the holiday defined in this test + * * @throws Exception */ public function holidayDataProvider(): array diff --git a/tests/Russia/NewYearHolidaysDay4Test.php b/tests/Russia/NewYearHolidaysDay4Test.php index c51b88289..cb4a3c4e0 100644 --- a/tests/Russia/NewYearHolidaysDay4Test.php +++ b/tests/Russia/NewYearHolidaysDay4Test.php @@ -33,6 +33,8 @@ class NewYearHolidaysDay4Test extends RussiaBaseTestCase implements HolidayTestC public const HOLIDAY = 'newYearHolidaysDay4'; /** + * @return array list of test dates for the holiday defined in this test + * * @throws Exception */ public function holidayDataProvider(): array diff --git a/tests/Russia/NewYearHolidaysDay5Test.php b/tests/Russia/NewYearHolidaysDay5Test.php index 242bd2f36..fcf7b15f2 100644 --- a/tests/Russia/NewYearHolidaysDay5Test.php +++ b/tests/Russia/NewYearHolidaysDay5Test.php @@ -34,6 +34,8 @@ class NewYearHolidaysDay5Test extends RussiaBaseTestCase implements HolidayTestC public const HOLIDAY = 'newYearHolidaysDay5'; /** + * @return array list of test dates for the holiday defined in this test + * * @throws Exception */ public function holidayDataProvider(): array diff --git a/tests/Russia/NewYearHolidaysDay6Test.php b/tests/Russia/NewYearHolidaysDay6Test.php index 5f94abc92..0ec5eea47 100644 --- a/tests/Russia/NewYearHolidaysDay6Test.php +++ b/tests/Russia/NewYearHolidaysDay6Test.php @@ -34,6 +34,8 @@ class NewYearHolidaysDay6Test extends RussiaBaseTestCase implements HolidayTestC public const HOLIDAY = 'newYearHolidaysDay6'; /** + * @return array list of test dates for the holiday defined in this test + * * @throws Exception */ public function holidayDataProvider(): array diff --git a/tests/Russia/NewYearHolidaysDay8Test.php b/tests/Russia/NewYearHolidaysDay8Test.php index fdb45bf79..a044061ba 100644 --- a/tests/Russia/NewYearHolidaysDay8Test.php +++ b/tests/Russia/NewYearHolidaysDay8Test.php @@ -33,6 +33,8 @@ class NewYearHolidaysDay8Test extends RussiaBaseTestCase implements HolidayTestC public const HOLIDAY = 'newYearHolidaysDay8'; /** + * @return array list of test dates for the holiday defined in this test + * * @throws Exception */ public function holidayDataProvider(): array diff --git a/tests/Russia/NewYearsDayTest.php b/tests/Russia/NewYearsDayTest.php index 94cad9a1b..ddda23516 100644 --- a/tests/Russia/NewYearsDayTest.php +++ b/tests/Russia/NewYearsDayTest.php @@ -34,6 +34,8 @@ class NewYearsDayTest extends RussiaBaseTestCase implements HolidayTestCase public const HOLIDAY = 'newYearsDay'; /** + * @return array list of test dates for the holiday defined in this test + * * @throws Exception */ public function holidayDataProvider(): array diff --git a/tests/Russia/OrthodoxChristmasDayTest.php b/tests/Russia/OrthodoxChristmasDayTest.php index 016526628..d06f102a6 100644 --- a/tests/Russia/OrthodoxChristmasDayTest.php +++ b/tests/Russia/OrthodoxChristmasDayTest.php @@ -34,6 +34,8 @@ class OrthodoxChristmasDayTest extends RussiaBaseTestCase implements HolidayTest public const HOLIDAY = 'orthodoxChristmasDay'; /** + * @return array list of test dates for the holiday defined in this test + * * @throws Exception */ public function holidayDataProvider(): array diff --git a/tests/Russia/SpringAndLabourDayTest.php b/tests/Russia/SpringAndLabourDayTest.php index 174b27369..bce11c436 100644 --- a/tests/Russia/SpringAndLabourDayTest.php +++ b/tests/Russia/SpringAndLabourDayTest.php @@ -34,6 +34,8 @@ class SpringAndLabourDayTest extends RussiaBaseTestCase implements HolidayTestCa public const HOLIDAY = 'springAndLabourDay'; /** + * @return array list of test dates for the holiday defined in this test + * * @throws Exception */ public function holidayDataProvider(): array diff --git a/tests/Russia/VictoryDayTest.php b/tests/Russia/VictoryDayTest.php index 98080be53..2b2d29acd 100644 --- a/tests/Russia/VictoryDayTest.php +++ b/tests/Russia/VictoryDayTest.php @@ -34,6 +34,8 @@ class VictoryDayTest extends RussiaBaseTestCase implements HolidayTestCase public const HOLIDAY = 'victoryDay'; /** + * @return array list of test dates for the holiday defined in this test + * * @throws Exception */ public function holidayDataProvider(): array diff --git a/tests/Slovakia/AllSaintsDayTest.php b/tests/Slovakia/AllSaintsDayTest.php index 902ef8b86..af032e4d7 100644 --- a/tests/Slovakia/AllSaintsDayTest.php +++ b/tests/Slovakia/AllSaintsDayTest.php @@ -51,7 +51,7 @@ public function testHoliday(int $year, DateTime $expected): void /** * Returns a list of random test dates used for assertion of the holiday defined in this test. * - * @return array list of test dates for the holiday defined in this test + * @return array list of test dates for the holiday defined in this test * * @throws Exception */ diff --git a/tests/Slovakia/ChristmasDayTest.php b/tests/Slovakia/ChristmasDayTest.php index 7f9bb4fc5..3e07372b3 100644 --- a/tests/Slovakia/ChristmasDayTest.php +++ b/tests/Slovakia/ChristmasDayTest.php @@ -51,7 +51,7 @@ public function testChristmasDay(int $year, DateTime $expected): void /** * Returns a list of random test dates used for assertion of the holiday defined in this test. * - * @return array list of test dates for the holiday defined in this test + * @return array list of test dates for the holiday defined in this test * * @throws Exception */ diff --git a/tests/Slovakia/ChristmasEveTest.php b/tests/Slovakia/ChristmasEveTest.php index 41f718fa5..eb94b65a7 100644 --- a/tests/Slovakia/ChristmasEveTest.php +++ b/tests/Slovakia/ChristmasEveTest.php @@ -51,7 +51,7 @@ public function testChristmasEve(int $year, DateTime $expected): void /** * Returns a list of random test dates used for assertion of the holiday defined in this test. * - * @return array list of test dates for the holiday defined in this test + * @return array list of test dates for the holiday defined in this test * * @throws Exception */ diff --git a/tests/Slovakia/EasterMondayTest.php b/tests/Slovakia/EasterMondayTest.php index 84bbcc628..4aecaf8ad 100644 --- a/tests/Slovakia/EasterMondayTest.php +++ b/tests/Slovakia/EasterMondayTest.php @@ -52,7 +52,7 @@ public function testHoliday(int $year, DateTime $expected): void /** * Returns a list of test dates used for assertion of the holiday defined in this test. * - * @return array list of test dates for the holiday defined in this test + * @return array list of test dates for the holiday defined in this test * * @throws Exception */ diff --git a/tests/Slovakia/EpiphanyTest.php b/tests/Slovakia/EpiphanyTest.php index 07ad9c2b2..273ad8dd7 100644 --- a/tests/Slovakia/EpiphanyTest.php +++ b/tests/Slovakia/EpiphanyTest.php @@ -51,7 +51,7 @@ public function testHoliday(int $year, DateTime $expected): void /** * Returns a list of random test dates used for assertion of the holiday defined in this test. * - * @return array list of test dates for the holiday defined in this test + * @return array list of test dates for the holiday defined in this test * * @throws Exception */ diff --git a/tests/Slovakia/GoodFridayTest.php b/tests/Slovakia/GoodFridayTest.php index 9ccf63e00..8a19a81b8 100644 --- a/tests/Slovakia/GoodFridayTest.php +++ b/tests/Slovakia/GoodFridayTest.php @@ -52,7 +52,7 @@ public function testHoliday(int $year, DateTime $expected): void /** * Returns a list of test dates used for assertion of the holiday defined in this test. * - * @return array list of test dates for the holiday defined in this test + * @return array list of test dates for the holiday defined in this test * * @throws Exception */ diff --git a/tests/Slovakia/InternationalWorkersDayTest.php b/tests/Slovakia/InternationalWorkersDayTest.php index ec68de79d..ff3c4ac88 100644 --- a/tests/Slovakia/InternationalWorkersDayTest.php +++ b/tests/Slovakia/InternationalWorkersDayTest.php @@ -51,7 +51,7 @@ public function testHoliday(int $year, DateTime $expected): void /** * Returns a list of random test dates used for assertion of the holiday defined in this test. * - * @return array list of test dates for the holiday defined in this test + * @return array list of test dates for the holiday defined in this test * * @throws Exception */ diff --git a/tests/Slovakia/OurLadyOfSorrowsDayTest.php b/tests/Slovakia/OurLadyOfSorrowsDayTest.php index 061c25036..86f1ba46d 100644 --- a/tests/Slovakia/OurLadyOfSorrowsDayTest.php +++ b/tests/Slovakia/OurLadyOfSorrowsDayTest.php @@ -51,7 +51,7 @@ public function testHoliday(int $year, DateTime $expected): void /** * Returns a list of random test dates used for assertion of the holiday defined in this test. * - * @return array list of test dates for the holiday defined in this test + * @return array list of test dates for the holiday defined in this test * * @throws Exception */ diff --git a/tests/Slovakia/SaintsCyrilAndMethodiusDayTest.php b/tests/Slovakia/SaintsCyrilAndMethodiusDayTest.php index e519ffbe3..12b9cf024 100644 --- a/tests/Slovakia/SaintsCyrilAndMethodiusDayTest.php +++ b/tests/Slovakia/SaintsCyrilAndMethodiusDayTest.php @@ -51,7 +51,7 @@ public function testHoliday(int $year, DateTime $expected): void /** * Returns a list of random test dates used for assertion of the holiday defined in this test. * - * @return array list of test dates for the holiday defined in this test + * @return array list of test dates for the holiday defined in this test * * @throws Exception */ diff --git a/tests/Slovakia/SecondChristmasDayTest.php b/tests/Slovakia/SecondChristmasDayTest.php index d20e4c666..1d2ffc773 100644 --- a/tests/Slovakia/SecondChristmasDayTest.php +++ b/tests/Slovakia/SecondChristmasDayTest.php @@ -51,7 +51,7 @@ public function testHoliday(int $year, DateTime $expected): void /** * Returns a list of random test dates used for assertion of the holiday defined in this test. * - * @return array list of test dates for the holiday defined in this test + * @return array list of test dates for the holiday defined in this test * * @throws Exception */ diff --git a/tests/Slovakia/SlovakConstitutionDayTest.php b/tests/Slovakia/SlovakConstitutionDayTest.php index 004410b8c..0393a0129 100644 --- a/tests/Slovakia/SlovakConstitutionDayTest.php +++ b/tests/Slovakia/SlovakConstitutionDayTest.php @@ -51,7 +51,7 @@ public function testHoliday(int $year, DateTime $expected): void /** * Returns a list of random test dates used for assertion of the holiday defined in this test. * - * @return array list of test dates for the holiday defined in this test + * @return array list of test dates for the holiday defined in this test * * @throws Exception */ diff --git a/tests/Slovakia/SlovakIndependeceDayTest.php b/tests/Slovakia/SlovakIndependeceDayTest.php index 07d12c3cb..ae1ef9d71 100644 --- a/tests/Slovakia/SlovakIndependeceDayTest.php +++ b/tests/Slovakia/SlovakIndependeceDayTest.php @@ -52,7 +52,7 @@ public function testHoliday(int $year, DateTime $expected): void /** * Returns a list of random test dates used for assertion of the holiday defined in this test. * - * @return array list of test dates for the holiday defined in this test + * @return array list of test dates for the holiday defined in this test * * @throws Exception */ diff --git a/tests/Slovakia/SlovakNationalUprisingDayTest.php b/tests/Slovakia/SlovakNationalUprisingDayTest.php index 023dc4b38..dbb667c89 100644 --- a/tests/Slovakia/SlovakNationalUprisingDayTest.php +++ b/tests/Slovakia/SlovakNationalUprisingDayTest.php @@ -51,7 +51,7 @@ public function testHoliday(int $year, DateTime $expected): void /** * Returns a list of random test dates used for assertion of the holiday defined in this test. * - * @return array list of test dates for the holiday defined in this test + * @return array list of test dates for the holiday defined in this test * * @throws Exception */ diff --git a/tests/Slovakia/StruggleForFreedomAndDemocracyDayTest.php b/tests/Slovakia/StruggleForFreedomAndDemocracyDayTest.php index 1d142ee7e..5946e66f6 100644 --- a/tests/Slovakia/StruggleForFreedomAndDemocracyDayTest.php +++ b/tests/Slovakia/StruggleForFreedomAndDemocracyDayTest.php @@ -51,7 +51,7 @@ public function testHoliday(int $year, DateTime $expected): void /** * Returns a list of random test dates used for assertion of the holiday defined in this test. * - * @return array list of test dates for the holiday defined in this test + * @return array list of test dates for the holiday defined in this test * * @throws Exception */ diff --git a/tests/Slovakia/VictoryInEuropeDayTest.php b/tests/Slovakia/VictoryInEuropeDayTest.php index 15c4f8116..ee3b13e20 100644 --- a/tests/Slovakia/VictoryInEuropeDayTest.php +++ b/tests/Slovakia/VictoryInEuropeDayTest.php @@ -51,7 +51,7 @@ public function testHoliday(int $year, DateTime $expected): void /** * Returns a list of random test dates used for assertion of the holiday defined in this test. * - * @return array list of test dates for the holiday defined in this test + * @return array list of test dates for the holiday defined in this test * * @throws Exception */ diff --git a/tests/SouthAfrica/ChristmasDayTest.php b/tests/SouthAfrica/ChristmasDayTest.php index 0bb3a7183..5145ec17f 100644 --- a/tests/SouthAfrica/ChristmasDayTest.php +++ b/tests/SouthAfrica/ChristmasDayTest.php @@ -67,7 +67,7 @@ public function testHoliday(int $year, string $expected): void /** * Returns a list of random test dates used for assertion of the holiday defined in this test. * - * @return array list of test dates for the holiday defined in this test + * @return array list of test dates for the holiday defined in this test * * @throws Exception */ diff --git a/tests/SouthAfrica/FamilyDayTest.php b/tests/SouthAfrica/FamilyDayTest.php index ea65d5bf7..1f635a0ef 100644 --- a/tests/SouthAfrica/FamilyDayTest.php +++ b/tests/SouthAfrica/FamilyDayTest.php @@ -65,7 +65,7 @@ public function testHoliday(int $year, string $expected): void /** * Returns a list of random test dates used for assertion of the holiday defined in this test. * - * @return array list of test dates for the holiday defined in this test + * @return array list of test dates for the holiday defined in this test * * @throws Exception */ diff --git a/tests/SouthAfrica/FreedomDayTest.php b/tests/SouthAfrica/FreedomDayTest.php index 1f0e20ba4..fc9d7f641 100644 --- a/tests/SouthAfrica/FreedomDayTest.php +++ b/tests/SouthAfrica/FreedomDayTest.php @@ -67,7 +67,7 @@ public function testHoliday(int $year, string $expected): void /** * Returns a list of random test dates used for assertion of the holiday defined in this test. * - * @return array list of test dates for the holiday defined in this test + * @return array list of test dates for the holiday defined in this test * * @throws Exception */ diff --git a/tests/SouthAfrica/GoodFridayTest.php b/tests/SouthAfrica/GoodFridayTest.php index 199ab3944..440deff88 100644 --- a/tests/SouthAfrica/GoodFridayTest.php +++ b/tests/SouthAfrica/GoodFridayTest.php @@ -65,7 +65,7 @@ public function testHoliday(int $year, string $expected): void /** * Returns a list of random test dates used for assertion of the holiday defined in this test. * - * @return array list of test dates for the holiday defined in this test + * @return array list of test dates for the holiday defined in this test * * @throws Exception */ diff --git a/tests/SouthAfrica/HeritageDayTest.php b/tests/SouthAfrica/HeritageDayTest.php index 809de1d73..db48aefd8 100644 --- a/tests/SouthAfrica/HeritageDayTest.php +++ b/tests/SouthAfrica/HeritageDayTest.php @@ -67,7 +67,7 @@ public function testHoliday(int $year, string $expected): void /** * Returns a list of random test dates used for assertion of the holiday defined in this test. * - * @return array list of test dates for the holiday defined in this test + * @return array list of test dates for the holiday defined in this test * * @throws Exception */ diff --git a/tests/SouthAfrica/HumanRightsDayTest.php b/tests/SouthAfrica/HumanRightsDayTest.php index 2004dcca7..acc33a3e2 100644 --- a/tests/SouthAfrica/HumanRightsDayTest.php +++ b/tests/SouthAfrica/HumanRightsDayTest.php @@ -67,7 +67,7 @@ public function testHoliday(int $year, string $expected): void /** * Returns a list of random test dates used for assertion of the holiday defined in this test. * - * @return array list of test dates for the holiday defined in this test + * @return array list of test dates for the holiday defined in this test * * @throws Exception */ diff --git a/tests/SouthAfrica/NationalWomensDayTest.php b/tests/SouthAfrica/NationalWomensDayTest.php index 42b2cb092..a75b61783 100644 --- a/tests/SouthAfrica/NationalWomensDayTest.php +++ b/tests/SouthAfrica/NationalWomensDayTest.php @@ -67,7 +67,7 @@ public function testHoliday(int $year, string $expected): void /** * Returns a list of random test dates used for assertion of the holiday defined in this test. * - * @return array list of test dates for the holiday defined in this test + * @return array list of test dates for the holiday defined in this test * * @throws Exception */ diff --git a/tests/SouthAfrica/NewYearsDayTest.php b/tests/SouthAfrica/NewYearsDayTest.php index 712814ff1..ac177ddf5 100644 --- a/tests/SouthAfrica/NewYearsDayTest.php +++ b/tests/SouthAfrica/NewYearsDayTest.php @@ -67,7 +67,7 @@ public function testHoliday(int $year, string $expected): void /** * Returns a list of random test dates used for assertion of the holiday defined in this test. * - * @return array list of test dates for the holiday defined in this test + * @return array list of test dates for the holiday defined in this test * * @throws Exception */ diff --git a/tests/SouthAfrica/ReconciliationDayTest.php b/tests/SouthAfrica/ReconciliationDayTest.php index 962239c52..e47f08359 100644 --- a/tests/SouthAfrica/ReconciliationDayTest.php +++ b/tests/SouthAfrica/ReconciliationDayTest.php @@ -67,7 +67,7 @@ public function testHoliday(int $year, string $expected): void /** * Returns a list of random test dates used for assertion of the holiday defined in this test. * - * @return array list of test dates for the holiday defined in this test + * @return array list of test dates for the holiday defined in this test * * @throws Exception */ diff --git a/tests/SouthAfrica/SecondChristmasDayTest.php b/tests/SouthAfrica/SecondChristmasDayTest.php index ff450186c..6ef19f7d8 100644 --- a/tests/SouthAfrica/SecondChristmasDayTest.php +++ b/tests/SouthAfrica/SecondChristmasDayTest.php @@ -67,7 +67,7 @@ public function testHoliday(int $year, string $expected): void /** * Returns a list of random test dates used for assertion of the holiday defined in this test. * - * @return array list of test dates for the holiday defined in this test + * @return array list of test dates for the holiday defined in this test * * @throws Exception */ diff --git a/tests/SouthAfrica/WorkersDayTest.php b/tests/SouthAfrica/WorkersDayTest.php index 73a1a8f6c..4c3f1d994 100644 --- a/tests/SouthAfrica/WorkersDayTest.php +++ b/tests/SouthAfrica/WorkersDayTest.php @@ -67,7 +67,7 @@ public function testHoliday(int $year, string $expected): void /** * Returns a list of random test dates used for assertion of the holiday defined in this test. * - * @return array list of test dates for the holiday defined in this test + * @return array list of test dates for the holiday defined in this test * * @throws Exception */ diff --git a/tests/SouthAfrica/YouthDayTest.php b/tests/SouthAfrica/YouthDayTest.php index b6ec95c01..b736fded7 100644 --- a/tests/SouthAfrica/YouthDayTest.php +++ b/tests/SouthAfrica/YouthDayTest.php @@ -67,7 +67,7 @@ public function testHoliday(int $year, string $expected): void /** * Returns a list of random test dates used for assertion of the holiday defined in this test. * - * @return array list of test dates for the holiday defined in this test + * @return array list of test dates for the holiday defined in this test * * @throws Exception */ diff --git a/tests/Spain/AllSaintsDayTest.php b/tests/Spain/AllSaintsDayTest.php index 3cd01d2e0..ff7dbe2fd 100644 --- a/tests/Spain/AllSaintsDayTest.php +++ b/tests/Spain/AllSaintsDayTest.php @@ -48,7 +48,7 @@ public function testHoliday(int $year, DateTime $expected): void /** * Returns a list of random test dates used for assertion of the holiday defined in this test. * - * @return array list of test dates for the holiday defined in this test + * @return array list of test dates for the holiday defined in this test * * @throws Exception */ diff --git a/tests/Spain/AssumptionOfMaryTest.php b/tests/Spain/AssumptionOfMaryTest.php index 4766ddd43..9809dca74 100644 --- a/tests/Spain/AssumptionOfMaryTest.php +++ b/tests/Spain/AssumptionOfMaryTest.php @@ -48,7 +48,7 @@ public function testHoliday(int $year, DateTime $expected): void /** * Returns a list of random test dates used for assertion of the holiday defined in this test. * - * @return array list of test dates for the day of the holiday defined in this test + * @return array list of test dates for the holiday defined in this test * * @throws Exception */ diff --git a/tests/Spain/Catalonia/stJohnsDayTest.php b/tests/Spain/Catalonia/stJohnsDayTest.php index cb5aebbc3..6c807c7f5 100644 --- a/tests/Spain/Catalonia/stJohnsDayTest.php +++ b/tests/Spain/Catalonia/stJohnsDayTest.php @@ -48,7 +48,7 @@ public function testHoliday(int $year, DateTime $expected): void /** * Returns a list of random test dates used for assertion of the holiday defined in this test. * - * @return array list of test dates for the holiday defined in this test + * @return array list of test dates for the holiday defined in this test * * @throws Exception */ diff --git a/tests/Spain/ChristmasTest.php b/tests/Spain/ChristmasTest.php index a9a4fa352..47df8e030 100644 --- a/tests/Spain/ChristmasTest.php +++ b/tests/Spain/ChristmasTest.php @@ -48,7 +48,7 @@ public function testHoliday(int $year, DateTime $expected): void /** * Returns a list of random test dates used for assertion of the holiday defined in this test. * - * @return array list of test dates for the holiday defined in this test + * @return array list of test dates for the holiday defined in this test * * @throws Exception */ diff --git a/tests/Spain/EpiphanyTest.php b/tests/Spain/EpiphanyTest.php index 6cfa13d7a..89c1b1874 100644 --- a/tests/Spain/EpiphanyTest.php +++ b/tests/Spain/EpiphanyTest.php @@ -48,7 +48,7 @@ public function testHoliday(int $year, DateTime $expected): void /** * Returns a list of random test dates used for assertion of the holiday defined in this test. * - * @return array list of test dates for the day of the holiday defined in this test + * @return array list of test dates for the holiday defined in this test * * @throws Exception */ diff --git a/tests/Spain/ImmaculateConceptionTest.php b/tests/Spain/ImmaculateConceptionTest.php index b6b4adba5..89baa7c87 100644 --- a/tests/Spain/ImmaculateConceptionTest.php +++ b/tests/Spain/ImmaculateConceptionTest.php @@ -48,7 +48,7 @@ public function testHoliday(int $year, DateTime $expected): void /** * Returns a list of random test dates used for assertion of the holiday defined in this test. * - * @return array list of test dates for the day of the holiday defined in this test + * @return array list of test dates for the holiday defined in this test * * @throws Exception */ diff --git a/tests/Spain/InternationalWorkersDayTest.php b/tests/Spain/InternationalWorkersDayTest.php index 55e59c6b3..76697626a 100644 --- a/tests/Spain/InternationalWorkersDayTest.php +++ b/tests/Spain/InternationalWorkersDayTest.php @@ -48,7 +48,7 @@ public function testHoliday(int $year, DateTime $expected): void /** * Returns a list of random test dates used for assertion of the holiday defined in this test. * - * @return array list of test dates for the day of the holiday defined in this test + * @return array list of test dates for the holiday defined in this test * * @throws Exception */ diff --git a/tests/Spain/NewYearsDayTest.php b/tests/Spain/NewYearsDayTest.php index 8ca78398c..4cde99773 100644 --- a/tests/Spain/NewYearsDayTest.php +++ b/tests/Spain/NewYearsDayTest.php @@ -48,7 +48,7 @@ public function testHoliday(int $year, DateTime $expected): void /** * Returns a list of random test dates used for assertion of the holiday defined in this test. * - * @return array list of test dates for the holiday defined in this test + * @return array list of test dates for the holiday defined in this test * * @throws Exception */ diff --git a/tests/Spain/ValentinesDayTest.php b/tests/Spain/ValentinesDayTest.php index 0be0aadf7..dd830d65d 100644 --- a/tests/Spain/ValentinesDayTest.php +++ b/tests/Spain/ValentinesDayTest.php @@ -48,7 +48,7 @@ public function testHoliday(int $year, DateTime $expected): void /** * Returns a list of random test dates used for assertion of the holiday defined in this test. * - * @return array list of test dates for the holiday defined in this test + * @return array list of test dates for the holiday defined in this test * * @throws Exception */ diff --git a/tests/Spain/stJosephsDayTest.php b/tests/Spain/stJosephsDayTest.php index 7163ead9a..3c811e549 100644 --- a/tests/Spain/stJosephsDayTest.php +++ b/tests/Spain/stJosephsDayTest.php @@ -54,7 +54,7 @@ public function testHoliday(int $year, DateTime $expected): void /** * Returns a list of random test dates used for assertion of the holiday defined in this test. * - * @return array list of test dates for the holiday defined in this test + * @return array list of test dates for the holiday defined in this test * * @throws Exception */ diff --git a/tests/Sweden/AllSaintsDayTest.php b/tests/Sweden/AllSaintsDayTest.php index bd0b51367..c2b0450a5 100644 --- a/tests/Sweden/AllSaintsDayTest.php +++ b/tests/Sweden/AllSaintsDayTest.php @@ -50,7 +50,7 @@ public function testHoliday(int $year, DateTime $expected): void /** * Returns a list of random test dates used for assertion of the holiday defined in this test. * - * @return array list of test dates for the holiday defined in this test + * @return array list of test dates for the holiday defined in this test * * @throws Exception */ diff --git a/tests/Sweden/AllSaintsEveTest.php b/tests/Sweden/AllSaintsEveTest.php index 3d6898487..f1228d348 100644 --- a/tests/Sweden/AllSaintsEveTest.php +++ b/tests/Sweden/AllSaintsEveTest.php @@ -50,7 +50,7 @@ public function testHoliday(int $year, DateTime $expected): void /** * Returns a list of random test dates used for assertion of the holiday defined in this test. * - * @return array list of test dates for the holiday defined in this test + * @return array list of test dates for the holiday defined in this test * * @throws Exception */ diff --git a/tests/Sweden/ChristmasDayTest.php b/tests/Sweden/ChristmasDayTest.php index 5e7afd40d..d1414856d 100644 --- a/tests/Sweden/ChristmasDayTest.php +++ b/tests/Sweden/ChristmasDayTest.php @@ -48,7 +48,7 @@ public function testHoliday(int $year, DateTime $expected): void /** * Returns a list of random test dates used for assertion of the holiday defined in this test. * - * @return array list of test dates for the holiday defined in this test + * @return array list of test dates for the holiday defined in this test * * @throws Exception */ diff --git a/tests/Sweden/ChristmasEveTest.php b/tests/Sweden/ChristmasEveTest.php index 1f7ebadec..3f4aa1fb2 100644 --- a/tests/Sweden/ChristmasEveTest.php +++ b/tests/Sweden/ChristmasEveTest.php @@ -48,7 +48,7 @@ public function testHoliday(int $year, DateTime $expected): void /** * Returns a list of random test dates used for assertion of the holiday defined in this test. * - * @return array list of test dates for the holiday defined in this test + * @return array list of test dates for the holiday defined in this test * * @throws Exception */ diff --git a/tests/Sweden/EpiphanyEveTest.php b/tests/Sweden/EpiphanyEveTest.php index 9bbd5b621..0e3f53c54 100644 --- a/tests/Sweden/EpiphanyEveTest.php +++ b/tests/Sweden/EpiphanyEveTest.php @@ -48,7 +48,7 @@ public function testHoliday(int $year, DateTime $expected): void /** * Returns a list of random test dates used for assertion of the holiday defined in this test. * - * @return array list of test dates for the day of the holiday defined in this test + * @return array list of test dates for the holiday defined in this test * * @throws Exception */ diff --git a/tests/Sweden/EpiphanyTest.php b/tests/Sweden/EpiphanyTest.php index e954a5ed4..1e1bf999b 100644 --- a/tests/Sweden/EpiphanyTest.php +++ b/tests/Sweden/EpiphanyTest.php @@ -48,7 +48,7 @@ public function testHoliday(int $year, DateTime $expected): void /** * Returns a list of random test dates used for assertion of the holiday defined in this test. * - * @return array list of test dates for the day of the holiday defined in this test + * @return array list of test dates for the holiday defined in this test * * @throws Exception */ diff --git a/tests/Sweden/InternationalWorkersDayTest.php b/tests/Sweden/InternationalWorkersDayTest.php index 7bc19dbef..10b818889 100644 --- a/tests/Sweden/InternationalWorkersDayTest.php +++ b/tests/Sweden/InternationalWorkersDayTest.php @@ -73,7 +73,7 @@ public function testHolidayType(): void /** * Returns a list of random test dates used for assertion of International Workers' Day. * - * @return array list of test dates for International Workers' Day + * @return array list of test dates for International Workers' Day * * @throws Exception */ diff --git a/tests/Sweden/NewYearsDayTest.php b/tests/Sweden/NewYearsDayTest.php index 56543b568..7dbf2cb77 100644 --- a/tests/Sweden/NewYearsDayTest.php +++ b/tests/Sweden/NewYearsDayTest.php @@ -48,7 +48,7 @@ public function testHoliday(int $year, DateTime $expected): void /** * Returns a list of random test dates used for assertion of the holiday defined in this test. * - * @return array list of test dates for the holiday defined in this test + * @return array list of test dates for the holiday defined in this test * * @throws Exception */ diff --git a/tests/Sweden/NewYearsEveTest.php b/tests/Sweden/NewYearsEveTest.php index 694051a31..d00fe33dd 100644 --- a/tests/Sweden/NewYearsEveTest.php +++ b/tests/Sweden/NewYearsEveTest.php @@ -48,7 +48,7 @@ public function testHoliday(int $year, DateTime $expected): void /** * Returns a list of random test dates used for assertion of the holiday defined in this test. * - * @return array list of test dates for the holiday defined in this test + * @return array list of test dates for the holiday defined in this test * * @throws Exception */ diff --git a/tests/Sweden/SecondChristmasDayTest.php b/tests/Sweden/SecondChristmasDayTest.php index 9ca638d9f..8b6ca7ad5 100644 --- a/tests/Sweden/SecondChristmasDayTest.php +++ b/tests/Sweden/SecondChristmasDayTest.php @@ -48,7 +48,7 @@ public function testHoliday(int $year, DateTime $expected): void /** * Returns a list of random test dates used for assertion of the holiday defined in this test. * - * @return array list of test dates for the holiday defined in this test + * @return array list of test dates for the holiday defined in this test * * @throws Exception */ diff --git a/tests/Sweden/WalpurgisEveTest.php b/tests/Sweden/WalpurgisEveTest.php index 0d933f6a3..4422afbd1 100644 --- a/tests/Sweden/WalpurgisEveTest.php +++ b/tests/Sweden/WalpurgisEveTest.php @@ -48,7 +48,7 @@ public function testHoliday(int $year, DateTime $expected): void /** * Returns a list of random test dates used for assertion of the holiday defined in this test. * - * @return array list of test dates for the day of the holiday defined in this test + * @return array list of test dates for the holiday defined in this test * * @throws Exception */ diff --git a/tests/Switzerland/Aargau/ChristmasDayTest.php b/tests/Switzerland/Aargau/ChristmasDayTest.php index 9086eb552..c15531c02 100644 --- a/tests/Switzerland/Aargau/ChristmasDayTest.php +++ b/tests/Switzerland/Aargau/ChristmasDayTest.php @@ -48,7 +48,7 @@ public function testChristmasDay(int $year, DateTime $expected): void /** * Returns a list of random test dates used for assertion of Christmas Day. * - * @return array list of test dates for Christmas Day + * @return array list of test dates for Christmas Day * * @throws Exception */ diff --git a/tests/Switzerland/Aargau/NewYearsDayTest.php b/tests/Switzerland/Aargau/NewYearsDayTest.php index 07e665c31..082609218 100644 --- a/tests/Switzerland/Aargau/NewYearsDayTest.php +++ b/tests/Switzerland/Aargau/NewYearsDayTest.php @@ -73,7 +73,7 @@ public function testHolidayType(): void /** * Returns a list of random test dates used for assertion of New Years Day. * - * @return array list of test dates for New Years Day + * @return array list of test dates for New Years Day * * @throws Exception */ diff --git a/tests/Switzerland/AppenzellAusserrhoden/ChristmasDayTest.php b/tests/Switzerland/AppenzellAusserrhoden/ChristmasDayTest.php index a80ea3def..7a9656248 100644 --- a/tests/Switzerland/AppenzellAusserrhoden/ChristmasDayTest.php +++ b/tests/Switzerland/AppenzellAusserrhoden/ChristmasDayTest.php @@ -48,7 +48,7 @@ public function testChristmasDay(int $year, DateTime $expected): void /** * Returns a list of random test dates used for assertion of Christmas Day. * - * @return array list of test dates for Christmas Day + * @return array list of test dates for Christmas Day * * @throws Exception */ diff --git a/tests/Switzerland/AppenzellAusserrhoden/NewYearsDayTest.php b/tests/Switzerland/AppenzellAusserrhoden/NewYearsDayTest.php index f345a9857..105f9102a 100644 --- a/tests/Switzerland/AppenzellAusserrhoden/NewYearsDayTest.php +++ b/tests/Switzerland/AppenzellAusserrhoden/NewYearsDayTest.php @@ -73,7 +73,7 @@ public function testHolidayType(): void /** * Returns a list of random test dates used for assertion of New Years Day. * - * @return array list of test dates for New Years Day + * @return array list of test dates for New Years Day * * @throws Exception */ diff --git a/tests/Switzerland/AppenzellAusserrhoden/StStephensDayTest.php b/tests/Switzerland/AppenzellAusserrhoden/StStephensDayTest.php index a28a571c2..18ba2953a 100644 --- a/tests/Switzerland/AppenzellAusserrhoden/StStephensDayTest.php +++ b/tests/Switzerland/AppenzellAusserrhoden/StStephensDayTest.php @@ -48,7 +48,7 @@ public function testHoliday(int $year, DateTime $expected): void /** * Returns a list of random test dates used for assertion of the holiday defined in this test. * - * @return array list of test dates for the holiday defined in this test + * @return array list of test dates for the holiday defined in this test * * @throws Exception */ diff --git a/tests/Switzerland/AppenzellInnerrhoden/AllSaintsDayTest.php b/tests/Switzerland/AppenzellInnerrhoden/AllSaintsDayTest.php index f1f1ada74..d33b8fc7a 100644 --- a/tests/Switzerland/AppenzellInnerrhoden/AllSaintsDayTest.php +++ b/tests/Switzerland/AppenzellInnerrhoden/AllSaintsDayTest.php @@ -73,7 +73,7 @@ public function testHolidayType(): void /** * Returns a list of random test dates used for assertion of All Saints' Day. * - * @return array list of test dates for All Saints' Day + * @return array list of test dates for All Saints' Day * * @throws Exception */ diff --git a/tests/Switzerland/AppenzellInnerrhoden/AssumptionOfMaryTest.php b/tests/Switzerland/AppenzellInnerrhoden/AssumptionOfMaryTest.php index be67a54a7..a344238b5 100644 --- a/tests/Switzerland/AppenzellInnerrhoden/AssumptionOfMaryTest.php +++ b/tests/Switzerland/AppenzellInnerrhoden/AssumptionOfMaryTest.php @@ -73,7 +73,7 @@ public function testHolidayType(): void /** * Returns a list of random test dates used for assertion of the day of the Assumption of Mary. * - * @return array list of test dates for the day of the Assumption of Mary + * @return array list of test dates for the day of the Assumption of Mary * * @throws Exception */ diff --git a/tests/Switzerland/AppenzellInnerrhoden/ChristmasDayTest.php b/tests/Switzerland/AppenzellInnerrhoden/ChristmasDayTest.php index a72fbd8c2..e656e644b 100644 --- a/tests/Switzerland/AppenzellInnerrhoden/ChristmasDayTest.php +++ b/tests/Switzerland/AppenzellInnerrhoden/ChristmasDayTest.php @@ -48,7 +48,7 @@ public function testChristmasDay(int $year, DateTime $expected): void /** * Returns a list of random test dates used for assertion of Christmas Day. * - * @return array list of test dates for Christmas Day + * @return array list of test dates for Christmas Day * * @throws Exception */ diff --git a/tests/Switzerland/AppenzellInnerrhoden/ImmaculateConceptionTest.php b/tests/Switzerland/AppenzellInnerrhoden/ImmaculateConceptionTest.php index 798b701b4..d708e4664 100644 --- a/tests/Switzerland/AppenzellInnerrhoden/ImmaculateConceptionTest.php +++ b/tests/Switzerland/AppenzellInnerrhoden/ImmaculateConceptionTest.php @@ -48,7 +48,7 @@ public function testHoliday(int $year, DateTime $expected): void /** * Returns a list of random test dates used for assertion of the holiday defined in this test. * - * @return array list of test dates for the day of the holiday defined in this test + * @return array list of test dates for the holiday defined in this test * * @throws Exception */ diff --git a/tests/Switzerland/AppenzellInnerrhoden/NewYearsDayTest.php b/tests/Switzerland/AppenzellInnerrhoden/NewYearsDayTest.php index 53b4ef57d..caf6d3e44 100644 --- a/tests/Switzerland/AppenzellInnerrhoden/NewYearsDayTest.php +++ b/tests/Switzerland/AppenzellInnerrhoden/NewYearsDayTest.php @@ -73,7 +73,7 @@ public function testHolidayType(): void /** * Returns a list of random test dates used for assertion of New Years Day. * - * @return array list of test dates for New Years Day + * @return array list of test dates for New Years Day * * @throws Exception */ diff --git a/tests/Switzerland/AppenzellInnerrhoden/StStephensDayTest.php b/tests/Switzerland/AppenzellInnerrhoden/StStephensDayTest.php index 2f146ef9b..e300a8db6 100644 --- a/tests/Switzerland/AppenzellInnerrhoden/StStephensDayTest.php +++ b/tests/Switzerland/AppenzellInnerrhoden/StStephensDayTest.php @@ -48,7 +48,7 @@ public function testHoliday(int $year, DateTime $expected): void /** * Returns a list of random test dates used for assertion of the holiday defined in this test. * - * @return array list of test dates for the holiday defined in this test + * @return array list of test dates for the holiday defined in this test * * @throws Exception */ diff --git a/tests/Switzerland/BaselLandschaft/ChristmasDayTest.php b/tests/Switzerland/BaselLandschaft/ChristmasDayTest.php index 1ca1c772c..cc5026060 100644 --- a/tests/Switzerland/BaselLandschaft/ChristmasDayTest.php +++ b/tests/Switzerland/BaselLandschaft/ChristmasDayTest.php @@ -48,7 +48,7 @@ public function testChristmasDay(int $year, DateTime $expected): void /** * Returns a list of random test dates used for assertion of Christmas Day. * - * @return array list of test dates for Christmas Day + * @return array list of test dates for Christmas Day * * @throws Exception */ diff --git a/tests/Switzerland/BaselLandschaft/NewYearsDayTest.php b/tests/Switzerland/BaselLandschaft/NewYearsDayTest.php index 0640d6789..c4419aa44 100644 --- a/tests/Switzerland/BaselLandschaft/NewYearsDayTest.php +++ b/tests/Switzerland/BaselLandschaft/NewYearsDayTest.php @@ -73,7 +73,7 @@ public function testHolidayType(): void /** * Returns a list of random test dates used for assertion of New Years Day. * - * @return array list of test dates for New Years Day + * @return array list of test dates for New Years Day * * @throws Exception */ diff --git a/tests/Switzerland/BaselLandschaft/StStephensDayTest.php b/tests/Switzerland/BaselLandschaft/StStephensDayTest.php index c74e6f0b1..0807b582a 100644 --- a/tests/Switzerland/BaselLandschaft/StStephensDayTest.php +++ b/tests/Switzerland/BaselLandschaft/StStephensDayTest.php @@ -48,7 +48,7 @@ public function testHoliday(int $year, DateTime $expected): void /** * Returns a list of random test dates used for assertion of the holiday defined in this test. * - * @return array list of test dates for the holiday defined in this test + * @return array list of test dates for the holiday defined in this test * * @throws Exception */ diff --git a/tests/Switzerland/BaselLandschaft/WorkersDayTest.php b/tests/Switzerland/BaselLandschaft/WorkersDayTest.php index 4f2d48978..fe2656b60 100644 --- a/tests/Switzerland/BaselLandschaft/WorkersDayTest.php +++ b/tests/Switzerland/BaselLandschaft/WorkersDayTest.php @@ -51,7 +51,7 @@ public function testHoliday(int $year, string $expected): void /** * Returns a list of random test dates used for assertion of the holiday defined in this test. * - * @return array list of test dates for the holiday defined in this test + * @return array list of test dates for the holiday defined in this test * * @throws Exception */ diff --git a/tests/Switzerland/BaselStadt/ChristmasDayTest.php b/tests/Switzerland/BaselStadt/ChristmasDayTest.php index 9307b4a03..2e4fb20c2 100644 --- a/tests/Switzerland/BaselStadt/ChristmasDayTest.php +++ b/tests/Switzerland/BaselStadt/ChristmasDayTest.php @@ -48,7 +48,7 @@ public function testChristmasDay(int $year, DateTime $expected): void /** * Returns a list of random test dates used for assertion of Christmas Day. * - * @return array list of test dates for Christmas Day + * @return array list of test dates for Christmas Day * * @throws Exception */ diff --git a/tests/Switzerland/BaselStadt/NewYearsDayTest.php b/tests/Switzerland/BaselStadt/NewYearsDayTest.php index 936395895..f8be83c24 100644 --- a/tests/Switzerland/BaselStadt/NewYearsDayTest.php +++ b/tests/Switzerland/BaselStadt/NewYearsDayTest.php @@ -73,7 +73,7 @@ public function testHolidayType(): void /** * Returns a list of random test dates used for assertion of New Years Day. * - * @return array list of test dates for New Years Day + * @return array list of test dates for New Years Day * * @throws Exception */ diff --git a/tests/Switzerland/BaselStadt/StStephensDayTest.php b/tests/Switzerland/BaselStadt/StStephensDayTest.php index 28d0e94ee..864939106 100644 --- a/tests/Switzerland/BaselStadt/StStephensDayTest.php +++ b/tests/Switzerland/BaselStadt/StStephensDayTest.php @@ -48,7 +48,7 @@ public function testHoliday(int $year, DateTime $expected): void /** * Returns a list of random test dates used for assertion of the holiday defined in this test. * - * @return array list of test dates for the holiday defined in this test + * @return array list of test dates for the holiday defined in this test * * @throws Exception */ diff --git a/tests/Switzerland/BaselStadt/WorkersDayTest.php b/tests/Switzerland/BaselStadt/WorkersDayTest.php index 8c784a7e2..2a772b678 100644 --- a/tests/Switzerland/BaselStadt/WorkersDayTest.php +++ b/tests/Switzerland/BaselStadt/WorkersDayTest.php @@ -51,7 +51,7 @@ public function testHoliday(int $year, string $expected): void /** * Returns a list of random test dates used for assertion of the holiday defined in this test. * - * @return array list of test dates for the holiday defined in this test + * @return array list of test dates for the holiday defined in this test * * @throws Exception */ diff --git a/tests/Switzerland/Bern/ChristmasDayTest.php b/tests/Switzerland/Bern/ChristmasDayTest.php index 70bc40e1b..b6585c5ce 100644 --- a/tests/Switzerland/Bern/ChristmasDayTest.php +++ b/tests/Switzerland/Bern/ChristmasDayTest.php @@ -48,7 +48,7 @@ public function testChristmasDay(int $year, DateTime $expected): void /** * Returns a list of random test dates used for assertion of Christmas Day. * - * @return array list of test dates for Christmas Day + * @return array list of test dates for Christmas Day * * @throws Exception */ diff --git a/tests/Switzerland/Bern/NewYearsDayTest.php b/tests/Switzerland/Bern/NewYearsDayTest.php index 2df10607d..e2e06f262 100644 --- a/tests/Switzerland/Bern/NewYearsDayTest.php +++ b/tests/Switzerland/Bern/NewYearsDayTest.php @@ -73,7 +73,7 @@ public function testHolidayType(): void /** * Returns a list of random test dates used for assertion of New Years Day. * - * @return array list of test dates for New Years Day + * @return array list of test dates for New Years Day * * @throws Exception */ diff --git a/tests/Switzerland/Bern/StStephensDayTest.php b/tests/Switzerland/Bern/StStephensDayTest.php index 3a4b37c53..a98ac2519 100644 --- a/tests/Switzerland/Bern/StStephensDayTest.php +++ b/tests/Switzerland/Bern/StStephensDayTest.php @@ -48,7 +48,7 @@ public function testHoliday(int $year, DateTime $expected): void /** * Returns a list of random test dates used for assertion of the holiday defined in this test. * - * @return array list of test dates for the holiday defined in this test + * @return array list of test dates for the holiday defined in this test * * @throws Exception */ diff --git a/tests/Switzerland/Fribourg/AllSaintsDayTest.php b/tests/Switzerland/Fribourg/AllSaintsDayTest.php index 795ab7c05..7f109391a 100644 --- a/tests/Switzerland/Fribourg/AllSaintsDayTest.php +++ b/tests/Switzerland/Fribourg/AllSaintsDayTest.php @@ -73,7 +73,7 @@ public function testHolidayType(): void /** * Returns a list of random test dates used for assertion of All Saints' Day. * - * @return array list of test dates for All Saints' Day + * @return array list of test dates for All Saints' Day * * @throws Exception */ diff --git a/tests/Switzerland/Fribourg/AssumptionOfMaryTest.php b/tests/Switzerland/Fribourg/AssumptionOfMaryTest.php index 64e64cc3a..85f457e24 100644 --- a/tests/Switzerland/Fribourg/AssumptionOfMaryTest.php +++ b/tests/Switzerland/Fribourg/AssumptionOfMaryTest.php @@ -73,7 +73,7 @@ public function testHolidayType(): void /** * Returns a list of random test dates used for assertion of the day of the Assumption of Mary. * - * @return array list of test dates for the day of the Assumption of Mary + * @return array list of test dates for the day of the Assumption of Mary * * @throws Exception */ diff --git a/tests/Switzerland/Fribourg/ChristmasDayTest.php b/tests/Switzerland/Fribourg/ChristmasDayTest.php index 6682a1d04..6673ba0c8 100644 --- a/tests/Switzerland/Fribourg/ChristmasDayTest.php +++ b/tests/Switzerland/Fribourg/ChristmasDayTest.php @@ -48,7 +48,7 @@ public function testChristmasDay(int $year, DateTime $expected): void /** * Returns a list of random test dates used for assertion of Christmas Day. * - * @return array list of test dates for Christmas Day + * @return array list of test dates for Christmas Day * * @throws Exception */ diff --git a/tests/Switzerland/Fribourg/ImmaculateConceptionTest.php b/tests/Switzerland/Fribourg/ImmaculateConceptionTest.php index 26f465dc3..2d65589c6 100644 --- a/tests/Switzerland/Fribourg/ImmaculateConceptionTest.php +++ b/tests/Switzerland/Fribourg/ImmaculateConceptionTest.php @@ -48,7 +48,7 @@ public function testHoliday(int $year, DateTime $expected): void /** * Returns a list of random test dates used for assertion of the holiday defined in this test. * - * @return array list of test dates for the day of the holiday defined in this test + * @return array list of test dates for the holiday defined in this test * * @throws Exception */ diff --git a/tests/Switzerland/Fribourg/NewYearsDayTest.php b/tests/Switzerland/Fribourg/NewYearsDayTest.php index 086c31b9f..d09cf73a3 100644 --- a/tests/Switzerland/Fribourg/NewYearsDayTest.php +++ b/tests/Switzerland/Fribourg/NewYearsDayTest.php @@ -73,7 +73,7 @@ public function testHolidayType(): void /** * Returns a list of random test dates used for assertion of New Years Day. * - * @return array list of test dates for New Years Day + * @return array list of test dates for New Years Day * * @throws Exception */ diff --git a/tests/Switzerland/Geneva/ChristmasDayTest.php b/tests/Switzerland/Geneva/ChristmasDayTest.php index 3f30a19d0..9592b1fb6 100644 --- a/tests/Switzerland/Geneva/ChristmasDayTest.php +++ b/tests/Switzerland/Geneva/ChristmasDayTest.php @@ -48,7 +48,7 @@ public function testChristmasDay(int $year, DateTime $expected): void /** * Returns a list of random test dates used for assertion of Christmas Day. * - * @return array list of test dates for Christmas Day + * @return array list of test dates for Christmas Day * * @throws Exception */ diff --git a/tests/Switzerland/Geneva/NewYearsDayTest.php b/tests/Switzerland/Geneva/NewYearsDayTest.php index 3447184d3..d3ea0a9d8 100644 --- a/tests/Switzerland/Geneva/NewYearsDayTest.php +++ b/tests/Switzerland/Geneva/NewYearsDayTest.php @@ -73,7 +73,7 @@ public function testHolidayType(): void /** * Returns a list of random test dates used for assertion of New Years Day. * - * @return array list of test dates for New Years Day + * @return array list of test dates for New Years Day * * @throws Exception */ diff --git a/tests/Switzerland/Glarus/AllSaintsDayTest.php b/tests/Switzerland/Glarus/AllSaintsDayTest.php index 9309a1de9..1aa755a79 100644 --- a/tests/Switzerland/Glarus/AllSaintsDayTest.php +++ b/tests/Switzerland/Glarus/AllSaintsDayTest.php @@ -73,7 +73,7 @@ public function testHolidayType(): void /** * Returns a list of random test dates used for assertion of All Saints' Day. * - * @return array list of test dates for All Saints' Day + * @return array list of test dates for All Saints' Day * * @throws Exception */ diff --git a/tests/Switzerland/Glarus/ChristmasDayTest.php b/tests/Switzerland/Glarus/ChristmasDayTest.php index 11a65655e..e5a7fd966 100644 --- a/tests/Switzerland/Glarus/ChristmasDayTest.php +++ b/tests/Switzerland/Glarus/ChristmasDayTest.php @@ -48,7 +48,7 @@ public function testChristmasDay(int $year, DateTime $expected): void /** * Returns a list of random test dates used for assertion of Christmas Day. * - * @return array list of test dates for Christmas Day + * @return array list of test dates for Christmas Day * * @throws Exception */ diff --git a/tests/Switzerland/Glarus/NewYearsDayTest.php b/tests/Switzerland/Glarus/NewYearsDayTest.php index dfd6b5c61..a1f01d1a1 100644 --- a/tests/Switzerland/Glarus/NewYearsDayTest.php +++ b/tests/Switzerland/Glarus/NewYearsDayTest.php @@ -73,7 +73,7 @@ public function testHolidayType(): void /** * Returns a list of random test dates used for assertion of New Years Day. * - * @return array list of test dates for New Years Day + * @return array list of test dates for New Years Day * * @throws Exception */ diff --git a/tests/Switzerland/Glarus/StStephensDayTest.php b/tests/Switzerland/Glarus/StStephensDayTest.php index 378351f34..80e5283c6 100644 --- a/tests/Switzerland/Glarus/StStephensDayTest.php +++ b/tests/Switzerland/Glarus/StStephensDayTest.php @@ -48,7 +48,7 @@ public function testHoliday(int $year, DateTime $expected): void /** * Returns a list of random test dates used for assertion of the holiday defined in this test. * - * @return array list of test dates for the holiday defined in this test + * @return array list of test dates for the holiday defined in this test * * @throws Exception */ diff --git a/tests/Switzerland/Grisons/ChristmasDayTest.php b/tests/Switzerland/Grisons/ChristmasDayTest.php index 6a04a9c60..a42b1d742 100644 --- a/tests/Switzerland/Grisons/ChristmasDayTest.php +++ b/tests/Switzerland/Grisons/ChristmasDayTest.php @@ -48,7 +48,7 @@ public function testChristmasDay(int $year, DateTime $expected): void /** * Returns a list of random test dates used for assertion of Christmas Day. * - * @return array list of test dates for Christmas Day + * @return array list of test dates for Christmas Day * * @throws Exception */ diff --git a/tests/Switzerland/Grisons/NewYearsDayTest.php b/tests/Switzerland/Grisons/NewYearsDayTest.php index 75ef609fc..cf596ac82 100644 --- a/tests/Switzerland/Grisons/NewYearsDayTest.php +++ b/tests/Switzerland/Grisons/NewYearsDayTest.php @@ -73,7 +73,7 @@ public function testHolidayType(): void /** * Returns a list of random test dates used for assertion of New Years Day. * - * @return array list of test dates for New Years Day + * @return array list of test dates for New Years Day * * @throws Exception */ diff --git a/tests/Switzerland/Grisons/StStephensDayTest.php b/tests/Switzerland/Grisons/StStephensDayTest.php index 2431f25fb..ddb5cf96a 100644 --- a/tests/Switzerland/Grisons/StStephensDayTest.php +++ b/tests/Switzerland/Grisons/StStephensDayTest.php @@ -48,7 +48,7 @@ public function testHoliday(int $year, DateTime $expected): void /** * Returns a list of random test dates used for assertion of the holiday defined in this test. * - * @return array list of test dates for the holiday defined in this test + * @return array list of test dates for the holiday defined in this test * * @throws Exception */ diff --git a/tests/Switzerland/Jura/AllSaintsDayTest.php b/tests/Switzerland/Jura/AllSaintsDayTest.php index f0f1693d9..2452b2bef 100644 --- a/tests/Switzerland/Jura/AllSaintsDayTest.php +++ b/tests/Switzerland/Jura/AllSaintsDayTest.php @@ -73,7 +73,7 @@ public function testHolidayType(): void /** * Returns a list of random test dates used for assertion of All Saints' Day. * - * @return array list of test dates for All Saints' Day + * @return array list of test dates for All Saints' Day * * @throws Exception */ diff --git a/tests/Switzerland/Jura/AssumptionOfMaryTest.php b/tests/Switzerland/Jura/AssumptionOfMaryTest.php index 99d0baf07..97ae5e632 100644 --- a/tests/Switzerland/Jura/AssumptionOfMaryTest.php +++ b/tests/Switzerland/Jura/AssumptionOfMaryTest.php @@ -73,7 +73,7 @@ public function testHolidayType(): void /** * Returns a list of random test dates used for assertion of the day of the Assumption of Mary. * - * @return array list of test dates for the day of the Assumption of Mary + * @return array list of test dates for the day of the Assumption of Mary * * @throws Exception */ diff --git a/tests/Switzerland/Jura/ChristmasDayTest.php b/tests/Switzerland/Jura/ChristmasDayTest.php index 6a1f07d9a..a8918601a 100644 --- a/tests/Switzerland/Jura/ChristmasDayTest.php +++ b/tests/Switzerland/Jura/ChristmasDayTest.php @@ -48,7 +48,7 @@ public function testChristmasDay(int $year, DateTime $expected): void /** * Returns a list of random test dates used for assertion of Christmas Day. * - * @return array list of test dates for Christmas Day + * @return array list of test dates for Christmas Day * * @throws Exception */ diff --git a/tests/Switzerland/Jura/NewYearsDayTest.php b/tests/Switzerland/Jura/NewYearsDayTest.php index a961530ac..01928d6bd 100644 --- a/tests/Switzerland/Jura/NewYearsDayTest.php +++ b/tests/Switzerland/Jura/NewYearsDayTest.php @@ -73,7 +73,7 @@ public function testHolidayType(): void /** * Returns a list of random test dates used for assertion of New Years Day. * - * @return array list of test dates for New Years Day + * @return array list of test dates for New Years Day * * @throws Exception */ diff --git a/tests/Switzerland/Jura/WorkersDayTest.php b/tests/Switzerland/Jura/WorkersDayTest.php index 5e95d525a..6a6d7ab8a 100644 --- a/tests/Switzerland/Jura/WorkersDayTest.php +++ b/tests/Switzerland/Jura/WorkersDayTest.php @@ -51,7 +51,7 @@ public function testHoliday(int $year, string $expected): void /** * Returns a list of random test dates used for assertion of the holiday defined in this test. * - * @return array list of test dates for the holiday defined in this test + * @return array list of test dates for the holiday defined in this test * * @throws Exception */ diff --git a/tests/Switzerland/Lucerne/AllSaintsDayTest.php b/tests/Switzerland/Lucerne/AllSaintsDayTest.php index f7ee3e4c6..17ba5b196 100644 --- a/tests/Switzerland/Lucerne/AllSaintsDayTest.php +++ b/tests/Switzerland/Lucerne/AllSaintsDayTest.php @@ -73,7 +73,7 @@ public function testHolidayType(): void /** * Returns a list of random test dates used for assertion of All Saints' Day. * - * @return array list of test dates for All Saints' Day + * @return array list of test dates for All Saints' Day * * @throws Exception */ diff --git a/tests/Switzerland/Lucerne/AssumptionOfMaryTest.php b/tests/Switzerland/Lucerne/AssumptionOfMaryTest.php index 9a6cf4694..2396238b7 100644 --- a/tests/Switzerland/Lucerne/AssumptionOfMaryTest.php +++ b/tests/Switzerland/Lucerne/AssumptionOfMaryTest.php @@ -73,7 +73,7 @@ public function testHolidayType(): void /** * Returns a list of random test dates used for assertion of the day of the Assumption of Mary. * - * @return array list of test dates for the day of the Assumption of Mary + * @return array list of test dates for the day of the Assumption of Mary * * @throws Exception */ diff --git a/tests/Switzerland/Lucerne/ChristmasDayTest.php b/tests/Switzerland/Lucerne/ChristmasDayTest.php index 460ab8c84..50cb199c9 100644 --- a/tests/Switzerland/Lucerne/ChristmasDayTest.php +++ b/tests/Switzerland/Lucerne/ChristmasDayTest.php @@ -48,7 +48,7 @@ public function testChristmasDay(int $year, DateTime $expected): void /** * Returns a list of random test dates used for assertion of Christmas Day. * - * @return array list of test dates for Christmas Day + * @return array list of test dates for Christmas Day * * @throws Exception */ diff --git a/tests/Switzerland/Lucerne/ImmaculateConceptionTest.php b/tests/Switzerland/Lucerne/ImmaculateConceptionTest.php index 152da33cb..9f6299c67 100644 --- a/tests/Switzerland/Lucerne/ImmaculateConceptionTest.php +++ b/tests/Switzerland/Lucerne/ImmaculateConceptionTest.php @@ -48,7 +48,7 @@ public function testHoliday(int $year, DateTime $expected): void /** * Returns a list of random test dates used for assertion of the holiday defined in this test. * - * @return array list of test dates for the day of the holiday defined in this test + * @return array list of test dates for the holiday defined in this test * * @throws Exception */ diff --git a/tests/Switzerland/Lucerne/NewYearsDayTest.php b/tests/Switzerland/Lucerne/NewYearsDayTest.php index beb0f60d9..c0b1b305d 100644 --- a/tests/Switzerland/Lucerne/NewYearsDayTest.php +++ b/tests/Switzerland/Lucerne/NewYearsDayTest.php @@ -73,7 +73,7 @@ public function testHolidayType(): void /** * Returns a list of random test dates used for assertion of New Years Day. * - * @return array list of test dates for New Years Day + * @return array list of test dates for New Years Day * * @throws Exception */ diff --git a/tests/Switzerland/Lucerne/StStephensDayTest.php b/tests/Switzerland/Lucerne/StStephensDayTest.php index e87f3c51e..cc42010da 100644 --- a/tests/Switzerland/Lucerne/StStephensDayTest.php +++ b/tests/Switzerland/Lucerne/StStephensDayTest.php @@ -48,7 +48,7 @@ public function testHoliday(int $year, DateTime $expected): void /** * Returns a list of random test dates used for assertion of the holiday defined in this test. * - * @return array list of test dates for the holiday defined in this test + * @return array list of test dates for the holiday defined in this test * * @throws Exception */ diff --git a/tests/Switzerland/Neuchatel/ChristmasDayTest.php b/tests/Switzerland/Neuchatel/ChristmasDayTest.php index 5ac9e6384..556fd9367 100644 --- a/tests/Switzerland/Neuchatel/ChristmasDayTest.php +++ b/tests/Switzerland/Neuchatel/ChristmasDayTest.php @@ -48,7 +48,7 @@ public function testChristmasDay(int $year, DateTime $expected): void /** * Returns a list of random test dates used for assertion of Christmas Day. * - * @return array list of test dates for Christmas Day + * @return array list of test dates for Christmas Day * * @throws Exception */ diff --git a/tests/Switzerland/Neuchatel/NewYearsDayTest.php b/tests/Switzerland/Neuchatel/NewYearsDayTest.php index 78fccac81..67dd2a8ef 100644 --- a/tests/Switzerland/Neuchatel/NewYearsDayTest.php +++ b/tests/Switzerland/Neuchatel/NewYearsDayTest.php @@ -73,7 +73,7 @@ public function testHolidayType(): void /** * Returns a list of random test dates used for assertion of New Years Day. * - * @return array list of test dates for New Years Day + * @return array list of test dates for New Years Day * * @throws Exception */ diff --git a/tests/Switzerland/Neuchatel/WorkersDayTest.php b/tests/Switzerland/Neuchatel/WorkersDayTest.php index a9b319e03..102f3fb93 100644 --- a/tests/Switzerland/Neuchatel/WorkersDayTest.php +++ b/tests/Switzerland/Neuchatel/WorkersDayTest.php @@ -51,7 +51,7 @@ public function testHoliday(int $year, string $expected): void /** * Returns a list of random test dates used for assertion of the holiday defined in this test. * - * @return array list of test dates for the holiday defined in this test + * @return array list of test dates for the holiday defined in this test * * @throws Exception */ diff --git a/tests/Switzerland/Nidwalden/AllSaintsDayTest.php b/tests/Switzerland/Nidwalden/AllSaintsDayTest.php index 618265c0b..93a0ff464 100644 --- a/tests/Switzerland/Nidwalden/AllSaintsDayTest.php +++ b/tests/Switzerland/Nidwalden/AllSaintsDayTest.php @@ -73,7 +73,7 @@ public function testHolidayType(): void /** * Returns a list of random test dates used for assertion of All Saints' Day. * - * @return array list of test dates for All Saints' Day + * @return array list of test dates for All Saints' Day * * @throws Exception */ diff --git a/tests/Switzerland/Nidwalden/AssumptionOfMaryTest.php b/tests/Switzerland/Nidwalden/AssumptionOfMaryTest.php index 84da7fb8c..572742fac 100644 --- a/tests/Switzerland/Nidwalden/AssumptionOfMaryTest.php +++ b/tests/Switzerland/Nidwalden/AssumptionOfMaryTest.php @@ -73,7 +73,7 @@ public function testHolidayType(): void /** * Returns a list of random test dates used for assertion of the day of the Assumption of Mary. * - * @return array list of test dates for the day of the Assumption of Mary + * @return array list of test dates for the day of the Assumption of Mary * * @throws Exception */ diff --git a/tests/Switzerland/Nidwalden/ChristmasDayTest.php b/tests/Switzerland/Nidwalden/ChristmasDayTest.php index 781b969b7..e905354a4 100644 --- a/tests/Switzerland/Nidwalden/ChristmasDayTest.php +++ b/tests/Switzerland/Nidwalden/ChristmasDayTest.php @@ -48,7 +48,7 @@ public function testChristmasDay(int $year, DateTime $expected): void /** * Returns a list of random test dates used for assertion of Christmas Day. * - * @return array list of test dates for Christmas Day + * @return array list of test dates for Christmas Day * * @throws Exception */ diff --git a/tests/Switzerland/Nidwalden/ImmaculateConceptionTest.php b/tests/Switzerland/Nidwalden/ImmaculateConceptionTest.php index ebcba00b5..b49a246bf 100644 --- a/tests/Switzerland/Nidwalden/ImmaculateConceptionTest.php +++ b/tests/Switzerland/Nidwalden/ImmaculateConceptionTest.php @@ -48,7 +48,7 @@ public function testHoliday(int $year, DateTime $expected): void /** * Returns a list of random test dates used for assertion of the holiday defined in this test. * - * @return array list of test dates for the day of the holiday defined in this test + * @return array list of test dates for the holiday defined in this test * * @throws Exception */ diff --git a/tests/Switzerland/Nidwalden/NewYearsDayTest.php b/tests/Switzerland/Nidwalden/NewYearsDayTest.php index a5f6fa17e..3b3573f40 100644 --- a/tests/Switzerland/Nidwalden/NewYearsDayTest.php +++ b/tests/Switzerland/Nidwalden/NewYearsDayTest.php @@ -73,7 +73,7 @@ public function testHolidayType(): void /** * Returns a list of random test dates used for assertion of New Years Day. * - * @return array list of test dates for New Years Day + * @return array list of test dates for New Years Day * * @throws Exception */ diff --git a/tests/Switzerland/Nidwalden/StJosephDayTest.php b/tests/Switzerland/Nidwalden/StJosephDayTest.php index 67f09bc3d..c755e1687 100644 --- a/tests/Switzerland/Nidwalden/StJosephDayTest.php +++ b/tests/Switzerland/Nidwalden/StJosephDayTest.php @@ -51,7 +51,7 @@ public function testStJosephDay(int $year, DateTime $expected): void /** * Returns a list of random test dates used for assertion of St. Joseph's Day. * - * @return array list of test dates for St. Joseph's Day + * @return array list of test dates for St. Joseph's Day * * @throws Exception */ diff --git a/tests/Switzerland/Nidwalden/StStephensDayTest.php b/tests/Switzerland/Nidwalden/StStephensDayTest.php index fca401103..222b738fe 100644 --- a/tests/Switzerland/Nidwalden/StStephensDayTest.php +++ b/tests/Switzerland/Nidwalden/StStephensDayTest.php @@ -48,7 +48,7 @@ public function testHoliday(int $year, DateTime $expected): void /** * Returns a list of random test dates used for assertion of the holiday defined in this test. * - * @return array list of test dates for the holiday defined in this test + * @return array list of test dates for the holiday defined in this test * * @throws Exception */ diff --git a/tests/Switzerland/Obwalden/AllSaintsDayTest.php b/tests/Switzerland/Obwalden/AllSaintsDayTest.php index 7ff738679..e45f7a03f 100644 --- a/tests/Switzerland/Obwalden/AllSaintsDayTest.php +++ b/tests/Switzerland/Obwalden/AllSaintsDayTest.php @@ -73,7 +73,7 @@ public function testHolidayType(): void /** * Returns a list of random test dates used for assertion of All Saints' Day. * - * @return array list of test dates for All Saints' Day + * @return array list of test dates for All Saints' Day * * @throws Exception */ diff --git a/tests/Switzerland/Obwalden/AssumptionOfMaryTest.php b/tests/Switzerland/Obwalden/AssumptionOfMaryTest.php index 83d9f7e55..b984c240a 100644 --- a/tests/Switzerland/Obwalden/AssumptionOfMaryTest.php +++ b/tests/Switzerland/Obwalden/AssumptionOfMaryTest.php @@ -73,7 +73,7 @@ public function testHolidayType(): void /** * Returns a list of random test dates used for assertion of the day of the Assumption of Mary. * - * @return array list of test dates for the day of the Assumption of Mary + * @return array list of test dates for the day of the Assumption of Mary * * @throws Exception */ diff --git a/tests/Switzerland/Obwalden/ChristmasDayTest.php b/tests/Switzerland/Obwalden/ChristmasDayTest.php index cbfdf7dfc..859ddeaa1 100644 --- a/tests/Switzerland/Obwalden/ChristmasDayTest.php +++ b/tests/Switzerland/Obwalden/ChristmasDayTest.php @@ -48,7 +48,7 @@ public function testChristmasDay(int $year, DateTime $expected): void /** * Returns a list of random test dates used for assertion of Christmas Day. * - * @return array list of test dates for Christmas Day + * @return array list of test dates for Christmas Day * * @throws Exception */ diff --git a/tests/Switzerland/Obwalden/ImmaculateConceptionTest.php b/tests/Switzerland/Obwalden/ImmaculateConceptionTest.php index 0632cb40d..f9d7a5cc9 100644 --- a/tests/Switzerland/Obwalden/ImmaculateConceptionTest.php +++ b/tests/Switzerland/Obwalden/ImmaculateConceptionTest.php @@ -48,7 +48,7 @@ public function testHoliday(int $year, DateTime $expected): void /** * Returns a list of random test dates used for assertion of the holiday defined in this test. * - * @return array list of test dates for the day of the holiday defined in this test + * @return array list of test dates for the holiday defined in this test * * @throws Exception */ diff --git a/tests/Switzerland/Obwalden/NewYearsDayTest.php b/tests/Switzerland/Obwalden/NewYearsDayTest.php index dbfd43780..23e29fdc4 100644 --- a/tests/Switzerland/Obwalden/NewYearsDayTest.php +++ b/tests/Switzerland/Obwalden/NewYearsDayTest.php @@ -73,7 +73,7 @@ public function testHolidayType(): void /** * Returns a list of random test dates used for assertion of New Years Day. * - * @return array list of test dates for New Years Day + * @return array list of test dates for New Years Day * * @throws Exception */ diff --git a/tests/Switzerland/Obwalden/StStephensDayTest.php b/tests/Switzerland/Obwalden/StStephensDayTest.php index bd5f21cc5..32d427e3d 100644 --- a/tests/Switzerland/Obwalden/StStephensDayTest.php +++ b/tests/Switzerland/Obwalden/StStephensDayTest.php @@ -48,7 +48,7 @@ public function testHoliday(int $year, DateTime $expected): void /** * Returns a list of random test dates used for assertion of the holiday defined in this test. * - * @return array list of test dates for the holiday defined in this test + * @return array list of test dates for the holiday defined in this test * * @throws Exception */ diff --git a/tests/Switzerland/Schaffhausen/ChristmasDayTest.php b/tests/Switzerland/Schaffhausen/ChristmasDayTest.php index 863c12c8e..274e8ced9 100644 --- a/tests/Switzerland/Schaffhausen/ChristmasDayTest.php +++ b/tests/Switzerland/Schaffhausen/ChristmasDayTest.php @@ -48,7 +48,7 @@ public function testChristmasDay(int $year, DateTime $expected): void /** * Returns a list of random test dates used for assertion of Christmas Day. * - * @return array list of test dates for Christmas Day + * @return array list of test dates for Christmas Day * * @throws Exception */ diff --git a/tests/Switzerland/Schaffhausen/NewYearsDayTest.php b/tests/Switzerland/Schaffhausen/NewYearsDayTest.php index 44963f866..42eff7880 100644 --- a/tests/Switzerland/Schaffhausen/NewYearsDayTest.php +++ b/tests/Switzerland/Schaffhausen/NewYearsDayTest.php @@ -73,7 +73,7 @@ public function testHolidayType(): void /** * Returns a list of random test dates used for assertion of New Years Day. * - * @return array list of test dates for New Years Day + * @return array list of test dates for New Years Day * * @throws Exception */ diff --git a/tests/Switzerland/Schaffhausen/StStephensDayTest.php b/tests/Switzerland/Schaffhausen/StStephensDayTest.php index 8264f20a1..2af128680 100644 --- a/tests/Switzerland/Schaffhausen/StStephensDayTest.php +++ b/tests/Switzerland/Schaffhausen/StStephensDayTest.php @@ -48,7 +48,7 @@ public function testHoliday(int $year, DateTime $expected): void /** * Returns a list of random test dates used for assertion of the holiday defined in this test. * - * @return array list of test dates for the holiday defined in this test + * @return array list of test dates for the holiday defined in this test * * @throws Exception */ diff --git a/tests/Switzerland/Schaffhausen/WorkersDayTest.php b/tests/Switzerland/Schaffhausen/WorkersDayTest.php index 7bafe1742..efe1fe5d6 100644 --- a/tests/Switzerland/Schaffhausen/WorkersDayTest.php +++ b/tests/Switzerland/Schaffhausen/WorkersDayTest.php @@ -51,7 +51,7 @@ public function testHoliday(int $year, string $expected): void /** * Returns a list of random test dates used for assertion of the holiday defined in this test. * - * @return array list of test dates for the holiday defined in this test + * @return array list of test dates for the holiday defined in this test * * @throws Exception */ diff --git a/tests/Switzerland/Schwyz/AllSaintsDayTest.php b/tests/Switzerland/Schwyz/AllSaintsDayTest.php index a326cfc26..29f38fbc0 100644 --- a/tests/Switzerland/Schwyz/AllSaintsDayTest.php +++ b/tests/Switzerland/Schwyz/AllSaintsDayTest.php @@ -73,7 +73,7 @@ public function testHolidayType(): void /** * Returns a list of random test dates used for assertion of All Saints' Day. * - * @return array list of test dates for All Saints' Day + * @return array list of test dates for All Saints' Day * * @throws Exception */ diff --git a/tests/Switzerland/Schwyz/AssumptionOfMaryTest.php b/tests/Switzerland/Schwyz/AssumptionOfMaryTest.php index b23410274..d3923041f 100644 --- a/tests/Switzerland/Schwyz/AssumptionOfMaryTest.php +++ b/tests/Switzerland/Schwyz/AssumptionOfMaryTest.php @@ -73,7 +73,7 @@ public function testHolidayType(): void /** * Returns a list of random test dates used for assertion of the day of the Assumption of Mary. * - * @return array list of test dates for the day of the Assumption of Mary + * @return array list of test dates for the day of the Assumption of Mary * * @throws Exception */ diff --git a/tests/Switzerland/Schwyz/ChristmasDayTest.php b/tests/Switzerland/Schwyz/ChristmasDayTest.php index 741cd464f..9a71d4e02 100644 --- a/tests/Switzerland/Schwyz/ChristmasDayTest.php +++ b/tests/Switzerland/Schwyz/ChristmasDayTest.php @@ -48,7 +48,7 @@ public function testChristmasDay(int $year, DateTime $expected): void /** * Returns a list of random test dates used for assertion of Christmas Day. * - * @return array list of test dates for Christmas Day + * @return array list of test dates for Christmas Day * * @throws Exception */ diff --git a/tests/Switzerland/Schwyz/EpiphanyTest.php b/tests/Switzerland/Schwyz/EpiphanyTest.php index 2d4f998d2..38ff413c4 100644 --- a/tests/Switzerland/Schwyz/EpiphanyTest.php +++ b/tests/Switzerland/Schwyz/EpiphanyTest.php @@ -48,7 +48,7 @@ public function testHoliday(int $year, DateTime $expected): void /** * Returns a list of random test dates used for assertion of the holiday defined in this test. * - * @return array list of test dates for the day of the holiday defined in this test + * @return array list of test dates for the holiday defined in this test * * @throws Exception */ diff --git a/tests/Switzerland/Schwyz/ImmaculateConceptionTest.php b/tests/Switzerland/Schwyz/ImmaculateConceptionTest.php index 3f26bf35c..af29abe19 100644 --- a/tests/Switzerland/Schwyz/ImmaculateConceptionTest.php +++ b/tests/Switzerland/Schwyz/ImmaculateConceptionTest.php @@ -48,7 +48,7 @@ public function testHoliday(int $year, DateTime $expected): void /** * Returns a list of random test dates used for assertion of the holiday defined in this test. * - * @return array list of test dates for the day of the holiday defined in this test + * @return array list of test dates for the holiday defined in this test * * @throws Exception */ diff --git a/tests/Switzerland/Schwyz/NewYearsDayTest.php b/tests/Switzerland/Schwyz/NewYearsDayTest.php index deefbaeca..cd7494ae5 100644 --- a/tests/Switzerland/Schwyz/NewYearsDayTest.php +++ b/tests/Switzerland/Schwyz/NewYearsDayTest.php @@ -73,7 +73,7 @@ public function testHolidayType(): void /** * Returns a list of random test dates used for assertion of New Years Day. * - * @return array list of test dates for New Years Day + * @return array list of test dates for New Years Day * * @throws Exception */ diff --git a/tests/Switzerland/Schwyz/StJosephDayTest.php b/tests/Switzerland/Schwyz/StJosephDayTest.php index a68c33a96..48a1bfd67 100644 --- a/tests/Switzerland/Schwyz/StJosephDayTest.php +++ b/tests/Switzerland/Schwyz/StJosephDayTest.php @@ -51,7 +51,7 @@ public function testStJosephDay(int $year, DateTime $expected): void /** * Returns a list of random test dates used for assertion of St. Joseph's Day. * - * @return array list of test dates for St. Joseph's Day + * @return array list of test dates for St. Joseph's Day * * @throws Exception */ diff --git a/tests/Switzerland/Schwyz/StStephensDayTest.php b/tests/Switzerland/Schwyz/StStephensDayTest.php index 456e62bb6..8843a3dc4 100644 --- a/tests/Switzerland/Schwyz/StStephensDayTest.php +++ b/tests/Switzerland/Schwyz/StStephensDayTest.php @@ -48,7 +48,7 @@ public function testHoliday(int $year, DateTime $expected): void /** * Returns a list of random test dates used for assertion of the holiday defined in this test. * - * @return array list of test dates for the holiday defined in this test + * @return array list of test dates for the holiday defined in this test * * @throws Exception */ diff --git a/tests/Switzerland/Solothurn/ChristmasDayTest.php b/tests/Switzerland/Solothurn/ChristmasDayTest.php index d5bbc5883..e3117293d 100644 --- a/tests/Switzerland/Solothurn/ChristmasDayTest.php +++ b/tests/Switzerland/Solothurn/ChristmasDayTest.php @@ -48,7 +48,7 @@ public function testChristmasDay(int $year, DateTime $expected): void /** * Returns a list of random test dates used for assertion of Christmas Day. * - * @return array list of test dates for Christmas Day + * @return array list of test dates for Christmas Day * * @throws Exception */ diff --git a/tests/Switzerland/Solothurn/NewYearsDayTest.php b/tests/Switzerland/Solothurn/NewYearsDayTest.php index 1209a3f1b..658e4dc5f 100644 --- a/tests/Switzerland/Solothurn/NewYearsDayTest.php +++ b/tests/Switzerland/Solothurn/NewYearsDayTest.php @@ -73,7 +73,7 @@ public function testHolidayType(): void /** * Returns a list of random test dates used for assertion of New Years Day. * - * @return array list of test dates for New Years Day + * @return array list of test dates for New Years Day * * @throws Exception */ diff --git a/tests/Switzerland/StGallen/AllSaintsDayTest.php b/tests/Switzerland/StGallen/AllSaintsDayTest.php index 38315b04a..c8bb3cf9c 100644 --- a/tests/Switzerland/StGallen/AllSaintsDayTest.php +++ b/tests/Switzerland/StGallen/AllSaintsDayTest.php @@ -73,7 +73,7 @@ public function testHolidayType(): void /** * Returns a list of random test dates used for assertion of All Saints' Day. * - * @return array list of test dates for All Saints' Day + * @return array list of test dates for All Saints' Day * * @throws Exception */ diff --git a/tests/Switzerland/StGallen/ChristmasDayTest.php b/tests/Switzerland/StGallen/ChristmasDayTest.php index 5b033a8a0..8eef44970 100644 --- a/tests/Switzerland/StGallen/ChristmasDayTest.php +++ b/tests/Switzerland/StGallen/ChristmasDayTest.php @@ -48,7 +48,7 @@ public function testChristmasDay(int $year, DateTime $expected): void /** * Returns a list of random test dates used for assertion of Christmas Day. * - * @return array list of test dates for Christmas Day + * @return array list of test dates for Christmas Day * * @throws Exception */ diff --git a/tests/Switzerland/StGallen/NewYearsDayTest.php b/tests/Switzerland/StGallen/NewYearsDayTest.php index 268fba7e3..80c22cb2e 100644 --- a/tests/Switzerland/StGallen/NewYearsDayTest.php +++ b/tests/Switzerland/StGallen/NewYearsDayTest.php @@ -73,7 +73,7 @@ public function testHolidayType(): void /** * Returns a list of random test dates used for assertion of New Years Day. * - * @return array list of test dates for New Years Day + * @return array list of test dates for New Years Day * * @throws Exception */ diff --git a/tests/Switzerland/StGallen/StStephensDayTest.php b/tests/Switzerland/StGallen/StStephensDayTest.php index 0abcae41a..83e8d1470 100644 --- a/tests/Switzerland/StGallen/StStephensDayTest.php +++ b/tests/Switzerland/StGallen/StStephensDayTest.php @@ -48,7 +48,7 @@ public function testHoliday(int $year, DateTime $expected): void /** * Returns a list of random test dates used for assertion of the holiday defined in this test. * - * @return array list of test dates for the holiday defined in this test + * @return array list of test dates for the holiday defined in this test * * @throws Exception */ diff --git a/tests/Switzerland/Thurgau/ChristmasDayTest.php b/tests/Switzerland/Thurgau/ChristmasDayTest.php index 1827fd155..f8944fa49 100644 --- a/tests/Switzerland/Thurgau/ChristmasDayTest.php +++ b/tests/Switzerland/Thurgau/ChristmasDayTest.php @@ -48,7 +48,7 @@ public function testChristmasDay(int $year, DateTime $expected): void /** * Returns a list of random test dates used for assertion of Christmas Day. * - * @return array list of test dates for Christmas Day + * @return array list of test dates for Christmas Day * * @throws Exception */ diff --git a/tests/Switzerland/Thurgau/NewYearsDayTest.php b/tests/Switzerland/Thurgau/NewYearsDayTest.php index 613306be1..731276734 100644 --- a/tests/Switzerland/Thurgau/NewYearsDayTest.php +++ b/tests/Switzerland/Thurgau/NewYearsDayTest.php @@ -73,7 +73,7 @@ public function testHolidayType(): void /** * Returns a list of random test dates used for assertion of New Years Day. * - * @return array list of test dates for New Years Day + * @return array list of test dates for New Years Day * * @throws Exception */ diff --git a/tests/Switzerland/Thurgau/StStephensDayTest.php b/tests/Switzerland/Thurgau/StStephensDayTest.php index a22751424..19a1eebff 100644 --- a/tests/Switzerland/Thurgau/StStephensDayTest.php +++ b/tests/Switzerland/Thurgau/StStephensDayTest.php @@ -48,7 +48,7 @@ public function testHoliday(int $year, DateTime $expected): void /** * Returns a list of random test dates used for assertion of the holiday defined in this test. * - * @return array list of test dates for the holiday defined in this test + * @return array list of test dates for the holiday defined in this test * * @throws Exception */ diff --git a/tests/Switzerland/Thurgau/WorkersDayTest.php b/tests/Switzerland/Thurgau/WorkersDayTest.php index f802ff2f4..f01f8926b 100644 --- a/tests/Switzerland/Thurgau/WorkersDayTest.php +++ b/tests/Switzerland/Thurgau/WorkersDayTest.php @@ -51,7 +51,7 @@ public function testHoliday(int $year, string $expected): void /** * Returns a list of random test dates used for assertion of the holiday defined in this test. * - * @return array list of test dates for the holiday defined in this test + * @return array list of test dates for the holiday defined in this test * * @throws Exception */ diff --git a/tests/Switzerland/Ticino/AllSaintsDayTest.php b/tests/Switzerland/Ticino/AllSaintsDayTest.php index ba67385a9..3495fc29e 100644 --- a/tests/Switzerland/Ticino/AllSaintsDayTest.php +++ b/tests/Switzerland/Ticino/AllSaintsDayTest.php @@ -73,7 +73,7 @@ public function testHolidayType(): void /** * Returns a list of random test dates used for assertion of All Saints' Day. * - * @return array list of test dates for All Saints' Day + * @return array list of test dates for All Saints' Day * * @throws Exception */ diff --git a/tests/Switzerland/Ticino/AssumptionOfMaryTest.php b/tests/Switzerland/Ticino/AssumptionOfMaryTest.php index 8fea858c8..940f711ad 100644 --- a/tests/Switzerland/Ticino/AssumptionOfMaryTest.php +++ b/tests/Switzerland/Ticino/AssumptionOfMaryTest.php @@ -73,7 +73,7 @@ public function testHolidayType(): void /** * Returns a list of random test dates used for assertion of the day of the Assumption of Mary. * - * @return array list of test dates for the day of the Assumption of Mary + * @return array list of test dates for the day of the Assumption of Mary * * @throws Exception */ diff --git a/tests/Switzerland/Ticino/ChristmasDayTest.php b/tests/Switzerland/Ticino/ChristmasDayTest.php index 51fbd26a3..861d96a92 100644 --- a/tests/Switzerland/Ticino/ChristmasDayTest.php +++ b/tests/Switzerland/Ticino/ChristmasDayTest.php @@ -48,7 +48,7 @@ public function testChristmasDay(int $year, DateTime $expected): void /** * Returns a list of random test dates used for assertion of Christmas Day. * - * @return array list of test dates for Christmas Day + * @return array list of test dates for Christmas Day * * @throws Exception */ diff --git a/tests/Switzerland/Ticino/EpiphanyTest.php b/tests/Switzerland/Ticino/EpiphanyTest.php index 348b6e544..f7ee9df0f 100644 --- a/tests/Switzerland/Ticino/EpiphanyTest.php +++ b/tests/Switzerland/Ticino/EpiphanyTest.php @@ -48,7 +48,7 @@ public function testHoliday(int $year, DateTime $expected): void /** * Returns a list of random test dates used for assertion of the holiday defined in this test. * - * @return array list of test dates for the day of the holiday defined in this test + * @return array list of test dates for the holiday defined in this test * * @throws Exception */ diff --git a/tests/Switzerland/Ticino/ImmaculateConceptionTest.php b/tests/Switzerland/Ticino/ImmaculateConceptionTest.php index 95214fae2..613bd96bd 100644 --- a/tests/Switzerland/Ticino/ImmaculateConceptionTest.php +++ b/tests/Switzerland/Ticino/ImmaculateConceptionTest.php @@ -48,7 +48,7 @@ public function testHoliday(int $year, DateTime $expected): void /** * Returns a list of random test dates used for assertion of the holiday defined in this test. * - * @return array list of test dates for the day of the holiday defined in this test + * @return array list of test dates for the holiday defined in this test * * @throws Exception */ diff --git a/tests/Switzerland/Ticino/NewYearsDayTest.php b/tests/Switzerland/Ticino/NewYearsDayTest.php index 1dabc57c7..e91d08956 100644 --- a/tests/Switzerland/Ticino/NewYearsDayTest.php +++ b/tests/Switzerland/Ticino/NewYearsDayTest.php @@ -73,7 +73,7 @@ public function testHolidayType(): void /** * Returns a list of random test dates used for assertion of New Years Day. * - * @return array list of test dates for New Years Day + * @return array list of test dates for New Years Day * * @throws Exception */ diff --git a/tests/Switzerland/Ticino/StJosephDayTest.php b/tests/Switzerland/Ticino/StJosephDayTest.php index 8b3e0e13d..24562f239 100644 --- a/tests/Switzerland/Ticino/StJosephDayTest.php +++ b/tests/Switzerland/Ticino/StJosephDayTest.php @@ -51,7 +51,7 @@ public function testStJosephDay(int $year, DateTime $expected): void /** * Returns a list of random test dates used for assertion of St. Joseph's Day. * - * @return array list of test dates for St. Joseph's Day + * @return array list of test dates for St. Joseph's Day * * @throws Exception */ diff --git a/tests/Switzerland/Ticino/StPeterPaulTest.php b/tests/Switzerland/Ticino/StPeterPaulTest.php index e1e7667a9..80af96580 100644 --- a/tests/Switzerland/Ticino/StPeterPaulTest.php +++ b/tests/Switzerland/Ticino/StPeterPaulTest.php @@ -48,7 +48,7 @@ public function testStPeterPaul(int $year, DateTime $expected): void /** * Returns a list of random test dates used for assertion of Feast of Saints Peter and Paul. * - * @return array list of test dates for Feast of Saints Peter and Paul + * @return array list of test dates for Feast of Saints Peter and Paul * * @throws Exception */ diff --git a/tests/Switzerland/Ticino/StStephensDayTest.php b/tests/Switzerland/Ticino/StStephensDayTest.php index 71b9f62c4..c753c859c 100644 --- a/tests/Switzerland/Ticino/StStephensDayTest.php +++ b/tests/Switzerland/Ticino/StStephensDayTest.php @@ -48,7 +48,7 @@ public function testHoliday(int $year, DateTime $expected): void /** * Returns a list of random test dates used for assertion of the holiday defined in this test. * - * @return array list of test dates for the holiday defined in this test + * @return array list of test dates for the holiday defined in this test * * @throws Exception */ diff --git a/tests/Switzerland/Ticino/WorkersDayTest.php b/tests/Switzerland/Ticino/WorkersDayTest.php index 77ee0c689..3562dd3e6 100644 --- a/tests/Switzerland/Ticino/WorkersDayTest.php +++ b/tests/Switzerland/Ticino/WorkersDayTest.php @@ -51,7 +51,7 @@ public function testHoliday(int $year, string $expected): void /** * Returns a list of random test dates used for assertion of the holiday defined in this test. * - * @return array list of test dates for the holiday defined in this test + * @return array list of test dates for the holiday defined in this test * * @throws Exception */ diff --git a/tests/Switzerland/Uri/AllSaintsDayTest.php b/tests/Switzerland/Uri/AllSaintsDayTest.php index 30b09f5fc..41c7f8ac5 100644 --- a/tests/Switzerland/Uri/AllSaintsDayTest.php +++ b/tests/Switzerland/Uri/AllSaintsDayTest.php @@ -73,7 +73,7 @@ public function testHolidayType(): void /** * Returns a list of random test dates used for assertion of All Saints' Day. * - * @return array list of test dates for All Saints' Day + * @return array list of test dates for All Saints' Day * * @throws Exception */ diff --git a/tests/Switzerland/Uri/AssumptionOfMaryTest.php b/tests/Switzerland/Uri/AssumptionOfMaryTest.php index d4e5a8c04..3328befff 100644 --- a/tests/Switzerland/Uri/AssumptionOfMaryTest.php +++ b/tests/Switzerland/Uri/AssumptionOfMaryTest.php @@ -73,7 +73,7 @@ public function testHolidayType(): void /** * Returns a list of random test dates used for assertion of the day of the Assumption of Mary. * - * @return array list of test dates for the day of the Assumption of Mary + * @return array list of test dates for the day of the Assumption of Mary * * @throws Exception */ diff --git a/tests/Switzerland/Uri/ChristmasDayTest.php b/tests/Switzerland/Uri/ChristmasDayTest.php index 794ef9de5..128d3814e 100644 --- a/tests/Switzerland/Uri/ChristmasDayTest.php +++ b/tests/Switzerland/Uri/ChristmasDayTest.php @@ -48,7 +48,7 @@ public function testChristmasDay(int $year, DateTime $expected): void /** * Returns a list of random test dates used for assertion of Christmas Day. * - * @return array list of test dates for Christmas Day + * @return array list of test dates for Christmas Day * * @throws Exception */ diff --git a/tests/Switzerland/Uri/EpiphanyTest.php b/tests/Switzerland/Uri/EpiphanyTest.php index 78bedef36..a3ab97aab 100644 --- a/tests/Switzerland/Uri/EpiphanyTest.php +++ b/tests/Switzerland/Uri/EpiphanyTest.php @@ -48,7 +48,7 @@ public function testHoliday(int $year, DateTime $expected): void /** * Returns a list of random test dates used for assertion of the holiday defined in this test. * - * @return array list of test dates for the day of the holiday defined in this test + * @return array list of test dates for the holiday defined in this test * * @throws Exception */ diff --git a/tests/Switzerland/Uri/ImmaculateConceptionTest.php b/tests/Switzerland/Uri/ImmaculateConceptionTest.php index 1398afc53..565cfeaca 100644 --- a/tests/Switzerland/Uri/ImmaculateConceptionTest.php +++ b/tests/Switzerland/Uri/ImmaculateConceptionTest.php @@ -48,7 +48,7 @@ public function testHoliday(int $year, DateTime $expected): void /** * Returns a list of random test dates used for assertion of the holiday defined in this test. * - * @return array list of test dates for the day of the holiday defined in this test + * @return array list of test dates for the holiday defined in this test * * @throws Exception */ diff --git a/tests/Switzerland/Uri/NewYearsDayTest.php b/tests/Switzerland/Uri/NewYearsDayTest.php index d293e754c..2c96268e6 100644 --- a/tests/Switzerland/Uri/NewYearsDayTest.php +++ b/tests/Switzerland/Uri/NewYearsDayTest.php @@ -73,7 +73,7 @@ public function testHolidayType(): void /** * Returns a list of random test dates used for assertion of New Years Day. * - * @return array list of test dates for New Years Day + * @return array list of test dates for New Years Day * * @throws Exception */ diff --git a/tests/Switzerland/Uri/StJosephDayTest.php b/tests/Switzerland/Uri/StJosephDayTest.php index 5ee262165..15527ccfd 100644 --- a/tests/Switzerland/Uri/StJosephDayTest.php +++ b/tests/Switzerland/Uri/StJosephDayTest.php @@ -51,7 +51,7 @@ public function testStJosephDay(int $year, DateTime $expected): void /** * Returns a list of random test dates used for assertion of St. Joseph's Day. * - * @return array list of test dates for St. Joseph's Day + * @return array list of test dates for St. Joseph's Day * * @throws Exception */ diff --git a/tests/Switzerland/Uri/StStephensDayTest.php b/tests/Switzerland/Uri/StStephensDayTest.php index 44d4b1d81..c24a86761 100644 --- a/tests/Switzerland/Uri/StStephensDayTest.php +++ b/tests/Switzerland/Uri/StStephensDayTest.php @@ -48,7 +48,7 @@ public function testHoliday(int $year, DateTime $expected): void /** * Returns a list of random test dates used for assertion of the holiday defined in this test. * - * @return array list of test dates for the holiday defined in this test + * @return array list of test dates for the holiday defined in this test * * @throws Exception */ diff --git a/tests/Switzerland/Valais/AllSaintsDayTest.php b/tests/Switzerland/Valais/AllSaintsDayTest.php index 0e65de541..4d4afebde 100644 --- a/tests/Switzerland/Valais/AllSaintsDayTest.php +++ b/tests/Switzerland/Valais/AllSaintsDayTest.php @@ -73,7 +73,7 @@ public function testHolidayType(): void /** * Returns a list of random test dates used for assertion of All Saints' Day. * - * @return array list of test dates for All Saints' Day + * @return array list of test dates for All Saints' Day * * @throws Exception */ diff --git a/tests/Switzerland/Valais/AssumptionOfMaryTest.php b/tests/Switzerland/Valais/AssumptionOfMaryTest.php index 15e6a4ccf..7caa0c699 100644 --- a/tests/Switzerland/Valais/AssumptionOfMaryTest.php +++ b/tests/Switzerland/Valais/AssumptionOfMaryTest.php @@ -73,7 +73,7 @@ public function testHolidayType(): void /** * Returns a list of random test dates used for assertion of the day of the Assumption of Mary. * - * @return array list of test dates for the day of the Assumption of Mary + * @return array list of test dates for the day of the Assumption of Mary * * @throws Exception */ diff --git a/tests/Switzerland/Valais/ChristmasDayTest.php b/tests/Switzerland/Valais/ChristmasDayTest.php index d21a97b4c..3f6aff06f 100644 --- a/tests/Switzerland/Valais/ChristmasDayTest.php +++ b/tests/Switzerland/Valais/ChristmasDayTest.php @@ -48,7 +48,7 @@ public function testChristmasDay(int $year, DateTime $expected): void /** * Returns a list of random test dates used for assertion of Christmas Day. * - * @return array list of test dates for Christmas Day + * @return array list of test dates for Christmas Day * * @throws Exception */ diff --git a/tests/Switzerland/Valais/ImmaculateConceptionTest.php b/tests/Switzerland/Valais/ImmaculateConceptionTest.php index cbee831b4..db7bde5d0 100644 --- a/tests/Switzerland/Valais/ImmaculateConceptionTest.php +++ b/tests/Switzerland/Valais/ImmaculateConceptionTest.php @@ -48,7 +48,7 @@ public function testHoliday(int $year, DateTime $expected): void /** * Returns a list of random test dates used for assertion of the holiday defined in this test. * - * @return array list of test dates for the day of the holiday defined in this test + * @return array list of test dates for the holiday defined in this test * * @throws Exception */ diff --git a/tests/Switzerland/Valais/NewYearsDayTest.php b/tests/Switzerland/Valais/NewYearsDayTest.php index 6e198deb5..0a6dc8dbb 100644 --- a/tests/Switzerland/Valais/NewYearsDayTest.php +++ b/tests/Switzerland/Valais/NewYearsDayTest.php @@ -73,7 +73,7 @@ public function testHolidayType(): void /** * Returns a list of random test dates used for assertion of New Years Day. * - * @return array list of test dates for New Years Day + * @return array list of test dates for New Years Day * * @throws Exception */ diff --git a/tests/Switzerland/Valais/StJosephDayTest.php b/tests/Switzerland/Valais/StJosephDayTest.php index 6d2d589d0..0df7761f6 100644 --- a/tests/Switzerland/Valais/StJosephDayTest.php +++ b/tests/Switzerland/Valais/StJosephDayTest.php @@ -51,7 +51,7 @@ public function testStJosephDay(int $year, DateTime $expected): void /** * Returns a list of random test dates used for assertion of St. Joseph's Day. * - * @return array list of test dates for St. Joseph's Day + * @return array list of test dates for St. Joseph's Day * * @throws Exception */ diff --git a/tests/Switzerland/Vaud/ChristmasDayTest.php b/tests/Switzerland/Vaud/ChristmasDayTest.php index aa41921fa..4d5a2c1de 100644 --- a/tests/Switzerland/Vaud/ChristmasDayTest.php +++ b/tests/Switzerland/Vaud/ChristmasDayTest.php @@ -48,7 +48,7 @@ public function testChristmasDay(int $year, DateTime $expected): void /** * Returns a list of random test dates used for assertion of Christmas Day. * - * @return array list of test dates for Christmas Day + * @return array list of test dates for Christmas Day * * @throws Exception */ diff --git a/tests/Switzerland/Vaud/NewYearsDayTest.php b/tests/Switzerland/Vaud/NewYearsDayTest.php index d46863bd3..859a9f2e5 100644 --- a/tests/Switzerland/Vaud/NewYearsDayTest.php +++ b/tests/Switzerland/Vaud/NewYearsDayTest.php @@ -73,7 +73,7 @@ public function testHolidayType(): void /** * Returns a list of random test dates used for assertion of New Years Day. * - * @return array list of test dates for New Years Day + * @return array list of test dates for New Years Day * * @throws Exception */ diff --git a/tests/Switzerland/Zug/AllSaintsDayTest.php b/tests/Switzerland/Zug/AllSaintsDayTest.php index 9af38a68d..09b360dba 100644 --- a/tests/Switzerland/Zug/AllSaintsDayTest.php +++ b/tests/Switzerland/Zug/AllSaintsDayTest.php @@ -73,7 +73,7 @@ public function testHolidayType(): void /** * Returns a list of random test dates used for assertion of All Saints' Day. * - * @return array list of test dates for All Saints' Day + * @return array list of test dates for All Saints' Day * * @throws Exception */ diff --git a/tests/Switzerland/Zug/AssumptionOfMaryTest.php b/tests/Switzerland/Zug/AssumptionOfMaryTest.php index e16cfbb07..debe5c3e4 100644 --- a/tests/Switzerland/Zug/AssumptionOfMaryTest.php +++ b/tests/Switzerland/Zug/AssumptionOfMaryTest.php @@ -73,7 +73,7 @@ public function testHolidayType(): void /** * Returns a list of random test dates used for assertion of the day of the Assumption of Mary. * - * @return array list of test dates for the day of the Assumption of Mary + * @return array list of test dates for the day of the Assumption of Mary * * @throws Exception */ diff --git a/tests/Switzerland/Zug/ChristmasDayTest.php b/tests/Switzerland/Zug/ChristmasDayTest.php index ea82e7b80..0ecd66210 100644 --- a/tests/Switzerland/Zug/ChristmasDayTest.php +++ b/tests/Switzerland/Zug/ChristmasDayTest.php @@ -48,7 +48,7 @@ public function testChristmasDay(int $year, DateTime $expected): void /** * Returns a list of random test dates used for assertion of Christmas Day. * - * @return array list of test dates for Christmas Day + * @return array list of test dates for Christmas Day * * @throws Exception */ diff --git a/tests/Switzerland/Zug/ImmaculateConceptionTest.php b/tests/Switzerland/Zug/ImmaculateConceptionTest.php index 33e671c0b..ac2cd7d1a 100644 --- a/tests/Switzerland/Zug/ImmaculateConceptionTest.php +++ b/tests/Switzerland/Zug/ImmaculateConceptionTest.php @@ -48,7 +48,7 @@ public function testHoliday(int $year, DateTime $expected): void /** * Returns a list of random test dates used for assertion of the holiday defined in this test. * - * @return array list of test dates for the day of the holiday defined in this test + * @return array list of test dates for the holiday defined in this test * * @throws Exception */ diff --git a/tests/Switzerland/Zug/NewYearsDayTest.php b/tests/Switzerland/Zug/NewYearsDayTest.php index 5d0083bdc..4bbefbfac 100644 --- a/tests/Switzerland/Zug/NewYearsDayTest.php +++ b/tests/Switzerland/Zug/NewYearsDayTest.php @@ -73,7 +73,7 @@ public function testHolidayType(): void /** * Returns a list of random test dates used for assertion of New Years Day. * - * @return array list of test dates for New Years Day + * @return array list of test dates for New Years Day * * @throws Exception */ diff --git a/tests/Switzerland/Zug/StStephensDayTest.php b/tests/Switzerland/Zug/StStephensDayTest.php index 425036125..2f0e0a4cd 100644 --- a/tests/Switzerland/Zug/StStephensDayTest.php +++ b/tests/Switzerland/Zug/StStephensDayTest.php @@ -48,7 +48,7 @@ public function testHoliday(int $year, DateTime $expected): void /** * Returns a list of random test dates used for assertion of the holiday defined in this test. * - * @return array list of test dates for the holiday defined in this test + * @return array list of test dates for the holiday defined in this test * * @throws Exception */ diff --git a/tests/Switzerland/Zurich/ChristmasDayTest.php b/tests/Switzerland/Zurich/ChristmasDayTest.php index 33081c3c6..6b5d8c464 100644 --- a/tests/Switzerland/Zurich/ChristmasDayTest.php +++ b/tests/Switzerland/Zurich/ChristmasDayTest.php @@ -48,7 +48,7 @@ public function testChristmasDay(int $year, DateTime $expected): void /** * Returns a list of random test dates used for assertion of Christmas Day. * - * @return array list of test dates for Christmas Day + * @return array list of test dates for Christmas Day * * @throws Exception */ diff --git a/tests/Switzerland/Zurich/NewYearsDayTest.php b/tests/Switzerland/Zurich/NewYearsDayTest.php index 9378e4840..46568c6ba 100644 --- a/tests/Switzerland/Zurich/NewYearsDayTest.php +++ b/tests/Switzerland/Zurich/NewYearsDayTest.php @@ -73,7 +73,7 @@ public function testHolidayType(): void /** * Returns a list of random test dates used for assertion of New Years Day. * - * @return array list of test dates for New Years Day + * @return array list of test dates for New Years Day * * @throws Exception */ diff --git a/tests/Switzerland/Zurich/StStephensDayTest.php b/tests/Switzerland/Zurich/StStephensDayTest.php index cd8da2b5e..426b0dd45 100644 --- a/tests/Switzerland/Zurich/StStephensDayTest.php +++ b/tests/Switzerland/Zurich/StStephensDayTest.php @@ -48,7 +48,7 @@ public function testHoliday(int $year, DateTime $expected): void /** * Returns a list of random test dates used for assertion of the holiday defined in this test. * - * @return array list of test dates for the holiday defined in this test + * @return array list of test dates for the holiday defined in this test * * @throws Exception */ diff --git a/tests/Switzerland/Zurich/WorkersDayTest.php b/tests/Switzerland/Zurich/WorkersDayTest.php index a3ff927f2..3ca643dc4 100644 --- a/tests/Switzerland/Zurich/WorkersDayTest.php +++ b/tests/Switzerland/Zurich/WorkersDayTest.php @@ -51,7 +51,7 @@ public function testHoliday(int $year, string $expected): void /** * Returns a list of random test dates used for assertion of the holiday defined in this test. * - * @return array list of test dates for the holiday defined in this test + * @return array list of test dates for the holiday defined in this test * * @throws Exception */ diff --git a/tests/Turkey/LabourDayTest.php b/tests/Turkey/LabourDayTest.php index 3657db65f..20069558b 100644 --- a/tests/Turkey/LabourDayTest.php +++ b/tests/Turkey/LabourDayTest.php @@ -64,7 +64,7 @@ public function testHolidayType(): void } /** - * @return array list of test dates for the holiday defined in this test + * @return array list of test dates for the holiday defined in this test * * @throws Exception */ diff --git a/tests/Turkey/NewYearsDayTest.php b/tests/Turkey/NewYearsDayTest.php index 3558ffbc7..5480a2757 100644 --- a/tests/Turkey/NewYearsDayTest.php +++ b/tests/Turkey/NewYearsDayTest.php @@ -38,7 +38,7 @@ public function testHoliday(int $year, DateTime $expected): void } /** - * @return array list of test dates for the holiday defined in this test + * @return array list of test dates for the holiday defined in this test * * @throws Exception */ diff --git a/tests/Ukraine/CatholicChristmasDayTest.php b/tests/Ukraine/CatholicChristmasDayTest.php index c6bf670e5..6f55216d6 100644 --- a/tests/Ukraine/CatholicChristmasDayTest.php +++ b/tests/Ukraine/CatholicChristmasDayTest.php @@ -91,7 +91,7 @@ public function testHolidayType(): void /** * Returns a list of random test dates used for assertion of Catholic Christmas Day. * - * @return array list of test dates for Catholic Christmas Day + * @return array list of test dates for Catholic Christmas Day * * @throws Exception */ diff --git a/tests/Ukraine/ChristmasDayTest.php b/tests/Ukraine/ChristmasDayTest.php index 205134053..4db0562f5 100644 --- a/tests/Ukraine/ChristmasDayTest.php +++ b/tests/Ukraine/ChristmasDayTest.php @@ -48,7 +48,7 @@ public function testChristmasDay(int $year, DateTime $expected): void /** * Returns a list of random test dates used for assertion of the holiday defined in this test. * - * @return array list of test dates for the holiday defined in this test + * @return array list of test dates for the holiday defined in this test * * @throws Exception */ diff --git a/tests/Ukraine/InternationalWomensDayTest.php b/tests/Ukraine/InternationalWomensDayTest.php index b13ff28e5..a46b46f21 100644 --- a/tests/Ukraine/InternationalWomensDayTest.php +++ b/tests/Ukraine/InternationalWomensDayTest.php @@ -43,7 +43,7 @@ public function testHoliday(int $year, DateTime $expected): void /** * Returns a list of random test dates used for assertion of the holiday defined in this test. * - * @return array list of test dates for the holiday defined in this test + * @return array list of test dates for the holiday defined in this test * * @throws Exception */ diff --git a/tests/Ukraine/InternationalWorkersDayTest.php b/tests/Ukraine/InternationalWorkersDayTest.php index 0c4b3df98..46407353d 100644 --- a/tests/Ukraine/InternationalWorkersDayTest.php +++ b/tests/Ukraine/InternationalWorkersDayTest.php @@ -73,7 +73,7 @@ public function testHolidayType(): void /** * Returns a list of random test dates used for assertion of International Workers' Day. * - * @return array list of test dates for International Workers' Day + * @return array list of test dates for International Workers' Day * * @throws Exception */ diff --git a/tests/Ukraine/NewYearsDayTest.php b/tests/Ukraine/NewYearsDayTest.php index 007c5c859..6899ec9e1 100644 --- a/tests/Ukraine/NewYearsDayTest.php +++ b/tests/Ukraine/NewYearsDayTest.php @@ -48,7 +48,7 @@ public function testHoliday(int $year, DateTime $expected): void /** * Returns a list of random test dates used for assertion of the holiday defined in this test. * - * @return array list of test dates for the holiday defined in this test + * @return array list of test dates for the holiday defined in this test * * @throws Exception */ diff --git a/tests/Ukraine/SecondInternationalWorkersDayTest.php b/tests/Ukraine/SecondInternationalWorkersDayTest.php index 9b4c4242a..55bc24cf3 100644 --- a/tests/Ukraine/SecondInternationalWorkersDayTest.php +++ b/tests/Ukraine/SecondInternationalWorkersDayTest.php @@ -95,7 +95,7 @@ public function testHolidayType(): void /** * Returns a list of random test dates used for assertion of International Workers' Day. * - * @return array list of test dates for International Workers' Day + * @return array list of test dates for International Workers' Day * * @throws \Exception */ diff --git a/tests/Ukraine/VictoryDayTest.php b/tests/Ukraine/VictoryDayTest.php index 39f599e3b..08c573511 100644 --- a/tests/Ukraine/VictoryDayTest.php +++ b/tests/Ukraine/VictoryDayTest.php @@ -43,7 +43,7 @@ public function testHoliday(int $year, DateTime $expected): void /** * Returns a list of random test dates used for assertion of the holiday defined in this test. * - * @return array list of test dates for the holiday defined in this test + * @return array list of test dates for the holiday defined in this test * * @throws Exception */ diff --git a/tests/UnitedKingdom/BoxingDayTest.php b/tests/UnitedKingdom/BoxingDayTest.php index 5b72563fe..1bb47bb2c 100644 --- a/tests/UnitedKingdom/BoxingDayTest.php +++ b/tests/UnitedKingdom/BoxingDayTest.php @@ -58,7 +58,7 @@ public function testHoliday(int $year, string $expected): void /** * Returns a list of test dates. * - * @return array list of test dates for the holiday defined in this test + * @return array list of test dates for the holiday defined in this test * * @throws Exception */ diff --git a/tests/UnitedKingdom/ChristmasDayTest.php b/tests/UnitedKingdom/ChristmasDayTest.php index c952e1bfa..3b4c3f4f8 100644 --- a/tests/UnitedKingdom/ChristmasDayTest.php +++ b/tests/UnitedKingdom/ChristmasDayTest.php @@ -58,7 +58,7 @@ public function testHoliday(int $year, string $expected): void /** * Returns a list of test dates. * - * @return array list of test dates for the holiday defined in this test + * @return array list of test dates for the holiday defined in this test * * @throws Exception */ diff --git a/tests/UnitedKingdom/EasterMondayTest.php b/tests/UnitedKingdom/EasterMondayTest.php index 55ea738db..29806a8b0 100644 --- a/tests/UnitedKingdom/EasterMondayTest.php +++ b/tests/UnitedKingdom/EasterMondayTest.php @@ -56,7 +56,7 @@ public function testHoliday(int $year, string $expected): void /** * Returns a list of test dates. * - * @return array list of test dates for the holiday defined in this test + * @return array list of test dates for the holiday defined in this test * * @throws Exception */ diff --git a/tests/UnitedKingdom/England/BoxingDayTest.php b/tests/UnitedKingdom/England/BoxingDayTest.php index 8b072c9f2..f5ac58fbf 100644 --- a/tests/UnitedKingdom/England/BoxingDayTest.php +++ b/tests/UnitedKingdom/England/BoxingDayTest.php @@ -58,7 +58,7 @@ public function testHoliday(int $year, string $expected): void /** * Returns a list of test dates. * - * @return array list of test dates for the holiday defined in this test + * @return array list of test dates for the holiday defined in this test * * @throws Exception */ diff --git a/tests/UnitedKingdom/England/ChristmasDayTest.php b/tests/UnitedKingdom/England/ChristmasDayTest.php index 44db5a5d8..1a244d78f 100644 --- a/tests/UnitedKingdom/England/ChristmasDayTest.php +++ b/tests/UnitedKingdom/England/ChristmasDayTest.php @@ -58,7 +58,7 @@ public function testHoliday(int $year, string $expected): void /** * Returns a list of test dates. * - * @return array list of test dates for the holiday defined in this test + * @return array list of test dates for the holiday defined in this test * * @throws Exception */ diff --git a/tests/UnitedKingdom/England/EasterMondayTest.php b/tests/UnitedKingdom/England/EasterMondayTest.php index d19452a3a..0bc947d45 100644 --- a/tests/UnitedKingdom/England/EasterMondayTest.php +++ b/tests/UnitedKingdom/England/EasterMondayTest.php @@ -56,7 +56,7 @@ public function testHoliday(int $year, string $expected): void /** * Returns a list of test dates. * - * @return array list of test dates for the holiday defined in this test + * @return array list of test dates for the holiday defined in this test * * @throws Exception */ diff --git a/tests/UnitedKingdom/England/NewYearsDayTest.php b/tests/UnitedKingdom/England/NewYearsDayTest.php index 2cdba56d8..8aadfd6e8 100644 --- a/tests/UnitedKingdom/England/NewYearsDayTest.php +++ b/tests/UnitedKingdom/England/NewYearsDayTest.php @@ -94,7 +94,7 @@ public function testHolidayIsObservedTypeBeforeChange(): void /** * Returns a list of random test dates used for assertion of the holiday defined in this test. * - * @return array list of test dates for the holiday defined in this test + * @return array list of test dates for the holiday defined in this test * * @throws Exception */ diff --git a/tests/UnitedKingdom/NewYearsDayTest.php b/tests/UnitedKingdom/NewYearsDayTest.php index 204c316e3..7c20b464f 100644 --- a/tests/UnitedKingdom/NewYearsDayTest.php +++ b/tests/UnitedKingdom/NewYearsDayTest.php @@ -94,7 +94,7 @@ public function testHolidayIsObservedTypeBeforeChange(): void /** * Returns a list of random test dates used for assertion of the holiday defined in this test. * - * @return array list of test dates for the holiday defined in this test + * @return array list of test dates for the holiday defined in this test * * @throws Exception */ diff --git a/tests/UnitedKingdom/NorthernIreland/BattleOfTheBoyneTest.php b/tests/UnitedKingdom/NorthernIreland/BattleOfTheBoyneTest.php index 0aa8159a1..e7afbc512 100644 --- a/tests/UnitedKingdom/NorthernIreland/BattleOfTheBoyneTest.php +++ b/tests/UnitedKingdom/NorthernIreland/BattleOfTheBoyneTest.php @@ -75,7 +75,7 @@ public function testHolidayBeforeEstablishment(): void /** * Returns a list of random test dates used for assertion of the holiday defined in this test. * - * @return array list of test dates for the holiday defined in this test + * @return array list of test dates for the holiday defined in this test * * @throws Exception */ diff --git a/tests/UnitedKingdom/NorthernIreland/BoxingDayTest.php b/tests/UnitedKingdom/NorthernIreland/BoxingDayTest.php index 45890c1bc..61b11a906 100644 --- a/tests/UnitedKingdom/NorthernIreland/BoxingDayTest.php +++ b/tests/UnitedKingdom/NorthernIreland/BoxingDayTest.php @@ -58,7 +58,7 @@ public function testHoliday(int $year, string $expected): void /** * Returns a list of test dates. * - * @return array list of test dates for the holiday defined in this test + * @return array list of test dates for the holiday defined in this test * * @throws Exception */ diff --git a/tests/UnitedKingdom/NorthernIreland/ChristmasDayTest.php b/tests/UnitedKingdom/NorthernIreland/ChristmasDayTest.php index 12ce2faae..a95578df8 100644 --- a/tests/UnitedKingdom/NorthernIreland/ChristmasDayTest.php +++ b/tests/UnitedKingdom/NorthernIreland/ChristmasDayTest.php @@ -58,7 +58,7 @@ public function testHoliday(int $year, string $expected): void /** * Returns a list of test dates. * - * @return array list of test dates for the holiday defined in this test + * @return array list of test dates for the holiday defined in this test * * @throws Exception */ diff --git a/tests/UnitedKingdom/NorthernIreland/EasterMondayTest.php b/tests/UnitedKingdom/NorthernIreland/EasterMondayTest.php index 30805ff8d..ea65fae74 100644 --- a/tests/UnitedKingdom/NorthernIreland/EasterMondayTest.php +++ b/tests/UnitedKingdom/NorthernIreland/EasterMondayTest.php @@ -56,7 +56,7 @@ public function testHoliday(int $year, string $expected): void /** * Returns a list of test dates. * - * @return array list of test dates for the holiday defined in this test + * @return array list of test dates for the holiday defined in this test * * @throws Exception */ diff --git a/tests/UnitedKingdom/NorthernIreland/NewYearsDayTest.php b/tests/UnitedKingdom/NorthernIreland/NewYearsDayTest.php index f3bb05962..54d318d15 100644 --- a/tests/UnitedKingdom/NorthernIreland/NewYearsDayTest.php +++ b/tests/UnitedKingdom/NorthernIreland/NewYearsDayTest.php @@ -94,7 +94,7 @@ public function testHolidayIsObservedTypeBeforeChange(): void /** * Returns a list of random test dates used for assertion of the holiday defined in this test. * - * @return array list of test dates for the holiday defined in this test + * @return array list of test dates for the holiday defined in this test * * @throws Exception */ diff --git a/tests/UnitedKingdom/NorthernIreland/StPatricksDayTest.php b/tests/UnitedKingdom/NorthernIreland/StPatricksDayTest.php index df0ca5a3d..85430e391 100644 --- a/tests/UnitedKingdom/NorthernIreland/StPatricksDayTest.php +++ b/tests/UnitedKingdom/NorthernIreland/StPatricksDayTest.php @@ -75,7 +75,7 @@ public function testHolidayBeforeEstablishment(): void /** * Returns a list of random test dates used for assertion of the holiday defined in this test. * - * @return array list of test dates for the holiday defined in this test + * @return array list of test dates for the holiday defined in this test * * @throws Exception */ diff --git a/tests/UnitedKingdom/Scotland/BoxingDayTest.php b/tests/UnitedKingdom/Scotland/BoxingDayTest.php index 466be0f67..37e14d9f5 100644 --- a/tests/UnitedKingdom/Scotland/BoxingDayTest.php +++ b/tests/UnitedKingdom/Scotland/BoxingDayTest.php @@ -58,7 +58,7 @@ public function testHoliday(int $year, string $expected): void /** * Returns a list of test dates. * - * @return array list of test dates for the holiday defined in this test + * @return array list of test dates for the holiday defined in this test * * @throws Exception */ diff --git a/tests/UnitedKingdom/Scotland/ChristmasDayTest.php b/tests/UnitedKingdom/Scotland/ChristmasDayTest.php index 1aa746349..c00ae6d06 100644 --- a/tests/UnitedKingdom/Scotland/ChristmasDayTest.php +++ b/tests/UnitedKingdom/Scotland/ChristmasDayTest.php @@ -58,7 +58,7 @@ public function testHoliday(int $year, string $expected): void /** * Returns a list of test dates. * - * @return array list of test dates for the holiday defined in this test + * @return array list of test dates for the holiday defined in this test * * @throws Exception */ diff --git a/tests/UnitedKingdom/Scotland/NewYearsDayTest.php b/tests/UnitedKingdom/Scotland/NewYearsDayTest.php index f7e5da741..08913d82a 100644 --- a/tests/UnitedKingdom/Scotland/NewYearsDayTest.php +++ b/tests/UnitedKingdom/Scotland/NewYearsDayTest.php @@ -96,7 +96,7 @@ public function testHolidayIsObservedTypeBeforeChange(): void /** * Returns a list of random test dates used for assertion of the holiday defined in this test. * - * @return array list of test dates for the holiday defined in this test + * @return array list of test dates for the holiday defined in this test * * @throws Exception */ diff --git a/tests/UnitedKingdom/Scotland/SecondNewYearsDayTest.php b/tests/UnitedKingdom/Scotland/SecondNewYearsDayTest.php index a6a01db64..a4492d69c 100644 --- a/tests/UnitedKingdom/Scotland/SecondNewYearsDayTest.php +++ b/tests/UnitedKingdom/Scotland/SecondNewYearsDayTest.php @@ -96,7 +96,7 @@ public function testHolidayIsObservedTypeBeforeChange(): void /** * Returns a list of random test dates used for assertion of the holiday defined in this test. * - * @return array list of test dates for the holiday defined in this test + * @return array list of test dates for the holiday defined in this test * * @throws Exception */ diff --git a/tests/UnitedKingdom/Scotland/StAndrewsDayTest.php b/tests/UnitedKingdom/Scotland/StAndrewsDayTest.php index 9c2e92e3d..a2b39a341 100644 --- a/tests/UnitedKingdom/Scotland/StAndrewsDayTest.php +++ b/tests/UnitedKingdom/Scotland/StAndrewsDayTest.php @@ -61,7 +61,7 @@ public function testHoliday(int $year, string $expected): void /** * Returns a list of random test dates used for assertion of the holiday defined in this test. * - * @return array list of test dates for the holiday defined in this test + * @return array list of test dates for the holiday defined in this test * * @throws Exception */ diff --git a/tests/UnitedKingdom/Wales/BoxingDayTest.php b/tests/UnitedKingdom/Wales/BoxingDayTest.php index 37c9cb595..dcd153923 100644 --- a/tests/UnitedKingdom/Wales/BoxingDayTest.php +++ b/tests/UnitedKingdom/Wales/BoxingDayTest.php @@ -58,7 +58,7 @@ public function testHoliday(int $year, string $expected): void /** * Returns a list of test dates. * - * @return array list of test dates for the holiday defined in this test + * @return array list of test dates for the holiday defined in this test * * @throws Exception */ diff --git a/tests/UnitedKingdom/Wales/ChristmasDayTest.php b/tests/UnitedKingdom/Wales/ChristmasDayTest.php index a3c48d62c..2fb282aef 100644 --- a/tests/UnitedKingdom/Wales/ChristmasDayTest.php +++ b/tests/UnitedKingdom/Wales/ChristmasDayTest.php @@ -58,7 +58,7 @@ public function testHoliday(int $year, string $expected): void /** * Returns a list of test dates. * - * @return array list of test dates for the holiday defined in this test + * @return array list of test dates for the holiday defined in this test * * @throws Exception */ diff --git a/tests/UnitedKingdom/Wales/EasterMondayTest.php b/tests/UnitedKingdom/Wales/EasterMondayTest.php index 90619720a..8e07b0d95 100644 --- a/tests/UnitedKingdom/Wales/EasterMondayTest.php +++ b/tests/UnitedKingdom/Wales/EasterMondayTest.php @@ -56,7 +56,7 @@ public function testHoliday(int $year, string $expected): void /** * Returns a list of test dates. * - * @return array list of test dates for the holiday defined in this test + * @return array list of test dates for the holiday defined in this test * * @throws Exception */ diff --git a/tests/UnitedKingdom/Wales/NewYearsDayTest.php b/tests/UnitedKingdom/Wales/NewYearsDayTest.php index b35bfe2a1..77d673e3f 100644 --- a/tests/UnitedKingdom/Wales/NewYearsDayTest.php +++ b/tests/UnitedKingdom/Wales/NewYearsDayTest.php @@ -94,7 +94,7 @@ public function testHolidayIsObservedTypeBeforeChange(): void /** * Returns a list of random test dates used for assertion of the holiday defined in this test. * - * @return array list of test dates for the holiday defined in this test + * @return array list of test dates for the holiday defined in this test * * @throws Exception */ diff --git a/tests/YasumiBase.php b/tests/YasumiBase.php index c1f756842..8ade5c6e2 100644 --- a/tests/YasumiBase.php +++ b/tests/YasumiBase.php @@ -41,17 +41,17 @@ */ trait YasumiBase { - protected static $defaultTimezone; + protected static string $defaultTimezone; /** * Asserts that the expected holidays are indeed a holiday for the given provider and year. * - * @param array $expectedHolidays list of all known holidays of the given provider - * @param string $provider the holiday provider (i.e. country/state) for which the holidays need to be - * tested - * @param int $year holiday calendar year - * @param string $type The type of holiday. Use the following constants: TYPE_OFFICIAL, - * TYPE_OBSERVANCE, TYPE_SEASON, TYPE_BANK or TYPE_OTHER. + * @param array $expectedHolidays list of all known holidays of the given provider + * @param string $provider the holiday provider (i.e. country/state) for which the holidays need to be + * tested + * @param int $year holiday calendar year + * @param string $type The type of holiday. Use the following constants: TYPE_OFFICIAL, + * TYPE_OBSERVANCE, TYPE_SEASON, TYPE_BANK or TYPE_OTHER. * * @throws InvalidArgumentException * @throws RuntimeException @@ -202,10 +202,10 @@ public function assertNotHoliday( /** * Asserts that the expected name is indeed provided as a translated holiday name for that given year and name. * - * @param string $provider the holiday provider (i.e. country/state) for which the holiday need to be tested - * @param string $key string the key of the holiday to be checked against - * @param int $year holiday calendar year - * @param array $translations the translations to be checked against + * @param string $provider the holiday provider (i.e. country/state) for which the holiday need to be tested + * @param string $key string the key of the holiday to be checked against + * @param int $year holiday calendar year + * @param array $translations the translations to be checked against * * @throws InvalidArgumentException * @throws RuntimeException @@ -328,7 +328,7 @@ public function assertSources(string $provider, int $expectedSourceCount): void * @param int|null $iterations number of iterations (i.e. samples) that need to be generated (default: 10) * @param int|null $range year range from which dates will be generated (default: 1000) * - * @return array list of random test dates used for assertion of holidays + * @return array list of random test dates used for assertion of holidays * * @throws Exception */ @@ -356,7 +356,7 @@ public function generateRandomDates( * @param int|null $iterations number of iterations (i.e. samples) that need to be generated (default: 10) * @param int|null $range year range from which dates will be generated (default: 1000) * - * @return array list of random easter test dates used for assertion of holidays + * @return array list of random easter test dates used for assertion of holidays * * @throws Exception */ @@ -385,7 +385,7 @@ public function generateRandomEasterDates( * @param int|null $iterations number of iterations (i.e. samples) that need to be generated (default: 10) * @param int|null $range year range from which dates will be generated (default: 1000) * - * @return array list of random Easter Monday test dates used for assertion of holidays + * @return array list of random Easter Monday test dates used for assertion of holidays * * @throws Exception */ @@ -409,7 +409,7 @@ public function generateRandomEasterMondayDates( * @param int|null $iterations number of iterations (i.e. samples) that need to be generated (default: 10) * @param int|null $range year range from which dates will be generated (default: 1000) * - * @return array list of random modified Easter day test dates for assertion of holidays + * @return array list of random modified Easter day test dates for assertion of holidays * * @throws Exception */ @@ -440,7 +440,7 @@ public function generateRandomModifiedEasterDates( * @param int|null $iterations number of iterations (i.e. samples) that need to be generated (default: 10) * @param int|null $range year range from which dates will be generated (default: 1000) * - * @return array list of random Good Friday test dates used for assertion of holidays + * @return array list of random Good Friday test dates used for assertion of holidays * * @throws Exception */ @@ -463,7 +463,7 @@ public function generateRandomGoodFridayDates( * @param int|null $iterations number of iterations (i.e. samples) that need to be generated (default: 10) * @param int|null $range year range from which dates will be generated (default: 1000) * - * @return array list of random Pentecost test dates used for assertion of holidays + * @return array list of random Pentecost test dates used for assertion of holidays * * @throws Exception */ @@ -489,7 +489,7 @@ public function generateRandomPentecostDates( * @param int|null $iterations number of iterations (i.e. samples) that need to be generated (default: 10) * @param int|null $range year range from which dates will be generated (default: 1000) * - * @return array list of random test dates used for assertion of holidays + * @return array list of random test dates used for assertion of holidays * * @throws Exception */ @@ -517,7 +517,7 @@ public function generateRandomDatesWithHolidayMovedToMonday( * @param int $range year range from which dates will be generated (default: 1000) * @param string|null $timezone name of the timezone for which the dates need to be generated * - * @return array list of random test dates used for assertion of holidays with applied callback + * @return array list of random test dates used for assertion of holidays with applied callback * * @throws Exception */ @@ -562,7 +562,7 @@ public function generateRandomYear( * Checks if given $dateTime is a weekend. * * @param DateTimeInterface $dateTime date for which weekend will be checked - * @param array $weekendDays weekend days. Saturday and Sunday are used by default. + * @param array $weekendDays weekend days. Saturday and Sunday are used by default. * * @return bool true if $dateTime is a weekend, false otherwise */ @@ -724,7 +724,7 @@ private static function setTimezone(DateTime $dt, ?string $timezone): DateTime return $dt->setTimezone(new \DateTimeZone(static::resolveTimezone($timezone))); } - private static function resolveTimezone(?string $timezone): ?string + private static function resolveTimezone(?string $timezone): string { return $timezone ?? (static::$defaultTimezone ?? date_default_timezone_get()); } From 0418a3355392dce885db03223d70b9b3b042c0a5 Mon Sep 17 00:00:00 2001 From: Sacha Telgenhof Date: Thu, 3 Feb 2022 00:54:29 +0900 Subject: [PATCH 003/142] Created interface methods that were not defined. --- src/Yasumi/Provider/AbstractProvider.php | 154 ++------------------- src/Yasumi/ProviderInterface.php | 169 +++++++++++++++++++++++ 2 files changed, 184 insertions(+), 139 deletions(-) diff --git a/src/Yasumi/Provider/AbstractProvider.php b/src/Yasumi/Provider/AbstractProvider.php index 2f7c01870..28f81e853 100755 --- a/src/Yasumi/Provider/AbstractProvider.php +++ b/src/Yasumi/Provider/AbstractProvider.php @@ -18,7 +18,6 @@ use Countable; use InvalidArgumentException; use IteratorAggregate; -use Yasumi\Exception\InvalidDateException; use Yasumi\Exception\UnknownLocaleException; use Yasumi\Filters\BetweenFilter; use Yasumi\Filters\OnFilter; @@ -115,12 +114,7 @@ public function __construct( $this->initialize(); } - /** - * Adds a holiday to the holidays providers (i.e. country/state) list of holidays. - * - * @param Holiday $holiday holiday instance (representing a holiday) to be added to the internal list - * of holidays of this country - */ + /** {@inheritdoc} */ public function addHoliday(Holiday $holiday): void { if ($this->globalTranslations instanceof TranslationsInterface) { @@ -131,14 +125,7 @@ public function addHoliday(Holiday $holiday): void uasort($this->holidays, fn (\DateTimeInterface $dateA, \DateTimeInterface $dateB): int => $this::compareDates($dateA, $dateB)); } - /** - * Removes a holiday from the holidays providers (i.e. country/state) list of holidays. - * - * This function can be helpful in cases where an existing holiday provider class can be extended but some holidays - * are not part of the original (extended) provider. - * - * @param string $key holiday key - */ + /** {@inheritdoc} */ public function removeHoliday(string $key): void { unset($this->holidays[$key]); @@ -150,32 +137,14 @@ public function isWorkingDay(\DateTimeInterface $date): bool return !$this->isHoliday($date) && !$this->isWeekendDay($date); } - /** - * Determines whether a date represents a holiday or not. - * - * @param \DateTimeInterface $date any date object that implements the DateTimeInterface (e.g. Yasumi\Holiday, - * \DateTime) - * - * @return bool true if date represents a holiday, otherwise false - * - * @throws InvalidDateException - */ + /** {@inheritdoc} */ public function isHoliday(\DateTimeInterface $date): bool { // Check if given date is a holiday or not return \in_array($date->format('Y-m-d'), $this->getHolidayDates(), true); } - /** - * Determines whether a date represents a weekend day or not. - * - * @param \DateTimeInterface $date any date object that implements the DateTimeInterface (e.g. Yasumi\Holiday, - * \DateTime) - * - * @return bool true if date represents a weekend day, otherwise false - * - * @throws InvalidDateException - */ + /** {@inheritdoc} */ public function isWeekendDay(\DateTimeInterface $date): bool { // If no data is defined for this Holiday Provider, the function falls back to the global weekend definition. @@ -186,15 +155,7 @@ public function isWeekendDay(\DateTimeInterface $date): bool ); } - /** - * On what date is the given holiday? - * - * @param string $key holiday key - * - * @return string the date of the requested holiday - * - * @throws InvalidArgumentException when the given name is blank or empty - */ + /** {@inheritdoc} */ public function whenIs(string $key): string { $this->isHolidayKeyNotEmpty($key); // Validate if key is not empty @@ -202,18 +163,7 @@ public function whenIs(string $key): string return (string) $this->holidays[$key]; } - /** - * On what day of the week is the given holiday? - * - * This function returns the index number for the day of the week on which the given holiday falls. - * The index number is an integer starting with 0 being Sunday, 1 = Monday, etc. - * - * @param string $key key of the holiday - * - * @return int the index of the weekdays of the requested holiday (0 = Sunday, 1 = Monday, etc.) - * - * @throws InvalidArgumentException when the given name is blank or empty - */ + /** {@inheritdoc} */ public function whatWeekDayIs(string $key): int { $this->isHolidayKeyNotEmpty($key); // Validate if key is not empty @@ -221,12 +171,7 @@ public function whatWeekDayIs(string $key): int return (int) $this->holidays[$key]->format('w'); } - /** - * Returns the number of defined holidays (for the given country and the given year). - * In case a holiday is substituted (e.g. observed), the holiday is only counted once. - * - * @return int number of holidays - */ + /** {@inheritdoc} */ public function count(): int { $names = array_map(static function ($holiday): string { @@ -240,21 +185,13 @@ public function count(): int return \count(array_unique($names)); } - /** - * Gets all the holidays defined by this holiday provider (for the given year). - * - * @return Holiday[] list of all holidays defined for the given year - */ + /** {@inheritdoc} */ public function getHolidays(): array { return $this->holidays; } - /** - * Gets all the holiday names defined by this holiday provider (for the given year). - * - * @return array list of all holiday names defined for the given year - */ + /** {@inheritdoc} */ public function getHolidayNames(): array { return array_keys($this->holidays); @@ -266,19 +203,7 @@ public function getYear(): int return $this->year; } - /** - * Retrieves the next date (year) the given holiday is going to take place. - * - * @param string $key key of the holiday for which the next occurrence need to be retrieved - * - * @return Holiday|null a Holiday instance for the given holiday - * - * @throws UnknownLocaleException - * @throws \RuntimeException - * @throws InvalidArgumentException - * - * @covers AbstractProvider::anotherTime - */ + /** {@inheritdoc} */ public function next(string $key): ?Holiday { return $this->anotherTime($this->year + 1, $key); @@ -294,44 +219,13 @@ public function getHoliday(string $key): ?Holiday return $holidays[$key] ?? null; } - /** - * Retrieves the previous date (year) the given holiday took place. - * - * @param string $key key of the holiday for which the previous occurrence need to be retrieved - * - * @return Holiday|null a Holiday instance for the given holiday - * - * @throws UnknownLocaleException - * @throws \RuntimeException - * @throws InvalidArgumentException - * - * @covers AbstractProvider::anotherTime - */ + /** {@inheritdoc} */ public function previous(string $key): ?Holiday { return $this->anotherTime($this->year - 1, $key); } - /** - * Retrieves a list of all holidays between the given start and end date. - * - * Yasumi only calculates holidays for a single year, so a start date or end date beyond the given year will only - * return holidays for the given year. For example, holidays calculated for the year 2016, will only return 2016 - * holidays if the provided period is for example 01/01/2012 - 31/12/2017. - * - * Please take care to use the appropriate timezone for the start and end date parameters. In case you use - * different - * timezone for these parameters versus the instantiated Holiday Provider, the outcome might be unexpected (but - * correct). - * - * @param \DateTimeInterface $startDate Start date of the time frame to check against - * @param \DateTimeInterface $endDate End date of the time frame to check against - * @param ?bool $equals indicate whether the start and end dates should be included in the - * comparison - * - * @throws InvalidArgumentException an InvalidArgumentException is thrown if the start date is set after the end - * date - */ + /** {@inheritdoc} */ public function between( \DateTimeInterface $startDate, \DateTimeInterface $endDate, @@ -344,37 +238,19 @@ public function between( return new BetweenFilter($this->getIterator(), $startDate, $endDate, $equals ?? true); } - /** - * Get an iterator for the holidays. - * - * @return ArrayIterator iterator for the holidays of this calendar - */ + /** {@inheritdoc} */ public function getIterator(): ArrayIterator { return new ArrayIterator($this->getHolidays()); } - /** - * Retrieves a list of all holidays that happen on the given date. - * - * Yasumi only calculates holidays for a single year, so a date outside the given year will not appear to - * contain any holidays. - * - * Please take care to use the appropriate timezone for the date parameters. If there is a different timezone used - * for these parameters versus the instantiated Holiday Provider, the outcome might be unexpected (but correct). - * - * @param \DateTimeInterface $date date to check for holidays on - */ + /** {@inheritdoc} */ public function on(\DateTimeInterface $date): OnFilter { return new OnFilter($this->getIterator(), $date); } - /** - * Gets all the holiday dates defined by this holiday provider (for the given year). - * - * @return array list of all holiday dates defined for the given year - */ + /** {@inheritdoc} */ public function getHolidayDates(): array { return array_map(static fn ($holiday): string => (string) $holiday, $this->holidays); diff --git a/src/Yasumi/ProviderInterface.php b/src/Yasumi/ProviderInterface.php index 83ae7f7a9..1734f08a0 100755 --- a/src/Yasumi/ProviderInterface.php +++ b/src/Yasumi/ProviderInterface.php @@ -14,7 +14,11 @@ namespace Yasumi; +use ArrayIterator; use Yasumi\Exception\InvalidDateException; +use Yasumi\Exception\UnknownLocaleException; +use Yasumi\Filters\BetweenFilter; +use Yasumi\Filters\OnFilter; /** * Interface ProviderInterface - Holiday provider interface. @@ -77,4 +81,169 @@ public function getHoliday(string $key): ?Holiday; * @return Holiday[] list of all holidays defined for the given year */ public function getHolidays(): array; + + /** + * Determines whether a date represents a holiday or not. + * + * @param \DateTimeInterface $date any date object that implements the DateTimeInterface (e.g. Yasumi\Holiday, + * \DateTime) + * + * @return bool true if date represents a holiday, otherwise false + * + * @throws InvalidDateException + */ + public function isHoliday(\DateTimeInterface $date): bool; + + /** + * Get an iterator for the holidays. + * + * @return ArrayIterator iterator for the holidays of this calendar + */ + public function getIterator(): ArrayIterator; + + /** + * Adds a holiday to the holidays providers (i.e. country/state) list of holidays. + * + * @param Holiday $holiday holiday instance (representing a holiday) to be added to the internal list + * of holidays of this country + */ + public function addHoliday(Holiday $holiday): void; + + /** + * Removes a holiday from the holidays providers (i.e. country/state) list of holidays. + * + * This function can be helpful in cases where an existing holiday provider class can be extended but some holidays + * are not part of the original (extended) provider. + * + * @param string $key holiday key + */ + public function removeHoliday(string $key): void; + + /** + * Determines whether a date represents a weekend day or not. + * + * @param \DateTimeInterface $date any date object that implements the DateTimeInterface (e.g. Yasumi\Holiday, + * \DateTime) + * + * @return bool true if date represents a weekend day, otherwise false + * + * @throws InvalidDateException + */ + public function isWeekendDay(\DateTimeInterface $date): bool; + + /** + * On what date is the given holiday? + * + * @param string $key holiday key + * + * @return string the date of the requested holiday + * + * @throws \InvalidArgumentException when the given name is blank or empty + */ + public function whenIs(string $key): string; + + /** + * On what day of the week is the given holiday? + * + * This function returns the index number for the day of the week on which the given holiday falls. + * The index number is an integer starting with 0 being Sunday, 1 = Monday, etc. + * + * @param string $key key of the holiday + * + * @return int the index of the weekdays of the requested holiday (0 = Sunday, 1 = Monday, etc.) + * + * @throws \InvalidArgumentException when the given name is blank or empty + */ + public function whatWeekDayIs(string $key): int; + + /** + * Returns the number of defined holidays (for the given country and the given year). + * In case a holiday is substituted (e.g. observed), the holiday is only counted once. + * + * @return int number of holidays + */ + public function count(): int; + + /** + * Gets all the holiday names defined by this holiday provider (for the given year). + * + * @return array list of all holiday names defined for the given year + */ + public function getHolidayNames(): array; + + /** + * Retrieves the next date (year) the given holiday is going to take place. + * + * @param string $key key of the holiday for which the next occurrence need to be retrieved + * + * @return Holiday|null a Holiday instance for the given holiday + * + * @throws UnknownLocaleException + * @throws \RuntimeException + * @throws \InvalidArgumentException + * + * @covers AbstractProvider::anotherTime + */ + public function next(string $key): ?Holiday; + + /** + * Retrieves the previous date (year) the given holiday took place. + * + * @param string $key key of the holiday for which the previous occurrence need to be retrieved + * + * @return Holiday|null a Holiday instance for the given holiday + * + * @throws UnknownLocaleException + * @throws \RuntimeException + * @throws \InvalidArgumentException + * + * @covers AbstractProvider::anotherTime + */ + public function previous(string $key): ?Holiday; + + /** + * Retrieves a list of all holidays between the given start and end date. + * + * Yasumi only calculates holidays for a single year, so a start date or end date beyond the given year will only + * return holidays for the given year. For example, holidays calculated for the year 2016, will only return 2016 + * holidays if the provided period is for example 01/01/2012 - 31/12/2017. + * + * Please take care to use the appropriate timezone for the start and end date parameters. In case you use + * different + * timezone for these parameters versus the instantiated Holiday Provider, the outcome might be unexpected (but + * correct). + * + * @param \DateTimeInterface $startDate Start date of the time frame to check against + * @param \DateTimeInterface $endDate End date of the time frame to check against + * @param ?bool $equals indicate whether the start and end dates should be included in the + * comparison + * + * @throws \InvalidArgumentException an InvalidArgumentException is thrown if the start date is set after the end + * date + */ + public function between( + \DateTimeInterface $startDate, + \DateTimeInterface $endDate, + ?bool $equals = null + ): BetweenFilter; + + /** + * Retrieves a list of all holidays that happen on the given date. + * + * Yasumi only calculates holidays for a single year, so a date outside the given year will not appear to + * contain any holidays. + * + * Please take care to use the appropriate timezone for the date parameters. If there is a different timezone used + * for these parameters versus the instantiated Holiday Provider, the outcome might be unexpected (but correct). + * + * @param \DateTimeInterface $date date to check for holidays on + */ + public function on(\DateTimeInterface $date): OnFilter; + + /** + * Gets all the holiday dates defined by this holiday provider (for the given year). + * + * @return array list of all holiday dates defined for the given year + */ + public function getHolidayDates(): array; } From ea7228810b12cab61c72a11b3d78313b88a07436 Mon Sep 17 00:00:00 2001 From: Sacha Telgenhof Date: Thu, 3 Feb 2022 01:20:19 +0900 Subject: [PATCH 004/142] Removed superfluous comments/notes. --- src/Yasumi/ProviderInterface.php | 2 +- tests/Base/HolidayBetweenFilterTest.php | 59 ++---------- tests/Base/HolidayFiltersTest.php | 31 ------- tests/Base/HolidayOnFilterTest.php | 23 +---- tests/Base/HolidayTest.php | 73 +++------------ tests/Base/SubstituteHolidayTest.php | 60 ++----------- tests/Base/TranslationsTest.php | 35 -------- tests/Base/YasumiExternalProvider.php | 8 -- tests/Base/YasumiTest.php | 114 ------------------------ tests/Base/YasumiWorkdayTest.php | 11 --- 10 files changed, 31 insertions(+), 385 deletions(-) diff --git a/src/Yasumi/ProviderInterface.php b/src/Yasumi/ProviderInterface.php index 1734f08a0..483806355 100755 --- a/src/Yasumi/ProviderInterface.php +++ b/src/Yasumi/ProviderInterface.php @@ -27,7 +27,7 @@ * * @see AbstractProvider */ -interface ProviderInterface +interface ProviderInterface extends \Countable { /** * Initialize country holidays. diff --git a/tests/Base/HolidayBetweenFilterTest.php b/tests/Base/HolidayBetweenFilterTest.php index b8f91f1be..e3f0efd8d 100644 --- a/tests/Base/HolidayBetweenFilterTest.php +++ b/tests/Base/HolidayBetweenFilterTest.php @@ -20,25 +20,14 @@ use Exception; use InvalidArgumentException; use PHPUnit\Framework\TestCase; -use ReflectionException; use Yasumi\tests\YasumiBase; use Yasumi\Yasumi; -/** - * Class HolidayBetweenFilterTest. - * - * Contains tests for testing the BetweenFilter class - */ class HolidayBetweenFilterTest extends TestCase { use YasumiBase; - /** - * Tests the basic usage of the BetweenFilter. - * - * @throws Exception - * @throws ReflectionException - */ + /** @throws Exception */ public function testHolidaysBetweenDateRange(): void { $timezone = 'Europe/Amsterdam'; @@ -88,12 +77,7 @@ public function testHolidaysBetweenDateRange(): void self::assertNotEquals(\count($holidays), $between->count()); } - /** - * Tests the basic usage of the BetweenFilter using DateTimeImmutable objects. - * - * @throws Exception - * @throws ReflectionException - */ + /** @throws Exception */ public function testHolidaysBetweenDateRangeWithDateTimeImmutable(): void { $timezone = 'Europe/Amsterdam'; @@ -143,12 +127,7 @@ public function testHolidaysBetweenDateRangeWithDateTimeImmutable(): void self::assertNotEquals(\count($holidays), $between->count()); } - /** - * Tests that BetweenFilter considers the date and ignores timezones and time of day. - * - * @throws Exception - * @throws ReflectionException - */ + /** @throws Exception */ public function testHolidaysBetweenDateRangeDifferentTimezone(): void { $holidays = Yasumi::create('Netherlands', 2016); @@ -170,12 +149,7 @@ public function testHolidaysBetweenDateRangeDifferentTimezone(): void } } - /** - * Tests the BetweenFilter with date range where start and end date are exclusive of the comparison. - * - * @throws Exception - * @throws ReflectionException - */ + /** @throws Exception */ public function testHolidaysBetweenDateRangeExclusiveStartEndDate(): void { $timezone = 'Europe/Amsterdam'; @@ -226,12 +200,7 @@ public function testHolidaysBetweenDateRangeExclusiveStartEndDate(): void self::assertNotEquals(\count($holidays), $between->count()); } - /** - * Tests the BetweenFilter where the start date lies before the year of the Holiday Provider instance. - * - * @throws Exception - * @throws ReflectionException - */ + /** @throws Exception */ public function testHolidaysBetweenDateRangeWithStartBeforeInstanceYear(): void { $year = 2015; @@ -266,12 +235,7 @@ public function testHolidaysBetweenDateRangeWithStartBeforeInstanceYear(): void self::assertNotEquals(\count($holidays), $between->count()); } - /** - * Tests the BetweenFilter where the end date lies beyond the year of the Holiday Provider instance. - * - * @throws Exception - * @throws ReflectionException - */ + /** @throws Exception */ public function testHolidaysBetweenDateRangeWithEndAfterInstanceYear(): void { $year = 2000; @@ -306,12 +270,7 @@ public function testHolidaysBetweenDateRangeWithEndAfterInstanceYear(): void self::assertNotEquals(\count($holidays), $between->count()); } - /** - * Tests that an InvalidArgumentException is thrown in case an invalid holiday provider is given. - * - * @throws Exception - * @throws ReflectionException - */ + /** @throws Exception */ public function testWrongDates(): void { $this->expectException(InvalidArgumentException::class); @@ -332,7 +291,6 @@ public function testWrongDates(): void * This test covers the scenario that the requested date range covers all know holidays. * * @throws Exception - * @throws ReflectionException */ public function testCountBetweenWithSubstitutes(): void { @@ -373,7 +331,6 @@ public function testCountBetweenWithSubstitutes(): void * This test covers the scenario that the requested date range excludes a substituted holiday. * * @throws Exception - * @throws ReflectionException */ public function testCountBetweenExcludingSubstituteHoliday(): void { @@ -418,7 +375,6 @@ public function testCountBetweenExcludingSubstituteHoliday(): void * the original substituted holiday. * * @throws Exception - * @throws ReflectionException */ public function testCountBetweenExcludingSubstituteHolidayIncludingOriginalHoliday(): void { @@ -464,7 +420,6 @@ public function testCountBetweenExcludingSubstituteHolidayIncludingOriginalHolid * the original substituted holiday. * * @throws Exception - * @throws ReflectionException */ public function testCountBetweenExcludingSubstituteHolidayAndOriginalHoliday(): void { diff --git a/tests/Base/HolidayFiltersTest.php b/tests/Base/HolidayFiltersTest.php index b2b41797e..07c1d7042 100644 --- a/tests/Base/HolidayFiltersTest.php +++ b/tests/Base/HolidayFiltersTest.php @@ -15,7 +15,6 @@ namespace Yasumi\tests\Base; use PHPUnit\Framework\TestCase; -use ReflectionException; use Yasumi\Filters\BankHolidaysFilter; use Yasumi\Filters\ObservedHolidaysFilter; use Yasumi\Filters\OfficialHolidaysFilter; @@ -24,20 +23,10 @@ use Yasumi\tests\YasumiBase; use Yasumi\Yasumi; -/** - * Class HolidayFiltersTest. - * - * Contains tests for testing the filter classes - */ class HolidayFiltersTest extends TestCase { use YasumiBase; - /** - * Tests the Official Holidays filter. - * - * @throws ReflectionException - */ public function testOfficialHolidaysFilter(): void { // There are 11 official holidays in Ireland in the year 2018, with 1 substituted holiday. @@ -68,11 +57,6 @@ public function testOfficialHolidaysFilter(): void self::assertNotEquals(\count($holidays), $filteredHolidays->count()); } - /** - * Tests the Observed Holidays filter. - * - * @throws ReflectionException - */ public function testObservedHolidaysFilter(): void { // There are 2 observed holidays in Ireland in the year 2018. @@ -103,11 +87,6 @@ public function testObservedHolidaysFilter(): void self::assertNotEquals(\count($holidays), $filteredHolidays->count()); } - /** - * Tests Bank Holidays. - * - * @throws ReflectionException - */ public function testBankHolidaysFilter(): void { // There are no bank holidays in Ireland in the year 2018. @@ -138,11 +117,6 @@ public function testBankHolidaysFilter(): void self::assertNotEquals(\count($holidays), $filteredHolidays->count()); } - /** - * Tests Seasonal Holidays. - * - * @throws ReflectionException - */ public function testSeasonalHolidaysFilter(): void { $holidays = Yasumi::create('Netherlands', 2017); @@ -187,11 +161,6 @@ public function testSeasonalHolidaysFilter(): void self::assertNotEquals(\count($holidays), $filteredHolidays->count()); } - /** - * Tests other type of Holidays. - * - * @throws ReflectionException - */ public function testOtherHolidaysFilter(): void { $holidays = Yasumi::create('Netherlands', 2017); diff --git a/tests/Base/HolidayOnFilterTest.php b/tests/Base/HolidayOnFilterTest.php index e95a069fe..5bdeecbd7 100644 --- a/tests/Base/HolidayOnFilterTest.php +++ b/tests/Base/HolidayOnFilterTest.php @@ -18,25 +18,14 @@ use DateTimeZone; use Exception; use PHPUnit\Framework\TestCase; -use ReflectionException; use Yasumi\tests\YasumiBase; use Yasumi\Yasumi; -/** - * Class HolidayOnFilterTest. - * - * Contains tests for testing the OnFilter class - */ class HolidayOnFilterTest extends TestCase { use YasumiBase; - /** - * Tests the basic usage of the OnFilter. - * - * @throws ReflectionException - * @throws Exception - */ + /** @throws Exception */ public function testHolidaysOnDate(): void { $timezone = 'Europe/Amsterdam'; @@ -57,10 +46,7 @@ public function testHolidaysOnDate(): void } } - /** - * @throws ReflectionException - * @throws Exception - */ + /** @throws Exception */ public function testHolidaysNotOnDate(): void { $timezone = 'Europe/Amsterdam'; @@ -81,10 +67,7 @@ public function testHolidaysNotOnDate(): void } } - /** - * @throws ReflectionException - * @throws Exception - */ + /** @throws Exception */ public function testCorrectNumberOfHolidaysOnDate(): void { $timezone = 'Europe/Amsterdam'; diff --git a/tests/Base/HolidayTest.php b/tests/Base/HolidayTest.php index 8bd9eba42..eff824902 100644 --- a/tests/Base/HolidayTest.php +++ b/tests/Base/HolidayTest.php @@ -25,20 +25,11 @@ use Yasumi\tests\YasumiBase; use Yasumi\TranslationsInterface; -/** - * Class HolidayTest. - * - * Contains tests for testing the Holiday class - */ class HolidayTest extends TestCase { use YasumiBase; - /** - * Tests that an InvalidArgumentException is thrown in case a blank key is given. - * - * @throws Exception - */ + /** @throws Exception */ public function testHolidayBlankKeyInvalidArgumentException(): void { $this->expectException(InvalidArgumentException::class); @@ -46,11 +37,7 @@ public function testHolidayBlankKeyInvalidArgumentException(): void new Holiday('', [], new DateTime()); } - /** - * Tests that an Yasumi\Exception\UnknownLocaleException is thrown in case an invalid locale is given. - * - * @throws Exception - */ + /** @throws Exception */ public function testCreateHolidayUnknownLocaleException(): void { $this->expectException(UnknownLocaleException::class); @@ -58,11 +45,7 @@ public function testCreateHolidayUnknownLocaleException(): void new Holiday('testHoliday', [], new DateTime(), 'wx-YZ'); } - /** - * Tests that a Yasumi holiday instance can be serialized to a JSON object. - * - * @throws Exception - */ + /** @throws Exception */ public function testHolidayIsJsonSerializable(): void { $holiday = new Holiday('testHoliday', [], new DateTime(), 'en_US'); @@ -74,12 +57,7 @@ public function testHolidayIsJsonSerializable(): void self::assertArrayHasKey('shortName', $instance); } - /** - * Tests that a Yasumi holiday instance can be created using an object that implements the DateTimeInterface (e.g. - * DateTime or DateTimeImmutable). - * - * @throws Exception - */ + /** @throws Exception */ public function testHolidayWithDateTimeInterface(): void { // Assert with DateTime instance @@ -93,11 +71,7 @@ public function testHolidayWithDateTimeInterface(): void self::assertInstanceOf(Holiday::class, $holiday); } - /** - * Tests the getLocales function of the Holiday object. - * - * @throws Exception - */ + /** @throws Exception */ public function testHolidayGetLocales(): void { $holiday = new Holiday('testHoliday', [], new DateTime(), 'ca_ES_VALENCIA'); @@ -109,11 +83,7 @@ public function testHolidayGetLocales(): void self::assertEquals(['de_DE', 'de', Holiday::LOCALE_KEY], $method->invoke($holiday, ['de_DE', Holiday::LOCALE_KEY])); } - /** - * Tests the getName function of the Holiday object without any arguments provided. - * - * @throws Exception - */ + /** @throws Exception */ public function testHolidayGetNameWithoutArgument(): void { // 'en_US' fallback @@ -160,12 +130,7 @@ public function testHolidayGetNameWithoutArgument(): void self::assertEquals('testHoliday', $holiday->getName()); } - /** - * Tests the getName function of the Holiday object with an explicit list of locales. - * - * @throws MissingTranslationException - * @throws Exception - */ + /** @throws Exception */ public function testHolidayGetNameWithArgument(): void { $translations = [ @@ -197,11 +162,7 @@ public function testHolidayGetNameWithArgument(): void $holiday->getName(['it']); } - /** - * Tests the getName function of the Holiday object with global translations and no custom translation. - * - * @throws Exception - */ + /** @throws Exception */ public function testHolidayGetNameWithGlobalTranslations(): void { $translationsStub = $this->getMockBuilder(TranslationsInterface::class)->getMock(); @@ -223,11 +184,7 @@ public function testHolidayGetNameWithGlobalTranslations(): void self::assertEquals($translations[$locale], $holiday->getName()); } - /** - * Tests the getName function of the Holiday object with global translations and no custom translation. - * - * @throws Exception - */ + /** @throws Exception */ public function testHolidayGetNameWithGlobalParentLocaleTranslations(): void { $translationsStub = $this->getMockBuilder(TranslationsInterface::class)->getMock(); @@ -249,11 +206,7 @@ public function testHolidayGetNameWithGlobalParentLocaleTranslations(): void self::assertEquals($translations['pl'], $holiday->getName()); } - /** - * Tests the getName function of the Holiday object with global translations and a new custom translation. - * - * @throws Exception - */ + /** @throws Exception */ public function testHolidayGetNameWithGlobalAndCustomTranslations(): void { $translationsStub = $this->getMockBuilder(TranslationsInterface::class)->getMock(); @@ -281,11 +234,7 @@ public function testHolidayGetNameWithGlobalAndCustomTranslations(): void self::assertEquals($customTranslation, $holiday->getName()); } - /** - * Tests the getName function of the Holiday object with global translations and an overriding custom translation. - * - * @throws Exception - */ + /** @throws Exception */ public function testHolidayGetNameWithOverridenGlobalTranslations(): void { $translationsStub = $this->getMockBuilder(TranslationsInterface::class)->getMock(); diff --git a/tests/Base/SubstituteHolidayTest.php b/tests/Base/SubstituteHolidayTest.php index 9ceca52ad..a947adb1c 100644 --- a/tests/Base/SubstituteHolidayTest.php +++ b/tests/Base/SubstituteHolidayTest.php @@ -23,20 +23,11 @@ use Yasumi\tests\YasumiBase; use Yasumi\TranslationsInterface; -/** - * Class SubstituteHolidayTest. - * - * Contains tests for testing the SubstituteHoliday class - */ class SubstituteHolidayTest extends TestCase { use YasumiBase; - /** - * Tests that an UnknownLocaleException is thrown in case an invalid locale is given. - * - * @throws \Exception - */ + /** @throws \Exception */ public function testCreateSubstituteHolidayUnknownLocaleException(): void { $holiday = new Holiday('testHoliday', [], new DateTime()); @@ -60,11 +51,7 @@ public function testCreateSubstituteHolidaySameDate(): void new SubstituteHoliday($holiday, [], new DateTime('2019-01-01')); } - /** - * Tests the constructor. - * - * @throws \Exception - */ + /** @throws \Exception */ public function testConstructor(): void { $holiday = new Holiday('testHoliday', [], new DateTime('2019-01-01'), 'en_US', Holiday::TYPE_BANK); @@ -76,11 +63,7 @@ public function testConstructor(): void self::assertEquals(new DateTime('2019-01-02'), $substitute); } - /** - * Tests that a Yasumi holiday instance can be serialized to a JSON object. - * - * @throws \Exception - */ + /** @throws \Exception */ public function testSubstituteHolidayIsJsonSerializable(): void { $holiday = new Holiday('testHoliday', [], new DateTime('2019-01-01'), 'en_US'); @@ -94,12 +77,7 @@ public function testSubstituteHolidayIsJsonSerializable(): void self::assertArrayHasKey('substitutedHoliday', $instance); } - /** - * Tests that a Yasumi holiday instance can be created using an object that implements the DateTimeInterface (e.g. - * DateTime or DateTimeImmutable). - * - * @throws \Exception - */ + /** @throws \Exception */ public function testSubstituteHolidayWithDateTimeInterface(): void { // Assert with DateTime instance @@ -114,11 +92,7 @@ public function testSubstituteHolidayWithDateTimeInterface(): void self::assertInstanceOf(SubstituteHoliday::class, $substitute); } - /** - * Tests the getName function of the SubstituteHoliday object with no translations for the name given. - * - * @throws \Exception - */ + /** @throws \Exception */ public function testSubstituteHolidayGetNameWithNoTranslations(): void { $name = 'testHoliday'; @@ -129,11 +103,7 @@ public function testSubstituteHolidayGetNameWithNoTranslations(): void self::assertEquals('substituteHoliday:'.$name, $substitute->getName()); } - /** - * Tests the getName function of the SubstituteHoliday object when it has a custom translation. - * - * @throws \Exception - */ + /** @throws \Exception */ public function testSubstituteHolidayGetNameWithCustomSubstituteTranslation(): void { $name = 'testHoliday'; @@ -159,11 +129,7 @@ public function testSubstituteHolidayGetNameWithCustomSubstituteTranslation(): v self::assertEquals($translation, $substitute->getName()); } - /** - * Tests the getName function of the SubstituteHoliday object when substitute holiday pattern uses fallback. - * - * @throws \Exception - */ + /** @throws \Exception */ public function testSubstituteHolidayGetNameWithPatternFallback(): void { $name = 'testHoliday'; @@ -189,11 +155,7 @@ public function testSubstituteHolidayGetNameWithPatternFallback(): void self::assertEquals('My Holiday obs', $substitute->getName()); } - /** - * Tests the getName function of the SubstituteHoliday object when it has a global translation. - * - * @throws \Exception - */ + /** @throws \Exception */ public function testSubstituteHolidayGetNameWithGlobalSubstituteTranslation(): void { $name = 'testHoliday'; @@ -219,11 +181,7 @@ public function testSubstituteHolidayGetNameWithGlobalSubstituteTranslation(): v self::assertEquals($translation, $substitute->getName()); } - /** - * Tests the getName function of the SubstituteHoliday object when only the substituted holiday has a translation. - * - * @throws \Exception - */ + /** @throws \Exception */ public function testSubstituteHolidayGetNameWithSubstitutedTranslation(): void { $name = 'testHoliday'; diff --git a/tests/Base/TranslationsTest.php b/tests/Base/TranslationsTest.php index d62d3b05d..ad4a785ab 100644 --- a/tests/Base/TranslationsTest.php +++ b/tests/Base/TranslationsTest.php @@ -20,11 +20,6 @@ use Yasumi\Exception\UnknownLocaleException; use Yasumi\Translations; -/** - * Class TranslationsTest. - * - * Contains tests for testing the Translations class - */ class TranslationsTest extends TestCase { public const LOCALES = [ @@ -33,9 +28,6 @@ class TranslationsTest extends TestCase 'pl_PL', ]; - /** - * Tests adding single translation. - */ public function testAddTranslation(): void { $translations = new Translations(self::LOCALES); @@ -58,9 +50,6 @@ public function testAddTranslation(): void self::assertEquals($translation, $translations->getTranslation($key, $locale)); } - /** - * Tests adding multiple translations. - */ public function testAddMultipleTranslations(): void { $translations = new Translations(self::LOCALES); @@ -111,9 +100,6 @@ public function testAddMultipleTranslations(): void self::assertEquals($thirdTranslation, $translations->getTranslation($thirdIdentifier, $thirdLocale)); } - /** - * Tests that an UnknownLocaleException is thrown when adding translation for unknown locale. - */ public function testAddTranslationUnknownLocaleException(): void { $this->expectException(UnknownLocaleException::class); @@ -127,9 +113,6 @@ public function testAddTranslationUnknownLocaleException(): void $translations->addTranslation($key, $unknownLocale, $translation); } - /** - * Tests that no translation is returned for an unknown holiday. - */ public function testNoTranslationForUnknownHoliday(): void { $translations = new Translations(self::LOCALES); @@ -146,9 +129,6 @@ public function testNoTranslationForUnknownHoliday(): void self::assertEmpty($translations->getTranslations($unknownIdentifier)); } - /** - * Tests that no translation is returned for not translated locale. - */ public function testNoTranslationForNotTranslatedLocale(): void { $translations = new Translations(self::LOCALES); @@ -164,9 +144,6 @@ public function testNoTranslationForNotTranslatedLocale(): void self::assertNull($translations->getTranslation($key, $unknownLocale)); } - /** - * Tests loading one translation file from directory. - */ public function testLoadingTranslationsFromDirectory(): void { $key = 'newYearsDay'; @@ -193,9 +170,6 @@ public function testLoadingTranslationsFromDirectory(): void self::assertEquals($translation, $translations->getTranslation($key, $locale)); } - /** - * Tests that translation is not loaded from file with invalid extension. - */ public function testNotLoadingTranslationsFromFileWithInvalidExtension(): void { $key = 'newYearsDay'; @@ -217,9 +191,6 @@ public function testNotLoadingTranslationsFromFileWithInvalidExtension(): void self::assertEmpty($translations->getTranslations($key)); } - /** - * Tests that an UnknownLocaleException is thrown when loading translation with unknown locale(s). - */ public function testLoadingTranslationsFromDirectoryWithUnknownLocaleException(): void { $this->expectException(UnknownLocaleException::class); @@ -239,9 +210,6 @@ public function testLoadingTranslationsFromDirectoryWithUnknownLocaleException() $translations->loadTranslations(vfsStream::url('root/lang')); } - /** - * Tests that an InvalidArgumentException is thrown when loading translation from inexistent directory. - */ public function testLoadingTranslationsFromInexistentDirectory(): void { $this->expectException(InvalidArgumentException::class); @@ -252,9 +220,6 @@ public function testLoadingTranslationsFromInexistentDirectory(): void $translations->loadTranslations(vfsStream::url('root/lang')); } - /** - * Tests loading more than one translation file from directory. - */ public function testLoadingMultipleTranslationsFromDirectory(): void { $firstIdentifier = 'newYearsDay'; diff --git a/tests/Base/YasumiExternalProvider.php b/tests/Base/YasumiExternalProvider.php index 224f0f6a1..0bce81376 100644 --- a/tests/Base/YasumiExternalProvider.php +++ b/tests/Base/YasumiExternalProvider.php @@ -16,16 +16,8 @@ use Yasumi\Provider\AbstractProvider; -/** - * Class YasumiExternalProvider. - * - * Class for testing the use of an external holiday provider class. - */ class YasumiExternalProvider extends AbstractProvider { - /** - * Initialize country holidays. - */ public function initialize(): void { // We don't actually have to do anything here. diff --git a/tests/Base/YasumiTest.php b/tests/Base/YasumiTest.php index 2a94f3153..27d9dd0fe 100644 --- a/tests/Base/YasumiTest.php +++ b/tests/Base/YasumiTest.php @@ -27,30 +27,14 @@ use Yasumi\tests\YasumiBase; use Yasumi\Yasumi; -/** - * Class YasumiTest. - * - * Contains tests for testing the Holiday class - */ class YasumiTest extends TestCase { use YasumiBase; - /** - * The lower year limit supported by Yasumi. - */ public const YEAR_LOWER_BOUND = 1000; - /** - * The upper year limit supported by Yasumi. - */ public const YEAR_UPPER_BOUND = 9999; - /** - * Tests that an InvalidArgumentException is thrown in case an invalid year is given. - * - * @throws ReflectionException - */ public function testCreateWithInvalidYear(): void { $this->expectException(InvalidYearException::class); @@ -58,11 +42,6 @@ public function testCreateWithInvalidYear(): void Yasumi::create('Japan', 10100); } - /** - * Tests that an InvalidArgumentException is thrown in case an invalid holiday provider is given. - * - * @throws ReflectionException - */ public function testCreateWithInvalidProvider(): void { $this->expectException(ProviderNotFoundException::class); @@ -70,11 +49,6 @@ public function testCreateWithInvalidProvider(): void Yasumi::create('Mars'); } - /** - * Tests that an InvalidArgumentException is thrown in case we try to load a Trait as provider. - * - * @throws ReflectionException - */ public function testCreateWithInvalidProviderBecauseItsATrait(): void { $this->expectException(InvalidArgumentException::class); @@ -82,11 +56,6 @@ public function testCreateWithInvalidProviderBecauseItsATrait(): void Yasumi::create('CommonHolidays'); } - /** - * Tests that an InvalidArgumentException is thrown in case we try to load the AbstractProvider as provider. - * - * @throws ReflectionException - */ public function testCreateWithAbstractClassProvider(): void { $this->expectException(InvalidArgumentException::class); @@ -94,11 +63,6 @@ public function testCreateWithAbstractClassProvider(): void Yasumi::create('AbstractProvider'); } - /** - * Tests that Yasumi allows external classes that extend the ProviderInterface. - * - * @throws ReflectionException - */ public function testCreateWithAbstractExtension(): void { $class = YasumiExternalProvider::class; @@ -109,11 +73,6 @@ public function testCreateWithAbstractExtension(): void self::assertInstanceOf(YasumiExternalProvider::class, $instance); } - /** - * Tests that an Yasumi\Exception\UnknownLocaleException is thrown in case an invalid locale is given. - * - * @throws ReflectionException - */ public function testCreateWithInvalidLocale(): void { $this->expectException(UnknownLocaleException::class); @@ -125,11 +84,6 @@ public function testCreateWithInvalidLocale(): void ); } - /** - * Tests that the count function returns an integer and a correct count for the test holiday provider. - * - * @throws ReflectionException - */ public function testCount(): void { // There are 16 holidays in Japan in the year 2015, with 1 substituted holiday. @@ -140,11 +94,6 @@ public function testCount(): void self::assertNotEquals(17, $holidays->count()); } - /** - * Tests that the getType function returns a string for the test holiday provider. - * - * @throws ReflectionException - */ public function testGetType(): void { $holidays = Yasumi::create('Japan', self::numberBetween(1949, self::YEAR_UPPER_BOUND)); @@ -153,11 +102,6 @@ public function testGetType(): void self::assertIsString($holiday->getType()); } - /** - * Tests that the getYear function returns an integer for the test holiday provider. - * - * @throws ReflectionException - */ public function testGetYear(): void { $year = self::numberBetween(self::YEAR_LOWER_BOUND, self::YEAR_UPPER_BOUND); @@ -183,11 +127,6 @@ public function testNext(): void $this->assertHoliday($country, $name, $year + 1, $holidays->next($name)); } - /** - * Tests the next function that an InvalidArgumentException is thrown in case a blank name is given. - * - * @throws ReflectionException - */ public function testNextWithBlankKey(): void { $this->expectException(InvalidArgumentException::class); @@ -221,11 +160,6 @@ public function testPrevious(): void ); } - /** - * Tests the previous function that an InvalidArgumentException is thrown in case a blank name is given. - * - * @throws ReflectionException - */ public function testPreviousWithBlankKey(): void { $this->expectException(InvalidArgumentException::class); @@ -237,11 +171,6 @@ public function testPreviousWithBlankKey(): void $holidays->previous(''); } - /** - * Tests that the getHolidayNames function returns an array and a correct count for the test holiday provider. - * - * @throws ReflectionException - */ public function testGetHolidayNames(): void { $holidays = Yasumi::create('Japan', 2015); @@ -252,11 +181,6 @@ public function testGetHolidayNames(): void self::assertContains('newYearsDay', $holidayNames); } - /** - * Tests that the WhenIs function returns a string representation of the date the given holiday occurs. - * - * @throws ReflectionException - */ public function testWhenIs(): void { $holidays = Yasumi::create('Japan', 2010); @@ -267,11 +191,6 @@ public function testWhenIs(): void self::assertEquals('2010-09-23', $when); } - /** - * Tests that the WhenIs function throws an InvalidArgumentException when a blank key is given. - * - * @throws ReflectionException - */ public function testWhenIsWithBlankKey(): void { $this->expectException(InvalidArgumentException::class); @@ -280,11 +199,6 @@ public function testWhenIsWithBlankKey(): void $holidays->whenIs(''); } - /** - * Tests that an InvalidArgumentException is thrown in case a blank name is given for the getHoliday function. - * - * @throws ReflectionException - */ public function testGetHolidayWithBlankKey(): void { $this->expectException(InvalidArgumentException::class); @@ -293,12 +207,6 @@ public function testGetHolidayWithBlankKey(): void $holidays->getHoliday(''); } - /** - * Tests that the whatWeekDayIs function returns an integer representation of the day of the week the given holiday - * is occurring. - * - * @throws ReflectionException - */ public function testWhatWeekDayIs(): void { $holidays = Yasumi::create('Netherlands', 2110); @@ -308,11 +216,6 @@ public function testWhatWeekDayIs(): void self::assertEquals(2, $weekDay); } - /** - * Tests that the whatWeekDayIs function throws an InvalidArgumentException when a blank name is given. - * - * @throws ReflectionException - */ public function testWhatWeekDayIsWithBlankKey(): void { $this->expectException(InvalidArgumentException::class); @@ -366,9 +269,6 @@ public function testGetProvidersStaticCall(): void * only asserts that it is a date calculated by the Holiday Provider. * * @throws Exception - * @throws ReflectionException - * @throws Exception - * @throws ReflectionException */ public function testIsHoliday(): void { @@ -396,9 +296,6 @@ public function testIsHoliday(): void * only asserts that it is a date calculated by the Holiday Provider. * * @throws Exception - * @throws ReflectionException - * @throws Exception - * @throws ReflectionException */ public function testIsNotHoliday(): void { @@ -426,9 +323,6 @@ public function testIsNotHoliday(): void * @TODO Add additional unit tests for those holiday providers that differ from the global definition * * @throws Exception - * @throws ReflectionException - * @throws Exception - * @throws ReflectionException */ public function testIsWorkingDay(): void { @@ -456,9 +350,6 @@ public function testIsWorkingDay(): void * @TODO Add additional unit tests for those holiday providers that differ from the global definition * * @throws Exception - * @throws ReflectionException - * @throws Exception - * @throws ReflectionException */ public function testIsNotWorkingDay(): void { @@ -479,11 +370,6 @@ public function testIsNotWorkingDay(): void unset($isNotWorkingDay); } - /** - * Tests that holidays successfully can be removed from the list of holidays of a provider. - * - * @throws ReflectionException - */ public function testRemoveHoliday(): void { $provider = Yasumi::create('Ireland', 2018); diff --git a/tests/Base/YasumiWorkdayTest.php b/tests/Base/YasumiWorkdayTest.php index 4a46b505d..0a794f1b3 100644 --- a/tests/Base/YasumiWorkdayTest.php +++ b/tests/Base/YasumiWorkdayTest.php @@ -19,14 +19,8 @@ use DateTimeZone; use Exception; use PHPUnit\Framework\TestCase; -use ReflectionException; use Yasumi\Yasumi; -/** - * Class YasumiWorkdayTest. - * - * Class for testing the workday functions. - */ class YasumiWorkdayTest extends TestCase { public const FORMAT_DATE = 'Y-m-d'; @@ -35,7 +29,6 @@ class YasumiWorkdayTest extends TestCase * Tests that the nextWorkingDay function returns an object that implements the DateTimeInterface (e.g. DateTime). * * @throws Exception - * @throws ReflectionException */ public function testNextWorkingDay(): void { @@ -64,7 +57,6 @@ public function testNextWorkingDay(): void * Tests that the prevWorkingDay function returns an object that implements the DateTimeInterface (e.g. DateTime). * * @throws Exception - * @throws ReflectionException */ public function testPreviousWorkingDay(): void { @@ -94,7 +86,6 @@ public function testPreviousWorkingDay(): void * DateTimeInterface (e.g. DateTime) when an interval is chosen that passes the year boundary (i.e. beyond 12/31). * * @throws Exception - * @throws ReflectionException */ public function testYearBoundary(): void { @@ -148,7 +139,6 @@ public function testYearBoundary(): void * * @dataProvider dataProviderWorkDayNextYear * - * @throws ReflectionException * @throws Exception */ public function testWorkDayIsNextYear(string $start, int $workdays, string $expectedNext): void @@ -185,7 +175,6 @@ public function dataProviderWorkDayNextYear(): array * * @dataProvider dataProviderWorkDayPreviousYear * - * @throws ReflectionException * @throws Exception */ public function testWorkDayIsPreviousYear(string $start, int $workdays, string $expectedNext): void From 93c4fab933592a86900a328b17c760a9aacdae83 Mon Sep 17 00:00:00 2001 From: Sacha Telgenhof Date: Thu, 3 Feb 2022 09:02:56 +0900 Subject: [PATCH 005/142] Extracted generators to private functions as a foreach only accepts iterators. --- tests/Portugal/PortugueseRepublicDayTest.php | 40 ++++++++++++-------- 1 file changed, 25 insertions(+), 15 deletions(-) diff --git a/tests/Portugal/PortugueseRepublicDayTest.php b/tests/Portugal/PortugueseRepublicDayTest.php index e70ea6ba7..8c5f2fb4e 100644 --- a/tests/Portugal/PortugueseRepublicDayTest.php +++ b/tests/Portugal/PortugueseRepublicDayTest.php @@ -37,10 +37,7 @@ class PortugueseRepublicDayTest extends PortugalBaseTestCase implements HolidayT */ public function testHolidayOnAfterRestoration(): void { - foreach (function () { - yield $this->generateRandomYear(self::HOLIDAY_YEAR_RESTORED); - yield self::HOLIDAY_YEAR_RESTORED; - } as $year) { + foreach ($this->randomYearsOnAfterRestoration() as $year) { $this->assertHoliday( self::REGION, self::HOLIDAY, @@ -68,10 +65,7 @@ public function testNotHolidayDuringAbolishment(): void */ public function testHolidayOnAfterEstablishment(): void { - foreach (function () { - yield $this->generateRandomYear(self::ESTABLISHMENT_YEAR); - yield self::ESTABLISHMENT_YEAR; - } as $year) { + foreach ($this->randomYearsOnAfterEstablishment() as $year) { $this->assertHoliday( self::REGION, self::HOLIDAY, @@ -86,10 +80,7 @@ public function testHolidayOnAfterEstablishment(): void */ public function testHolidayBeforeEstablishment(): void { - foreach (function () { - yield $this->generateRandomYear(1000, self::ESTABLISHMENT_YEAR - 1); - yield self::ESTABLISHMENT_YEAR - 1; - } as $year) { + foreach ($this->randomYearsBeforeEstablishment() as $year) { $this->assertNotHoliday(self::REGION, self::HOLIDAY, $year); } } @@ -124,12 +115,31 @@ public function testHolidayType(): void } } - /** - * @return \Generator - */ + /** @return \Generator */ private function randomEstablishedYear(): \Generator { yield $this->generateRandomYear(self::ESTABLISHMENT_YEAR, self::HOLIDAY_YEAR_SUSPENDED - 1); yield $this->generateRandomYear(self::HOLIDAY_YEAR_RESTORED); } + + /** @return \Generator */ + private function randomYearsBeforeEstablishment(): \Generator + { + yield $this->generateRandomYear(1000, self::ESTABLISHMENT_YEAR - 1); + yield self::ESTABLISHMENT_YEAR - 1; + } + + /** @return \Generator */ + private function randomYearsOnAfterEstablishment(): \Generator + { + yield $this->generateRandomYear(self::ESTABLISHMENT_YEAR); + yield self::ESTABLISHMENT_YEAR; + } + + /** @return \Generator */ + private function randomYearsOnAfterRestoration(): \Generator + { + yield $this->generateRandomYear(self::HOLIDAY_YEAR_RESTORED); + yield self::HOLIDAY_YEAR_RESTORED; + } } From 8e4c7e47cbba7a7af59323fe69985082e432ebc7 Mon Sep 17 00:00:00 2001 From: Sacha Telgenhof Date: Thu, 3 Feb 2022 21:12:26 +0900 Subject: [PATCH 006/142] Removed count from ProviderInterface as the AbstractProvider already implements the Countable interface. --- src/Yasumi/Provider/AbstractProvider.php | 9 +++++++-- src/Yasumi/ProviderInterface.php | 12 +----------- 2 files changed, 8 insertions(+), 13 deletions(-) diff --git a/src/Yasumi/Provider/AbstractProvider.php b/src/Yasumi/Provider/AbstractProvider.php index 28f81e853..ae9886305 100755 --- a/src/Yasumi/Provider/AbstractProvider.php +++ b/src/Yasumi/Provider/AbstractProvider.php @@ -30,7 +30,7 @@ /** * Class AbstractProvider. */ -abstract class AbstractProvider implements ProviderInterface, Countable, IteratorAggregate +abstract class AbstractProvider implements Countable, ProviderInterface, IteratorAggregate { /** * Code to identify the Holiday Provider. Typically, this is the ISO3166 code corresponding to the respective @@ -171,7 +171,12 @@ public function whatWeekDayIs(string $key): int return (int) $this->holidays[$key]->format('w'); } - /** {@inheritdoc} */ + /** + * Returns the number of defined holidays (for the given country and the given year). + * In case a holiday is substituted (e.g. observed), the holiday is only counted once. + * + * @return int number of holidays + */ public function count(): int { $names = array_map(static function ($holiday): string { diff --git a/src/Yasumi/ProviderInterface.php b/src/Yasumi/ProviderInterface.php index 483806355..430ca4fdc 100755 --- a/src/Yasumi/ProviderInterface.php +++ b/src/Yasumi/ProviderInterface.php @@ -29,9 +29,7 @@ */ interface ProviderInterface extends \Countable { - /** - * Initialize country holidays. - */ + /** Initialize country holidays */ public function initialize(): void; /** @@ -156,14 +154,6 @@ public function whenIs(string $key): string; */ public function whatWeekDayIs(string $key): int; - /** - * Returns the number of defined holidays (for the given country and the given year). - * In case a holiday is substituted (e.g. observed), the holiday is only counted once. - * - * @return int number of holidays - */ - public function count(): int; - /** * Gets all the holiday names defined by this holiday provider (for the given year). * From 1f6db4ace316b7bf940422f60f1e3656c9d083ad Mon Sep 17 00:00:00 2001 From: Sacha Telgenhof Date: Thu, 3 Feb 2022 21:46:58 +0900 Subject: [PATCH 007/142] Updated the Changelog with the recent changes. --- CHANGELOG.md | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/CHANGELOG.md b/CHANGELOG.md index e292b5485..4ac626dcb 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -11,12 +11,21 @@ to [Semantic Versioning](https://semver.org). ### Changed +- Included the unit tests directory for checking by PHPStan. + ### Fixed +- Created the interface methods of the `ProviderInterface` that the abstract provider class implements. Since the return + type of the Yasumi factory methods is now `ProviderInterface`, those missing methods generated errors especially by + statistic analyzers. +- Included the data type for test methods that return an array. + ### Deprecated ### Removed +- Superfluous notes/comments. + ## [2.5.0] - 2022-01-30 ### Added From acf62a7bd0248d1e62bd826d91cd0c2a4b598cea Mon Sep 17 00:00:00 2001 From: Sacha Telgenhof Date: Thu, 3 Feb 2022 22:35:12 +0900 Subject: [PATCH 008/142] The test for Remembrance Day (Argentina) in that Remembrance Day was considered for all years: it is only celebrated since 2006. --- CHANGELOG.md | 2 ++ tests/Argentina/ArgentinaTest.php | 5 ++++- 2 files changed, 6 insertions(+), 1 deletion(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 4ac626dcb..e2ee0927f 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -15,6 +15,8 @@ to [Semantic Versioning](https://semver.org). ### Fixed +- The test for Remembrance Day (Argentina) in that Remembrance Day was considered for all years: it is only celebrated + since 2006. - Created the interface methods of the `ProviderInterface` that the abstract provider class implements. Since the return type of the Yasumi factory methods is now `ProviderInterface`, those missing methods generated errors especially by statistic analyzers. diff --git a/tests/Argentina/ArgentinaTest.php b/tests/Argentina/ArgentinaTest.php index 0f66d092a..6fb7983a0 100644 --- a/tests/Argentina/ArgentinaTest.php +++ b/tests/Argentina/ArgentinaTest.php @@ -47,7 +47,6 @@ public function testOfficialHolidays(): void $holidays = [ 'newYearsDay', 'internationalWorkersDay', - 'remembranceDay', 'malvinasDay', 'mayRevolution', 'generalMartinMigueldeGuemesDay', @@ -63,6 +62,10 @@ public function testOfficialHolidays(): void $holidays[] = 'independenceDay'; } + if ($this->year >= 2006) { + $holidays[] = 'remembranceDay'; + } + $this->assertDefinedHolidays($holidays, self::REGION, $this->year, Holiday::TYPE_OFFICIAL); } From a2788843bcbdfa80b3fd0dcd7ceed7be02d70ebb Mon Sep 17 00:00:00 2001 From: Sacha Telgenhof Date: Thu, 3 Feb 2022 23:38:15 +0900 Subject: [PATCH 009/142] Reverted visibility to protected. Accidentally the visibility was reduced during a cleanup of code. This causes these methods not being accessible when extending a provider class for example. --- src/Yasumi/Provider/CommonHolidays.php | 20 ++++++++++---------- 1 file changed, 10 insertions(+), 10 deletions(-) diff --git a/src/Yasumi/Provider/CommonHolidays.php b/src/Yasumi/Provider/CommonHolidays.php index 8afb5131d..aea86a0eb 100644 --- a/src/Yasumi/Provider/CommonHolidays.php +++ b/src/Yasumi/Provider/CommonHolidays.php @@ -186,7 +186,7 @@ protected function internationalWomensDay( * @throws \InvalidArgumentException * @throws \Exception */ - private function newYearsEve( + protected function newYearsEve( int $year, string $timezone, string $locale, @@ -217,7 +217,7 @@ private function newYearsEve( * @throws \InvalidArgumentException * @throws \Exception */ - private function valentinesDay( + protected function valentinesDay( int $year, string $timezone, string $locale, @@ -252,7 +252,7 @@ private function valentinesDay( * @throws \InvalidArgumentException * @throws \Exception */ - private function worldAnimalDay( + protected function worldAnimalDay( int $year, string $timezone, string $locale, @@ -288,7 +288,7 @@ private function worldAnimalDay( * @throws \InvalidArgumentException * @throws \Exception */ - private function fathersDay( + protected function fathersDay( int $year, string $timezone, string $locale, @@ -324,7 +324,7 @@ private function fathersDay( * @throws \InvalidArgumentException * @throws \Exception */ - private function mothersDay( + protected function mothersDay( int $year, string $timezone, string $locale, @@ -360,7 +360,7 @@ private function mothersDay( * @throws \InvalidArgumentException * @throws \Exception */ - private function victoryInEuropeDay( + protected function victoryInEuropeDay( int $year, string $timezone, string $locale, @@ -398,7 +398,7 @@ private function victoryInEuropeDay( * @throws \InvalidArgumentException * @throws \Exception */ - private function armisticeDay( + protected function armisticeDay( int $year, string $timezone, string $locale, @@ -426,7 +426,7 @@ private function armisticeDay( * * @throws \Exception */ - private function summerTime( + protected function summerTime( int $year, string $timezone, string $locale, @@ -460,7 +460,7 @@ private function summerTime( * * @throws \Exception */ - private function winterTime( + protected function winterTime( int $year, string $timezone, string $locale, @@ -503,7 +503,7 @@ private function winterTime( * * @throws \Exception */ - private function calculateSummerWinterTime( + protected function calculateSummerWinterTime( int $year, string $timezone, bool $summer From 6f708f3964ac475c0a21d39f5bb74872837633e8 Mon Sep 17 00:00:00 2001 From: Sacha Telgenhof Date: Fri, 4 Feb 2022 00:11:57 +0900 Subject: [PATCH 010/142] Reverted visibility to protected. Accidentally the visibility was reduced during a cleanup of code. This causes these methods not being accessible when extending a provider class for example. --- src/Yasumi/Provider/ChristianHolidays.php | 24 +++++++++++------------ 1 file changed, 12 insertions(+), 12 deletions(-) diff --git a/src/Yasumi/Provider/ChristianHolidays.php b/src/Yasumi/Provider/ChristianHolidays.php index 40e229a11..614b9fb25 100644 --- a/src/Yasumi/Provider/ChristianHolidays.php +++ b/src/Yasumi/Provider/ChristianHolidays.php @@ -477,7 +477,7 @@ protected function pentecost( * @throws \InvalidArgumentException * @throws \Exception */ - private function easterMonday( + protected function easterMonday( int $year, string $timezone, string $locale, @@ -512,7 +512,7 @@ private function easterMonday( * @throws \InvalidArgumentException * @throws \Exception */ - private function ascensionDay( + protected function ascensionDay( int $year, string $timezone, string $locale, @@ -544,7 +544,7 @@ private function ascensionDay( * @throws \InvalidArgumentException * @throws \Exception */ - private function pentecostMonday( + protected function pentecostMonday( int $year, string $timezone, string $locale, @@ -580,7 +580,7 @@ private function pentecostMonday( * @throws \InvalidArgumentException * @throws \Exception */ - private function christmasEve( + protected function christmasEve( int $year, string $timezone, string $locale, @@ -613,7 +613,7 @@ private function christmasEve( * @throws \InvalidArgumentException * @throws \Exception */ - private function christmasDay( + protected function christmasDay( int $year, string $timezone, string $locale, @@ -646,7 +646,7 @@ private function christmasDay( * @throws \InvalidArgumentException * @throws \Exception */ - private function secondChristmasDay( + protected function secondChristmasDay( int $year, string $timezone, string $locale, @@ -681,7 +681,7 @@ private function secondChristmasDay( * @throws \InvalidArgumentException * @throws \Exception */ - private function ashWednesday( + protected function ashWednesday( int $year, string $timezone, string $locale, @@ -717,7 +717,7 @@ private function ashWednesday( * @throws \InvalidArgumentException * @throws \Exception */ - private function immaculateConception( + protected function immaculateConception( int $year, string $timezone, string $locale, @@ -754,7 +754,7 @@ private function immaculateConception( * @throws \InvalidArgumentException * @throws \Exception */ - private function stStephensDay( + protected function stStephensDay( int $year, string $timezone, string $locale, @@ -790,7 +790,7 @@ private function stStephensDay( * @throws \InvalidArgumentException * @throws \Exception */ - private function maundyThursday( + protected function maundyThursday( int $year, string $timezone, string $locale, @@ -827,7 +827,7 @@ private function maundyThursday( * @throws \InvalidArgumentException * @throws \Exception */ - private function stJohnsDay( + protected function stJohnsDay( int $year, string $timezone, string $locale, @@ -858,7 +858,7 @@ private function stJohnsDay( * @throws \InvalidArgumentException * @throws \Exception */ - private function annunciation( + protected function annunciation( int $year, string $timezone, string $locale, From 76560bf9bd4ad490e5b616241166343d335944cc Mon Sep 17 00:00:00 2001 From: Sacha Telgenhof Date: Fri, 4 Feb 2022 22:40:30 +0900 Subject: [PATCH 011/142] Removed exceptions in PHPDoc that are not thrown. Simplified variable assignment. --- tests/YasumiBase.php | 22 +++++++--------------- 1 file changed, 7 insertions(+), 15 deletions(-) diff --git a/tests/YasumiBase.php b/tests/YasumiBase.php index 8ade5c6e2..6b70a8f58 100644 --- a/tests/YasumiBase.php +++ b/tests/YasumiBase.php @@ -56,7 +56,6 @@ trait YasumiBase * @throws InvalidArgumentException * @throws RuntimeException * @throws UnknownLocaleException - * @throws ReflectionException */ public function assertDefinedHolidays( array $expectedHolidays, @@ -103,7 +102,6 @@ public function assertDefinedHolidays( * @throws InvalidArgumentException * @throws RuntimeException * @throws AssertionFailedError - * @throws ReflectionException */ public function assertHoliday( string $provider, @@ -132,7 +130,6 @@ public function assertHoliday( * @throws InvalidArgumentException * @throws RuntimeException * @throws AssertionFailedError - * @throws ReflectionException */ public function assertSubstituteHoliday( string $provider, @@ -186,7 +183,6 @@ public function assertNotSubstituteHoliday( * @throws UnknownLocaleException * @throws InvalidDateException * @throws AssertionFailedError - * @throws ReflectionException */ public function assertNotHoliday( string $provider, @@ -211,8 +207,7 @@ public function assertNotHoliday( * @throws RuntimeException * @throws UnknownLocaleException * @throws AssertionFailedError - * @throws ReflectionException - */ + */ public function assertTranslatedHolidayName( string $provider, string $key, @@ -259,7 +254,6 @@ public function assertTranslatedHolidayName( * @throws RuntimeException * @throws AssertionFailedError * @throws UnknownLocaleException - * @throws ReflectionException */ public function assertHolidayType( string $provider, @@ -287,7 +281,6 @@ public function assertHolidayType( * @throws InvalidArgumentException * @throws RuntimeException * @throws UnknownLocaleException - * @throws ReflectionException */ public function assertDayOfWeek( string $provider, @@ -310,7 +303,6 @@ public function assertDayOfWeek( * tested * @param int $expectedSourceCount the expected number of sources * - * @throws ReflectionException */ public function assertSources(string $provider, int $expectedSourceCount): void { @@ -340,7 +332,7 @@ public function generateRandomDates( int $range = null ): array { $data = []; - $range = $range ?? 1000; + $range ??= 1000; for ($y = 1; $y <= ($iterations ?? 10); ++$y) { $year = (int) self::dateTimeBetween("-$range years", "+$range years")->format('Y'); $data[] = [$year, new DateTime("$year-$month-$day", new DateTimeZone($timezone ?? 'UTC'))]; @@ -366,7 +358,7 @@ public function generateRandomEasterDates( int $range = null ): array { $data = []; - $range = $range ?? 1000; + $range ??= 1000; for ($i = 1; $i <= ($iterations ?? 10); ++$i) { $year = (int) self::dateTimeBetween("-$range years", "+$range years")->format('Y'); @@ -394,7 +386,7 @@ public function generateRandomEasterMondayDates( int $iterations = null, int $range = null ): array { - $range = $range ?? 1000; + $range ??= 1000; return $this->generateRandomModifiedEasterDates(static function (DateTime $date) { $date->add(new DateInterval('P1D')); @@ -420,7 +412,7 @@ public function generateRandomModifiedEasterDates( int $range = null ): array { $data = []; - $range = $range ?? 1000; + $range ??= 1000; for ($i = 1; $i <= ($iterations ?? 10); ++$i) { $year = (int) self::dateTimeBetween("-$range years", "+$range years")->format('Y'); $date = $this->calculateEaster($year, $timezone ?? 'UTC'); @@ -449,7 +441,7 @@ public function generateRandomGoodFridayDates( int $iterations = null, int $range = null ): array { - $range = $range ?? 1000; + $range ??= 1000; return $this->generateRandomModifiedEasterDates(static function (DateTime $date) { $date->sub(new DateInterval('P2D')); @@ -472,7 +464,7 @@ public function generateRandomPentecostDates( int $iterations = null, int $range = null ): array { - $range = $range ?? 1000; + $range ??= 1000; return $this->generateRandomModifiedEasterDates(static function (DateTime $date) { $date->add(new DateInterval('P49D')); From 87e545a26470c03bc0283ea29d1fd333cec63676 Mon Sep 17 00:00:00 2001 From: Sacha Telgenhof Date: Fri, 4 Feb 2022 22:47:35 +0900 Subject: [PATCH 012/142] Included tests directory for analysis by Phan. --- .phan/config.php | 2 ++ 1 file changed, 2 insertions(+) diff --git a/.phan/config.php b/.phan/config.php index 8d583c969..1b53e48ef 100644 --- a/.phan/config.php +++ b/.phan/config.php @@ -350,11 +350,13 @@ // your application should be included in this list. 'directory_list' => [ 'src', + 'test' ], // A list of individual files to include in analysis // with a path relative to the root directory of the // project. 'file_list' => [ + 'vendor/phpunit/phpunit/src/Framework/Assert.php' ], ]; From cee6cfbd988949232de8503ea1c031663c578ebd Mon Sep 17 00:00:00 2001 From: Sacha Telgenhof Date: Fri, 4 Feb 2022 22:51:02 +0900 Subject: [PATCH 013/142] Upgraded PHPStan to v1.4 --- composer.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/composer.json b/composer.json index 342460ac4..5b85e464c 100755 --- a/composer.json +++ b/composer.json @@ -44,7 +44,7 @@ "infection/infection": "^0.17 | ^0.26", "mikey179/vfsstream": "^1.6", "phan/phan": "^5.2", - "phpstan/phpstan": "^0.12", + "phpstan/phpstan": "^1.4", "phpunit/phpunit": "^8.5 | ^9.5", "vimeo/psalm": "^4.9" }, From 62c25211dfb815223017dad41351da8535ad7829 Mon Sep 17 00:00:00 2001 From: Sacha Telgenhof Date: Fri, 4 Feb 2022 22:56:04 +0900 Subject: [PATCH 014/142] Added note what Exception is thrown and parameter types. Removed superfluous comments. --- tests/YasumiBase.php | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/tests/YasumiBase.php b/tests/YasumiBase.php index 6b70a8f58..fd74f6721 100644 --- a/tests/YasumiBase.php +++ b/tests/YasumiBase.php @@ -568,12 +568,10 @@ public function isWeekend( /** * Returns a random number between $int1 and $int2 (any order). * - * @param int $int1 default to 0 - * @param int $int2 defaults to 32 bit max integer, ie 2147483647 - * + * @throws Exception * @example 79907610 */ - public static function numberBetween($int1 = 0, $int2 = 2147483647): int + public static function numberBetween(int $int1 = 0, int $int2 = 2147483647): int { $min = $int1 < $int2 ? $int1 : $int2; $max = $int1 < $int2 ? $int2 : $int1; From dfb4ec111ecb2aab9e4229cb5afd3885481b1d31 Mon Sep 17 00:00:00 2001 From: Sacha Telgenhof Date: Fri, 4 Feb 2022 22:57:08 +0900 Subject: [PATCH 015/142] Reformatting. --- tests/YasumiBase.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/tests/YasumiBase.php b/tests/YasumiBase.php index fd74f6721..11b175dd6 100644 --- a/tests/YasumiBase.php +++ b/tests/YasumiBase.php @@ -207,7 +207,7 @@ public function assertNotHoliday( * @throws RuntimeException * @throws UnknownLocaleException * @throws AssertionFailedError - */ + */ public function assertTranslatedHolidayName( string $provider, string $key, @@ -302,7 +302,6 @@ public function assertDayOfWeek( * @param string $provider the holiday provider (i.e. country/state) for which the holiday need to be * tested * @param int $expectedSourceCount the expected number of sources - * */ public function assertSources(string $provider, int $expectedSourceCount): void { @@ -569,6 +568,7 @@ public function isWeekend( * Returns a random number between $int1 and $int2 (any order). * * @throws Exception + * * @example 79907610 */ public static function numberBetween(int $int1 = 0, int $int2 = 2147483647): int From d2889b79227fc31a684c9406ade0693bdb223131 Mon Sep 17 00:00:00 2001 From: Sacha Telgenhof Date: Fri, 4 Feb 2022 23:10:42 +0900 Subject: [PATCH 016/142] Removed exceptions in PHPDoc that are not thrown and added one that is thrown. Throw an exception in case the timestamp of the start and end date in the `dateTimeBetween` method can't be established. Otherwise, a boolean would be used as an argument for the subsequent step which isn't accepted. --- tests/YasumiBase.php | 19 ++++++++++++++++--- 1 file changed, 16 insertions(+), 3 deletions(-) diff --git a/tests/YasumiBase.php b/tests/YasumiBase.php index 11b175dd6..e5f183323 100644 --- a/tests/YasumiBase.php +++ b/tests/YasumiBase.php @@ -21,7 +21,6 @@ use Exception; use InvalidArgumentException; use PHPUnit\Framework\AssertionFailedError; -use ReflectionException; use RuntimeException; use Yasumi\Exception\InvalidDateException; use Yasumi\Exception\UnknownLocaleException; @@ -157,7 +156,6 @@ public function assertSubstituteHoliday( * @throws UnknownLocaleException * @throws InvalidDateException * @throws AssertionFailedError - * @throws ReflectionException */ public function assertNotSubstituteHoliday( string $provider, @@ -302,6 +300,8 @@ public function assertDayOfWeek( * @param string $provider the holiday provider (i.e. country/state) for which the holiday need to be * tested * @param int $expectedSourceCount the expected number of sources + * + * @throws Exception */ public function assertSources(string $provider, int $expectedSourceCount): void { @@ -541,6 +541,8 @@ public function generateRandomDatesWithModifier( * @param int|null $upperLimit the upper limit for generating a year number (default: 9999) * * @return int a year number + * + * @throws Exception */ public function generateRandomYear( int $lowerLimit = null, @@ -587,16 +589,27 @@ public static function numberBetween(int $int1 = 0, int $int2 = 2147483647): int * @param \DateTime|string $endDate Defaults to "now" * @param string|null $timezone time zone in which the date time should be set, default to DateTime::$defaultTimezone, if set, otherwise the result of `date_default_timezone_get` * - * @example DateTime('1999-02-02 11:42:52') + * @throws Exception * * @see http://php.net/manual/en/timezones.php * @see http://php.net/manual/en/function.date-default-timezone-get.php + * + * @example DateTime('1999-02-02 11:42:52') */ public static function dateTimeBetween($startDate = '-30 years', $endDate = 'now', $timezone = null): DateTime { $startTimestamp = $startDate instanceof \DateTime ? $startDate->getTimestamp() : strtotime($startDate); + + if (!$startTimestamp) { + throw new \RuntimeException('unable to get timestamp for the start date'); + } + $endTimestamp = static::getMaxTimestamp($endDate); + if (!$endTimestamp) { + throw new \RuntimeException('unable to get timestamp for the end date'); + } + if ($startTimestamp > $endTimestamp) { throw new \InvalidArgumentException('Start date must be anterior to end date.'); } From 504a129f0330b86f0e62d0ac3a8dd207158828d3 Mon Sep 17 00:00:00 2001 From: Sacha Telgenhof Date: Sat, 5 Feb 2022 16:54:15 +0900 Subject: [PATCH 017/142] Removed exceptions in PHPDoc that are not thrown and added ones that are. Added missing attribute data type in some classes. --- tests/Argentina/ArgentinaTest.php | 11 +-- tests/Argentina/CarnavalMondayTest.php | 8 +-- tests/Argentina/CarnavalTuesdayTest.php | 8 +-- tests/Argentina/ChristmasDayTest.php | 6 +- tests/Argentina/EasterTest.php | 6 +- tests/Argentina/FlagDayTest.php | 8 +-- .../Argentina/GeneralJoseSanMartinDayTest.php | 8 +-- .../GeneralMartinMigueldeGuemesDayTest.php | 8 +-- tests/Argentina/GoodFridayTest.php | 6 +- .../Argentina/ImmaculateConceptionDayTest.php | 8 +-- tests/Argentina/IndependenceDayTest.php | 8 +-- .../Argentina/InternationalWorkersDayTest.php | 6 +- tests/Argentina/MalvinasDayTest.php | 8 +-- tests/Argentina/MayRevolutionTest.php | 8 +-- .../Argentina/NationalSovereigntyDayTest.php | 8 +-- tests/Argentina/NewYearsDayTest.php | 6 +- tests/Argentina/RaceDayTest.php | 8 +-- tests/Argentina/RemembranceDayTest.php | 8 +-- tests/Australia/AnzacDayTest.php | 8 +-- tests/Australia/AustraliaDayTest.php | 8 +-- tests/Australia/AustraliaTest.php | 15 ++-- .../AustralianCapitalTerritoryTest.php | 7 +- .../CanberraDayTest.php | 6 +- .../EasterSaturdayTest.php | 6 +- .../EasterSundayTest.php | 6 +- .../LabourDayTest.php | 6 +- .../QueensBirthdayTest.php | 6 +- .../ReconciliationDayTest.php | 6 +- tests/Australia/BoxingDayTest.php | 6 +- tests/Australia/ChristmasDayTest.php | 6 +- tests/Australia/EasterMondayTest.php | 7 +- tests/Australia/GoodFridayTest.php | 6 +- .../NewSouthWales/BankHolidayTest.php | 6 +- .../NewSouthWales/EasterSaturdayTest.php | 6 +- .../NewSouthWales/EasterSundayTest.php | 6 +- .../Australia/NewSouthWales/LabourDayTest.php | 6 +- .../NewSouthWales/NewSouthWalesTest.php | 9 ++- .../NewSouthWales/QueensBirthdayTest.php | 6 +- tests/Australia/NewYearsDayTest.php | 6 +- .../NorthernTerritory/EasterSaturdayTest.php | 6 +- .../NorthernTerritory/MayDayTest.php | 6 +- .../NorthernTerritoryTest.php | 7 +- .../NorthernTerritory/PicnicDayTest.php | 6 +- .../NorthernTerritory/QueensBirthdayTest.php | 6 +- .../Queensland/Brisbane/BrisbaneTest.php | 7 +- .../Queensland/Brisbane/PeoplesDayTest.php | 6 +- tests/Australia/Queensland/LabourDayTest.php | 6 +- .../Queensland/QueensBirthdayTest.php | 6 +- tests/Australia/Queensland/QueenslandTest.php | 7 +- .../SouthAustralia/AdelaideCupDayTest.php | 6 +- .../SouthAustralia/ChristmasDayTest.php | 6 +- .../SouthAustralia/EasterSaturdayTest.php | 6 +- .../SouthAustralia/LabourDayTest.php | 6 +- .../SouthAustralia/ProclamationDayTest.php | 6 +- .../SouthAustralia/QueensBirthdayTest.php | 6 +- .../SouthAustralia/SouthAustraliaTest.php | 7 +- .../CentralNorth/CentralNorthTest.php | 5 +- .../CentralNorth/DevonportShowTest.php | 6 +- tests/Australia/Tasmania/EightHourDayTest.php | 6 +- .../FlindersIsland/FlindersIslandShowTest.php | 6 +- .../FlindersIsland/FlindersIslandTest.php | 5 +- .../KingIsland/KingIslandShowTest.php | 6 +- .../Tasmania/KingIsland/KingIslandTest.php | 5 +- .../Tasmania/Northeast/LauncestonShowTest.php | 6 +- .../Tasmania/Northeast/NortheastTest.php | 5 +- .../Tasmania/Northwest/BurnieShowTest.php | 6 +- .../Northwest/CircularHead/AGFESTTest.php | 6 +- .../CircularHead/CircularHeadTest.php | 5 +- .../Tasmania/Northwest/NorthwestTest.php | 5 +- .../Australia/Tasmania/QueensBirthdayTest.php | 6 +- .../Australia/Tasmania/RecreationDayTest.php | 6 +- .../Tasmania/South/HobartShowTest.php | 6 +- tests/Australia/Tasmania/South/SouthTest.php | 5 +- .../South/Southeast/HobartRegattaTest.php | 6 +- .../South/Southeast/SoutheastTest.php | 5 +- tests/Australia/Tasmania/TasmaniaTest.php | 5 +- .../Victoria/AFLGrandFinalFridayTest.php | 8 +-- .../Australia/Victoria/EasterSaturdayTest.php | 6 +- tests/Australia/Victoria/EasterSundayTest.php | 6 +- tests/Australia/Victoria/LabourDayTest.php | 6 +- .../Victoria/MelbourneCupDayTest.php | 6 +- .../Australia/Victoria/QueensBirthdayTest.php | 6 +- tests/Australia/Victoria/VictoriaTest.php | 7 +- .../WesternAustralia/LabourDayTest.php | 6 +- .../WesternAustralia/QueensBirthdayTest.php | 6 +- .../WesternAustraliaDayTest.php | 6 +- .../WesternAustralia/WesternAustraliaTest.php | 7 +- tests/Austria/AllSaintsDayTest.php | 7 +- tests/Austria/AscensionDayTest.php | 6 +- tests/Austria/AssumptionOfMaryTest.php | 7 +- tests/Austria/AustriaTest.php | 13 +--- tests/Austria/Burgenland/BurgenlandTest.php | 13 +--- tests/Austria/Burgenland/stMartinsDayTest.php | 7 +- tests/Austria/Carinthia/CarinthiaTest.php | 13 +--- tests/Austria/Carinthia/PlebisciteDayTest.php | 9 +-- tests/Austria/Carinthia/StJosephsDayTest.php | 7 +- tests/Austria/ChristmasTest.php | 7 +- tests/Austria/CorpusChristiTest.php | 6 +- tests/Austria/EasterMondayTest.php | 6 +- tests/Austria/EasterTest.php | 6 +- tests/Austria/EpiphanyTest.php | 7 +- tests/Austria/ImmaculateConceptionTest.php | 7 +- tests/Austria/InternationalWorkersDayTest.php | 7 +- .../Austria/LowerAustria/LowerAustriaTest.php | 13 +--- .../LowerAustria/StLeopoldsDayTest.php | 9 +-- tests/Austria/NationalDayTest.php | 8 +-- tests/Austria/NewYearsDayTest.php | 7 +- tests/Austria/PentecostMondayTest.php | 6 +- tests/Austria/PentecostTest.php | 6 +- tests/Austria/Salzburg/SalzburgTest.php | 13 +--- tests/Austria/Salzburg/StRupertsDayTest.php | 7 +- tests/Austria/SecondChristmasDayTest.php | 7 +- tests/Austria/Styria/StJosephsDayTest.php | 7 +- tests/Austria/Styria/StyriaTest.php | 13 +--- tests/Austria/Tyrol/StJosephsDayTest.php | 7 +- tests/Austria/Tyrol/TyrolTest.php | 13 +--- .../UpperAustria/StFloriansDayTest.php | 7 +- .../Austria/UpperAustria/UpperAustriaTest.php | 13 +--- tests/Austria/Vienna/StLeopoldsDayTest.php | 9 +-- tests/Austria/Vienna/ViennaTest.php | 13 +--- tests/Austria/Vorarlberg/StJosephsDayTest.php | 7 +- tests/Austria/Vorarlberg/VorarlbergTest.php | 13 +--- tests/Base/TypographyTest.php | 1 + tests/Base/WeekendTest.php | 4 -- tests/Base/YasumiTest.php | 4 +- tests/Belgium/AllSaintsDayTest.php | 7 +- tests/Belgium/ArmisticeDayTest.php | 7 +- tests/Belgium/AscensionDayTest.php | 6 +- tests/Belgium/AssumptionOfMaryTest.php | 7 +- tests/Belgium/BelgiumTest.php | 13 +--- tests/Belgium/ChristmasTest.php | 7 +- tests/Belgium/EasterMondayTest.php | 6 +- tests/Belgium/EasterTest.php | 6 +- tests/Belgium/InternationalWorkersDayTest.php | 7 +- tests/Belgium/NationalDayTest.php | 7 +- tests/Belgium/NewYearsDayTest.php | 7 +- tests/Belgium/PentecostTest.php | 6 +- tests/Belgium/pentecostMondayTest.php | 6 +- tests/Bosnia/BosniaTest.php | 13 +--- tests/Bosnia/ChristmasDayTest.php | 7 +- tests/Bosnia/DayAfterNewYearsDay.php | 7 +- tests/Bosnia/EasterTest.php | 6 +- tests/Bosnia/IndependenceDayTest.php | 8 +-- tests/Bosnia/InternationalWorkersDayTest.php | 7 +- tests/Bosnia/NewYearsDayTest.php | 7 +- tests/Bosnia/OrthodoxChristmasDay.php | 7 +- tests/Bosnia/SecondLabourDay.php | 7 +- tests/Bosnia/StatehoodDayTest.php | 8 +-- tests/Brazil/AllSoulsDayTest.php | 8 +-- tests/Brazil/AshWednesdayTest.php | 6 +- tests/Brazil/BrazilTest.php | 13 +--- tests/Brazil/CarnavalMondayTest.php | 8 +-- tests/Brazil/CarnavalTuesdayTest.php | 8 +-- tests/Brazil/ChristmasDayTest.php | 6 +- tests/Brazil/CorpusChristiTest.php | 6 +- tests/Brazil/EasterTest.php | 6 +- tests/Brazil/GoodFridayTest.php | 6 +- tests/Brazil/IndependenceDayTest.php | 8 +-- tests/Brazil/InternationalWorkersDayTest.php | 6 +- tests/Brazil/NewYearsDayTest.php | 6 +- tests/Brazil/OurLadyOfAparecidaDayTest.php | 8 +-- .../Brazil/ProclamationOfRepublicDayTest.php | 8 +-- tests/Brazil/TiradentesDayTest.php | 8 +-- tests/Canada/Alberta/AlbertaTest.php | 13 +--- .../BritishColumbia/BritishColumbiaTest.php | 13 +--- tests/Canada/CanadaDayTest.php | 8 +-- tests/Canada/CanadaTest.php | 13 +--- tests/Canada/ChristmasDayTest.php | 6 +- tests/Canada/LabourDayTest.php | 8 +-- tests/Canada/Manitoba/ManitobaTest.php | 13 +--- .../Canada/NewBrunswick/NewBrunswickTest.php | 13 +--- tests/Canada/NewYearsDayTest.php | 6 +- .../NewfoundlandAndLabradorTest.php | 13 +--- .../NorthwestTerritoriesTest.php | 13 +--- tests/Canada/NovaScotia/NovaScotiaTest.php | 13 +--- tests/Canada/Nunavut/NunavutTest.php | 13 +--- tests/Canada/Ontario/OntarioTest.php | 13 +--- .../PrinceEdwardIslandTest.php | 13 +--- tests/Canada/Quebec/QuebecTest.php | 13 +--- tests/Canada/RemembranceDayTest.php | 8 +-- .../Canada/Saskatchewan/SaskatchewanTest.php | 13 +--- tests/Canada/ThanksgivingDayTest.php | 8 +-- .../Canada/TruthAndReconciliationDayTest.php | 8 +-- tests/Canada/Yukon/YukonTest.php | 13 +--- tests/Croatia/AllSaintsDayTest.php | 7 +- tests/Croatia/AntifascistStruggleDayTest.php | 8 +-- tests/Croatia/AssumptionOfMaryTest.php | 7 +- tests/Croatia/ChristmasDayTest.php | 7 +- tests/Croatia/CorpusChristiTest.php | 6 +- tests/Croatia/CroatiaTest.php | 13 +--- tests/Croatia/EasterMondayTest.php | 6 +- tests/Croatia/EasterTest.php | 6 +- tests/Croatia/EpiphanyTest.php | 7 +- tests/Croatia/HomelandThanksgivingDayTest.php | 8 +-- tests/Croatia/IndependenceDayTest.php | 10 ++- tests/Croatia/InternationalWorkersDayTest.php | 7 +- tests/Croatia/NewYearsDayTest.php | 7 +- tests/Croatia/RemembranceDayTest.php | 7 +- tests/Croatia/StStephensDayTest.php | 7 +- tests/Croatia/StatehoodDayTest.php | 8 +-- tests/CzechRepublic/ChristmasDayTest.php | 7 +- tests/CzechRepublic/ChristmasEveTest.php | 7 +- tests/CzechRepublic/CzechRepublicTest.php | 15 ++-- tests/CzechRepublic/CzechStateHoodDayTest.php | 7 +- tests/CzechRepublic/EasterMondayTest.php | 6 +- tests/CzechRepublic/GoodFridayTest.php | 6 +- .../IndependentCzechoslovakStateDayTest.php | 7 +- .../InternationalWorkersDayTest.php | 7 +- tests/CzechRepublic/JanHusDayTest.php | 7 +- tests/CzechRepublic/NewYearsDayTest.php | 7 +- .../RenewalOfIndependentCzechStateDayTest.php | 7 +- .../SaintsCyrilAndMethodiusDayTest.php | 7 +- .../CzechRepublic/SecondChristmasDayTest.php | 7 +- .../StruggleForFreedomAndDemocracyDayTest.php | 7 +- .../CzechRepublic/VictoryInEuropeDayTest.php | 7 +- tests/Denmark/AscensionDayTest.php | 6 +- tests/Denmark/ChristmasDayTest.php | 7 +- tests/Denmark/ChristmasEveTest.php | 7 +- tests/Denmark/ConstitutionDayTest.php | 8 +-- tests/Denmark/DenmarkTest.php | 13 ++-- tests/Denmark/EasterMondayTest.php | 6 +- tests/Denmark/EasterTest.php | 6 +- tests/Denmark/GoodFridayTest.php | 6 +- tests/Denmark/GreatPrayerDayTest.php | 8 +-- tests/Denmark/InternationalWorkersDayTest.php | 7 +- tests/Denmark/MaundyThursdayTest.php | 6 +- tests/Denmark/NewYearsDayTest.php | 7 +- tests/Denmark/NewYearsEveTest.php | 7 +- tests/Denmark/PentecostMondayTest.php | 6 +- tests/Denmark/PentecostTest.php | 6 +- tests/Denmark/SecondChristmasDayTest.php | 7 +- tests/Denmark/SummerTimeTest.php | 6 +- tests/Denmark/WinterTimeTest.php | 6 +- tests/Estonia/ChristmasDayTest.php | 7 +- tests/Estonia/ChristmasEveDayTest.php | 7 +- tests/Estonia/EasterDayTest.php | 6 +- tests/Estonia/EstoniaTest.php | 11 +-- tests/Estonia/GoodFridayDayTest.php | 6 +- tests/Estonia/IndependenceDayTest.php | 8 +-- tests/Estonia/InternationalWorkersDayTest.php | 7 +- tests/Estonia/NewYearsDayTest.php | 7 +- tests/Estonia/PentecostTest.php | 6 +- .../RestorationOfIndependenceDayTest.php | 8 +-- tests/Estonia/SecondChristmasDayTest.php | 7 +- tests/Estonia/StJohnsDayTest.php | 7 +- tests/Estonia/VictoryDayTest.php | 8 +-- tests/Finland/AllSaintsDayTest.php | 7 +- tests/Finland/AscensionDayTest.php | 6 +- tests/Finland/ChristmasDayTest.php | 7 +- tests/Finland/EasterMondayTest.php | 6 +- tests/Finland/EasterTest.php | 6 +- tests/Finland/EpiphanyTest.php | 7 +- tests/Finland/FinlandTest.php | 13 +--- tests/Finland/GoodFridayTest.php | 6 +- tests/Finland/IndependenceDayTest.php | 8 +-- tests/Finland/InternationalWorkersDayTest.php | 7 +- tests/Finland/NewYearsDayTest.php | 7 +- tests/Finland/PentecostTest.php | 6 +- tests/Finland/SecondChristmasDayTest.php | 7 +- tests/Finland/stJohnsDayTest.php | 8 +-- tests/France/AllSaintsDayTest.php | 7 +- tests/France/ArmisticeDayTest.php | 8 +-- tests/France/AscensionDayTest.php | 6 +- tests/France/AssumptionOfMaryTest.php | 7 +- tests/France/BasRhin/BasRhinTest.php | 13 +--- tests/France/BasRhin/GoodFridayTest.php | 6 +- tests/France/BasRhin/stStephensDayTest.php | 7 +- tests/France/BastilleDayTest.php | 8 +-- tests/France/ChristmasDayTest.php | 7 +- tests/France/EasterMondayTest.php | 6 +- tests/France/FranceTest.php | 13 +--- tests/France/HautRhin/GoodFridayTest.php | 6 +- tests/France/HautRhin/HautRhinTest.php | 13 +--- tests/France/HautRhin/stStephensDayTest.php | 7 +- tests/France/InternationalWorkersDayTest.php | 7 +- tests/France/Moselle/GoodFridayTest.php | 6 +- tests/France/Moselle/MoselleTest.php | 13 +--- tests/France/Moselle/stStephensDayTest.php | 7 +- tests/France/NewYearsDayTest.php | 7 +- tests/France/PentecostMondayTest.php | 6 +- tests/France/VictoryInEuropeDayTest.php | 8 +-- tests/Georgia/EasterTest.php | 6 +- tests/Georgia/GeorgiaTest.php | 13 +--- tests/Georgia/IndependenceDayTest.php | 6 -- tests/Georgia/InternationalWomensDayTest.php | 7 +- tests/Georgia/MtskhetobaDayTest.php | 7 +- tests/Georgia/NewYearsDayTest.php | 7 +- tests/Georgia/OrthodoxChristmasDayTest.php | 7 +- tests/Georgia/OrthodoxEpiphanyDayTest.php | 7 +- tests/Georgia/SecondNewYearDayTest.php | 7 +- tests/Georgia/StAndrewsDayTest.php | 7 +- tests/Georgia/StGeorgesDayTest.php | 7 +- tests/Georgia/StMarysDayTest.php | 7 +- tests/Georgia/UnityDayTest.php | 6 -- tests/Georgia/VictoryDayTest.php | 7 +- tests/Germany/AscensionDayTest.php | 6 +- .../BadenWurttemberg/AllSaintsDayTest.php | 7 +- .../BadenWurttemberg/BadenWurttembergTest.php | 13 +--- .../BadenWurttemberg/CorpusChristiTest.php | 6 +- .../Germany/BadenWurttemberg/EpiphanyTest.php | 7 +- tests/Germany/Bavaria/AllSaintsDayTest.php | 7 +- tests/Germany/Bavaria/BavariaTest.php | 13 +--- tests/Germany/Bavaria/CorpusChristiTest.php | 6 +- tests/Germany/Bavaria/EpiphanyTest.php | 7 +- tests/Germany/Berlin/BerlinTest.php | 13 +--- .../Berlin/DayOfLiberation2020Test.php | 10 +-- .../Berlin/InternationalWomensDay2019Test.php | 10 ++- tests/Germany/Brandenburg/BrandenburgTest.php | 13 +--- .../Brandenburg/ReformationDayTest.php | 9 +-- tests/Germany/Bremen/BremenTest.php | 13 +--- tests/Germany/Bremen/ReformationDayTest.php | 9 +-- tests/Germany/ChristmasTest.php | 7 +- tests/Germany/EasterMondayTest.php | 6 +- tests/Germany/GermanUnityDayTest.php | 8 +-- tests/Germany/GermanyTest.php | 13 +--- tests/Germany/GoodFridayTest.php | 6 +- .../Germany/Hamburg/DayOfReformationTest.php | 9 +-- tests/Germany/Hamburg/HamburgTest.php | 13 +--- tests/Germany/Hesse/CorpusChristiTest.php | 6 +- tests/Germany/Hesse/HesseTest.php | 13 +--- tests/Germany/InternationalWorkersDayTest.php | 7 +- tests/Germany/LowerSaxony/LowerSaxonyTest.php | 13 +--- .../LowerSaxony/ReformationDayTest.php | 9 +-- .../MecklenburgWesternPomeraniaTest.php | 13 +--- .../ReformationDayTest.php | 7 +- tests/Germany/NewYearsDayTest.php | 7 +- tests/Germany/NewYearsEveTest.php | 7 +- .../NorthRhineWestphalia/AllSaintsDayTest.php | 7 +- .../CorpusChristiTest.php | 6 +- .../NorthRhineWestphaliaTest.php | 13 +--- tests/Germany/PentecostMondayTest.php | 6 +- tests/Germany/PentecostTest.php | 6 +- tests/Germany/ReformationDay2017Test.php | 10 ++- .../RhinelandPalatinate/AllSaintsDayTest.php | 7 +- .../RhinelandPalatinate/CorpusChristiTest.php | 6 +- .../RhinelandPalatinateTest.php | 13 +--- tests/Germany/Saarland/AllSaintsDayTest.php | 7 +- .../Germany/Saarland/AssumptionOfMaryTest.php | 7 +- tests/Germany/Saarland/CorpusChristiTest.php | 6 +- tests/Germany/Saarland/SaarlandTest.php | 13 +--- tests/Germany/Saxony/ReformationDayTest.php | 9 +-- .../Saxony/RepentanceAndPrayerDayTest.php | 8 +-- tests/Germany/Saxony/SaxonyTest.php | 13 +--- tests/Germany/SaxonyAnhalt/EpiphanyTest.php | 7 +- .../SaxonyAnhalt/ReformationDayTest.php | 9 +-- .../Germany/SaxonyAnhalt/SaxonyAnhaltTest.php | 13 +--- .../SchleswigHolstein/ReformationDayTest.php | 9 +-- .../SchleswigHolsteinTest.php | 13 +--- tests/Germany/SecondChristmasDayTest.php | 7 +- .../Germany/Thuringia/ReformationDayTest.php | 9 +-- tests/Germany/Thuringia/ThuringiaTest.php | 13 +--- .../Thuringia/WorldChildrensDayTest.php | 9 +-- tests/Greece/AnnunciationTest.php | 7 +- tests/Greece/AscensionDayTest.php | 6 +- tests/Greece/AssumptionOfMaryTest.php | 7 +- tests/Greece/ChristmasDayTest.php | 7 +- tests/Greece/CleanMondayTest.php | 6 +- tests/Greece/EasterMondayTest.php | 6 +- tests/Greece/EasterTest.php | 6 +- tests/Greece/EpiphanyTest.php | 7 +- tests/Greece/GreeceTest.php | 13 +--- tests/Greece/IndepencenceDayTest.php | 8 +-- tests/Greece/InternationalWorkersDayTest.php | 7 +- tests/Greece/NewYearsDayTest.php | 7 +- tests/Greece/OhiDayTest.php | 8 +-- tests/Greece/PentecostMondayTest.php | 6 +- tests/Greece/PentecostTest.php | 6 +- tests/Greece/PolytechnioTest.php | 8 +-- tests/Greece/ThreeHolyHierarchsTest.php | 7 +- tests/Greece/goodFridayTest.php | 6 +- tests/Hungary/AllSaintsDayTest.php | 7 +- tests/Hungary/ChristmasTest.php | 7 +- tests/Hungary/EasterMondayTest.php | 6 +- tests/Hungary/EasterTest.php | 6 +- tests/Hungary/HungaryTest.php | 13 +--- tests/Hungary/InternationalWorkersDayTest.php | 7 +- tests/Hungary/MemorialDay1848Test.php | 8 +-- tests/Hungary/MemorialDay1956Test.php | 8 +-- tests/Hungary/NewYearsDayTest.php | 7 +- tests/Hungary/PentecostMondayTest.php | 6 +- tests/Hungary/PentecostTest.php | 6 +- tests/Hungary/SecondChristmasDayTest.php | 7 +- tests/Hungary/StateFoundationDayTest.php | 8 +-- tests/Ireland/AugustHolidayTest.php | 6 +- tests/Ireland/ChristmasDayTest.php | 6 +- tests/Ireland/EasterMondayTest.php | 6 +- tests/Ireland/EasterTest.php | 6 +- tests/Ireland/GoodFridayTest.php | 6 +- tests/Ireland/IrelandTest.php | 13 +--- tests/Ireland/JuneHolidayTest.php | 8 +-- tests/Ireland/MayDayTest.php | 8 +-- tests/Ireland/NewYearsDayTest.php | 8 +-- tests/Ireland/OctoberHolidayTest.php | 8 +-- tests/Ireland/PentecostTest.php | 6 +- tests/Ireland/StPatricksDayTest.php | 8 +-- tests/Ireland/StStephensDayTest.php | 6 +- tests/Ireland/pentecostMondayTest.php | 8 +-- tests/Italy/AllSaintsDayTest.php | 7 +- tests/Italy/AssumptionOfMaryTest.php | 7 +- tests/Italy/ChristmasTest.php | 7 +- tests/Italy/EasterMondayTest.php | 6 +- tests/Italy/EasterTest.php | 6 +- tests/Italy/EpiphanyTest.php | 7 +- tests/Italy/ImmaculateConceptionTest.php | 7 +- tests/Italy/InternationalWorkersDayTest.php | 7 +- tests/Italy/ItalyTest.php | 13 +--- tests/Italy/LiberationDayTest.php | 8 +-- tests/Italy/NewYearsDayTest.php | 7 +- tests/Italy/RepublicDayTest.php | 8 +-- tests/Italy/stStephensDayTest.php | 7 +- tests/Japan/AutumnalEquinoxDayTest.php | 10 ++- tests/Japan/ChildrensDayTest.php | 9 +-- tests/Japan/ComingOfAgeDayTest.php | 9 +-- tests/Japan/ConstitutionMemorialDayTest.php | 9 +-- tests/Japan/CoronationDayTest.php | 10 +-- tests/Japan/CultureDayTest.php | 9 +-- tests/Japan/EmperorsBirthdayTest.php | 13 +--- .../EnthronementProclamationCeremonyTest.php | 10 +-- tests/Japan/GreeneryDayTest.php | 11 +-- tests/Japan/JapanTest.php | 15 +--- tests/Japan/LabourThanksgivingDayTest.php | 9 +-- tests/Japan/MarineDayTest.php | 11 +-- tests/Japan/MountainDayTest.php | 11 +-- tests/Japan/NationalFoundationDayTest.php | 9 +-- tests/Japan/NewYearsDayTest.php | 9 +-- tests/Japan/PublicBridgeDayTest.php | 6 -- tests/Japan/RespectForTheAgedDayTest.php | 10 +-- tests/Japan/ShowaDayTest.php | 9 +-- tests/Japan/SportsDayTest.php | 14 ++-- tests/Japan/VernalEquinoxDayTest.php | 10 ++- tests/Latvia/ChristmasDayTest.php | 7 +- tests/Latvia/ChristmasEveDayTest.php | 7 +- tests/Latvia/EasterDayTest.php | 6 +- tests/Latvia/EasterMondayDayTest.php | 6 +- tests/Latvia/GoodFridayDayTest.php | 6 +- tests/Latvia/InternationalWorkersDayTest.php | 7 +- tests/Latvia/LatviaTest.php | 11 +-- tests/Latvia/MidsummerEveDayTest.php | 7 +- tests/Latvia/NewYearsDayTest.php | 7 +- tests/Latvia/NewYearsEveDayTest.php | 7 +- ...oclamationOfTheRepublicOfLatviaDayTest.php | 8 +-- .../RestorationOfIndependenceDayTest.php | 8 +-- tests/Latvia/SecondChristmasDayTest.php | 7 +- tests/Latvia/StJohnsDayTest.php | 7 +- tests/Lithuania/AllSaintsDayTest.php | 7 +- tests/Lithuania/AllSoulsDayTest.php | 8 +-- tests/Lithuania/AssumptionOfMaryDayTest.php | 7 +- tests/Lithuania/ChristmasDayTest.php | 7 +- tests/Lithuania/ChristmasEveDayTest.php | 7 +- tests/Lithuania/EasterDayTest.php | 6 +- tests/Lithuania/EasterMondayDayTest.php | 6 +- .../Lithuania/InternationalWorkersDayTest.php | 7 +- tests/Lithuania/LithuaniaTest.php | 11 +-- tests/Lithuania/NewYearsDayTest.php | 7 +- ...rationOfIndependenceOfLithuaniaDayTest.php | 8 +-- ...estorationOfTheStateOfLithuaniaDayTest.php | 8 +-- tests/Lithuania/SecondChristmasDayTest.php | 7 +- tests/Lithuania/StJohnsDayTest.php | 7 +- tests/Lithuania/StatehoodDayTest.php | 8 +-- tests/Luxembourg/AllSaintsDayTest.php | 7 +- tests/Luxembourg/AscensionDayTest.php | 6 +- tests/Luxembourg/AssumptionOfMaryTest.php | 7 +- tests/Luxembourg/ChristmasDayTest.php | 7 +- tests/Luxembourg/EasterMondayTest.php | 6 +- tests/Luxembourg/EuropeDayTest.php | 8 +-- .../InternationalWorkersDayTest.php | 7 +- tests/Luxembourg/LuxembourgTest.php | 13 ++-- tests/Luxembourg/NationalDayTest.php | 7 +- tests/Luxembourg/NewYearsDayTest.php | 7 +- tests/Luxembourg/PentecostMondayTest.php | 6 +- tests/Luxembourg/SecondChristmasDayTest.php | 7 +- tests/Netherlands/AscensionDayTest.php | 6 +- tests/Netherlands/AshWednesdayTest.php | 6 +- tests/Netherlands/ChristmasDayTest.php | 7 +- tests/Netherlands/CommemorationDayTest.php | 8 +-- tests/Netherlands/EasterMondayTest.php | 6 +- tests/Netherlands/EasterTest.php | 6 +- tests/Netherlands/EpiphanyTest.php | 7 +- tests/Netherlands/FathersDayTest.php | 6 +- tests/Netherlands/GoodFridayTest.php | 6 +- tests/Netherlands/HalloweenTest.php | 7 +- .../InternationalWorkersDayTest.php | 7 +- tests/Netherlands/KingsDayTest.php | 9 +-- tests/Netherlands/LiberationDayTest.php | 8 +-- tests/Netherlands/MothersDayTest.php | 6 +- tests/Netherlands/NetherlandsTest.php | 15 ++-- tests/Netherlands/NewYearsDayTest.php | 7 +- tests/Netherlands/PentecostTest.php | 6 +- tests/Netherlands/QueensDayTest.php | 14 ++-- tests/Netherlands/SummertimeTest.php | 6 +- tests/Netherlands/ValentinesDayTest.php | 7 +- tests/Netherlands/WintertimeTest.php | 6 +- tests/Netherlands/WorldAnimalDayTest.php | 8 +-- tests/Netherlands/carnivalDayTest.php | 6 +- tests/Netherlands/pentecostMondayTest.php | 6 +- tests/Netherlands/princesDayTest.php | 6 +- tests/Netherlands/secondCarnivalDay.php | 6 +- tests/Netherlands/secondChristmasdayTest.php | 7 +- tests/Netherlands/stMartinsDayTest.php | 7 +- tests/Netherlands/stNicholasDayTest.php | 7 +- tests/Netherlands/thirdCarnivalDay.php | 6 +- tests/NewZealand/AnzacDayTest.php | 8 +-- tests/NewZealand/BoxingDayTest.php | 6 +- tests/NewZealand/ChristmasDayTest.php | 6 +- tests/NewZealand/DayAfterNewYearsDayTest.php | 6 +- tests/NewZealand/EasterMondayTest.php | 6 +- tests/NewZealand/GoodFridayTest.php | 6 +- tests/NewZealand/LabourDayTest.php | 8 +-- tests/NewZealand/NewYearsDayTest.php | 6 +- tests/NewZealand/NewZealandTest.php | 15 ++-- tests/NewZealand/QueensBirthdayTest.php | 9 +-- tests/NewZealand/WaitangiDayTest.php | 8 +-- tests/Norway/AscensionDayTest.php | 6 +- tests/Norway/ChristmasDayTest.php | 7 +- tests/Norway/ConstitutionDayTest.php | 8 +-- tests/Norway/EasterMondayTest.php | 6 +- tests/Norway/EasterTest.php | 6 +- tests/Norway/GoodFridayTest.php | 6 +- tests/Norway/InternationalWorkersDayTest.php | 7 +- tests/Norway/MaundyThursdayTest.php | 6 +- tests/Norway/NewYearsDayTest.php | 7 +- tests/Norway/NorwayTest.php | 13 +--- tests/Norway/PentecostMondayTest.php | 6 +- tests/Norway/PentecostTest.php | 6 +- tests/Norway/SecondChristmasDayTest.php | 7 +- tests/Poland/AllSaintsDayTest.php | 7 +- tests/Poland/AssumptionOfMaryTest.php | 7 +- tests/Poland/ChristmasTest.php | 7 +- tests/Poland/ConstitutionDayTest.php | 8 +-- tests/Poland/CorpusChristiTest.php | 6 +- tests/Poland/EasterMondayTest.php | 6 +- tests/Poland/EasterTest.php | 6 +- tests/Poland/EpiphanyTest.php | 7 +- tests/Poland/IndependenceDayTest.php | 8 +-- tests/Poland/InternationalWorkersDayTest.php | 7 +- tests/Poland/NewYearsDayTest.php | 7 +- tests/Poland/PentecostTest.php | 6 +- tests/Poland/PolandTest.php | 13 +--- tests/Poland/SecondChristmasDayTest.php | 7 +- tests/Portugal/AllSaintsDayTest.php | 10 +-- tests/Portugal/AssumptionOfMaryTest.php | 7 +- tests/Portugal/CarnationRevolutionDayTest.php | 8 +-- tests/Portugal/ChristmasTest.php | 7 +- tests/Portugal/CorpusChristiTest.php | 8 +-- tests/Portugal/EasterTest.php | 6 +- tests/Portugal/GoodFridayTest.php | 6 +- tests/Portugal/ImmaculateConceptionTest.php | 7 +- .../Portugal/InternationalWorkersDayTest.php | 7 +- tests/Portugal/NewYearsDayTest.php | 7 +- tests/Portugal/PortugalDayTest.php | 9 +-- tests/Portugal/PortugalTest.php | 13 +--- tests/Portugal/PortugueseRepublicDayTest.php | 71 ++++++++++--------- .../RestorationOfIndependenceTest.php | 14 ++-- tests/Romania/AssumptionOfMaryTest.php | 8 +-- tests/Romania/ChildrensDayTest.php | 8 +-- tests/Romania/ChristmasDayTest.php | 7 +- tests/Romania/ConstantinBrancusiDayTest.php | 8 +-- tests/Romania/DayAfterNewYearsDayTest.php | 7 +- tests/Romania/EasterMondayTest.php | 6 +- tests/Romania/EasterTest.php | 6 +- tests/Romania/InternationalWorkersDayTest.php | 7 +- tests/Romania/NationalDayTest.php | 10 +-- tests/Romania/NewYearsDayTest.php | 7 +- tests/Romania/PentecostMondayTest.php | 8 +-- tests/Romania/PentecostTest.php | 8 +-- tests/Romania/RomaniaTest.php | 13 +--- tests/Romania/SecondChristmasDayTest.php | 7 +- tests/Romania/StAndrewsDayTest.php | 8 +-- tests/Romania/UnitedPrincipalitiesDayTest.php | 8 +-- .../Russia/DefenceOfTheFatherlandDayTest.php | 8 +-- tests/Russia/InternationalWomensDayTest.php | 7 +- tests/Russia/NewYearHolidaysDay2Test.php | 7 +- tests/Russia/NewYearHolidaysDay3Test.php | 7 +- tests/Russia/NewYearHolidaysDay4Test.php | 7 +- tests/Russia/NewYearHolidaysDay5Test.php | 7 +- tests/Russia/NewYearHolidaysDay6Test.php | 7 +- tests/Russia/NewYearHolidaysDay8Test.php | 7 +- tests/Russia/NewYearsDayTest.php | 7 +- tests/Russia/OrthodoxChristmasDayTest.php | 7 +- tests/Russia/RussiaDayTest.php | 8 +-- tests/Russia/RussiaTest.php | 11 +-- tests/Russia/SpringAndLabourDayTest.php | 7 +- tests/Russia/UnityDayTest.php | 8 +-- tests/Russia/VictoryDayTest.php | 7 +- tests/Slovakia/AllSaintsDayTest.php | 7 +- tests/Slovakia/ChristmasDayTest.php | 7 +- tests/Slovakia/ChristmasEveTest.php | 7 +- tests/Slovakia/EasterMondayTest.php | 7 +- tests/Slovakia/EpiphanyTest.php | 7 +- tests/Slovakia/GoodFridayTest.php | 7 +- .../Slovakia/InternationalWorkersDayTest.php | 7 +- tests/Slovakia/OurLadyOfSorrowsDayTest.php | 7 +- .../SaintsCyrilAndMethodiusDayTest.php | 7 +- tests/Slovakia/SecondChristmasDayTest.php | 7 +- tests/Slovakia/SlovakConstitutionDayTest.php | 7 +- tests/Slovakia/SlovakIndependeceDayTest.php | 7 +- .../SlovakNationalUprisingDayTest.php | 7 +- tests/Slovakia/SlovakiaTest.php | 13 +--- .../StruggleForFreedomAndDemocracyDayTest.php | 7 +- tests/Slovakia/VictoryInEuropeDayTest.php | 7 +- tests/SouthAfrica/ChristmasDayTest.php | 8 +-- tests/SouthAfrica/FamilyDayTest.php | 8 +-- tests/SouthAfrica/FreedomDayTest.php | 8 +-- tests/SouthAfrica/GoodFridayTest.php | 8 +-- tests/SouthAfrica/HeritageDayTest.php | 8 +-- tests/SouthAfrica/HumanRightsDayTest.php | 8 +-- .../MunicipalElections2016DayTest.php | 10 ++- tests/SouthAfrica/NationalWomensDayTest.php | 8 +-- tests/SouthAfrica/NewYearsDayTest.php | 8 +-- tests/SouthAfrica/ReconciliationDayTest.php | 8 +-- tests/SouthAfrica/SecondChristmasDayTest.php | 8 +-- tests/SouthAfrica/SouthAfricaTest.php | 15 ++-- .../SubstituteDayOfGoodwillTest.php | 10 ++- tests/SouthAfrica/WorkersDayTest.php | 8 +-- tests/SouthAfrica/YouthDayTest.php | 8 +-- tests/SouthKorea/ArborDayTest.php | 10 ++- tests/SouthKorea/ArmedForcesDayTest.php | 10 ++- tests/SouthKorea/BuddhasBirthdayTest.php | 8 +-- tests/SouthKorea/ChildrensDayTest.php | 10 +-- tests/SouthKorea/ChristmasDayTest.php | 8 +-- tests/SouthKorea/ChuseokTest.php | 10 +-- tests/SouthKorea/ConstitutionDayTest.php | 10 ++- tests/SouthKorea/GaecheonjeolTest.php | 10 +-- tests/SouthKorea/HangulDayTest.php | 9 +-- .../IndependenceMovementDayTest.php | 9 +-- tests/SouthKorea/LiberationDayTest.php | 9 +-- tests/SouthKorea/MemorialDayTest.php | 8 +-- tests/SouthKorea/NewYearsDayTest.php | 10 ++- tests/SouthKorea/SeollalTest.php | 9 +-- tests/SouthKorea/SouthKoreaTest.php | 15 ++-- tests/Spain/AllSaintsDayTest.php | 7 +- tests/Spain/Andalusia/AndalusiaDayTest.php | 8 +-- tests/Spain/Andalusia/AndalusiaTest.php | 13 +--- tests/Spain/Aragon/AragonTest.php | 13 +--- tests/Spain/Aragon/StGeorgesDayTest.php | 6 +- tests/Spain/AssumptionOfMaryTest.php | 7 +- tests/Spain/Asturias/AsturiasDayTest.php | 8 +-- tests/Spain/Asturias/AsturiasTest.php | 13 +--- .../BalearicIslandsDayTest.php | 8 +-- .../BalearicIslands/BalearicIslandsTest.php | 13 +--- .../BasqueCountry/BasqueCountryDayTest.php | 10 ++- .../Spain/BasqueCountry/BasqueCountryTest.php | 13 +--- .../CanaryIslands/CanaryIslandsDayTest.php | 8 +-- .../Spain/CanaryIslands/CanaryIslandsTest.php | 13 +--- tests/Spain/Cantabria/CantabriaDayTest.php | 8 +-- tests/Spain/Cantabria/CantabriaTest.php | 13 +--- .../CastileAndLeon/CastileAndLeonDayTest.php | 8 +-- .../CastileAndLeon/CastileAndLeonTest.php | 13 +--- .../CastillaLaManchaDayTest.php | 8 +-- .../CastillaLaMancha/CastillaLaManchaTest.php | 13 +--- tests/Spain/Catalonia/CataloniaTest.php | 13 +--- .../Catalonia/nationalCataloniaDayTest.php | 8 +-- tests/Spain/Catalonia/stJohnsDayTest.php | 7 +- tests/Spain/Ceuta/CeutaTest.php | 13 +--- tests/Spain/Ceuta/ceutaDayTest.php | 8 +-- tests/Spain/ChristmasTest.php | 7 +- .../CommunityOfMadridTest.php | 13 +--- .../DosdeMayoUprisingDayTest.php | 6 +- tests/Spain/ConstitutionDayTest.php | 8 +-- tests/Spain/EasterMondayTest.php | 6 +- tests/Spain/EpiphanyTest.php | 7 +- .../Spain/Extremadura/ExtremaduraDayTest.php | 8 +-- tests/Spain/Extremadura/ExtremaduraTest.php | 13 +--- tests/Spain/Galicia/GaliciaTest.php | 13 +--- .../Galicia/GalicianLiteratureDayTest.php | 8 +-- tests/Spain/Galicia/stJamesDayTest.php | 8 +-- tests/Spain/GoodFridayTest.php | 6 +- tests/Spain/ImmaculateConceptionTest.php | 7 +- tests/Spain/InternationalWorkersDayTest.php | 7 +- tests/Spain/LaRioja/LaRiojaDayTest.php | 8 +-- tests/Spain/LaRioja/LaRiojaTest.php | 13 +--- tests/Spain/MaundyThursdayTest.php | 6 +- tests/Spain/Melilla/MelillaTest.php | 13 +--- tests/Spain/NationalDayTest.php | 8 +-- tests/Spain/Navarre/NavarreTest.php | 13 +--- tests/Spain/NewYearsDayTest.php | 7 +- .../RegionOfMurcia/RegionOfMurciaDayTest.php | 8 +-- .../RegionOfMurcia/RegionOfMurciaTest.php | 13 +--- tests/Spain/SpainTest.php | 13 +--- .../ValencianCommunityDayTest.php | 8 +-- .../ValencianCommunityTest.php | 13 +--- tests/Spain/ValentinesDayTest.php | 7 +- tests/Spain/stJosephsDayTest.php | 7 +- tests/Sweden/AllSaintsDayTest.php | 7 +- tests/Sweden/AllSaintsEveTest.php | 7 +- tests/Sweden/AscensionDayTest.php | 6 +- tests/Sweden/ChristmasDayTest.php | 7 +- tests/Sweden/ChristmasEveTest.php | 7 +- tests/Sweden/EasterMondayTest.php | 6 +- tests/Sweden/EasterTest.php | 6 +- tests/Sweden/EpiphanyEveTest.php | 7 +- tests/Sweden/EpiphanyTest.php | 7 +- tests/Sweden/GoodFridayTest.php | 6 +- tests/Sweden/InternationalWorkersDayTest.php | 7 +- tests/Sweden/NationalDayTest.php | 10 ++- tests/Sweden/NewYearsDayTest.php | 7 +- tests/Sweden/NewYearsEveTest.php | 7 +- tests/Sweden/PentecostTest.php | 6 +- tests/Sweden/SecondChristmasDayTest.php | 7 +- tests/Sweden/StJohnsDayTest.php | 7 +- tests/Sweden/StJohnsEveTest.php | 7 +- tests/Sweden/SwedenTest.php | 13 +--- tests/Sweden/WalpurgisEveTest.php | 7 +- tests/Switzerland/Aargau/AargauTest.php | 17 ++--- tests/Switzerland/Aargau/AscensionDayTest.php | 6 +- tests/Switzerland/Aargau/ChristmasDayTest.php | 7 +- tests/Switzerland/Aargau/GoodFridayTest.php | 6 +- tests/Switzerland/Aargau/NewYearsDayTest.php | 7 +- .../AppenzellAusserrhodenTest.php | 17 ++--- .../AscensionDayTest.php | 6 +- .../ChristmasDayTest.php | 7 +- .../EasterMondayTest.php | 6 +- .../AppenzellAusserrhoden/GoodFridayTest.php | 6 +- .../AppenzellAusserrhoden/NewYearsDayTest.php | 7 +- .../PentecostMondayTest.php | 6 +- .../StStephensDayTest.php | 7 +- .../AppenzellInnerrhoden/AllSaintsDayTest.php | 7 +- .../AppenzellInnerrhodenTest.php | 17 ++--- .../AppenzellInnerrhoden/AscensionDayTest.php | 6 +- .../AssumptionOfMaryTest.php | 7 +- .../AppenzellInnerrhoden/ChristmasDayTest.php | 7 +- .../CorpusChristiTest.php | 6 +- .../AppenzellInnerrhoden/EasterMondayTest.php | 6 +- .../AppenzellInnerrhoden/GoodFridayTest.php | 6 +- .../ImmaculateConceptionTest.php | 7 +- .../AppenzellInnerrhoden/NewYearsDayTest.php | 7 +- .../PentecostMondayTest.php | 6 +- .../StStephensDayTest.php | 7 +- .../BaselLandschaft/AscensionDayTest.php | 6 +- .../BaselLandschaft/BaselLandschaftTest.php | 17 ++--- .../BaselLandschaft/ChristmasDayTest.php | 7 +- .../BaselLandschaft/EasterMondayTest.php | 6 +- .../BaselLandschaft/GoodFridayTest.php | 6 +- .../BaselLandschaft/NewYearsDayTest.php | 7 +- .../BaselLandschaft/PentecostMondayTest.php | 6 +- .../BaselLandschaft/StStephensDayTest.php | 7 +- .../BaselLandschaft/WorkersDayTest.php | 6 +- .../BaselStadt/AscensionDayTest.php | 6 +- .../Switzerland/BaselStadt/BaselStadtTest.php | 17 ++--- .../BaselStadt/ChristmasDayTest.php | 7 +- .../BaselStadt/EasterMondayTest.php | 6 +- .../Switzerland/BaselStadt/GoodFridayTest.php | 6 +- .../BaselStadt/NewYearsDayTest.php | 7 +- .../BaselStadt/PentecostMondayTest.php | 6 +- .../BaselStadt/StStephensDayTest.php | 7 +- .../Switzerland/BaselStadt/WorkersDayTest.php | 6 +- tests/Switzerland/Bern/AscensionDayTest.php | 6 +- tests/Switzerland/Bern/BerchtoldsTagTest.php | 6 +- tests/Switzerland/Bern/BernTest.php | 17 ++--- tests/Switzerland/Bern/ChristmasDayTest.php | 7 +- tests/Switzerland/Bern/EasterMondayTest.php | 6 +- tests/Switzerland/Bern/GoodFridayTest.php | 6 +- tests/Switzerland/Bern/NewYearsDayTest.php | 7 +- .../Switzerland/Bern/PentecostMondayTest.php | 6 +- tests/Switzerland/Bern/StStephensDayTest.php | 7 +- .../Switzerland/Fribourg/AllSaintsDayTest.php | 7 +- .../Switzerland/Fribourg/AscensionDayTest.php | 6 +- .../Fribourg/AssumptionOfMaryTest.php | 7 +- .../Fribourg/BerchtoldsTagTest.php | 6 +- .../Switzerland/Fribourg/ChristmasDayTest.php | 7 +- .../Fribourg/CorpusChristiTest.php | 6 +- .../Switzerland/Fribourg/December26thTest.php | 6 +- .../Switzerland/Fribourg/EasterMondayTest.php | 6 +- tests/Switzerland/Fribourg/FribourgTest.php | 17 ++--- tests/Switzerland/Fribourg/GoodFridayTest.php | 6 +- .../Fribourg/ImmaculateConceptionTest.php | 7 +- .../Switzerland/Fribourg/NewYearsDayTest.php | 7 +- .../Fribourg/PentecostMondayTest.php | 6 +- tests/Switzerland/Geneva/AscensionDayTest.php | 6 +- tests/Switzerland/Geneva/ChristmasDayTest.php | 7 +- tests/Switzerland/Geneva/EasterMondayTest.php | 6 +- tests/Switzerland/Geneva/GenevaTest.php | 17 ++--- tests/Switzerland/Geneva/GoodFridayTest.php | 6 +- .../Switzerland/Geneva/JeuneGenevoisTest.php | 9 +-- tests/Switzerland/Geneva/NewYearsDayTest.php | 7 +- .../Geneva/PentecostMondayTest.php | 6 +- .../Geneva/RestaurationGenevoiseTest.php | 6 +- tests/Switzerland/Glarus/AllSaintsDayTest.php | 7 +- tests/Switzerland/Glarus/AscensionDayTest.php | 6 +- .../Switzerland/Glarus/BerchtoldsTagTest.php | 6 +- tests/Switzerland/Glarus/ChristmasDayTest.php | 7 +- tests/Switzerland/Glarus/EasterMondayTest.php | 6 +- tests/Switzerland/Glarus/GlarusTest.php | 17 ++--- tests/Switzerland/Glarus/GoodFridayTest.php | 6 +- .../Switzerland/Glarus/NafelserFahrtTest.php | 8 +-- tests/Switzerland/Glarus/NewYearsDayTest.php | 7 +- .../Glarus/PentecostMondayTest.php | 6 +- .../Switzerland/Glarus/StStephensDayTest.php | 7 +- .../Switzerland/Grisons/AscensionDayTest.php | 6 +- .../Switzerland/Grisons/ChristmasDayTest.php | 7 +- .../Switzerland/Grisons/EasterMondayTest.php | 6 +- tests/Switzerland/Grisons/GoodFridayTest.php | 6 +- tests/Switzerland/Grisons/GrisonsTest.php | 17 ++--- tests/Switzerland/Grisons/NewYearsDayTest.php | 7 +- .../Grisons/PentecostMondayTest.php | 6 +- .../Switzerland/Grisons/StStephensDayTest.php | 7 +- tests/Switzerland/Jura/AllSaintsDayTest.php | 7 +- tests/Switzerland/Jura/AscensionDayTest.php | 6 +- .../Switzerland/Jura/AssumptionOfMaryTest.php | 7 +- tests/Switzerland/Jura/BerchtoldsTagTest.php | 6 +- tests/Switzerland/Jura/BettagsMontagTest.php | 8 +-- tests/Switzerland/Jura/ChristmasDayTest.php | 7 +- tests/Switzerland/Jura/CorpusChristiTest.php | 6 +- tests/Switzerland/Jura/EasterMondayTest.php | 6 +- tests/Switzerland/Jura/EasterTest.php | 6 +- tests/Switzerland/Jura/GoodFridayTest.php | 6 +- tests/Switzerland/Jura/JuraTest.php | 17 ++--- tests/Switzerland/Jura/NewYearsDayTest.php | 7 +- .../Switzerland/Jura/PentecostMondayTest.php | 6 +- tests/Switzerland/Jura/PentecostTest.php | 6 +- .../Jura/PlebisciteJurassienTest.php | 8 +-- tests/Switzerland/Jura/WorkersDayTest.php | 6 +- .../Switzerland/Lucerne/AllSaintsDayTest.php | 7 +- .../Switzerland/Lucerne/AscensionDayTest.php | 6 +- .../Lucerne/AssumptionOfMaryTest.php | 7 +- .../Switzerland/Lucerne/BerchtoldsTagTest.php | 6 +- .../Switzerland/Lucerne/ChristmasDayTest.php | 7 +- .../Switzerland/Lucerne/CorpusChristiTest.php | 6 +- .../Switzerland/Lucerne/EasterMondayTest.php | 6 +- tests/Switzerland/Lucerne/GoodFridayTest.php | 6 +- .../Lucerne/ImmaculateConceptionTest.php | 7 +- tests/Switzerland/Lucerne/LucerneTest.php | 17 ++--- tests/Switzerland/Lucerne/NewYearsDayTest.php | 7 +- .../Lucerne/PentecostMondayTest.php | 6 +- .../Switzerland/Lucerne/StStephensDayTest.php | 7 +- .../Neuchatel/AscensionDayTest.php | 6 +- .../Neuchatel/BettagsMontagTest.php | 8 +-- .../Neuchatel/ChristmasDayTest.php | 7 +- .../Neuchatel/December26thTest.php | 6 -- .../Neuchatel/EasterMondayTest.php | 6 +- .../Switzerland/Neuchatel/GoodFridayTest.php | 6 +- .../Neuchatel/InstaurationRepubliqueTest.php | 8 +-- .../Switzerland/Neuchatel/January2ndTest.php | 6 -- tests/Switzerland/Neuchatel/NeuchatelTest.php | 17 ++--- .../Switzerland/Neuchatel/NewYearsDayTest.php | 7 +- .../Neuchatel/PentecostMondayTest.php | 6 +- .../Switzerland/Neuchatel/WorkersDayTest.php | 6 +- .../Nidwalden/AllSaintsDayTest.php | 7 +- .../Nidwalden/AscensionDayTest.php | 6 +- .../Nidwalden/AssumptionOfMaryTest.php | 7 +- .../Nidwalden/ChristmasDayTest.php | 7 +- .../Nidwalden/CorpusChristiTest.php | 6 +- .../Nidwalden/EasterMondayTest.php | 6 +- .../Switzerland/Nidwalden/GoodFridayTest.php | 6 +- .../Nidwalden/ImmaculateConceptionTest.php | 7 +- .../Switzerland/Nidwalden/NewYearsDayTest.php | 7 +- tests/Switzerland/Nidwalden/NidwaldenTest.php | 17 ++--- .../Nidwalden/PentecostMondayTest.php | 6 +- .../Switzerland/Nidwalden/StJosephDayTest.php | 7 +- .../Nidwalden/StStephensDayTest.php | 7 +- .../Switzerland/Obwalden/AllSaintsDayTest.php | 7 +- .../Switzerland/Obwalden/AscensionDayTest.php | 6 +- .../Obwalden/AssumptionOfMaryTest.php | 7 +- .../Obwalden/BerchtoldsTagTest.php | 6 +- .../Obwalden/BruderKlausenFestTest.php | 9 +-- .../Switzerland/Obwalden/ChristmasDayTest.php | 7 +- .../Obwalden/CorpusChristiTest.php | 6 +- .../Switzerland/Obwalden/EasterMondayTest.php | 6 +- tests/Switzerland/Obwalden/GoodFridayTest.php | 6 +- .../Obwalden/ImmaculateConceptionTest.php | 7 +- .../Switzerland/Obwalden/NewYearsDayTest.php | 7 +- tests/Switzerland/Obwalden/ObwaldenTest.php | 17 ++--- .../Obwalden/PentecostMondayTest.php | 6 +- .../Obwalden/StStephensDayTest.php | 7 +- .../Schaffhausen/AscensionDayTest.php | 6 +- .../Schaffhausen/BerchtoldsTagTest.php | 6 +- .../Schaffhausen/ChristmasDayTest.php | 7 +- .../Schaffhausen/EasterMondayTest.php | 6 +- .../Schaffhausen/GoodFridayTest.php | 6 +- .../Schaffhausen/NewYearsDayTest.php | 7 +- .../Schaffhausen/PentecostMondayTest.php | 6 +- .../Schaffhausen/SchaffhausenTest.php | 17 ++--- .../Schaffhausen/StStephensDayTest.php | 7 +- .../Schaffhausen/WorkersDayTest.php | 6 +- tests/Switzerland/Schwyz/AllSaintsDayTest.php | 7 +- tests/Switzerland/Schwyz/AscensionDayTest.php | 6 +- .../Schwyz/AssumptionOfMaryTest.php | 7 +- tests/Switzerland/Schwyz/ChristmasDayTest.php | 7 +- .../Switzerland/Schwyz/CorpusChristiTest.php | 6 +- tests/Switzerland/Schwyz/EasterMondayTest.php | 6 +- tests/Switzerland/Schwyz/EpiphanyTest.php | 7 +- tests/Switzerland/Schwyz/GoodFridayTest.php | 6 +- .../Schwyz/ImmaculateConceptionTest.php | 7 +- tests/Switzerland/Schwyz/NewYearsDayTest.php | 7 +- .../Schwyz/PentecostMondayTest.php | 6 +- tests/Switzerland/Schwyz/SchwyzTest.php | 17 ++--- tests/Switzerland/Schwyz/StJosephDayTest.php | 7 +- .../Switzerland/Schwyz/StStephensDayTest.php | 7 +- .../Solothurn/AscensionDayTest.php | 6 +- .../Solothurn/BerchtoldsTagTest.php | 6 +- .../Solothurn/ChristmasDayTest.php | 7 +- .../Switzerland/Solothurn/GoodFridayTest.php | 6 +- .../Switzerland/Solothurn/NewYearsDayTest.php | 7 +- tests/Switzerland/Solothurn/SolothurnTest.php | 17 ++--- .../Switzerland/StGallen/AllSaintsDayTest.php | 7 +- .../Switzerland/StGallen/AscensionDayTest.php | 6 +- .../Switzerland/StGallen/ChristmasDayTest.php | 7 +- .../Switzerland/StGallen/EasterMondayTest.php | 6 +- tests/Switzerland/StGallen/GoodFridayTest.php | 6 +- .../Switzerland/StGallen/NewYearsDayTest.php | 7 +- .../StGallen/PentecostMondayTest.php | 6 +- tests/Switzerland/StGallen/StGallenTest.php | 17 ++--- .../StGallen/StStephensDayTest.php | 7 +- tests/Switzerland/SwissNationalDayTest.php | 14 ++-- tests/Switzerland/SwitzerlandTest.php | 15 ++-- .../Switzerland/Thurgau/AscensionDayTest.php | 6 +- .../Switzerland/Thurgau/BerchtoldsTagTest.php | 6 +- .../Switzerland/Thurgau/ChristmasDayTest.php | 7 +- .../Switzerland/Thurgau/EasterMondayTest.php | 6 +- tests/Switzerland/Thurgau/GoodFridayTest.php | 6 +- tests/Switzerland/Thurgau/NewYearsDayTest.php | 7 +- .../Thurgau/PentecostMondayTest.php | 6 +- .../Switzerland/Thurgau/StStephensDayTest.php | 7 +- tests/Switzerland/Thurgau/ThurgauTest.php | 17 ++--- tests/Switzerland/Thurgau/WorkersDayTest.php | 6 +- tests/Switzerland/Ticino/AllSaintsDayTest.php | 7 +- tests/Switzerland/Ticino/AscensionDayTest.php | 6 +- .../Ticino/AssumptionOfMaryTest.php | 7 +- tests/Switzerland/Ticino/ChristmasDayTest.php | 7 +- .../Switzerland/Ticino/CorpusChristiTest.php | 6 +- tests/Switzerland/Ticino/EasterMondayTest.php | 6 +- tests/Switzerland/Ticino/EpiphanyTest.php | 7 +- .../Ticino/ImmaculateConceptionTest.php | 7 +- tests/Switzerland/Ticino/NewYearsDayTest.php | 7 +- .../Ticino/PentecostMondayTest.php | 6 +- tests/Switzerland/Ticino/StJosephDayTest.php | 7 +- tests/Switzerland/Ticino/StPeterPaulTest.php | 7 +- .../Switzerland/Ticino/StStephensDayTest.php | 7 +- tests/Switzerland/Ticino/TicinoTest.php | 17 ++--- tests/Switzerland/Ticino/WorkersDayTest.php | 6 +- tests/Switzerland/Uri/AllSaintsDayTest.php | 7 +- tests/Switzerland/Uri/AscensionDayTest.php | 6 +- .../Switzerland/Uri/AssumptionOfMaryTest.php | 7 +- tests/Switzerland/Uri/ChristmasDayTest.php | 7 +- tests/Switzerland/Uri/CorpusChristiTest.php | 6 +- tests/Switzerland/Uri/EasterMondayTest.php | 6 +- tests/Switzerland/Uri/EpiphanyTest.php | 7 +- tests/Switzerland/Uri/GoodFridayTest.php | 6 +- .../Uri/ImmaculateConceptionTest.php | 7 +- tests/Switzerland/Uri/NewYearsDayTest.php | 7 +- tests/Switzerland/Uri/PentecostMondayTest.php | 6 +- tests/Switzerland/Uri/StJosephDayTest.php | 7 +- tests/Switzerland/Uri/StStephensDayTest.php | 7 +- tests/Switzerland/Uri/UriTest.php | 17 ++--- tests/Switzerland/Valais/AllSaintsDayTest.php | 7 +- tests/Switzerland/Valais/AscensionDayTest.php | 6 +- .../Valais/AssumptionOfMaryTest.php | 7 +- tests/Switzerland/Valais/ChristmasDayTest.php | 7 +- .../Switzerland/Valais/CorpusChristiTest.php | 6 +- .../Valais/ImmaculateConceptionTest.php | 7 +- tests/Switzerland/Valais/NewYearsDayTest.php | 7 +- tests/Switzerland/Valais/StJosephDayTest.php | 7 +- tests/Switzerland/Valais/ValaisTest.php | 17 ++--- tests/Switzerland/Vaud/AscensionDayTest.php | 6 +- tests/Switzerland/Vaud/BerchtoldsTagTest.php | 6 +- tests/Switzerland/Vaud/BettagsMontagTest.php | 8 +-- tests/Switzerland/Vaud/ChristmasDayTest.php | 7 +- tests/Switzerland/Vaud/EasterMondayTest.php | 6 +- tests/Switzerland/Vaud/GoodFridayTest.php | 6 +- tests/Switzerland/Vaud/NewYearsDayTest.php | 7 +- .../Switzerland/Vaud/PentecostMondayTest.php | 6 +- tests/Switzerland/Vaud/VaudTest.php | 17 ++--- tests/Switzerland/Zug/AllSaintsDayTest.php | 7 +- tests/Switzerland/Zug/AscensionDayTest.php | 6 +- .../Switzerland/Zug/AssumptionOfMaryTest.php | 7 +- tests/Switzerland/Zug/BerchtoldsTagTest.php | 6 +- tests/Switzerland/Zug/ChristmasDayTest.php | 7 +- tests/Switzerland/Zug/CorpusChristiTest.php | 6 +- tests/Switzerland/Zug/EasterMondayTest.php | 6 +- tests/Switzerland/Zug/GoodFridayTest.php | 6 +- .../Zug/ImmaculateConceptionTest.php | 7 +- tests/Switzerland/Zug/NewYearsDayTest.php | 7 +- tests/Switzerland/Zug/PentecostMondayTest.php | 6 +- tests/Switzerland/Zug/StStephensDayTest.php | 7 +- tests/Switzerland/Zug/ZugTest.php | 17 ++--- tests/Switzerland/Zurich/AscensionDayTest.php | 6 +- tests/Switzerland/Zurich/ChristmasDayTest.php | 7 +- tests/Switzerland/Zurich/EasterMondayTest.php | 6 +- tests/Switzerland/Zurich/GoodFridayTest.php | 6 +- tests/Switzerland/Zurich/NewYearsDayTest.php | 7 +- .../Zurich/PentecostMondayTest.php | 6 +- .../Switzerland/Zurich/StStephensDayTest.php | 7 +- tests/Switzerland/Zurich/WorkersDayTest.php | 6 +- tests/Switzerland/Zurich/ZurichTest.php | 17 ++--- tests/Turkey/CommemorationOfAtaturkTest.php | 8 +-- tests/Turkey/DemocracyDayTest.php | 9 ++- tests/Turkey/LabourDayTest.php | 7 +- tests/Turkey/NationalSovereigntyDayTest.php | 10 ++- tests/Turkey/NewYearsDayTest.php | 7 +- tests/Turkey/RepublicDayTest.php | 9 ++- tests/Turkey/TurkeyTest.php | 19 ++--- tests/Turkey/VictoryDayTest.php | 11 ++- tests/USA/ChristmasDayTest.php | 8 +-- tests/USA/ColumbusDayTest.php | 9 +-- tests/USA/IndependenceDayTest.php | 10 +-- tests/USA/JuneteenthTest.php | 10 +-- tests/USA/LabourDayTest.php | 8 +-- tests/USA/MartinLutherKingDayTest.php | 8 +-- tests/USA/MemorialDayTest.php | 9 +-- tests/USA/NewYearsDayTest.php | 8 +-- tests/USA/ThanksgivingDayTest.php | 8 +-- tests/USA/USATest.php | 13 +--- tests/USA/VeteransDayTest.php | 22 +++--- tests/USA/WashingtonsBirthdayTest.php | 9 +-- tests/Ukraine/CatholicChristmasDayTest.php | 9 +-- tests/Ukraine/ChristmasDayTest.php | 7 +- tests/Ukraine/ConstitutionDayTest.php | 6 -- tests/Ukraine/DefenderOfUkraineDayTest.php | 6 -- tests/Ukraine/EasterTest.php | 6 +- tests/Ukraine/IndependenceDayTest.php | 6 -- tests/Ukraine/InternationalWomensDayTest.php | 7 +- tests/Ukraine/InternationalWorkersDayTest.php | 7 +- tests/Ukraine/NewYearsDayTest.php | 7 +- tests/Ukraine/PentecostTest.php | 6 +- .../SecondInternationalWorkersDayTest.php | 9 +-- tests/Ukraine/SubstitutedHolidayTest.php | 2 - tests/Ukraine/UkraineTest.php | 13 +--- tests/Ukraine/VictoryDayTest.php | 7 +- tests/UnitedKingdom/BoxingDayTest.php | 6 +- tests/UnitedKingdom/ChristmasDayTest.php | 6 +- tests/UnitedKingdom/EasterMondayTest.php | 6 +- tests/UnitedKingdom/England/BoxingDayTest.php | 6 +- .../England/ChristmasDayTest.php | 6 +- .../England/EasterMondayTest.php | 6 +- tests/UnitedKingdom/England/EnglandTest.php | 15 ++-- .../UnitedKingdom/England/GoodFridayTest.php | 6 +- .../England/MayDayBankHolidayTest.php | 9 +-- .../UnitedKingdom/England/NewYearsDayTest.php | 10 ++- .../England/SpringBankHolidayTest.php | 9 +-- .../England/SummerBankHolidayTest.php | 11 ++- tests/UnitedKingdom/GoodFridayTest.php | 6 +- tests/UnitedKingdom/MayDayBankHolidayTest.php | 9 +-- tests/UnitedKingdom/MotheringSundayTest.php | 6 +- tests/UnitedKingdom/NewYearsDayTest.php | 10 ++- .../NorthernIreland/BattleOfTheBoyneTest.php | 8 +-- .../NorthernIreland/BoxingDayTest.php | 6 +- .../NorthernIreland/ChristmasDayTest.php | 6 +- .../NorthernIreland/EasterMondayTest.php | 6 +- .../NorthernIreland/GoodFridayTest.php | 6 +- .../NorthernIreland/MayDayBankHolidayTest.php | 9 +-- .../NorthernIreland/NewYearsDayTest.php | 10 ++- .../NorthernIreland/NorthernIrelandTest.php | 15 ++-- .../NorthernIreland/SpringBankHolidayTest.php | 8 +-- .../NorthernIreland/StPatricksDayTest.php | 8 +-- .../NorthernIreland/SummerBankHolidayTest.php | 12 ++-- .../PlatinumJubileeBankHolidayTest.php | 10 +-- .../UnitedKingdom/Scotland/BoxingDayTest.php | 6 +- .../Scotland/ChristmasDayTest.php | 6 +- .../UnitedKingdom/Scotland/GoodFridayTest.php | 6 +- .../Scotland/MayDayBankHolidayTest.php | 9 +-- .../Scotland/NewYearsDayTest.php | 10 ++- tests/UnitedKingdom/Scotland/ScotlandTest.php | 15 ++-- .../Scotland/SecondNewYearsDayTest.php | 10 ++- .../Scotland/SpringBankHolidayTest.php | 8 +-- .../Scotland/StAndrewsDayTest.php | 6 +- .../Scotland/SummerBankHolidayTest.php | 8 +-- tests/UnitedKingdom/SpringBankHolidayTest.php | 9 +-- tests/UnitedKingdom/SummerBankHolidayTest.php | 12 ++-- tests/UnitedKingdom/UnitedKingdomTest.php | 15 ++-- tests/UnitedKingdom/Wales/BoxingDayTest.php | 6 +- .../UnitedKingdom/Wales/ChristmasDayTest.php | 6 +- .../UnitedKingdom/Wales/EasterMondayTest.php | 6 +- tests/UnitedKingdom/Wales/GoodFridayTest.php | 6 +- .../Wales/MayDayBankHolidayTest.php | 9 +-- tests/UnitedKingdom/Wales/NewYearsDayTest.php | 10 ++- .../Wales/SpringBankHolidayTest.php | 9 +-- .../Wales/SummerBankHolidayTest.php | 12 ++-- tests/UnitedKingdom/Wales/WalesTest.php | 15 ++-- tests/YasumiBase.php | 14 ++-- 1069 files changed, 2615 insertions(+), 5868 deletions(-) diff --git a/tests/Argentina/ArgentinaTest.php b/tests/Argentina/ArgentinaTest.php index 6fb7983a0..8b0fd47ce 100644 --- a/tests/Argentina/ArgentinaTest.php +++ b/tests/Argentina/ArgentinaTest.php @@ -14,7 +14,6 @@ namespace Yasumi\tests\Argentina; -use ReflectionException; use Yasumi\Holiday; use Yasumi\Provider\Argentina; use Yasumi\tests\ProviderTestCase; @@ -31,6 +30,8 @@ class ArgentinaTest extends ArgentinaBaseTestCase implements ProviderTestCase /** * Initial setup of this Test Case. + * + * @throws \Exception */ protected function setUp(): void { @@ -39,8 +40,6 @@ protected function setUp(): void /** * Tests if all official holidays in Argentina are defined by the provider class. - * - * @throws ReflectionException */ public function testOfficialHolidays(): void { @@ -71,8 +70,6 @@ public function testOfficialHolidays(): void /** * Tests if all observed holidays in Argentina are defined by the provider class. - * - * @throws ReflectionException */ public function testObservedHolidays(): void { @@ -84,9 +81,7 @@ public function testObservedHolidays(): void ], self::REGION, $this->year, Holiday::TYPE_OBSERVANCE); } - /** - * @throws ReflectionException - */ + /** @throws \Exception */ public function testSources(): void { $this->assertSources(self::REGION, 1); diff --git a/tests/Argentina/CarnavalMondayTest.php b/tests/Argentina/CarnavalMondayTest.php index d8b1aad25..870ab79be 100644 --- a/tests/Argentina/CarnavalMondayTest.php +++ b/tests/Argentina/CarnavalMondayTest.php @@ -16,7 +16,6 @@ use DateInterval; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\Provider\ChristianHolidays; use Yasumi\tests\HolidayTestCase; @@ -42,7 +41,6 @@ class CarnavalMondayTest extends ArgentinaBaseTestCase implements HolidayTestCas * Tests Carnaval Monday on or after 1700. * * @throws Exception - * @throws ReflectionException */ public function testCarnavalMondayAfter1700(): void { @@ -58,7 +56,7 @@ public function testCarnavalMondayAfter1700(): void /** * Tests Carnaval Monday on or before 1700. * - * @throws ReflectionException + * @throws Exception */ public function testCarnavalMondayBefore1700(): void { @@ -69,7 +67,7 @@ public function testCarnavalMondayBefore1700(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -80,7 +78,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Argentina/CarnavalTuesdayTest.php b/tests/Argentina/CarnavalTuesdayTest.php index d510bf5ec..25b5b6493 100644 --- a/tests/Argentina/CarnavalTuesdayTest.php +++ b/tests/Argentina/CarnavalTuesdayTest.php @@ -16,7 +16,6 @@ use DateInterval; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\Provider\ChristianHolidays; use Yasumi\tests\HolidayTestCase; @@ -42,7 +41,6 @@ class CarnavalTuesdayTest extends ArgentinaBaseTestCase implements HolidayTestCa * Tests Carnaval Tuesday on or after 1700. * * @throws Exception - * @throws ReflectionException */ public function testCarnavalTuesdayAfter1700(): void { @@ -58,7 +56,7 @@ public function testCarnavalTuesdayAfter1700(): void /** * Tests Carnaval Tuesday on or before 1700. * - * @throws ReflectionException + * @throws Exception */ public function testCarnavalTuesdayBefore1700(): void { @@ -69,7 +67,7 @@ public function testCarnavalTuesdayBefore1700(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -80,7 +78,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Argentina/ChristmasDayTest.php b/tests/Argentina/ChristmasDayTest.php index 2d120a733..52070ad1a 100644 --- a/tests/Argentina/ChristmasDayTest.php +++ b/tests/Argentina/ChristmasDayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -35,7 +34,6 @@ class ChristmasDayTest extends ArgentinaBaseTestCase implements HolidayTestCase * Tests Christmas Day. * * @throws Exception - * @throws ReflectionException */ public function testChristmasDay(): void { @@ -51,7 +49,7 @@ public function testChristmasDay(): void /** * Tests translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -66,7 +64,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Argentina/EasterTest.php b/tests/Argentina/EasterTest.php index 67c0cea68..e6527630a 100644 --- a/tests/Argentina/EasterTest.php +++ b/tests/Argentina/EasterTest.php @@ -15,7 +15,6 @@ namespace Yasumi\tests\Argentina; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\Provider\ChristianHolidays; use Yasumi\tests\HolidayTestCase; @@ -36,7 +35,6 @@ class EasterTest extends ArgentinaBaseTestCase implements HolidayTestCase * Tests Easter. * * @throws Exception - * @throws ReflectionException */ public function testEaster(): void { @@ -47,7 +45,7 @@ public function testEaster(): void /** * Tests translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -62,7 +60,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Argentina/FlagDayTest.php b/tests/Argentina/FlagDayTest.php index 65f4a0afd..fbe826af2 100644 --- a/tests/Argentina/FlagDayTest.php +++ b/tests/Argentina/FlagDayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -40,7 +39,6 @@ class FlagDayTest extends ArgentinaBaseTestCase implements HolidayTestCase * Tests the holiday defined in this test. * * @throws Exception - * @throws ReflectionException */ public function testHoliday(): void { @@ -55,8 +53,6 @@ public function testHoliday(): void /** * Tests that holiday is not present before establishment year. - * - * @throws ReflectionException */ public function testNotHoliday(): void { @@ -66,7 +62,7 @@ public function testNotHoliday(): void /** * Tests translated name of the holiday. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -81,7 +77,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Argentina/GeneralJoseSanMartinDayTest.php b/tests/Argentina/GeneralJoseSanMartinDayTest.php index 458afa5d1..66d4c3fe2 100644 --- a/tests/Argentina/GeneralJoseSanMartinDayTest.php +++ b/tests/Argentina/GeneralJoseSanMartinDayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -40,7 +39,6 @@ class GeneralJoseSanMartinDayTest extends ArgentinaBaseTestCase implements Holid * Tests the holiday defined in this test. * * @throws Exception - * @throws ReflectionException */ public function testHoliday(): void { @@ -55,8 +53,6 @@ public function testHoliday(): void /** * Tests that holiday is not present before establishment year. - * - * @throws ReflectionException */ public function testNotHoliday(): void { @@ -66,7 +62,7 @@ public function testNotHoliday(): void /** * Tests translated name of the holiday. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -81,7 +77,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Argentina/GeneralMartinMigueldeGuemesDayTest.php b/tests/Argentina/GeneralMartinMigueldeGuemesDayTest.php index 648eaa108..119c45c1c 100644 --- a/tests/Argentina/GeneralMartinMigueldeGuemesDayTest.php +++ b/tests/Argentina/GeneralMartinMigueldeGuemesDayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -40,7 +39,6 @@ class GeneralMartinMigueldeGuemesDayTest extends ArgentinaBaseTestCase implement * Tests the holiday defined in this test. * * @throws Exception - * @throws ReflectionException */ public function testHoliday(): void { @@ -55,8 +53,6 @@ public function testHoliday(): void /** * Tests that holiday is not present before establishment year. - * - * @throws ReflectionException */ public function testNotHoliday(): void { @@ -66,7 +62,7 @@ public function testNotHoliday(): void /** * Tests translated name of the holiday. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -81,7 +77,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Argentina/GoodFridayTest.php b/tests/Argentina/GoodFridayTest.php index 8c4f95eea..fbe4b4ea6 100644 --- a/tests/Argentina/GoodFridayTest.php +++ b/tests/Argentina/GoodFridayTest.php @@ -16,7 +16,6 @@ use DateInterval; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\Provider\ChristianHolidays; use Yasumi\tests\HolidayTestCase; @@ -37,7 +36,6 @@ class GoodFridayTest extends ArgentinaBaseTestCase implements HolidayTestCase * Tests Good Friday. * * @throws Exception - * @throws ReflectionException */ public function testGoodFriday(): void { @@ -53,7 +51,7 @@ public function testGoodFriday(): void /** * Tests translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -68,7 +66,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Argentina/ImmaculateConceptionDayTest.php b/tests/Argentina/ImmaculateConceptionDayTest.php index ce495970d..94142b054 100644 --- a/tests/Argentina/ImmaculateConceptionDayTest.php +++ b/tests/Argentina/ImmaculateConceptionDayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -40,7 +39,6 @@ class ImmaculateConceptionDayTest extends ArgentinaBaseTestCase implements Holid * Tests the holiday defined in this test. * * @throws Exception - * @throws ReflectionException */ public function testHoliday(): void { @@ -55,8 +53,6 @@ public function testHoliday(): void /** * Tests that holiday is not present before establishment year. - * - * @throws ReflectionException */ public function testNotHoliday(): void { @@ -66,7 +62,7 @@ public function testNotHoliday(): void /** * Tests translated name of the holiday. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -81,7 +77,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Argentina/IndependenceDayTest.php b/tests/Argentina/IndependenceDayTest.php index 7a4a375f6..c187f2f61 100644 --- a/tests/Argentina/IndependenceDayTest.php +++ b/tests/Argentina/IndependenceDayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -40,7 +39,6 @@ class IndependenceDayTest extends ArgentinaBaseTestCase implements HolidayTestCa * Tests the holiday defined in this test. * * @throws Exception - * @throws ReflectionException */ public function testHoliday(): void { @@ -55,8 +53,6 @@ public function testHoliday(): void /** * Tests that holiday is not present before establishment year. - * - * @throws ReflectionException */ public function testNotHoliday(): void { @@ -66,7 +62,7 @@ public function testNotHoliday(): void /** * Tests translated name of the holiday. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -81,7 +77,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Argentina/InternationalWorkersDayTest.php b/tests/Argentina/InternationalWorkersDayTest.php index 346ab0438..c2e7baf2e 100644 --- a/tests/Argentina/InternationalWorkersDayTest.php +++ b/tests/Argentina/InternationalWorkersDayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -35,7 +34,6 @@ class InternationalWorkersDayTest extends ArgentinaBaseTestCase implements Holid * Tests International Workers' Day. * * @throws Exception - * @throws ReflectionException */ public function testInternationalWorkersDay(): void { @@ -51,7 +49,7 @@ public function testInternationalWorkersDay(): void /** * Tests translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -66,7 +64,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Argentina/MalvinasDayTest.php b/tests/Argentina/MalvinasDayTest.php index af91840c6..14ff33536 100644 --- a/tests/Argentina/MalvinasDayTest.php +++ b/tests/Argentina/MalvinasDayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -40,7 +39,6 @@ class MalvinasDayTest extends ArgentinaBaseTestCase implements HolidayTestCase * Tests the holiday defined in this test. * * @throws Exception - * @throws ReflectionException */ public function testHoliday(): void { @@ -55,8 +53,6 @@ public function testHoliday(): void /** * Tests that holiday is not present before establishment year. - * - * @throws ReflectionException */ public function testNotHoliday(): void { @@ -66,7 +62,7 @@ public function testNotHoliday(): void /** * Tests translated name of Malvinas Day. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -81,7 +77,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Argentina/MayRevolutionTest.php b/tests/Argentina/MayRevolutionTest.php index e5e7bd335..95a7a75f9 100644 --- a/tests/Argentina/MayRevolutionTest.php +++ b/tests/Argentina/MayRevolutionTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -40,7 +39,6 @@ class MayRevolutionTest extends ArgentinaBaseTestCase implements HolidayTestCase * Tests the holiday defined in this test. * * @throws Exception - * @throws ReflectionException */ public function testHoliday(): void { @@ -55,8 +53,6 @@ public function testHoliday(): void /** * Tests that holiday is not present before establishment year. - * - * @throws ReflectionException */ public function testNotHoliday(): void { @@ -66,7 +62,7 @@ public function testNotHoliday(): void /** * Tests translated name of First National Government. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -81,7 +77,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Argentina/NationalSovereigntyDayTest.php b/tests/Argentina/NationalSovereigntyDayTest.php index e55e04acb..7defe3529 100644 --- a/tests/Argentina/NationalSovereigntyDayTest.php +++ b/tests/Argentina/NationalSovereigntyDayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -40,7 +39,6 @@ class NationalSovereigntyDayTest extends ArgentinaBaseTestCase implements Holida * Tests the holiday defined in this test. * * @throws Exception - * @throws ReflectionException */ public function testHoliday(): void { @@ -55,8 +53,6 @@ public function testHoliday(): void /** * Tests that holiday is not present before establishment year. - * - * @throws ReflectionException */ public function testNotHoliday(): void { @@ -66,7 +62,7 @@ public function testNotHoliday(): void /** * Tests translated name of the holiday. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -81,7 +77,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Argentina/NewYearsDayTest.php b/tests/Argentina/NewYearsDayTest.php index 5a7e1f11f..0342e37cf 100644 --- a/tests/Argentina/NewYearsDayTest.php +++ b/tests/Argentina/NewYearsDayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -35,7 +34,6 @@ class NewYearsDayTest extends ArgentinaBaseTestCase implements HolidayTestCase * Tests New Years Day. * * @throws Exception - * @throws ReflectionException */ public function testNewYearsDay(): void { @@ -51,7 +49,7 @@ public function testNewYearsDay(): void /** * Tests translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -66,7 +64,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Argentina/RaceDayTest.php b/tests/Argentina/RaceDayTest.php index 389278ec1..46abbe4ed 100644 --- a/tests/Argentina/RaceDayTest.php +++ b/tests/Argentina/RaceDayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -40,7 +39,6 @@ class RaceDayTest extends ArgentinaBaseTestCase implements HolidayTestCase * Tests the holiday defined in this test. * * @throws Exception - * @throws ReflectionException */ public function testHoliday(): void { @@ -55,8 +53,6 @@ public function testHoliday(): void /** * Tests that holiday is not present before establishment year. - * - * @throws ReflectionException */ public function testNotHoliday(): void { @@ -66,7 +62,7 @@ public function testNotHoliday(): void /** * Tests translated name of the holiday. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -81,7 +77,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Argentina/RemembranceDayTest.php b/tests/Argentina/RemembranceDayTest.php index 83a88f75b..e414dfaca 100644 --- a/tests/Argentina/RemembranceDayTest.php +++ b/tests/Argentina/RemembranceDayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -40,7 +39,6 @@ class RemembranceDayTest extends ArgentinaBaseTestCase implements HolidayTestCas * Tests Day of Remembrance for Truth and Justice on or after 2006. * * @throws Exception - * @throws ReflectionException */ public function testRemembranceDayAfter2006(): void { @@ -56,7 +54,7 @@ public function testRemembranceDayAfter2006(): void /** * Tests Day of Remembrance for Truth and Justice on or before 2006. * - * @throws ReflectionException + * @throws Exception */ public function testRemembranceDayBefore2006(): void { @@ -67,7 +65,7 @@ public function testRemembranceDayBefore2006(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -78,7 +76,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Australia/AnzacDayTest.php b/tests/Australia/AnzacDayTest.php index 429cb3c0d..5df42057b 100644 --- a/tests/Australia/AnzacDayTest.php +++ b/tests/Australia/AnzacDayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -44,7 +43,6 @@ class AnzacDayTest extends AustraliaBaseTestCase implements HolidayTestCase * @param int $year the year for which the holiday defined in this test needs to be tested * @param string $expected the expected date * - * @throws ReflectionException * @throws Exception */ public function testHoliday(int $year, string $expected): void @@ -59,8 +57,6 @@ public function testHoliday(int $year, string $expected): void /** * Tests that ANZAC Day is not present before 1921. - * - * @throws ReflectionException */ public function testNotHoliday(): void { @@ -93,7 +89,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -108,7 +104,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Australia/AustraliaDayTest.php b/tests/Australia/AustraliaDayTest.php index 2461499c7..16bbbf238 100644 --- a/tests/Australia/AustraliaDayTest.php +++ b/tests/Australia/AustraliaDayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -38,8 +37,6 @@ class AustraliaDayTest extends AustraliaBaseTestCase implements HolidayTestCase * * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testHoliday(int $year, DateTime $expected): void { @@ -54,7 +51,6 @@ public function testHoliday(int $year, DateTime $expected): void * @param int $year the year for which the holiday defined in this test needs to be tested * @param ?string $expected the expected date * - * @throws ReflectionException * @throws Exception */ public function testSubstituteHoliday(int $year, ?string $expected): void @@ -78,7 +74,7 @@ public function testSubstituteHoliday(int $year, ?string $expected): void /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -93,7 +89,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Australia/AustraliaTest.php b/tests/Australia/AustraliaTest.php index 22a614269..18e86b074 100644 --- a/tests/Australia/AustraliaTest.php +++ b/tests/Australia/AustraliaTest.php @@ -26,10 +26,12 @@ class AustraliaTest extends AustraliaBaseTestCase implements ProviderTestCase /** * @var int year random year number used for all tests in this Test Case */ - protected $year; + protected int $year; /** * Initial setup of this Test Case. + * + * @throws \Exception */ protected function setUp(): void { @@ -38,8 +40,6 @@ protected function setUp(): void /** * Tests if all official holidays in Australia are defined by the provider class. - * - * @throws ReflectionException */ public function testOfficialHolidays(): void { @@ -56,8 +56,6 @@ public function testOfficialHolidays(): void /** * Tests if all observed holidays in Australia are defined by the provider class. - * - * @throws ReflectionException */ public function testObservedHolidays(): void { @@ -66,8 +64,6 @@ public function testObservedHolidays(): void /** * Tests if all seasonal holidays in Australia are defined by the provider class. - * - * @throws ReflectionException */ public function testSeasonalHolidays(): void { @@ -76,8 +72,6 @@ public function testSeasonalHolidays(): void /** * Tests if all bank holidays in Australia are defined by the provider class. - * - * @throws ReflectionException */ public function testBankHolidays(): void { @@ -86,8 +80,6 @@ public function testBankHolidays(): void /** * Tests if all other holidays in Australia are defined by the provider class. - * - * @throws ReflectionException */ public function testOtherHolidays(): void { @@ -96,6 +88,7 @@ public function testOtherHolidays(): void /** * @throws ReflectionException + * @throws \Exception */ public function testSources(): void { diff --git a/tests/Australia/AustralianCapitalTerritory/AustralianCapitalTerritoryTest.php b/tests/Australia/AustralianCapitalTerritory/AustralianCapitalTerritoryTest.php index 2d48c95b0..472d01650 100644 --- a/tests/Australia/AustralianCapitalTerritory/AustralianCapitalTerritoryTest.php +++ b/tests/Australia/AustralianCapitalTerritory/AustralianCapitalTerritoryTest.php @@ -26,10 +26,12 @@ class AustralianCapitalTerritoryTest extends AustralianCapitalTerritoryBaseTestC /** * @var int year random year number used for all tests in this Test Case */ - protected $year; + protected int $year; /** * Initial setup of this Test Case. + * + * @throws \Exception */ protected function setUp(): void { @@ -38,8 +40,6 @@ protected function setUp(): void /** * Tests if all official holidays in Australian Capital Territory (Australia) are defined by the provider class. - * - * @throws ReflectionException */ public function testOfficialHolidays(): void { @@ -62,6 +62,7 @@ public function testOfficialHolidays(): void /** * @throws ReflectionException + * @throws \Exception */ public function testSources(): void { diff --git a/tests/Australia/AustralianCapitalTerritory/CanberraDayTest.php b/tests/Australia/AustralianCapitalTerritory/CanberraDayTest.php index 2fa82fc2c..615b8e7e4 100644 --- a/tests/Australia/AustralianCapitalTerritory/CanberraDayTest.php +++ b/tests/Australia/AustralianCapitalTerritory/CanberraDayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -44,7 +43,6 @@ class CanberraDayTest extends AustralianCapitalTerritoryBaseTestCase implements * @param int $year the year for which the holiday defined in this test needs to be tested * @param string $expected the expected date * - * @throws ReflectionException * @throws Exception */ public function testHoliday(int $year, string $expected): void @@ -82,7 +80,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -97,7 +95,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Australia/AustralianCapitalTerritory/EasterSaturdayTest.php b/tests/Australia/AustralianCapitalTerritory/EasterSaturdayTest.php index 103b15d7d..27ab89783 100644 --- a/tests/Australia/AustralianCapitalTerritory/EasterSaturdayTest.php +++ b/tests/Australia/AustralianCapitalTerritory/EasterSaturdayTest.php @@ -18,7 +18,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -40,7 +39,6 @@ class EasterSaturdayTest extends AustralianCapitalTerritoryBaseTestCase implemen * @param int $year the year for which the holiday defined in this test needs to be tested * @param string $expected the expected date * - * @throws ReflectionException * @throws Exception */ public function testHoliday(int $year, string $expected): void @@ -78,7 +76,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -93,7 +91,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Australia/AustralianCapitalTerritory/EasterSundayTest.php b/tests/Australia/AustralianCapitalTerritory/EasterSundayTest.php index 6ac520c26..2dd6297a7 100644 --- a/tests/Australia/AustralianCapitalTerritory/EasterSundayTest.php +++ b/tests/Australia/AustralianCapitalTerritory/EasterSundayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -39,7 +38,6 @@ class EasterSundayTest extends AustralianCapitalTerritoryBaseTestCase implements * @param int $year the year for which the holiday defined in this test needs to be tested * @param string $expected the expected date * - * @throws ReflectionException * @throws Exception */ public function testHoliday(int $year, string $expected): void @@ -76,7 +74,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -91,7 +89,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Australia/AustralianCapitalTerritory/LabourDayTest.php b/tests/Australia/AustralianCapitalTerritory/LabourDayTest.php index 45393245b..bc3c02249 100644 --- a/tests/Australia/AustralianCapitalTerritory/LabourDayTest.php +++ b/tests/Australia/AustralianCapitalTerritory/LabourDayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -39,7 +38,6 @@ class LabourDayTest extends AustralianCapitalTerritoryBaseTestCase implements Ho * @param int $year the year for which the holiday defined in this test needs to be tested * @param string $expected the expected date * - * @throws ReflectionException * @throws Exception */ public function testHoliday(int $year, string $expected): void @@ -77,7 +75,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -92,7 +90,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Australia/AustralianCapitalTerritory/QueensBirthdayTest.php b/tests/Australia/AustralianCapitalTerritory/QueensBirthdayTest.php index bc88b9d1d..e8606351b 100644 --- a/tests/Australia/AustralianCapitalTerritory/QueensBirthdayTest.php +++ b/tests/Australia/AustralianCapitalTerritory/QueensBirthdayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -44,7 +43,6 @@ class QueensBirthdayTest extends AustralianCapitalTerritoryBaseTestCase implemen * @param int $year the year for which the holiday defined in this test needs to be tested * @param string $expected the expected date * - * @throws ReflectionException * @throws Exception */ public function testHoliday(int $year, string $expected): void @@ -82,7 +80,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -97,7 +95,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Australia/AustralianCapitalTerritory/ReconciliationDayTest.php b/tests/Australia/AustralianCapitalTerritory/ReconciliationDayTest.php index b92043159..01e16ff53 100644 --- a/tests/Australia/AustralianCapitalTerritory/ReconciliationDayTest.php +++ b/tests/Australia/AustralianCapitalTerritory/ReconciliationDayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -44,7 +43,6 @@ class ReconciliationDayTest extends AustralianCapitalTerritoryBaseTestCase imple * @param int $year the year for which the holiday defined in this test needs to be tested * @param string $expected the expected date * - * @throws ReflectionException * @throws Exception */ public function testHoliday(int $year, string $expected): void @@ -84,7 +82,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -99,7 +97,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Australia/BoxingDayTest.php b/tests/Australia/BoxingDayTest.php index 85d5fe3d3..3757db122 100644 --- a/tests/Australia/BoxingDayTest.php +++ b/tests/Australia/BoxingDayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -41,7 +40,6 @@ class BoxingDayTest extends AustraliaBaseTestCase implements HolidayTestCase * @param string $expected the expected date * @param ?string $expectedExtra the expected date for the additional holiday, or null if no additional holiday * - * @throws ReflectionException * @throws Exception */ public function testHoliday(int $year, string $expected, ?string $expectedExtra): void @@ -93,7 +91,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -114,7 +112,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Australia/ChristmasDayTest.php b/tests/Australia/ChristmasDayTest.php index c03dbab0a..2badfcd37 100644 --- a/tests/Australia/ChristmasDayTest.php +++ b/tests/Australia/ChristmasDayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -41,7 +40,6 @@ class ChristmasDayTest extends AustraliaBaseTestCase implements HolidayTestCase * @param string $expected the expected date * @param ?string $expectedExtra the expected date for the additional holiday, or null if no additional holiday * - * @throws ReflectionException * @throws Exception */ public function testHoliday(int $year, string $expected, ?string $expectedExtra): void @@ -93,7 +91,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -114,7 +112,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Australia/EasterMondayTest.php b/tests/Australia/EasterMondayTest.php index 68fc8b0a1..18088f406 100644 --- a/tests/Australia/EasterMondayTest.php +++ b/tests/Australia/EasterMondayTest.php @@ -18,7 +18,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -41,7 +40,6 @@ class EasterMondayTest extends AustraliaBaseTestCase implements HolidayTestCase * @param int $year the year for which the holiday defined in this test needs to be tested * @param string $expected the expected date * - * @throws ReflectionException * @throws Exception */ public function testHoliday(int $year, string $expected): void @@ -62,7 +60,6 @@ public function testHoliday(int $year, string $expected): void * @param int $year the year for which the holiday defined in this test needs to be tested * @param string $expected the expected date * - * @throws ReflectionException * @throws Exception */ public function testHoliday2(int $year, string $expected): void @@ -115,7 +112,7 @@ public function HolidayDataProvider2(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -136,7 +133,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Australia/GoodFridayTest.php b/tests/Australia/GoodFridayTest.php index 2d586fba0..f2ad138b6 100644 --- a/tests/Australia/GoodFridayTest.php +++ b/tests/Australia/GoodFridayTest.php @@ -18,7 +18,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -40,7 +39,6 @@ class GoodFridayTest extends AustraliaBaseTestCase implements HolidayTestCase * @param int $year the year for which the holiday defined in this test needs to be tested * @param string $expected the expected date * - * @throws ReflectionException * @throws Exception */ public function testHoliday(int $year, string $expected): void @@ -77,7 +75,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -92,7 +90,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Australia/NewSouthWales/BankHolidayTest.php b/tests/Australia/NewSouthWales/BankHolidayTest.php index c9b74de45..4fb19326d 100644 --- a/tests/Australia/NewSouthWales/BankHolidayTest.php +++ b/tests/Australia/NewSouthWales/BankHolidayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -39,7 +38,6 @@ class BankHolidayTest extends NewSouthWalesBaseTestCase implements HolidayTestCa * @param int $year the year for which the holiday defined in this test needs to be tested * @param string $expected the expected date * - * @throws ReflectionException * @throws Exception */ public function testHoliday(int $year, string $expected): void @@ -77,7 +75,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -92,7 +90,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Australia/NewSouthWales/EasterSaturdayTest.php b/tests/Australia/NewSouthWales/EasterSaturdayTest.php index 3e4c2ce89..cfb4040e8 100644 --- a/tests/Australia/NewSouthWales/EasterSaturdayTest.php +++ b/tests/Australia/NewSouthWales/EasterSaturdayTest.php @@ -18,7 +18,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -40,7 +39,6 @@ class EasterSaturdayTest extends NewSouthWalesBaseTestCase implements HolidayTes * @param int $year the year for which the holiday defined in this test needs to be tested * @param string $expected the expected date * - * @throws ReflectionException * @throws Exception */ public function testHoliday(int $year, string $expected): void @@ -78,7 +76,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -93,7 +91,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Australia/NewSouthWales/EasterSundayTest.php b/tests/Australia/NewSouthWales/EasterSundayTest.php index 94d833652..8bbc5d25a 100644 --- a/tests/Australia/NewSouthWales/EasterSundayTest.php +++ b/tests/Australia/NewSouthWales/EasterSundayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -39,7 +38,6 @@ class EasterSundayTest extends NewSouthWalesBaseTestCase implements HolidayTestC * @param int $year the year for which the holiday defined in this test needs to be tested * @param string $expected the expected date * - * @throws ReflectionException * @throws Exception */ public function testHoliday(int $year, string $expected): void @@ -76,7 +74,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -91,7 +89,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Australia/NewSouthWales/LabourDayTest.php b/tests/Australia/NewSouthWales/LabourDayTest.php index 1fab61ada..0a678ee10 100644 --- a/tests/Australia/NewSouthWales/LabourDayTest.php +++ b/tests/Australia/NewSouthWales/LabourDayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -39,7 +38,6 @@ class LabourDayTest extends NewSouthWalesBaseTestCase implements HolidayTestCase * @param int $year the year for which the holiday defined in this test needs to be tested * @param string $expected the expected date * - * @throws ReflectionException * @throws Exception */ public function testHoliday(int $year, string $expected): void @@ -77,7 +75,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -92,7 +90,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Australia/NewSouthWales/NewSouthWalesTest.php b/tests/Australia/NewSouthWales/NewSouthWalesTest.php index cca33c8d9..0249ebbf4 100644 --- a/tests/Australia/NewSouthWales/NewSouthWalesTest.php +++ b/tests/Australia/NewSouthWales/NewSouthWalesTest.php @@ -26,10 +26,12 @@ class NewSouthWalesTest extends NewSouthWalesBaseTestCase implements ProviderTes /** * @var int year random year number used for all tests in this Test Case */ - protected $year; + protected int $year; /** * Initial setup of this Test Case. + * + * @throws \Exception */ protected function setUp(): void { @@ -38,8 +40,6 @@ protected function setUp(): void /** * Tests if all official holidays in New South Wales (Australia) are defined by the provider class. - * - * @throws ReflectionException */ public function testOfficialHolidays(): void { @@ -60,8 +60,6 @@ public function testOfficialHolidays(): void /** * Tests if all bank holidays in New South Wales (Australia) are defined by the provider class. - * - * @throws ReflectionException */ public function testBankHolidays(): void { @@ -72,6 +70,7 @@ public function testBankHolidays(): void /** * @throws ReflectionException + * @throws \Exception */ public function testSources(): void { diff --git a/tests/Australia/NewSouthWales/QueensBirthdayTest.php b/tests/Australia/NewSouthWales/QueensBirthdayTest.php index cf7277beb..81bee578b 100644 --- a/tests/Australia/NewSouthWales/QueensBirthdayTest.php +++ b/tests/Australia/NewSouthWales/QueensBirthdayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -44,7 +43,6 @@ class QueensBirthdayTest extends NewSouthWalesBaseTestCase implements HolidayTes * @param int $year the year for which the holiday defined in this test needs to be tested * @param string $expected the expected date * - * @throws ReflectionException * @throws Exception */ public function testHoliday(int $year, string $expected): void @@ -82,7 +80,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -97,7 +95,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Australia/NewYearsDayTest.php b/tests/Australia/NewYearsDayTest.php index c0622cbb4..f36800828 100644 --- a/tests/Australia/NewYearsDayTest.php +++ b/tests/Australia/NewYearsDayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -41,7 +40,6 @@ class NewYearsDayTest extends AustraliaBaseTestCase implements HolidayTestCase * @param string $expected the expected date * @param ?string $expectedExtra the expected date for the additional holiday, or null if no additional holiday * - * @throws ReflectionException * @throws Exception */ public function testHoliday(int $year, string $expected, ?string $expectedExtra): void @@ -93,7 +91,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -114,7 +112,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Australia/NorthernTerritory/EasterSaturdayTest.php b/tests/Australia/NorthernTerritory/EasterSaturdayTest.php index da8294475..4c164251d 100644 --- a/tests/Australia/NorthernTerritory/EasterSaturdayTest.php +++ b/tests/Australia/NorthernTerritory/EasterSaturdayTest.php @@ -18,7 +18,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -40,7 +39,6 @@ class EasterSaturdayTest extends NorthernTerritoryBaseTestCase implements Holida * @param int $year the year for which the holiday defined in this test needs to be tested * @param string $expected the expected date * - * @throws ReflectionException * @throws Exception */ public function testHoliday(int $year, string $expected): void @@ -78,7 +76,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -93,7 +91,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Australia/NorthernTerritory/MayDayTest.php b/tests/Australia/NorthernTerritory/MayDayTest.php index 1547cb287..8b5675c44 100644 --- a/tests/Australia/NorthernTerritory/MayDayTest.php +++ b/tests/Australia/NorthernTerritory/MayDayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -39,7 +38,6 @@ class MayDayTest extends NorthernTerritoryBaseTestCase implements HolidayTestCas * @param int $year the year for which the holiday defined in this test needs to be tested * @param string $expected the expected date * - * @throws ReflectionException * @throws Exception */ public function testHoliday(int $year, string $expected): void @@ -77,7 +75,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -92,7 +90,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Australia/NorthernTerritory/NorthernTerritoryTest.php b/tests/Australia/NorthernTerritory/NorthernTerritoryTest.php index 6b7a51150..cbe17acf8 100644 --- a/tests/Australia/NorthernTerritory/NorthernTerritoryTest.php +++ b/tests/Australia/NorthernTerritory/NorthernTerritoryTest.php @@ -26,10 +26,12 @@ class NorthernTerritoryTest extends NorthernTerritoryBaseTestCase implements Pro /** * @var int year random year number used for all tests in this Test Case */ - protected $year; + protected int $year; /** * Initial setup of this Test Case. + * + * @throws \Exception */ protected function setUp(): void { @@ -38,8 +40,6 @@ protected function setUp(): void /** * Tests if all official holidays in Northern Territory (Australia) are defined by the provider class. - * - * @throws ReflectionException */ public function testOfficialHolidays(): void { @@ -60,6 +60,7 @@ public function testOfficialHolidays(): void /** * @throws ReflectionException + * @throws \Exception */ public function testSources(): void { diff --git a/tests/Australia/NorthernTerritory/PicnicDayTest.php b/tests/Australia/NorthernTerritory/PicnicDayTest.php index 868c30ed2..fef8e3bb2 100644 --- a/tests/Australia/NorthernTerritory/PicnicDayTest.php +++ b/tests/Australia/NorthernTerritory/PicnicDayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -39,7 +38,6 @@ class PicnicDayTest extends NorthernTerritoryBaseTestCase implements HolidayTest * @param int $year the year for which the holiday defined in this test needs to be tested * @param string $expected the expected date * - * @throws ReflectionException * @throws Exception */ public function testHoliday(int $year, string $expected): void @@ -77,7 +75,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -92,7 +90,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Australia/NorthernTerritory/QueensBirthdayTest.php b/tests/Australia/NorthernTerritory/QueensBirthdayTest.php index 094742b5c..f31e35f1a 100644 --- a/tests/Australia/NorthernTerritory/QueensBirthdayTest.php +++ b/tests/Australia/NorthernTerritory/QueensBirthdayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -44,7 +43,6 @@ class QueensBirthdayTest extends NorthernTerritoryBaseTestCase implements Holida * @param int $year the year for which the holiday defined in this test needs to be tested * @param string $expected the expected date * - * @throws ReflectionException * @throws Exception */ public function testHoliday(int $year, string $expected): void @@ -82,7 +80,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -97,7 +95,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Australia/Queensland/Brisbane/BrisbaneTest.php b/tests/Australia/Queensland/Brisbane/BrisbaneTest.php index 6982e325d..1d0c17ad0 100644 --- a/tests/Australia/Queensland/Brisbane/BrisbaneTest.php +++ b/tests/Australia/Queensland/Brisbane/BrisbaneTest.php @@ -26,10 +26,12 @@ class BrisbaneTest extends BrisbaneBaseTestCase implements ProviderTestCase /** * @var int year random year number used for all tests in this Test Case */ - protected $year; + protected int $year; /** * Initial setup of this Test Case. + * + * @throws \Exception */ protected function setUp(): void { @@ -38,8 +40,6 @@ protected function setUp(): void /** * Tests if all official holidays in Queensland (Australia) are defined by the provider class. - * - * @throws ReflectionException */ public function testOfficialHolidays(): void { @@ -59,6 +59,7 @@ public function testOfficialHolidays(): void /** * @throws ReflectionException + * @throws \Exception */ public function testSources(): void { diff --git a/tests/Australia/Queensland/Brisbane/PeoplesDayTest.php b/tests/Australia/Queensland/Brisbane/PeoplesDayTest.php index 3d9089eba..89af7c121 100644 --- a/tests/Australia/Queensland/Brisbane/PeoplesDayTest.php +++ b/tests/Australia/Queensland/Brisbane/PeoplesDayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -39,7 +38,6 @@ class PeoplesDayTest extends BrisbaneBaseTestCase implements HolidayTestCase * @param int $year the year for which the holiday defined in this test needs to be tested * @param string $expected the expected date * - * @throws ReflectionException * @throws Exception */ public function testHoliday(int $year, string $expected): void @@ -77,7 +75,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -92,7 +90,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Australia/Queensland/LabourDayTest.php b/tests/Australia/Queensland/LabourDayTest.php index 9eddbda8c..a9d0177f9 100644 --- a/tests/Australia/Queensland/LabourDayTest.php +++ b/tests/Australia/Queensland/LabourDayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -39,7 +38,6 @@ class LabourDayTest extends QueenslandBaseTestCase implements HolidayTestCase * @param int $year the year for which the holiday defined in this test needs to be tested * @param string $expected the expected date * - * @throws ReflectionException * @throws Exception */ public function testHoliday(int $year, string $expected): void @@ -77,7 +75,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -92,7 +90,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Australia/Queensland/QueensBirthdayTest.php b/tests/Australia/Queensland/QueensBirthdayTest.php index 199c7cef3..15d02035c 100644 --- a/tests/Australia/Queensland/QueensBirthdayTest.php +++ b/tests/Australia/Queensland/QueensBirthdayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -44,7 +43,6 @@ class QueensBirthdayTest extends QueenslandBaseTestCase implements HolidayTestCa * @param int $year the year for which the holiday defined in this test needs to be tested * @param string $expected the expected date * - * @throws ReflectionException * @throws Exception */ public function testHoliday(int $year, string $expected): void @@ -82,7 +80,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -97,7 +95,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Australia/Queensland/QueenslandTest.php b/tests/Australia/Queensland/QueenslandTest.php index 8cc68abe3..393a32b99 100644 --- a/tests/Australia/Queensland/QueenslandTest.php +++ b/tests/Australia/Queensland/QueenslandTest.php @@ -26,10 +26,12 @@ class QueenslandTest extends QueenslandBaseTestCase implements ProviderTestCase /** * @var int year random year number used for all tests in this Test Case */ - protected $year; + protected int $year; /** * Initial setup of this Test Case. + * + * @throws \Exception */ protected function setUp(): void { @@ -38,8 +40,6 @@ protected function setUp(): void /** * Tests if all official holidays in Queensland (Australia) are defined by the provider class. - * - * @throws ReflectionException */ public function testOfficialHolidays(): void { @@ -58,6 +58,7 @@ public function testOfficialHolidays(): void /** * @throws ReflectionException + * @throws \Exception */ public function testSources(): void { diff --git a/tests/Australia/SouthAustralia/AdelaideCupDayTest.php b/tests/Australia/SouthAustralia/AdelaideCupDayTest.php index ca06dae3e..3d4d768bd 100644 --- a/tests/Australia/SouthAustralia/AdelaideCupDayTest.php +++ b/tests/Australia/SouthAustralia/AdelaideCupDayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -44,7 +43,6 @@ class AdelaideCupDayTest extends SouthAustraliaBaseTestCase implements HolidayTe * @param int $year the year for which the holiday defined in this test needs to be tested * @param string $expected the expected date * - * @throws ReflectionException * @throws Exception */ public function testHoliday(int $year, string $expected): void @@ -92,7 +90,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -107,7 +105,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Australia/SouthAustralia/ChristmasDayTest.php b/tests/Australia/SouthAustralia/ChristmasDayTest.php index 901f77531..9514d2089 100644 --- a/tests/Australia/SouthAustralia/ChristmasDayTest.php +++ b/tests/Australia/SouthAustralia/ChristmasDayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -41,7 +40,6 @@ class ChristmasDayTest extends SouthAustraliaBaseTestCase implements HolidayTest * @param string $expected the expected date * @param ?string $expectedExtra the expected date for the additional holiday, or null if no additional holiday * - * @throws ReflectionException * @throws Exception */ public function testHoliday(int $year, string $expected, ?string $expectedExtra): void @@ -93,7 +91,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -114,7 +112,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Australia/SouthAustralia/EasterSaturdayTest.php b/tests/Australia/SouthAustralia/EasterSaturdayTest.php index be452f2c6..d19049985 100644 --- a/tests/Australia/SouthAustralia/EasterSaturdayTest.php +++ b/tests/Australia/SouthAustralia/EasterSaturdayTest.php @@ -18,7 +18,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -40,7 +39,6 @@ class EasterSaturdayTest extends SouthAustraliaBaseTestCase implements HolidayTe * @param int $year the year for which the holiday defined in this test needs to be tested * @param string $expected the expected date * - * @throws ReflectionException * @throws Exception */ public function testHoliday(int $year, string $expected): void @@ -78,7 +76,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -93,7 +91,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Australia/SouthAustralia/LabourDayTest.php b/tests/Australia/SouthAustralia/LabourDayTest.php index 4562a36b6..daf8d88df 100644 --- a/tests/Australia/SouthAustralia/LabourDayTest.php +++ b/tests/Australia/SouthAustralia/LabourDayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -39,7 +38,6 @@ class LabourDayTest extends SouthAustraliaBaseTestCase implements HolidayTestCas * @param int $year the year for which the holiday defined in this test needs to be tested * @param string $expected the expected date * - * @throws ReflectionException * @throws Exception */ public function testHoliday(int $year, string $expected): void @@ -77,7 +75,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -92,7 +90,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Australia/SouthAustralia/ProclamationDayTest.php b/tests/Australia/SouthAustralia/ProclamationDayTest.php index b31eb4de1..6ca469fbd 100644 --- a/tests/Australia/SouthAustralia/ProclamationDayTest.php +++ b/tests/Australia/SouthAustralia/ProclamationDayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -39,7 +38,6 @@ class ProclamationDayTest extends SouthAustraliaBaseTestCase implements HolidayT * @param int $year the year for which the holiday defined in this test needs to be tested * @param string $expected the expected date * - * @throws ReflectionException * @throws Exception */ public function testHoliday(int $year, string $expected): void @@ -77,7 +75,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -92,7 +90,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Australia/SouthAustralia/QueensBirthdayTest.php b/tests/Australia/SouthAustralia/QueensBirthdayTest.php index 9db861703..e5a880014 100644 --- a/tests/Australia/SouthAustralia/QueensBirthdayTest.php +++ b/tests/Australia/SouthAustralia/QueensBirthdayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -44,7 +43,6 @@ class QueensBirthdayTest extends SouthAustraliaBaseTestCase implements HolidayTe * @param int $year the year for which the holiday defined in this test needs to be tested * @param string $expected the expected date * - * @throws ReflectionException * @throws Exception */ public function testHoliday(int $year, string $expected): void @@ -82,7 +80,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -97,7 +95,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Australia/SouthAustralia/SouthAustraliaTest.php b/tests/Australia/SouthAustralia/SouthAustraliaTest.php index 9f348c698..d35c0bad6 100644 --- a/tests/Australia/SouthAustralia/SouthAustraliaTest.php +++ b/tests/Australia/SouthAustralia/SouthAustraliaTest.php @@ -26,10 +26,12 @@ class SouthAustraliaTest extends SouthAustraliaBaseTestCase implements ProviderT /** * @var int year random year number used for all tests in this Test Case */ - protected $year; + protected int $year; /** * Initial setup of this Test Case. + * + * @throws \Exception */ protected function setUp(): void { @@ -38,8 +40,6 @@ protected function setUp(): void /** * Tests if all official holidays in South Australia (Australia) are defined by the provider class. - * - * @throws ReflectionException */ public function testOfficialHolidays(): void { @@ -60,6 +60,7 @@ public function testOfficialHolidays(): void /** * @throws ReflectionException + * @throws \Exception */ public function testSources(): void { diff --git a/tests/Australia/Tasmania/CentralNorth/CentralNorthTest.php b/tests/Australia/Tasmania/CentralNorth/CentralNorthTest.php index 2f96ca123..4c8a04c1d 100644 --- a/tests/Australia/Tasmania/CentralNorth/CentralNorthTest.php +++ b/tests/Australia/Tasmania/CentralNorth/CentralNorthTest.php @@ -30,6 +30,8 @@ class CentralNorthTest extends CentralNorthBaseTestCase implements ProviderTestC /** * Initial setup of this Test Case. + * + * @throws \Exception */ protected function setUp(): void { @@ -38,8 +40,6 @@ protected function setUp(): void /** * Tests if all official holidays in central north Tasmania (Australia) are defined by the provider class. - * - * @throws ReflectionException */ public function testOfficialHolidays(): void { @@ -60,6 +60,7 @@ public function testOfficialHolidays(): void /** * @throws ReflectionException + * @throws \Exception */ public function testSources(): void { diff --git a/tests/Australia/Tasmania/CentralNorth/DevonportShowTest.php b/tests/Australia/Tasmania/CentralNorth/DevonportShowTest.php index 461adfc2d..c110d7469 100644 --- a/tests/Australia/Tasmania/CentralNorth/DevonportShowTest.php +++ b/tests/Australia/Tasmania/CentralNorth/DevonportShowTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -39,7 +38,6 @@ class DevonportShowTest extends CentralNorthBaseTestCase implements HolidayTestC * @param int $year the year for which the holiday defined in this test needs to be tested * @param string $expected the expected date * - * @throws ReflectionException * @throws Exception */ public function testHoliday(int $year, string $expected): void @@ -77,7 +75,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -92,7 +90,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Australia/Tasmania/EightHourDayTest.php b/tests/Australia/Tasmania/EightHourDayTest.php index e56d0fcc8..bda06f4b9 100644 --- a/tests/Australia/Tasmania/EightHourDayTest.php +++ b/tests/Australia/Tasmania/EightHourDayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -39,7 +38,6 @@ class EightHourDayTest extends TasmaniaBaseTestCase implements HolidayTestCase * @param int $year the year for which the holiday defined in this test needs to be tested * @param string $expected the expected date * - * @throws ReflectionException * @throws Exception */ public function testHoliday(int $year, string $expected): void @@ -77,7 +75,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -92,7 +90,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Australia/Tasmania/FlindersIsland/FlindersIslandShowTest.php b/tests/Australia/Tasmania/FlindersIsland/FlindersIslandShowTest.php index b33fcc1e0..e4f293f71 100644 --- a/tests/Australia/Tasmania/FlindersIsland/FlindersIslandShowTest.php +++ b/tests/Australia/Tasmania/FlindersIsland/FlindersIslandShowTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -39,7 +38,6 @@ class FlindersIslandShowTest extends FlindersIslandBaseTestCase implements Holid * @param int $year the year for which the holiday defined in this test needs to be tested * @param string $expected the expected date * - * @throws ReflectionException * @throws Exception */ public function testHoliday(int $year, string $expected): void @@ -77,7 +75,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -92,7 +90,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Australia/Tasmania/FlindersIsland/FlindersIslandTest.php b/tests/Australia/Tasmania/FlindersIsland/FlindersIslandTest.php index fe612a37b..76bce01a5 100644 --- a/tests/Australia/Tasmania/FlindersIsland/FlindersIslandTest.php +++ b/tests/Australia/Tasmania/FlindersIsland/FlindersIslandTest.php @@ -30,6 +30,8 @@ class FlindersIslandTest extends FlindersIslandBaseTestCase implements ProviderT /** * Initial setup of this Test Case. + * + * @throws \Exception */ protected function setUp(): void { @@ -38,8 +40,6 @@ protected function setUp(): void /** * Tests if all official holidays in Flinders Island (Australia) are defined by the provider class. - * - * @throws ReflectionException */ public function testOfficialHolidays(): void { @@ -60,6 +60,7 @@ public function testOfficialHolidays(): void /** * @throws ReflectionException + * @throws \Exception */ public function testSources(): void { diff --git a/tests/Australia/Tasmania/KingIsland/KingIslandShowTest.php b/tests/Australia/Tasmania/KingIsland/KingIslandShowTest.php index 943a95dd9..3dae93000 100644 --- a/tests/Australia/Tasmania/KingIsland/KingIslandShowTest.php +++ b/tests/Australia/Tasmania/KingIsland/KingIslandShowTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -39,7 +38,6 @@ class KingIslandShowTest extends KingIslandBaseTestCase implements HolidayTestCa * @param int $year the year for which the holiday defined in this test needs to be tested * @param string $expected the expected date * - * @throws ReflectionException * @throws Exception */ public function testHoliday(int $year, string $expected): void @@ -77,7 +75,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -92,7 +90,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Australia/Tasmania/KingIsland/KingIslandTest.php b/tests/Australia/Tasmania/KingIsland/KingIslandTest.php index 2f1d23083..fc5464e25 100644 --- a/tests/Australia/Tasmania/KingIsland/KingIslandTest.php +++ b/tests/Australia/Tasmania/KingIsland/KingIslandTest.php @@ -30,6 +30,8 @@ class KingIslandTest extends KingIslandBaseTestCase implements ProviderTestCase /** * Initial setup of this Test Case. + * + * @throws \Exception */ protected function setUp(): void { @@ -38,8 +40,6 @@ protected function setUp(): void /** * Tests if all official holidays in King Island (Australia) are defined by the provider class. - * - * @throws ReflectionException */ public function testOfficialHolidays(): void { @@ -60,6 +60,7 @@ public function testOfficialHolidays(): void /** * @throws ReflectionException + * @throws \Exception */ public function testSources(): void { diff --git a/tests/Australia/Tasmania/Northeast/LauncestonShowTest.php b/tests/Australia/Tasmania/Northeast/LauncestonShowTest.php index aba05fe83..183f07977 100644 --- a/tests/Australia/Tasmania/Northeast/LauncestonShowTest.php +++ b/tests/Australia/Tasmania/Northeast/LauncestonShowTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -39,7 +38,6 @@ class LauncestonShowTest extends NortheastBaseTestCase implements HolidayTestCas * @param int $year the year for which the holiday defined in this test needs to be tested * @param string $expected the expected date * - * @throws ReflectionException * @throws Exception */ public function testHoliday(int $year, string $expected): void @@ -77,7 +75,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -92,7 +90,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Australia/Tasmania/Northeast/NortheastTest.php b/tests/Australia/Tasmania/Northeast/NortheastTest.php index e01db49eb..fe9933f9a 100644 --- a/tests/Australia/Tasmania/Northeast/NortheastTest.php +++ b/tests/Australia/Tasmania/Northeast/NortheastTest.php @@ -30,6 +30,8 @@ class NortheastTest extends NortheastBaseTestCase implements ProviderTestCase /** * Initial setup of this Test Case. + * + * @throws \Exception */ protected function setUp(): void { @@ -38,8 +40,6 @@ protected function setUp(): void /** * Tests if all official holidays in northeastern Tasmania (Australia) are defined by the provider class. - * - * @throws ReflectionException */ public function testOfficialHolidays(): void { @@ -60,6 +60,7 @@ public function testOfficialHolidays(): void /** * @throws ReflectionException + * @throws \Exception */ public function testSources(): void { diff --git a/tests/Australia/Tasmania/Northwest/BurnieShowTest.php b/tests/Australia/Tasmania/Northwest/BurnieShowTest.php index 527785c2a..99d7a2836 100644 --- a/tests/Australia/Tasmania/Northwest/BurnieShowTest.php +++ b/tests/Australia/Tasmania/Northwest/BurnieShowTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -39,7 +38,6 @@ class BurnieShowTest extends NorthwestBaseTestCase implements HolidayTestCase * @param int $year the year for which the holiday defined in this test needs to be tested * @param string $expected the expected date * - * @throws ReflectionException * @throws Exception */ public function testHoliday(int $year, string $expected): void @@ -77,7 +75,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -92,7 +90,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Australia/Tasmania/Northwest/CircularHead/AGFESTTest.php b/tests/Australia/Tasmania/Northwest/CircularHead/AGFESTTest.php index e723744ae..2be1d89e9 100644 --- a/tests/Australia/Tasmania/Northwest/CircularHead/AGFESTTest.php +++ b/tests/Australia/Tasmania/Northwest/CircularHead/AGFESTTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -39,7 +38,6 @@ class AGFESTTest extends CircularHeadBaseTestCase implements HolidayTestCase * @param int $year the year for which the holiday defined in this test needs to be tested * @param string $expected the expected date * - * @throws ReflectionException * @throws Exception */ public function testHoliday(int $year, string $expected): void @@ -77,7 +75,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -92,7 +90,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Australia/Tasmania/Northwest/CircularHead/CircularHeadTest.php b/tests/Australia/Tasmania/Northwest/CircularHead/CircularHeadTest.php index 79b1ec73a..4c2d1d13d 100644 --- a/tests/Australia/Tasmania/Northwest/CircularHead/CircularHeadTest.php +++ b/tests/Australia/Tasmania/Northwest/CircularHead/CircularHeadTest.php @@ -14,7 +14,6 @@ namespace Yasumi\tests\Australia\Tasmania\Northwest\CircularHead; -use ReflectionException; use Yasumi\Holiday; /** @@ -29,6 +28,8 @@ class CircularHeadTest extends CircularHeadBaseTestCase /** * Initial setup of this Test Case. + * + * @throws \Exception */ protected function setUp(): void { @@ -37,8 +38,6 @@ protected function setUp(): void /** * Tests if all official holidays in Circular Head (Australia) are defined by the provider class. - * - * @throws ReflectionException */ public function testOfficialHolidays(): void { diff --git a/tests/Australia/Tasmania/Northwest/NorthwestTest.php b/tests/Australia/Tasmania/Northwest/NorthwestTest.php index 36466435e..aee008564 100644 --- a/tests/Australia/Tasmania/Northwest/NorthwestTest.php +++ b/tests/Australia/Tasmania/Northwest/NorthwestTest.php @@ -30,6 +30,8 @@ class NorthwestTest extends NorthwestBaseTestCase implements ProviderTestCase /** * Initial setup of this Test Case. + * + * @throws \Exception */ protected function setUp(): void { @@ -38,8 +40,6 @@ protected function setUp(): void /** * Tests if all official holidays in northwestern Tasmania (Australia) are defined by the provider class. - * - * @throws ReflectionException */ public function testOfficialHolidays(): void { @@ -60,6 +60,7 @@ public function testOfficialHolidays(): void /** * @throws ReflectionException + * @throws \Exception */ public function testSources(): void { diff --git a/tests/Australia/Tasmania/QueensBirthdayTest.php b/tests/Australia/Tasmania/QueensBirthdayTest.php index ca6f4a709..5aa0b7fd3 100644 --- a/tests/Australia/Tasmania/QueensBirthdayTest.php +++ b/tests/Australia/Tasmania/QueensBirthdayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -44,7 +43,6 @@ class QueensBirthdayTest extends TasmaniaBaseTestCase implements HolidayTestCase * @param int $year the year for which the holiday defined in this test needs to be tested * @param string $expected the expected date * - * @throws ReflectionException * @throws Exception */ public function testHoliday(int $year, string $expected): void @@ -82,7 +80,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -97,7 +95,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Australia/Tasmania/RecreationDayTest.php b/tests/Australia/Tasmania/RecreationDayTest.php index ded75ec5a..207ee6ba7 100644 --- a/tests/Australia/Tasmania/RecreationDayTest.php +++ b/tests/Australia/Tasmania/RecreationDayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -39,7 +38,6 @@ class RecreationDayTest extends TasmaniaBaseTestCase implements HolidayTestCase * @param int $year the year for which the holiday defined in this test needs to be tested * @param string $expected the expected date * - * @throws ReflectionException * @throws Exception */ public function testHoliday(int $year, string $expected): void @@ -77,7 +75,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -92,7 +90,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Australia/Tasmania/South/HobartShowTest.php b/tests/Australia/Tasmania/South/HobartShowTest.php index d2b4bde9b..63f91ab22 100644 --- a/tests/Australia/Tasmania/South/HobartShowTest.php +++ b/tests/Australia/Tasmania/South/HobartShowTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -39,7 +38,6 @@ class HobartShowTest extends SouthBaseTestCase implements HolidayTestCase * @param int $year the year for which the holiday defined in this test needs to be tested * @param string $expected the expected date * - * @throws ReflectionException * @throws Exception */ public function testHoliday(int $year, string $expected): void @@ -77,7 +75,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -92,7 +90,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Australia/Tasmania/South/SouthTest.php b/tests/Australia/Tasmania/South/SouthTest.php index 7af73ab3e..2d65b97dc 100644 --- a/tests/Australia/Tasmania/South/SouthTest.php +++ b/tests/Australia/Tasmania/South/SouthTest.php @@ -30,6 +30,8 @@ class SouthTest extends SouthBaseTestCase implements ProviderTestCase /** * Initial setup of this Test Case. + * + * @throws \Exception */ protected function setUp(): void { @@ -38,8 +40,6 @@ protected function setUp(): void /** * Tests if all official holidays in northwestern Tasmania (Australia) are defined by the provider class. - * - * @throws ReflectionException */ public function testOfficialHolidays(): void { @@ -60,6 +60,7 @@ public function testOfficialHolidays(): void /** * @throws ReflectionException + * @throws \Exception */ public function testSources(): void { diff --git a/tests/Australia/Tasmania/South/Southeast/HobartRegattaTest.php b/tests/Australia/Tasmania/South/Southeast/HobartRegattaTest.php index ed8ac69c3..e4e609ab2 100644 --- a/tests/Australia/Tasmania/South/Southeast/HobartRegattaTest.php +++ b/tests/Australia/Tasmania/South/Southeast/HobartRegattaTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -39,7 +38,6 @@ class HobartRegattaTest extends SoutheastBaseTestCase implements HolidayTestCase * @param int $year the year for which the holiday defined in this test needs to be tested * @param string $expected the expected date * - * @throws ReflectionException * @throws Exception */ public function testHoliday(int $year, string $expected): void @@ -77,7 +75,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -92,7 +90,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Australia/Tasmania/South/Southeast/SoutheastTest.php b/tests/Australia/Tasmania/South/Southeast/SoutheastTest.php index f0d42b0ad..abc999e9a 100644 --- a/tests/Australia/Tasmania/South/Southeast/SoutheastTest.php +++ b/tests/Australia/Tasmania/South/Southeast/SoutheastTest.php @@ -14,7 +14,6 @@ namespace Yasumi\tests\Australia\Tasmania\South\Southeast; -use ReflectionException; use Yasumi\Holiday; /** @@ -29,6 +28,8 @@ class SoutheastTest extends SoutheastBaseTestCase /** * Initial setup of this Test Case. + * + * @throws \Exception */ protected function setUp(): void { @@ -37,8 +38,6 @@ protected function setUp(): void /** * Tests if all official holidays in Circular Head (Australia) are defined by the provider class. - * - * @throws ReflectionException */ public function testOfficialHolidays(): void { diff --git a/tests/Australia/Tasmania/TasmaniaTest.php b/tests/Australia/Tasmania/TasmaniaTest.php index e1e40fcfa..a5157c60c 100644 --- a/tests/Australia/Tasmania/TasmaniaTest.php +++ b/tests/Australia/Tasmania/TasmaniaTest.php @@ -30,6 +30,8 @@ class TasmaniaTest extends TasmaniaBaseTestCase implements ProviderTestCase /** * Initial setup of this Test Case. + * + * @throws \Exception */ protected function setUp(): void { @@ -38,8 +40,6 @@ protected function setUp(): void /** * Tests if all official holidays in Tasmania (Australia) are defined by the provider class. - * - * @throws ReflectionException */ public function testOfficialHolidays(): void { @@ -59,6 +59,7 @@ public function testOfficialHolidays(): void /** * @throws ReflectionException + * @throws \Exception */ public function testSources(): void { diff --git a/tests/Australia/Victoria/AFLGrandFinalFridayTest.php b/tests/Australia/Victoria/AFLGrandFinalFridayTest.php index 2fdceaca2..114c710e0 100644 --- a/tests/Australia/Victoria/AFLGrandFinalFridayTest.php +++ b/tests/Australia/Victoria/AFLGrandFinalFridayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -42,7 +41,6 @@ class AFLGrandFinalFridayTest extends VictoriaBaseTestCase implements HolidayTes * @param int $year the year for which the holiday defined in this test needs to be tested * @param string $expected the expected date * - * @throws ReflectionException * @throws Exception */ public function testHoliday(int $year, string $expected): void @@ -58,7 +56,7 @@ public function testHoliday(int $year, string $expected): void /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -73,7 +71,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { @@ -87,8 +85,6 @@ public function testHolidayType(): void /** * Tests that Holiday is not present before establishment year. - * - * @throws ReflectionException */ public function testNotHoliday(): void { diff --git a/tests/Australia/Victoria/EasterSaturdayTest.php b/tests/Australia/Victoria/EasterSaturdayTest.php index 7c24a3ca9..9799c546e 100644 --- a/tests/Australia/Victoria/EasterSaturdayTest.php +++ b/tests/Australia/Victoria/EasterSaturdayTest.php @@ -18,7 +18,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -40,7 +39,6 @@ class EasterSaturdayTest extends VictoriaBaseTestCase implements HolidayTestCase * @param int $year the year for which the holiday defined in this test needs to be tested * @param string $expected the expected date * - * @throws ReflectionException * @throws Exception */ public function testHoliday(int $year, string $expected): void @@ -78,7 +76,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -93,7 +91,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Australia/Victoria/EasterSundayTest.php b/tests/Australia/Victoria/EasterSundayTest.php index 33ed6cec3..194f19685 100644 --- a/tests/Australia/Victoria/EasterSundayTest.php +++ b/tests/Australia/Victoria/EasterSundayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -39,7 +38,6 @@ class EasterSundayTest extends VictoriaBaseTestCase implements HolidayTestCase * @param int $year the year for which the holiday defined in this test needs to be tested * @param string $expected the expected date * - * @throws ReflectionException * @throws Exception */ public function testHoliday(int $year, string $expected): void @@ -76,7 +74,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -91,7 +89,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Australia/Victoria/LabourDayTest.php b/tests/Australia/Victoria/LabourDayTest.php index 0bb0b40e6..602b5728a 100644 --- a/tests/Australia/Victoria/LabourDayTest.php +++ b/tests/Australia/Victoria/LabourDayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -39,7 +38,6 @@ class LabourDayTest extends VictoriaBaseTestCase implements HolidayTestCase * @param int $year the year for which the holiday defined in this test needs to be tested * @param string $expected the expected date * - * @throws ReflectionException * @throws Exception */ public function testHoliday(int $year, string $expected): void @@ -77,7 +75,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -92,7 +90,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Australia/Victoria/MelbourneCupDayTest.php b/tests/Australia/Victoria/MelbourneCupDayTest.php index 130864c8a..e106247f3 100644 --- a/tests/Australia/Victoria/MelbourneCupDayTest.php +++ b/tests/Australia/Victoria/MelbourneCupDayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -44,7 +43,6 @@ class MelbourneCupDayTest extends VictoriaBaseTestCase implements HolidayTestCas * @param int $year the year for which the holiday defined in this test needs to be tested * @param string $expected the expected date * - * @throws ReflectionException * @throws Exception */ public function testHoliday(int $year, string $expected): void @@ -82,7 +80,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -97,7 +95,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Australia/Victoria/QueensBirthdayTest.php b/tests/Australia/Victoria/QueensBirthdayTest.php index e56c77223..d569ee816 100644 --- a/tests/Australia/Victoria/QueensBirthdayTest.php +++ b/tests/Australia/Victoria/QueensBirthdayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -44,7 +43,6 @@ class QueensBirthdayTest extends VictoriaBaseTestCase implements HolidayTestCase * @param int $year the year for which the holiday defined in this test needs to be tested * @param string $expected the expected date * - * @throws ReflectionException * @throws Exception */ public function testHoliday(int $year, string $expected): void @@ -82,7 +80,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -97,7 +95,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Australia/Victoria/VictoriaTest.php b/tests/Australia/Victoria/VictoriaTest.php index 73b0c7c26..112827c25 100644 --- a/tests/Australia/Victoria/VictoriaTest.php +++ b/tests/Australia/Victoria/VictoriaTest.php @@ -26,10 +26,12 @@ class VictoriaTest extends VictoriaBaseTestCase implements ProviderTestCase /** * @var int year random year number used for all tests in this Test Case */ - protected $year; + protected int $year; /** * Initial setup of this Test Case. + * + * @throws \Exception */ protected function setUp(): void { @@ -38,8 +40,6 @@ protected function setUp(): void /** * Tests if all official holidays in Victoria (Australia) are defined by the provider class. - * - * @throws ReflectionException */ public function testOfficialHolidays(): void { @@ -62,6 +62,7 @@ public function testOfficialHolidays(): void /** * @throws ReflectionException + * @throws \Exception */ public function testSources(): void { diff --git a/tests/Australia/WesternAustralia/LabourDayTest.php b/tests/Australia/WesternAustralia/LabourDayTest.php index 9422ab63d..583bb8070 100644 --- a/tests/Australia/WesternAustralia/LabourDayTest.php +++ b/tests/Australia/WesternAustralia/LabourDayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -39,7 +38,6 @@ class LabourDayTest extends WesternAustraliaBaseTestCase implements HolidayTestC * @param int $year the year for which the holiday defined in this test needs to be tested * @param string $expected the expected date * - * @throws ReflectionException * @throws Exception */ public function testHoliday(int $year, string $expected): void @@ -77,7 +75,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -92,7 +90,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Australia/WesternAustralia/QueensBirthdayTest.php b/tests/Australia/WesternAustralia/QueensBirthdayTest.php index aa50f3a85..23dfedacb 100644 --- a/tests/Australia/WesternAustralia/QueensBirthdayTest.php +++ b/tests/Australia/WesternAustralia/QueensBirthdayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -44,7 +43,6 @@ class QueensBirthdayTest extends WesternAustraliaBaseTestCase implements Holiday * @param int $year the year for which the holiday defined in this test needs to be tested * @param string $expected the expected date * - * @throws ReflectionException * @throws Exception */ public function testHoliday(int $year, string $expected): void @@ -82,7 +80,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -97,7 +95,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Australia/WesternAustralia/WesternAustraliaDayTest.php b/tests/Australia/WesternAustralia/WesternAustraliaDayTest.php index a58c0e515..ec55944ce 100644 --- a/tests/Australia/WesternAustralia/WesternAustraliaDayTest.php +++ b/tests/Australia/WesternAustralia/WesternAustraliaDayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -39,7 +38,6 @@ class WesternAustraliaDayTest extends WesternAustraliaBaseTestCase implements Ho * @param int $year the year for which the holiday defined in this test needs to be tested * @param string $expected the expected date * - * @throws ReflectionException * @throws Exception */ public function testHoliday(int $year, string $expected): void @@ -77,7 +75,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -92,7 +90,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Australia/WesternAustralia/WesternAustraliaTest.php b/tests/Australia/WesternAustralia/WesternAustraliaTest.php index 6447710ef..42e2b05e7 100644 --- a/tests/Australia/WesternAustralia/WesternAustraliaTest.php +++ b/tests/Australia/WesternAustralia/WesternAustraliaTest.php @@ -26,10 +26,12 @@ class WesternAustraliaTest extends WesternAustraliaBaseTestCase implements Provi /** * @var int year random year number used for all tests in this Test Case */ - protected $year; + protected int $year; /** * Initial setup of this Test Case. + * + * @throws \Exception */ protected function setUp(): void { @@ -38,8 +40,6 @@ protected function setUp(): void /** * Tests if all official holidays in Western Australia (Australia) are defined by the provider class. - * - * @throws ReflectionException */ public function testOfficialHolidays(): void { @@ -59,6 +59,7 @@ public function testOfficialHolidays(): void /** * @throws ReflectionException + * @throws \Exception */ public function testSources(): void { diff --git a/tests/Austria/AllSaintsDayTest.php b/tests/Austria/AllSaintsDayTest.php index e8032d2a0..3a21f53e1 100644 --- a/tests/Austria/AllSaintsDayTest.php +++ b/tests/Austria/AllSaintsDayTest.php @@ -16,7 +16,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -37,8 +36,6 @@ class AllSaintsDayTest extends AustriaBaseTestCase implements HolidayTestCase * * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testHoliday(int $year, DateTime $expected): void { @@ -60,7 +57,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -75,7 +72,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Austria/AscensionDayTest.php b/tests/Austria/AscensionDayTest.php index b952b6bb0..2598db313 100644 --- a/tests/Austria/AscensionDayTest.php +++ b/tests/Austria/AscensionDayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -35,7 +34,6 @@ class AscensionDayTest extends AustriaBaseTestCase implements HolidayTestCase * Tests the holiday defined in this test. * * @throws Exception - * @throws ReflectionException */ public function testHoliday(): void { @@ -51,7 +49,7 @@ public function testHoliday(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -66,7 +64,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Austria/AssumptionOfMaryTest.php b/tests/Austria/AssumptionOfMaryTest.php index c31d8569c..79b48b6a6 100644 --- a/tests/Austria/AssumptionOfMaryTest.php +++ b/tests/Austria/AssumptionOfMaryTest.php @@ -16,7 +16,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -37,8 +36,6 @@ class AssumptionOfMaryTest extends AustriaBaseTestCase implements HolidayTestCas * * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testHoliday(int $year, DateTime $expected): void { @@ -60,7 +57,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -75,7 +72,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Austria/AustriaTest.php b/tests/Austria/AustriaTest.php index 491a70ba6..76015bd23 100644 --- a/tests/Austria/AustriaTest.php +++ b/tests/Austria/AustriaTest.php @@ -30,6 +30,8 @@ class AustriaTest extends AustriaBaseTestCase implements ProviderTestCase /** * Initial setup of this Test Case. + * + * @throws \Exception */ protected function setUp(): void { @@ -38,8 +40,6 @@ protected function setUp(): void /** * Tests if all official holidays in Austria are defined by the provider class. - * - * @throws ReflectionException */ public function testOfficialHolidays(): void { @@ -62,8 +62,6 @@ public function testOfficialHolidays(): void /** * Tests if all observed holidays in Austria are defined by the provider class. - * - * @throws ReflectionException */ public function testObservedHolidays(): void { @@ -72,8 +70,6 @@ public function testObservedHolidays(): void /** * Tests if all seasonal holidays in Austria are defined by the provider class. - * - * @throws ReflectionException */ public function testSeasonalHolidays(): void { @@ -82,8 +78,6 @@ public function testSeasonalHolidays(): void /** * Tests if all bank holidays in Austria are defined by the provider class. - * - * @throws ReflectionException */ public function testBankHolidays(): void { @@ -92,8 +86,6 @@ public function testBankHolidays(): void /** * Tests if all other holidays in Austria are defined by the provider class. - * - * @throws ReflectionException */ public function testOtherHolidays(): void { @@ -102,6 +94,7 @@ public function testOtherHolidays(): void /** * @throws ReflectionException + * @throws \Exception */ public function testSources(): void { diff --git a/tests/Austria/Burgenland/BurgenlandTest.php b/tests/Austria/Burgenland/BurgenlandTest.php index cdaf6f31e..72c872459 100644 --- a/tests/Austria/Burgenland/BurgenlandTest.php +++ b/tests/Austria/Burgenland/BurgenlandTest.php @@ -30,6 +30,8 @@ class BurgenlandTest extends BurgenlandBaseTestCase implements ProviderTestCase /** * Initial setup of this Test Case. + * + * @throws \Exception */ protected function setUp(): void { @@ -38,8 +40,6 @@ protected function setUp(): void /** * Tests if all official holidays in Burgenland (Austria) are defined by the provider class. - * - * @throws ReflectionException */ public function testOfficialHolidays(): void { @@ -68,8 +68,6 @@ public function testOfficialHolidays(): void /** * Tests if all observed holidays in Burgenland (Austria) are defined by the provider class. - * - * @throws ReflectionException */ public function testObservedHolidays(): void { @@ -78,8 +76,6 @@ public function testObservedHolidays(): void /** * Tests if all seasonal holidays in Burgenland (Austria) are defined by the provider class. - * - * @throws ReflectionException */ public function testSeasonalHolidays(): void { @@ -88,8 +84,6 @@ public function testSeasonalHolidays(): void /** * Tests if all bank holidays in Burgenland (Austria) are defined by the provider class. - * - * @throws ReflectionException */ public function testBankHolidays(): void { @@ -98,8 +92,6 @@ public function testBankHolidays(): void /** * Tests if all other holidays in Burgenland (Austria) are defined by the provider class. - * - * @throws ReflectionException */ public function testOtherHolidays(): void { @@ -108,6 +100,7 @@ public function testOtherHolidays(): void /** * @throws ReflectionException + * @throws \Exception */ public function testSources(): void { diff --git a/tests/Austria/Burgenland/stMartinsDayTest.php b/tests/Austria/Burgenland/stMartinsDayTest.php index 0bb8ce04c..1600e642e 100644 --- a/tests/Austria/Burgenland/stMartinsDayTest.php +++ b/tests/Austria/Burgenland/stMartinsDayTest.php @@ -16,7 +16,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -37,8 +36,6 @@ class stMartinsDayTest extends BurgenlandBaseTestCase implements HolidayTestCase * * @param int $year the year for which Saint Martins Day needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function teststMartinsDay(int $year, DateTime $expected): void { @@ -60,7 +57,7 @@ public function stMartinsDayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -75,7 +72,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Austria/Carinthia/CarinthiaTest.php b/tests/Austria/Carinthia/CarinthiaTest.php index 79e9acb3b..7b58a548c 100644 --- a/tests/Austria/Carinthia/CarinthiaTest.php +++ b/tests/Austria/Carinthia/CarinthiaTest.php @@ -30,6 +30,8 @@ class CarinthiaTest extends CarinthiaBaseTestCase implements ProviderTestCase /** * Initial setup of this Test Case. + * + * @throws \Exception */ protected function setUp(): void { @@ -38,8 +40,6 @@ protected function setUp(): void /** * Tests if all official holidays in Carinthia (Austria) are defined by the provider class. - * - * @throws ReflectionException */ public function testOfficialHolidays(): void { @@ -72,8 +72,6 @@ public function testOfficialHolidays(): void /** * Tests if all observed holidays in Carinthia (Austria) are defined by the provider class. - * - * @throws ReflectionException */ public function testObservedHolidays(): void { @@ -82,8 +80,6 @@ public function testObservedHolidays(): void /** * Tests if all seasonal holidays in Carinthia (Austria) are defined by the provider class. - * - * @throws ReflectionException */ public function testSeasonalHolidays(): void { @@ -92,8 +88,6 @@ public function testSeasonalHolidays(): void /** * Tests if all bank holidays in Carinthia (Austria) are defined by the provider class. - * - * @throws ReflectionException */ public function testBankHolidays(): void { @@ -102,8 +96,6 @@ public function testBankHolidays(): void /** * Tests if all other holidays in Carinthia (Austria) are defined by the provider class. - * - * @throws ReflectionException */ public function testOtherHolidays(): void { @@ -112,6 +104,7 @@ public function testOtherHolidays(): void /** * @throws ReflectionException + * @throws \Exception */ public function testSources(): void { diff --git a/tests/Austria/Carinthia/PlebisciteDayTest.php b/tests/Austria/Carinthia/PlebisciteDayTest.php index ea0bda51c..7fcf95fcd 100644 --- a/tests/Austria/Carinthia/PlebisciteDayTest.php +++ b/tests/Austria/Carinthia/PlebisciteDayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -43,8 +42,6 @@ class PlebisciteDayTest extends CarinthiaBaseTestCase implements HolidayTestCase * * @param int $year the year for which Plebiscite Day needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testPlebisciteDay(int $year, DateTime $expected): void { @@ -73,7 +70,7 @@ public function PlebisciteDayDataProvider(): array /** * Tests the holiday defined in this test before establishment. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayBeforeEstablishment(): void { @@ -87,7 +84,7 @@ public function testHolidayBeforeEstablishment(): void /** * Tests translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -102,7 +99,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Austria/Carinthia/StJosephsDayTest.php b/tests/Austria/Carinthia/StJosephsDayTest.php index 6504849f7..be01f9ff7 100644 --- a/tests/Austria/Carinthia/StJosephsDayTest.php +++ b/tests/Austria/Carinthia/StJosephsDayTest.php @@ -16,7 +16,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -37,8 +36,6 @@ class StJosephsDayTest extends CarinthiaBaseTestCase implements HolidayTestCase * * @param int $year the year for which St. Joseph's Day needs to be tested. * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testStJosephsDay(int $year, DateTime $expected): void { @@ -60,7 +57,7 @@ public function StJosephsDayDataProvider(): array /** * Tests translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -75,7 +72,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Austria/ChristmasTest.php b/tests/Austria/ChristmasTest.php index 10c5eae0e..4373654bf 100644 --- a/tests/Austria/ChristmasTest.php +++ b/tests/Austria/ChristmasTest.php @@ -16,7 +16,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -37,8 +36,6 @@ class ChristmasTest extends AustriaBaseTestCase implements HolidayTestCase * * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testHoliday(int $year, DateTime $expected): void { @@ -60,7 +57,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -75,7 +72,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Austria/CorpusChristiTest.php b/tests/Austria/CorpusChristiTest.php index 1b5dfe0fa..2eb327f0d 100644 --- a/tests/Austria/CorpusChristiTest.php +++ b/tests/Austria/CorpusChristiTest.php @@ -16,7 +16,6 @@ use DateInterval; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\Provider\ChristianHolidays; use Yasumi\tests\HolidayTestCase; @@ -37,7 +36,6 @@ class CorpusChristiTest extends AustriaBaseTestCase implements HolidayTestCase * Tests the holiday defined in this test. * * @throws Exception - * @throws ReflectionException */ public function testHoliday(): void { @@ -53,7 +51,7 @@ public function testHoliday(): void /** * Tests translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -68,7 +66,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Austria/EasterMondayTest.php b/tests/Austria/EasterMondayTest.php index e3b3fafcd..3ac452316 100644 --- a/tests/Austria/EasterMondayTest.php +++ b/tests/Austria/EasterMondayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -35,7 +34,6 @@ class EasterMondayTest extends AustriaBaseTestCase implements HolidayTestCase * Tests the holiday defined in this test. * * @throws Exception - * @throws ReflectionException */ public function testHoliday(): void { @@ -51,7 +49,7 @@ public function testHoliday(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -66,7 +64,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Austria/EasterTest.php b/tests/Austria/EasterTest.php index 362f49c16..3228a0365 100644 --- a/tests/Austria/EasterTest.php +++ b/tests/Austria/EasterTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -35,7 +34,6 @@ class EasterTest extends AustriaBaseTestCase implements HolidayTestCase * Tests the holiday defined in this test. * * @throws Exception - * @throws ReflectionException */ public function testHoliday(): void { @@ -51,7 +49,7 @@ public function testHoliday(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -66,7 +64,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Austria/EpiphanyTest.php b/tests/Austria/EpiphanyTest.php index 911541038..1373e4d8c 100644 --- a/tests/Austria/EpiphanyTest.php +++ b/tests/Austria/EpiphanyTest.php @@ -16,7 +16,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -37,8 +36,6 @@ class EpiphanyTest extends AustriaBaseTestCase implements HolidayTestCase * * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testHoliday(int $year, DateTime $expected): void { @@ -60,7 +57,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -75,7 +72,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Austria/ImmaculateConceptionTest.php b/tests/Austria/ImmaculateConceptionTest.php index e508ecb96..0499dd59a 100644 --- a/tests/Austria/ImmaculateConceptionTest.php +++ b/tests/Austria/ImmaculateConceptionTest.php @@ -16,7 +16,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -37,8 +36,6 @@ class ImmaculateConceptionTest extends AustriaBaseTestCase implements HolidayTes * * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testHoliday(int $year, DateTime $expected): void { @@ -60,7 +57,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -75,7 +72,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Austria/InternationalWorkersDayTest.php b/tests/Austria/InternationalWorkersDayTest.php index 771d48d4f..652f25fdf 100644 --- a/tests/Austria/InternationalWorkersDayTest.php +++ b/tests/Austria/InternationalWorkersDayTest.php @@ -16,7 +16,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -37,8 +36,6 @@ class InternationalWorkersDayTest extends AustriaBaseTestCase implements Holiday * * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testHoliday(int $year, DateTime $expected): void { @@ -60,7 +57,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -75,7 +72,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Austria/LowerAustria/LowerAustriaTest.php b/tests/Austria/LowerAustria/LowerAustriaTest.php index 6295481fb..7bced1f7f 100644 --- a/tests/Austria/LowerAustria/LowerAustriaTest.php +++ b/tests/Austria/LowerAustria/LowerAustriaTest.php @@ -30,6 +30,8 @@ class LowerAustriaTest extends LowerAustriaBaseTestCase implements ProviderTestC /** * Initial setup of this Test Case. + * + * @throws \Exception */ protected function setUp(): void { @@ -38,8 +40,6 @@ protected function setUp(): void /** * Tests if all official holidays in Lower Austria (Austria) are defined by the provider class. - * - * @throws ReflectionException */ public function testOfficialHolidays(): void { @@ -71,8 +71,6 @@ public function testOfficialHolidays(): void /** * Tests if all observed holidays in Lower Austria (Austria) are defined by the provider class. - * - * @throws ReflectionException */ public function testObservedHolidays(): void { @@ -81,8 +79,6 @@ public function testObservedHolidays(): void /** * Tests if all seasonal holidays in Lower Austria (Austria) are defined by the provider class. - * - * @throws ReflectionException */ public function testSeasonalHolidays(): void { @@ -91,8 +87,6 @@ public function testSeasonalHolidays(): void /** * Tests if all bank holidays in Lower Austria (Austria) are defined by the provider class. - * - * @throws ReflectionException */ public function testBankHolidays(): void { @@ -101,8 +95,6 @@ public function testBankHolidays(): void /** * Tests if all other holidays in Lower Austria (Austria) are defined by the provider class. - * - * @throws ReflectionException */ public function testOtherHolidays(): void { @@ -111,6 +103,7 @@ public function testOtherHolidays(): void /** * @throws ReflectionException + * @throws \Exception */ public function testSources(): void { diff --git a/tests/Austria/LowerAustria/StLeopoldsDayTest.php b/tests/Austria/LowerAustria/StLeopoldsDayTest.php index 5436b7c84..d14f2ba22 100644 --- a/tests/Austria/LowerAustria/StLeopoldsDayTest.php +++ b/tests/Austria/LowerAustria/StLeopoldsDayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -43,8 +42,6 @@ class StLeopoldsDayTest extends LowerAustriaBaseTestCase implements HolidayTestC * * @param int $year the year for which Saint Leopold's Day needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testStLeopoldsDay(int $year, DateTime $expected): void { @@ -73,7 +70,7 @@ public function StLeopoldsDayDataProvider(): array /** * Tests the holiday defined in this test before establishment. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayBeforeEstablishment(): void { @@ -87,7 +84,7 @@ public function testHolidayBeforeEstablishment(): void /** * Tests translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -102,7 +99,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Austria/NationalDayTest.php b/tests/Austria/NationalDayTest.php index 4dae40559..8cba12015 100644 --- a/tests/Austria/NationalDayTest.php +++ b/tests/Austria/NationalDayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -40,7 +39,6 @@ class NationalDayTest extends AustriaBaseTestCase implements HolidayTestCase * Tests the holiday defined in this test on or after establishment. * * @throws Exception - * @throws ReflectionException */ public function testHolidayOnAfterEstablishment(): void { @@ -56,7 +54,7 @@ public function testHolidayOnAfterEstablishment(): void /** * Tests the holiday defined in this test before establishment. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayBeforeEstablishment(): void { @@ -70,7 +68,7 @@ public function testHolidayBeforeEstablishment(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -85,7 +83,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Austria/NewYearsDayTest.php b/tests/Austria/NewYearsDayTest.php index 79e578fe2..73d5588a0 100644 --- a/tests/Austria/NewYearsDayTest.php +++ b/tests/Austria/NewYearsDayTest.php @@ -16,7 +16,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -37,8 +36,6 @@ class NewYearsDayTest extends AustriaBaseTestCase implements HolidayTestCase * * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testHoliday(int $year, DateTime $expected): void { @@ -60,7 +57,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -75,7 +72,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Austria/PentecostMondayTest.php b/tests/Austria/PentecostMondayTest.php index 8a9ef2cd4..779313ef1 100644 --- a/tests/Austria/PentecostMondayTest.php +++ b/tests/Austria/PentecostMondayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -35,7 +34,6 @@ class PentecostMondayTest extends AustriaBaseTestCase implements HolidayTestCase * Tests the holiday defined in this test. * * @throws Exception - * @throws ReflectionException */ public function testHoliday(): void { @@ -51,7 +49,7 @@ public function testHoliday(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -66,7 +64,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Austria/PentecostTest.php b/tests/Austria/PentecostTest.php index caed66870..f7099bd0e 100644 --- a/tests/Austria/PentecostTest.php +++ b/tests/Austria/PentecostTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -35,7 +34,6 @@ class PentecostTest extends AustriaBaseTestCase implements HolidayTestCase * Tests the holiday defined in this test. * * @throws Exception - * @throws ReflectionException */ public function testHoliday(): void { @@ -51,7 +49,7 @@ public function testHoliday(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -66,7 +64,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Austria/Salzburg/SalzburgTest.php b/tests/Austria/Salzburg/SalzburgTest.php index b0587b605..861598bff 100644 --- a/tests/Austria/Salzburg/SalzburgTest.php +++ b/tests/Austria/Salzburg/SalzburgTest.php @@ -30,6 +30,8 @@ class SalzburgTest extends SalzburgBaseTestCase implements ProviderTestCase /** * Initial setup of this Test Case. + * + * @throws \Exception */ protected function setUp(): void { @@ -38,8 +40,6 @@ protected function setUp(): void /** * Tests if all official holidays in Salzburg (Austria) are defined by the provider class. - * - * @throws ReflectionException */ public function testOfficialHolidays(): void { @@ -71,8 +71,6 @@ public function testOfficialHolidays(): void /** * Tests if all observed holidays in Salzburg (Austria) are defined by the provider class. - * - * @throws ReflectionException */ public function testObservedHolidays(): void { @@ -81,8 +79,6 @@ public function testObservedHolidays(): void /** * Tests if all seasonal holidays in Salzburg (Austria) are defined by the provider class. - * - * @throws ReflectionException */ public function testSeasonalHolidays(): void { @@ -91,8 +87,6 @@ public function testSeasonalHolidays(): void /** * Tests if all bank holidays in Salzburg (Austria) are defined by the provider class. - * - * @throws ReflectionException */ public function testBankHolidays(): void { @@ -101,8 +95,6 @@ public function testBankHolidays(): void /** * Tests if all other holidays in Salzburg (Austria) are defined by the provider class. - * - * @throws ReflectionException */ public function testOtherHolidays(): void { @@ -111,6 +103,7 @@ public function testOtherHolidays(): void /** * @throws ReflectionException + * @throws \Exception */ public function testSources(): void { diff --git a/tests/Austria/Salzburg/StRupertsDayTest.php b/tests/Austria/Salzburg/StRupertsDayTest.php index b723e0a1b..880385ea2 100644 --- a/tests/Austria/Salzburg/StRupertsDayTest.php +++ b/tests/Austria/Salzburg/StRupertsDayTest.php @@ -16,7 +16,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -37,8 +36,6 @@ class StRupertsDayTest extends SalzburgBaseTestCase implements HolidayTestCase * * @param int $year the year for which Saint Rupert's Day needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testStRupertsDay(int $year, DateTime $expected): void { @@ -60,7 +57,7 @@ public function StRupertsDayDataProvider(): array /** * Tests translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -75,7 +72,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Austria/SecondChristmasDayTest.php b/tests/Austria/SecondChristmasDayTest.php index 582855b89..4d0a82886 100644 --- a/tests/Austria/SecondChristmasDayTest.php +++ b/tests/Austria/SecondChristmasDayTest.php @@ -16,7 +16,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -37,8 +36,6 @@ class SecondChristmasDayTest extends AustriaBaseTestCase implements HolidayTestC * * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testHoliday(int $year, DateTime $expected): void { @@ -60,7 +57,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -75,7 +72,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Austria/Styria/StJosephsDayTest.php b/tests/Austria/Styria/StJosephsDayTest.php index 935e2abf9..c3d55e3bd 100644 --- a/tests/Austria/Styria/StJosephsDayTest.php +++ b/tests/Austria/Styria/StJosephsDayTest.php @@ -16,7 +16,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -37,8 +36,6 @@ class StJosephsDayTest extends StyriaBaseTestCase implements HolidayTestCase * * @param int $year the year for which St. Joseph's Day needs to be tested. * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testStJosephsDay(int $year, DateTime $expected): void { @@ -60,7 +57,7 @@ public function StJosephsDayDataProvider(): array /** * Tests translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -75,7 +72,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Austria/Styria/StyriaTest.php b/tests/Austria/Styria/StyriaTest.php index 5b1f24e6b..9e777e8c0 100644 --- a/tests/Austria/Styria/StyriaTest.php +++ b/tests/Austria/Styria/StyriaTest.php @@ -30,6 +30,8 @@ class StyriaTest extends StyriaBaseTestCase implements ProviderTestCase /** * Initial setup of this Test Case. + * + * @throws \Exception */ protected function setUp(): void { @@ -38,8 +40,6 @@ protected function setUp(): void /** * Tests if all official holidays in Styria (Austria) are defined by the provider class. - * - * @throws ReflectionException */ public function testOfficialHolidays(): void { @@ -68,8 +68,6 @@ public function testOfficialHolidays(): void /** * Tests if all observed holidays in Styria (Austria) are defined by the provider class. - * - * @throws ReflectionException */ public function testObservedHolidays(): void { @@ -78,8 +76,6 @@ public function testObservedHolidays(): void /** * Tests if all seasonal holidays in Styria (Austria) are defined by the provider class. - * - * @throws ReflectionException */ public function testSeasonalHolidays(): void { @@ -88,8 +84,6 @@ public function testSeasonalHolidays(): void /** * Tests if all bank holidays in Styria (Austria) are defined by the provider class. - * - * @throws ReflectionException */ public function testBankHolidays(): void { @@ -98,8 +92,6 @@ public function testBankHolidays(): void /** * Tests if all other holidays in Styria (Austria) are defined by the provider class. - * - * @throws ReflectionException */ public function testOtherHolidays(): void { @@ -108,6 +100,7 @@ public function testOtherHolidays(): void /** * @throws ReflectionException + * @throws \Exception */ public function testSources(): void { diff --git a/tests/Austria/Tyrol/StJosephsDayTest.php b/tests/Austria/Tyrol/StJosephsDayTest.php index a5eae304c..6894d92e5 100644 --- a/tests/Austria/Tyrol/StJosephsDayTest.php +++ b/tests/Austria/Tyrol/StJosephsDayTest.php @@ -16,7 +16,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -37,8 +36,6 @@ class StJosephsDayTest extends TyrolBaseTestCase implements HolidayTestCase * * @param int $year the year for which St. Joseph's Day needs to be tested. * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testStJosephsDay(int $year, DateTime $expected): void { @@ -60,7 +57,7 @@ public function StJosephsDayDataProvider(): array /** * Tests translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -75,7 +72,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Austria/Tyrol/TyrolTest.php b/tests/Austria/Tyrol/TyrolTest.php index ac08b857c..211b0e21e 100644 --- a/tests/Austria/Tyrol/TyrolTest.php +++ b/tests/Austria/Tyrol/TyrolTest.php @@ -30,6 +30,8 @@ class TyrolTest extends TyrolBaseTestCase implements ProviderTestCase /** * Initial setup of this Test Case. + * + * @throws \Exception */ protected function setUp(): void { @@ -38,8 +40,6 @@ protected function setUp(): void /** * Tests if all official holidays in Tyrol (Austria) are defined by the provider class. - * - * @throws ReflectionException */ public function testOfficialHolidays(): void { @@ -68,8 +68,6 @@ public function testOfficialHolidays(): void /** * Tests if all observed holidays in Tyrol (Austria) are defined by the provider class. - * - * @throws ReflectionException */ public function testObservedHolidays(): void { @@ -78,8 +76,6 @@ public function testObservedHolidays(): void /** * Tests if all seasonal holidays in Tyrol (Austria) are defined by the provider class. - * - * @throws ReflectionException */ public function testSeasonalHolidays(): void { @@ -88,8 +84,6 @@ public function testSeasonalHolidays(): void /** * Tests if all bank holidays in Tyrol (Austria) are defined by the provider class. - * - * @throws ReflectionException */ public function testBankHolidays(): void { @@ -98,8 +92,6 @@ public function testBankHolidays(): void /** * Tests if all other holidays in Tyrol (Austria) are defined by the provider class. - * - * @throws ReflectionException */ public function testOtherHolidays(): void { @@ -108,6 +100,7 @@ public function testOtherHolidays(): void /** * @throws ReflectionException + * @throws \Exception */ public function testSources(): void { diff --git a/tests/Austria/UpperAustria/StFloriansDayTest.php b/tests/Austria/UpperAustria/StFloriansDayTest.php index d5e9db4f7..5bdd1d540 100644 --- a/tests/Austria/UpperAustria/StFloriansDayTest.php +++ b/tests/Austria/UpperAustria/StFloriansDayTest.php @@ -16,7 +16,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -37,8 +36,6 @@ class StFloriansDayTest extends UpperAustriaBaseTestCase implements HolidayTestC * * @param int $year the year for which Saint Florian's Day needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testStFloriansDay(int $year, DateTime $expected): void { @@ -60,7 +57,7 @@ public function StFloriansDayDataProvider(): array /** * Tests translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -75,7 +72,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Austria/UpperAustria/UpperAustriaTest.php b/tests/Austria/UpperAustria/UpperAustriaTest.php index a6c91b0cf..36cbce30c 100644 --- a/tests/Austria/UpperAustria/UpperAustriaTest.php +++ b/tests/Austria/UpperAustria/UpperAustriaTest.php @@ -30,6 +30,8 @@ class UpperAustriaTest extends UpperAustriaBaseTestCase implements ProviderTestC /** * Initial setup of this Test Case. + * + * @throws \Exception */ protected function setUp(): void { @@ -38,8 +40,6 @@ protected function setUp(): void /** * Tests if all official holidays in Upper Austria (Austria) are defined by the provider class. - * - * @throws ReflectionException */ public function testOfficialHolidays(): void { @@ -71,8 +71,6 @@ public function testOfficialHolidays(): void /** * Tests if all observed holidays in Upper Austria (Austria) are defined by the provider class. - * - * @throws ReflectionException */ public function testObservedHolidays(): void { @@ -81,8 +79,6 @@ public function testObservedHolidays(): void /** * Tests if all seasonal holidays in Upper Austria (Austria) are defined by the provider class. - * - * @throws ReflectionException */ public function testSeasonalHolidays(): void { @@ -91,8 +87,6 @@ public function testSeasonalHolidays(): void /** * Tests if all bank holidays in Upper Austria (Austria) are defined by the provider class. - * - * @throws ReflectionException */ public function testBankHolidays(): void { @@ -101,8 +95,6 @@ public function testBankHolidays(): void /** * Tests if all other holidays in Upper Austria (Austria) are defined by the provider class. - * - * @throws ReflectionException */ public function testOtherHolidays(): void { @@ -111,6 +103,7 @@ public function testOtherHolidays(): void /** * @throws ReflectionException + * @throws \Exception */ public function testSources(): void { diff --git a/tests/Austria/Vienna/StLeopoldsDayTest.php b/tests/Austria/Vienna/StLeopoldsDayTest.php index a40e0cf1d..ca1dbd237 100644 --- a/tests/Austria/Vienna/StLeopoldsDayTest.php +++ b/tests/Austria/Vienna/StLeopoldsDayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -43,8 +42,6 @@ class StLeopoldsDayTest extends ViennaBaseTestCase implements HolidayTestCase * * @param int $year the year for which Saint Leopold's Day needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testStLeopoldsDay(int $year, DateTime $expected): void { @@ -73,7 +70,7 @@ public function StLeopoldsDayDataProvider(): array /** * Tests the holiday defined in this test before establishment. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayBeforeEstablishment(): void { @@ -87,7 +84,7 @@ public function testHolidayBeforeEstablishment(): void /** * Tests translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -102,7 +99,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Austria/Vienna/ViennaTest.php b/tests/Austria/Vienna/ViennaTest.php index 8eebe56ce..6b2e56884 100644 --- a/tests/Austria/Vienna/ViennaTest.php +++ b/tests/Austria/Vienna/ViennaTest.php @@ -30,6 +30,8 @@ class ViennaTest extends ViennaBaseTestCase implements ProviderTestCase /** * Initial setup of this Test Case. + * + * @throws \Exception */ protected function setUp(): void { @@ -38,8 +40,6 @@ protected function setUp(): void /** * Tests if all official holidays in Vienna (Austria) are defined by the provider class. - * - * @throws ReflectionException */ public function testOfficialHolidays(): void { @@ -71,8 +71,6 @@ public function testOfficialHolidays(): void /** * Tests if all observed holidays in Vienna (Austria) are defined by the provider class. - * - * @throws ReflectionException */ public function testObservedHolidays(): void { @@ -81,8 +79,6 @@ public function testObservedHolidays(): void /** * Tests if all seasonal holidays in Vienna (Austria) are defined by the provider class. - * - * @throws ReflectionException */ public function testSeasonalHolidays(): void { @@ -91,8 +87,6 @@ public function testSeasonalHolidays(): void /** * Tests if all bank holidays in Vienna (Austria) are defined by the provider class. - * - * @throws ReflectionException */ public function testBankHolidays(): void { @@ -101,8 +95,6 @@ public function testBankHolidays(): void /** * Tests if all other holidays in Vienna (Austria) are defined by the provider class. - * - * @throws ReflectionException */ public function testOtherHolidays(): void { @@ -111,6 +103,7 @@ public function testOtherHolidays(): void /** * @throws ReflectionException + * @throws \Exception */ public function testSources(): void { diff --git a/tests/Austria/Vorarlberg/StJosephsDayTest.php b/tests/Austria/Vorarlberg/StJosephsDayTest.php index ff2e21227..12b6ae4e0 100644 --- a/tests/Austria/Vorarlberg/StJosephsDayTest.php +++ b/tests/Austria/Vorarlberg/StJosephsDayTest.php @@ -16,7 +16,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -37,8 +36,6 @@ class StJosephsDayTest extends VorarlbergBaseTestCase implements HolidayTestCase * * @param int $year the year for which St. Joseph's Day needs to be tested. * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testStJosephsDay(int $year, DateTime $expected): void { @@ -60,7 +57,7 @@ public function StJosephsDayDataProvider(): array /** * Tests translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -75,7 +72,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Austria/Vorarlberg/VorarlbergTest.php b/tests/Austria/Vorarlberg/VorarlbergTest.php index 24c7713ac..5d9a1542c 100644 --- a/tests/Austria/Vorarlberg/VorarlbergTest.php +++ b/tests/Austria/Vorarlberg/VorarlbergTest.php @@ -30,6 +30,8 @@ class VorarlbergTest extends VorarlbergBaseTestCase implements ProviderTestCase /** * Initial setup of this Test Case. + * + * @throws \Exception */ protected function setUp(): void { @@ -38,8 +40,6 @@ protected function setUp(): void /** * Tests if all official holidays in Vorarlberg (Austria) are defined by the provider class. - * - * @throws ReflectionException */ public function testOfficialHolidays(): void { @@ -68,8 +68,6 @@ public function testOfficialHolidays(): void /** * Tests if all observed holidays in Vorarlberg (Austria) are defined by the provider class. - * - * @throws ReflectionException */ public function testObservedHolidays(): void { @@ -78,8 +76,6 @@ public function testObservedHolidays(): void /** * Tests if all seasonal holidays in Vorarlberg (Austria) are defined by the provider class. - * - * @throws ReflectionException */ public function testSeasonalHolidays(): void { @@ -88,8 +84,6 @@ public function testSeasonalHolidays(): void /** * Tests if all bank holidays in Vorarlberg (Austria) are defined by the provider class. - * - * @throws ReflectionException */ public function testBankHolidays(): void { @@ -98,8 +92,6 @@ public function testBankHolidays(): void /** * Tests if all other holidays in Vorarlberg (Austria) are defined by the provider class. - * - * @throws ReflectionException */ public function testOtherHolidays(): void { @@ -108,6 +100,7 @@ public function testOtherHolidays(): void /** * @throws ReflectionException + * @throws \Exception */ public function testSources(): void { diff --git a/tests/Base/TypographyTest.php b/tests/Base/TypographyTest.php index b6f3b22c0..36e44b9f5 100644 --- a/tests/Base/TypographyTest.php +++ b/tests/Base/TypographyTest.php @@ -52,6 +52,7 @@ public function testTranslations(string $name, string $class, string $key, strin * @return array list of test translations * * @throws \ReflectionException + * @throws \Exception */ public function translationProvider(): array { diff --git a/tests/Base/WeekendTest.php b/tests/Base/WeekendTest.php index 8a2695b7d..fcf26574c 100644 --- a/tests/Base/WeekendTest.php +++ b/tests/Base/WeekendTest.php @@ -35,8 +35,6 @@ class WeekendTest extends TestCase * Holiday Provider is created. * * @dataProvider dataProviderWeekendDays - * - * @throws \ReflectionException */ public function testWeekendDay(\DateTimeImmutable $date): void { @@ -79,8 +77,6 @@ public function dataProviderWeekendDays(): array * Holiday Provider is created. * * @dataProvider dataProviderNonWeekendDays - * - * @throws \ReflectionException */ public function testNonWeekendDay(\DateTimeImmutable $date): void { diff --git a/tests/Base/YasumiTest.php b/tests/Base/YasumiTest.php index 27d9dd0fe..9e164abc6 100644 --- a/tests/Base/YasumiTest.php +++ b/tests/Base/YasumiTest.php @@ -114,7 +114,7 @@ public function testGetYear(): void /** * Tests that the next function returns the next upcoming date (i.e. next year) for the given holiday. * - * @throws ReflectionException + * @throws Exception */ public function testNext(): void { @@ -141,7 +141,7 @@ public function testNextWithBlankKey(): void /** * Tests the previous function returns the previous date (i.e. previous year) for the given holiday. * - * @throws ReflectionException + * @throws Exception */ public function testPrevious(): void { diff --git a/tests/Belgium/AllSaintsDayTest.php b/tests/Belgium/AllSaintsDayTest.php index 2d9bd2255..d45c5292e 100644 --- a/tests/Belgium/AllSaintsDayTest.php +++ b/tests/Belgium/AllSaintsDayTest.php @@ -16,7 +16,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -37,8 +36,6 @@ class AllSaintsDayTest extends BelgiumBaseTestCase implements HolidayTestCase * * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testHoliday(int $year, DateTime $expected): void { @@ -60,7 +57,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -75,7 +72,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Belgium/ArmisticeDayTest.php b/tests/Belgium/ArmisticeDayTest.php index fbffaad1d..0906630fd 100644 --- a/tests/Belgium/ArmisticeDayTest.php +++ b/tests/Belgium/ArmisticeDayTest.php @@ -16,7 +16,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -37,8 +36,6 @@ class ArmisticeDayTest extends BelgiumBaseTestCase implements HolidayTestCase * * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testHoliday(int $year, DateTime $expected): void { @@ -60,7 +57,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -75,7 +72,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Belgium/AscensionDayTest.php b/tests/Belgium/AscensionDayTest.php index d094730df..9a7c1c4a8 100644 --- a/tests/Belgium/AscensionDayTest.php +++ b/tests/Belgium/AscensionDayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -35,7 +34,6 @@ class AscensionDayTest extends BelgiumBaseTestCase implements HolidayTestCase * Tests the holiday defined in this test. * * @throws Exception - * @throws ReflectionException */ public function testHoliday(): void { @@ -51,7 +49,7 @@ public function testHoliday(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -66,7 +64,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Belgium/AssumptionOfMaryTest.php b/tests/Belgium/AssumptionOfMaryTest.php index 2f11ee542..4461dfd4b 100644 --- a/tests/Belgium/AssumptionOfMaryTest.php +++ b/tests/Belgium/AssumptionOfMaryTest.php @@ -16,7 +16,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -37,8 +36,6 @@ class AssumptionOfMaryTest extends BelgiumBaseTestCase implements HolidayTestCas * * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testHoliday(int $year, DateTime $expected): void { @@ -60,7 +57,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -75,7 +72,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Belgium/BelgiumTest.php b/tests/Belgium/BelgiumTest.php index 28779e5ed..1cc601171 100644 --- a/tests/Belgium/BelgiumTest.php +++ b/tests/Belgium/BelgiumTest.php @@ -29,6 +29,8 @@ class BelgiumTest extends BelgiumBaseTestCase /** * Initial setup of this Test Case. + * + * @throws \Exception */ protected function setUp(): void { @@ -37,8 +39,6 @@ protected function setUp(): void /** * Tests if all official holidays in Belgium are defined by the provider class. - * - * @throws ReflectionException */ public function testOfficialHolidays(): void { @@ -60,8 +60,6 @@ public function testOfficialHolidays(): void /** * Tests if all observed holidays in Belgium are defined by the provider class. - * - * @throws ReflectionException */ public function testObservedHolidays(): void { @@ -70,8 +68,6 @@ public function testObservedHolidays(): void /** * Tests if all seasonal holidays in Belgium are defined by the provider class. - * - * @throws ReflectionException */ public function testSeasonalHolidays(): void { @@ -80,8 +76,6 @@ public function testSeasonalHolidays(): void /** * Tests if all bank holidays in Belgium are defined by the provider class. - * - * @throws ReflectionException */ public function testBankHolidays(): void { @@ -90,8 +84,6 @@ public function testBankHolidays(): void /** * Tests if all other holidays in Belgium are defined by the provider class. - * - * @throws ReflectionException */ public function testOtherHolidays(): void { @@ -100,6 +92,7 @@ public function testOtherHolidays(): void /** * @throws ReflectionException + * @throws \Exception */ public function testSources(): void { diff --git a/tests/Belgium/ChristmasTest.php b/tests/Belgium/ChristmasTest.php index abacc016e..1b0186712 100644 --- a/tests/Belgium/ChristmasTest.php +++ b/tests/Belgium/ChristmasTest.php @@ -16,7 +16,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -37,8 +36,6 @@ class ChristmasTest extends BelgiumBaseTestCase implements HolidayTestCase * * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testHoliday(int $year, DateTime $expected): void { @@ -60,7 +57,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -75,7 +72,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Belgium/EasterMondayTest.php b/tests/Belgium/EasterMondayTest.php index 9ecfb2cfa..477d96e22 100644 --- a/tests/Belgium/EasterMondayTest.php +++ b/tests/Belgium/EasterMondayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -35,7 +34,6 @@ class EasterMondayTest extends BelgiumBaseTestCase implements HolidayTestCase * Tests the holiday defined in this test. * * @throws Exception - * @throws ReflectionException */ public function testHoliday(): void { @@ -51,7 +49,7 @@ public function testHoliday(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -66,7 +64,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Belgium/EasterTest.php b/tests/Belgium/EasterTest.php index c09320ff3..1d5161837 100644 --- a/tests/Belgium/EasterTest.php +++ b/tests/Belgium/EasterTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -35,7 +34,6 @@ class EasterTest extends BelgiumBaseTestCase implements HolidayTestCase * Tests Easter. * * @throws Exception - * @throws ReflectionException */ public function testEaster(): void { @@ -51,7 +49,7 @@ public function testEaster(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -66,7 +64,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Belgium/InternationalWorkersDayTest.php b/tests/Belgium/InternationalWorkersDayTest.php index d5a8640fb..2fd13c167 100644 --- a/tests/Belgium/InternationalWorkersDayTest.php +++ b/tests/Belgium/InternationalWorkersDayTest.php @@ -16,7 +16,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -37,8 +36,6 @@ class InternationalWorkersDayTest extends BelgiumBaseTestCase implements Holiday * * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testHoliday(int $year, DateTime $expected): void { @@ -60,7 +57,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -75,7 +72,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Belgium/NationalDayTest.php b/tests/Belgium/NationalDayTest.php index b3d6c7086..43e4e2419 100644 --- a/tests/Belgium/NationalDayTest.php +++ b/tests/Belgium/NationalDayTest.php @@ -16,7 +16,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -37,8 +36,6 @@ class NationalDayTest extends BelgiumBaseTestCase implements HolidayTestCase * * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testHoliday(int $year, DateTime $expected): void { @@ -60,7 +57,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -75,7 +72,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Belgium/NewYearsDayTest.php b/tests/Belgium/NewYearsDayTest.php index 713975296..6a671f436 100644 --- a/tests/Belgium/NewYearsDayTest.php +++ b/tests/Belgium/NewYearsDayTest.php @@ -16,7 +16,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -37,8 +36,6 @@ class NewYearsDayTest extends BelgiumBaseTestCase implements HolidayTestCase * * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testHoliday(int $year, DateTime $expected): void { @@ -60,7 +57,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -75,7 +72,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Belgium/PentecostTest.php b/tests/Belgium/PentecostTest.php index 0a1dfbaf4..0703498e5 100644 --- a/tests/Belgium/PentecostTest.php +++ b/tests/Belgium/PentecostTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -35,7 +34,6 @@ class PentecostTest extends BelgiumBaseTestCase implements HolidayTestCase * Tests Pentecost. * * @throws Exception - * @throws ReflectionException */ public function testHoliday(): void { @@ -51,7 +49,7 @@ public function testHoliday(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -66,7 +64,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Belgium/pentecostMondayTest.php b/tests/Belgium/pentecostMondayTest.php index 61c4607f8..5cc3b89d4 100644 --- a/tests/Belgium/pentecostMondayTest.php +++ b/tests/Belgium/pentecostMondayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -35,7 +34,6 @@ class pentecostMondayTest extends BelgiumBaseTestCase implements HolidayTestCase * Tests Pentecost Monday. * * @throws Exception - * @throws ReflectionException */ public function testHoliday(): void { @@ -51,7 +49,7 @@ public function testHoliday(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -66,7 +64,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Bosnia/BosniaTest.php b/tests/Bosnia/BosniaTest.php index 381461ef9..673532c57 100644 --- a/tests/Bosnia/BosniaTest.php +++ b/tests/Bosnia/BosniaTest.php @@ -30,6 +30,8 @@ class BosniaTest extends BosniaBaseTestCase implements ProviderTestCase /** * Initial setup of this Test Case. + * + * @throws \Exception */ protected function setUp(): void { @@ -38,8 +40,6 @@ protected function setUp(): void /** * Tests if all official holidays in Bosnia are defined by the provider class. - * - * @throws ReflectionException */ public function testOfficialHolidays(): void { @@ -59,8 +59,6 @@ public function testOfficialHolidays(): void /** * Tests if all observed holidays in Bosnia are defined by the provider class. - * - * @throws ReflectionException */ public function testObservedHolidays(): void { @@ -69,8 +67,6 @@ public function testObservedHolidays(): void /** * Tests if all seasonal holidays in Bosnia are defined by the provider class. - * - * @throws ReflectionException */ public function testSeasonalHolidays(): void { @@ -79,8 +75,6 @@ public function testSeasonalHolidays(): void /** * Tests if all bank holidays in Bosnia are defined by the provider class. - * - * @throws ReflectionException */ public function testBankHolidays(): void { @@ -89,8 +83,6 @@ public function testBankHolidays(): void /** * Tests if all other holidays in Bosnia are defined by the provider class. - * - * @throws ReflectionException */ public function testOtherHolidays(): void { @@ -99,6 +91,7 @@ public function testOtherHolidays(): void /** * @throws ReflectionException + * @throws \Exception */ public function testSources(): void { diff --git a/tests/Bosnia/ChristmasDayTest.php b/tests/Bosnia/ChristmasDayTest.php index 5fdd54db6..2216185fa 100644 --- a/tests/Bosnia/ChristmasDayTest.php +++ b/tests/Bosnia/ChristmasDayTest.php @@ -16,7 +16,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -37,8 +36,6 @@ class ChristmasDayTest extends BosniaBaseTestCase implements HolidayTestCase * * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testHoliday(int $year, DateTime $expected): void { @@ -60,7 +57,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -75,7 +72,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Bosnia/DayAfterNewYearsDay.php b/tests/Bosnia/DayAfterNewYearsDay.php index ffef673f6..8551a4cd7 100644 --- a/tests/Bosnia/DayAfterNewYearsDay.php +++ b/tests/Bosnia/DayAfterNewYearsDay.php @@ -16,7 +16,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -37,8 +36,6 @@ class DayAfterNewYearsDay extends BosniaBaseTestCase implements HolidayTestCase * * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testHoliday(int $year, DateTime $expected): void { @@ -60,7 +57,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -75,7 +72,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Bosnia/EasterTest.php b/tests/Bosnia/EasterTest.php index 655fd6305..f81df105c 100644 --- a/tests/Bosnia/EasterTest.php +++ b/tests/Bosnia/EasterTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -35,7 +34,6 @@ class EasterTest extends BosniaBaseTestCase implements HolidayTestCase * Tests the holiday defined in this test. * * @throws Exception - * @throws ReflectionException */ public function testHoliday(): void { @@ -51,7 +49,7 @@ public function testHoliday(): void /** * Tests translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -66,7 +64,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Bosnia/IndependenceDayTest.php b/tests/Bosnia/IndependenceDayTest.php index d57fdf9dd..c3080cdba 100644 --- a/tests/Bosnia/IndependenceDayTest.php +++ b/tests/Bosnia/IndependenceDayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -40,7 +39,6 @@ class IndependenceDayTest extends BosniaBaseTestCase implements HolidayTestCase * Tests Independence Day on or after 1992. * * @throws Exception - * @throws ReflectionException */ public function testIndependenceDayOnAfter1992(): void { @@ -56,7 +54,7 @@ public function testIndependenceDayOnAfter1992(): void /** * Tests Independence Day before 1992. * - * @throws ReflectionException + * @throws Exception */ public function testIndependenceDayBefore1992(): void { @@ -70,7 +68,7 @@ public function testIndependenceDayBefore1992(): void /** * Tests translated name of Independence Day. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -85,7 +83,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Bosnia/InternationalWorkersDayTest.php b/tests/Bosnia/InternationalWorkersDayTest.php index 2230e07de..d0867d17c 100644 --- a/tests/Bosnia/InternationalWorkersDayTest.php +++ b/tests/Bosnia/InternationalWorkersDayTest.php @@ -16,7 +16,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -37,8 +36,6 @@ class InternationalWorkersDayTest extends BosniaBaseTestCase implements HolidayT * * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testHoliday(int $year, DateTime $expected): void { @@ -48,7 +45,7 @@ public function testHoliday(int $year, DateTime $expected): void /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -63,7 +60,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Bosnia/NewYearsDayTest.php b/tests/Bosnia/NewYearsDayTest.php index 36dd23b96..8928675cb 100644 --- a/tests/Bosnia/NewYearsDayTest.php +++ b/tests/Bosnia/NewYearsDayTest.php @@ -16,7 +16,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -37,8 +36,6 @@ class NewYearsDayTest extends BosniaBaseTestCase implements HolidayTestCase * * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testHoliday(int $year, DateTime $expected): void { @@ -60,7 +57,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -75,7 +72,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Bosnia/OrthodoxChristmasDay.php b/tests/Bosnia/OrthodoxChristmasDay.php index eccde76df..90e7fdc93 100644 --- a/tests/Bosnia/OrthodoxChristmasDay.php +++ b/tests/Bosnia/OrthodoxChristmasDay.php @@ -16,7 +16,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -42,8 +41,6 @@ public function holidayDataProvider(): array /** * @dataProvider holidayDataProvider - * - * @throws ReflectionException */ public function testHoliday(int $year, DateTime $expected): void { @@ -53,7 +50,7 @@ public function testHoliday(int $year, DateTime $expected): void /** * {@inheritdoc} * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -68,7 +65,7 @@ public function testTranslation(): void /** * {@inheritdoc} * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Bosnia/SecondLabourDay.php b/tests/Bosnia/SecondLabourDay.php index 6790237a2..3848a82c8 100644 --- a/tests/Bosnia/SecondLabourDay.php +++ b/tests/Bosnia/SecondLabourDay.php @@ -16,7 +16,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -37,8 +36,6 @@ class SecondLabourDay extends BosniaBaseTestCase implements HolidayTestCase * * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testHoliday(int $year, DateTime $expected): void { @@ -48,7 +45,7 @@ public function testHoliday(int $year, DateTime $expected): void /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -63,7 +60,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Bosnia/StatehoodDayTest.php b/tests/Bosnia/StatehoodDayTest.php index 4d5f0c93f..0b2040a33 100644 --- a/tests/Bosnia/StatehoodDayTest.php +++ b/tests/Bosnia/StatehoodDayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -40,7 +39,6 @@ class StatehoodDayTest extends BosniaBaseTestCase implements HolidayTestCase * Tests Statehood Day on or after 1943. * * @throws Exception - * @throws ReflectionException */ public function testStatehoodDayOnAfter1943(): void { @@ -56,7 +54,7 @@ public function testStatehoodDayOnAfter1943(): void /** * Tests Statehood Day before 1943. * - * @throws ReflectionException + * @throws Exception */ public function testStatehoodDayBefore1943(): void { @@ -70,7 +68,7 @@ public function testStatehoodDayBefore1943(): void /** * Tests translated name of Statehood Day. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -85,7 +83,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Brazil/AllSoulsDayTest.php b/tests/Brazil/AllSoulsDayTest.php index ed75ab3ba..cc6692835 100644 --- a/tests/Brazil/AllSoulsDayTest.php +++ b/tests/Brazil/AllSoulsDayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -40,7 +39,6 @@ class AllSoulsDayTest extends BrazilBaseTestCase implements HolidayTestCase * Tests Dia dos Finados on or after 1300. * * @throws Exception - * @throws ReflectionException */ public function testDiaDosFinadosAfter1300(): void { @@ -56,7 +54,7 @@ public function testDiaDosFinadosAfter1300(): void /** * Tests Dia dos Finados on or before 1300. * - * @throws ReflectionException + * @throws Exception */ public function testDiaDosFinadosBefore1300(): void { @@ -67,7 +65,7 @@ public function testDiaDosFinadosBefore1300(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -78,7 +76,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Brazil/AshWednesdayTest.php b/tests/Brazil/AshWednesdayTest.php index 69163062f..2342686b1 100644 --- a/tests/Brazil/AshWednesdayTest.php +++ b/tests/Brazil/AshWednesdayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -35,7 +34,6 @@ class AshWednesdayTest extends BrazilBaseTestCase implements HolidayTestCase * Tests the holiday defined in this test. * * @throws Exception - * @throws ReflectionException */ public function testHoliday(): void { @@ -51,7 +49,7 @@ public function testHoliday(): void /** * Tests translated name of Ash Wednesday. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -66,7 +64,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Brazil/BrazilTest.php b/tests/Brazil/BrazilTest.php index dfb60b96f..01396d761 100644 --- a/tests/Brazil/BrazilTest.php +++ b/tests/Brazil/BrazilTest.php @@ -30,6 +30,8 @@ class BrazilTest extends BrazilBaseTestCase implements ProviderTestCase /** * Initial setup of this Test Case. + * + * @throws \Exception */ protected function setUp(): void { @@ -38,8 +40,6 @@ protected function setUp(): void /** * Tests if all official holidays in Brazil are defined by the provider class. - * - * @throws ReflectionException */ public function testOfficialHolidays(): void { @@ -57,8 +57,6 @@ public function testOfficialHolidays(): void /** * Tests if all observed holidays in Brazil are defined by the provider class. - * - * @throws ReflectionException */ public function testObservedHolidays(): void { @@ -74,8 +72,6 @@ public function testObservedHolidays(): void /** * Tests if all seasonal holidays in Brazil are defined by the provider class. - * - * @throws ReflectionException */ public function testSeasonalHolidays(): void { @@ -84,8 +80,6 @@ public function testSeasonalHolidays(): void /** * Tests if all bank holidays in Brazil are defined by the provider class. - * - * @throws ReflectionException */ public function testBankHolidays(): void { @@ -94,8 +88,6 @@ public function testBankHolidays(): void /** * Tests if all other holidays in Brazil are defined by the provider class. - * - * @throws ReflectionException */ public function testOtherHolidays(): void { @@ -104,6 +96,7 @@ public function testOtherHolidays(): void /** * @throws ReflectionException + * @throws \Exception */ public function testSources(): void { diff --git a/tests/Brazil/CarnavalMondayTest.php b/tests/Brazil/CarnavalMondayTest.php index 26a2afd25..e4fad2483 100644 --- a/tests/Brazil/CarnavalMondayTest.php +++ b/tests/Brazil/CarnavalMondayTest.php @@ -16,7 +16,6 @@ use DateInterval; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\Provider\ChristianHolidays; use Yasumi\tests\HolidayTestCase; @@ -42,7 +41,6 @@ class CarnavalMondayTest extends BrazilBaseTestCase implements HolidayTestCase * Tests Carnaval Monday on or after 1700. * * @throws Exception - * @throws ReflectionException */ public function testCarnavalMondayAfter1700(): void { @@ -58,7 +56,7 @@ public function testCarnavalMondayAfter1700(): void /** * Tests Carnaval Monday on or before 1700. * - * @throws ReflectionException + * @throws Exception */ public function testCarnavalMondayBefore1700(): void { @@ -69,7 +67,7 @@ public function testCarnavalMondayBefore1700(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -80,7 +78,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Brazil/CarnavalTuesdayTest.php b/tests/Brazil/CarnavalTuesdayTest.php index ca3b1759b..d39111db3 100644 --- a/tests/Brazil/CarnavalTuesdayTest.php +++ b/tests/Brazil/CarnavalTuesdayTest.php @@ -16,7 +16,6 @@ use DateInterval; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\Provider\ChristianHolidays; use Yasumi\tests\HolidayTestCase; @@ -42,7 +41,6 @@ class CarnavalTuesdayTest extends BrazilBaseTestCase implements HolidayTestCase * Tests Carnaval Tuesday on or after 1700. * * @throws Exception - * @throws ReflectionException */ public function testCarnavalTuesdayAfter1700(): void { @@ -58,7 +56,7 @@ public function testCarnavalTuesdayAfter1700(): void /** * Tests Carnaval Tuesday on or before 1700. * - * @throws ReflectionException + * @throws Exception */ public function testCarnavalTuesdayBefore1700(): void { @@ -69,7 +67,7 @@ public function testCarnavalTuesdayBefore1700(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -80,7 +78,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Brazil/ChristmasDayTest.php b/tests/Brazil/ChristmasDayTest.php index 603102be9..bc3217a38 100644 --- a/tests/Brazil/ChristmasDayTest.php +++ b/tests/Brazil/ChristmasDayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -35,7 +34,6 @@ class ChristmasDayTest extends BrazilBaseTestCase implements HolidayTestCase * Tests Christmas Day. * * @throws Exception - * @throws ReflectionException */ public function testChristmasDay(): void { @@ -51,7 +49,7 @@ public function testChristmasDay(): void /** * Tests translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -66,7 +64,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Brazil/CorpusChristiTest.php b/tests/Brazil/CorpusChristiTest.php index 6752f3c4c..0d61b003e 100644 --- a/tests/Brazil/CorpusChristiTest.php +++ b/tests/Brazil/CorpusChristiTest.php @@ -16,7 +16,6 @@ use DateInterval; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\Provider\ChristianHolidays; use Yasumi\tests\HolidayTestCase; @@ -37,7 +36,6 @@ class CorpusChristiTest extends BrazilBaseTestCase implements HolidayTestCase * Tests Corpus Christi. * * @throws Exception - * @throws ReflectionException */ public function testCorpusChristi(): void { @@ -53,7 +51,7 @@ public function testCorpusChristi(): void /** * Tests translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -68,7 +66,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Brazil/EasterTest.php b/tests/Brazil/EasterTest.php index b1191ac3b..765480f37 100644 --- a/tests/Brazil/EasterTest.php +++ b/tests/Brazil/EasterTest.php @@ -15,7 +15,6 @@ namespace Yasumi\tests\Brazil; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\Provider\ChristianHolidays; use Yasumi\tests\HolidayTestCase; @@ -36,7 +35,6 @@ class EasterTest extends BrazilBaseTestCase implements HolidayTestCase * Tests Easter. * * @throws Exception - * @throws ReflectionException */ public function testEaster(): void { @@ -47,7 +45,7 @@ public function testEaster(): void /** * Tests translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -62,7 +60,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Brazil/GoodFridayTest.php b/tests/Brazil/GoodFridayTest.php index 81bfb6758..866574985 100644 --- a/tests/Brazil/GoodFridayTest.php +++ b/tests/Brazil/GoodFridayTest.php @@ -16,7 +16,6 @@ use DateInterval; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\Provider\ChristianHolidays; use Yasumi\tests\HolidayTestCase; @@ -37,7 +36,6 @@ class GoodFridayTest extends BrazilBaseTestCase implements HolidayTestCase * Tests Good Friday. * * @throws Exception - * @throws ReflectionException */ public function testGoodFriday(): void { @@ -53,7 +51,7 @@ public function testGoodFriday(): void /** * Tests translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -68,7 +66,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Brazil/IndependenceDayTest.php b/tests/Brazil/IndependenceDayTest.php index 52cd0c361..393e327ae 100644 --- a/tests/Brazil/IndependenceDayTest.php +++ b/tests/Brazil/IndependenceDayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -40,7 +39,6 @@ class IndependenceDayTest extends BrazilBaseTestCase implements HolidayTestCase * Tests Dia da independência do Brasil on or after 1822. * * @throws Exception - * @throws ReflectionException */ public function testDiaDaIndependenciaDoBrasilAfter1822(): void { @@ -56,7 +54,7 @@ public function testDiaDaIndependenciaDoBrasilAfter1822(): void /** * Tests Dia da independência do Brasil on or before 1822. * - * @throws ReflectionException + * @throws Exception */ public function testDiaDaIndependenciaDoBrasilBefore1822(): void { @@ -67,7 +65,7 @@ public function testDiaDaIndependenciaDoBrasilBefore1822(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -83,7 +81,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Brazil/InternationalWorkersDayTest.php b/tests/Brazil/InternationalWorkersDayTest.php index 65b25690d..06138c9b0 100644 --- a/tests/Brazil/InternationalWorkersDayTest.php +++ b/tests/Brazil/InternationalWorkersDayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -35,7 +34,6 @@ class InternationalWorkersDayTest extends BrazilBaseTestCase implements HolidayT * Tests International Workers' Day. * * @throws Exception - * @throws ReflectionException */ public function testInternationalWorkersDay(): void { @@ -51,7 +49,7 @@ public function testInternationalWorkersDay(): void /** * Tests translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -66,7 +64,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Brazil/NewYearsDayTest.php b/tests/Brazil/NewYearsDayTest.php index 2d07d76c5..221a30422 100644 --- a/tests/Brazil/NewYearsDayTest.php +++ b/tests/Brazil/NewYearsDayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -35,7 +34,6 @@ class NewYearsDayTest extends BrazilBaseTestCase implements HolidayTestCase * Tests New Years Day. * * @throws Exception - * @throws ReflectionException */ public function testNewYearsDay(): void { @@ -51,7 +49,7 @@ public function testNewYearsDay(): void /** * Tests translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -66,7 +64,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Brazil/OurLadyOfAparecidaDayTest.php b/tests/Brazil/OurLadyOfAparecidaDayTest.php index d485bb340..65b270fbe 100644 --- a/tests/Brazil/OurLadyOfAparecidaDayTest.php +++ b/tests/Brazil/OurLadyOfAparecidaDayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -40,7 +39,6 @@ class OurLadyOfAparecidaDayTest extends BrazilBaseTestCase implements HolidayTes * Tests Nossa Senhora Aparecida on or after 1980. * * @throws Exception - * @throws ReflectionException */ public function testNossaSenhoraAparecidaAfter1980(): void { @@ -56,7 +54,7 @@ public function testNossaSenhoraAparecidaAfter1980(): void /** * Tests Nossa Senhora Aparecida on or before 1980. * - * @throws ReflectionException + * @throws Exception */ public function testNossaSenhoraAparecidaBefore1980(): void { @@ -67,7 +65,7 @@ public function testNossaSenhoraAparecidaBefore1980(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -83,7 +81,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Brazil/ProclamationOfRepublicDayTest.php b/tests/Brazil/ProclamationOfRepublicDayTest.php index 7d07e71dc..6b7393eb6 100644 --- a/tests/Brazil/ProclamationOfRepublicDayTest.php +++ b/tests/Brazil/ProclamationOfRepublicDayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -40,7 +39,6 @@ class ProclamationOfRepublicDayTest extends BrazilBaseTestCase implements Holida * Tests Proclamação da República on or after 1889. * * @throws Exception - * @throws ReflectionException */ public function testProclamacaoDaRepublicaAfter1889(): void { @@ -56,7 +54,7 @@ public function testProclamacaoDaRepublicaAfter1889(): void /** * Tests Proclamação da República on or before 1889. * - * @throws ReflectionException + * @throws Exception */ public function testProclamacaoDaRepublicaBefore1889(): void { @@ -67,7 +65,7 @@ public function testProclamacaoDaRepublicaBefore1889(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -83,7 +81,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Brazil/TiradentesDayTest.php b/tests/Brazil/TiradentesDayTest.php index 7ae9b3738..f80d9f07a 100644 --- a/tests/Brazil/TiradentesDayTest.php +++ b/tests/Brazil/TiradentesDayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -40,7 +39,6 @@ class TiradentesDayTest extends BrazilBaseTestCase implements HolidayTestCase * Tests Dia de Tiradentes on or after 1792. * * @throws Exception - * @throws ReflectionException */ public function testDiaDeTiradentesAfter1792(): void { @@ -56,7 +54,7 @@ public function testDiaDeTiradentesAfter1792(): void /** * Tests Dia de Tiradentes on or before 1792. * - * @throws ReflectionException + * @throws Exception */ public function testDiaDeTiradentesBefore1792(): void { @@ -67,7 +65,7 @@ public function testDiaDeTiradentesBefore1792(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -78,7 +76,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Canada/Alberta/AlbertaTest.php b/tests/Canada/Alberta/AlbertaTest.php index b5282478a..921d74da0 100644 --- a/tests/Canada/Alberta/AlbertaTest.php +++ b/tests/Canada/Alberta/AlbertaTest.php @@ -30,6 +30,8 @@ class AlbertaTest extends AlbertaBaseTestCase implements ProviderTestCase /** * Initial setup of this Test Case. + * + * @throws \Exception */ protected function setUp(): void { @@ -38,8 +40,6 @@ protected function setUp(): void /** * Tests if all official holidays in Alberta are defined by the provider class. - * - * @throws ReflectionException */ public function testOfficialHolidays(): void { @@ -59,8 +59,6 @@ public function testOfficialHolidays(): void /** * Tests if all observed holidays in Alberta are defined by the provider class. - * - * @throws ReflectionException */ public function testObservedHolidays(): void { @@ -69,8 +67,6 @@ public function testObservedHolidays(): void /** * Tests if all seasonal holidays in Alberta are defined by the provider class. - * - * @throws ReflectionException */ public function testSeasonalHolidays(): void { @@ -79,8 +75,6 @@ public function testSeasonalHolidays(): void /** * Tests if all bank holidays in Alberta are defined by the provider class. - * - * @throws ReflectionException */ public function testBankHolidays(): void { @@ -89,8 +83,6 @@ public function testBankHolidays(): void /** * Tests if all other holidays in Alberta are defined by the provider class. - * - * @throws ReflectionException */ public function testOtherHolidays(): void { @@ -99,6 +91,7 @@ public function testOtherHolidays(): void /** * @throws ReflectionException + * @throws \Exception */ public function testSources(): void { diff --git a/tests/Canada/BritishColumbia/BritishColumbiaTest.php b/tests/Canada/BritishColumbia/BritishColumbiaTest.php index 0f81006bc..7eee55af8 100644 --- a/tests/Canada/BritishColumbia/BritishColumbiaTest.php +++ b/tests/Canada/BritishColumbia/BritishColumbiaTest.php @@ -30,6 +30,8 @@ class BritishColumbiaTest extends BritishColumbiaBaseTestCase implements Provide /** * Initial setup of this Test Case. + * + * @throws \Exception */ protected function setUp(): void { @@ -38,8 +40,6 @@ protected function setUp(): void /** * Tests if all official holidays in BritishColumbia are defined by the provider class. - * - * @throws ReflectionException */ public function testOfficialHolidays(): void { @@ -59,8 +59,6 @@ public function testOfficialHolidays(): void /** * Tests if all observed holidays in BritishColumbia are defined by the provider class. - * - * @throws ReflectionException */ public function testObservedHolidays(): void { @@ -69,8 +67,6 @@ public function testObservedHolidays(): void /** * Tests if all seasonal holidays in BritishColumbia are defined by the provider class. - * - * @throws ReflectionException */ public function testSeasonalHolidays(): void { @@ -79,8 +75,6 @@ public function testSeasonalHolidays(): void /** * Tests if all bank holidays in BritishColumbia are defined by the provider class. - * - * @throws ReflectionException */ public function testBankHolidays(): void { @@ -89,8 +83,6 @@ public function testBankHolidays(): void /** * Tests if all other holidays in BritishColumbia are defined by the provider class. - * - * @throws ReflectionException */ public function testOtherHolidays(): void { @@ -99,6 +91,7 @@ public function testOtherHolidays(): void /** * @throws ReflectionException + * @throws \Exception */ public function testSources(): void { diff --git a/tests/Canada/CanadaDayTest.php b/tests/Canada/CanadaDayTest.php index 9271a1e04..3a1b10c38 100644 --- a/tests/Canada/CanadaDayTest.php +++ b/tests/Canada/CanadaDayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -40,7 +39,6 @@ class CanadaDayTest extends CanadaBaseTestCase implements HolidayTestCase * Tests Canada Day on or after 1983. Canada Day was established in 1983 on July 1st. * * @throws Exception - * @throws ReflectionException */ public function testCanadaDayOnAfter1983(): void { @@ -63,7 +61,7 @@ public function testCanadaDayOnAfter1983(): void /** * Tests Canada Day before 1879. Canada Day was established as Dominion Day in 1879 on July 1st. * - * @throws ReflectionException + * @throws Exception */ public function testCanadaDayBefore1879(): void { @@ -77,7 +75,7 @@ public function testCanadaDayBefore1879(): void /** * Tests translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -92,7 +90,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Canada/CanadaTest.php b/tests/Canada/CanadaTest.php index 7658cc233..93c454dd6 100644 --- a/tests/Canada/CanadaTest.php +++ b/tests/Canada/CanadaTest.php @@ -30,6 +30,8 @@ class CanadaTest extends CanadaBaseTestCase implements ProviderTestCase /** * Initial setup of this Test Case. + * + * @throws \Exception */ protected function setUp(): void { @@ -38,8 +40,6 @@ protected function setUp(): void /** * Tests if all official holidays in the USA are defined by the provider class. - * - * @throws ReflectionException */ public function testOfficialHolidays(): void { @@ -58,8 +58,6 @@ public function testOfficialHolidays(): void /** * Tests if all observed holidays in the Canada are defined by the provider class. - * - * @throws ReflectionException */ public function testObservedHolidays(): void { @@ -68,8 +66,6 @@ public function testObservedHolidays(): void /** * Tests if all seasonal holidays in the Canada are defined by the provider class. - * - * @throws ReflectionException */ public function testSeasonalHolidays(): void { @@ -78,8 +74,6 @@ public function testSeasonalHolidays(): void /** * Tests if all bank holidays in the Canada are defined by the provider class. - * - * @throws ReflectionException */ public function testBankHolidays(): void { @@ -88,8 +82,6 @@ public function testBankHolidays(): void /** * Tests if all other holidays in the Canada are defined by the provider class. - * - * @throws ReflectionException */ public function testOtherHolidays(): void { @@ -98,6 +90,7 @@ public function testOtherHolidays(): void /** * @throws ReflectionException + * @throws \Exception */ public function testSources(): void { diff --git a/tests/Canada/ChristmasDayTest.php b/tests/Canada/ChristmasDayTest.php index a0804ee73..c5be59386 100644 --- a/tests/Canada/ChristmasDayTest.php +++ b/tests/Canada/ChristmasDayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -35,7 +34,6 @@ class ChristmasDayTest extends CanadaBaseTestCase implements HolidayTestCase * Tests Christmas Day. Christmas Day is celebrated on December 25th. * * @throws Exception - * @throws ReflectionException */ public function testChristmasDay(): void { @@ -51,7 +49,7 @@ public function testChristmasDay(): void /** * Tests translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -66,7 +64,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Canada/LabourDayTest.php b/tests/Canada/LabourDayTest.php index de1ea1044..d73c4851b 100644 --- a/tests/Canada/LabourDayTest.php +++ b/tests/Canada/LabourDayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -40,7 +39,6 @@ class LabourDayTest extends CanadaBaseTestCase implements HolidayTestCase * Tests Labour Day on or after 1894. Labour Day was established since 1894 on the first Monday of September. * * @throws Exception - * @throws ReflectionException */ public function testLabourDayOnAfter1894(): void { @@ -56,7 +54,7 @@ public function testLabourDayOnAfter1894(): void /** * Tests Labour Day before 1894. Labour Day was established since 1894 on the first Monday of September. * - * @throws ReflectionException + * @throws Exception */ public function testLabourDayBefore1894(): void { @@ -70,7 +68,7 @@ public function testLabourDayBefore1894(): void /** * Tests translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -85,7 +83,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Canada/Manitoba/ManitobaTest.php b/tests/Canada/Manitoba/ManitobaTest.php index 49db8947d..d7569c982 100644 --- a/tests/Canada/Manitoba/ManitobaTest.php +++ b/tests/Canada/Manitoba/ManitobaTest.php @@ -30,6 +30,8 @@ class ManitobaTest extends ManitobaBaseTestCase implements ProviderTestCase /** * Initial setup of this Test Case. + * + * @throws \Exception */ protected function setUp(): void { @@ -38,8 +40,6 @@ protected function setUp(): void /** * Tests if all official holidays in Manitoba are defined by the provider class. - * - * @throws ReflectionException */ public function testOfficialHolidays(): void { @@ -59,8 +59,6 @@ public function testOfficialHolidays(): void /** * Tests if all observed holidays in Manitoba are defined by the provider class. - * - * @throws ReflectionException */ public function testObservedHolidays(): void { @@ -69,8 +67,6 @@ public function testObservedHolidays(): void /** * Tests if all seasonal holidays in Manitoba are defined by the provider class. - * - * @throws ReflectionException */ public function testSeasonalHolidays(): void { @@ -79,8 +75,6 @@ public function testSeasonalHolidays(): void /** * Tests if all bank holidays in Manitoba are defined by the provider class. - * - * @throws ReflectionException */ public function testBankHolidays(): void { @@ -89,8 +83,6 @@ public function testBankHolidays(): void /** * Tests if all other holidays in Manitoba are defined by the provider class. - * - * @throws ReflectionException */ public function testOtherHolidays(): void { @@ -99,6 +91,7 @@ public function testOtherHolidays(): void /** * @throws ReflectionException + * @throws \Exception */ public function testSources(): void { diff --git a/tests/Canada/NewBrunswick/NewBrunswickTest.php b/tests/Canada/NewBrunswick/NewBrunswickTest.php index 1982907f9..4e3b05eb0 100644 --- a/tests/Canada/NewBrunswick/NewBrunswickTest.php +++ b/tests/Canada/NewBrunswick/NewBrunswickTest.php @@ -30,6 +30,8 @@ class NewBrunswickTest extends NewBrunswickBaseTestCase implements ProviderTestC /** * Initial setup of this Test Case. + * + * @throws \Exception */ protected function setUp(): void { @@ -38,8 +40,6 @@ protected function setUp(): void /** * Tests if all official holidays in NewBrunswick are defined by the provider class. - * - * @throws ReflectionException */ public function testOfficialHolidays(): void { @@ -59,8 +59,6 @@ public function testOfficialHolidays(): void /** * Tests if all observed holidays in NewBrunswick are defined by the provider class. - * - * @throws ReflectionException */ public function testObservedHolidays(): void { @@ -69,8 +67,6 @@ public function testObservedHolidays(): void /** * Tests if all seasonal holidays in NewBrunswick are defined by the provider class. - * - * @throws ReflectionException */ public function testSeasonalHolidays(): void { @@ -79,8 +75,6 @@ public function testSeasonalHolidays(): void /** * Tests if all bank holidays in NewBrunswick are defined by the provider class. - * - * @throws ReflectionException */ public function testBankHolidays(): void { @@ -89,8 +83,6 @@ public function testBankHolidays(): void /** * Tests if all other holidays in NewBrunswick are defined by the provider class. - * - * @throws ReflectionException */ public function testOtherHolidays(): void { @@ -99,6 +91,7 @@ public function testOtherHolidays(): void /** * @throws ReflectionException + * @throws \Exception */ public function testSources(): void { diff --git a/tests/Canada/NewYearsDayTest.php b/tests/Canada/NewYearsDayTest.php index 544dd784b..2413282e9 100644 --- a/tests/Canada/NewYearsDayTest.php +++ b/tests/Canada/NewYearsDayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -35,7 +34,6 @@ class NewYearsDayTest extends CanadaBaseTestCase implements HolidayTestCase * Tests New Years Day. * * @throws Exception - * @throws ReflectionException */ public function testNewYearsDay(): void { @@ -51,7 +49,7 @@ public function testNewYearsDay(): void /** * Tests translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -66,7 +64,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Canada/NewfoundlandAndLabrador/NewfoundlandAndLabradorTest.php b/tests/Canada/NewfoundlandAndLabrador/NewfoundlandAndLabradorTest.php index 54c39795b..cb6353994 100644 --- a/tests/Canada/NewfoundlandAndLabrador/NewfoundlandAndLabradorTest.php +++ b/tests/Canada/NewfoundlandAndLabrador/NewfoundlandAndLabradorTest.php @@ -30,6 +30,8 @@ class NewfoundlandAndLabradorTest extends NewfoundlandAndLabradorBaseTestCase im /** * Initial setup of this Test Case. + * + * @throws \Exception */ protected function setUp(): void { @@ -38,8 +40,6 @@ protected function setUp(): void /** * Tests if all official holidays in NewfoundlandAndLabrador are defined by the provider class. - * - * @throws ReflectionException */ public function testOfficialHolidays(): void { @@ -52,8 +52,6 @@ public function testOfficialHolidays(): void /** * Tests if all observed holidays in NewfoundlandAndLabrador are defined by the provider class. - * - * @throws ReflectionException */ public function testObservedHolidays(): void { @@ -62,8 +60,6 @@ public function testObservedHolidays(): void /** * Tests if all seasonal holidays in NewfoundlandAndLabrador are defined by the provider class. - * - * @throws ReflectionException */ public function testSeasonalHolidays(): void { @@ -72,8 +68,6 @@ public function testSeasonalHolidays(): void /** * Tests if all bank holidays in NewfoundlandAndLabrador are defined by the provider class. - * - * @throws ReflectionException */ public function testBankHolidays(): void { @@ -85,8 +79,6 @@ public function testBankHolidays(): void /** * Tests if all other holidays in NewfoundlandAndLabrador are defined by the provider class. - * - * @throws ReflectionException */ public function testOtherHolidays(): void { @@ -95,6 +87,7 @@ public function testOtherHolidays(): void /** * @throws ReflectionException + * @throws \Exception */ public function testSources(): void { diff --git a/tests/Canada/NorthwestTerritories/NorthwestTerritoriesTest.php b/tests/Canada/NorthwestTerritories/NorthwestTerritoriesTest.php index ac47a50d1..3885e7bb6 100644 --- a/tests/Canada/NorthwestTerritories/NorthwestTerritoriesTest.php +++ b/tests/Canada/NorthwestTerritories/NorthwestTerritoriesTest.php @@ -30,6 +30,8 @@ class NorthwestTerritoriesTest extends NorthwestTerritoriesBaseTestCase implemen /** * Initial setup of this Test Case. + * + * @throws \Exception */ protected function setUp(): void { @@ -38,8 +40,6 @@ protected function setUp(): void /** * Tests if all official holidays in NorthwestTerritories are defined by the provider class. - * - * @throws ReflectionException */ public function testOfficialHolidays(): void { @@ -59,8 +59,6 @@ public function testOfficialHolidays(): void /** * Tests if all observed holidays in NorthwestTerritories are defined by the provider class. - * - * @throws ReflectionException */ public function testObservedHolidays(): void { @@ -69,8 +67,6 @@ public function testObservedHolidays(): void /** * Tests if all seasonal holidays in NorthwestTerritories are defined by the provider class. - * - * @throws ReflectionException */ public function testSeasonalHolidays(): void { @@ -79,8 +75,6 @@ public function testSeasonalHolidays(): void /** * Tests if all bank holidays in NorthwestTerritories are defined by the provider class. - * - * @throws ReflectionException */ public function testBankHolidays(): void { @@ -89,8 +83,6 @@ public function testBankHolidays(): void /** * Tests if all other holidays in NorthwestTerritories are defined by the provider class. - * - * @throws ReflectionException */ public function testOtherHolidays(): void { @@ -99,6 +91,7 @@ public function testOtherHolidays(): void /** * @throws ReflectionException + * @throws \Exception */ public function testSources(): void { diff --git a/tests/Canada/NovaScotia/NovaScotiaTest.php b/tests/Canada/NovaScotia/NovaScotiaTest.php index 5806edfe5..f8ffcddd5 100644 --- a/tests/Canada/NovaScotia/NovaScotiaTest.php +++ b/tests/Canada/NovaScotia/NovaScotiaTest.php @@ -30,6 +30,8 @@ class NovaScotiaTest extends NovaScotiaBaseTestCase implements ProviderTestCase /** * Initial setup of this Test Case. + * + * @throws \Exception */ protected function setUp(): void { @@ -38,8 +40,6 @@ protected function setUp(): void /** * Tests if all official holidays in Nova Scotia are defined by the provider class. - * - * @throws ReflectionException */ public function testOfficialHolidays(): void { @@ -59,8 +59,6 @@ public function testOfficialHolidays(): void /** * Tests if all observed holidays in NovaScotia are defined by the provider class. - * - * @throws ReflectionException */ public function testObservedHolidays(): void { @@ -69,8 +67,6 @@ public function testObservedHolidays(): void /** * Tests if all seasonal holidays in NovaScotia are defined by the provider class. - * - * @throws ReflectionException */ public function testSeasonalHolidays(): void { @@ -79,8 +75,6 @@ public function testSeasonalHolidays(): void /** * Tests if all bank holidays in NovaScotia are defined by the provider class. - * - * @throws ReflectionException */ public function testBankHolidays(): void { @@ -89,8 +83,6 @@ public function testBankHolidays(): void /** * Tests if all other holidays in NovaScotia are defined by the provider class. - * - * @throws ReflectionException */ public function testOtherHolidays(): void { @@ -99,6 +91,7 @@ public function testOtherHolidays(): void /** * @throws ReflectionException + * @throws \Exception */ public function testSources(): void { diff --git a/tests/Canada/Nunavut/NunavutTest.php b/tests/Canada/Nunavut/NunavutTest.php index 880323569..27913c836 100644 --- a/tests/Canada/Nunavut/NunavutTest.php +++ b/tests/Canada/Nunavut/NunavutTest.php @@ -30,6 +30,8 @@ class NunavutTest extends NunavutBaseTestCase implements ProviderTestCase /** * Initial setup of this Test Case. + * + * @throws \Exception */ protected function setUp(): void { @@ -38,8 +40,6 @@ protected function setUp(): void /** * Tests if all official holidays in Nunavut are defined by the provider class. - * - * @throws ReflectionException */ public function testOfficialHolidays(): void { @@ -53,8 +53,6 @@ public function testOfficialHolidays(): void /** * Tests if all observed holidays in Nunavut are defined by the provider class. - * - * @throws ReflectionException */ public function testObservedHolidays(): void { @@ -63,8 +61,6 @@ public function testObservedHolidays(): void /** * Tests if all seasonal holidays in Nunavut are defined by the provider class. - * - * @throws ReflectionException */ public function testSeasonalHolidays(): void { @@ -73,8 +69,6 @@ public function testSeasonalHolidays(): void /** * Tests if all bank holidays in Nunavut are defined by the provider class. - * - * @throws ReflectionException */ public function testBankHolidays(): void { @@ -83,8 +77,6 @@ public function testBankHolidays(): void /** * Tests if all other holidays in Nunavut are defined by the provider class. - * - * @throws ReflectionException */ public function testOtherHolidays(): void { @@ -93,6 +85,7 @@ public function testOtherHolidays(): void /** * @throws ReflectionException + * @throws \Exception */ public function testSources(): void { diff --git a/tests/Canada/Ontario/OntarioTest.php b/tests/Canada/Ontario/OntarioTest.php index 871a0f207..d6746141a 100644 --- a/tests/Canada/Ontario/OntarioTest.php +++ b/tests/Canada/Ontario/OntarioTest.php @@ -30,6 +30,8 @@ class OntarioTest extends OntarioBaseTestCase implements ProviderTestCase /** * Initial setup of this Test Case. + * + * @throws \Exception */ protected function setUp(): void { @@ -38,8 +40,6 @@ protected function setUp(): void /** * Tests if all official holidays in Ontario are defined by the provider class. - * - * @throws ReflectionException */ public function testOfficialHolidays(): void { @@ -59,8 +59,6 @@ public function testOfficialHolidays(): void /** * Tests if all observed holidays in Ontario are defined by the provider class. - * - * @throws ReflectionException */ public function testObservedHolidays(): void { @@ -69,8 +67,6 @@ public function testObservedHolidays(): void /** * Tests if all seasonal holidays in Ontario are defined by the provider class. - * - * @throws ReflectionException */ public function testSeasonalHolidays(): void { @@ -79,8 +75,6 @@ public function testSeasonalHolidays(): void /** * Tests if all bank holidays in Ontario are defined by the provider class. - * - * @throws ReflectionException */ public function testBankHolidays(): void { @@ -89,8 +83,6 @@ public function testBankHolidays(): void /** * Tests if all other holidays in Ontario are defined by the provider class. - * - * @throws ReflectionException */ public function testOtherHolidays(): void { @@ -99,6 +91,7 @@ public function testOtherHolidays(): void /** * @throws ReflectionException + * @throws \Exception */ public function testSources(): void { diff --git a/tests/Canada/PrinceEdwardIsland/PrinceEdwardIslandTest.php b/tests/Canada/PrinceEdwardIsland/PrinceEdwardIslandTest.php index c39180328..4624b6251 100644 --- a/tests/Canada/PrinceEdwardIsland/PrinceEdwardIslandTest.php +++ b/tests/Canada/PrinceEdwardIsland/PrinceEdwardIslandTest.php @@ -30,6 +30,8 @@ class PrinceEdwardIslandTest extends PrinceEdwardIslandBaseTestCase implements P /** * Initial setup of this Test Case. + * + * @throws \Exception */ protected function setUp(): void { @@ -38,8 +40,6 @@ protected function setUp(): void /** * Tests if all official holidays in Prince Edward Island are defined by the provider class. - * - * @throws ReflectionException */ public function testOfficialHolidays(): void { @@ -59,8 +59,6 @@ public function testOfficialHolidays(): void /** * Tests if all observed holidays in PrinceEdwardIsland are defined by the provider class. - * - * @throws ReflectionException */ public function testObservedHolidays(): void { @@ -69,8 +67,6 @@ public function testObservedHolidays(): void /** * Tests if all seasonal holidays in PrinceEdwardIsland are defined by the provider class. - * - * @throws ReflectionException */ public function testSeasonalHolidays(): void { @@ -79,8 +75,6 @@ public function testSeasonalHolidays(): void /** * Tests if all bank holidays in PrinceEdwardIsland are defined by the provider class. - * - * @throws ReflectionException */ public function testBankHolidays(): void { @@ -89,8 +83,6 @@ public function testBankHolidays(): void /** * Tests if all other holidays in PrinceEdwardIsland are defined by the provider class. - * - * @throws ReflectionException */ public function testOtherHolidays(): void { @@ -99,6 +91,7 @@ public function testOtherHolidays(): void /** * @throws ReflectionException + * @throws \Exception */ public function testSources(): void { diff --git a/tests/Canada/Quebec/QuebecTest.php b/tests/Canada/Quebec/QuebecTest.php index ab7339fdf..254dcb8bf 100644 --- a/tests/Canada/Quebec/QuebecTest.php +++ b/tests/Canada/Quebec/QuebecTest.php @@ -30,6 +30,8 @@ class QuebecTest extends QuebecBaseTestCase implements ProviderTestCase /** * Initial setup of this Test Case. + * + * @throws \Exception */ protected function setUp(): void { @@ -38,8 +40,6 @@ protected function setUp(): void /** * Tests if all official holidays in Quebec are defined by the provider class. - * - * @throws ReflectionException */ public function testOfficialHolidays(): void { @@ -58,8 +58,6 @@ public function testOfficialHolidays(): void /** * Tests if all observed holidays in Quebec are defined by the provider class. - * - * @throws ReflectionException */ public function testObservedHolidays(): void { @@ -68,8 +66,6 @@ public function testObservedHolidays(): void /** * Tests if all seasonal holidays in Quebec are defined by the provider class. - * - * @throws ReflectionException */ public function testSeasonalHolidays(): void { @@ -78,8 +74,6 @@ public function testSeasonalHolidays(): void /** * Tests if all bank holidays in Quebec are defined by the provider class. - * - * @throws ReflectionException */ public function testBankHolidays(): void { @@ -88,8 +82,6 @@ public function testBankHolidays(): void /** * Tests if all other holidays in Quebec are defined by the provider class. - * - * @throws ReflectionException */ public function testOtherHolidays(): void { @@ -98,6 +90,7 @@ public function testOtherHolidays(): void /** * @throws ReflectionException + * @throws \Exception */ public function testSources(): void { diff --git a/tests/Canada/RemembranceDayTest.php b/tests/Canada/RemembranceDayTest.php index f9bfbac1a..6d14b88e3 100644 --- a/tests/Canada/RemembranceDayTest.php +++ b/tests/Canada/RemembranceDayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -40,7 +39,6 @@ class RemembranceDayTest extends CanadaBaseTestCase implements HolidayTestCase * Tests Remembrance Day on or after 1919. Remembrance Day was established in 1919 on November 11. * * @throws Exception - * @throws ReflectionException */ public function testRemembranceDayOnAfter1919(): void { @@ -56,7 +54,7 @@ public function testRemembranceDayOnAfter1919(): void /** * Tests Remembrance Day before 1919. Remembrance Day was established in 1919 on November 11. * - * @throws ReflectionException + * @throws Exception */ public function testVeteransDayBefore1919(): void { @@ -70,7 +68,7 @@ public function testVeteransDayBefore1919(): void /** * Tests translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -85,7 +83,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Canada/Saskatchewan/SaskatchewanTest.php b/tests/Canada/Saskatchewan/SaskatchewanTest.php index 37390de0f..811750143 100644 --- a/tests/Canada/Saskatchewan/SaskatchewanTest.php +++ b/tests/Canada/Saskatchewan/SaskatchewanTest.php @@ -30,6 +30,8 @@ class SaskatchewanTest extends SaskatchewanBaseTestCase implements ProviderTestC /** * Initial setup of this Test Case. + * + * @throws \Exception */ protected function setUp(): void { @@ -38,8 +40,6 @@ protected function setUp(): void /** * Tests if all official holidays in Saskatchewan are defined by the provider class. - * - * @throws ReflectionException */ public function testOfficialHolidays(): void { @@ -59,8 +59,6 @@ public function testOfficialHolidays(): void /** * Tests if all observed holidays in Saskatchewan are defined by the provider class. - * - * @throws ReflectionException */ public function testObservedHolidays(): void { @@ -69,8 +67,6 @@ public function testObservedHolidays(): void /** * Tests if all seasonal holidays in Saskatchewan are defined by the provider class. - * - * @throws ReflectionException */ public function testSeasonalHolidays(): void { @@ -79,8 +75,6 @@ public function testSeasonalHolidays(): void /** * Tests if all bank holidays in Saskatchewan are defined by the provider class. - * - * @throws ReflectionException */ public function testBankHolidays(): void { @@ -89,8 +83,6 @@ public function testBankHolidays(): void /** * Tests if all other holidays in Saskatchewan are defined by the provider class. - * - * @throws ReflectionException */ public function testOtherHolidays(): void { @@ -99,6 +91,7 @@ public function testOtherHolidays(): void /** * @throws ReflectionException + * @throws \Exception */ public function testSources(): void { diff --git a/tests/Canada/ThanksgivingDayTest.php b/tests/Canada/ThanksgivingDayTest.php index 18155736d..d57b1a54d 100644 --- a/tests/Canada/ThanksgivingDayTest.php +++ b/tests/Canada/ThanksgivingDayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -41,7 +40,6 @@ class ThanksgivingDayTest extends CanadaBaseTestCase implements HolidayTestCase * of October. * * @throws Exception - * @throws ReflectionException */ public function testThanksgivingDayOnAfter1879(): void { @@ -58,7 +56,7 @@ public function testThanksgivingDayOnAfter1879(): void * Tests Thanksgiving Day before 1879. ThanksgivingDay Day is celebrated since 1879 on the second Monday * of October. * - * @throws ReflectionException + * @throws Exception */ public function testThanksgivingDayBefore1879(): void { @@ -72,7 +70,7 @@ public function testThanksgivingDayBefore1879(): void /** * Tests translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -87,7 +85,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Canada/TruthAndReconciliationDayTest.php b/tests/Canada/TruthAndReconciliationDayTest.php index 3ee107938..648e539b3 100644 --- a/tests/Canada/TruthAndReconciliationDayTest.php +++ b/tests/Canada/TruthAndReconciliationDayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -41,7 +40,6 @@ class TruthAndReconciliationDayTest extends CanadaBaseTestCase implements Holida * of September. * * @throws Exception - * @throws ReflectionException */ public function testTruthAndReconciliationDayOnAfter2021(): void { @@ -58,7 +56,7 @@ public function testTruthAndReconciliationDayOnAfter2021(): void * Tests TruthAndReconciliationDay before 2021. TruthAndReconciliationDay is celebrated since 2021 on the last day * of September. * - * @throws ReflectionException + * @throws Exception */ public function testTruthAndReconciliationDayBefore2021(): void { @@ -72,7 +70,7 @@ public function testTruthAndReconciliationDayBefore2021(): void /** * Tests translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -87,7 +85,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Canada/Yukon/YukonTest.php b/tests/Canada/Yukon/YukonTest.php index ac7549090..3f34cfe4a 100644 --- a/tests/Canada/Yukon/YukonTest.php +++ b/tests/Canada/Yukon/YukonTest.php @@ -30,6 +30,8 @@ class YukonTest extends YukonBaseTestCase implements ProviderTestCase /** * Initial setup of this Test Case. + * + * @throws \Exception */ protected function setUp(): void { @@ -38,8 +40,6 @@ protected function setUp(): void /** * Tests if all official holidays in Yukon are defined by the provider class. - * - * @throws ReflectionException */ public function testOfficialHolidays(): void { @@ -69,8 +69,6 @@ public function testOfficialHolidays(): void /** * Tests if all observed holidays in Yukon are defined by the provider class. - * - * @throws ReflectionException */ public function testObservedHolidays(): void { @@ -79,8 +77,6 @@ public function testObservedHolidays(): void /** * Tests if all seasonal holidays in Yukon are defined by the provider class. - * - * @throws ReflectionException */ public function testSeasonalHolidays(): void { @@ -89,8 +85,6 @@ public function testSeasonalHolidays(): void /** * Tests if all bank holidays in Yukon are defined by the provider class. - * - * @throws ReflectionException */ public function testBankHolidays(): void { @@ -99,8 +93,6 @@ public function testBankHolidays(): void /** * Tests if all other holidays in Yukon are defined by the provider class. - * - * @throws ReflectionException */ public function testOtherHolidays(): void { @@ -109,6 +101,7 @@ public function testOtherHolidays(): void /** * @throws ReflectionException + * @throws \Exception */ public function testSources(): void { diff --git a/tests/Croatia/AllSaintsDayTest.php b/tests/Croatia/AllSaintsDayTest.php index 32eebfb8b..f642f0fae 100644 --- a/tests/Croatia/AllSaintsDayTest.php +++ b/tests/Croatia/AllSaintsDayTest.php @@ -16,7 +16,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -37,8 +36,6 @@ class AllSaintsDayTest extends CroatiaBaseTestCase implements HolidayTestCase * * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testHoliday(int $year, DateTime $expected): void { @@ -60,7 +57,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -75,7 +72,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Croatia/AntifascistStruggleDayTest.php b/tests/Croatia/AntifascistStruggleDayTest.php index ad5a50171..dd392b339 100644 --- a/tests/Croatia/AntifascistStruggleDayTest.php +++ b/tests/Croatia/AntifascistStruggleDayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -40,7 +39,6 @@ class AntifascistStruggleDayTest extends CroatiaBaseTestCase implements HolidayT * Tests Day of Antifascist Struggle on or after 1941. * * @throws Exception - * @throws ReflectionException */ public function testAntifascistStruggleDayOnAfter1941(): void { @@ -56,7 +54,7 @@ public function testAntifascistStruggleDayOnAfter1941(): void /** * Tests Day of Antifascist Struggle before 1941. * - * @throws ReflectionException + * @throws Exception */ public function testAntifascistStruggleDayBefore1941(): void { @@ -70,7 +68,7 @@ public function testAntifascistStruggleDayBefore1941(): void /** * Tests translated name of Day of Antifascist Struggle. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -85,7 +83,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Croatia/AssumptionOfMaryTest.php b/tests/Croatia/AssumptionOfMaryTest.php index 19697fe5a..384bc7308 100644 --- a/tests/Croatia/AssumptionOfMaryTest.php +++ b/tests/Croatia/AssumptionOfMaryTest.php @@ -16,7 +16,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -37,8 +36,6 @@ class AssumptionOfMaryTest extends CroatiaBaseTestCase implements HolidayTestCas * * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testHoliday(int $year, DateTime $expected): void { @@ -60,7 +57,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -75,7 +72,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Croatia/ChristmasDayTest.php b/tests/Croatia/ChristmasDayTest.php index 48b2f62b0..759351789 100644 --- a/tests/Croatia/ChristmasDayTest.php +++ b/tests/Croatia/ChristmasDayTest.php @@ -16,7 +16,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -37,8 +36,6 @@ class ChristmasDayTest extends CroatiaBaseTestCase implements HolidayTestCase * * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testHoliday(int $year, DateTime $expected): void { @@ -60,7 +57,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -75,7 +72,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Croatia/CorpusChristiTest.php b/tests/Croatia/CorpusChristiTest.php index 20b8bcf01..ff9bf6847 100644 --- a/tests/Croatia/CorpusChristiTest.php +++ b/tests/Croatia/CorpusChristiTest.php @@ -16,7 +16,6 @@ use DateInterval; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\Provider\ChristianHolidays; use Yasumi\tests\HolidayTestCase; @@ -37,7 +36,6 @@ class CorpusChristiTest extends CroatiaBaseTestCase implements HolidayTestCase * Tests Corpus Christi. * * @throws Exception - * @throws ReflectionException */ public function testCorpusChristi(): void { @@ -53,7 +51,7 @@ public function testCorpusChristi(): void /** * Tests translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -68,7 +66,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Croatia/CroatiaTest.php b/tests/Croatia/CroatiaTest.php index 98652c6a7..50420f792 100644 --- a/tests/Croatia/CroatiaTest.php +++ b/tests/Croatia/CroatiaTest.php @@ -30,6 +30,8 @@ class CroatiaTest extends CroatiaBaseTestCase implements ProviderTestCase /** * Initial setup of this Test Case. + * + * @throws \Exception */ protected function setUp(): void { @@ -38,8 +40,6 @@ protected function setUp(): void /** * Tests if all official holidays in Croatia are defined by the provider class. - * - * @throws ReflectionException */ public function testOfficialHolidays(): void { @@ -81,8 +81,6 @@ public function testOfficialHolidays(): void /** * Tests if all observed holidays in Croatia are defined by the provider class. - * - * @throws ReflectionException */ public function testObservedHolidays(): void { @@ -91,8 +89,6 @@ public function testObservedHolidays(): void /** * Tests if all seasonal holidays in Croatia are defined by the provider class. - * - * @throws ReflectionException */ public function testSeasonalHolidays(): void { @@ -101,8 +97,6 @@ public function testSeasonalHolidays(): void /** * Tests if all bank holidays in Croatia are defined by the provider class. - * - * @throws ReflectionException */ public function testBankHolidays(): void { @@ -111,8 +105,6 @@ public function testBankHolidays(): void /** * Tests if all other holidays in Croatia are defined by the provider class. - * - * @throws ReflectionException */ public function testOtherHolidays(): void { @@ -121,6 +113,7 @@ public function testOtherHolidays(): void /** * @throws ReflectionException + * @throws \Exception */ public function testSources(): void { diff --git a/tests/Croatia/EasterMondayTest.php b/tests/Croatia/EasterMondayTest.php index 16fca9417..4336eeec5 100644 --- a/tests/Croatia/EasterMondayTest.php +++ b/tests/Croatia/EasterMondayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -35,7 +34,6 @@ class EasterMondayTest extends CroatiaBaseTestCase implements HolidayTestCase * Tests the holiday defined in this test. * * @throws Exception - * @throws ReflectionException */ public function testHoliday(): void { @@ -51,7 +49,7 @@ public function testHoliday(): void /** * Tests translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -66,7 +64,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Croatia/EasterTest.php b/tests/Croatia/EasterTest.php index 1a20b505d..e75ae4918 100644 --- a/tests/Croatia/EasterTest.php +++ b/tests/Croatia/EasterTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -35,7 +34,6 @@ class EasterTest extends CroatiaBaseTestCase implements HolidayTestCase * Tests the holiday defined in this test. * * @throws Exception - * @throws ReflectionException */ public function testHoliday(): void { @@ -51,7 +49,7 @@ public function testHoliday(): void /** * Tests translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -66,7 +64,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Croatia/EpiphanyTest.php b/tests/Croatia/EpiphanyTest.php index 35b1b16d5..c3c7f3dff 100644 --- a/tests/Croatia/EpiphanyTest.php +++ b/tests/Croatia/EpiphanyTest.php @@ -16,7 +16,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -37,8 +36,6 @@ class EpiphanyTest extends CroatiaBaseTestCase implements HolidayTestCase * * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testHoliday(int $year, DateTime $expected): void { @@ -60,7 +57,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -75,7 +72,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Croatia/HomelandThanksgivingDayTest.php b/tests/Croatia/HomelandThanksgivingDayTest.php index 1671a54e7..91fe5721a 100644 --- a/tests/Croatia/HomelandThanksgivingDayTest.php +++ b/tests/Croatia/HomelandThanksgivingDayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -45,7 +44,6 @@ class HomelandThanksgivingDayTest extends CroatiaBaseTestCase implements Holiday * Tests Homeland Thanksgiving Day on or after 1995. * * @throws Exception - * @throws ReflectionException */ public function testHomelandThanksgivingDayOnAfter1995(): void { @@ -61,7 +59,7 @@ public function testHomelandThanksgivingDayOnAfter1995(): void /** * Tests Homeland Thanksgiving Day before 1995. * - * @throws ReflectionException + * @throws Exception */ public function testHomelandThanksgivingDayBefore1995(): void { @@ -75,7 +73,7 @@ public function testHomelandThanksgivingDayBefore1995(): void /** * Tests translated name of Homeland Thanksgiving Day. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -101,7 +99,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Croatia/IndependenceDayTest.php b/tests/Croatia/IndependenceDayTest.php index 2ea157559..63abb5f1b 100644 --- a/tests/Croatia/IndependenceDayTest.php +++ b/tests/Croatia/IndependenceDayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -45,7 +44,6 @@ class IndependenceDayTest extends CroatiaBaseTestCase implements HolidayTestCase * Tests Independence Day on or after 1991. * * @throws Exception - * @throws ReflectionException */ public function testIndependenceDayOnAfter1991(): void { @@ -61,7 +59,7 @@ public function testIndependenceDayOnAfter1991(): void /** * Tests Independence Day before 1991. * - * @throws ReflectionException + * @throws Exception */ public function testIndependenceDayBefore1991(): void { @@ -75,7 +73,7 @@ public function testIndependenceDayBefore1991(): void /** * Tests Independence Day before 1991. * - * @throws ReflectionException + * @throws Exception */ public function testIndependenceDayAfterDisbandment(): void { @@ -89,7 +87,7 @@ public function testIndependenceDayAfterDisbandment(): void /** * Tests translated name of Independence Day. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -104,7 +102,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Croatia/InternationalWorkersDayTest.php b/tests/Croatia/InternationalWorkersDayTest.php index fd81ac3e9..bacd804c2 100644 --- a/tests/Croatia/InternationalWorkersDayTest.php +++ b/tests/Croatia/InternationalWorkersDayTest.php @@ -16,7 +16,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -37,8 +36,6 @@ class InternationalWorkersDayTest extends CroatiaBaseTestCase implements Holiday * * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testHoliday(int $year, DateTime $expected): void { @@ -48,7 +45,7 @@ public function testHoliday(int $year, DateTime $expected): void /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -63,7 +60,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Croatia/NewYearsDayTest.php b/tests/Croatia/NewYearsDayTest.php index 43661610e..fe136f74e 100644 --- a/tests/Croatia/NewYearsDayTest.php +++ b/tests/Croatia/NewYearsDayTest.php @@ -16,7 +16,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -37,8 +36,6 @@ class NewYearsDayTest extends CroatiaBaseTestCase implements HolidayTestCase * * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testHoliday(int $year, DateTime $expected): void { @@ -60,7 +57,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -75,7 +72,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Croatia/RemembranceDayTest.php b/tests/Croatia/RemembranceDayTest.php index 48ad1558c..376354dc9 100644 --- a/tests/Croatia/RemembranceDayTest.php +++ b/tests/Croatia/RemembranceDayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -40,7 +39,6 @@ class RemembranceDayTest extends CroatiaBaseTestCase implements HolidayTestCase * Tests Remembrance Day. * * @throws Exception - * @throws ReflectionException */ public function testRemembranceDayAfterItWasEstablished(): void { @@ -57,7 +55,6 @@ public function testRemembranceDayAfterItWasEstablished(): void * Tests Remembrance Day. * * @throws Exception - * @throws ReflectionException */ public function testRemembranceDayBeforeItWasEstablished(): void { @@ -71,7 +68,7 @@ public function testRemembranceDayBeforeItWasEstablished(): void /** * Tests translated name of Remembrance Day. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -86,7 +83,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Croatia/StStephensDayTest.php b/tests/Croatia/StStephensDayTest.php index ae5171375..fe27bb07b 100644 --- a/tests/Croatia/StStephensDayTest.php +++ b/tests/Croatia/StStephensDayTest.php @@ -16,7 +16,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -37,8 +36,6 @@ class StStephensDayTest extends CroatiaBaseTestCase implements HolidayTestCase * * @param int $year the year for which St. Stephen's Day needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function teststStephensDay(int $year, DateTime $expected): void { @@ -60,7 +57,7 @@ public function stStephensDayDataProvider(): array /** * Tests translated name of St. Stephen's Day. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -75,7 +72,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Croatia/StatehoodDayTest.php b/tests/Croatia/StatehoodDayTest.php index 3de09184b..9b98d48c4 100644 --- a/tests/Croatia/StatehoodDayTest.php +++ b/tests/Croatia/StatehoodDayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -45,7 +44,6 @@ class StatehoodDayTest extends CroatiaBaseTestCase implements HolidayTestCase * Tests Statehood Day. * * @throws Exception - * @throws ReflectionException */ public function testStatehoodDay(): void { @@ -71,7 +69,7 @@ public function testStatehoodDay(): void /** * Tests Statehood Day before 1991. * - * @throws ReflectionException + * @throws Exception */ public function testStatehoodDayBefore1991(): void { @@ -85,7 +83,7 @@ public function testStatehoodDayBefore1991(): void /** * Tests translated name of Statehood Day. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -100,7 +98,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/CzechRepublic/ChristmasDayTest.php b/tests/CzechRepublic/ChristmasDayTest.php index 4dc6247d0..fa1ef6b41 100644 --- a/tests/CzechRepublic/ChristmasDayTest.php +++ b/tests/CzechRepublic/ChristmasDayTest.php @@ -16,7 +16,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -41,8 +40,6 @@ class ChristmasDayTest extends CzechRepublicBaseTestCase implements HolidayTestC * * @param int $year the year for which Christmas Day needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testChristmasDay(int $year, DateTime $expected): void { @@ -64,7 +61,7 @@ public function HolidayDataProvider(): array /** * Tests translated name of Christmas Day. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -79,7 +76,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/CzechRepublic/ChristmasEveTest.php b/tests/CzechRepublic/ChristmasEveTest.php index f9cd7ac53..d3c0096b1 100644 --- a/tests/CzechRepublic/ChristmasEveTest.php +++ b/tests/CzechRepublic/ChristmasEveTest.php @@ -16,7 +16,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -41,8 +40,6 @@ class ChristmasEveTest extends CzechRepublicBaseTestCase implements HolidayTestC * * @param int $year the year for which Christmas Eve needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testChristmasDay(int $year, DateTime $expected): void { @@ -64,7 +61,7 @@ public function HolidayDataProvider(): array /** * Tests translated name of Christmas Day. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -79,7 +76,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/CzechRepublic/CzechRepublicTest.php b/tests/CzechRepublic/CzechRepublicTest.php index e69602492..f6170ed92 100644 --- a/tests/CzechRepublic/CzechRepublicTest.php +++ b/tests/CzechRepublic/CzechRepublicTest.php @@ -30,10 +30,12 @@ class CzechRepublicTest extends CzechRepublicBaseTestCase implements ProviderTes /** * @var int year random year number used for all tests in this Test Case */ - protected $year; + protected int $year; /** * Initial setup of this Test Case. + * + * @throws \Exception */ protected function setUp(): void { @@ -42,8 +44,6 @@ protected function setUp(): void /** * Tests if all official holidays in Finland are defined by the provider class. - * - * @throws ReflectionException */ public function testOfficialHolidays(): void { @@ -66,8 +66,6 @@ public function testOfficialHolidays(): void /** * Tests if all observed holidays in the Czech Republic are defined by the provider class. - * - * @throws ReflectionException */ public function testObservedHolidays(): void { @@ -76,8 +74,6 @@ public function testObservedHolidays(): void /** * Tests if all seasonal holidays in the Czech Republic are defined by the provider class. - * - * @throws ReflectionException */ public function testSeasonalHolidays(): void { @@ -86,8 +82,6 @@ public function testSeasonalHolidays(): void /** * Tests if all bank holidays in the Czech Republic are defined by the provider class. - * - * @throws ReflectionException */ public function testBankHolidays(): void { @@ -96,8 +90,6 @@ public function testBankHolidays(): void /** * Tests if all other holidays in the Czech Republic are defined by the provider class. - * - * @throws ReflectionException */ public function testOtherHolidays(): void { @@ -106,6 +98,7 @@ public function testOtherHolidays(): void /** * @throws ReflectionException + * @throws \Exception */ public function testSources(): void { diff --git a/tests/CzechRepublic/CzechStateHoodDayTest.php b/tests/CzechRepublic/CzechStateHoodDayTest.php index 721f22bec..3cdff1952 100644 --- a/tests/CzechRepublic/CzechStateHoodDayTest.php +++ b/tests/CzechRepublic/CzechStateHoodDayTest.php @@ -16,7 +16,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -41,8 +40,6 @@ class CzechStateHoodDayTest extends CzechRepublicBaseTestCase implements Holiday * * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testHoliday(int $year, DateTime $expected): void { @@ -64,7 +61,7 @@ public function HolidayDataProvider(): array /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -79,7 +76,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/CzechRepublic/EasterMondayTest.php b/tests/CzechRepublic/EasterMondayTest.php index 94ffccbb1..c0c190fc2 100644 --- a/tests/CzechRepublic/EasterMondayTest.php +++ b/tests/CzechRepublic/EasterMondayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -39,7 +38,6 @@ class EasterMondayTest extends CzechRepublicBaseTestCase implements HolidayTestC * Tests the holiday defined in this test. * * @throws Exception - * @throws ReflectionException */ public function testHoliday(): void { @@ -55,7 +53,7 @@ public function testHoliday(): void /** * Tests translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -70,7 +68,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/CzechRepublic/GoodFridayTest.php b/tests/CzechRepublic/GoodFridayTest.php index 08533553f..40500243e 100644 --- a/tests/CzechRepublic/GoodFridayTest.php +++ b/tests/CzechRepublic/GoodFridayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -39,7 +38,6 @@ class GoodFridayTest extends CzechRepublicBaseTestCase implements HolidayTestCas * Tests Good Friday. * * @throws Exception - * @throws ReflectionException */ public function testGoodFriday(): void { @@ -55,7 +53,7 @@ public function testGoodFriday(): void /** * Tests translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -70,7 +68,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/CzechRepublic/IndependentCzechoslovakStateDayTest.php b/tests/CzechRepublic/IndependentCzechoslovakStateDayTest.php index cbce326ce..baaf565b7 100644 --- a/tests/CzechRepublic/IndependentCzechoslovakStateDayTest.php +++ b/tests/CzechRepublic/IndependentCzechoslovakStateDayTest.php @@ -16,7 +16,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -37,8 +36,6 @@ class IndependentCzechoslovakStateDayTest extends CzechRepublicBaseTestCase impl * * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testHoliday(int $year, DateTime $expected): void { @@ -60,7 +57,7 @@ public function HolidayDataProvider(): array /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -75,7 +72,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/CzechRepublic/InternationalWorkersDayTest.php b/tests/CzechRepublic/InternationalWorkersDayTest.php index f9bdb32fd..5fe46f617 100644 --- a/tests/CzechRepublic/InternationalWorkersDayTest.php +++ b/tests/CzechRepublic/InternationalWorkersDayTest.php @@ -16,7 +16,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -41,8 +40,6 @@ class InternationalWorkersDayTest extends CzechRepublicBaseTestCase implements H * * @param int $year the year for which International Workers' Day needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testHoliday(int $year, DateTime $expected): void { @@ -52,7 +49,7 @@ public function testHoliday(int $year, DateTime $expected): void /** * Tests translated name of International Workers' Day. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -67,7 +64,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/CzechRepublic/JanHusDayTest.php b/tests/CzechRepublic/JanHusDayTest.php index a276145b4..82958228a 100644 --- a/tests/CzechRepublic/JanHusDayTest.php +++ b/tests/CzechRepublic/JanHusDayTest.php @@ -16,7 +16,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -37,8 +36,6 @@ class JanHusDayTest extends CzechRepublicBaseTestCase implements HolidayTestCase * * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testHoliday(int $year, DateTime $expected): void { @@ -60,7 +57,7 @@ public function HolidayDataProvider(): array /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -75,7 +72,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/CzechRepublic/NewYearsDayTest.php b/tests/CzechRepublic/NewYearsDayTest.php index 081d5b135..47f9b5529 100644 --- a/tests/CzechRepublic/NewYearsDayTest.php +++ b/tests/CzechRepublic/NewYearsDayTest.php @@ -16,7 +16,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -41,8 +40,6 @@ class NewYearsDayTest extends CzechRepublicBaseTestCase implements HolidayTestCa * * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testHoliday(int $year, DateTime $expected): void { @@ -64,7 +61,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -79,7 +76,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/CzechRepublic/RenewalOfIndependentCzechStateDayTest.php b/tests/CzechRepublic/RenewalOfIndependentCzechStateDayTest.php index e951b1a5a..4036ffbc0 100644 --- a/tests/CzechRepublic/RenewalOfIndependentCzechStateDayTest.php +++ b/tests/CzechRepublic/RenewalOfIndependentCzechStateDayTest.php @@ -16,7 +16,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -40,8 +39,6 @@ class RenewalOfIndependentCzechStateDayTest extends CzechRepublicBaseTestCase im * * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testHoliday(int $year, DateTime $expected): void { @@ -63,7 +60,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -78,7 +75,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/CzechRepublic/SaintsCyrilAndMethodiusDayTest.php b/tests/CzechRepublic/SaintsCyrilAndMethodiusDayTest.php index 937f89015..63d3df693 100644 --- a/tests/CzechRepublic/SaintsCyrilAndMethodiusDayTest.php +++ b/tests/CzechRepublic/SaintsCyrilAndMethodiusDayTest.php @@ -16,7 +16,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -41,8 +40,6 @@ class SaintsCyrilAndMethodiusDayTest extends CzechRepublicBaseTestCase implement * * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testHoliday(int $year, DateTime $expected): void { @@ -64,7 +61,7 @@ public function HolidayDataProvider(): array /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -79,7 +76,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/CzechRepublic/SecondChristmasDayTest.php b/tests/CzechRepublic/SecondChristmasDayTest.php index 94f152f2e..72ba345a8 100644 --- a/tests/CzechRepublic/SecondChristmasDayTest.php +++ b/tests/CzechRepublic/SecondChristmasDayTest.php @@ -16,7 +16,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -41,8 +40,6 @@ class SecondChristmasDayTest extends CzechRepublicBaseTestCase implements Holida * * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testHoliday(int $year, DateTime $expected): void { @@ -64,7 +61,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -79,7 +76,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/CzechRepublic/StruggleForFreedomAndDemocracyDayTest.php b/tests/CzechRepublic/StruggleForFreedomAndDemocracyDayTest.php index 31e15f7e9..ef7a19c45 100644 --- a/tests/CzechRepublic/StruggleForFreedomAndDemocracyDayTest.php +++ b/tests/CzechRepublic/StruggleForFreedomAndDemocracyDayTest.php @@ -16,7 +16,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -37,8 +36,6 @@ class StruggleForFreedomAndDemocracyDayTest extends CzechRepublicBaseTestCase im * * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testHoliday(int $year, DateTime $expected): void { @@ -60,7 +57,7 @@ public function HolidayDataProvider(): array /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -75,7 +72,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/CzechRepublic/VictoryInEuropeDayTest.php b/tests/CzechRepublic/VictoryInEuropeDayTest.php index fa1dcd128..8cb5f7041 100644 --- a/tests/CzechRepublic/VictoryInEuropeDayTest.php +++ b/tests/CzechRepublic/VictoryInEuropeDayTest.php @@ -16,7 +16,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -41,8 +40,6 @@ class VictoryInEuropeDayTest extends CzechRepublicBaseTestCase implements Holida * * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testHoliday(int $year, DateTime $expected): void { @@ -64,7 +61,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -79,7 +76,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Denmark/AscensionDayTest.php b/tests/Denmark/AscensionDayTest.php index b17b9f86b..0d517c15c 100644 --- a/tests/Denmark/AscensionDayTest.php +++ b/tests/Denmark/AscensionDayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -35,7 +34,6 @@ class AscensionDayTest extends DenmarkBaseTestCase implements HolidayTestCase * Tests Ascension Day. * * @throws Exception - * @throws ReflectionException */ public function testAscensionDay(): void { @@ -51,7 +49,7 @@ public function testAscensionDay(): void /** * Tests translated name of Ascension Day. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -66,7 +64,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Denmark/ChristmasDayTest.php b/tests/Denmark/ChristmasDayTest.php index da84ebb2e..1894672fd 100644 --- a/tests/Denmark/ChristmasDayTest.php +++ b/tests/Denmark/ChristmasDayTest.php @@ -16,7 +16,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -37,8 +36,6 @@ class ChristmasDayTest extends DenmarkBaseTestCase implements HolidayTestCase * * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testHoliday(int $year, DateTime $expected): void { @@ -60,7 +57,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -75,7 +72,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Denmark/ChristmasEveTest.php b/tests/Denmark/ChristmasEveTest.php index 8cdeeeb91..144678d9e 100644 --- a/tests/Denmark/ChristmasEveTest.php +++ b/tests/Denmark/ChristmasEveTest.php @@ -16,7 +16,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -37,8 +36,6 @@ class ChristmasEveTest extends DenmarkBaseTestCase implements HolidayTestCase * * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testHoliday(int $year, DateTime $expected): void { @@ -60,7 +57,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -75,7 +72,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Denmark/ConstitutionDayTest.php b/tests/Denmark/ConstitutionDayTest.php index 7023256bd..a2787feb2 100644 --- a/tests/Denmark/ConstitutionDayTest.php +++ b/tests/Denmark/ConstitutionDayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -40,7 +39,6 @@ class ConstitutionDayTest extends DenmarkBaseTestCase implements HolidayTestCase * Tests the holiday defined in this test on or after establishment. * * @throws Exception - * @throws ReflectionException */ public function testHolidayOnAfterEstablishment(): void { @@ -56,7 +54,7 @@ public function testHolidayOnAfterEstablishment(): void /** * Tests the holiday defined in this test before establishment. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayBeforeEstablishment(): void { @@ -70,7 +68,7 @@ public function testHolidayBeforeEstablishment(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -85,7 +83,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Denmark/DenmarkTest.php b/tests/Denmark/DenmarkTest.php index 79cb6fca8..d5a3a928d 100644 --- a/tests/Denmark/DenmarkTest.php +++ b/tests/Denmark/DenmarkTest.php @@ -30,6 +30,8 @@ class DenmarkTest extends DenmarkBaseTestCase implements ProviderTestCase /** * Initial setup of this Test Case. + * + * @throws \Exception */ protected function setUp(): void { @@ -38,8 +40,6 @@ protected function setUp(): void /** * Tests if all official holidays in Denmark are defined by the provider class. - * - * @throws ReflectionException */ public function testOfficialHolidays(): void { @@ -60,8 +60,6 @@ public function testOfficialHolidays(): void /** * Tests if all observed holidays in Denmark are defined by the provider class. - * - * @throws ReflectionException */ public function testObservedHolidays(): void { @@ -76,7 +74,7 @@ public function testObservedHolidays(): void /** * Tests if all seasonal holidays in Denmark are defined by the provider class. * - * @throws ReflectionException + * @throws \Exception */ public function testSeasonalHolidays(): void { @@ -86,8 +84,6 @@ public function testSeasonalHolidays(): void /** * Tests if all bank holidays in Denmark are defined by the provider class. - * - * @throws ReflectionException */ public function testBankHolidays(): void { @@ -96,8 +92,6 @@ public function testBankHolidays(): void /** * Tests if all other holidays in Denmark are defined by the provider class. - * - * @throws ReflectionException */ public function testOtherHolidays(): void { @@ -106,6 +100,7 @@ public function testOtherHolidays(): void /** * @throws ReflectionException + * @throws \Exception */ public function testSources(): void { diff --git a/tests/Denmark/EasterMondayTest.php b/tests/Denmark/EasterMondayTest.php index 87daa37a8..657a717aa 100644 --- a/tests/Denmark/EasterMondayTest.php +++ b/tests/Denmark/EasterMondayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -35,7 +34,6 @@ class EasterMondayTest extends DenmarkBaseTestCase implements HolidayTestCase * Tests the holiday defined in this test. * * @throws Exception - * @throws ReflectionException */ public function testHoliday(): void { @@ -51,7 +49,7 @@ public function testHoliday(): void /** * Tests translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -66,7 +64,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Denmark/EasterTest.php b/tests/Denmark/EasterTest.php index f328718b5..1a154c98c 100644 --- a/tests/Denmark/EasterTest.php +++ b/tests/Denmark/EasterTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -35,7 +34,6 @@ class EasterTest extends DenmarkBaseTestCase implements HolidayTestCase * Tests the holiday defined in this test. * * @throws Exception - * @throws ReflectionException */ public function testHoliday(): void { @@ -51,7 +49,7 @@ public function testHoliday(): void /** * Tests translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -66,7 +64,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Denmark/GoodFridayTest.php b/tests/Denmark/GoodFridayTest.php index 77e94cb82..89a55047c 100644 --- a/tests/Denmark/GoodFridayTest.php +++ b/tests/Denmark/GoodFridayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -35,7 +34,6 @@ class GoodFridayTest extends DenmarkBaseTestCase implements HolidayTestCase * Tests the holiday defined in this test. * * @throws Exception - * @throws ReflectionException */ public function testHoliday(): void { @@ -51,7 +49,7 @@ public function testHoliday(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -66,7 +64,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Denmark/GreatPrayerDayTest.php b/tests/Denmark/GreatPrayerDayTest.php index 66f494a1e..494ee5d17 100644 --- a/tests/Denmark/GreatPrayerDayTest.php +++ b/tests/Denmark/GreatPrayerDayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -40,7 +39,6 @@ class GreatPrayerDayTest extends DenmarkBaseTestCase implements HolidayTestCase * Tests the holiday defined in this test on or after establishment. * * @throws Exception - * @throws ReflectionException */ public function testHolidayOnAfterEstablishment(): void { @@ -56,7 +54,7 @@ public function testHolidayOnAfterEstablishment(): void /** * Tests the holiday defined in this test before establishment. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayBeforeEstablishment(): void { @@ -70,7 +68,7 @@ public function testHolidayBeforeEstablishment(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -85,7 +83,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Denmark/InternationalWorkersDayTest.php b/tests/Denmark/InternationalWorkersDayTest.php index 8a6ed9686..c7cf4f642 100644 --- a/tests/Denmark/InternationalWorkersDayTest.php +++ b/tests/Denmark/InternationalWorkersDayTest.php @@ -16,7 +16,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -37,8 +36,6 @@ class InternationalWorkersDayTest extends DenmarkBaseTestCase implements Holiday * * @param int $year the year for which International Workers' Day needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testInternationalWorkersDay(int $year, DateTime $expected): void { @@ -60,7 +57,7 @@ public function InternationalWorkersDayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -75,7 +72,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Denmark/MaundyThursdayTest.php b/tests/Denmark/MaundyThursdayTest.php index e3f6c5336..6d77b3805 100644 --- a/tests/Denmark/MaundyThursdayTest.php +++ b/tests/Denmark/MaundyThursdayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -35,7 +34,6 @@ class MaundyThursdayTest extends DenmarkBaseTestCase implements HolidayTestCase * Tests the holiday defined in this test. * * @throws Exception - * @throws ReflectionException */ public function testHoliday(): void { @@ -51,7 +49,7 @@ public function testHoliday(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -66,7 +64,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Denmark/NewYearsDayTest.php b/tests/Denmark/NewYearsDayTest.php index e844f4c1d..c9ddc59c3 100644 --- a/tests/Denmark/NewYearsDayTest.php +++ b/tests/Denmark/NewYearsDayTest.php @@ -16,7 +16,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -37,8 +36,6 @@ class NewYearsDayTest extends DenmarkBaseTestCase implements HolidayTestCase * * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testHoliday(int $year, DateTime $expected): void { @@ -60,7 +57,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -75,7 +72,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Denmark/NewYearsEveTest.php b/tests/Denmark/NewYearsEveTest.php index b16335eda..c281ad1a1 100644 --- a/tests/Denmark/NewYearsEveTest.php +++ b/tests/Denmark/NewYearsEveTest.php @@ -16,7 +16,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -37,8 +36,6 @@ class NewYearsEveTest extends DenmarkBaseTestCase implements HolidayTestCase * * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testHoliday(int $year, DateTime $expected): void { @@ -60,7 +57,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -75,7 +72,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Denmark/PentecostMondayTest.php b/tests/Denmark/PentecostMondayTest.php index b62d2db43..1ee6251e5 100644 --- a/tests/Denmark/PentecostMondayTest.php +++ b/tests/Denmark/PentecostMondayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -35,7 +34,6 @@ class PentecostMondayTest extends DenmarkBaseTestCase implements HolidayTestCase * Tests the holiday defined in this test. * * @throws Exception - * @throws ReflectionException */ public function testHoliday(): void { @@ -51,7 +49,7 @@ public function testHoliday(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -66,7 +64,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Denmark/PentecostTest.php b/tests/Denmark/PentecostTest.php index 79f58903c..59fbdf37b 100644 --- a/tests/Denmark/PentecostTest.php +++ b/tests/Denmark/PentecostTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -35,7 +34,6 @@ class PentecostTest extends DenmarkBaseTestCase implements HolidayTestCase * Tests the holiday defined in this test. * * @throws Exception - * @throws ReflectionException */ public function testHoliday(): void { @@ -51,7 +49,7 @@ public function testHoliday(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -66,7 +64,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Denmark/SecondChristmasDayTest.php b/tests/Denmark/SecondChristmasDayTest.php index 6d93a34f9..e7de79ba1 100644 --- a/tests/Denmark/SecondChristmasDayTest.php +++ b/tests/Denmark/SecondChristmasDayTest.php @@ -16,7 +16,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -37,8 +36,6 @@ class SecondChristmasDayTest extends DenmarkBaseTestCase implements HolidayTestC * * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testHoliday(int $year, DateTime $expected): void { @@ -60,7 +57,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -75,7 +72,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Denmark/SummerTimeTest.php b/tests/Denmark/SummerTimeTest.php index d7af59a0c..dbdb66c95 100644 --- a/tests/Denmark/SummerTimeTest.php +++ b/tests/Denmark/SummerTimeTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -35,7 +34,6 @@ class SummerTimeTest extends DenmarkBaseTestCase implements HolidayTestCase * Tests the holiday defined in this test. * * @throws Exception - * @throws ReflectionException */ public function testSummerTime(): void { @@ -60,7 +58,7 @@ public function testSummerTime(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -75,7 +73,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Denmark/WinterTimeTest.php b/tests/Denmark/WinterTimeTest.php index 792499428..01fe35ad1 100644 --- a/tests/Denmark/WinterTimeTest.php +++ b/tests/Denmark/WinterTimeTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -35,7 +34,6 @@ class WinterTimeTest extends DenmarkBaseTestCase implements HolidayTestCase * Tests the holiday defined in this test. * * @throws Exception - * @throws ReflectionException */ public function testWinterTime(): void { @@ -61,7 +59,7 @@ public function testWinterTime(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -76,7 +74,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Estonia/ChristmasDayTest.php b/tests/Estonia/ChristmasDayTest.php index 5aadd5ff9..0f99ddc6a 100644 --- a/tests/Estonia/ChristmasDayTest.php +++ b/tests/Estonia/ChristmasDayTest.php @@ -17,7 +17,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -45,8 +44,6 @@ public function holidayDataProvider(): array /** * @dataProvider holidayDataProvider - * - * @throws ReflectionException */ public function testHoliday(int $year, DateTime $expected): void { @@ -56,7 +53,7 @@ public function testHoliday(int $year, DateTime $expected): void /** * {@inheritdoc} * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -71,7 +68,7 @@ public function testTranslation(): void /** * {@inheritdoc} * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Estonia/ChristmasEveDayTest.php b/tests/Estonia/ChristmasEveDayTest.php index bdddf9630..c093d8dfb 100644 --- a/tests/Estonia/ChristmasEveDayTest.php +++ b/tests/Estonia/ChristmasEveDayTest.php @@ -17,7 +17,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -45,8 +44,6 @@ public function holidayDataProvider(): array /** * @dataProvider holidayDataProvider - * - * @throws ReflectionException */ public function testHoliday(int $year, DateTime $expected): void { @@ -56,7 +53,7 @@ public function testHoliday(int $year, DateTime $expected): void /** * {@inheritdoc} * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -71,7 +68,7 @@ public function testTranslation(): void /** * {@inheritdoc} * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Estonia/EasterDayTest.php b/tests/Estonia/EasterDayTest.php index b37d453a0..096583288 100644 --- a/tests/Estonia/EasterDayTest.php +++ b/tests/Estonia/EasterDayTest.php @@ -18,7 +18,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -52,7 +51,6 @@ public function holidayDataProvider(): array * @param int $year the year for which the holiday defined in this test needs to be tested * @param string $expected the expected date * - * @throws ReflectionException * @throws Exception */ public function testHoliday(int $year, string $expected): void @@ -68,7 +66,7 @@ public function testHoliday(int $year, string $expected): void /** * {@inheritdoc} * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -83,7 +81,7 @@ public function testTranslation(): void /** * {@inheritdoc} * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Estonia/EstoniaTest.php b/tests/Estonia/EstoniaTest.php index ec85bda72..41c3e8b07 100644 --- a/tests/Estonia/EstoniaTest.php +++ b/tests/Estonia/EstoniaTest.php @@ -30,7 +30,7 @@ class EstoniaTest extends EstoniaBaseTestCase implements ProviderTestCase /** * Tests if all official holidays in Estonia are defined by the provider class. * - * @throws ReflectionException + * @throws \Exception */ public function testOfficialHolidays(): void { @@ -66,7 +66,7 @@ public function testOfficialHolidays(): void /** * Tests if all observed holidays in Estonia are defined by the provider class. * - * @throws ReflectionException + * @throws \Exception */ public function testObservedHolidays(): void { @@ -76,7 +76,7 @@ public function testObservedHolidays(): void /** * Tests if all seasonal holidays in Estonia are defined by the provider class. * - * @throws ReflectionException + * @throws \Exception */ public function testSeasonalHolidays(): void { @@ -86,7 +86,7 @@ public function testSeasonalHolidays(): void /** * Tests if all bank holidays in Estonia are defined by the provider class. * - * @throws ReflectionException + * @throws \Exception */ public function testBankHolidays(): void { @@ -96,7 +96,7 @@ public function testBankHolidays(): void /** * Tests if all other holidays in Estonia are defined by the provider class. * - * @throws ReflectionException + * @throws \Exception */ public function testOtherHolidays(): void { @@ -105,6 +105,7 @@ public function testOtherHolidays(): void /** * @throws ReflectionException + * @throws \Exception */ public function testSources(): void { diff --git a/tests/Estonia/GoodFridayDayTest.php b/tests/Estonia/GoodFridayDayTest.php index adb757569..8aff83895 100644 --- a/tests/Estonia/GoodFridayDayTest.php +++ b/tests/Estonia/GoodFridayDayTest.php @@ -18,7 +18,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -52,7 +51,6 @@ public function holidayDataProvider(): array * @param int $year the year for which the holiday defined in this test needs to be tested * @param string $expected the expected date * - * @throws ReflectionException * @throws Exception */ public function testHoliday(int $year, string $expected): void @@ -68,7 +66,7 @@ public function testHoliday(int $year, string $expected): void /** * {@inheritdoc} * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -83,7 +81,7 @@ public function testTranslation(): void /** * {@inheritdoc} * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Estonia/IndependenceDayTest.php b/tests/Estonia/IndependenceDayTest.php index 4423b2ff3..d518c6760 100644 --- a/tests/Estonia/IndependenceDayTest.php +++ b/tests/Estonia/IndependenceDayTest.php @@ -18,7 +18,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\Provider\Estonia; use Yasumi\tests\HolidayTestCase; @@ -38,7 +37,7 @@ class IndependenceDayTest extends EstoniaBaseTestCase implements HolidayTestCase /** * Test if holiday is not defined before. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayBefore(): void { @@ -53,7 +52,6 @@ public function testHolidayBefore(): void * Test if holiday is defined after. * * @throws Exception - * @throws ReflectionException */ public function testHolidayAfter(): void { @@ -70,7 +68,7 @@ public function testHolidayAfter(): void /** * {@inheritdoc} * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -91,7 +89,7 @@ public function testTranslation(): void /** * {@inheritdoc} * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Estonia/InternationalWorkersDayTest.php b/tests/Estonia/InternationalWorkersDayTest.php index 0f6f8ff6e..01eb7a3c3 100644 --- a/tests/Estonia/InternationalWorkersDayTest.php +++ b/tests/Estonia/InternationalWorkersDayTest.php @@ -17,7 +17,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -45,8 +44,6 @@ public function holidayDataProvider(): array /** * @dataProvider holidayDataProvider - * - * @throws ReflectionException */ public function testHoliday(int $year, DateTime $expected): void { @@ -56,7 +53,7 @@ public function testHoliday(int $year, DateTime $expected): void /** * {@inheritdoc} * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -71,7 +68,7 @@ public function testTranslation(): void /** * {@inheritdoc} * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Estonia/NewYearsDayTest.php b/tests/Estonia/NewYearsDayTest.php index 6be904b9d..e33ef6753 100644 --- a/tests/Estonia/NewYearsDayTest.php +++ b/tests/Estonia/NewYearsDayTest.php @@ -17,7 +17,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -45,8 +44,6 @@ public function holidayDataProvider(): array /** * @dataProvider holidayDataProvider - * - * @throws ReflectionException */ public function testHoliday(int $year, DateTime $expected): void { @@ -56,7 +53,7 @@ public function testHoliday(int $year, DateTime $expected): void /** * {@inheritdoc} * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -71,7 +68,7 @@ public function testTranslation(): void /** * {@inheritdoc} * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Estonia/PentecostTest.php b/tests/Estonia/PentecostTest.php index 5dc27dab7..b5ebdc056 100644 --- a/tests/Estonia/PentecostTest.php +++ b/tests/Estonia/PentecostTest.php @@ -18,7 +18,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -52,7 +51,6 @@ public function holidayDataProvider(): array * @param int $year the year for which the holiday defined in this test needs to be tested * @param string $expected the expected date * - * @throws ReflectionException * @throws Exception */ public function testHoliday(int $year, string $expected): void @@ -68,7 +66,7 @@ public function testHoliday(int $year, string $expected): void /** * {@inheritdoc} * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -83,7 +81,7 @@ public function testTranslation(): void /** * {@inheritdoc} * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Estonia/RestorationOfIndependenceDayTest.php b/tests/Estonia/RestorationOfIndependenceDayTest.php index a375a50ae..bc0e1fa07 100644 --- a/tests/Estonia/RestorationOfIndependenceDayTest.php +++ b/tests/Estonia/RestorationOfIndependenceDayTest.php @@ -18,7 +18,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\Provider\Estonia; use Yasumi\tests\HolidayTestCase; @@ -38,7 +37,7 @@ class RestorationOfIndependenceDayTest extends EstoniaBaseTestCase implements Ho /** * Test if holiday is not defined before. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayBefore(): void { @@ -53,7 +52,6 @@ public function testHolidayBefore(): void * Test if holiday is defined after. * * @throws Exception - * @throws ReflectionException */ public function testHolidayAfter(): void { @@ -70,7 +68,7 @@ public function testHolidayAfter(): void /** * {@inheritdoc} * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -91,7 +89,7 @@ public function testTranslation(): void /** * {@inheritdoc} * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Estonia/SecondChristmasDayTest.php b/tests/Estonia/SecondChristmasDayTest.php index 39780fe8f..4846a9054 100644 --- a/tests/Estonia/SecondChristmasDayTest.php +++ b/tests/Estonia/SecondChristmasDayTest.php @@ -17,7 +17,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -45,8 +44,6 @@ public function holidayDataProvider(): array /** * @dataProvider holidayDataProvider - * - * @throws ReflectionException */ public function testHoliday(int $year, DateTime $expected): void { @@ -56,7 +53,7 @@ public function testHoliday(int $year, DateTime $expected): void /** * {@inheritdoc} * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -71,7 +68,7 @@ public function testTranslation(): void /** * {@inheritdoc} * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Estonia/StJohnsDayTest.php b/tests/Estonia/StJohnsDayTest.php index 4b443670a..e6cfe998d 100644 --- a/tests/Estonia/StJohnsDayTest.php +++ b/tests/Estonia/StJohnsDayTest.php @@ -17,7 +17,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -45,8 +44,6 @@ public function holidayDataProvider(): array /** * @dataProvider holidayDataProvider - * - * @throws ReflectionException */ public function testHoliday(int $year, DateTime $expected): void { @@ -56,7 +53,7 @@ public function testHoliday(int $year, DateTime $expected): void /** * {@inheritdoc} * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -71,7 +68,7 @@ public function testTranslation(): void /** * {@inheritdoc} * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Estonia/VictoryDayTest.php b/tests/Estonia/VictoryDayTest.php index 7ff5fda2a..853b7f329 100644 --- a/tests/Estonia/VictoryDayTest.php +++ b/tests/Estonia/VictoryDayTest.php @@ -18,7 +18,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\Provider\Estonia; use Yasumi\tests\HolidayTestCase; @@ -38,7 +37,7 @@ class VictoryDayTest extends EstoniaBaseTestCase implements HolidayTestCase /** * Test if holiday is not defined before. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayBefore(): void { @@ -53,7 +52,6 @@ public function testHolidayBefore(): void * Test if holiday is defined after. * * @throws Exception - * @throws ReflectionException */ public function testHolidayAfter(): void { @@ -70,7 +68,7 @@ public function testHolidayAfter(): void /** * {@inheritdoc} * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -91,7 +89,7 @@ public function testTranslation(): void /** * {@inheritdoc} * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Finland/AllSaintsDayTest.php b/tests/Finland/AllSaintsDayTest.php index 60b944f89..22de63d6f 100644 --- a/tests/Finland/AllSaintsDayTest.php +++ b/tests/Finland/AllSaintsDayTest.php @@ -18,7 +18,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -39,8 +38,6 @@ class AllSaintsDayTest extends FinlandBaseTestCase implements HolidayTestCase * * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testHoliday(int $year, DateTime $expected): void { @@ -78,7 +75,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -93,7 +90,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Finland/AscensionDayTest.php b/tests/Finland/AscensionDayTest.php index a0dde23d2..d052f8fea 100644 --- a/tests/Finland/AscensionDayTest.php +++ b/tests/Finland/AscensionDayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -35,7 +34,6 @@ class AscensionDayTest extends FinlandBaseTestCase implements HolidayTestCase * Tests the holiday defined in this test. * * @throws Exception - * @throws ReflectionException */ public function testHoliday(): void { @@ -51,7 +49,7 @@ public function testHoliday(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -66,7 +64,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Finland/ChristmasDayTest.php b/tests/Finland/ChristmasDayTest.php index 263bf9dc9..0c1ef4281 100644 --- a/tests/Finland/ChristmasDayTest.php +++ b/tests/Finland/ChristmasDayTest.php @@ -16,7 +16,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -37,8 +36,6 @@ class ChristmasDayTest extends FinlandBaseTestCase implements HolidayTestCase * * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testHoliday(int $year, DateTime $expected): void { @@ -60,7 +57,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -75,7 +72,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Finland/EasterMondayTest.php b/tests/Finland/EasterMondayTest.php index 51b1da3f0..ed1e5e3a7 100644 --- a/tests/Finland/EasterMondayTest.php +++ b/tests/Finland/EasterMondayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -35,7 +34,6 @@ class EasterMondayTest extends FinlandBaseTestCase implements HolidayTestCase * Tests the holiday defined in this test. * * @throws Exception - * @throws ReflectionException */ public function testHoliday(): void { @@ -51,7 +49,7 @@ public function testHoliday(): void /** * Tests translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -66,7 +64,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Finland/EasterTest.php b/tests/Finland/EasterTest.php index 6f2170361..10e0ffa1b 100644 --- a/tests/Finland/EasterTest.php +++ b/tests/Finland/EasterTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -35,7 +34,6 @@ class EasterTest extends FinlandBaseTestCase implements HolidayTestCase * Tests the holiday defined in this test. * * @throws Exception - * @throws ReflectionException */ public function testHoliday(): void { @@ -51,7 +49,7 @@ public function testHoliday(): void /** * Tests translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -66,7 +64,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Finland/EpiphanyTest.php b/tests/Finland/EpiphanyTest.php index a66273efc..3b00cc05b 100644 --- a/tests/Finland/EpiphanyTest.php +++ b/tests/Finland/EpiphanyTest.php @@ -16,7 +16,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -37,8 +36,6 @@ class EpiphanyTest extends FinlandBaseTestCase implements HolidayTestCase * * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testHoliday(int $year, DateTime $expected): void { @@ -60,7 +57,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -75,7 +72,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Finland/FinlandTest.php b/tests/Finland/FinlandTest.php index 7f98f2580..16a8dc1db 100644 --- a/tests/Finland/FinlandTest.php +++ b/tests/Finland/FinlandTest.php @@ -30,6 +30,8 @@ class FinlandTest extends FinlandBaseTestCase implements ProviderTestCase /** * Initial setup of this Test Case. + * + * @throws \Exception */ protected function setUp(): void { @@ -38,8 +40,6 @@ protected function setUp(): void /** * Tests if all official holidays in Finland are defined by the provider class. - * - * @throws ReflectionException */ public function testOfficialHolidays(): void { @@ -62,8 +62,6 @@ public function testOfficialHolidays(): void /** * Tests if all observed holidays in Finland are defined by the provider class. - * - * @throws ReflectionException */ public function testObservedHolidays(): void { @@ -72,8 +70,6 @@ public function testObservedHolidays(): void /** * Tests if all seasonal holidays in Finland are defined by the provider class. - * - * @throws ReflectionException */ public function testSeasonalHolidays(): void { @@ -82,8 +78,6 @@ public function testSeasonalHolidays(): void /** * Tests if all bank holidays in Finland are defined by the provider class. - * - * @throws ReflectionException */ public function testBankHolidays(): void { @@ -92,8 +86,6 @@ public function testBankHolidays(): void /** * Tests if all other holidays in Finland are defined by the provider class. - * - * @throws ReflectionException */ public function testOtherHolidays(): void { @@ -102,6 +94,7 @@ public function testOtherHolidays(): void /** * @throws ReflectionException + * @throws \Exception */ public function testSources(): void { diff --git a/tests/Finland/GoodFridayTest.php b/tests/Finland/GoodFridayTest.php index 466d97c0b..196ff2288 100644 --- a/tests/Finland/GoodFridayTest.php +++ b/tests/Finland/GoodFridayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -35,7 +34,6 @@ class GoodFridayTest extends FinlandBaseTestCase implements HolidayTestCase * Tests the holiday defined in this test. * * @throws Exception - * @throws ReflectionException */ public function testHoliday(): void { @@ -51,7 +49,7 @@ public function testHoliday(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -66,7 +64,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Finland/IndependenceDayTest.php b/tests/Finland/IndependenceDayTest.php index 07581f40b..4552495b2 100644 --- a/tests/Finland/IndependenceDayTest.php +++ b/tests/Finland/IndependenceDayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -40,7 +39,6 @@ class IndependenceDayTest extends FinlandBaseTestCase implements HolidayTestCase * Tests the holiday defined in this test on or after establishment. * * @throws Exception - * @throws ReflectionException */ public function testHolidayOnAfterEstablishment(): void { @@ -56,7 +54,7 @@ public function testHolidayOnAfterEstablishment(): void /** * Tests the holiday defined in this test before establishment. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayBeforeEstablishment(): void { @@ -70,7 +68,7 @@ public function testHolidayBeforeEstablishment(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -85,7 +83,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Finland/InternationalWorkersDayTest.php b/tests/Finland/InternationalWorkersDayTest.php index 1734c8238..787c37829 100644 --- a/tests/Finland/InternationalWorkersDayTest.php +++ b/tests/Finland/InternationalWorkersDayTest.php @@ -16,7 +16,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -37,8 +36,6 @@ class InternationalWorkersDayTest extends FinlandBaseTestCase implements Holiday * * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testHoliday(int $year, DateTime $expected): void { @@ -48,7 +45,7 @@ public function testHoliday(int $year, DateTime $expected): void /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -63,7 +60,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Finland/NewYearsDayTest.php b/tests/Finland/NewYearsDayTest.php index 71c16aca5..f39819e55 100644 --- a/tests/Finland/NewYearsDayTest.php +++ b/tests/Finland/NewYearsDayTest.php @@ -16,7 +16,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -37,8 +36,6 @@ class NewYearsDayTest extends FinlandBaseTestCase implements HolidayTestCase * * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testHoliday(int $year, DateTime $expected): void { @@ -60,7 +57,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -75,7 +72,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Finland/PentecostTest.php b/tests/Finland/PentecostTest.php index dd67ed761..c3cb5edbd 100644 --- a/tests/Finland/PentecostTest.php +++ b/tests/Finland/PentecostTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -35,7 +34,6 @@ class PentecostTest extends FinlandBaseTestCase implements HolidayTestCase * Tests the holiday defined in this test. * * @throws Exception - * @throws ReflectionException */ public function testHoliday(): void { @@ -51,7 +49,7 @@ public function testHoliday(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -66,7 +64,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Finland/SecondChristmasDayTest.php b/tests/Finland/SecondChristmasDayTest.php index f64bf1e3c..34e0b5c71 100644 --- a/tests/Finland/SecondChristmasDayTest.php +++ b/tests/Finland/SecondChristmasDayTest.php @@ -16,7 +16,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -37,8 +36,6 @@ class SecondChristmasDayTest extends FinlandBaseTestCase implements HolidayTestC * * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testHoliday(int $year, DateTime $expected): void { @@ -60,7 +57,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -75,7 +72,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Finland/stJohnsDayTest.php b/tests/Finland/stJohnsDayTest.php index 207ea0e67..ca7a7fe0b 100644 --- a/tests/Finland/stJohnsDayTest.php +++ b/tests/Finland/stJohnsDayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; use Yasumi\Yasumi; @@ -44,7 +43,6 @@ class stJohnsDayTest extends FinlandBaseTestCase implements HolidayTestCase * Tests the holiday before it was adjusted. * * @throws Exception - * @throws ReflectionException */ public function testHolidayBeforeAdjustment(): void { @@ -60,7 +58,7 @@ public function testHolidayBeforeAdjustment(): void /** * Tests the holiday before it was adjusted. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayAfterAdjustment(): void { @@ -84,7 +82,7 @@ public function testHolidayAfterAdjustment(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -99,7 +97,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/France/AllSaintsDayTest.php b/tests/France/AllSaintsDayTest.php index 70d28516b..5ed7e9df7 100644 --- a/tests/France/AllSaintsDayTest.php +++ b/tests/France/AllSaintsDayTest.php @@ -16,7 +16,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -37,8 +36,6 @@ class AllSaintsDayTest extends FranceBaseTestCase implements HolidayTestCase * * @param int $year the year for which All Saints' Day needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testAllSaintsDay(int $year, DateTime $expected): void { @@ -48,7 +45,7 @@ public function testAllSaintsDay(int $year, DateTime $expected): void /** * Tests translated name of All Saints' Day. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -63,7 +60,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/France/ArmisticeDayTest.php b/tests/France/ArmisticeDayTest.php index d467049df..b9a44cebd 100644 --- a/tests/France/ArmisticeDayTest.php +++ b/tests/France/ArmisticeDayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -40,7 +39,6 @@ class ArmisticeDayTest extends FranceBaseTestCase implements HolidayTestCase * Tests Armistice Day on or after 1919. * * @throws Exception - * @throws ReflectionException */ public function testArmisticeDayOnAfter1919(): void { @@ -56,7 +54,7 @@ public function testArmisticeDayOnAfter1919(): void /** * Tests Armistice Day before 1919. * - * @throws ReflectionException + * @throws Exception */ public function testArmisticeDayBefore1919(): void { @@ -70,7 +68,7 @@ public function testArmisticeDayBefore1919(): void /** * Tests translated name of Armistice Day. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -85,7 +83,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/France/AscensionDayTest.php b/tests/France/AscensionDayTest.php index 484e1e18c..2d9b2d24a 100644 --- a/tests/France/AscensionDayTest.php +++ b/tests/France/AscensionDayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -35,7 +34,6 @@ class AscensionDayTest extends FranceBaseTestCase implements HolidayTestCase * Tests Ascension Day. * * @throws Exception - * @throws ReflectionException */ public function testAscensionDay(): void { @@ -51,7 +49,7 @@ public function testAscensionDay(): void /** * Tests translated name of Ascension Day. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -66,7 +64,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/France/AssumptionOfMaryTest.php b/tests/France/AssumptionOfMaryTest.php index 6448fd9da..b24757763 100644 --- a/tests/France/AssumptionOfMaryTest.php +++ b/tests/France/AssumptionOfMaryTest.php @@ -16,7 +16,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -37,8 +36,6 @@ class AssumptionOfMaryTest extends FranceBaseTestCase implements HolidayTestCase * * @param int $year the year for which the day of the Assumption of Mary needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testAssumptionOfMary(int $year, DateTime $expected): void { @@ -48,7 +45,7 @@ public function testAssumptionOfMary(int $year, DateTime $expected): void /** * Tests translated name of the day of the Assumption of Mary. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -63,7 +60,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/France/BasRhin/BasRhinTest.php b/tests/France/BasRhin/BasRhinTest.php index fe0242897..3d7733a62 100644 --- a/tests/France/BasRhin/BasRhinTest.php +++ b/tests/France/BasRhin/BasRhinTest.php @@ -30,6 +30,8 @@ class BasRhinTest extends BasRhinBaseTestCase implements ProviderTestCase /** * Initial setup of this Test Case. + * + * @throws \Exception */ protected function setUp(): void { @@ -38,8 +40,6 @@ protected function setUp(): void /** * Tests if all official holidays in Bas-Rhin are defined by the provider class. - * - * @throws ReflectionException */ public function testOfficialHolidays(): void { @@ -62,8 +62,6 @@ public function testOfficialHolidays(): void /** * Tests if all observed holidays in Bas-Rhin (France) are defined by the provider class. - * - * @throws ReflectionException */ public function testObservedHolidays(): void { @@ -72,8 +70,6 @@ public function testObservedHolidays(): void /** * Tests if all seasonal holidays in Bas-Rhin (France) are defined by the provider class. - * - * @throws ReflectionException */ public function testSeasonalHolidays(): void { @@ -82,8 +78,6 @@ public function testSeasonalHolidays(): void /** * Tests if all bank holidays in Bas-Rhin (France) are defined by the provider class. - * - * @throws ReflectionException */ public function testBankHolidays(): void { @@ -92,8 +86,6 @@ public function testBankHolidays(): void /** * Tests if all other holidays in Bas-Rhin (France) are defined by the provider class. - * - * @throws ReflectionException */ public function testOtherHolidays(): void { @@ -102,6 +94,7 @@ public function testOtherHolidays(): void /** * @throws ReflectionException + * @throws \Exception */ public function testSources(): void { diff --git a/tests/France/BasRhin/GoodFridayTest.php b/tests/France/BasRhin/GoodFridayTest.php index f4900022b..17b09c753 100644 --- a/tests/France/BasRhin/GoodFridayTest.php +++ b/tests/France/BasRhin/GoodFridayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -35,7 +34,6 @@ class GoodFridayTest extends BasRhinBaseTestCase implements HolidayTestCase * Tests the holiday defined in this test. * * @throws Exception - * @throws ReflectionException */ public function testHoliday(): void { @@ -51,7 +49,7 @@ public function testHoliday(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -66,7 +64,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/France/BasRhin/stStephensDayTest.php b/tests/France/BasRhin/stStephensDayTest.php index 0e1c09764..ea894a4dc 100644 --- a/tests/France/BasRhin/stStephensDayTest.php +++ b/tests/France/BasRhin/stStephensDayTest.php @@ -16,7 +16,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -37,8 +36,6 @@ class stStephensDayTest extends BasRhinBaseTestCase implements HolidayTestCase * * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testHoliday(int $year, DateTime $expected): void { @@ -60,7 +57,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -75,7 +72,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/France/BastilleDayTest.php b/tests/France/BastilleDayTest.php index 7e5904013..fda55e4e0 100644 --- a/tests/France/BastilleDayTest.php +++ b/tests/France/BastilleDayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -40,7 +39,6 @@ class BastilleDayTest extends FranceBaseTestCase implements HolidayTestCase * Tests Bastille Day on or after 1790. * * @throws Exception - * @throws ReflectionException */ public function testBastilleDayOnAfter1790(): void { @@ -56,7 +54,7 @@ public function testBastilleDayOnAfter1790(): void /** * Tests Bastille Day before 1790. * - * @throws ReflectionException + * @throws Exception */ public function testBastilleDayBefore1790(): void { @@ -70,7 +68,7 @@ public function testBastilleDayBefore1790(): void /** * Tests translated name of Bastille Day. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -85,7 +83,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/France/ChristmasDayTest.php b/tests/France/ChristmasDayTest.php index 93132590c..073605881 100644 --- a/tests/France/ChristmasDayTest.php +++ b/tests/France/ChristmasDayTest.php @@ -16,7 +16,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -37,8 +36,6 @@ class ChristmasDayTest extends FranceBaseTestCase implements HolidayTestCase * * @param int $year the year for which Christmas Day needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testChristmasDay(int $year, DateTime $expected): void { @@ -60,7 +57,7 @@ public function ChristmasDayDataProvider(): array /** * Tests translated name of Christmas Day. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -75,7 +72,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/France/EasterMondayTest.php b/tests/France/EasterMondayTest.php index 55a90cdf5..63b506330 100644 --- a/tests/France/EasterMondayTest.php +++ b/tests/France/EasterMondayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -35,7 +34,6 @@ class EasterMondayTest extends FranceBaseTestCase implements HolidayTestCase * Tests Easter Monday. * * @throws Exception - * @throws ReflectionException */ public function testEasterMonday(): void { @@ -51,7 +49,7 @@ public function testEasterMonday(): void /** * Tests translated name of Easter Monday. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -66,7 +64,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/France/FranceTest.php b/tests/France/FranceTest.php index 518a2bd3b..84228f7e7 100644 --- a/tests/France/FranceTest.php +++ b/tests/France/FranceTest.php @@ -30,6 +30,8 @@ class FranceTest extends FranceBaseTestCase implements ProviderTestCase /** * Initial setup of this Test Case. + * + * @throws \Exception */ protected function setUp(): void { @@ -38,8 +40,6 @@ protected function setUp(): void /** * Tests if all official holidays in France are defined by the provider class. - * - * @throws ReflectionException */ public function testOfficialHolidays(): void { @@ -60,8 +60,6 @@ public function testOfficialHolidays(): void /** * Tests if all observed holidays in France are defined by the provider class. - * - * @throws ReflectionException */ public function testObservedHolidays(): void { @@ -70,8 +68,6 @@ public function testObservedHolidays(): void /** * Tests if all seasonal holidays in France are defined by the provider class. - * - * @throws ReflectionException */ public function testSeasonalHolidays(): void { @@ -80,8 +76,6 @@ public function testSeasonalHolidays(): void /** * Tests if all bank holidays in France are defined by the provider class. - * - * @throws ReflectionException */ public function testBankHolidays(): void { @@ -90,8 +84,6 @@ public function testBankHolidays(): void /** * Tests if all other holidays in France are defined by the provider class. - * - * @throws ReflectionException */ public function testOtherHolidays(): void { @@ -100,6 +92,7 @@ public function testOtherHolidays(): void /** * @throws ReflectionException + * @throws \Exception */ public function testSources(): void { diff --git a/tests/France/HautRhin/GoodFridayTest.php b/tests/France/HautRhin/GoodFridayTest.php index 421e5c5dd..4e06aaeca 100644 --- a/tests/France/HautRhin/GoodFridayTest.php +++ b/tests/France/HautRhin/GoodFridayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -35,7 +34,6 @@ class GoodFridayTest extends HautRhinBaseTestCase implements HolidayTestCase * Tests the holiday defined in this test. * * @throws Exception - * @throws ReflectionException */ public function testHoliday(): void { @@ -51,7 +49,7 @@ public function testHoliday(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -66,7 +64,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/France/HautRhin/HautRhinTest.php b/tests/France/HautRhin/HautRhinTest.php index d7e3964bf..3bdefdaaa 100644 --- a/tests/France/HautRhin/HautRhinTest.php +++ b/tests/France/HautRhin/HautRhinTest.php @@ -30,6 +30,8 @@ class HautRhinTest extends HautRhinBaseTestCase implements ProviderTestCase /** * Initial setup of this Test Case. + * + * @throws \Exception */ protected function setUp(): void { @@ -38,8 +40,6 @@ protected function setUp(): void /** * Tests if all official holidays in Haut-Rhin are defined by the provider class. - * - * @throws ReflectionException */ public function testOfficialHolidays(): void { @@ -62,8 +62,6 @@ public function testOfficialHolidays(): void /** * Tests if all observed holidays in Haut-Rhin (France) are defined by the provider class. - * - * @throws ReflectionException */ public function testObservedHolidays(): void { @@ -72,8 +70,6 @@ public function testObservedHolidays(): void /** * Tests if all seasonal holidays in Haut-Rhin (France) are defined by the provider class. - * - * @throws ReflectionException */ public function testSeasonalHolidays(): void { @@ -82,8 +78,6 @@ public function testSeasonalHolidays(): void /** * Tests if all bank holidays in Haut-Rhin (France) are defined by the provider class. - * - * @throws ReflectionException */ public function testBankHolidays(): void { @@ -92,8 +86,6 @@ public function testBankHolidays(): void /** * Tests if all other holidays in Haut-Rhin (France) are defined by the provider class. - * - * @throws ReflectionException */ public function testOtherHolidays(): void { @@ -102,6 +94,7 @@ public function testOtherHolidays(): void /** * @throws ReflectionException + * @throws \Exception */ public function testSources(): void { diff --git a/tests/France/HautRhin/stStephensDayTest.php b/tests/France/HautRhin/stStephensDayTest.php index 76a82e6c8..ea428f6f9 100644 --- a/tests/France/HautRhin/stStephensDayTest.php +++ b/tests/France/HautRhin/stStephensDayTest.php @@ -16,7 +16,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -37,8 +36,6 @@ class stStephensDayTest extends HautRhinBaseTestCase implements HolidayTestCase * * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testHoliday(int $year, DateTime $expected): void { @@ -60,7 +57,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -75,7 +72,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/France/InternationalWorkersDayTest.php b/tests/France/InternationalWorkersDayTest.php index bd94a58ea..d04950b96 100644 --- a/tests/France/InternationalWorkersDayTest.php +++ b/tests/France/InternationalWorkersDayTest.php @@ -16,7 +16,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -37,8 +36,6 @@ class InternationalWorkersDayTest extends FranceBaseTestCase implements HolidayT * * @param int $year the year for which International Workers' Day needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testInternationalWorkersDay(int $year, DateTime $expected): void { @@ -48,7 +45,7 @@ public function testInternationalWorkersDay(int $year, DateTime $expected): void /** * Tests translated name of International Workers' Day. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -63,7 +60,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/France/Moselle/GoodFridayTest.php b/tests/France/Moselle/GoodFridayTest.php index a39f5025b..05c2cb6cd 100644 --- a/tests/France/Moselle/GoodFridayTest.php +++ b/tests/France/Moselle/GoodFridayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -35,7 +34,6 @@ class GoodFridayTest extends MoselleBaseTestCase implements HolidayTestCase * Tests the holiday defined in this test. * * @throws Exception - * @throws ReflectionException */ public function testHoliday(): void { @@ -51,7 +49,7 @@ public function testHoliday(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -66,7 +64,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/France/Moselle/MoselleTest.php b/tests/France/Moselle/MoselleTest.php index 71842d52c..8a097222c 100644 --- a/tests/France/Moselle/MoselleTest.php +++ b/tests/France/Moselle/MoselleTest.php @@ -30,6 +30,8 @@ class MoselleTest extends MoselleBaseTestCase implements ProviderTestCase /** * Initial setup of this Test Case. + * + * @throws \Exception */ protected function setUp(): void { @@ -38,8 +40,6 @@ protected function setUp(): void /** * Tests if all official holidays in Moselle are defined by the provider class. - * - * @throws ReflectionException */ public function testOfficialHolidays(): void { @@ -62,8 +62,6 @@ public function testOfficialHolidays(): void /** * Tests if all observed holidays in Moselle (France) are defined by the provider class. - * - * @throws ReflectionException */ public function testObservedHolidays(): void { @@ -72,8 +70,6 @@ public function testObservedHolidays(): void /** * Tests if all seasonal holidays in Moselle (France) are defined by the provider class. - * - * @throws ReflectionException */ public function testSeasonalHolidays(): void { @@ -82,8 +78,6 @@ public function testSeasonalHolidays(): void /** * Tests if all bank holidays in Moselle (France) are defined by the provider class. - * - * @throws ReflectionException */ public function testBankHolidays(): void { @@ -92,8 +86,6 @@ public function testBankHolidays(): void /** * Tests if all other holidays in Moselle (France) are defined by the provider class. - * - * @throws ReflectionException */ public function testOtherHolidays(): void { @@ -102,6 +94,7 @@ public function testOtherHolidays(): void /** * @throws ReflectionException + * @throws \Exception */ public function testSources(): void { diff --git a/tests/France/Moselle/stStephensDayTest.php b/tests/France/Moselle/stStephensDayTest.php index 559020362..0ee3ec544 100644 --- a/tests/France/Moselle/stStephensDayTest.php +++ b/tests/France/Moselle/stStephensDayTest.php @@ -16,7 +16,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -37,8 +36,6 @@ class stStephensDayTest extends MoselleBaseTestCase implements HolidayTestCase * * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testHoliday(int $year, DateTime $expected): void { @@ -60,7 +57,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -75,7 +72,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/France/NewYearsDayTest.php b/tests/France/NewYearsDayTest.php index d87bb62f5..e4fa8176f 100644 --- a/tests/France/NewYearsDayTest.php +++ b/tests/France/NewYearsDayTest.php @@ -16,7 +16,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -37,8 +36,6 @@ class NewYearsDayTest extends FranceBaseTestCase implements HolidayTestCase * * @param int $year the year for which New Years Day needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testNewYearsDay(int $year, DateTime $expected): void { @@ -48,7 +45,7 @@ public function testNewYearsDay(int $year, DateTime $expected): void /** * Tests translated name of New Years Day. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -63,7 +60,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/France/PentecostMondayTest.php b/tests/France/PentecostMondayTest.php index c422a82e0..789b0316e 100644 --- a/tests/France/PentecostMondayTest.php +++ b/tests/France/PentecostMondayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -35,7 +34,6 @@ class PentecostMondayTest extends FranceBaseTestCase implements HolidayTestCase * Tests Pentecost Monday. * * @throws Exception - * @throws ReflectionException */ public function testPentecostMonday(): void { @@ -51,7 +49,7 @@ public function testPentecostMonday(): void /** * Tests translated name of Pentecost Monday. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -66,7 +64,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/France/VictoryInEuropeDayTest.php b/tests/France/VictoryInEuropeDayTest.php index 7d5359a43..3b1dc75b1 100644 --- a/tests/France/VictoryInEuropeDayTest.php +++ b/tests/France/VictoryInEuropeDayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -40,7 +39,6 @@ class VictoryInEuropeDayTest extends FranceBaseTestCase implements HolidayTestCa * Tests Victory In Europe Day on or after 1945. * * @throws Exception - * @throws ReflectionException */ public function testVictoryInEuropeDayOnAfter1945(): void { @@ -56,7 +54,7 @@ public function testVictoryInEuropeDayOnAfter1945(): void /** * Tests Victory In Europe Day before 1945. * - * @throws ReflectionException + * @throws Exception */ public function testVictoryInEuropeDayBefore1945(): void { @@ -70,7 +68,7 @@ public function testVictoryInEuropeDayBefore1945(): void /** * Tests translated name of Victory in Europe Day. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -85,7 +83,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Georgia/EasterTest.php b/tests/Georgia/EasterTest.php index 8a2801be8..d2207f46c 100644 --- a/tests/Georgia/EasterTest.php +++ b/tests/Georgia/EasterTest.php @@ -7,7 +7,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -22,7 +21,6 @@ class EasterTest extends GeorgiaBaseTestCase implements HolidayTestCase * Tests the holiday defined in this test. * * @throws Exception - * @throws ReflectionException */ public function testHoliday(): void { @@ -39,7 +37,7 @@ public function testHoliday(): void /** * Tests translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -54,7 +52,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Georgia/GeorgiaTest.php b/tests/Georgia/GeorgiaTest.php index d86642c37..c135e9b52 100644 --- a/tests/Georgia/GeorgiaTest.php +++ b/tests/Georgia/GeorgiaTest.php @@ -34,6 +34,8 @@ class GeorgiaTest extends GeorgiaBaseTestCase implements ProviderTestCase /** * Initial setup of this Test Case. + * + * @throws \Exception */ protected function setUp(): void { @@ -42,8 +44,6 @@ protected function setUp(): void /** * Tests if all official holidays in Georgia are defined by the provider class. - * - * @throws ReflectionException */ public function testOfficialHolidays(): void { @@ -74,8 +74,6 @@ public function testOfficialHolidays(): void /** * Tests if all observed holidays in Georgia are defined by the provider class. - * - * @throws ReflectionException */ public function testObservedHolidays(): void { @@ -84,8 +82,6 @@ public function testObservedHolidays(): void /** * Tests if all seasonal holidays in Georgia are defined by the provider class. - * - * @throws ReflectionException */ public function testSeasonalHolidays(): void { @@ -94,8 +90,6 @@ public function testSeasonalHolidays(): void /** * Tests if all bank holidays in Georgia are defined by the provider class. - * - * @throws ReflectionException */ public function testBankHolidays(): void { @@ -104,8 +98,6 @@ public function testBankHolidays(): void /** * Tests if all other holidays in Georgia are defined by the provider class. - * - * @throws ReflectionException */ public function testOtherHolidays(): void { @@ -114,6 +106,7 @@ public function testOtherHolidays(): void /** * @throws ReflectionException + * @throws \Exception */ public function testSources(): void { diff --git a/tests/Georgia/IndependenceDayTest.php b/tests/Georgia/IndependenceDayTest.php index 79b53ed0b..90afd51f2 100644 --- a/tests/Georgia/IndependenceDayTest.php +++ b/tests/Georgia/IndependenceDayTest.php @@ -18,7 +18,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -30,7 +29,6 @@ class IndependenceDayTest extends GeorgiaBaseTestCase implements HolidayTestCase public const HOLIDAY = 'independenceDay'; /** - * @throws ReflectionException * @throws Exception */ public function testHoliday(): void @@ -46,8 +44,6 @@ public function testHoliday(): void /** * Tests the translated name of the holiday defined in this test. - * - * @throws ReflectionException */ public function testTranslation(): void { @@ -63,8 +59,6 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. - * - * @throws ReflectionException */ public function testHolidayType(): void { diff --git a/tests/Georgia/InternationalWomensDayTest.php b/tests/Georgia/InternationalWomensDayTest.php index 43edbaf15..c1a8eca7c 100644 --- a/tests/Georgia/InternationalWomensDayTest.php +++ b/tests/Georgia/InternationalWomensDayTest.php @@ -17,7 +17,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -30,8 +29,6 @@ class InternationalWomensDayTest extends GeorgiaBaseTestCase implements HolidayT /** * @dataProvider HolidayDataProvider - * - * @throws ReflectionException */ public function testHoliday(int $year, DateTime $expected): void { @@ -53,7 +50,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -68,7 +65,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Georgia/MtskhetobaDayTest.php b/tests/Georgia/MtskhetobaDayTest.php index 76e9ea612..a1be83ad6 100644 --- a/tests/Georgia/MtskhetobaDayTest.php +++ b/tests/Georgia/MtskhetobaDayTest.php @@ -17,7 +17,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -30,8 +29,6 @@ class MtskhetobaDayTest extends GeorgiaBaseTestCase implements HolidayTestCase /** * @dataProvider HolidayDataProvider - * - * @throws ReflectionException */ public function testHoliday(int $year, DateTime $expected): void { @@ -53,7 +50,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -68,7 +65,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Georgia/NewYearsDayTest.php b/tests/Georgia/NewYearsDayTest.php index 601ea55d7..f76898cec 100644 --- a/tests/Georgia/NewYearsDayTest.php +++ b/tests/Georgia/NewYearsDayTest.php @@ -17,7 +17,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -30,8 +29,6 @@ class NewYearsDayTest extends GeorgiaBaseTestCase implements HolidayTestCase /** * @dataProvider HolidayDataProvider - * - * @throws ReflectionException */ public function testHoliday(int $year, DateTime $expected): void { @@ -53,7 +50,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -68,7 +65,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Georgia/OrthodoxChristmasDayTest.php b/tests/Georgia/OrthodoxChristmasDayTest.php index 4cfc569b7..e6356a5bb 100644 --- a/tests/Georgia/OrthodoxChristmasDayTest.php +++ b/tests/Georgia/OrthodoxChristmasDayTest.php @@ -17,7 +17,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -30,8 +29,6 @@ class OrthodoxChristmasDayTest extends GeorgiaBaseTestCase implements HolidayTes /** * @dataProvider HolidayDataProvider - * - * @throws ReflectionException */ public function testHoliday(int $year, DateTime $expected): void { @@ -53,7 +50,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -68,7 +65,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Georgia/OrthodoxEpiphanyDayTest.php b/tests/Georgia/OrthodoxEpiphanyDayTest.php index 022aa469d..aae496458 100644 --- a/tests/Georgia/OrthodoxEpiphanyDayTest.php +++ b/tests/Georgia/OrthodoxEpiphanyDayTest.php @@ -17,7 +17,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -30,8 +29,6 @@ class OrthodoxEpiphanyDayTest extends GeorgiaBaseTestCase implements HolidayTest /** * @dataProvider HolidayDataProvider - * - * @throws ReflectionException */ public function testHoliday(int $year, DateTime $expected): void { @@ -53,7 +50,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -68,7 +65,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Georgia/SecondNewYearDayTest.php b/tests/Georgia/SecondNewYearDayTest.php index c5aaf49c5..0c3a34100 100644 --- a/tests/Georgia/SecondNewYearDayTest.php +++ b/tests/Georgia/SecondNewYearDayTest.php @@ -17,7 +17,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -30,8 +29,6 @@ class SecondNewYearDayTest extends GeorgiaBaseTestCase implements HolidayTestCas /** * @dataProvider HolidayDataProvider - * - * @throws ReflectionException */ public function testHoliday(int $year, DateTime $expected): void { @@ -53,7 +50,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -68,7 +65,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Georgia/StAndrewsDayTest.php b/tests/Georgia/StAndrewsDayTest.php index 44c3c3521..0e6d3c404 100644 --- a/tests/Georgia/StAndrewsDayTest.php +++ b/tests/Georgia/StAndrewsDayTest.php @@ -17,7 +17,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -30,8 +29,6 @@ class StAndrewsDayTest extends GeorgiaBaseTestCase implements HolidayTestCase /** * @dataProvider HolidayDataProvider - * - * @throws ReflectionException */ public function testHoliday(int $year, DateTime $expected): void { @@ -53,7 +50,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -68,7 +65,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Georgia/StGeorgesDayTest.php b/tests/Georgia/StGeorgesDayTest.php index eb5529115..be8f8b8ed 100644 --- a/tests/Georgia/StGeorgesDayTest.php +++ b/tests/Georgia/StGeorgesDayTest.php @@ -17,7 +17,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -30,8 +29,6 @@ class StGeorgesDayTest extends GeorgiaBaseTestCase implements HolidayTestCase /** * @dataProvider HolidayDataProvider - * - * @throws ReflectionException */ public function testHoliday(int $year, DateTime $expected): void { @@ -53,7 +50,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -68,7 +65,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Georgia/StMarysDayTest.php b/tests/Georgia/StMarysDayTest.php index 77f7c3ee9..78a4b9d40 100644 --- a/tests/Georgia/StMarysDayTest.php +++ b/tests/Georgia/StMarysDayTest.php @@ -17,7 +17,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -30,8 +29,6 @@ class StMarysDayTest extends GeorgiaBaseTestCase implements HolidayTestCase /** * @dataProvider HolidayDataProvider - * - * @throws ReflectionException */ public function testHoliday(int $year, DateTime $expected): void { @@ -53,7 +50,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -68,7 +65,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Georgia/UnityDayTest.php b/tests/Georgia/UnityDayTest.php index 0b3492da3..c0a9724de 100644 --- a/tests/Georgia/UnityDayTest.php +++ b/tests/Georgia/UnityDayTest.php @@ -18,7 +18,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -30,7 +29,6 @@ class UnityDayTest extends GeorgiaBaseTestCase implements HolidayTestCase public const HOLIDAY = 'unityDay'; /** - * @throws ReflectionException * @throws Exception */ public function testHoliday(): void @@ -46,8 +44,6 @@ public function testHoliday(): void /** * Tests the translated name of the holiday defined in this test. - * - * @throws ReflectionException */ public function testTranslation(): void { @@ -63,8 +59,6 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. - * - * @throws ReflectionException */ public function testHolidayType(): void { diff --git a/tests/Georgia/VictoryDayTest.php b/tests/Georgia/VictoryDayTest.php index 12d8822d0..700a8872c 100644 --- a/tests/Georgia/VictoryDayTest.php +++ b/tests/Georgia/VictoryDayTest.php @@ -17,7 +17,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -30,8 +29,6 @@ class VictoryDayTest extends GeorgiaBaseTestCase implements HolidayTestCase /** * @dataProvider HolidayDataProvider - * - * @throws ReflectionException */ public function testHoliday(int $year, DateTime $expected): void { @@ -53,7 +50,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -68,7 +65,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Germany/AscensionDayTest.php b/tests/Germany/AscensionDayTest.php index a3950edc5..9b6fb6f42 100644 --- a/tests/Germany/AscensionDayTest.php +++ b/tests/Germany/AscensionDayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -35,7 +34,6 @@ class AscensionDayTest extends GermanyBaseTestCase implements HolidayTestCase * Tests Ascension Day. * * @throws Exception - * @throws ReflectionException */ public function testAscensionDay(): void { @@ -51,7 +49,7 @@ public function testAscensionDay(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -66,7 +64,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Germany/BadenWurttemberg/AllSaintsDayTest.php b/tests/Germany/BadenWurttemberg/AllSaintsDayTest.php index 1def6b656..a1d7cf32b 100644 --- a/tests/Germany/BadenWurttemberg/AllSaintsDayTest.php +++ b/tests/Germany/BadenWurttemberg/AllSaintsDayTest.php @@ -16,7 +16,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -37,8 +36,6 @@ class AllSaintsDayTest extends BadenWurttembergBaseTestCase implements HolidayTe * * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testHoliday(int $year, DateTime $expected): void { @@ -60,7 +57,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -75,7 +72,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Germany/BadenWurttemberg/BadenWurttembergTest.php b/tests/Germany/BadenWurttemberg/BadenWurttembergTest.php index c409c9c17..d3c13b388 100644 --- a/tests/Germany/BadenWurttemberg/BadenWurttembergTest.php +++ b/tests/Germany/BadenWurttemberg/BadenWurttembergTest.php @@ -30,6 +30,8 @@ class BadenWurttembergTest extends BadenWurttembergBaseTestCase implements Provi /** * Initial setup of this Test Case. + * + * @throws \Exception */ protected function setUp(): void { @@ -38,8 +40,6 @@ protected function setUp(): void /** * Tests if all official holidays in Baden-Württemberg (Germany) are defined by the provider class. - * - * @throws ReflectionException */ public function testOfficialHolidays(): void { @@ -60,8 +60,6 @@ public function testOfficialHolidays(): void /** * Tests if all observed holidays in Baden-Württemberg (Germany) are defined by the provider class. - * - * @throws ReflectionException */ public function testObservedHolidays(): void { @@ -70,8 +68,6 @@ public function testObservedHolidays(): void /** * Tests if all seasonal holidays in Baden-Württemberg (Germany) are defined by the provider class. - * - * @throws ReflectionException */ public function testSeasonalHolidays(): void { @@ -80,8 +76,6 @@ public function testSeasonalHolidays(): void /** * Tests if all bank holidays in Baden-Württemberg (Germany) are defined by the provider class. - * - * @throws ReflectionException */ public function testBankHolidays(): void { @@ -90,8 +84,6 @@ public function testBankHolidays(): void /** * Tests if all other holidays in Baden-Württemberg (Germany) are defined by the provider class. - * - * @throws ReflectionException */ public function testOtherHolidays(): void { @@ -105,6 +97,7 @@ public function testOtherHolidays(): void /** * @throws ReflectionException + * @throws \Exception */ public function testSources(): void { diff --git a/tests/Germany/BadenWurttemberg/CorpusChristiTest.php b/tests/Germany/BadenWurttemberg/CorpusChristiTest.php index 8b17388f3..b82749505 100644 --- a/tests/Germany/BadenWurttemberg/CorpusChristiTest.php +++ b/tests/Germany/BadenWurttemberg/CorpusChristiTest.php @@ -15,7 +15,6 @@ namespace Yasumi\tests\Germany\BadenWurttemberg; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -33,7 +32,6 @@ class CorpusChristiTest extends BadenWurttembergBaseTestCase implements HolidayT * Tests the holiday defined in this test. * * @throws Exception - * @throws ReflectionException */ public function testHoliday(): void { @@ -50,7 +48,7 @@ public function testHoliday(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -65,7 +63,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Germany/BadenWurttemberg/EpiphanyTest.php b/tests/Germany/BadenWurttemberg/EpiphanyTest.php index b9d418ddf..9d0e5eaba 100644 --- a/tests/Germany/BadenWurttemberg/EpiphanyTest.php +++ b/tests/Germany/BadenWurttemberg/EpiphanyTest.php @@ -16,7 +16,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -37,8 +36,6 @@ class EpiphanyTest extends BadenWurttembergBaseTestCase implements HolidayTestCa * * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testHoliday(int $year, DateTime $expected): void { @@ -60,7 +57,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -75,7 +72,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Germany/Bavaria/AllSaintsDayTest.php b/tests/Germany/Bavaria/AllSaintsDayTest.php index d5caef2c0..7bb9bef2e 100644 --- a/tests/Germany/Bavaria/AllSaintsDayTest.php +++ b/tests/Germany/Bavaria/AllSaintsDayTest.php @@ -16,7 +16,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -37,8 +36,6 @@ class AllSaintsDayTest extends BavariaBaseTestCase implements HolidayTestCase * * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testHoliday(int $year, DateTime $expected): void { @@ -60,7 +57,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -75,7 +72,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Germany/Bavaria/BavariaTest.php b/tests/Germany/Bavaria/BavariaTest.php index d9dbe3947..08e7069d6 100644 --- a/tests/Germany/Bavaria/BavariaTest.php +++ b/tests/Germany/Bavaria/BavariaTest.php @@ -30,6 +30,8 @@ class BavariaTest extends BavariaBaseTestCase implements ProviderTestCase /** * Initial setup of this Test Case. + * + * @throws \Exception */ protected function setUp(): void { @@ -38,8 +40,6 @@ protected function setUp(): void /** * Tests if all official holidays in Bavaria (Germany) are defined by the provider class. - * - * @throws ReflectionException */ public function testOfficialHolidays(): void { @@ -60,8 +60,6 @@ public function testOfficialHolidays(): void /** * Tests if all observed holidays in Bavaria (Germany) are defined by the provider class. - * - * @throws ReflectionException */ public function testObservedHolidays(): void { @@ -70,8 +68,6 @@ public function testObservedHolidays(): void /** * Tests if all seasonal holidays in Bavaria (Germany) are defined by the provider class. - * - * @throws ReflectionException */ public function testSeasonalHolidays(): void { @@ -80,8 +76,6 @@ public function testSeasonalHolidays(): void /** * Tests if all bank holidays in Bavaria (Germany) are defined by the provider class. - * - * @throws ReflectionException */ public function testBankHolidays(): void { @@ -90,8 +84,6 @@ public function testBankHolidays(): void /** * Tests if all other holidays in Bavaria (Germany) are defined by the provider class. - * - * @throws ReflectionException */ public function testOtherHolidays(): void { @@ -105,6 +97,7 @@ public function testOtherHolidays(): void /** * @throws ReflectionException + * @throws \Exception */ public function testSources(): void { diff --git a/tests/Germany/Bavaria/CorpusChristiTest.php b/tests/Germany/Bavaria/CorpusChristiTest.php index b806ff93c..bb41077a0 100644 --- a/tests/Germany/Bavaria/CorpusChristiTest.php +++ b/tests/Germany/Bavaria/CorpusChristiTest.php @@ -15,7 +15,6 @@ namespace Yasumi\tests\Germany\Bavaria; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -33,7 +32,6 @@ class CorpusChristiTest extends BavariaBaseTestCase implements HolidayTestCase * Tests the holiday defined in this test. * * @throws Exception - * @throws ReflectionException */ public function testHoliday(): void { @@ -50,7 +48,7 @@ public function testHoliday(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -65,7 +63,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Germany/Bavaria/EpiphanyTest.php b/tests/Germany/Bavaria/EpiphanyTest.php index 997e250d5..99d5c8a22 100644 --- a/tests/Germany/Bavaria/EpiphanyTest.php +++ b/tests/Germany/Bavaria/EpiphanyTest.php @@ -16,7 +16,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -37,8 +36,6 @@ class EpiphanyTest extends BavariaBaseTestCase implements HolidayTestCase * * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testHoliday(int $year, DateTime $expected): void { @@ -60,7 +57,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -75,7 +72,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Germany/Berlin/BerlinTest.php b/tests/Germany/Berlin/BerlinTest.php index fa551e4ec..63cfd5473 100644 --- a/tests/Germany/Berlin/BerlinTest.php +++ b/tests/Germany/Berlin/BerlinTest.php @@ -30,6 +30,8 @@ class BerlinTest extends BerlinBaseTestCase implements ProviderTestCase /** * Initial setup of this Test Case. + * + * @throws \Exception */ protected function setUp(): void { @@ -38,8 +40,6 @@ protected function setUp(): void /** * Tests if all official holidays in Berlin (Germany) are defined by the provider class. - * - * @throws ReflectionException */ public function testOfficialHolidays(): void { @@ -58,8 +58,6 @@ public function testOfficialHolidays(): void /** * Tests if all observed holidays in Berlin (Germany) are defined by the provider class. - * - * @throws ReflectionException */ public function testObservedHolidays(): void { @@ -68,8 +66,6 @@ public function testObservedHolidays(): void /** * Tests if all seasonal holidays in Berlin (Germany) are defined by the provider class. - * - * @throws ReflectionException */ public function testSeasonalHolidays(): void { @@ -78,8 +74,6 @@ public function testSeasonalHolidays(): void /** * Tests if all bank holidays in Berlin (Germany) are defined by the provider class. - * - * @throws ReflectionException */ public function testBankHolidays(): void { @@ -88,8 +82,6 @@ public function testBankHolidays(): void /** * Tests if all other holidays in Berlin (Germany) are defined by the provider class. - * - * @throws ReflectionException */ public function testOtherHolidays(): void { @@ -98,6 +90,7 @@ public function testOtherHolidays(): void /** * @throws ReflectionException + * @throws \Exception */ public function testSources(): void { diff --git a/tests/Germany/Berlin/DayOfLiberation2020Test.php b/tests/Germany/Berlin/DayOfLiberation2020Test.php index 75c724390..ca001dccc 100644 --- a/tests/Germany/Berlin/DayOfLiberation2020Test.php +++ b/tests/Germany/Berlin/DayOfLiberation2020Test.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -40,7 +39,6 @@ class DayOfLiberation2020Test extends BerlinBaseTestCase implements HolidayTestC * Test the holiday defined in this test. * * @throws Exception - * @throws ReflectionException */ public function testHolidayInYear(): void { @@ -55,7 +53,7 @@ public function testHolidayInYear(): void /** * Test the holiday defined in this test in the years before. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayBeforeYear(): void { @@ -69,7 +67,7 @@ public function testHolidayBeforeYear(): void /** * Test the holiday defined in this test in the years after. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayAfterYear(): void { @@ -82,8 +80,6 @@ public function testHolidayAfterYear(): void /** * Tests the translated name of the holiday defined in this test. - * - * @throws ReflectionException */ public function testTranslation(): void { @@ -97,8 +93,6 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. - * - * @throws ReflectionException */ public function testHolidayType(): void { diff --git a/tests/Germany/Berlin/InternationalWomensDay2019Test.php b/tests/Germany/Berlin/InternationalWomensDay2019Test.php index d339363e0..7b90c41b0 100644 --- a/tests/Germany/Berlin/InternationalWomensDay2019Test.php +++ b/tests/Germany/Berlin/InternationalWomensDay2019Test.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -40,7 +39,6 @@ class InternationalWomensDay2019Test extends BerlinBaseTestCase implements Holid * Test the holiday defined in this test upon establishment. * * @throws Exception - * @throws ReflectionException */ public function testHolidayOnEstablishment(): void { @@ -55,7 +53,7 @@ public function testHolidayOnEstablishment(): void /** * Test the holiday defined in this test before establishment. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayBeforeEstablishment(): void { @@ -69,7 +67,7 @@ public function testHolidayBeforeEstablishment(): void /** * Test the holiday defined in this test after completion. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayAfterCompletion(): void { @@ -79,7 +77,7 @@ public function testHolidayAfterCompletion(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -94,7 +92,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Germany/Brandenburg/BrandenburgTest.php b/tests/Germany/Brandenburg/BrandenburgTest.php index 3fda8a19d..080281e13 100644 --- a/tests/Germany/Brandenburg/BrandenburgTest.php +++ b/tests/Germany/Brandenburg/BrandenburgTest.php @@ -30,6 +30,8 @@ class BrandenburgTest extends BrandenburgBaseTestCase implements ProviderTestCas /** * Initial setup of this Test Case. + * + * @throws \Exception */ protected function setUp(): void { @@ -38,8 +40,6 @@ protected function setUp(): void /** * Tests if all official holidays in Brandenburg (Germany) are defined by the provider class. - * - * @throws ReflectionException */ public function testOfficialHolidays(): void { @@ -69,8 +69,6 @@ public function testOfficialHolidays(): void /** * Tests if all observed holidays in Brandenburg (Germany) are defined by the provider class. - * - * @throws ReflectionException */ public function testObservedHolidays(): void { @@ -79,8 +77,6 @@ public function testObservedHolidays(): void /** * Tests if all seasonal holidays in Brandenburg (Germany) are defined by the provider class. - * - * @throws ReflectionException */ public function testSeasonalHolidays(): void { @@ -89,8 +85,6 @@ public function testSeasonalHolidays(): void /** * Tests if all bank holidays in Brandenburg (Germany) are defined by the provider class. - * - * @throws ReflectionException */ public function testBankHolidays(): void { @@ -99,8 +93,6 @@ public function testBankHolidays(): void /** * Tests if all other holidays in Brandenburg (Germany) are defined by the provider class. - * - * @throws ReflectionException */ public function testOtherHolidays(): void { @@ -109,6 +101,7 @@ public function testOtherHolidays(): void /** * @throws ReflectionException + * @throws \Exception */ public function testSources(): void { diff --git a/tests/Germany/Brandenburg/ReformationDayTest.php b/tests/Germany/Brandenburg/ReformationDayTest.php index 50736d85c..e9f6072a2 100644 --- a/tests/Germany/Brandenburg/ReformationDayTest.php +++ b/tests/Germany/Brandenburg/ReformationDayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -43,8 +42,6 @@ class ReformationDayTest extends BrandenburgBaseTestCase implements HolidayTestC * * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testHoliday(int $year, DateTime $expected): void { @@ -73,7 +70,7 @@ public function HolidayDataProvider(): array /** * Tests the holiday defined in this test before establishment. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayBeforeEstablishment(): void { @@ -87,7 +84,7 @@ public function testHolidayBeforeEstablishment(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -102,7 +99,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Germany/Bremen/BremenTest.php b/tests/Germany/Bremen/BremenTest.php index 49ae20575..e5f3472b9 100644 --- a/tests/Germany/Bremen/BremenTest.php +++ b/tests/Germany/Bremen/BremenTest.php @@ -30,6 +30,8 @@ class BremenTest extends BremenBaseTestCase implements ProviderTestCase /** * Initial setup of this Test Case. + * + * @throws \Exception */ protected function setUp(): void { @@ -38,8 +40,6 @@ protected function setUp(): void /** * Tests if all official holidays in Bremen (Germany) are defined by the provider class. - * - * @throws ReflectionException */ public function testOfficialHolidays(): void { @@ -58,8 +58,6 @@ public function testOfficialHolidays(): void /** * Tests if all observed holidays in Bremen (Germany) are defined by the provider class. - * - * @throws ReflectionException */ public function testObservedHolidays(): void { @@ -68,8 +66,6 @@ public function testObservedHolidays(): void /** * Tests if all seasonal holidays in Bremen (Germany) are defined by the provider class. - * - * @throws ReflectionException */ public function testSeasonalHolidays(): void { @@ -78,8 +74,6 @@ public function testSeasonalHolidays(): void /** * Tests if all bank holidays in Bremen (Germany) are defined by the provider class. - * - * @throws ReflectionException */ public function testBankHolidays(): void { @@ -88,8 +82,6 @@ public function testBankHolidays(): void /** * Tests if all other holidays in Bremen (Germany) are defined by the provider class. - * - * @throws ReflectionException */ public function testOtherHolidays(): void { @@ -98,6 +90,7 @@ public function testOtherHolidays(): void /** * @throws ReflectionException + * @throws \Exception */ public function testSources(): void { diff --git a/tests/Germany/Bremen/ReformationDayTest.php b/tests/Germany/Bremen/ReformationDayTest.php index 9a399fade..6ab7107cf 100644 --- a/tests/Germany/Bremen/ReformationDayTest.php +++ b/tests/Germany/Bremen/ReformationDayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -43,8 +42,6 @@ class ReformationDayTest extends BremenBaseTestCase implements HolidayTestCase * * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testHoliday(int $year, DateTime $expected): void { @@ -73,7 +70,7 @@ public function HolidayDataProvider(): array /** * Tests the holiday defined in this test before establishment. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayBeforeEstablishment(): void { @@ -87,7 +84,7 @@ public function testHolidayBeforeEstablishment(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -102,7 +99,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Germany/ChristmasTest.php b/tests/Germany/ChristmasTest.php index dd4da91cb..157327f86 100644 --- a/tests/Germany/ChristmasTest.php +++ b/tests/Germany/ChristmasTest.php @@ -16,7 +16,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -37,8 +36,6 @@ class ChristmasTest extends GermanyBaseTestCase implements HolidayTestCase * * @param int $year the year for which Christmas Day needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testChristmasDay(int $year, DateTime $expected): void { @@ -60,7 +57,7 @@ public function HolidayDataProvider(): array /** * Tests translated name of Christmas Day. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -75,7 +72,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Germany/EasterMondayTest.php b/tests/Germany/EasterMondayTest.php index 745eed5ee..4bbe6c792 100644 --- a/tests/Germany/EasterMondayTest.php +++ b/tests/Germany/EasterMondayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -35,7 +34,6 @@ class EasterMondayTest extends GermanyBaseTestCase implements HolidayTestCase * Tests the holiday defined in this test. * * @throws Exception - * @throws ReflectionException */ public function testHoliday(): void { @@ -51,7 +49,7 @@ public function testHoliday(): void /** * Tests translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -66,7 +64,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Germany/GermanUnityDayTest.php b/tests/Germany/GermanUnityDayTest.php index 26633b7eb..1dcae3c36 100644 --- a/tests/Germany/GermanUnityDayTest.php +++ b/tests/Germany/GermanUnityDayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -40,7 +39,6 @@ class GermanUnityDayTest extends GermanyBaseTestCase implements HolidayTestCase * Tests the holiday defined in this test on or after establishment. * * @throws Exception - * @throws ReflectionException */ public function testHolidayOnAfterEstablishment(): void { @@ -56,7 +54,7 @@ public function testHolidayOnAfterEstablishment(): void /** * Tests the holiday defined in this test before establishment. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayBeforeEstablishment(): void { @@ -70,7 +68,7 @@ public function testHolidayBeforeEstablishment(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -85,7 +83,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Germany/GermanyTest.php b/tests/Germany/GermanyTest.php index 6c0fde0ba..ce8cc9c1c 100644 --- a/tests/Germany/GermanyTest.php +++ b/tests/Germany/GermanyTest.php @@ -30,6 +30,8 @@ class GermanyTest extends GermanyBaseTestCase implements ProviderTestCase /** * Initial setup of this Test Case. + * + * @throws \Exception */ protected function setUp(): void { @@ -38,8 +40,6 @@ protected function setUp(): void /** * Tests if all official holidays in Finland are defined by the provider class. - * - * @throws ReflectionException */ public function testOfficialHolidays(): void { @@ -58,8 +58,6 @@ public function testOfficialHolidays(): void /** * Tests if all observed holidays in Germany are defined by the provider class. - * - * @throws ReflectionException */ public function testObservedHolidays(): void { @@ -68,8 +66,6 @@ public function testObservedHolidays(): void /** * Tests if all seasonal holidays in Germany are defined by the provider class. - * - * @throws ReflectionException */ public function testSeasonalHolidays(): void { @@ -78,8 +74,6 @@ public function testSeasonalHolidays(): void /** * Tests if all bank holidays in Germany are defined by the provider class. - * - * @throws ReflectionException */ public function testBankHolidays(): void { @@ -88,8 +82,6 @@ public function testBankHolidays(): void /** * Tests if all other holidays in Germany are defined by the provider class. - * - * @throws ReflectionException */ public function testOtherHolidays(): void { @@ -98,6 +90,7 @@ public function testOtherHolidays(): void /** * @throws ReflectionException + * @throws \Exception */ public function testSources(): void { diff --git a/tests/Germany/GoodFridayTest.php b/tests/Germany/GoodFridayTest.php index d37bbd56e..f4c2486ac 100644 --- a/tests/Germany/GoodFridayTest.php +++ b/tests/Germany/GoodFridayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -35,7 +34,6 @@ class GoodFridayTest extends GermanyBaseTestCase implements HolidayTestCase * Tests Good Friday. * * @throws Exception - * @throws ReflectionException */ public function testGoodFriday(): void { @@ -51,7 +49,7 @@ public function testGoodFriday(): void /** * Tests translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -66,7 +64,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Germany/Hamburg/DayOfReformationTest.php b/tests/Germany/Hamburg/DayOfReformationTest.php index f17ec8d0b..1fc660422 100644 --- a/tests/Germany/Hamburg/DayOfReformationTest.php +++ b/tests/Germany/Hamburg/DayOfReformationTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -43,8 +42,6 @@ class DayOfReformationTest extends HamburgBaseTestCase implements HolidayTestCas * * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testHoliday(int $year, DateTime $expected): void { @@ -73,7 +70,7 @@ public function HolidayDataProvider(): array /** * Tests the holiday defined in this test before establishment. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayBeforeEstablishment(): void { @@ -87,7 +84,7 @@ public function testHolidayBeforeEstablishment(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -102,7 +99,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Germany/Hamburg/HamburgTest.php b/tests/Germany/Hamburg/HamburgTest.php index 5b84a54ae..eceee6d43 100644 --- a/tests/Germany/Hamburg/HamburgTest.php +++ b/tests/Germany/Hamburg/HamburgTest.php @@ -30,6 +30,8 @@ class HamburgTest extends HamburgBaseTestCase implements ProviderTestCase /** * Initial setup of this Test Case. + * + * @throws \Exception */ protected function setUp(): void { @@ -38,8 +40,6 @@ protected function setUp(): void /** * Tests if all official holidays in Hamburg (Germany) are defined by the provider class. - * - * @throws ReflectionException */ public function testOfficialHolidays(): void { @@ -58,8 +58,6 @@ public function testOfficialHolidays(): void /** * Tests if all observed holidays in Hamburg (Germany) are defined by the provider class. - * - * @throws ReflectionException */ public function testObservedHolidays(): void { @@ -68,8 +66,6 @@ public function testObservedHolidays(): void /** * Tests if all seasonal holidays in Hamburg (Germany) are defined by the provider class. - * - * @throws ReflectionException */ public function testSeasonalHolidays(): void { @@ -78,8 +74,6 @@ public function testSeasonalHolidays(): void /** * Tests if all bank holidays in Hamburg (Germany) are defined by the provider class. - * - * @throws ReflectionException */ public function testBankHolidays(): void { @@ -88,8 +82,6 @@ public function testBankHolidays(): void /** * Tests if all other holidays in Hamburg (Germany) are defined by the provider class. - * - * @throws ReflectionException */ public function testOtherHolidays(): void { @@ -98,6 +90,7 @@ public function testOtherHolidays(): void /** * @throws ReflectionException + * @throws \Exception */ public function testSources(): void { diff --git a/tests/Germany/Hesse/CorpusChristiTest.php b/tests/Germany/Hesse/CorpusChristiTest.php index dd6871470..c20838f8f 100644 --- a/tests/Germany/Hesse/CorpusChristiTest.php +++ b/tests/Germany/Hesse/CorpusChristiTest.php @@ -15,7 +15,6 @@ namespace Yasumi\tests\Germany\Hesse; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -33,7 +32,6 @@ class CorpusChristiTest extends HesseBaseTestCase implements HolidayTestCase * Tests the holiday defined in this test. * * @throws Exception - * @throws ReflectionException */ public function testHoliday(): void { @@ -50,7 +48,7 @@ public function testHoliday(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -65,7 +63,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Germany/Hesse/HesseTest.php b/tests/Germany/Hesse/HesseTest.php index 21d6b8610..5858f2de9 100644 --- a/tests/Germany/Hesse/HesseTest.php +++ b/tests/Germany/Hesse/HesseTest.php @@ -30,6 +30,8 @@ class HesseTest extends HesseBaseTestCase implements ProviderTestCase /** * Initial setup of this Test Case. + * + * @throws \Exception */ protected function setUp(): void { @@ -38,8 +40,6 @@ protected function setUp(): void /** * Tests if all official holidays in Hesse (Germany) are defined by the provider class. - * - * @throws ReflectionException */ public function testOfficialHolidays(): void { @@ -59,8 +59,6 @@ public function testOfficialHolidays(): void /** * Tests if all observed holidays in Hesse (Germany) are defined by the provider class. - * - * @throws ReflectionException */ public function testObservedHolidays(): void { @@ -69,8 +67,6 @@ public function testObservedHolidays(): void /** * Tests if all seasonal holidays in Hesse (Germany) are defined by the provider class. - * - * @throws ReflectionException */ public function testSeasonalHolidays(): void { @@ -79,8 +75,6 @@ public function testSeasonalHolidays(): void /** * Tests if all bank holidays in Hesse (Germany) are defined by the provider class. - * - * @throws ReflectionException */ public function testBankHolidays(): void { @@ -89,8 +83,6 @@ public function testBankHolidays(): void /** * Tests if all other holidays in Hesse (Germany) are defined by the provider class. - * - * @throws ReflectionException */ public function testOtherHolidays(): void { @@ -99,6 +91,7 @@ public function testOtherHolidays(): void /** * @throws ReflectionException + * @throws \Exception */ public function testSources(): void { diff --git a/tests/Germany/InternationalWorkersDayTest.php b/tests/Germany/InternationalWorkersDayTest.php index ff8312ade..02d2d9453 100644 --- a/tests/Germany/InternationalWorkersDayTest.php +++ b/tests/Germany/InternationalWorkersDayTest.php @@ -16,7 +16,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -37,8 +36,6 @@ class InternationalWorkersDayTest extends GermanyBaseTestCase implements Holiday * * @param int $year the year for which International Workers' Day needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testHoliday(int $year, DateTime $expected): void { @@ -48,7 +45,7 @@ public function testHoliday(int $year, DateTime $expected): void /** * Tests translated name of International Workers' Day. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -63,7 +60,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Germany/LowerSaxony/LowerSaxonyTest.php b/tests/Germany/LowerSaxony/LowerSaxonyTest.php index b27d90e32..3ec102887 100644 --- a/tests/Germany/LowerSaxony/LowerSaxonyTest.php +++ b/tests/Germany/LowerSaxony/LowerSaxonyTest.php @@ -30,6 +30,8 @@ class LowerSaxonyTest extends LowerSaxonyBaseTestCase implements ProviderTestCas /** * Initial setup of this Test Case. + * + * @throws \Exception */ protected function setUp(): void { @@ -38,8 +40,6 @@ protected function setUp(): void /** * Tests if all official holidays in Lower Saxony (Germany) are defined by the provider class. - * - * @throws ReflectionException */ public function testOfficialHolidays(): void { @@ -58,8 +58,6 @@ public function testOfficialHolidays(): void /** * Tests if all observed holidays in Lower Saxony (Germany) are defined by the provider class. - * - * @throws ReflectionException */ public function testObservedHolidays(): void { @@ -68,8 +66,6 @@ public function testObservedHolidays(): void /** * Tests if all seasonal holidays in Lower Saxony (Germany) are defined by the provider class. - * - * @throws ReflectionException */ public function testSeasonalHolidays(): void { @@ -78,8 +74,6 @@ public function testSeasonalHolidays(): void /** * Tests if all bank holidays in Lower Saxony (Germany) are defined by the provider class. - * - * @throws ReflectionException */ public function testBankHolidays(): void { @@ -88,8 +82,6 @@ public function testBankHolidays(): void /** * Tests if all other holidays in Lower Saxony (Germany) are defined by the provider class. - * - * @throws ReflectionException */ public function testOtherHolidays(): void { @@ -98,6 +90,7 @@ public function testOtherHolidays(): void /** * @throws ReflectionException + * @throws \Exception */ public function testSources(): void { diff --git a/tests/Germany/LowerSaxony/ReformationDayTest.php b/tests/Germany/LowerSaxony/ReformationDayTest.php index 4b6b2fc6b..9060aa3c1 100644 --- a/tests/Germany/LowerSaxony/ReformationDayTest.php +++ b/tests/Germany/LowerSaxony/ReformationDayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -43,8 +42,6 @@ class ReformationDayTest extends LowerSaxonyBaseTestCase implements HolidayTestC * * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testHoliday(int $year, DateTime $expected): void { @@ -73,7 +70,7 @@ public function HolidayDataProvider(): array /** * Tests the holiday defined in this test before establishment. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayBeforeEstablishment(): void { @@ -87,7 +84,7 @@ public function testHolidayBeforeEstablishment(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -102,7 +99,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Germany/MecklenburgWesternPomerania/MecklenburgWesternPomeraniaTest.php b/tests/Germany/MecklenburgWesternPomerania/MecklenburgWesternPomeraniaTest.php index 78bd9b14c..595910468 100644 --- a/tests/Germany/MecklenburgWesternPomerania/MecklenburgWesternPomeraniaTest.php +++ b/tests/Germany/MecklenburgWesternPomerania/MecklenburgWesternPomeraniaTest.php @@ -30,6 +30,8 @@ class MecklenburgWesternPomeraniaTest extends MecklenburgWesternPomeraniaBaseTes /** * Initial setup of this Test Case. + * + * @throws \Exception */ protected function setUp(): void { @@ -38,8 +40,6 @@ protected function setUp(): void /** * Tests if all official holidays in Mecklenburg-Western Pomerania (Germany) are defined by the provider class. - * - * @throws ReflectionException */ public function testOfficialHolidays(): void { @@ -67,8 +67,6 @@ public function testOfficialHolidays(): void /** * Tests if all observed holidays in Mecklenburg-Western Pomerania (Germany) are defined by the provider class. - * - * @throws ReflectionException */ public function testObservedHolidays(): void { @@ -77,8 +75,6 @@ public function testObservedHolidays(): void /** * Tests if all seasonal holidays in Mecklenburg-Western Pomerania (Germany) are defined by the provider class. - * - * @throws ReflectionException */ public function testSeasonalHolidays(): void { @@ -87,8 +83,6 @@ public function testSeasonalHolidays(): void /** * Tests if all bank holidays in Mecklenburg-Western Pomerania (Germany) are defined by the provider class. - * - * @throws ReflectionException */ public function testBankHolidays(): void { @@ -97,8 +91,6 @@ public function testBankHolidays(): void /** * Tests if all other holidays in Mecklenburg-Western Pomerania (Germany) are defined by the provider class. - * - * @throws ReflectionException */ public function testOtherHolidays(): void { @@ -107,6 +99,7 @@ public function testOtherHolidays(): void /** * @throws ReflectionException + * @throws \Exception */ public function testSources(): void { diff --git a/tests/Germany/MecklenburgWesternPomerania/ReformationDayTest.php b/tests/Germany/MecklenburgWesternPomerania/ReformationDayTest.php index 368b6e098..ee8de3318 100644 --- a/tests/Germany/MecklenburgWesternPomerania/ReformationDayTest.php +++ b/tests/Germany/MecklenburgWesternPomerania/ReformationDayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -58,7 +57,7 @@ public function HolidayDataProvider(): array /** * Tests the holiday defined in this test before establishment. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayBeforeEstablishment(): void { @@ -72,7 +71,7 @@ public function testHolidayBeforeEstablishment(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -87,7 +86,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Germany/NewYearsDayTest.php b/tests/Germany/NewYearsDayTest.php index ce226496a..344af79e2 100644 --- a/tests/Germany/NewYearsDayTest.php +++ b/tests/Germany/NewYearsDayTest.php @@ -16,7 +16,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -37,8 +36,6 @@ class NewYearsDayTest extends GermanyBaseTestCase implements HolidayTestCase * * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testHoliday(int $year, DateTime $expected): void { @@ -60,7 +57,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -75,7 +72,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Germany/NewYearsEveTest.php b/tests/Germany/NewYearsEveTest.php index 64e5c9b06..9ece28007 100644 --- a/tests/Germany/NewYearsEveTest.php +++ b/tests/Germany/NewYearsEveTest.php @@ -16,7 +16,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -37,8 +36,6 @@ class NewYearsEveTest extends GermanyBaseTestCase implements HolidayTestCase * * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testHoliday(int $year, DateTime $expected): void { @@ -60,7 +57,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -75,7 +72,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Germany/NorthRhineWestphalia/AllSaintsDayTest.php b/tests/Germany/NorthRhineWestphalia/AllSaintsDayTest.php index 25a33a18a..1a1b9e504 100644 --- a/tests/Germany/NorthRhineWestphalia/AllSaintsDayTest.php +++ b/tests/Germany/NorthRhineWestphalia/AllSaintsDayTest.php @@ -16,7 +16,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -37,8 +36,6 @@ class AllSaintsDayTest extends NorthRhineWestphaliaBaseTestCase implements Holid * * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testHoliday(int $year, DateTime $expected): void { @@ -60,7 +57,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -75,7 +72,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Germany/NorthRhineWestphalia/CorpusChristiTest.php b/tests/Germany/NorthRhineWestphalia/CorpusChristiTest.php index 3066cdd03..dc116b24f 100644 --- a/tests/Germany/NorthRhineWestphalia/CorpusChristiTest.php +++ b/tests/Germany/NorthRhineWestphalia/CorpusChristiTest.php @@ -15,7 +15,6 @@ namespace Yasumi\tests\Germany\NorthRhineWestphalia; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -33,7 +32,6 @@ class CorpusChristiTest extends NorthRhineWestphaliaBaseTestCase implements Holi * Tests the holiday defined in this test. * * @throws Exception - * @throws ReflectionException */ public function testHoliday(): void { @@ -50,7 +48,7 @@ public function testHoliday(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -65,7 +63,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Germany/NorthRhineWestphalia/NorthRhineWestphaliaTest.php b/tests/Germany/NorthRhineWestphalia/NorthRhineWestphaliaTest.php index 35751c641..fee44f16a 100644 --- a/tests/Germany/NorthRhineWestphalia/NorthRhineWestphaliaTest.php +++ b/tests/Germany/NorthRhineWestphalia/NorthRhineWestphaliaTest.php @@ -30,6 +30,8 @@ class NorthRhineWestphaliaTest extends NorthRhineWestphaliaBaseTestCase implemen /** * Initial setup of this Test Case. + * + * @throws \Exception */ protected function setUp(): void { @@ -38,8 +40,6 @@ protected function setUp(): void /** * Tests if all official holidays in North Rhine-Westphalia (Germany) are defined by the provider class. - * - * @throws ReflectionException */ public function testOfficialHolidays(): void { @@ -60,8 +60,6 @@ public function testOfficialHolidays(): void /** * Tests if all observed holidays in North Rhine-Westphalia (Germany) are defined by the provider class. - * - * @throws ReflectionException */ public function testObservedHolidays(): void { @@ -70,8 +68,6 @@ public function testObservedHolidays(): void /** * Tests if all seasonal holidays in North Rhine-Westphalia (Germany) are defined by the provider class. - * - * @throws ReflectionException */ public function testSeasonalHolidays(): void { @@ -80,8 +76,6 @@ public function testSeasonalHolidays(): void /** * Tests if all bank holidays in North Rhine-Westphalia (Germany) are defined by the provider class. - * - * @throws ReflectionException */ public function testBankHolidays(): void { @@ -90,8 +84,6 @@ public function testBankHolidays(): void /** * Tests if all other holidays in North Rhine-Westphalia (Germany) are defined by the provider class. - * - * @throws ReflectionException */ public function testOtherHolidays(): void { @@ -100,6 +92,7 @@ public function testOtherHolidays(): void /** * @throws ReflectionException + * @throws \Exception */ public function testSources(): void { diff --git a/tests/Germany/PentecostMondayTest.php b/tests/Germany/PentecostMondayTest.php index 7a84d6265..09b48b042 100644 --- a/tests/Germany/PentecostMondayTest.php +++ b/tests/Germany/PentecostMondayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -35,7 +34,6 @@ class PentecostMondayTest extends GermanyBaseTestCase implements HolidayTestCase * Tests the holiday defined in this test. * * @throws Exception - * @throws ReflectionException */ public function testHoliday(): void { @@ -51,7 +49,7 @@ public function testHoliday(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -66,7 +64,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Germany/PentecostTest.php b/tests/Germany/PentecostTest.php index 221ce94cb..1f87a4c02 100644 --- a/tests/Germany/PentecostTest.php +++ b/tests/Germany/PentecostTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -35,7 +34,6 @@ class PentecostTest extends GermanyBaseTestCase implements HolidayTestCase * Tests the holiday defined in this test. * * @throws Exception - * @throws ReflectionException */ public function testHoliday(): void { @@ -56,7 +54,7 @@ public function testHoliday(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -71,7 +69,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Germany/ReformationDay2017Test.php b/tests/Germany/ReformationDay2017Test.php index c12b505a1..4c6b9f1cd 100644 --- a/tests/Germany/ReformationDay2017Test.php +++ b/tests/Germany/ReformationDay2017Test.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -40,7 +39,6 @@ class ReformationDay2017Test extends GermanyBaseTestCase implements HolidayTestC * Test the holiday defined in this test upon establishment. * * @throws Exception - * @throws ReflectionException */ public function testHolidayOnEstablishment(): void { @@ -55,7 +53,7 @@ public function testHolidayOnEstablishment(): void /** * Test the holiday defined in this test before establishment. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayBeforeEstablishment(): void { @@ -69,7 +67,7 @@ public function testHolidayBeforeEstablishment(): void /** * Test the holiday defined in this test after completion. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayAfterCompletion(): void { @@ -79,7 +77,7 @@ public function testHolidayAfterCompletion(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -94,7 +92,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Germany/RhinelandPalatinate/AllSaintsDayTest.php b/tests/Germany/RhinelandPalatinate/AllSaintsDayTest.php index cbfd274be..629da43ab 100644 --- a/tests/Germany/RhinelandPalatinate/AllSaintsDayTest.php +++ b/tests/Germany/RhinelandPalatinate/AllSaintsDayTest.php @@ -16,7 +16,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -37,8 +36,6 @@ class AllSaintsDayTest extends RhinelandPalatinateBaseTestCase implements Holida * * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testHoliday(int $year, DateTime $expected): void { @@ -60,7 +57,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -75,7 +72,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Germany/RhinelandPalatinate/CorpusChristiTest.php b/tests/Germany/RhinelandPalatinate/CorpusChristiTest.php index 445ebc955..1dc96c1d7 100644 --- a/tests/Germany/RhinelandPalatinate/CorpusChristiTest.php +++ b/tests/Germany/RhinelandPalatinate/CorpusChristiTest.php @@ -15,7 +15,6 @@ namespace Yasumi\tests\Germany\RhinelandPalatinate; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -33,7 +32,6 @@ class CorpusChristiTest extends RhinelandPalatinateBaseTestCase implements Holid * Tests the holiday defined in this test. * * @throws Exception - * @throws ReflectionException */ public function testHoliday(): void { @@ -50,7 +48,7 @@ public function testHoliday(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -65,7 +63,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Germany/RhinelandPalatinate/RhinelandPalatinateTest.php b/tests/Germany/RhinelandPalatinate/RhinelandPalatinateTest.php index de2f76461..cdc672098 100644 --- a/tests/Germany/RhinelandPalatinate/RhinelandPalatinateTest.php +++ b/tests/Germany/RhinelandPalatinate/RhinelandPalatinateTest.php @@ -30,6 +30,8 @@ class RhinelandPalatinateTest extends RhinelandPalatinateBaseTestCase implements /** * Initial setup of this Test Case. + * + * @throws \Exception */ protected function setUp(): void { @@ -38,8 +40,6 @@ protected function setUp(): void /** * Tests if all official holidays in Rhineland Palatinate (Germany) are defined by the provider class. - * - * @throws ReflectionException */ public function testOfficialHolidays(): void { @@ -60,8 +60,6 @@ public function testOfficialHolidays(): void /** * Tests if all observed holidays in Rhineland Palatinate (Germany) are defined by the provider class. - * - * @throws ReflectionException */ public function testObservedHolidays(): void { @@ -70,8 +68,6 @@ public function testObservedHolidays(): void /** * Tests if all seasonal holidays in Rhineland Palatinate (Germany) are defined by the provider class. - * - * @throws ReflectionException */ public function testSeasonalHolidays(): void { @@ -80,8 +76,6 @@ public function testSeasonalHolidays(): void /** * Tests if all bank holidays in Rhineland Palatinate (Germany) are defined by the provider class. - * - * @throws ReflectionException */ public function testBankHolidays(): void { @@ -90,8 +84,6 @@ public function testBankHolidays(): void /** * Tests if all other holidays in Rhineland Palatinate (Germany) are defined by the provider class. - * - * @throws ReflectionException */ public function testOtherHolidays(): void { @@ -100,6 +92,7 @@ public function testOtherHolidays(): void /** * @throws ReflectionException + * @throws \Exception */ public function testSources(): void { diff --git a/tests/Germany/Saarland/AllSaintsDayTest.php b/tests/Germany/Saarland/AllSaintsDayTest.php index d4d5fc1db..b0eff6eb5 100644 --- a/tests/Germany/Saarland/AllSaintsDayTest.php +++ b/tests/Germany/Saarland/AllSaintsDayTest.php @@ -16,7 +16,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -37,8 +36,6 @@ class AllSaintsDayTest extends SaarlandBaseTestCase implements HolidayTestCase * * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testHoliday(int $year, DateTime $expected): void { @@ -60,7 +57,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -75,7 +72,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Germany/Saarland/AssumptionOfMaryTest.php b/tests/Germany/Saarland/AssumptionOfMaryTest.php index 78f70797d..94ff9966b 100644 --- a/tests/Germany/Saarland/AssumptionOfMaryTest.php +++ b/tests/Germany/Saarland/AssumptionOfMaryTest.php @@ -16,7 +16,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -37,8 +36,6 @@ class AssumptionOfMaryTest extends SaarlandBaseTestCase implements HolidayTestCa * * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testHoliday(int $year, DateTime $expected): void { @@ -60,7 +57,7 @@ public function HolidayDataProvider(): array /** * Tests translated name of the Assumption of Mary. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -75,7 +72,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Germany/Saarland/CorpusChristiTest.php b/tests/Germany/Saarland/CorpusChristiTest.php index a266d6bd7..231347ab7 100644 --- a/tests/Germany/Saarland/CorpusChristiTest.php +++ b/tests/Germany/Saarland/CorpusChristiTest.php @@ -15,7 +15,6 @@ namespace Yasumi\tests\Germany\Saarland; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -33,7 +32,6 @@ class CorpusChristiTest extends SaarlandBaseTestCase implements HolidayTestCase * Tests the holiday defined in this test. * * @throws Exception - * @throws ReflectionException */ public function testHoliday(): void { @@ -50,7 +48,7 @@ public function testHoliday(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -65,7 +63,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Germany/Saarland/SaarlandTest.php b/tests/Germany/Saarland/SaarlandTest.php index 2524fbdec..988c317b5 100644 --- a/tests/Germany/Saarland/SaarlandTest.php +++ b/tests/Germany/Saarland/SaarlandTest.php @@ -30,6 +30,8 @@ class SaarlandTest extends SaarlandBaseTestCase implements ProviderTestCase /** * Initial setup of this Test Case. + * + * @throws \Exception */ protected function setUp(): void { @@ -38,8 +40,6 @@ protected function setUp(): void /** * Tests if all official holidays in Saarland (Germany) are defined by the provider class. - * - * @throws ReflectionException */ public function testOfficialHolidays(): void { @@ -60,8 +60,6 @@ public function testOfficialHolidays(): void /** * Tests if all observed holidays in Saarland (Germany) are defined by the provider class. - * - * @throws ReflectionException */ public function testObservedHolidays(): void { @@ -70,8 +68,6 @@ public function testObservedHolidays(): void /** * Tests if all seasonal holidays in Saarland (Germany) are defined by the provider class. - * - * @throws ReflectionException */ public function testSeasonalHolidays(): void { @@ -80,8 +76,6 @@ public function testSeasonalHolidays(): void /** * Tests if all bank holidays in Saarland (Germany) are defined by the provider class. - * - * @throws ReflectionException */ public function testBankHolidays(): void { @@ -90,8 +84,6 @@ public function testBankHolidays(): void /** * Tests if all other holidays in Saarland (Germany) are defined by the provider class. - * - * @throws ReflectionException */ public function testOtherHolidays(): void { @@ -100,6 +92,7 @@ public function testOtherHolidays(): void /** * @throws ReflectionException + * @throws \Exception */ public function testSources(): void { diff --git a/tests/Germany/Saxony/ReformationDayTest.php b/tests/Germany/Saxony/ReformationDayTest.php index c89b88ca0..34f05982d 100644 --- a/tests/Germany/Saxony/ReformationDayTest.php +++ b/tests/Germany/Saxony/ReformationDayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -43,8 +42,6 @@ class ReformationDayTest extends SaxonyBaseTestCase implements HolidayTestCase * * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testHoliday(int $year, DateTime $expected): void { @@ -73,7 +70,7 @@ public function HolidayDataProvider(): array /** * Tests the holiday defined in this test before establishment. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayBeforeEstablishment(): void { @@ -87,7 +84,7 @@ public function testHolidayBeforeEstablishment(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -102,7 +99,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Germany/Saxony/RepentanceAndPrayerDayTest.php b/tests/Germany/Saxony/RepentanceAndPrayerDayTest.php index ef9429e7d..100724347 100644 --- a/tests/Germany/Saxony/RepentanceAndPrayerDayTest.php +++ b/tests/Germany/Saxony/RepentanceAndPrayerDayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -44,7 +43,6 @@ class RepentanceAndPrayerDayTest extends SaxonyBaseTestCase implements HolidayTe /** * Tests the holiday defined in this test on or after establishment. * - * @throws ReflectionException * @throws Exception */ public function testHolidayOnAfterEstablishment(): void @@ -64,7 +62,7 @@ public function testHolidayOnAfterEstablishment(): void /** * Tests the holiday defined in this test before establishment. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayBeforeEstablishment(): void { @@ -78,7 +76,7 @@ public function testHolidayBeforeEstablishment(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -93,7 +91,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Germany/Saxony/SaxonyTest.php b/tests/Germany/Saxony/SaxonyTest.php index b3713cc58..53e3741a2 100644 --- a/tests/Germany/Saxony/SaxonyTest.php +++ b/tests/Germany/Saxony/SaxonyTest.php @@ -30,6 +30,8 @@ class SaxonyTest extends SaxonyBaseTestCase implements ProviderTestCase /** * Initial setup of this Test Case. + * + * @throws \Exception */ protected function setUp(): void { @@ -38,8 +40,6 @@ protected function setUp(): void /** * Tests if all official holidays in Saxony (Germany) are defined by the provider class. - * - * @throws ReflectionException */ public function testOfficialHolidays(): void { @@ -71,8 +71,6 @@ public function testOfficialHolidays(): void /** * Tests if all observed holidays in Saxony (Germany) are defined by the provider class. - * - * @throws ReflectionException */ public function testObservedHolidays(): void { @@ -81,8 +79,6 @@ public function testObservedHolidays(): void /** * Tests if all seasonal holidays in Saxony (Germany) are defined by the provider class. - * - * @throws ReflectionException */ public function testSeasonalHolidays(): void { @@ -91,8 +87,6 @@ public function testSeasonalHolidays(): void /** * Tests if all bank holidays in Saxony (Germany) are defined by the provider class. - * - * @throws ReflectionException */ public function testBankHolidays(): void { @@ -101,8 +95,6 @@ public function testBankHolidays(): void /** * Tests if all other holidays in Saxony (Germany) are defined by the provider class. - * - * @throws ReflectionException */ public function testOtherHolidays(): void { @@ -111,6 +103,7 @@ public function testOtherHolidays(): void /** * @throws ReflectionException + * @throws \Exception */ public function testSources(): void { diff --git a/tests/Germany/SaxonyAnhalt/EpiphanyTest.php b/tests/Germany/SaxonyAnhalt/EpiphanyTest.php index 8b637ba86..e6ffc3272 100644 --- a/tests/Germany/SaxonyAnhalt/EpiphanyTest.php +++ b/tests/Germany/SaxonyAnhalt/EpiphanyTest.php @@ -16,7 +16,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -37,8 +36,6 @@ class EpiphanyTest extends SaxonyAnhaltBaseTestCase implements HolidayTestCase * * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testHoliday(int $year, DateTime $expected): void { @@ -60,7 +57,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -75,7 +72,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Germany/SaxonyAnhalt/ReformationDayTest.php b/tests/Germany/SaxonyAnhalt/ReformationDayTest.php index f840dbf16..0b07bfef7 100644 --- a/tests/Germany/SaxonyAnhalt/ReformationDayTest.php +++ b/tests/Germany/SaxonyAnhalt/ReformationDayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -43,8 +42,6 @@ class ReformationDayTest extends SaxonyAnhaltBaseTestCase implements HolidayTest * * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testHoliday(int $year, DateTime $expected): void { @@ -73,7 +70,7 @@ public function HolidayDataProvider(): array /** * Tests the holiday defined in this test before establishment. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayBeforeEstablishment(): void { @@ -87,7 +84,7 @@ public function testHolidayBeforeEstablishment(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -102,7 +99,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Germany/SaxonyAnhalt/SaxonyAnhaltTest.php b/tests/Germany/SaxonyAnhalt/SaxonyAnhaltTest.php index f15d9d599..1b3f5949e 100644 --- a/tests/Germany/SaxonyAnhalt/SaxonyAnhaltTest.php +++ b/tests/Germany/SaxonyAnhalt/SaxonyAnhaltTest.php @@ -30,6 +30,8 @@ class SaxonyAnhaltTest extends SaxonyAnhaltBaseTestCase implements ProviderTestC /** * Initial setup of this Test Case. + * + * @throws \Exception */ protected function setUp(): void { @@ -38,8 +40,6 @@ protected function setUp(): void /** * Tests if all official holidays in Saxony-Anhalt (Germany) are defined by the provider class. - * - * @throws ReflectionException */ public function testOfficialHolidays(): void { @@ -67,8 +67,6 @@ public function testOfficialHolidays(): void /** * Tests if all observed holidays in Saxony-Anhalt (Germany) are defined by the provider class. - * - * @throws ReflectionException */ public function testObservedHolidays(): void { @@ -77,8 +75,6 @@ public function testObservedHolidays(): void /** * Tests if all seasonal holidays in Saxony-Anhalt (Germany) are defined by the provider class. - * - * @throws ReflectionException */ public function testSeasonalHolidays(): void { @@ -87,8 +83,6 @@ public function testSeasonalHolidays(): void /** * Tests if all bank holidays in Saxony-Anhalt (Germany) are defined by the provider class. - * - * @throws ReflectionException */ public function testBankHolidays(): void { @@ -97,8 +91,6 @@ public function testBankHolidays(): void /** * Tests if all other holidays in Saxony-Anhalt (Germany) are defined by the provider class. - * - * @throws ReflectionException */ public function testOtherHolidays(): void { @@ -107,6 +99,7 @@ public function testOtherHolidays(): void /** * @throws ReflectionException + * @throws \Exception */ public function testSources(): void { diff --git a/tests/Germany/SchleswigHolstein/ReformationDayTest.php b/tests/Germany/SchleswigHolstein/ReformationDayTest.php index 09c4909c8..b5e2cd06d 100644 --- a/tests/Germany/SchleswigHolstein/ReformationDayTest.php +++ b/tests/Germany/SchleswigHolstein/ReformationDayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -43,8 +42,6 @@ class ReformationDayTest extends SchleswigHolsteinBaseTestCase implements Holida * * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testHoliday(int $year, DateTime $expected): void { @@ -73,7 +70,7 @@ public function HolidayDataProvider(): array /** * Tests the holiday defined in this test before establishment. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayBeforeEstablishment(): void { @@ -87,7 +84,7 @@ public function testHolidayBeforeEstablishment(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -102,7 +99,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Germany/SchleswigHolstein/SchleswigHolsteinTest.php b/tests/Germany/SchleswigHolstein/SchleswigHolsteinTest.php index 28eb39bc6..9ccc65097 100644 --- a/tests/Germany/SchleswigHolstein/SchleswigHolsteinTest.php +++ b/tests/Germany/SchleswigHolstein/SchleswigHolsteinTest.php @@ -30,6 +30,8 @@ class SchleswigHolsteinTest extends SchleswigHolsteinBaseTestCase implements Pro /** * Initial setup of this Test Case. + * + * @throws \Exception */ protected function setUp(): void { @@ -38,8 +40,6 @@ protected function setUp(): void /** * Tests if all official holidays in Schleswig-Holstein (Germany) are defined by the provider class. - * - * @throws ReflectionException */ public function testOfficialHolidays(): void { @@ -58,8 +58,6 @@ public function testOfficialHolidays(): void /** * Tests if all observed holidays in Schleswig-Holstein (Germany) are defined by the provider class. - * - * @throws ReflectionException */ public function testObservedHolidays(): void { @@ -68,8 +66,6 @@ public function testObservedHolidays(): void /** * Tests if all seasonal holidays in Schleswig-Holstein (Germany) are defined by the provider class. - * - * @throws ReflectionException */ public function testSeasonalHolidays(): void { @@ -78,8 +74,6 @@ public function testSeasonalHolidays(): void /** * Tests if all bank holidays in Schleswig-Holstein (Germany) are defined by the provider class. - * - * @throws ReflectionException */ public function testBankHolidays(): void { @@ -88,8 +82,6 @@ public function testBankHolidays(): void /** * Tests if all other holidays in Schleswig-Holstein (Germany) are defined by the provider class. - * - * @throws ReflectionException */ public function testOtherHolidays(): void { @@ -98,6 +90,7 @@ public function testOtherHolidays(): void /** * @throws ReflectionException + * @throws \Exception */ public function testSources(): void { diff --git a/tests/Germany/SecondChristmasDayTest.php b/tests/Germany/SecondChristmasDayTest.php index 13eb7d195..4caf6f494 100644 --- a/tests/Germany/SecondChristmasDayTest.php +++ b/tests/Germany/SecondChristmasDayTest.php @@ -16,7 +16,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -37,8 +36,6 @@ class SecondChristmasDayTest extends GermanyBaseTestCase implements HolidayTestC * * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testHoliday(int $year, DateTime $expected): void { @@ -60,7 +57,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -75,7 +72,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Germany/Thuringia/ReformationDayTest.php b/tests/Germany/Thuringia/ReformationDayTest.php index d750bbad2..5fb7bea47 100644 --- a/tests/Germany/Thuringia/ReformationDayTest.php +++ b/tests/Germany/Thuringia/ReformationDayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -43,8 +42,6 @@ class ReformationDayTest extends ThuringiaBaseTestCase implements HolidayTestCas * * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testHoliday(int $year, DateTime $expected): void { @@ -73,7 +70,7 @@ public function HolidayDataProvider(): array /** * Tests the holiday defined in this test before establishment. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayBeforeEstablishment(): void { @@ -87,7 +84,7 @@ public function testHolidayBeforeEstablishment(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -102,7 +99,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Germany/Thuringia/ThuringiaTest.php b/tests/Germany/Thuringia/ThuringiaTest.php index de62a7adf..49b1b3921 100644 --- a/tests/Germany/Thuringia/ThuringiaTest.php +++ b/tests/Germany/Thuringia/ThuringiaTest.php @@ -30,6 +30,8 @@ class ThuringiaTest extends ThuringiaBaseTestCase implements ProviderTestCase /** * Initial setup of this Test Case. + * + * @throws \Exception */ protected function setUp(): void { @@ -38,8 +40,6 @@ protected function setUp(): void /** * Tests if all official holidays in Thuringia (Germany) are defined by the provider class. - * - * @throws ReflectionException */ public function testOfficialHolidays(): void { @@ -71,8 +71,6 @@ public function testOfficialHolidays(): void /** * Tests if all observed holidays in Thuringia (Germany) are defined by the provider class. - * - * @throws ReflectionException */ public function testObservedHolidays(): void { @@ -81,8 +79,6 @@ public function testObservedHolidays(): void /** * Tests if all seasonal holidays in Thuringia (Germany) are defined by the provider class. - * - * @throws ReflectionException */ public function testSeasonalHolidays(): void { @@ -91,8 +87,6 @@ public function testSeasonalHolidays(): void /** * Tests if all bank holidays in Thuringia (Germany) are defined by the provider class. - * - * @throws ReflectionException */ public function testBankHolidays(): void { @@ -101,8 +95,6 @@ public function testBankHolidays(): void /** * Tests if all other holidays in Thuringia (Germany) are defined by the provider class. - * - * @throws ReflectionException */ public function testOtherHolidays(): void { @@ -111,6 +103,7 @@ public function testOtherHolidays(): void /** * @throws ReflectionException + * @throws \Exception */ public function testSources(): void { diff --git a/tests/Germany/Thuringia/WorldChildrensDayTest.php b/tests/Germany/Thuringia/WorldChildrensDayTest.php index fb1f90e74..1a835680c 100644 --- a/tests/Germany/Thuringia/WorldChildrensDayTest.php +++ b/tests/Germany/Thuringia/WorldChildrensDayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -43,8 +42,6 @@ class WorldChildrensDayTest extends ThuringiaBaseTestCase implements HolidayTest * * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testHoliday(int $year, DateTime $expected): void { @@ -73,7 +70,7 @@ public function HolidayDataProvider(): array /** * Tests the holiday defined in this test before establishment. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayBeforeEstablishment(): void { @@ -87,7 +84,7 @@ public function testHolidayBeforeEstablishment(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -102,7 +99,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Greece/AnnunciationTest.php b/tests/Greece/AnnunciationTest.php index 97a960d63..201e53173 100644 --- a/tests/Greece/AnnunciationTest.php +++ b/tests/Greece/AnnunciationTest.php @@ -16,7 +16,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -37,8 +36,6 @@ class AnnunciationTest extends GreeceBaseTestCase implements HolidayTestCase * * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testHoliday(int $year, DateTime $expected): void { @@ -60,7 +57,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -75,7 +72,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Greece/AscensionDayTest.php b/tests/Greece/AscensionDayTest.php index 442ac7ab8..e4ff78766 100644 --- a/tests/Greece/AscensionDayTest.php +++ b/tests/Greece/AscensionDayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -35,7 +34,6 @@ class AscensionDayTest extends GreeceBaseTestCase implements HolidayTestCase * Tests the holiday defined in this test. * * @throws Exception - * @throws ReflectionException */ public function testHoliday(): void { @@ -51,7 +49,7 @@ public function testHoliday(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -66,7 +64,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Greece/AssumptionOfMaryTest.php b/tests/Greece/AssumptionOfMaryTest.php index 5f246e201..1ac912272 100644 --- a/tests/Greece/AssumptionOfMaryTest.php +++ b/tests/Greece/AssumptionOfMaryTest.php @@ -16,7 +16,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -37,8 +36,6 @@ class AssumptionOfMaryTest extends GreeceBaseTestCase implements HolidayTestCase * * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testHoliday(int $year, DateTime $expected): void { @@ -60,7 +57,7 @@ public function HolidayDataProvider(): array /** * Tests translated name of the Assumption of Mary. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -75,7 +72,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Greece/ChristmasDayTest.php b/tests/Greece/ChristmasDayTest.php index 1fcf452e3..8bb6ddec5 100644 --- a/tests/Greece/ChristmasDayTest.php +++ b/tests/Greece/ChristmasDayTest.php @@ -16,7 +16,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -37,8 +36,6 @@ class ChristmasDayTest extends GreeceBaseTestCase implements HolidayTestCase * * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testHoliday(int $year, DateTime $expected): void { @@ -60,7 +57,7 @@ public function HolidayDataProvider(): array /** * Tests translated name of Christmas Day. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -75,7 +72,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Greece/CleanMondayTest.php b/tests/Greece/CleanMondayTest.php index 025fc6c1e..c05a66a16 100644 --- a/tests/Greece/CleanMondayTest.php +++ b/tests/Greece/CleanMondayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -35,7 +34,6 @@ class CleanMondayTest extends GreeceBaseTestCase implements HolidayTestCase * Tests the holiday defined in this test. * * @throws Exception - * @throws ReflectionException */ public function testHoliday(): void { @@ -51,7 +49,7 @@ public function testHoliday(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -66,7 +64,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Greece/EasterMondayTest.php b/tests/Greece/EasterMondayTest.php index 000efc060..51c8e28a7 100644 --- a/tests/Greece/EasterMondayTest.php +++ b/tests/Greece/EasterMondayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -35,7 +34,6 @@ class EasterMondayTest extends GreeceBaseTestCase implements HolidayTestCase * Tests the holiday defined in this test. * * @throws Exception - * @throws ReflectionException */ public function testHoliday(): void { @@ -51,7 +49,7 @@ public function testHoliday(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -66,7 +64,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Greece/EasterTest.php b/tests/Greece/EasterTest.php index d8c44a9ec..76d80df04 100644 --- a/tests/Greece/EasterTest.php +++ b/tests/Greece/EasterTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -35,7 +34,6 @@ class EasterTest extends GreeceBaseTestCase implements HolidayTestCase * Tests the holiday defined in this test. * * @throws Exception - * @throws ReflectionException */ public function testHoliday(): void { @@ -51,7 +49,7 @@ public function testHoliday(): void /** * Tests translated name of Easter. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -66,7 +64,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Greece/EpiphanyTest.php b/tests/Greece/EpiphanyTest.php index c9b973e42..54b27544f 100644 --- a/tests/Greece/EpiphanyTest.php +++ b/tests/Greece/EpiphanyTest.php @@ -16,7 +16,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -37,8 +36,6 @@ class EpiphanyTest extends GreeceBaseTestCase implements HolidayTestCase * * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testHoliday(int $year, DateTime $expected): void { @@ -60,7 +57,7 @@ public function HolidayDataProvider(): array /** * Tests translated name of Epiphany. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -75,7 +72,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Greece/GreeceTest.php b/tests/Greece/GreeceTest.php index 78024df39..095a5bf6d 100644 --- a/tests/Greece/GreeceTest.php +++ b/tests/Greece/GreeceTest.php @@ -30,6 +30,8 @@ class GreeceTest extends GreeceBaseTestCase implements ProviderTestCase /** * Initial setup of this Test Case. + * + * @throws \Exception */ protected function setUp(): void { @@ -38,8 +40,6 @@ protected function setUp(): void /** * Tests if all official holidays in Greece are defined by the provider class. - * - * @throws ReflectionException */ public function testOfficialHolidays(): void { @@ -64,8 +64,6 @@ public function testOfficialHolidays(): void /** * Tests if all observed holidays in Greece are defined by the provider class. - * - * @throws ReflectionException */ public function testObservedHolidays(): void { @@ -74,8 +72,6 @@ public function testObservedHolidays(): void /** * Tests if all seasonal holidays in Greece are defined by the provider class. - * - * @throws ReflectionException */ public function testSeasonalHolidays(): void { @@ -84,8 +80,6 @@ public function testSeasonalHolidays(): void /** * Tests if all bank holidays in Greece are defined by the provider class. - * - * @throws ReflectionException */ public function testBankHolidays(): void { @@ -94,8 +88,6 @@ public function testBankHolidays(): void /** * Tests if all other holidays in Greece are defined by the provider class. - * - * @throws ReflectionException */ public function testOtherHolidays(): void { @@ -109,6 +101,7 @@ public function testOtherHolidays(): void /** * @throws ReflectionException + * @throws \Exception */ public function testSources(): void { diff --git a/tests/Greece/IndepencenceDayTest.php b/tests/Greece/IndepencenceDayTest.php index 4f96f8c92..df94009f1 100644 --- a/tests/Greece/IndepencenceDayTest.php +++ b/tests/Greece/IndepencenceDayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -40,7 +39,6 @@ class IndepencenceDayTest extends GreeceBaseTestCase implements HolidayTestCase * Tests the holiday defined in this test. * * @throws Exception - * @throws ReflectionException */ public function testHoliday(): void { @@ -56,7 +54,7 @@ public function testHoliday(): void /** * Tests the holiday defined in this test before establishment. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayBeforeEstablishment(): void { @@ -70,7 +68,7 @@ public function testHolidayBeforeEstablishment(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -85,7 +83,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Greece/InternationalWorkersDayTest.php b/tests/Greece/InternationalWorkersDayTest.php index da146b5a3..5544f9d54 100644 --- a/tests/Greece/InternationalWorkersDayTest.php +++ b/tests/Greece/InternationalWorkersDayTest.php @@ -16,7 +16,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -37,8 +36,6 @@ class InternationalWorkersDayTest extends GreeceBaseTestCase implements HolidayT * * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testHoliday(int $year, DateTime $expected): void { @@ -48,7 +45,7 @@ public function testHoliday(int $year, DateTime $expected): void /** * Tests translated name of International Workers' Day. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -63,7 +60,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Greece/NewYearsDayTest.php b/tests/Greece/NewYearsDayTest.php index 6be5a507c..209b69bb9 100644 --- a/tests/Greece/NewYearsDayTest.php +++ b/tests/Greece/NewYearsDayTest.php @@ -16,7 +16,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -37,8 +36,6 @@ class NewYearsDayTest extends GreeceBaseTestCase implements HolidayTestCase * * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testHoliday(int $year, DateTime $expected): void { @@ -48,7 +45,7 @@ public function testHoliday(int $year, DateTime $expected): void /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -63,7 +60,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Greece/OhiDayTest.php b/tests/Greece/OhiDayTest.php index 6ba7b42ca..091a8d40b 100644 --- a/tests/Greece/OhiDayTest.php +++ b/tests/Greece/OhiDayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -40,7 +39,6 @@ class OhiDayTest extends GreeceBaseTestCase implements HolidayTestCase * Tests the holiday defined in this test. * * @throws Exception - * @throws ReflectionException */ public function testHoliday(): void { @@ -56,7 +54,7 @@ public function testHoliday(): void /** * Tests the holiday defined in this test before establishment. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayBeforeEstablishment(): void { @@ -70,7 +68,7 @@ public function testHolidayBeforeEstablishment(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -85,7 +83,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Greece/PentecostMondayTest.php b/tests/Greece/PentecostMondayTest.php index 593b8c9d7..d74eb66b5 100644 --- a/tests/Greece/PentecostMondayTest.php +++ b/tests/Greece/PentecostMondayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -35,7 +34,6 @@ class PentecostMondayTest extends GreeceBaseTestCase implements HolidayTestCase * Tests the holiday defined in this test. * * @throws Exception - * @throws ReflectionException */ public function testHoliday(): void { @@ -51,7 +49,7 @@ public function testHoliday(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -66,7 +64,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Greece/PentecostTest.php b/tests/Greece/PentecostTest.php index fb255be6a..56081bf19 100644 --- a/tests/Greece/PentecostTest.php +++ b/tests/Greece/PentecostTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -35,7 +34,6 @@ class PentecostTest extends GreeceBaseTestCase implements HolidayTestCase * Tests the holiday defined in this test. * * @throws Exception - * @throws ReflectionException */ public function testHoliday(): void { @@ -51,7 +49,7 @@ public function testHoliday(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -66,7 +64,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Greece/PolytechnioTest.php b/tests/Greece/PolytechnioTest.php index a68c70b56..7c428218a 100644 --- a/tests/Greece/PolytechnioTest.php +++ b/tests/Greece/PolytechnioTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -40,7 +39,6 @@ class PolytechnioTest extends GreeceBaseTestCase implements HolidayTestCase * Tests the holiday defined in this test. * * @throws Exception - * @throws ReflectionException */ public function testHoliday(): void { @@ -56,7 +54,7 @@ public function testHoliday(): void /** * Tests the holiday defined in this test before establishment. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayBeforeEstablishment(): void { @@ -70,7 +68,7 @@ public function testHolidayBeforeEstablishment(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -85,7 +83,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Greece/ThreeHolyHierarchsTest.php b/tests/Greece/ThreeHolyHierarchsTest.php index 8d8a7ab36..e119737a8 100644 --- a/tests/Greece/ThreeHolyHierarchsTest.php +++ b/tests/Greece/ThreeHolyHierarchsTest.php @@ -16,7 +16,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -37,8 +36,6 @@ class ThreeHolyHierarchsTest extends GreeceBaseTestCase implements HolidayTestCa * * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testHoliday(int $year, DateTime $expected): void { @@ -60,7 +57,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -75,7 +72,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Greece/goodFridayTest.php b/tests/Greece/goodFridayTest.php index c328a7578..b9f912639 100644 --- a/tests/Greece/goodFridayTest.php +++ b/tests/Greece/goodFridayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -35,7 +34,6 @@ class goodFridayTest extends GreeceBaseTestCase implements HolidayTestCase * Tests the holiday defined in this test. * * @throws Exception - * @throws ReflectionException */ public function testHoliday(): void { @@ -51,7 +49,7 @@ public function testHoliday(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -66,7 +64,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Hungary/AllSaintsDayTest.php b/tests/Hungary/AllSaintsDayTest.php index d2dc4fd3e..7fb1bce58 100644 --- a/tests/Hungary/AllSaintsDayTest.php +++ b/tests/Hungary/AllSaintsDayTest.php @@ -16,7 +16,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -37,8 +36,6 @@ class AllSaintsDayTest extends HungaryBaseTestCase implements HolidayTestCase * * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testHoliday(int $year, DateTime $expected): void { @@ -60,7 +57,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -75,7 +72,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Hungary/ChristmasTest.php b/tests/Hungary/ChristmasTest.php index ed3f7d5e7..0b05b7de6 100644 --- a/tests/Hungary/ChristmasTest.php +++ b/tests/Hungary/ChristmasTest.php @@ -16,7 +16,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -37,8 +36,6 @@ class ChristmasTest extends HungaryBaseTestCase implements HolidayTestCase * * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testHoliday(int $year, DateTime $expected): void { @@ -60,7 +57,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -75,7 +72,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Hungary/EasterMondayTest.php b/tests/Hungary/EasterMondayTest.php index 1de531198..526c2f208 100644 --- a/tests/Hungary/EasterMondayTest.php +++ b/tests/Hungary/EasterMondayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -35,7 +34,6 @@ class EasterMondayTest extends HungaryBaseTestCase implements HolidayTestCase * Tests the holiday defined in this test. * * @throws Exception - * @throws ReflectionException */ public function testHoliday(): void { @@ -51,7 +49,7 @@ public function testHoliday(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -66,7 +64,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Hungary/EasterTest.php b/tests/Hungary/EasterTest.php index 97eb06ec2..45356ebff 100644 --- a/tests/Hungary/EasterTest.php +++ b/tests/Hungary/EasterTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -35,7 +34,6 @@ class EasterTest extends HungaryBaseTestCase implements HolidayTestCase * Tests the holiday defined in this test. * * @throws Exception - * @throws ReflectionException */ public function testHoliday(): void { @@ -51,7 +49,7 @@ public function testHoliday(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -66,7 +64,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Hungary/HungaryTest.php b/tests/Hungary/HungaryTest.php index 2189669f4..eb3d8b7fb 100644 --- a/tests/Hungary/HungaryTest.php +++ b/tests/Hungary/HungaryTest.php @@ -30,6 +30,8 @@ class HungaryTest extends HungaryBaseTestCase implements ProviderTestCase /** * Initial setup of this Test Case. + * + * @throws \Exception */ protected function setUp(): void { @@ -38,8 +40,6 @@ protected function setUp(): void /** * Tests if all official holidays in Hungary are defined by the provider class. - * - * @throws ReflectionException */ public function testOfficialHolidays(): void { @@ -75,8 +75,6 @@ public function testOfficialHolidays(): void /** * Tests if all observed holidays in Hungary are defined by the provider class. - * - * @throws ReflectionException */ public function testObservedHolidays(): void { @@ -85,8 +83,6 @@ public function testObservedHolidays(): void /** * Tests if all seasonal holidays in Hungary are defined by the provider class. - * - * @throws ReflectionException */ public function testSeasonalHolidays(): void { @@ -95,8 +91,6 @@ public function testSeasonalHolidays(): void /** * Tests if all bank holidays in Hungary are defined by the provider class. - * - * @throws ReflectionException */ public function testBankHolidays(): void { @@ -105,8 +99,6 @@ public function testBankHolidays(): void /** * Tests if all other holidays in Hungary are defined by the provider class. - * - * @throws ReflectionException */ public function testOtherHolidays(): void { @@ -115,6 +107,7 @@ public function testOtherHolidays(): void /** * @throws ReflectionException + * @throws \Exception */ public function testSources(): void { diff --git a/tests/Hungary/InternationalWorkersDayTest.php b/tests/Hungary/InternationalWorkersDayTest.php index 6665d4a5f..dd168dff3 100644 --- a/tests/Hungary/InternationalWorkersDayTest.php +++ b/tests/Hungary/InternationalWorkersDayTest.php @@ -16,7 +16,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -37,8 +36,6 @@ class InternationalWorkersDayTest extends HungaryBaseTestCase implements Holiday * * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testHoliday(int $year, DateTime $expected): void { @@ -60,7 +57,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -75,7 +72,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Hungary/MemorialDay1848Test.php b/tests/Hungary/MemorialDay1848Test.php index 97b4d32a0..bbac4e42e 100644 --- a/tests/Hungary/MemorialDay1848Test.php +++ b/tests/Hungary/MemorialDay1848Test.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -40,7 +39,6 @@ class MemorialDay1848Test extends HungaryBaseTestCase implements HolidayTestCase * Tests the holiday defined in this test on or after establishment. * * @throws Exception - * @throws ReflectionException */ public function testHolidayOnAfterEstablishment(): void { @@ -56,7 +54,7 @@ public function testHolidayOnAfterEstablishment(): void /** * Tests the holiday defined in this test before establishment. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayBeforeEstablishment(): void { @@ -70,7 +68,7 @@ public function testHolidayBeforeEstablishment(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -85,7 +83,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Hungary/MemorialDay1956Test.php b/tests/Hungary/MemorialDay1956Test.php index ce181e8c3..3e746ca28 100644 --- a/tests/Hungary/MemorialDay1956Test.php +++ b/tests/Hungary/MemorialDay1956Test.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -40,7 +39,6 @@ class MemorialDay1956Test extends HungaryBaseTestCase implements HolidayTestCase * Tests the holiday defined in this test on or after establishment. * * @throws Exception - * @throws ReflectionException */ public function testHolidayOnAfterEstablishment(): void { @@ -56,7 +54,7 @@ public function testHolidayOnAfterEstablishment(): void /** * Tests the holiday defined in this test before establishment. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayBeforeEstablishment(): void { @@ -70,7 +68,7 @@ public function testHolidayBeforeEstablishment(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -85,7 +83,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Hungary/NewYearsDayTest.php b/tests/Hungary/NewYearsDayTest.php index f04a1c451..4e569703c 100644 --- a/tests/Hungary/NewYearsDayTest.php +++ b/tests/Hungary/NewYearsDayTest.php @@ -16,7 +16,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -37,8 +36,6 @@ class NewYearsDayTest extends HungaryBaseTestCase implements HolidayTestCase * * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testHoliday(int $year, DateTime $expected): void { @@ -60,7 +57,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -75,7 +72,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Hungary/PentecostMondayTest.php b/tests/Hungary/PentecostMondayTest.php index c5c7d1cc3..772ef2b54 100644 --- a/tests/Hungary/PentecostMondayTest.php +++ b/tests/Hungary/PentecostMondayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -35,7 +34,6 @@ class PentecostMondayTest extends HungaryBaseTestCase implements HolidayTestCase * Tests the holiday defined in this test. * * @throws Exception - * @throws ReflectionException */ public function testHoliday(): void { @@ -51,7 +49,7 @@ public function testHoliday(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -66,7 +64,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Hungary/PentecostTest.php b/tests/Hungary/PentecostTest.php index 6518f5c55..eec9d311b 100644 --- a/tests/Hungary/PentecostTest.php +++ b/tests/Hungary/PentecostTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -35,7 +34,6 @@ class PentecostTest extends HungaryBaseTestCase implements HolidayTestCase * Tests the holiday defined in this test. * * @throws Exception - * @throws ReflectionException */ public function testHoliday(): void { @@ -51,7 +49,7 @@ public function testHoliday(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -66,7 +64,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Hungary/SecondChristmasDayTest.php b/tests/Hungary/SecondChristmasDayTest.php index 48e2c5a8a..ac2c11c22 100644 --- a/tests/Hungary/SecondChristmasDayTest.php +++ b/tests/Hungary/SecondChristmasDayTest.php @@ -16,7 +16,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -37,8 +36,6 @@ class SecondChristmasDayTest extends HungaryBaseTestCase implements HolidayTestC * * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testHoliday(int $year, DateTime $expected): void { @@ -60,7 +57,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -75,7 +72,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Hungary/StateFoundationDayTest.php b/tests/Hungary/StateFoundationDayTest.php index 50aff2bdd..8cc745393 100644 --- a/tests/Hungary/StateFoundationDayTest.php +++ b/tests/Hungary/StateFoundationDayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -40,7 +39,6 @@ class StateFoundationDayTest extends HungaryBaseTestCase implements HolidayTestC * Tests the holiday defined in this test on or after establishment. * * @throws Exception - * @throws ReflectionException */ public function testHolidayOnAfterEstablishment(): void { @@ -56,7 +54,7 @@ public function testHolidayOnAfterEstablishment(): void /** * Tests the holiday defined in this test before establishment. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayBeforeEstablishment(): void { @@ -70,7 +68,7 @@ public function testHolidayBeforeEstablishment(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -85,7 +83,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Ireland/AugustHolidayTest.php b/tests/Ireland/AugustHolidayTest.php index d3d8e89ae..bbbe28e77 100644 --- a/tests/Ireland/AugustHolidayTest.php +++ b/tests/Ireland/AugustHolidayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -39,7 +38,6 @@ class AugustHolidayTest extends IrelandBaseTestCase implements HolidayTestCase * @param int $year the year for which the holiday defined in this test needs to be tested * @param string $expected the expected date * - * @throws ReflectionException * @throws Exception */ public function testHoliday(int $year, string $expected): void @@ -77,7 +75,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -98,7 +96,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Ireland/ChristmasDayTest.php b/tests/Ireland/ChristmasDayTest.php index fbacaa90e..fd577c0f9 100644 --- a/tests/Ireland/ChristmasDayTest.php +++ b/tests/Ireland/ChristmasDayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -39,7 +38,6 @@ class ChristmasDayTest extends IrelandBaseTestCase implements HolidayTestCase * @param int $year the year for which the holiday defined in this test needs to be tested * @param string $expected the expected date * - * @throws ReflectionException * @throws Exception */ public function testHoliday(int $year, string $expected): void @@ -76,7 +74,7 @@ public function HolidayDataProvider(): array /** * Tests translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -97,7 +95,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Ireland/EasterMondayTest.php b/tests/Ireland/EasterMondayTest.php index 288c3a5a2..235b699dd 100644 --- a/tests/Ireland/EasterMondayTest.php +++ b/tests/Ireland/EasterMondayTest.php @@ -18,7 +18,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -40,7 +39,6 @@ class EasterMondayTest extends IrelandBaseTestCase implements HolidayTestCase * @param int $year the year for which the holiday defined in this test needs to be tested * @param string $expected the expected date * - * @throws ReflectionException * @throws Exception */ public function testHoliday(int $year, string $expected): void @@ -78,7 +76,7 @@ public function HolidayDataProvider(): array /** * Tests translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -99,7 +97,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Ireland/EasterTest.php b/tests/Ireland/EasterTest.php index d67e648cc..c0c235a53 100644 --- a/tests/Ireland/EasterTest.php +++ b/tests/Ireland/EasterTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -39,7 +38,6 @@ class EasterTest extends IrelandBaseTestCase implements HolidayTestCase * @param int $year the year for which the holiday defined in this test needs to be tested * @param string $expected the expected date * - * @throws ReflectionException * @throws Exception */ public function testHoliday(int $year, string $expected): void @@ -76,7 +74,7 @@ public function HolidayDataProvider(): array /** * Tests translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -97,7 +95,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Ireland/GoodFridayTest.php b/tests/Ireland/GoodFridayTest.php index ea83651b8..95e4adc4a 100644 --- a/tests/Ireland/GoodFridayTest.php +++ b/tests/Ireland/GoodFridayTest.php @@ -18,7 +18,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -40,7 +39,6 @@ class GoodFridayTest extends IrelandBaseTestCase implements HolidayTestCase * @param int $year the year for which the holiday defined in this test needs to be tested * @param string $expected the expected date * - * @throws ReflectionException * @throws Exception */ public function testHoliday(int $year, string $expected): void @@ -77,7 +75,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -98,7 +96,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Ireland/IrelandTest.php b/tests/Ireland/IrelandTest.php index dd9787043..0fe62a448 100644 --- a/tests/Ireland/IrelandTest.php +++ b/tests/Ireland/IrelandTest.php @@ -30,6 +30,8 @@ class IrelandTest extends IrelandBaseTestCase implements ProviderTestCase /** * Initial setup of this Test Case. + * + * @throws \Exception */ protected function setUp(): void { @@ -38,8 +40,6 @@ protected function setUp(): void /** * Tests if all official holidays in Ireland are defined by the provider class. - * - * @throws ReflectionException */ public function testOfficialHolidays(): void { @@ -70,8 +70,6 @@ public function testOfficialHolidays(): void /** * Tests if all observed holidays in Ireland are defined by the provider class. - * - * @throws ReflectionException */ public function testObservedHolidays(): void { @@ -80,8 +78,6 @@ public function testObservedHolidays(): void /** * Tests if all seasonal holidays in Ireland are defined by the provider class. - * - * @throws ReflectionException */ public function testSeasonalHolidays(): void { @@ -90,8 +86,6 @@ public function testSeasonalHolidays(): void /** * Tests if all bank holidays in Ireland are defined by the provider class. - * - * @throws ReflectionException */ public function testBankHolidays(): void { @@ -100,8 +94,6 @@ public function testBankHolidays(): void /** * Tests if all other holidays in Ireland are defined by the provider class. - * - * @throws ReflectionException */ public function testOtherHolidays(): void { @@ -110,6 +102,7 @@ public function testOtherHolidays(): void /** * @throws ReflectionException + * @throws \Exception */ public function testSources(): void { diff --git a/tests/Ireland/JuneHolidayTest.php b/tests/Ireland/JuneHolidayTest.php index 53dd8cd30..1e8e0d216 100644 --- a/tests/Ireland/JuneHolidayTest.php +++ b/tests/Ireland/JuneHolidayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -44,7 +43,6 @@ class JuneHolidayTest extends IrelandBaseTestCase implements HolidayTestCase * @param int $year the year for which the holiday defined in this test needs to be tested * @param string $expected the expected date * - * @throws ReflectionException * @throws Exception */ public function testHoliday(int $year, string $expected): void @@ -82,7 +80,7 @@ public function HolidayDataProvider(): array /** * Tests the holiday defined in this test before establishment. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayBeforeEstablishment(): void { @@ -96,7 +94,7 @@ public function testHolidayBeforeEstablishment(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -117,7 +115,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Ireland/MayDayTest.php b/tests/Ireland/MayDayTest.php index 71e553a1a..90b8cb541 100644 --- a/tests/Ireland/MayDayTest.php +++ b/tests/Ireland/MayDayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -44,7 +43,6 @@ class MayDayTest extends IrelandBaseTestCase implements HolidayTestCase * @param int $year the year for which the holiday defined in this test needs to be tested * @param string $expected the expected date * - * @throws ReflectionException * @throws Exception */ public function testHoliday(int $year, string $expected): void @@ -82,7 +80,7 @@ public function HolidayDataProvider(): array /** * Tests the holiday defined in this test before establishment. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayBeforeEstablishment(): void { @@ -96,7 +94,7 @@ public function testHolidayBeforeEstablishment(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -117,7 +115,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Ireland/NewYearsDayTest.php b/tests/Ireland/NewYearsDayTest.php index c1c22ae78..7c33d94af 100644 --- a/tests/Ireland/NewYearsDayTest.php +++ b/tests/Ireland/NewYearsDayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -44,7 +43,6 @@ class NewYearsDayTest extends IrelandBaseTestCase implements HolidayTestCase * @param int $year the year for which the holiday defined in this test needs to be tested * @param string $expected the expected date * - * @throws ReflectionException * @throws Exception */ public function testHoliday(int $year, string $expected): void @@ -81,7 +79,7 @@ public function HolidayDataProvider(): array /** * Tests the holiday defined in this test before establishment. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayBeforeEstablishment(): void { @@ -95,7 +93,7 @@ public function testHolidayBeforeEstablishment(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -116,7 +114,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Ireland/OctoberHolidayTest.php b/tests/Ireland/OctoberHolidayTest.php index f5eaaa55a..a210e335c 100644 --- a/tests/Ireland/OctoberHolidayTest.php +++ b/tests/Ireland/OctoberHolidayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -44,7 +43,6 @@ class OctoberHolidayTest extends IrelandBaseTestCase implements HolidayTestCase * @param int $year the year for which the holiday defined in this test needs to be tested * @param string $expected the expected date * - * @throws ReflectionException * @throws Exception */ public function testHoliday(int $year, string $expected): void @@ -82,7 +80,7 @@ public function HolidayDataProvider(): array /** * Tests the holiday defined in this test before establishment. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayBeforeEstablishment(): void { @@ -96,7 +94,7 @@ public function testHolidayBeforeEstablishment(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -117,7 +115,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Ireland/PentecostTest.php b/tests/Ireland/PentecostTest.php index 5ff81dbc4..60a2c311a 100644 --- a/tests/Ireland/PentecostTest.php +++ b/tests/Ireland/PentecostTest.php @@ -18,7 +18,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -40,7 +39,6 @@ class PentecostTest extends IrelandBaseTestCase implements HolidayTestCase * @param int $year the year for which the holiday defined in this test needs to be tested * @param string $expected the expected date * - * @throws ReflectionException * @throws Exception */ public function testHoliday(int $year, string $expected): void @@ -78,7 +76,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -99,7 +97,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Ireland/StPatricksDayTest.php b/tests/Ireland/StPatricksDayTest.php index 24cca4d57..0ad3e91cb 100644 --- a/tests/Ireland/StPatricksDayTest.php +++ b/tests/Ireland/StPatricksDayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -44,7 +43,6 @@ class StPatricksDayTest extends IrelandBaseTestCase implements HolidayTestCase * @param int $year the year for which the holiday defined in this test needs to be tested * @param string $expected the expected date * - * @throws ReflectionException * @throws Exception */ public function testHoliday(int $year, string $expected): void @@ -81,7 +79,7 @@ public function HolidayDataProvider(): array /** * Tests the holiday defined in this test before establishment. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayBeforeEstablishment(): void { @@ -95,7 +93,7 @@ public function testHolidayBeforeEstablishment(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -116,7 +114,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Ireland/StStephensDayTest.php b/tests/Ireland/StStephensDayTest.php index dc654abce..b0f10b88f 100644 --- a/tests/Ireland/StStephensDayTest.php +++ b/tests/Ireland/StStephensDayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -39,7 +38,6 @@ class StStephensDayTest extends IrelandBaseTestCase implements HolidayTestCase * @param int $year the year for which the holiday defined in this test needs to be tested * @param string $expected the expected date * - * @throws ReflectionException * @throws Exception */ public function testHoliday(int $year, string $expected): void @@ -76,7 +74,7 @@ public function HolidayDataProvider(): array /** * Tests translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -97,7 +95,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Ireland/pentecostMondayTest.php b/tests/Ireland/pentecostMondayTest.php index 5a859f746..f1028a971 100644 --- a/tests/Ireland/pentecostMondayTest.php +++ b/tests/Ireland/pentecostMondayTest.php @@ -18,7 +18,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -45,7 +44,6 @@ class pentecostMondayTest extends IrelandBaseTestCase implements HolidayTestCase * @param int $year the year for which the holiday defined in this test needs to be tested * @param string $expected the expected date * - * @throws ReflectionException * @throws Exception */ public function testHoliday(int $year, string $expected): void @@ -82,7 +80,7 @@ public function HolidayDataProvider(): array /** * Tests the holiday defined in this test after abolishment. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayDayAfterAbolishment(): void { @@ -92,7 +90,7 @@ public function testHolidayDayAfterAbolishment(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -113,7 +111,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Italy/AllSaintsDayTest.php b/tests/Italy/AllSaintsDayTest.php index 2a67908b3..4442a07e2 100644 --- a/tests/Italy/AllSaintsDayTest.php +++ b/tests/Italy/AllSaintsDayTest.php @@ -16,7 +16,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -37,8 +36,6 @@ class AllSaintsDayTest extends ItalyBaseTestCase implements HolidayTestCase * * @param int $year the year for which All Saints' Day needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testAssumptionOfMary(int $year, DateTime $expected): void { @@ -60,7 +57,7 @@ public function AllSaintsDayDataProvider(): array /** * Tests translated name of All Saints' Day. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -75,7 +72,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Italy/AssumptionOfMaryTest.php b/tests/Italy/AssumptionOfMaryTest.php index 74c5e1558..e2143675d 100644 --- a/tests/Italy/AssumptionOfMaryTest.php +++ b/tests/Italy/AssumptionOfMaryTest.php @@ -16,7 +16,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -37,8 +36,6 @@ class AssumptionOfMaryTest extends ItalyBaseTestCase implements HolidayTestCase * * @param int $year the year for which the day of the Assumption of Mary needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testAssumptionOfMary(int $year, DateTime $expected): void { @@ -60,7 +57,7 @@ public function AssumptionOfMaryDataProvider(): array /** * Tests translated name of the Assumption of Mary. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -75,7 +72,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Italy/ChristmasTest.php b/tests/Italy/ChristmasTest.php index cf365feac..3c52d4f41 100644 --- a/tests/Italy/ChristmasTest.php +++ b/tests/Italy/ChristmasTest.php @@ -16,7 +16,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -37,8 +36,6 @@ class ChristmasTest extends ItalyBaseTestCase implements HolidayTestCase * * @param int $year the year for which Christmas Day needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testChristmasDay(int $year, DateTime $expected): void { @@ -60,7 +57,7 @@ public function ChristmasDayDataProvider(): array /** * Tests translated name of Christmas Day. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -75,7 +72,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Italy/EasterMondayTest.php b/tests/Italy/EasterMondayTest.php index 96ee4fdf1..8ccd7e6f5 100644 --- a/tests/Italy/EasterMondayTest.php +++ b/tests/Italy/EasterMondayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -35,7 +34,6 @@ class EasterMondayTest extends ItalyBaseTestCase implements HolidayTestCase * Tests the holiday defined in this test. * * @throws Exception - * @throws ReflectionException */ public function testHoliday(): void { @@ -51,7 +49,7 @@ public function testHoliday(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -66,7 +64,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Italy/EasterTest.php b/tests/Italy/EasterTest.php index 9b3780730..7a7e9887f 100644 --- a/tests/Italy/EasterTest.php +++ b/tests/Italy/EasterTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -35,7 +34,6 @@ class EasterTest extends ItalyBaseTestCase implements HolidayTestCase * Tests Easter. * * @throws Exception - * @throws ReflectionException */ public function testEaster(): void { @@ -51,7 +49,7 @@ public function testEaster(): void /** * Tests translated name of Easter. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -66,7 +64,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Italy/EpiphanyTest.php b/tests/Italy/EpiphanyTest.php index b5bec4d86..1810d0382 100644 --- a/tests/Italy/EpiphanyTest.php +++ b/tests/Italy/EpiphanyTest.php @@ -16,7 +16,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -37,8 +36,6 @@ class EpiphanyTest extends ItalyBaseTestCase implements HolidayTestCase * * @param int $year the year for which Epiphany needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testEpiphany(int $year, DateTime $expected): void { @@ -60,7 +57,7 @@ public function EpiphanyDataProvider(): array /** * Tests translated name of Epiphany. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -75,7 +72,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Italy/ImmaculateConceptionTest.php b/tests/Italy/ImmaculateConceptionTest.php index 735d0f3ca..8f6a68e51 100644 --- a/tests/Italy/ImmaculateConceptionTest.php +++ b/tests/Italy/ImmaculateConceptionTest.php @@ -16,7 +16,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -37,8 +36,6 @@ class ImmaculateConceptionTest extends ItalyBaseTestCase implements HolidayTestC * * @param int $year the year for which the day of Immaculate Conception needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testImmaculateConception(int $year, DateTime $expected): void { @@ -60,7 +57,7 @@ public function ImmaculateConceptionDataProvider(): array /** * Tests translated name of the day of Immaculate Conception. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -75,7 +72,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Italy/InternationalWorkersDayTest.php b/tests/Italy/InternationalWorkersDayTest.php index aedfeb4f3..87ccf3a45 100644 --- a/tests/Italy/InternationalWorkersDayTest.php +++ b/tests/Italy/InternationalWorkersDayTest.php @@ -16,7 +16,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -37,8 +36,6 @@ class InternationalWorkersDayTest extends ItalyBaseTestCase implements HolidayTe * * @param int $year the year for which International Workers' Day needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testInternationalWorkersDay(int $year, DateTime $expected): void { @@ -60,7 +57,7 @@ public function InternationalWorkersDayDataProvider(): array /** * Tests translated name of International Workers' Day. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -75,7 +72,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Italy/ItalyTest.php b/tests/Italy/ItalyTest.php index 5f17253e9..30d7a5632 100644 --- a/tests/Italy/ItalyTest.php +++ b/tests/Italy/ItalyTest.php @@ -30,6 +30,8 @@ class ItalyTest extends ItalyBaseTestCase implements ProviderTestCase /** * Initial setup of this Test Case. + * + * @throws \Exception */ protected function setUp(): void { @@ -38,8 +40,6 @@ protected function setUp(): void /** * Tests if all official holidays in Italy are defined by the provider class. - * - * @throws ReflectionException */ public function testOfficialHolidays(): void { @@ -61,8 +61,6 @@ public function testOfficialHolidays(): void /** * Tests if all observed holidays in Italy are defined by the provider class. - * - * @throws ReflectionException */ public function testObservedHolidays(): void { @@ -71,8 +69,6 @@ public function testObservedHolidays(): void /** * Tests if all seasonal holidays in Italy are defined by the provider class. - * - * @throws ReflectionException */ public function testSeasonalHolidays(): void { @@ -81,8 +77,6 @@ public function testSeasonalHolidays(): void /** * Tests if all bank holidays in Italy are defined by the provider class. - * - * @throws ReflectionException */ public function testBankHolidays(): void { @@ -91,8 +85,6 @@ public function testBankHolidays(): void /** * Tests if all other holidays in Italy are defined by the provider class. - * - * @throws ReflectionException */ public function testOtherHolidays(): void { @@ -101,6 +93,7 @@ public function testOtherHolidays(): void /** * @throws ReflectionException + * @throws \Exception */ public function testSources(): void { diff --git a/tests/Italy/LiberationDayTest.php b/tests/Italy/LiberationDayTest.php index 7d4845fdf..626aedf22 100644 --- a/tests/Italy/LiberationDayTest.php +++ b/tests/Italy/LiberationDayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -47,7 +46,6 @@ class LiberationDayTest extends ItalyBaseTestCase implements HolidayTestCase * Tests Liberation Day on or after 1949. * * @throws Exception - * @throws ReflectionException */ public function testLiberationDayOnAfter1949(): void { @@ -63,7 +61,7 @@ public function testLiberationDayOnAfter1949(): void /** * Tests Liberation Day before 1949. * - * @throws ReflectionException + * @throws Exception */ public function testLiberationDayBefore1949(): void { @@ -77,7 +75,7 @@ public function testLiberationDayBefore1949(): void /** * Tests translated name of Liberation Day. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -92,7 +90,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Italy/NewYearsDayTest.php b/tests/Italy/NewYearsDayTest.php index 5e1875602..19d15c69e 100644 --- a/tests/Italy/NewYearsDayTest.php +++ b/tests/Italy/NewYearsDayTest.php @@ -16,7 +16,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -37,8 +36,6 @@ class NewYearsDayTest extends ItalyBaseTestCase implements HolidayTestCase * * @param int $year the year for which New Years Day needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testNewYearsDay(int $year, DateTime $expected): void { @@ -60,7 +57,7 @@ public function NewYearsDayDataProvider(): array /** * Tests translated name of New Years Day. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -75,7 +72,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Italy/RepublicDayTest.php b/tests/Italy/RepublicDayTest.php index 859bd5d75..91fda23f2 100644 --- a/tests/Italy/RepublicDayTest.php +++ b/tests/Italy/RepublicDayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -47,7 +46,6 @@ class RepublicDayTest extends ItalyBaseTestCase implements HolidayTestCase * Tests Republic Day on or after 1946. * * @throws Exception - * @throws ReflectionException */ public function testRepublicDayOnAfter1946(): void { @@ -63,7 +61,7 @@ public function testRepublicDayOnAfter1946(): void /** * Tests Republic Day before 1946. * - * @throws ReflectionException + * @throws Exception */ public function testRepublicDayBefore1946(): void { @@ -77,7 +75,7 @@ public function testRepublicDayBefore1946(): void /** * Tests translated name of Republic Day. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -92,7 +90,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Italy/stStephensDayTest.php b/tests/Italy/stStephensDayTest.php index 83fe92e53..8e5e62a23 100644 --- a/tests/Italy/stStephensDayTest.php +++ b/tests/Italy/stStephensDayTest.php @@ -16,7 +16,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -37,8 +36,6 @@ class stStephensDayTest extends ItalyBaseTestCase implements HolidayTestCase * * @param int $year the year for which St. Stephen's Day needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function teststStephensDay(int $year, DateTime $expected): void { @@ -60,7 +57,7 @@ public function stStephensDayDataProvider(): array /** * Tests translated name of St. Stephen's Day. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -75,7 +72,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Japan/AutumnalEquinoxDayTest.php b/tests/Japan/AutumnalEquinoxDayTest.php index d1931c739..29fca97ed 100644 --- a/tests/Japan/AutumnalEquinoxDayTest.php +++ b/tests/Japan/AutumnalEquinoxDayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -43,7 +42,7 @@ class AutumnalEquinoxDayTest extends JapanBaseTestCase implements HolidayTestCas * * After 2150 no calculations are available yet. * - * @throws ReflectionException + * @throws Exception */ public function testAutumnalEquinoxDayOnAfter2150(): void { @@ -63,7 +62,6 @@ public function testAutumnalEquinoxDayOnAfter2150(): void * @param int $month month (number) of example data to be tested * @param int $day day of the month (number) of example data to be tested * - * @throws ReflectionException * @throws Exception */ public function testAutumnalEquinoxDayBetween1948And2150(int $year, int $month, int $day): void @@ -97,7 +95,7 @@ public function autumnalEquinoxHolidaysProvider(): array * one's ancestors and remember the dead. Prior to 1948, the autumnal equinox was an imperial ancestor worship * festival called Shūki kōrei-sai (秋季皇霊祭). * - * @throws ReflectionException + * @throws Exception */ public function testAutumnalEquinoxDayBefore1948(): void { @@ -111,7 +109,7 @@ public function testAutumnalEquinoxDayBefore1948(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -126,7 +124,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Japan/ChildrensDayTest.php b/tests/Japan/ChildrensDayTest.php index e5f4aef89..b99c04bda 100644 --- a/tests/Japan/ChildrensDayTest.php +++ b/tests/Japan/ChildrensDayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -40,7 +39,6 @@ class ChildrensDayTest extends JapanBaseTestCase implements HolidayTestCase * Tests Children's Day after 1948. Children's Day was established after 1948. * * @throws Exception - * @throws ReflectionException */ public function testChildrensDayOnAfter1948(): void { @@ -57,7 +55,6 @@ public function testChildrensDayOnAfter1948(): void * Tests Children's Day after 1948 substituted next working day (when Children's Day falls on a Sunday). * * @throws Exception - * @throws ReflectionException */ public function testChildrensDayOnAfter1948SubstitutedNextWorkingDay(): void { @@ -73,7 +70,7 @@ public function testChildrensDayOnAfter1948SubstitutedNextWorkingDay(): void /** * Tests Children's Day before 1948. Children's Day was established after 1948. * - * @throws ReflectionException + * @throws Exception */ public function testChildrensDayBefore1948(): void { @@ -87,7 +84,7 @@ public function testChildrensDayBefore1948(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -102,7 +99,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Japan/ComingOfAgeDayTest.php b/tests/Japan/ComingOfAgeDayTest.php index 5fe9295e0..717a07c04 100644 --- a/tests/Japan/ComingOfAgeDayTest.php +++ b/tests/Japan/ComingOfAgeDayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -41,7 +40,6 @@ class ComingOfAgeDayTest extends JapanBaseTestCase implements HolidayTestCase * was changed to be the second monday of January. * * @throws Exception - * @throws ReflectionException */ public function testComingOfAgeDayOnAfter2000(): void { @@ -59,7 +57,6 @@ public function testComingOfAgeDayOnAfter2000(): void * After 2000 it was changed to be the second monday of January. * * @throws Exception - * @throws ReflectionException */ public function testComingOfAgeDayBetween1948And2000(): void { @@ -76,7 +73,7 @@ public function testComingOfAgeDayBetween1948And2000(): void * Tests Coming of Age Day before 1948. Coming of Age Day was established after 1948 on January 15th. After 2000 it * was changed to be the second monday of January. * - * @throws ReflectionException + * @throws Exception */ public function testConstitutionMemorialDayBefore1948(): void { @@ -90,7 +87,7 @@ public function testConstitutionMemorialDayBefore1948(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -105,7 +102,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Japan/ConstitutionMemorialDayTest.php b/tests/Japan/ConstitutionMemorialDayTest.php index 37bb00c3a..7f8601adf 100644 --- a/tests/Japan/ConstitutionMemorialDayTest.php +++ b/tests/Japan/ConstitutionMemorialDayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -40,7 +39,6 @@ class ConstitutionMemorialDayTest extends JapanBaseTestCase implements HolidayTe * Tests Constitution Memorial Day after 1948. Constitution Memorial Day was established after 1948. * * @throws Exception - * @throws ReflectionException */ public function testConstitutionMemorialDayOnAfter1948(): void { @@ -58,7 +56,6 @@ public function testConstitutionMemorialDayOnAfter1948(): void * a Sunday). * * @throws Exception - * @throws ReflectionException */ public function testConstitutionMemorialDayOnAfter1948SubstitutedNextWorkingDay(): void { @@ -74,7 +71,7 @@ public function testConstitutionMemorialDayOnAfter1948SubstitutedNextWorkingDay( /** * Tests Constitution Memorial Day before 1948. Constitution Memorial Day was established after 1948. * - * @throws ReflectionException + * @throws Exception */ public function testConstitutionMemorialDayBefore1948(): void { @@ -88,7 +85,7 @@ public function testConstitutionMemorialDayBefore1948(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -103,7 +100,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Japan/CoronationDayTest.php b/tests/Japan/CoronationDayTest.php index d3f1a05c6..4c007674d 100644 --- a/tests/Japan/CoronationDayTest.php +++ b/tests/Japan/CoronationDayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -38,7 +37,6 @@ class CoronationDayTest extends JapanBaseTestCase implements HolidayTestCase /** * @throws Exception - * @throws ReflectionException */ public function testEmperorsCoronationDay(): void { @@ -51,7 +49,7 @@ public function testEmperorsCoronationDay(): void } /** - * @throws ReflectionException + * @throws Exception */ public function testEmperorsBirthdayBefore2019(): void { @@ -63,7 +61,7 @@ public function testEmperorsBirthdayBefore2019(): void } /** - * @throws ReflectionException + * @throws Exception */ public function testEmperorsBirthdayAfter2020(): void { @@ -76,8 +74,6 @@ public function testEmperorsBirthdayAfter2020(): void /** * Tests the translated name of the holiday defined in this test. - * - * @throws ReflectionException */ public function testTranslation(): void { @@ -91,8 +87,6 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. - * - * @throws ReflectionException */ public function testHolidayType(): void { diff --git a/tests/Japan/CultureDayTest.php b/tests/Japan/CultureDayTest.php index c068223cb..150c29e9f 100644 --- a/tests/Japan/CultureDayTest.php +++ b/tests/Japan/CultureDayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -40,7 +39,6 @@ class CultureDayTest extends JapanBaseTestCase implements HolidayTestCase * Tests Culture Day after 1948. Culture Day Day was established after 1948. * * @throws Exception - * @throws ReflectionException */ public function testCultureDayOnAfter1948(): void { @@ -57,7 +55,6 @@ public function testCultureDayOnAfter1948(): void * Tests Culture Day after 1948 substituted next working day (when Culture Day falls on a Sunday). * * @throws Exception - * @throws ReflectionException */ public function testCultureDayOnAfter1948SubstitutedNextWorkingDay(): void { @@ -73,7 +70,7 @@ public function testCultureDayOnAfter1948SubstitutedNextWorkingDay(): void /** * Tests Culture Day before 1948. Culture Day was established after 1948. * - * @throws ReflectionException + * @throws Exception */ public function testCultureDayBefore1948(): void { @@ -87,7 +84,7 @@ public function testCultureDayBefore1948(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -102,7 +99,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Japan/EmperorsBirthdayTest.php b/tests/Japan/EmperorsBirthdayTest.php index 3791aa770..da34dbad5 100644 --- a/tests/Japan/EmperorsBirthdayTest.php +++ b/tests/Japan/EmperorsBirthdayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -42,7 +41,6 @@ class EmperorsBirthdayTest extends JapanBaseTestCase implements HolidayTestCase * 1949. * * @throws Exception - * @throws ReflectionException */ public function testEmperorsBirthdayOnAfter1949(): void { @@ -61,7 +59,6 @@ public function testEmperorsBirthdayOnAfter1949(): void * Day". * * @throws Exception - * @throws ReflectionException */ public function testEmperorsBirthdayOnAfter1989(): void { @@ -79,7 +76,6 @@ public function testEmperorsBirthdayOnAfter1989(): void * 2020. * * @throws Exception - * @throws ReflectionException */ public function testEmperorsBirthdayOnAfter2020(): void { @@ -97,7 +93,6 @@ public function testEmperorsBirthdayOnAfter2020(): void * Sunday). * * @throws Exception - * @throws ReflectionException */ public function testEmperorsBirthdayOnAfter1989SubstitutedNextWorkingDay(): void { @@ -115,7 +110,7 @@ public function testEmperorsBirthdayOnAfter1989SubstitutedNextWorkingDay(): void * 1989. Prior to the death of Emperor Hirohito in 1989, this holiday was celebrated on April 29. See also "Shōwa * Day"/"Greenery Day". * - * @throws ReflectionException + * @throws Exception */ public function testEmperorsBirthdayBefore1989(): void { @@ -128,8 +123,6 @@ public function testEmperorsBirthdayBefore1989(): void /** * Tests the Emperors Birthday at 2019. - * - * @throws ReflectionException */ public function testEmperorsBirthdayAt2019(): void { @@ -143,7 +136,7 @@ public function testEmperorsBirthdayAt2019(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -158,7 +151,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Japan/EnthronementProclamationCeremonyTest.php b/tests/Japan/EnthronementProclamationCeremonyTest.php index 7ab798f3c..412ac45cb 100644 --- a/tests/Japan/EnthronementProclamationCeremonyTest.php +++ b/tests/Japan/EnthronementProclamationCeremonyTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -38,7 +37,6 @@ class EnthronementProclamationCeremonyTest extends JapanBaseTestCase implements /** * @throws Exception - * @throws ReflectionException */ public function testEmperorsCoronationDay(): void { @@ -51,7 +49,7 @@ public function testEmperorsCoronationDay(): void } /** - * @throws ReflectionException + * @throws Exception */ public function testEmperorsBirthdayBefore2019(): void { @@ -63,7 +61,7 @@ public function testEmperorsBirthdayBefore2019(): void } /** - * @throws ReflectionException + * @throws Exception */ public function testEmperorsBirthdayAfter2020(): void { @@ -76,8 +74,6 @@ public function testEmperorsBirthdayAfter2020(): void /** * Tests the translated name of the holiday defined in this test. - * - * @throws ReflectionException */ public function testTranslation(): void { @@ -91,8 +87,6 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. - * - * @throws ReflectionException */ public function testHolidayType(): void { diff --git a/tests/Japan/GreeneryDayTest.php b/tests/Japan/GreeneryDayTest.php index 55158feff..6ae952511 100644 --- a/tests/Japan/GreeneryDayTest.php +++ b/tests/Japan/GreeneryDayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -41,7 +40,6 @@ class GreeneryDayTest extends JapanBaseTestCase implements HolidayTestCase * it was changed to be May 4th. * * @throws Exception - * @throws ReflectionException */ public function testHolidayOnAfter2007(): void { @@ -58,7 +56,6 @@ public function testHolidayOnAfter2007(): void * Tests Greenery Day after 2007 substituted next working day (when Greenery Day falls on a Sunday). * * @throws Exception - * @throws ReflectionException */ public function testHolidayOnAfter2007SubstitutedNextWorkingDay(): void { @@ -76,7 +73,6 @@ public function testHolidayOnAfter2007SubstitutedNextWorkingDay(): void * it was changed to be May 4th. * * @throws Exception - * @throws ReflectionException */ public function testHolidayBetween1989And2007(): void { @@ -93,7 +89,6 @@ public function testHolidayBetween1989And2007(): void * Tests Greenery Day between 1989 and 2007 substituted next working day (when Greenery Day falls on a Sunday). * * @throws Exception - * @throws ReflectionException */ public function testHolidayBetween1989And2007SubstitutedNextWorkingDay(): void { @@ -110,7 +105,7 @@ public function testHolidayBetween1989And2007SubstitutedNextWorkingDay(): void * Tests Greenery Day before 1989. Greenery Day was established from 1989 on April 29th. After 2007 * it was changed to be May 4th. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayBefore1989(): void { @@ -124,7 +119,7 @@ public function testHolidayBefore1989(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -139,7 +134,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Japan/JapanTest.php b/tests/Japan/JapanTest.php index ec22e3eeb..d10a1b223 100644 --- a/tests/Japan/JapanTest.php +++ b/tests/Japan/JapanTest.php @@ -30,6 +30,8 @@ class JapanTest extends JapanBaseTestCase implements ProviderTestCase /** * Initial setup of this Test Case. + * + * @throws \Exception */ protected function setUp(): void { @@ -38,8 +40,6 @@ protected function setUp(): void /** * Tests if all official holidays in Japan are defined by the provider class. - * - * @throws ReflectionException */ public function testOfficialHolidays(): void { @@ -65,8 +65,6 @@ public function testOfficialHolidays(): void /** * Tests if all official holidays in Japan At 2019 are defined by the provider class. - * - * @throws ReflectionException */ public function testOfficialHolidaysAt2019(): void { @@ -93,8 +91,6 @@ public function testOfficialHolidaysAt2019(): void /** * Tests if all observed holidays in Japan are defined by the provider class. - * - * @throws ReflectionException */ public function testObservedHolidays(): void { @@ -103,8 +99,6 @@ public function testObservedHolidays(): void /** * Tests if all seasonal holidays in Japan are defined by the provider class. - * - * @throws ReflectionException */ public function testSeasonalHolidays(): void { @@ -113,8 +107,6 @@ public function testSeasonalHolidays(): void /** * Tests if all bank holidays in Japan are defined by the provider class. - * - * @throws ReflectionException */ public function testBankHolidays(): void { @@ -123,8 +115,6 @@ public function testBankHolidays(): void /** * Tests if all other holidays in Japan are defined by the provider class. - * - * @throws ReflectionException */ public function testOtherHolidays(): void { @@ -133,6 +123,7 @@ public function testOtherHolidays(): void /** * @throws ReflectionException + * @throws \Exception */ public function testSources(): void { diff --git a/tests/Japan/LabourThanksgivingDayTest.php b/tests/Japan/LabourThanksgivingDayTest.php index 2f3183bdc..34f7dc716 100644 --- a/tests/Japan/LabourThanksgivingDayTest.php +++ b/tests/Japan/LabourThanksgivingDayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -41,7 +40,6 @@ class LabourThanksgivingDayTest extends JapanBaseTestCase implements HolidayTest * 1948. * * @throws Exception - * @throws ReflectionException */ public function testLabourThanksgivingDayOnAfter1948(): void { @@ -59,7 +57,6 @@ public function testLabourThanksgivingDayOnAfter1948(): void * Sunday). * * @throws Exception - * @throws ReflectionException */ public function testLabourThanksgivingDayOnAfter1948SubstitutedNextWorkingDay(): void { @@ -76,7 +73,7 @@ public function testLabourThanksgivingDayOnAfter1948SubstitutedNextWorkingDay(): * Tests Labor Thanksgiving Day before 1948. Labor Thanksgiving Day is held on November 23rd and established since * 1948. * - * @throws ReflectionException + * @throws Exception */ public function testLabourThanksgivingDayBefore1948(): void { @@ -90,7 +87,7 @@ public function testLabourThanksgivingDayBefore1948(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -105,7 +102,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Japan/MarineDayTest.php b/tests/Japan/MarineDayTest.php index c1c11ed1e..1f22f8b82 100644 --- a/tests/Japan/MarineDayTest.php +++ b/tests/Japan/MarineDayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -40,7 +39,6 @@ class MarineDayTest extends JapanBaseTestCase implements HolidayTestCase * Tests Marine Day in 2021. Marine Day in 2021 is July 22th for rescheduled Olympic Games after COVID-19. * * @throws Exception - * @throws ReflectionException */ public function testMarineDayIn2021(): void { @@ -58,7 +56,6 @@ public function testMarineDayIn2021(): void * to be the third monday of July. * * @throws Exception - * @throws ReflectionException */ public function testMarineDayOnAfter2003(): void { @@ -81,7 +78,6 @@ public function testMarineDayOnAfter2003(): void * changed to be the third monday of July. * * @throws Exception - * @throws ReflectionException */ public function testMarineDayBetween1996And2003(): void { @@ -98,7 +94,6 @@ public function testMarineDayBetween1996And2003(): void * Tests Marine Day between 1996 and 2003 substituted next working day (when Marine Day falls on a Sunday). * * @throws Exception - * @throws ReflectionException */ public function testMarineDayBetween1996And2003SubstitutedNextWorkingDay(): void { @@ -115,7 +110,7 @@ public function testMarineDayBetween1996And2003SubstitutedNextWorkingDay(): void * Tests Marine Day before 1996. Marine Day was established since 1996 on July 20th. After 2003 it was changed * to be the third monday of July. * - * @throws ReflectionException + * @throws Exception */ public function testMarineDayBefore1996(): void { @@ -129,7 +124,7 @@ public function testMarineDayBefore1996(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -144,7 +139,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Japan/MountainDayTest.php b/tests/Japan/MountainDayTest.php index 302298864..4f29af8e5 100644 --- a/tests/Japan/MountainDayTest.php +++ b/tests/Japan/MountainDayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -40,7 +39,6 @@ class MountainDayTest extends JapanBaseTestCase implements HolidayTestCase * Tests Mountain Day in 2021. Mountain Day in 2021 is August 8th for rescheduled Olympic Games after COVID-19. * * @throws Exception - * @throws ReflectionException */ public function testMountainDayIn2021(): void { @@ -57,7 +55,6 @@ public function testMountainDayIn2021(): void * Tests Mountain Day in 2020. Mountain Day in 2020 is August 10th for the Olympic Games. * * @throws Exception - * @throws ReflectionException */ public function testMountainDayIn2020(): void { @@ -74,7 +71,6 @@ public function testMountainDayIn2020(): void * Tests Mountain Day after 2016. Mountain Day was established in 2014 and is held from 2016 on August 11th. * * @throws Exception - * @throws ReflectionException */ public function testMountainDayOnAfter2016(): void { @@ -91,7 +87,6 @@ public function testMountainDayOnAfter2016(): void * Tests Mountain Day after 2016 substituted next working day (when Mountain Day falls on a Sunday). * * @throws Exception - * @throws ReflectionException */ public function testMountainDayOnAfter2016SubstitutedNextWorkingDay(): void { @@ -107,7 +102,7 @@ public function testMountainDayOnAfter2016SubstitutedNextWorkingDay(): void /** * Tests Mountain Day before 2016. Mountain Day was established in 2014 and is held from 2016 on August 11th. * - * @throws ReflectionException + * @throws Exception */ public function testMountainDayBefore2016(): void { @@ -121,7 +116,7 @@ public function testMountainDayBefore2016(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -136,7 +131,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Japan/NationalFoundationDayTest.php b/tests/Japan/NationalFoundationDayTest.php index 052d2f81f..d08e402b2 100644 --- a/tests/Japan/NationalFoundationDayTest.php +++ b/tests/Japan/NationalFoundationDayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -40,7 +39,6 @@ class NationalFoundationDayTest extends JapanBaseTestCase implements HolidayTest * Tests National Foundation Day after 1966. National Foundation day was established after 1966. * * @throws Exception - * @throws ReflectionException */ public function testNationalFoundationDayOnAfter1966(): void { @@ -58,7 +56,6 @@ public function testNationalFoundationDayOnAfter1966(): void * Sunday). * * @throws Exception - * @throws ReflectionException */ public function testNationalFoundationDayOnAfter1966SubstitutedNextWorkingDay(): void { @@ -74,7 +71,7 @@ public function testNationalFoundationDayOnAfter1966SubstitutedNextWorkingDay(): /** * Tests National Foundation Day before 1966. National Foundation day was established after 1966. * - * @throws ReflectionException + * @throws Exception */ public function testNationalFoundationDayBefore1966(): void { @@ -88,7 +85,7 @@ public function testNationalFoundationDayBefore1966(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -103,7 +100,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Japan/NewYearsDayTest.php b/tests/Japan/NewYearsDayTest.php index 5a7e19e8c..fbc815aff 100644 --- a/tests/Japan/NewYearsDayTest.php +++ b/tests/Japan/NewYearsDayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -40,7 +39,6 @@ class NewYearsDayTest extends JapanBaseTestCase implements HolidayTestCase * Tests New Years Day after 1948. New Years Day was established after 1948. * * @throws Exception - * @throws ReflectionException */ public function testNewYearsDayOnAfter1948(): void { @@ -57,7 +55,6 @@ public function testNewYearsDayOnAfter1948(): void * Tests New Years Day after 1948 substituted next working day (when New Years Day falls on a Sunday). * * @throws Exception - * @throws ReflectionException */ public function testNewYearsDayOnAfter1948SubstitutedNextWorkingDay(): void { @@ -73,7 +70,7 @@ public function testNewYearsDayOnAfter1948SubstitutedNextWorkingDay(): void /** * Tests New Years Day before 1948. New Years Day was established after 1948. * - * @throws ReflectionException + * @throws Exception */ public function testNewYearsDayBefore1948(): void { @@ -87,7 +84,7 @@ public function testNewYearsDayBefore1948(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -102,7 +99,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Japan/PublicBridgeDayTest.php b/tests/Japan/PublicBridgeDayTest.php index ae02cc53d..261481d7a 100644 --- a/tests/Japan/PublicBridgeDayTest.php +++ b/tests/Japan/PublicBridgeDayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -47,7 +46,6 @@ protected function setUp(): void * Tests public bridge days. * * @throws Exception - * @throws ReflectionException */ public function testPublicBridgeDay(): void { @@ -67,8 +65,6 @@ public function testPublicBridgeDay(): void /** * Tests the translated name of the holiday defined in this test. - * - * @throws ReflectionException */ public function testTranslation(): void { @@ -77,8 +73,6 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. - * - * @throws ReflectionException */ public function testHolidayType(): void { diff --git a/tests/Japan/RespectForTheAgedDayTest.php b/tests/Japan/RespectForTheAgedDayTest.php index bd3739435..3c98b810e 100644 --- a/tests/Japan/RespectForTheAgedDayTest.php +++ b/tests/Japan/RespectForTheAgedDayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -41,7 +40,6 @@ class RespectForTheAgedDayTest extends JapanBaseTestCase implements HolidayTestC * 15th. After 2003 it was changed to be the third monday of September. * * @throws Exception - * @throws ReflectionException */ public function testRespectForTheAgedDayOnAfter2003(): void { @@ -59,7 +57,6 @@ public function testRespectForTheAgedDayOnAfter2003(): void * September 15th. After 2003 it was changed to be the third monday of September. * * @throws Exception - * @throws ReflectionException */ public function testRespectForTheAgedDayBetween1996And2003(): void { @@ -77,7 +74,6 @@ public function testRespectForTheAgedDayBetween1996And2003(): void * falls on a Sunday). * * @throws Exception - * @throws ReflectionException */ public function testRespectForTheAgedDayBetween1996And2003SubstitutedNextWorkingDay(): void { @@ -94,7 +90,7 @@ public function testRespectForTheAgedDayBetween1996And2003SubstitutedNextWorking * Tests Respect for the Aged Day before 1996. Respect for the Aged Day was established since 1996 on September * 15th. After 2003 it was changed to be the third monday of September. * - * @throws ReflectionException + * @throws Exception */ public function testRespectForTheAgedDayBefore1996(): void { @@ -108,7 +104,7 @@ public function testRespectForTheAgedDayBefore1996(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -123,7 +119,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Japan/ShowaDayTest.php b/tests/Japan/ShowaDayTest.php index 251f03674..2c131bc75 100644 --- a/tests/Japan/ShowaDayTest.php +++ b/tests/Japan/ShowaDayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -40,7 +39,6 @@ class ShowaDayTest extends JapanBaseTestCase implements HolidayTestCase * Tests the holiday defined in the test on or after establishment. * * @throws Exception - * @throws ReflectionException */ public function testHolidayOnAfter2007(): void { @@ -57,7 +55,6 @@ public function testHolidayOnAfter2007(): void * Tests the holiday defined in the test on or after the establishment and substituted next working day. * * @throws Exception - * @throws ReflectionException */ public function testHolidayOnAfterEstablishmentSubstitutedNextWorkingDay(): void { @@ -73,7 +70,7 @@ public function testHolidayOnAfterEstablishmentSubstitutedNextWorkingDay(): void /** * Tests the holiday defined in the test before establishment. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayBeforeEstablishment(): void { @@ -87,7 +84,7 @@ public function testHolidayBeforeEstablishment(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -102,7 +99,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Japan/SportsDayTest.php b/tests/Japan/SportsDayTest.php index 80bb0cf79..1b0f4fb66 100644 --- a/tests/Japan/SportsDayTest.php +++ b/tests/Japan/SportsDayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -41,7 +40,6 @@ class SportsDayTest extends JapanBaseTestCase implements HolidayTestCase * after COVID-19. * * @throws Exception - * @throws ReflectionException */ public function testSportsDayIn2021(): void { @@ -58,7 +56,6 @@ public function testSportsDayIn2021(): void * Tests Health And Sports Day in 2020. Health And Sports Day in 2020 is July 24th for the Olympic Games. * * @throws Exception - * @throws ReflectionException */ public function testSportsDayIn2020(): void { @@ -76,7 +73,6 @@ public function testSportsDayIn2020(): void * 2000 it was changed to be the second monday of October. * * @throws Exception - * @throws ReflectionException */ public function testSportsDayOnAfter2000(): void { @@ -94,7 +90,6 @@ public function testSportsDayOnAfter2000(): void * 10th. After 2000 it was changed to be the second monday of October. * * @throws Exception - * @throws ReflectionException */ public function testSportsDayBetween1996And2000(): void { @@ -112,7 +107,6 @@ public function testSportsDayBetween1996And2000(): void * on a Sunday). * * @throws Exception - * @throws ReflectionException */ public function testSportsDayBetween1996And2000SubstitutedNextWorkingDay(): void { @@ -129,7 +123,7 @@ public function testSportsDayBetween1996And2000SubstitutedNextWorkingDay(): void * Tests Health And Sports Day before. Health And Sports Day was established since 1996 on October 10th. After * 2000 it was changed to be the second monday of October. * - * @throws ReflectionException + * @throws Exception */ public function testSportsDayBefore1996(): void { @@ -144,7 +138,7 @@ public function testSportsDayBefore1996(): void * Tests the translated name of the holiday defined in this test. * 1996-2019:Health And Sports Day. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -160,7 +154,7 @@ public function testTranslation(): void * Tests the translated name of the holiday defined in this test. * 2020 - :Sports Day. * - * @throws ReflectionException + * @throws Exception */ public function testTranslationFrom2020(): void { @@ -176,7 +170,7 @@ public function testTranslationFrom2020(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Japan/VernalEquinoxDayTest.php b/tests/Japan/VernalEquinoxDayTest.php index cdc015e03..19d90f7b0 100644 --- a/tests/Japan/VernalEquinoxDayTest.php +++ b/tests/Japan/VernalEquinoxDayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -43,7 +42,7 @@ class VernalEquinoxDayTest extends JapanBaseTestCase implements HolidayTestCase * * After 2150 no calculations are available yet. * - * @throws ReflectionException + * @throws Exception */ public function testVernalEquinoxDayOnAfter2150(): void { @@ -63,7 +62,6 @@ public function testVernalEquinoxDayOnAfter2150(): void * @param int $month month (number) of example data to be tested * @param int $day day of the month (number) of example data to be tested * - * @throws ReflectionException * @throws Exception */ public function testVernalEquinoxDayBetween1948And2150(int $year, int $month, int $day): void @@ -97,7 +95,7 @@ public function vernalEquinoxHolidaysProvider(): array * of nature and the love of living things. Prior to 1948, the vernal equinox was an imperial ancestor worship * festival called Shunki kōrei-sai (春季皇霊祭). * - * @throws ReflectionException + * @throws Exception */ public function testVernalEquinoxDayBefore1948(): void { @@ -111,7 +109,7 @@ public function testVernalEquinoxDayBefore1948(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -126,7 +124,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Latvia/ChristmasDayTest.php b/tests/Latvia/ChristmasDayTest.php index 61257cb51..b62ca87a3 100644 --- a/tests/Latvia/ChristmasDayTest.php +++ b/tests/Latvia/ChristmasDayTest.php @@ -17,7 +17,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -45,8 +44,6 @@ public function holidayDataProvider(): array /** * @dataProvider holidayDataProvider - * - * @throws ReflectionException */ public function testHoliday(int $year, DateTime $expected): void { @@ -56,7 +53,7 @@ public function testHoliday(int $year, DateTime $expected): void /** * {@inheritdoc} * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -71,7 +68,7 @@ public function testTranslation(): void /** * {@inheritdoc} * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Latvia/ChristmasEveDayTest.php b/tests/Latvia/ChristmasEveDayTest.php index cf1665771..2c68a36e8 100644 --- a/tests/Latvia/ChristmasEveDayTest.php +++ b/tests/Latvia/ChristmasEveDayTest.php @@ -17,7 +17,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -45,8 +44,6 @@ public function holidayDataProvider(): array /** * @dataProvider holidayDataProvider - * - * @throws ReflectionException */ public function testHoliday(int $year, DateTime $expected): void { @@ -56,7 +53,7 @@ public function testHoliday(int $year, DateTime $expected): void /** * {@inheritdoc} * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -71,7 +68,7 @@ public function testTranslation(): void /** * {@inheritdoc} * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Latvia/EasterDayTest.php b/tests/Latvia/EasterDayTest.php index 05a464e60..76676758d 100644 --- a/tests/Latvia/EasterDayTest.php +++ b/tests/Latvia/EasterDayTest.php @@ -18,7 +18,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -52,7 +51,6 @@ public function holidayDataProvider(): array * @param int $year the year for which the holiday defined in this test needs to be tested * @param string $expected the expected date * - * @throws ReflectionException * @throws Exception */ public function testHoliday(int $year, string $expected): void @@ -68,7 +66,7 @@ public function testHoliday(int $year, string $expected): void /** * {@inheritdoc} * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -83,7 +81,7 @@ public function testTranslation(): void /** * {@inheritdoc} * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Latvia/EasterMondayDayTest.php b/tests/Latvia/EasterMondayDayTest.php index 76e8595d2..7bf4b20ae 100644 --- a/tests/Latvia/EasterMondayDayTest.php +++ b/tests/Latvia/EasterMondayDayTest.php @@ -18,7 +18,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -52,7 +51,6 @@ public function holidayDataProvider(): array * @param int $year the year for which the holiday defined in this test needs to be tested * @param string $expected the expected date * - * @throws ReflectionException * @throws Exception */ public function testHoliday(int $year, string $expected): void @@ -68,7 +66,7 @@ public function testHoliday(int $year, string $expected): void /** * {@inheritdoc} * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -83,7 +81,7 @@ public function testTranslation(): void /** * {@inheritdoc} * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Latvia/GoodFridayDayTest.php b/tests/Latvia/GoodFridayDayTest.php index 66c02497b..cd67382cf 100644 --- a/tests/Latvia/GoodFridayDayTest.php +++ b/tests/Latvia/GoodFridayDayTest.php @@ -18,7 +18,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -52,7 +51,6 @@ public function holidayDataProvider(): array * @param int $year the year for which the holiday defined in this test needs to be tested * @param string $expected the expected date * - * @throws ReflectionException * @throws Exception */ public function testHoliday(int $year, string $expected): void @@ -68,7 +66,7 @@ public function testHoliday(int $year, string $expected): void /** * {@inheritdoc} * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -83,7 +81,7 @@ public function testTranslation(): void /** * {@inheritdoc} * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Latvia/InternationalWorkersDayTest.php b/tests/Latvia/InternationalWorkersDayTest.php index 5d6161566..fe3d76a44 100644 --- a/tests/Latvia/InternationalWorkersDayTest.php +++ b/tests/Latvia/InternationalWorkersDayTest.php @@ -17,7 +17,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -45,8 +44,6 @@ public function holidayDataProvider(): array /** * @dataProvider holidayDataProvider - * - * @throws ReflectionException */ public function testHoliday(int $year, DateTime $expected): void { @@ -56,7 +53,7 @@ public function testHoliday(int $year, DateTime $expected): void /** * {@inheritdoc} * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -71,7 +68,7 @@ public function testTranslation(): void /** * {@inheritdoc} * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Latvia/LatviaTest.php b/tests/Latvia/LatviaTest.php index c2ba79116..eb87dd5a5 100644 --- a/tests/Latvia/LatviaTest.php +++ b/tests/Latvia/LatviaTest.php @@ -30,7 +30,7 @@ class LatviaTest extends LatviaBaseTestCase implements ProviderTestCase /** * Tests if all official holidays in Latvia are defined by the provider class. * - * @throws ReflectionException + * @throws \Exception */ public function testOfficialHolidays(): void { @@ -64,7 +64,7 @@ public function testOfficialHolidays(): void /** * Tests if all observed holidays in Latvia are defined by the provider class. * - * @throws ReflectionException + * @throws \Exception */ public function testObservedHolidays(): void { @@ -74,7 +74,7 @@ public function testObservedHolidays(): void /** * Tests if all seasonal holidays in Latvia are defined by the provider class. * - * @throws ReflectionException + * @throws \Exception */ public function testSeasonalHolidays(): void { @@ -84,7 +84,7 @@ public function testSeasonalHolidays(): void /** * Tests if all bank holidays in Latvia are defined by the provider class. * - * @throws ReflectionException + * @throws \Exception */ public function testBankHolidays(): void { @@ -94,7 +94,7 @@ public function testBankHolidays(): void /** * Tests if all other holidays in Latvia are defined by the provider class. * - * @throws ReflectionException + * @throws \Exception */ public function testOtherHolidays(): void { @@ -103,6 +103,7 @@ public function testOtherHolidays(): void /** * @throws ReflectionException + * @throws \Exception */ public function testSources(): void { diff --git a/tests/Latvia/MidsummerEveDayTest.php b/tests/Latvia/MidsummerEveDayTest.php index e2a6ac2a6..8c626949d 100644 --- a/tests/Latvia/MidsummerEveDayTest.php +++ b/tests/Latvia/MidsummerEveDayTest.php @@ -17,7 +17,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -45,8 +44,6 @@ public function holidayDataProvider(): array /** * @dataProvider holidayDataProvider - * - * @throws ReflectionException */ public function testHoliday(int $year, DateTime $expected): void { @@ -56,7 +53,7 @@ public function testHoliday(int $year, DateTime $expected): void /** * {@inheritdoc} * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -71,7 +68,7 @@ public function testTranslation(): void /** * {@inheritdoc} * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Latvia/NewYearsDayTest.php b/tests/Latvia/NewYearsDayTest.php index 04caa1309..9459b8ddf 100644 --- a/tests/Latvia/NewYearsDayTest.php +++ b/tests/Latvia/NewYearsDayTest.php @@ -17,7 +17,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -45,8 +44,6 @@ public function holidayDataProvider(): array /** * @dataProvider holidayDataProvider - * - * @throws ReflectionException */ public function testHoliday(int $year, DateTime $expected): void { @@ -56,7 +53,7 @@ public function testHoliday(int $year, DateTime $expected): void /** * {@inheritdoc} * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -71,7 +68,7 @@ public function testTranslation(): void /** * {@inheritdoc} * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Latvia/NewYearsEveDayTest.php b/tests/Latvia/NewYearsEveDayTest.php index b37c24e69..eb9aa2155 100644 --- a/tests/Latvia/NewYearsEveDayTest.php +++ b/tests/Latvia/NewYearsEveDayTest.php @@ -17,7 +17,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -45,8 +44,6 @@ public function holidayDataProvider(): array /** * @dataProvider holidayDataProvider - * - * @throws ReflectionException */ public function testHoliday(int $year, DateTime $expected): void { @@ -56,7 +53,7 @@ public function testHoliday(int $year, DateTime $expected): void /** * {@inheritdoc} * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -71,7 +68,7 @@ public function testTranslation(): void /** * {@inheritdoc} * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Latvia/ProclamationOfTheRepublicOfLatviaDayTest.php b/tests/Latvia/ProclamationOfTheRepublicOfLatviaDayTest.php index 3f6e6f577..f53cd107b 100644 --- a/tests/Latvia/ProclamationOfTheRepublicOfLatviaDayTest.php +++ b/tests/Latvia/ProclamationOfTheRepublicOfLatviaDayTest.php @@ -18,7 +18,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\Provider\Latvia; use Yasumi\tests\HolidayTestCase; @@ -38,7 +37,7 @@ class ProclamationOfTheRepublicOfLatviaDayTest extends LatviaBaseTestCase implem /** * Test if holiday is not defined before proclamation. * - * @throws ReflectionException + * @throws Exception */ public function testNotHoliday(): void { @@ -73,7 +72,6 @@ public function holidayDataProvider(): array * @param int $year the year for which the holiday defined in this test needs to be tested * @param string $expected the expected date * - * @throws ReflectionException * @throws Exception */ public function testHoliday(int $year, string $expected): void @@ -89,7 +87,7 @@ public function testHoliday(int $year, string $expected): void /** * {@inheritdoc} * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -107,7 +105,7 @@ public function testTranslation(): void /** * {@inheritdoc} * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Latvia/RestorationOfIndependenceDayTest.php b/tests/Latvia/RestorationOfIndependenceDayTest.php index 1011987cb..769c5d342 100644 --- a/tests/Latvia/RestorationOfIndependenceDayTest.php +++ b/tests/Latvia/RestorationOfIndependenceDayTest.php @@ -18,7 +18,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\Provider\Latvia; use Yasumi\tests\HolidayTestCase; @@ -38,7 +37,7 @@ class RestorationOfIndependenceDayTest extends LatviaBaseTestCase implements Hol /** * Test if holiday is not defined before restoration. * - * @throws ReflectionException + * @throws Exception */ public function testNotHoliday(): void { @@ -73,7 +72,6 @@ public function holidayDataProvider(): array * @param int $year the year for which the holiday defined in this test needs to be tested * @param string $expected the expected date * - * @throws ReflectionException * @throws Exception */ public function testHoliday(int $year, string $expected): void @@ -89,7 +87,7 @@ public function testHoliday(int $year, string $expected): void /** * {@inheritdoc} * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -107,7 +105,7 @@ public function testTranslation(): void /** * {@inheritdoc} * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Latvia/SecondChristmasDayTest.php b/tests/Latvia/SecondChristmasDayTest.php index b6f8e5d76..faab1bc69 100644 --- a/tests/Latvia/SecondChristmasDayTest.php +++ b/tests/Latvia/SecondChristmasDayTest.php @@ -17,7 +17,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -45,8 +44,6 @@ public function holidayDataProvider(): array /** * @dataProvider holidayDataProvider - * - * @throws ReflectionException */ public function testHoliday(int $year, DateTime $expected): void { @@ -56,7 +53,7 @@ public function testHoliday(int $year, DateTime $expected): void /** * {@inheritdoc} * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -71,7 +68,7 @@ public function testTranslation(): void /** * {@inheritdoc} * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Latvia/StJohnsDayTest.php b/tests/Latvia/StJohnsDayTest.php index db3d67077..ff3772828 100644 --- a/tests/Latvia/StJohnsDayTest.php +++ b/tests/Latvia/StJohnsDayTest.php @@ -17,7 +17,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -45,8 +44,6 @@ public function holidayDataProvider(): array /** * @dataProvider holidayDataProvider - * - * @throws ReflectionException */ public function testHoliday(int $year, DateTime $expected): void { @@ -56,7 +53,7 @@ public function testHoliday(int $year, DateTime $expected): void /** * {@inheritdoc} * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -71,7 +68,7 @@ public function testTranslation(): void /** * {@inheritdoc} * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Lithuania/AllSaintsDayTest.php b/tests/Lithuania/AllSaintsDayTest.php index 5438552f2..bcb82da10 100644 --- a/tests/Lithuania/AllSaintsDayTest.php +++ b/tests/Lithuania/AllSaintsDayTest.php @@ -17,7 +17,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -45,8 +44,6 @@ public function holidayDataProvider(): array /** * @dataProvider holidayDataProvider - * - * @throws ReflectionException */ public function testHoliday(int $year, DateTime $expected): void { @@ -56,7 +53,7 @@ public function testHoliday(int $year, DateTime $expected): void /** * {@inheritdoc} * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -71,7 +68,7 @@ public function testTranslation(): void /** * {@inheritdoc} * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Lithuania/AllSoulsDayTest.php b/tests/Lithuania/AllSoulsDayTest.php index 7373e3376..d8a008a9e 100644 --- a/tests/Lithuania/AllSoulsDayTest.php +++ b/tests/Lithuania/AllSoulsDayTest.php @@ -18,7 +18,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\Provider\Lithuania; use Yasumi\tests\HolidayTestCase; @@ -36,7 +35,7 @@ class AllSoulsDayTest extends LithuaniaBaseTestCase implements HolidayTestCase public const HOLIDAY = 'allSoulsDay'; /** - * @throws ReflectionException + * @throws Exception */ public function testHolidayBeforeAnnounce(): void { @@ -51,7 +50,6 @@ public function testHolidayBeforeAnnounce(): void * Test if holiday is defined after restoration. * * @throws Exception - * @throws ReflectionException */ public function testHolidayAfterAnnounce(): void { @@ -68,7 +66,7 @@ public function testHolidayAfterAnnounce(): void /** * {@inheritdoc} * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -83,7 +81,7 @@ public function testTranslation(): void /** * {@inheritdoc} * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Lithuania/AssumptionOfMaryDayTest.php b/tests/Lithuania/AssumptionOfMaryDayTest.php index 9073f0cf7..f86e221d2 100644 --- a/tests/Lithuania/AssumptionOfMaryDayTest.php +++ b/tests/Lithuania/AssumptionOfMaryDayTest.php @@ -17,7 +17,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -45,8 +44,6 @@ public function holidayDataProvider(): array /** * @dataProvider holidayDataProvider - * - * @throws ReflectionException */ public function testHoliday(int $year, DateTime $expected): void { @@ -56,7 +53,7 @@ public function testHoliday(int $year, DateTime $expected): void /** * {@inheritdoc} * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -71,7 +68,7 @@ public function testTranslation(): void /** * {@inheritdoc} * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Lithuania/ChristmasDayTest.php b/tests/Lithuania/ChristmasDayTest.php index 85343e6f1..0fac9cb87 100644 --- a/tests/Lithuania/ChristmasDayTest.php +++ b/tests/Lithuania/ChristmasDayTest.php @@ -17,7 +17,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -45,8 +44,6 @@ public function holidayDataProvider(): array /** * @dataProvider holidayDataProvider - * - * @throws ReflectionException */ public function testHoliday(int $year, DateTime $expected): void { @@ -56,7 +53,7 @@ public function testHoliday(int $year, DateTime $expected): void /** * {@inheritdoc} * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -71,7 +68,7 @@ public function testTranslation(): void /** * {@inheritdoc} * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Lithuania/ChristmasEveDayTest.php b/tests/Lithuania/ChristmasEveDayTest.php index 4794ac8c2..9609ef309 100644 --- a/tests/Lithuania/ChristmasEveDayTest.php +++ b/tests/Lithuania/ChristmasEveDayTest.php @@ -17,7 +17,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -45,8 +44,6 @@ public function holidayDataProvider(): array /** * @dataProvider holidayDataProvider - * - * @throws ReflectionException */ public function testHoliday(int $year, DateTime $expected): void { @@ -56,7 +53,7 @@ public function testHoliday(int $year, DateTime $expected): void /** * {@inheritdoc} * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -71,7 +68,7 @@ public function testTranslation(): void /** * {@inheritdoc} * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Lithuania/EasterDayTest.php b/tests/Lithuania/EasterDayTest.php index 4196a7798..b7dfce109 100644 --- a/tests/Lithuania/EasterDayTest.php +++ b/tests/Lithuania/EasterDayTest.php @@ -18,7 +18,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -52,7 +51,6 @@ public function holidayDataProvider(): array * @param int $year the year for which the holiday defined in this test needs to be tested * @param string $expected the expected date * - * @throws ReflectionException * @throws Exception */ public function testHoliday(int $year, string $expected): void @@ -68,7 +66,7 @@ public function testHoliday(int $year, string $expected): void /** * {@inheritdoc} * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -83,7 +81,7 @@ public function testTranslation(): void /** * {@inheritdoc} * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Lithuania/EasterMondayDayTest.php b/tests/Lithuania/EasterMondayDayTest.php index f8c31e50c..8a42568d3 100644 --- a/tests/Lithuania/EasterMondayDayTest.php +++ b/tests/Lithuania/EasterMondayDayTest.php @@ -18,7 +18,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -52,7 +51,6 @@ public function holidayDataProvider(): array * @param int $year the year for which the holiday defined in this test needs to be tested * @param string $expected the expected date * - * @throws ReflectionException * @throws Exception */ public function testHoliday(int $year, string $expected): void @@ -68,7 +66,7 @@ public function testHoliday(int $year, string $expected): void /** * {@inheritdoc} * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -83,7 +81,7 @@ public function testTranslation(): void /** * {@inheritdoc} * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Lithuania/InternationalWorkersDayTest.php b/tests/Lithuania/InternationalWorkersDayTest.php index aae7d5ed6..c4886a033 100644 --- a/tests/Lithuania/InternationalWorkersDayTest.php +++ b/tests/Lithuania/InternationalWorkersDayTest.php @@ -17,7 +17,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -45,8 +44,6 @@ public function holidayDataProvider(): array /** * @dataProvider holidayDataProvider - * - * @throws ReflectionException */ public function testHoliday(int $year, DateTime $expected): void { @@ -56,7 +53,7 @@ public function testHoliday(int $year, DateTime $expected): void /** * {@inheritdoc} * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -71,7 +68,7 @@ public function testTranslation(): void /** * {@inheritdoc} * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Lithuania/LithuaniaTest.php b/tests/Lithuania/LithuaniaTest.php index bfce4afb0..9213e832c 100644 --- a/tests/Lithuania/LithuaniaTest.php +++ b/tests/Lithuania/LithuaniaTest.php @@ -29,7 +29,7 @@ class LithuaniaTest extends LithuaniaBaseTestCase /** * Tests if all official holidays in Lithuania are defined by the provider class. * - * @throws ReflectionException + * @throws \Exception */ public function testOfficialHolidays(): void { @@ -66,7 +66,7 @@ public function testOfficialHolidays(): void /** * Tests if all observed holidays in Lithuania are defined by the provider class. * - * @throws ReflectionException + * @throws \Exception */ public function testObservedHolidays(): void { @@ -76,7 +76,7 @@ public function testObservedHolidays(): void /** * Tests if all seasonal holidays in Lithuania are defined by the provider class. * - * @throws ReflectionException + * @throws \Exception */ public function testSeasonalHolidays(): void { @@ -86,7 +86,7 @@ public function testSeasonalHolidays(): void /** * Tests if all bank holidays in Lithuania are defined by the provider class. * - * @throws ReflectionException + * @throws \Exception */ public function testBankHolidays(): void { @@ -96,7 +96,7 @@ public function testBankHolidays(): void /** * Tests if all other holidays in Lithuania are defined by the provider class. * - * @throws ReflectionException + * @throws \Exception */ public function testOtherHolidays(): void { @@ -105,6 +105,7 @@ public function testOtherHolidays(): void /** * @throws ReflectionException + * @throws \Exception */ public function testSources(): void { diff --git a/tests/Lithuania/NewYearsDayTest.php b/tests/Lithuania/NewYearsDayTest.php index 00fa10092..d845ce473 100644 --- a/tests/Lithuania/NewYearsDayTest.php +++ b/tests/Lithuania/NewYearsDayTest.php @@ -17,7 +17,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -45,8 +44,6 @@ public function holidayDataProvider(): array /** * @dataProvider holidayDataProvider - * - * @throws ReflectionException */ public function testHoliday(int $year, DateTime $expected): void { @@ -56,7 +53,7 @@ public function testHoliday(int $year, DateTime $expected): void /** * {@inheritdoc} * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -71,7 +68,7 @@ public function testTranslation(): void /** * {@inheritdoc} * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Lithuania/RestorationOfIndependenceOfLithuaniaDayTest.php b/tests/Lithuania/RestorationOfIndependenceOfLithuaniaDayTest.php index 4881296de..7c7ce62b4 100644 --- a/tests/Lithuania/RestorationOfIndependenceOfLithuaniaDayTest.php +++ b/tests/Lithuania/RestorationOfIndependenceOfLithuaniaDayTest.php @@ -18,7 +18,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\Provider\Lithuania; use Yasumi\tests\HolidayTestCase; @@ -38,7 +37,7 @@ class RestorationOfIndependenceOfLithuaniaDayTest extends LithuaniaBaseTestCase /** * Test if holiday is not defined before restoration. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayBeforeRestoration(): void { @@ -53,7 +52,6 @@ public function testHolidayBeforeRestoration(): void * Test if holiday is defined after restoration. * * @throws Exception - * @throws ReflectionException */ public function testHolidayAfterRestoration(): void { @@ -70,7 +68,7 @@ public function testHolidayAfterRestoration(): void /** * {@inheritdoc} * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -91,7 +89,7 @@ public function testTranslation(): void /** * {@inheritdoc} * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Lithuania/RestorationOfTheStateOfLithuaniaDayTest.php b/tests/Lithuania/RestorationOfTheStateOfLithuaniaDayTest.php index 7ecf6c601..97b2d4f0b 100644 --- a/tests/Lithuania/RestorationOfTheStateOfLithuaniaDayTest.php +++ b/tests/Lithuania/RestorationOfTheStateOfLithuaniaDayTest.php @@ -18,7 +18,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\Provider\Lithuania; use Yasumi\tests\HolidayTestCase; @@ -38,7 +37,7 @@ class RestorationOfTheStateOfLithuaniaDayTest extends LithuaniaBaseTestCase impl /** * Test if holiday is not defined before restoration. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayBeforeRestoration(): void { @@ -53,7 +52,6 @@ public function testHolidayBeforeRestoration(): void * Test if holiday is defined after restoration. * * @throws Exception - * @throws ReflectionException */ public function testHolidayAfterRestoration(): void { @@ -70,7 +68,7 @@ public function testHolidayAfterRestoration(): void /** * {@inheritdoc} * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -91,7 +89,7 @@ public function testTranslation(): void /** * {@inheritdoc} * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Lithuania/SecondChristmasDayTest.php b/tests/Lithuania/SecondChristmasDayTest.php index b05554e21..74594d52c 100644 --- a/tests/Lithuania/SecondChristmasDayTest.php +++ b/tests/Lithuania/SecondChristmasDayTest.php @@ -17,7 +17,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -45,8 +44,6 @@ public function holidayDataProvider(): array /** * @dataProvider holidayDataProvider - * - * @throws ReflectionException */ public function testHoliday(int $year, DateTime $expected): void { @@ -56,7 +53,7 @@ public function testHoliday(int $year, DateTime $expected): void /** * {@inheritdoc} * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -71,7 +68,7 @@ public function testTranslation(): void /** * {@inheritdoc} * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Lithuania/StJohnsDayTest.php b/tests/Lithuania/StJohnsDayTest.php index 392bff7b5..36dfa04df 100644 --- a/tests/Lithuania/StJohnsDayTest.php +++ b/tests/Lithuania/StJohnsDayTest.php @@ -17,7 +17,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -45,8 +44,6 @@ public function holidayDataProvider(): array /** * @dataProvider holidayDataProvider - * - * @throws ReflectionException */ public function testHoliday(int $year, DateTime $expected): void { @@ -56,7 +53,7 @@ public function testHoliday(int $year, DateTime $expected): void /** * {@inheritdoc} * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -71,7 +68,7 @@ public function testTranslation(): void /** * {@inheritdoc} * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Lithuania/StatehoodDayTest.php b/tests/Lithuania/StatehoodDayTest.php index f3cf30983..6fff94765 100644 --- a/tests/Lithuania/StatehoodDayTest.php +++ b/tests/Lithuania/StatehoodDayTest.php @@ -18,7 +18,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\Provider\Lithuania; use Yasumi\tests\HolidayTestCase; @@ -38,7 +37,7 @@ class StatehoodDayTest extends LithuaniaBaseTestCase implements HolidayTestCase /** * Test if holiday is not defined before restoration. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayBeforeRestoration(): void { @@ -53,7 +52,6 @@ public function testHolidayBeforeRestoration(): void * Test if holiday is defined after restoration. * * @throws Exception - * @throws ReflectionException */ public function testHolidayAfterRestoration(): void { @@ -70,7 +68,7 @@ public function testHolidayAfterRestoration(): void /** * {@inheritdoc} * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -91,7 +89,7 @@ public function testTranslation(): void /** * {@inheritdoc} * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Luxembourg/AllSaintsDayTest.php b/tests/Luxembourg/AllSaintsDayTest.php index 44a388f8a..efa0f17fd 100644 --- a/tests/Luxembourg/AllSaintsDayTest.php +++ b/tests/Luxembourg/AllSaintsDayTest.php @@ -16,7 +16,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -37,8 +36,6 @@ class AllSaintsDayTest extends LuxembourgBaseTestCase implements HolidayTestCase * * @param int $year the year for which All Saints' Day needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testAllSaintsDay(int $year, DateTime $expected): void { @@ -48,7 +45,7 @@ public function testAllSaintsDay(int $year, DateTime $expected): void /** * Tests translated name of All Saints' Day. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -63,7 +60,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Luxembourg/AscensionDayTest.php b/tests/Luxembourg/AscensionDayTest.php index 83cf3a9e4..192bd6276 100644 --- a/tests/Luxembourg/AscensionDayTest.php +++ b/tests/Luxembourg/AscensionDayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -35,7 +34,6 @@ class AscensionDayTest extends LuxembourgBaseTestCase implements HolidayTestCase * Tests Ascension Day. * * @throws Exception - * @throws ReflectionException */ public function testAscensionDay(): void { @@ -51,7 +49,7 @@ public function testAscensionDay(): void /** * Tests translated name of Ascension Day. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -66,7 +64,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Luxembourg/AssumptionOfMaryTest.php b/tests/Luxembourg/AssumptionOfMaryTest.php index f611451cd..a24070707 100644 --- a/tests/Luxembourg/AssumptionOfMaryTest.php +++ b/tests/Luxembourg/AssumptionOfMaryTest.php @@ -16,7 +16,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -37,8 +36,6 @@ class AssumptionOfMaryTest extends LuxembourgBaseTestCase implements HolidayTest * * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testHoliday(int $year, DateTime $expected): void { @@ -60,7 +57,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -75,7 +72,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Luxembourg/ChristmasDayTest.php b/tests/Luxembourg/ChristmasDayTest.php index cbb6cc9c4..7eed1a545 100644 --- a/tests/Luxembourg/ChristmasDayTest.php +++ b/tests/Luxembourg/ChristmasDayTest.php @@ -16,7 +16,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -37,8 +36,6 @@ class ChristmasDayTest extends LuxembourgBaseTestCase implements HolidayTestCase * * @param int $year the year for which Christmas Day needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testChristmasDay(int $year, DateTime $expected): void { @@ -60,7 +57,7 @@ public function ChristmasDayDataProvider(): array /** * Tests translated name of Christmas Day. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -75,7 +72,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Luxembourg/EasterMondayTest.php b/tests/Luxembourg/EasterMondayTest.php index df5664acf..b09e98b5c 100644 --- a/tests/Luxembourg/EasterMondayTest.php +++ b/tests/Luxembourg/EasterMondayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -35,7 +34,6 @@ class EasterMondayTest extends LuxembourgBaseTestCase implements HolidayTestCase * Tests Easter Monday. * * @throws Exception - * @throws ReflectionException */ public function testEasterMonday(): void { @@ -51,7 +49,7 @@ public function testEasterMonday(): void /** * Tests translated name of Easter Monday. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -66,7 +64,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Luxembourg/EuropeDayTest.php b/tests/Luxembourg/EuropeDayTest.php index 3d89b3274..95c35624d 100644 --- a/tests/Luxembourg/EuropeDayTest.php +++ b/tests/Luxembourg/EuropeDayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -40,7 +39,6 @@ class EuropeDayTest extends LuxembourgBaseTestCase implements HolidayTestCase * Tests Europe Day on or after 2019. * * @throws Exception - * @throws ReflectionException */ public function testEuropeDayOnAfter2019(): void { @@ -56,7 +54,7 @@ public function testEuropeDayOnAfter2019(): void /** * Tests Europe Day before 2019. * - * @throws ReflectionException + * @throws Exception */ public function testEuropeDayBefore2019(): void { @@ -70,7 +68,7 @@ public function testEuropeDayBefore2019(): void /** * Tests translated name of Europe Day. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -85,7 +83,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Luxembourg/InternationalWorkersDayTest.php b/tests/Luxembourg/InternationalWorkersDayTest.php index 9838ef820..cb3cf6b6d 100644 --- a/tests/Luxembourg/InternationalWorkersDayTest.php +++ b/tests/Luxembourg/InternationalWorkersDayTest.php @@ -16,7 +16,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -37,8 +36,6 @@ class InternationalWorkersDayTest extends LuxembourgBaseTestCase implements Holi * * @param int $year the year for which International Workers' Day needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testInternationalWorkersDay(int $year, DateTime $expected): void { @@ -48,7 +45,7 @@ public function testInternationalWorkersDay(int $year, DateTime $expected): void /** * Tests translated name of International Workers' Day. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -63,7 +60,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Luxembourg/LuxembourgTest.php b/tests/Luxembourg/LuxembourgTest.php index c262c2054..8abe1b8da 100644 --- a/tests/Luxembourg/LuxembourgTest.php +++ b/tests/Luxembourg/LuxembourgTest.php @@ -27,12 +27,12 @@ class LuxembourgTest extends LuxembourgBaseTestCase implements ProviderTestCase /** * @var int year random year number used for all tests in this Test Case */ - protected $year; + protected int $year; /** * Tests if all official holidays in Luxembourg are defined by the provider class. * - * @throws ReflectionException + * @throws \Exception */ public function testOfficialHolidays(): void { @@ -61,7 +61,7 @@ public function testOfficialHolidays(): void /** * Tests if all observed holidays in Luxembourg are defined by the provider class. * - * @throws ReflectionException + * @throws \Exception */ public function testObservedHolidays(): void { @@ -71,7 +71,7 @@ public function testObservedHolidays(): void /** * Tests if all seasonal holidays in Luxembourg are defined by the provider class. * - * @throws ReflectionException + * @throws \Exception */ public function testSeasonalHolidays(): void { @@ -81,7 +81,7 @@ public function testSeasonalHolidays(): void /** * Tests if all bank holidays in Luxembourg are defined by the provider class. * - * @throws ReflectionException + * @throws \Exception */ public function testBankHolidays(): void { @@ -91,7 +91,7 @@ public function testBankHolidays(): void /** * Tests if all other holidays in Luxembourg are defined by the provider class. * - * @throws ReflectionException + * @throws \Exception */ public function testOtherHolidays(): void { @@ -100,6 +100,7 @@ public function testOtherHolidays(): void /** * @throws ReflectionException + * @throws \Exception */ public function testSources(): void { diff --git a/tests/Luxembourg/NationalDayTest.php b/tests/Luxembourg/NationalDayTest.php index 6b586e173..811514fe4 100644 --- a/tests/Luxembourg/NationalDayTest.php +++ b/tests/Luxembourg/NationalDayTest.php @@ -16,7 +16,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -37,8 +36,6 @@ class NationalDayTest extends LuxembourgBaseTestCase implements HolidayTestCase * * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testHoliday(int $year, DateTime $expected): void { @@ -60,7 +57,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -75,7 +72,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Luxembourg/NewYearsDayTest.php b/tests/Luxembourg/NewYearsDayTest.php index ab90746f7..0243ce68a 100644 --- a/tests/Luxembourg/NewYearsDayTest.php +++ b/tests/Luxembourg/NewYearsDayTest.php @@ -16,7 +16,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -37,8 +36,6 @@ class NewYearsDayTest extends LuxembourgBaseTestCase implements HolidayTestCase * * @param int $year the year for which New Years Day needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testNewYearsDay(int $year, DateTime $expected): void { @@ -48,7 +45,7 @@ public function testNewYearsDay(int $year, DateTime $expected): void /** * Tests translated name of New Years Day. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -63,7 +60,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Luxembourg/PentecostMondayTest.php b/tests/Luxembourg/PentecostMondayTest.php index 5546f1382..9af50c120 100644 --- a/tests/Luxembourg/PentecostMondayTest.php +++ b/tests/Luxembourg/PentecostMondayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -35,7 +34,6 @@ class PentecostMondayTest extends LuxembourgBaseTestCase implements HolidayTestC * Tests Pentecost Monday. * * @throws Exception - * @throws ReflectionException */ public function testPentecostMonday(): void { @@ -51,7 +49,7 @@ public function testPentecostMonday(): void /** * Tests translated name of Pentecost Monday. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -66,7 +64,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Luxembourg/SecondChristmasDayTest.php b/tests/Luxembourg/SecondChristmasDayTest.php index 65b03ebf5..0584b7586 100644 --- a/tests/Luxembourg/SecondChristmasDayTest.php +++ b/tests/Luxembourg/SecondChristmasDayTest.php @@ -16,7 +16,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -37,8 +36,6 @@ class SecondChristmasDayTest extends LuxembourgBaseTestCase implements HolidayTe * * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testHoliday(int $year, DateTime $expected): void { @@ -60,7 +57,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -75,7 +72,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Netherlands/AscensionDayTest.php b/tests/Netherlands/AscensionDayTest.php index 9f8ad4ad0..f4fd68b63 100644 --- a/tests/Netherlands/AscensionDayTest.php +++ b/tests/Netherlands/AscensionDayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -35,7 +34,6 @@ class AscensionDayTest extends NetherlandsBaseTestCase implements HolidayTestCas * Tests the holiday defined in this test. * * @throws Exception - * @throws ReflectionException */ public function testHoliday(): void { @@ -51,7 +49,7 @@ public function testHoliday(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -66,7 +64,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Netherlands/AshWednesdayTest.php b/tests/Netherlands/AshWednesdayTest.php index efddc1113..d757817c3 100644 --- a/tests/Netherlands/AshWednesdayTest.php +++ b/tests/Netherlands/AshWednesdayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -35,7 +34,6 @@ class AshWednesdayTest extends NetherlandsBaseTestCase implements HolidayTestCas * Tests the holiday defined in this test. * * @throws Exception - * @throws ReflectionException */ public function testHoliday(): void { @@ -51,7 +49,7 @@ public function testHoliday(): void /** * Tests translated name of Ash Wednesday. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -66,7 +64,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Netherlands/ChristmasDayTest.php b/tests/Netherlands/ChristmasDayTest.php index 95e0e8936..6101e7e86 100644 --- a/tests/Netherlands/ChristmasDayTest.php +++ b/tests/Netherlands/ChristmasDayTest.php @@ -16,7 +16,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -37,8 +36,6 @@ class ChristmasDayTest extends NetherlandsBaseTestCase implements HolidayTestCas * * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testHoliday(int $year, DateTime $expected): void { @@ -60,7 +57,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -75,7 +72,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Netherlands/CommemorationDayTest.php b/tests/Netherlands/CommemorationDayTest.php index 28fdbf911..993cfcc05 100644 --- a/tests/Netherlands/CommemorationDayTest.php +++ b/tests/Netherlands/CommemorationDayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -39,7 +38,7 @@ class CommemorationDayTest extends NetherlandsBaseTestCase implements HolidayTes /** * Tests Commemoration Day before 1947. Commemoration Day was established after WWII in 1947. * - * @throws ReflectionException + * @throws Exception */ public function testCommemorationDayBefore1947(): void { @@ -54,7 +53,6 @@ public function testCommemorationDayBefore1947(): void * Tests Commemoration Day after 1947. Commemoration Day was established after WWII in 1947. * * @throws Exception - * @throws ReflectionException */ public function testCommemorationDayOnAfter1947(): void { @@ -70,7 +68,7 @@ public function testCommemorationDayOnAfter1947(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -85,7 +83,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Netherlands/EasterMondayTest.php b/tests/Netherlands/EasterMondayTest.php index 178912930..fcc5f1d88 100644 --- a/tests/Netherlands/EasterMondayTest.php +++ b/tests/Netherlands/EasterMondayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -35,7 +34,6 @@ class EasterMondayTest extends NetherlandsBaseTestCase implements HolidayTestCas * Tests the holiday defined in this test. * * @throws Exception - * @throws ReflectionException */ public function testHoliday(): void { @@ -51,7 +49,7 @@ public function testHoliday(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -66,7 +64,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Netherlands/EasterTest.php b/tests/Netherlands/EasterTest.php index 50eef008d..c62304672 100644 --- a/tests/Netherlands/EasterTest.php +++ b/tests/Netherlands/EasterTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -35,7 +34,6 @@ class EasterTest extends NetherlandsBaseTestCase implements HolidayTestCase * Tests Easter. * * @throws Exception - * @throws ReflectionException */ public function testEaster(): void { @@ -51,7 +49,7 @@ public function testEaster(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -66,7 +64,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Netherlands/EpiphanyTest.php b/tests/Netherlands/EpiphanyTest.php index b18d77e09..c9db4a0ab 100644 --- a/tests/Netherlands/EpiphanyTest.php +++ b/tests/Netherlands/EpiphanyTest.php @@ -16,7 +16,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -37,8 +36,6 @@ class EpiphanyTest extends NetherlandsBaseTestCase implements HolidayTestCase * * @param int $year the year for which Epiphany needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testEpiphany(int $year, DateTime $expected): void { @@ -60,7 +57,7 @@ public function EpiphanyDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -75,7 +72,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Netherlands/FathersDayTest.php b/tests/Netherlands/FathersDayTest.php index d90653786..10f943eb3 100644 --- a/tests/Netherlands/FathersDayTest.php +++ b/tests/Netherlands/FathersDayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -35,7 +34,6 @@ class FathersDayTest extends NetherlandsBaseTestCase implements HolidayTestCase * Tests the holiday defined in this test. * * @throws Exception - * @throws ReflectionException */ public function testHoliday(): void { @@ -51,7 +49,7 @@ public function testHoliday(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -66,7 +64,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Netherlands/GoodFridayTest.php b/tests/Netherlands/GoodFridayTest.php index d674af476..c99d1048e 100644 --- a/tests/Netherlands/GoodFridayTest.php +++ b/tests/Netherlands/GoodFridayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -35,7 +34,6 @@ class GoodFridayTest extends NetherlandsBaseTestCase implements HolidayTestCase * Tests Good Friday. * * @throws Exception - * @throws ReflectionException */ public function testGoodFriday(): void { @@ -51,7 +49,7 @@ public function testGoodFriday(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -66,7 +64,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Netherlands/HalloweenTest.php b/tests/Netherlands/HalloweenTest.php index c8d8d9d79..783949fec 100644 --- a/tests/Netherlands/HalloweenTest.php +++ b/tests/Netherlands/HalloweenTest.php @@ -16,7 +16,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -37,8 +36,6 @@ class HalloweenTest extends NetherlandsBaseTestCase implements HolidayTestCase * * @param int $year the year for which Halloween needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testHoliday(int $year, DateTime $expected): void { @@ -60,7 +57,7 @@ public function HalloweenDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -75,7 +72,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Netherlands/InternationalWorkersDayTest.php b/tests/Netherlands/InternationalWorkersDayTest.php index 1f47024d4..a00e1e2f1 100644 --- a/tests/Netherlands/InternationalWorkersDayTest.php +++ b/tests/Netherlands/InternationalWorkersDayTest.php @@ -16,7 +16,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -37,8 +36,6 @@ class InternationalWorkersDayTest extends NetherlandsBaseTestCase implements Hol * * @param int $year the year for which International Workers' Day needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testInternationalWorkersDay(int $year, DateTime $expected): void { @@ -60,7 +57,7 @@ public function InternationalWorkersDayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -75,7 +72,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Netherlands/KingsDayTest.php b/tests/Netherlands/KingsDayTest.php index 7ab2d81b1..38139c985 100644 --- a/tests/Netherlands/KingsDayTest.php +++ b/tests/Netherlands/KingsDayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -40,7 +39,6 @@ class KingsDayTest extends NetherlandsBaseTestCase implements HolidayTestCase * Tests Kings Day on or after 2014. King's Day is celebrated from 2014 onwards on April 27th. * * @throws Exception - * @throws ReflectionException */ public function testKingsDayOnAfter2014(): void { @@ -57,7 +55,6 @@ public function testKingsDayOnAfter2014(): void * Tests Kings Day substituted on Saturday (when Kings Day falls on a Sunday). * * @throws Exception - * @throws ReflectionException */ public function testKingsDayOnAfter2014SubstitutedDay(): void { @@ -73,7 +70,7 @@ public function testKingsDayOnAfter2014SubstitutedDay(): void /** * Tests Kings Day before 2014. King's Day is celebrated from 2014 onwards on April 27th. * - * @throws ReflectionException + * @throws Exception */ public function testKingsDayBefore2014(): void { @@ -87,7 +84,7 @@ public function testKingsDayBefore2014(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -102,7 +99,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Netherlands/LiberationDayTest.php b/tests/Netherlands/LiberationDayTest.php index 24106ecfd..39cdc4ce7 100644 --- a/tests/Netherlands/LiberationDayTest.php +++ b/tests/Netherlands/LiberationDayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -39,7 +38,7 @@ class LiberationDayTest extends NetherlandsBaseTestCase implements HolidayTestCa /** * Tests Liberation Day before 1947. Liberation Day was established after WWII in 1947. * - * @throws ReflectionException + * @throws Exception */ public function testLiberationDayBefore1947(): void { @@ -54,7 +53,6 @@ public function testLiberationDayBefore1947(): void * Tests Liberation Day after 1947. Liberation Day was established after WWII in 1947. * * @throws Exception - * @throws ReflectionException */ public function testLiberationDayOnAfter1947(): void { @@ -70,7 +68,7 @@ public function testLiberationDayOnAfter1947(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -85,7 +83,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Netherlands/MothersDayTest.php b/tests/Netherlands/MothersDayTest.php index e9ea418b6..fccd58c64 100644 --- a/tests/Netherlands/MothersDayTest.php +++ b/tests/Netherlands/MothersDayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -35,7 +34,6 @@ class MothersDayTest extends NetherlandsBaseTestCase implements HolidayTestCase * Tests Mother's Day. * * @throws Exception - * @throws ReflectionException */ public function testMothersDay(): void { @@ -51,7 +49,7 @@ public function testMothersDay(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -66,7 +64,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Netherlands/NetherlandsTest.php b/tests/Netherlands/NetherlandsTest.php index 99387f1d0..b10b702ce 100644 --- a/tests/Netherlands/NetherlandsTest.php +++ b/tests/Netherlands/NetherlandsTest.php @@ -26,10 +26,12 @@ class NetherlandsTest extends NetherlandsBaseTestCase implements ProviderTestCas /** * @var int year random year number used for all tests in this Test Case */ - protected $year; + protected int $year; /** * Initial setup of this Test Case. + * + * @throws \Exception */ protected function setUp(): void { @@ -38,8 +40,6 @@ protected function setUp(): void /** * Tests if all official holidays in Netherlands are defined by the provider class. - * - * @throws ReflectionException */ public function testOfficialHolidays(): void { @@ -59,8 +59,6 @@ public function testOfficialHolidays(): void /** * Tests if all observed holidays in Netherlands are defined by the provider class. - * - * @throws ReflectionException */ public function testObservedHolidays(): void { @@ -80,7 +78,7 @@ public function testObservedHolidays(): void /** * Tests if all seasonal holidays in Netherlands are defined by the provider class. * - * @throws ReflectionException + * @throws \Exception */ public function testSeasonalHolidays(): void { @@ -90,8 +88,6 @@ public function testSeasonalHolidays(): void /** * Tests if all bank holidays in Netherlands are defined by the provider class. - * - * @throws ReflectionException */ public function testBankHolidays(): void { @@ -100,8 +96,6 @@ public function testBankHolidays(): void /** * Tests if all other holidays in Netherlands are defined by the provider class. - * - * @throws ReflectionException */ public function testOtherHolidays(): void { @@ -118,6 +112,7 @@ public function testOtherHolidays(): void /** * @throws ReflectionException + * @throws \Exception */ public function testSources(): void { diff --git a/tests/Netherlands/NewYearsDayTest.php b/tests/Netherlands/NewYearsDayTest.php index 66eb9b681..e71cc80f9 100644 --- a/tests/Netherlands/NewYearsDayTest.php +++ b/tests/Netherlands/NewYearsDayTest.php @@ -16,7 +16,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -37,8 +36,6 @@ class NewYearsDayTest extends NetherlandsBaseTestCase implements HolidayTestCase * * @param int $year the year for which New Years Day needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testNewYearsDay(int $year, DateTime $expected): void { @@ -60,7 +57,7 @@ public function NewYearsDayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -75,7 +72,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Netherlands/PentecostTest.php b/tests/Netherlands/PentecostTest.php index 2ee6e3a07..136c7e4df 100644 --- a/tests/Netherlands/PentecostTest.php +++ b/tests/Netherlands/PentecostTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -35,7 +34,6 @@ class PentecostTest extends NetherlandsBaseTestCase implements HolidayTestCase * Tests the holiday defined in this test. * * @throws Exception - * @throws ReflectionException */ public function testHoliday(): void { @@ -51,7 +49,7 @@ public function testHoliday(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -66,7 +64,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Netherlands/QueensDayTest.php b/tests/Netherlands/QueensDayTest.php index ea9c5ff26..3ab39c73f 100644 --- a/tests/Netherlands/QueensDayTest.php +++ b/tests/Netherlands/QueensDayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -35,7 +34,6 @@ class QueensDayTest extends NetherlandsBaseTestCase implements HolidayTestCase * Tests Queens Day between 1891 and 1948. * * @throws Exception - * @throws ReflectionException */ public function testQueensBetween1891and1948(): void { @@ -52,7 +50,6 @@ public function testQueensBetween1891and1948(): void * Tests Queens Day between 1891 and 1948 substituted one day later (when Queens Day falls on a Sunday). * * @throws Exception - * @throws ReflectionException */ public function testQueensBetween1891and1948SubstitutedLater(): void { @@ -69,7 +66,6 @@ public function testQueensBetween1891and1948SubstitutedLater(): void * Tests Queens Day between 1949 and 2013. * * @throws Exception - * @throws ReflectionException */ public function testQueensBetween1949and2013(): void { @@ -86,7 +82,6 @@ public function testQueensBetween1949and2013(): void * Tests Queens Day between 1949 and 2013 substituted one day later. * * @throws Exception - * @throws ReflectionException */ public function testQueensBetween1949and2013SubstitutedLater(): void { @@ -103,7 +98,6 @@ public function testQueensBetween1949and2013SubstitutedLater(): void * Tests Queens Day between 1949 and 2013 substituted one day earlier. * * @throws Exception - * @throws ReflectionException */ public function testQueensBetween1949and2013SubstitutedEarlier(): void { @@ -119,7 +113,7 @@ public function testQueensBetween1949and2013SubstitutedEarlier(): void /** * Tests Queen's Day before 1891. * - * @throws ReflectionException + * @throws Exception */ public function testQueensDayBefore1891(): void { @@ -129,7 +123,7 @@ public function testQueensDayBefore1891(): void /** * Tests Queen's Day after 2013. * - * @throws ReflectionException + * @throws Exception */ public function testQueensDayAfter2013(): void { @@ -139,7 +133,7 @@ public function testQueensDayAfter2013(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -154,7 +148,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Netherlands/SummertimeTest.php b/tests/Netherlands/SummertimeTest.php index 1cf348cd8..e5707f104 100644 --- a/tests/Netherlands/SummertimeTest.php +++ b/tests/Netherlands/SummertimeTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -35,7 +34,6 @@ class SummertimeTest extends NetherlandsBaseTestCase implements HolidayTestCase * Tests Summertime. * * @throws Exception - * @throws ReflectionException */ public function testSummertime(): void { @@ -61,7 +59,7 @@ public function testSummertime(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -76,7 +74,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Netherlands/ValentinesDayTest.php b/tests/Netherlands/ValentinesDayTest.php index 4bb8b2a3b..5c302cf54 100644 --- a/tests/Netherlands/ValentinesDayTest.php +++ b/tests/Netherlands/ValentinesDayTest.php @@ -16,7 +16,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -37,8 +36,6 @@ class ValentinesDayTest extends NetherlandsBaseTestCase implements HolidayTestCa * * @param int $year the year for which Valentines Day needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testValentinesDay(int $year, DateTime $expected): void { @@ -60,7 +57,7 @@ public function ValentinesDayDataProvider(): array /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { @@ -70,7 +67,7 @@ public function testHolidayType(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { diff --git a/tests/Netherlands/WintertimeTest.php b/tests/Netherlands/WintertimeTest.php index 050024092..d496ec237 100644 --- a/tests/Netherlands/WintertimeTest.php +++ b/tests/Netherlands/WintertimeTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -35,7 +34,6 @@ class WintertimeTest extends NetherlandsBaseTestCase implements HolidayTestCase * Tests Wintertime. * * @throws Exception - * @throws ReflectionException */ public function testWintertime(): void { @@ -61,7 +59,7 @@ public function testWintertime(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -76,7 +74,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Netherlands/WorldAnimalDayTest.php b/tests/Netherlands/WorldAnimalDayTest.php index cb4431624..b589a8dc0 100644 --- a/tests/Netherlands/WorldAnimalDayTest.php +++ b/tests/Netherlands/WorldAnimalDayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -40,7 +39,6 @@ class WorldAnimalDayTest extends NetherlandsBaseTestCase implements HolidayTestC * Tests World Animal Day on or after 1931. * * @throws Exception - * @throws ReflectionException */ public function testWorldAnimalDayOnAfter1931(): void { @@ -56,7 +54,7 @@ public function testWorldAnimalDayOnAfter1931(): void /** * Tests World Animal Day before 1931. * - * @throws ReflectionException + * @throws Exception */ public function testWorldAnimalBefore1931(): void { @@ -70,7 +68,7 @@ public function testWorldAnimalBefore1931(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { @@ -85,7 +83,7 @@ public function testHolidayType(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { diff --git a/tests/Netherlands/carnivalDayTest.php b/tests/Netherlands/carnivalDayTest.php index b860ef3be..a6d134fc2 100644 --- a/tests/Netherlands/carnivalDayTest.php +++ b/tests/Netherlands/carnivalDayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -35,7 +34,6 @@ class carnivalDayTest extends NetherlandsBaseTestCase implements HolidayTestCase * Tests the holiday defined in this test. * * @throws Exception - * @throws ReflectionException */ public function testHoliday(): void { @@ -51,7 +49,7 @@ public function testHoliday(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { @@ -61,7 +59,7 @@ public function testHolidayType(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { diff --git a/tests/Netherlands/pentecostMondayTest.php b/tests/Netherlands/pentecostMondayTest.php index 07def2ae6..92fc4b66c 100644 --- a/tests/Netherlands/pentecostMondayTest.php +++ b/tests/Netherlands/pentecostMondayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -35,7 +34,6 @@ class pentecostMondayTest extends NetherlandsBaseTestCase implements HolidayTest * Tests Pentecost Monday. * * @throws Exception - * @throws ReflectionException */ public function testPentecostMonday(): void { @@ -51,7 +49,7 @@ public function testPentecostMonday(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -66,7 +64,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Netherlands/princesDayTest.php b/tests/Netherlands/princesDayTest.php index c561adc5f..5610b2818 100644 --- a/tests/Netherlands/princesDayTest.php +++ b/tests/Netherlands/princesDayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -35,7 +34,6 @@ class princesDayTest extends NetherlandsBaseTestCase implements HolidayTestCase * Tests Prince's Day. * * @throws Exception - * @throws ReflectionException */ public function testPrincesDay(): void { @@ -51,7 +49,7 @@ public function testPrincesDay(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -66,7 +64,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Netherlands/secondCarnivalDay.php b/tests/Netherlands/secondCarnivalDay.php index d88173d66..98ea9f19f 100644 --- a/tests/Netherlands/secondCarnivalDay.php +++ b/tests/Netherlands/secondCarnivalDay.php @@ -18,7 +18,6 @@ use DateTimeZone; use Exception; use InvalidArgumentException; -use ReflectionException; use RuntimeException; use Yasumi\Exception\UnknownLocaleException; use Yasumi\Holiday; @@ -40,7 +39,6 @@ class secondCarnivalDay extends NetherlandsBaseTestCase implements HolidayTestCa * @throws UnknownLocaleException * @throws InvalidArgumentException * @throws RuntimeException - * @throws ReflectionException * @throws Exception */ public function testHoliday(): void @@ -60,7 +58,7 @@ public function testHoliday(): void * @throws InvalidArgumentException * @throws RuntimeException * @throws UnknownLocaleException - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { @@ -73,7 +71,7 @@ public function testHolidayType(): void * @throws InvalidArgumentException * @throws RuntimeException * @throws UnknownLocaleException - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { diff --git a/tests/Netherlands/secondChristmasdayTest.php b/tests/Netherlands/secondChristmasdayTest.php index 218effec2..f8858adbd 100644 --- a/tests/Netherlands/secondChristmasdayTest.php +++ b/tests/Netherlands/secondChristmasdayTest.php @@ -16,7 +16,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -37,8 +36,6 @@ class secondChristmasdayTest extends NetherlandsBaseTestCase implements HolidayT * * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testHoliday(int $year, DateTime $expected): void { @@ -60,7 +57,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -75,7 +72,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Netherlands/stMartinsDayTest.php b/tests/Netherlands/stMartinsDayTest.php index 5aeecdd96..f64e5b72a 100644 --- a/tests/Netherlands/stMartinsDayTest.php +++ b/tests/Netherlands/stMartinsDayTest.php @@ -16,7 +16,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -37,8 +36,6 @@ class stMartinsDayTest extends NetherlandsBaseTestCase implements HolidayTestCas * * @param int $year the year for which Sint Martins Day needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function teststMartinsDay(int $year, DateTime $expected): void { @@ -60,7 +57,7 @@ public function stMartinsDayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -75,7 +72,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Netherlands/stNicholasDayTest.php b/tests/Netherlands/stNicholasDayTest.php index e816f5139..bc690befe 100644 --- a/tests/Netherlands/stNicholasDayTest.php +++ b/tests/Netherlands/stNicholasDayTest.php @@ -16,7 +16,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -37,8 +36,6 @@ class stNicholasDayTest extends NetherlandsBaseTestCase implements HolidayTestCa * * @param int $year the year for which Sint Nicholas Day needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function teststNicholasDay(int $year, DateTime $expected): void { @@ -60,7 +57,7 @@ public function stNicholasDayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -75,7 +72,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Netherlands/thirdCarnivalDay.php b/tests/Netherlands/thirdCarnivalDay.php index 33cd25a3a..0943572af 100644 --- a/tests/Netherlands/thirdCarnivalDay.php +++ b/tests/Netherlands/thirdCarnivalDay.php @@ -18,7 +18,6 @@ use DateTimeZone; use Exception; use InvalidArgumentException; -use ReflectionException; use RuntimeException; use Yasumi\Exception\UnknownLocaleException; use Yasumi\Holiday; @@ -40,7 +39,6 @@ class thirdCarnivalDay extends NetherlandsBaseTestCase implements HolidayTestCas * @throws UnknownLocaleException * @throws InvalidArgumentException * @throws RuntimeException - * @throws ReflectionException * @throws Exception */ public function testHoliday(): void @@ -60,7 +58,7 @@ public function testHoliday(): void * @throws InvalidArgumentException * @throws RuntimeException * @throws UnknownLocaleException - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { @@ -73,7 +71,7 @@ public function testHolidayType(): void * @throws InvalidArgumentException * @throws RuntimeException * @throws UnknownLocaleException - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { diff --git a/tests/NewZealand/AnzacDayTest.php b/tests/NewZealand/AnzacDayTest.php index e1d321e35..48025121f 100644 --- a/tests/NewZealand/AnzacDayTest.php +++ b/tests/NewZealand/AnzacDayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -44,7 +43,6 @@ class AnzacDayTest extends NewZealandBaseTestCase implements HolidayTestCase * @param int $year the year for which the holiday defined in this test needs to be tested * @param string $expected the expected date * - * @throws ReflectionException * @throws Exception */ public function testHoliday(int $year, string $expected): void @@ -59,8 +57,6 @@ public function testHoliday(int $year, string $expected): void /** * Tests that Labour Day is not present before 1921. - * - * @throws ReflectionException */ public function testNotHoliday(): void { @@ -87,7 +83,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -102,7 +98,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/NewZealand/BoxingDayTest.php b/tests/NewZealand/BoxingDayTest.php index 939b8819d..7957adddf 100644 --- a/tests/NewZealand/BoxingDayTest.php +++ b/tests/NewZealand/BoxingDayTest.php @@ -18,7 +18,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -40,7 +39,6 @@ class BoxingDayTest extends NewZealandBaseTestCase implements HolidayTestCase * @param int $year the year for which the holiday defined in this test needs to be tested * @param string $expected the expected date * - * @throws ReflectionException * @throws Exception */ public function testHoliday(int $year, string $expected): void @@ -81,7 +79,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -96,7 +94,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/NewZealand/ChristmasDayTest.php b/tests/NewZealand/ChristmasDayTest.php index 895701da2..1cfbd4639 100644 --- a/tests/NewZealand/ChristmasDayTest.php +++ b/tests/NewZealand/ChristmasDayTest.php @@ -18,7 +18,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -40,7 +39,6 @@ class ChristmasDayTest extends NewZealandBaseTestCase implements HolidayTestCase * @param int $year the year for which the holiday defined in this test needs to be tested * @param string $expected the expected date * - * @throws ReflectionException * @throws Exception */ public function testHoliday(int $year, string $expected): void @@ -81,7 +79,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -96,7 +94,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/NewZealand/DayAfterNewYearsDayTest.php b/tests/NewZealand/DayAfterNewYearsDayTest.php index 1efaca72a..6924635cb 100644 --- a/tests/NewZealand/DayAfterNewYearsDayTest.php +++ b/tests/NewZealand/DayAfterNewYearsDayTest.php @@ -18,7 +18,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -40,7 +39,6 @@ class DayAfterNewYearsDayTest extends NewZealandBaseTestCase implements HolidayT * @param int $year the year for which the holiday defined in this test needs to be tested * @param string $expected the expected date * - * @throws ReflectionException * @throws Exception */ public function testHoliday(int $year, string $expected): void @@ -56,7 +54,7 @@ public function testHoliday(int $year, string $expected): void /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -71,7 +69,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/NewZealand/EasterMondayTest.php b/tests/NewZealand/EasterMondayTest.php index 5d41f6461..b3380d7ca 100644 --- a/tests/NewZealand/EasterMondayTest.php +++ b/tests/NewZealand/EasterMondayTest.php @@ -18,7 +18,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -40,7 +39,6 @@ class EasterMondayTest extends NewZealandBaseTestCase implements HolidayTestCase * @param int $year the year for which the holiday defined in this test needs to be tested * @param string $expected the expected date * - * @throws ReflectionException * @throws Exception */ public function testHoliday(int $year, string $expected): void @@ -78,7 +76,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -93,7 +91,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/NewZealand/GoodFridayTest.php b/tests/NewZealand/GoodFridayTest.php index 80ac99751..00a83a9f8 100644 --- a/tests/NewZealand/GoodFridayTest.php +++ b/tests/NewZealand/GoodFridayTest.php @@ -18,7 +18,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -40,7 +39,6 @@ class GoodFridayTest extends NewZealandBaseTestCase implements HolidayTestCase * @param int $year the year for which the holiday defined in this test needs to be tested * @param string $expected the expected date * - * @throws ReflectionException * @throws Exception */ public function testHoliday(int $year, string $expected): void @@ -77,7 +75,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -92,7 +90,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/NewZealand/LabourDayTest.php b/tests/NewZealand/LabourDayTest.php index dbd5d4464..9bbdfa020 100644 --- a/tests/NewZealand/LabourDayTest.php +++ b/tests/NewZealand/LabourDayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -44,7 +43,6 @@ class LabourDayTest extends NewZealandBaseTestCase implements HolidayTestCase * @param int $year the year for which the holiday defined in this test needs to be tested * @param string $expected the expected date * - * @throws ReflectionException * @throws Exception */ public function testHoliday(int $year, string $expected): void @@ -59,8 +57,6 @@ public function testHoliday(int $year, string $expected): void /** * Tests that Labour Day is not present before 1900. - * - * @throws ReflectionException */ public function testNotHoliday(): void { @@ -94,7 +90,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -109,7 +105,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/NewZealand/NewYearsDayTest.php b/tests/NewZealand/NewYearsDayTest.php index 57d251a18..d1cf7b913 100644 --- a/tests/NewZealand/NewYearsDayTest.php +++ b/tests/NewZealand/NewYearsDayTest.php @@ -18,7 +18,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -40,7 +39,6 @@ class NewYearsDayTest extends NewZealandBaseTestCase implements HolidayTestCase * @param int $year the year for which the holiday defined in this test needs to be tested * @param string $expected the expected date * - * @throws ReflectionException * @throws Exception */ public function testHoliday(int $year, string $expected): void @@ -86,7 +84,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -101,7 +99,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/NewZealand/NewZealandTest.php b/tests/NewZealand/NewZealandTest.php index a46c47b7d..e17ef47b8 100644 --- a/tests/NewZealand/NewZealandTest.php +++ b/tests/NewZealand/NewZealandTest.php @@ -26,10 +26,12 @@ class NewZealandTest extends NewZealandBaseTestCase implements ProviderTestCase /** * @var int year random year number used for all tests in this Test Case */ - protected $year; + protected int $year; /** * Initial setup of this Test Case. + * + * @throws \Exception */ protected function setUp(): void { @@ -38,8 +40,6 @@ protected function setUp(): void /** * Tests if all official holidays in New Zealand are defined by the provider class. - * - * @throws ReflectionException */ public function testOfficialHolidays(): void { @@ -58,8 +58,6 @@ public function testOfficialHolidays(): void /** * Tests if all observed holidays in New Zealand are defined by the provider class. - * - * @throws ReflectionException */ public function testObservedHolidays(): void { @@ -68,8 +66,6 @@ public function testObservedHolidays(): void /** * Tests if all seasonal holidays in New Zealand are defined by the provider class. - * - * @throws ReflectionException */ public function testSeasonalHolidays(): void { @@ -78,8 +74,6 @@ public function testSeasonalHolidays(): void /** * Tests if all bank holidays in New Zealand are defined by the provider class. - * - * @throws ReflectionException */ public function testBankHolidays(): void { @@ -88,8 +82,6 @@ public function testBankHolidays(): void /** * Tests if all other holidays in New Zealand are defined by the provider class. - * - * @throws ReflectionException */ public function testOtherHolidays(): void { @@ -98,6 +90,7 @@ public function testOtherHolidays(): void /** * @throws ReflectionException + * @throws \Exception */ public function testSources(): void { diff --git a/tests/NewZealand/QueensBirthdayTest.php b/tests/NewZealand/QueensBirthdayTest.php index 1d0b5e2c2..9cb0ba085 100644 --- a/tests/NewZealand/QueensBirthdayTest.php +++ b/tests/NewZealand/QueensBirthdayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -43,8 +42,6 @@ class QueensBirthdayTest extends NewZealandBaseTestCase implements HolidayTestCa * * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testHoliday(int $year, DateTime $expected): void { @@ -53,8 +50,6 @@ public function testHoliday(int $year, DateTime $expected): void /** * Tests that Holiday is not present before 1952. - * - * @throws ReflectionException */ public function testNotHoliday(): void { @@ -84,7 +79,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -99,7 +94,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/NewZealand/WaitangiDayTest.php b/tests/NewZealand/WaitangiDayTest.php index 85a9188b3..ea79aa5ca 100644 --- a/tests/NewZealand/WaitangiDayTest.php +++ b/tests/NewZealand/WaitangiDayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -44,7 +43,6 @@ class WaitangiDayTest extends NewZealandBaseTestCase implements HolidayTestCase * @param int $year the year for which the holiday defined in this test needs to be tested * @param string $expected the expected date * - * @throws ReflectionException * @throws Exception */ public function testHoliday(int $year, string $expected): void @@ -59,8 +57,6 @@ public function testHoliday(int $year, string $expected): void /** * Tests that Holiday is not present before 1974. - * - * @throws ReflectionException */ public function testNotHoliday(): void { @@ -70,7 +66,7 @@ public function testNotHoliday(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -85,7 +81,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Norway/AscensionDayTest.php b/tests/Norway/AscensionDayTest.php index 92a7e9f75..6fc44b880 100644 --- a/tests/Norway/AscensionDayTest.php +++ b/tests/Norway/AscensionDayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -35,7 +34,6 @@ class AscensionDayTest extends NorwayBaseTestCase implements HolidayTestCase * Tests Ascension Day. * * @throws Exception - * @throws ReflectionException */ public function testAscensionDay(): void { @@ -51,7 +49,7 @@ public function testAscensionDay(): void /** * Tests translated name of Ascension Day. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -66,7 +64,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Norway/ChristmasDayTest.php b/tests/Norway/ChristmasDayTest.php index a867d0ee5..0abbdfe3e 100644 --- a/tests/Norway/ChristmasDayTest.php +++ b/tests/Norway/ChristmasDayTest.php @@ -16,7 +16,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -37,8 +36,6 @@ class ChristmasDayTest extends NorwayBaseTestCase implements HolidayTestCase * * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testHoliday(int $year, DateTime $expected): void { @@ -60,7 +57,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -75,7 +72,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Norway/ConstitutionDayTest.php b/tests/Norway/ConstitutionDayTest.php index b59f06842..03946d6ff 100644 --- a/tests/Norway/ConstitutionDayTest.php +++ b/tests/Norway/ConstitutionDayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -40,7 +39,6 @@ class ConstitutionDayTest extends NorwayBaseTestCase implements HolidayTestCase * Tests the holiday defined in this test on or after establishment. * * @throws Exception - * @throws ReflectionException */ public function testHolidayOnAfterEstablishment(): void { @@ -56,7 +54,7 @@ public function testHolidayOnAfterEstablishment(): void /** * Tests the holiday defined in this test before establishment. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayBeforeEstablishment(): void { @@ -70,7 +68,7 @@ public function testHolidayBeforeEstablishment(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -85,7 +83,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Norway/EasterMondayTest.php b/tests/Norway/EasterMondayTest.php index 0d82ecaaa..333f8374b 100644 --- a/tests/Norway/EasterMondayTest.php +++ b/tests/Norway/EasterMondayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -35,7 +34,6 @@ class EasterMondayTest extends NorwayBaseTestCase implements HolidayTestCase * Tests the holiday defined in this test. * * @throws Exception - * @throws ReflectionException */ public function testHoliday(): void { @@ -51,7 +49,7 @@ public function testHoliday(): void /** * Tests translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -66,7 +64,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Norway/EasterTest.php b/tests/Norway/EasterTest.php index 6a41148d5..098b921cf 100644 --- a/tests/Norway/EasterTest.php +++ b/tests/Norway/EasterTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -35,7 +34,6 @@ class EasterTest extends NorwayBaseTestCase implements HolidayTestCase * Tests the holiday defined in this test. * * @throws Exception - * @throws ReflectionException */ public function testHoliday(): void { @@ -51,7 +49,7 @@ public function testHoliday(): void /** * Tests translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -66,7 +64,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Norway/GoodFridayTest.php b/tests/Norway/GoodFridayTest.php index 032c80066..274d6ab66 100644 --- a/tests/Norway/GoodFridayTest.php +++ b/tests/Norway/GoodFridayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -35,7 +34,6 @@ class GoodFridayTest extends NorwayBaseTestCase implements HolidayTestCase * Tests the holiday defined in this test. * * @throws Exception - * @throws ReflectionException */ public function testHoliday(): void { @@ -51,7 +49,7 @@ public function testHoliday(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -66,7 +64,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Norway/InternationalWorkersDayTest.php b/tests/Norway/InternationalWorkersDayTest.php index 64fb62ed3..9e00706b1 100644 --- a/tests/Norway/InternationalWorkersDayTest.php +++ b/tests/Norway/InternationalWorkersDayTest.php @@ -16,7 +16,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -37,8 +36,6 @@ class InternationalWorkersDayTest extends NorwayBaseTestCase implements HolidayT * * @param int $year the year for which International Workers' Day needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testInternationalWorkersDay(int $year, DateTime $expected): void { @@ -48,7 +45,7 @@ public function testInternationalWorkersDay(int $year, DateTime $expected): void /** * Tests translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -63,7 +60,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Norway/MaundyThursdayTest.php b/tests/Norway/MaundyThursdayTest.php index 9338ab5eb..f2c0a03b8 100644 --- a/tests/Norway/MaundyThursdayTest.php +++ b/tests/Norway/MaundyThursdayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -35,7 +34,6 @@ class MaundyThursdayTest extends NorwayBaseTestCase implements HolidayTestCase * Tests the holiday defined in this test. * * @throws Exception - * @throws ReflectionException */ public function testHoliday(): void { @@ -51,7 +49,7 @@ public function testHoliday(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -66,7 +64,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Norway/NewYearsDayTest.php b/tests/Norway/NewYearsDayTest.php index acbe32565..6cefaa2c0 100644 --- a/tests/Norway/NewYearsDayTest.php +++ b/tests/Norway/NewYearsDayTest.php @@ -16,7 +16,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -37,8 +36,6 @@ class NewYearsDayTest extends NorwayBaseTestCase implements HolidayTestCase * * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testHoliday(int $year, DateTime $expected): void { @@ -60,7 +57,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -75,7 +72,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Norway/NorwayTest.php b/tests/Norway/NorwayTest.php index 426178240..f2a8a0713 100644 --- a/tests/Norway/NorwayTest.php +++ b/tests/Norway/NorwayTest.php @@ -30,6 +30,8 @@ class NorwayTest extends NorwayBaseTestCase implements ProviderTestCase /** * Initial setup of this Test Case. + * + * @throws \Exception */ protected function setUp(): void { @@ -38,8 +40,6 @@ protected function setUp(): void /** * Tests if all official holidays in Norway are defined by the provider class. - * - * @throws ReflectionException */ public function testOfficialHolidays(): void { @@ -61,8 +61,6 @@ public function testOfficialHolidays(): void /** * Tests if all observed holidays in Norway are defined by the provider class. - * - * @throws ReflectionException */ public function testObservedHolidays(): void { @@ -71,8 +69,6 @@ public function testObservedHolidays(): void /** * Tests if all seasonal holidays in Norway are defined by the provider class. - * - * @throws ReflectionException */ public function testSeasonalHolidays(): void { @@ -81,8 +77,6 @@ public function testSeasonalHolidays(): void /** * Tests if all bank holidays in Norway are defined by the provider class. - * - * @throws ReflectionException */ public function testBankHolidays(): void { @@ -91,8 +85,6 @@ public function testBankHolidays(): void /** * Tests if all other holidays in Norway are defined by the provider class. - * - * @throws ReflectionException */ public function testOtherHolidays(): void { @@ -101,6 +93,7 @@ public function testOtherHolidays(): void /** * @throws ReflectionException + * @throws \Exception */ public function testSources(): void { diff --git a/tests/Norway/PentecostMondayTest.php b/tests/Norway/PentecostMondayTest.php index 3678bd599..a472d8f81 100644 --- a/tests/Norway/PentecostMondayTest.php +++ b/tests/Norway/PentecostMondayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -35,7 +34,6 @@ class PentecostMondayTest extends NorwayBaseTestCase implements HolidayTestCase * Tests the holiday defined in this test. * * @throws Exception - * @throws ReflectionException */ public function testHoliday(): void { @@ -51,7 +49,7 @@ public function testHoliday(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -66,7 +64,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Norway/PentecostTest.php b/tests/Norway/PentecostTest.php index 36bd46d12..ee793c19c 100644 --- a/tests/Norway/PentecostTest.php +++ b/tests/Norway/PentecostTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -35,7 +34,6 @@ class PentecostTest extends NorwayBaseTestCase implements HolidayTestCase * Tests the holiday defined in this test. * * @throws Exception - * @throws ReflectionException */ public function testHoliday(): void { @@ -51,7 +49,7 @@ public function testHoliday(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -66,7 +64,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Norway/SecondChristmasDayTest.php b/tests/Norway/SecondChristmasDayTest.php index dcabc13c5..64689767a 100644 --- a/tests/Norway/SecondChristmasDayTest.php +++ b/tests/Norway/SecondChristmasDayTest.php @@ -16,7 +16,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -37,8 +36,6 @@ class SecondChristmasDayTest extends NorwayBaseTestCase implements HolidayTestCa * * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testHoliday(int $year, DateTime $expected): void { @@ -60,7 +57,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -75,7 +72,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Poland/AllSaintsDayTest.php b/tests/Poland/AllSaintsDayTest.php index 05932e8fe..31e1996fe 100644 --- a/tests/Poland/AllSaintsDayTest.php +++ b/tests/Poland/AllSaintsDayTest.php @@ -16,7 +16,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -37,8 +36,6 @@ class AllSaintsDayTest extends PolandBaseTestCase implements HolidayTestCase * * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testHoliday(int $year, DateTime $expected): void { @@ -60,7 +57,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -75,7 +72,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Poland/AssumptionOfMaryTest.php b/tests/Poland/AssumptionOfMaryTest.php index 1030ee8da..2802444c1 100644 --- a/tests/Poland/AssumptionOfMaryTest.php +++ b/tests/Poland/AssumptionOfMaryTest.php @@ -16,7 +16,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -37,8 +36,6 @@ class AssumptionOfMaryTest extends PolandBaseTestCase implements HolidayTestCase * * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testHoliday(int $year, DateTime $expected): void { @@ -60,7 +57,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -75,7 +72,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Poland/ChristmasTest.php b/tests/Poland/ChristmasTest.php index 8285fffde..f0b72abf1 100644 --- a/tests/Poland/ChristmasTest.php +++ b/tests/Poland/ChristmasTest.php @@ -16,7 +16,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -37,8 +36,6 @@ class ChristmasTest extends PolandBaseTestCase implements HolidayTestCase * * @param int $year the year for which Christmas Day needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testChristmasDay(int $year, DateTime $expected): void { @@ -60,7 +57,7 @@ public function ChristmasDayDataProvider(): array /** * Tests translated name of Christmas Day. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -75,7 +72,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Poland/ConstitutionDayTest.php b/tests/Poland/ConstitutionDayTest.php index f2817f7a7..1376c3995 100644 --- a/tests/Poland/ConstitutionDayTest.php +++ b/tests/Poland/ConstitutionDayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -40,7 +39,6 @@ class ConstitutionDayTest extends PolandBaseTestCase implements HolidayTestCase * Tests the holiday defined in this test on or after establishment. * * @throws Exception - * @throws ReflectionException */ public function testHolidayOnAfterEstablishment(): void { @@ -56,7 +54,7 @@ public function testHolidayOnAfterEstablishment(): void /** * Tests the holiday defined in this test before establishment. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayBeforeEstablishment(): void { @@ -70,7 +68,7 @@ public function testHolidayBeforeEstablishment(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -85,7 +83,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Poland/CorpusChristiTest.php b/tests/Poland/CorpusChristiTest.php index 7cee1e486..c3b446cd6 100644 --- a/tests/Poland/CorpusChristiTest.php +++ b/tests/Poland/CorpusChristiTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -35,7 +34,6 @@ class CorpusChristiTest extends PolandBaseTestCase implements HolidayTestCase * Tests the holiday defined in this test. * * @throws Exception - * @throws ReflectionException */ public function testHoliday(): void { @@ -51,7 +49,7 @@ public function testHoliday(): void /** * Tests translated name of Corpus Christi. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -66,7 +64,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Poland/EasterMondayTest.php b/tests/Poland/EasterMondayTest.php index 4a48c85e7..3c9f29b08 100644 --- a/tests/Poland/EasterMondayTest.php +++ b/tests/Poland/EasterMondayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -35,7 +34,6 @@ class EasterMondayTest extends PolandBaseTestCase implements HolidayTestCase * Tests the holiday defined in this test. * * @throws Exception - * @throws ReflectionException */ public function testHoliday(): void { @@ -51,7 +49,7 @@ public function testHoliday(): void /** * Tests translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -66,7 +64,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Poland/EasterTest.php b/tests/Poland/EasterTest.php index 144b2cbb0..cf3a22d3c 100644 --- a/tests/Poland/EasterTest.php +++ b/tests/Poland/EasterTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -35,7 +34,6 @@ class EasterTest extends PolandBaseTestCase implements HolidayTestCase * Tests the holiday defined in this test. * * @throws Exception - * @throws ReflectionException */ public function testHoliday(): void { @@ -51,7 +49,7 @@ public function testHoliday(): void /** * Tests translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -66,7 +64,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Poland/EpiphanyTest.php b/tests/Poland/EpiphanyTest.php index ec64bd019..9c8ed6cc5 100644 --- a/tests/Poland/EpiphanyTest.php +++ b/tests/Poland/EpiphanyTest.php @@ -16,7 +16,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -37,8 +36,6 @@ class EpiphanyTest extends PolandBaseTestCase implements HolidayTestCase * * @param int $year the year for which Epiphany needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testEpiphany(int $year, DateTime $expected): void { @@ -60,7 +57,7 @@ public function EpiphanyDataProvider(): array /** * Tests translated name of Epiphany. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -75,7 +72,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Poland/IndependenceDayTest.php b/tests/Poland/IndependenceDayTest.php index 2a3a85c76..7f51f3f74 100644 --- a/tests/Poland/IndependenceDayTest.php +++ b/tests/Poland/IndependenceDayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -40,7 +39,6 @@ class IndependenceDayTest extends PolandBaseTestCase implements HolidayTestCase * Tests the holiday defined in this test on or after establishment. * * @throws Exception - * @throws ReflectionException */ public function testHolidayOnAfterEstablishment(): void { @@ -56,7 +54,7 @@ public function testHolidayOnAfterEstablishment(): void /** * Tests the holiday defined in this test before establishment. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayBeforeEstablishment(): void { @@ -70,7 +68,7 @@ public function testHolidayBeforeEstablishment(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -85,7 +83,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Poland/InternationalWorkersDayTest.php b/tests/Poland/InternationalWorkersDayTest.php index 2c4f08536..b0574a4a9 100644 --- a/tests/Poland/InternationalWorkersDayTest.php +++ b/tests/Poland/InternationalWorkersDayTest.php @@ -16,7 +16,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -37,8 +36,6 @@ class InternationalWorkersDayTest extends PolandBaseTestCase implements HolidayT * * @param int $year the year for which International Workers' Day needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testInternationalWorkersDay(int $year, DateTime $expected): void { @@ -48,7 +45,7 @@ public function testInternationalWorkersDay(int $year, DateTime $expected): void /** * Tests translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -63,7 +60,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Poland/NewYearsDayTest.php b/tests/Poland/NewYearsDayTest.php index eb42740e5..1062802ef 100644 --- a/tests/Poland/NewYearsDayTest.php +++ b/tests/Poland/NewYearsDayTest.php @@ -16,7 +16,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -37,8 +36,6 @@ class NewYearsDayTest extends PolandBaseTestCase implements HolidayTestCase * * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testHoliday(int $year, DateTime $expected): void { @@ -60,7 +57,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -75,7 +72,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Poland/PentecostTest.php b/tests/Poland/PentecostTest.php index a1160c394..324862c4d 100644 --- a/tests/Poland/PentecostTest.php +++ b/tests/Poland/PentecostTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -35,7 +34,6 @@ class PentecostTest extends PolandBaseTestCase implements HolidayTestCase * Tests the holiday defined in this test. * * @throws Exception - * @throws ReflectionException */ public function testHoliday(): void { @@ -51,7 +49,7 @@ public function testHoliday(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -66,7 +64,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Poland/PolandTest.php b/tests/Poland/PolandTest.php index 5c1cd0023..cb143e78a 100644 --- a/tests/Poland/PolandTest.php +++ b/tests/Poland/PolandTest.php @@ -30,6 +30,8 @@ class PolandTest extends PolandBaseTestCase implements ProviderTestCase /** * Initial setup of this Test Case. + * + * @throws \Exception */ protected function setUp(): void { @@ -38,8 +40,6 @@ protected function setUp(): void /** * Tests if all official holidays in Poland are defined by the provider class. - * - * @throws ReflectionException */ public function testOfficialHolidays(): void { @@ -62,8 +62,6 @@ public function testOfficialHolidays(): void /** * Tests if all observed holidays in Poland are defined by the provider class. - * - * @throws ReflectionException */ public function testObservedHolidays(): void { @@ -72,8 +70,6 @@ public function testObservedHolidays(): void /** * Tests if all seasonal holidays in Poland are defined by the provider class. - * - * @throws ReflectionException */ public function testSeasonalHolidays(): void { @@ -82,8 +78,6 @@ public function testSeasonalHolidays(): void /** * Tests if all bank holidays in Poland are defined by the provider class. - * - * @throws ReflectionException */ public function testBankHolidays(): void { @@ -92,8 +86,6 @@ public function testBankHolidays(): void /** * Tests if all other holidays in Poland are defined by the provider class. - * - * @throws ReflectionException */ public function testOtherHolidays(): void { @@ -102,6 +94,7 @@ public function testOtherHolidays(): void /** * @throws ReflectionException + * @throws \Exception */ public function testSources(): void { diff --git a/tests/Poland/SecondChristmasDayTest.php b/tests/Poland/SecondChristmasDayTest.php index 364ff76ba..2b5d9f935 100644 --- a/tests/Poland/SecondChristmasDayTest.php +++ b/tests/Poland/SecondChristmasDayTest.php @@ -16,7 +16,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -37,8 +36,6 @@ class SecondChristmasDayTest extends PolandBaseTestCase implements HolidayTestCa * * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testHoliday(int $year, DateTime $expected): void { @@ -60,7 +57,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -75,7 +72,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Portugal/AllSaintsDayTest.php b/tests/Portugal/AllSaintsDayTest.php index ad72287bf..877d69f11 100644 --- a/tests/Portugal/AllSaintsDayTest.php +++ b/tests/Portugal/AllSaintsDayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -44,9 +43,6 @@ class AllSaintsDayTest extends PortugalBaseTestCase implements HolidayTestCase /** * Tests the holiday defined in this test. * - * @throws ReflectionException - * @throws Exception - * @throws ReflectionException * @throws Exception */ public function testHoliday(): void @@ -63,7 +59,7 @@ public function testHoliday(): void /** * Test that the holiday did not happen in 2013-2015. * - * @throws ReflectionException + * @throws Exception */ public function testNotHoliday(): void { @@ -74,7 +70,7 @@ public function testNotHoliday(): void /** * Tests translated name of Corpus Christi. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -90,7 +86,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Portugal/AssumptionOfMaryTest.php b/tests/Portugal/AssumptionOfMaryTest.php index e6bc4060e..667aadd4d 100644 --- a/tests/Portugal/AssumptionOfMaryTest.php +++ b/tests/Portugal/AssumptionOfMaryTest.php @@ -16,7 +16,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -37,8 +36,6 @@ class AssumptionOfMaryTest extends PortugalBaseTestCase implements HolidayTestCa * * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testHoliday(int $year, DateTime $expected): void { @@ -60,7 +57,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -75,7 +72,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Portugal/CarnationRevolutionDayTest.php b/tests/Portugal/CarnationRevolutionDayTest.php index d7445b877..38a464542 100644 --- a/tests/Portugal/CarnationRevolutionDayTest.php +++ b/tests/Portugal/CarnationRevolutionDayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -39,7 +38,6 @@ class CarnationRevolutionDayTest extends PortugalBaseTestCase implements Holiday /** * Test that the holiday is valid after the year of establishment. * - * @throws ReflectionException * @throws Exception */ public function testHolidayAfterEstablishment(): void @@ -52,7 +50,7 @@ public function testHolidayAfterEstablishment(): void /** * Tests that the holiday is not a holiday before the year of establishment. * - * @throws ReflectionException + * @throws Exception */ public function testNotHolidayBeforeEstablishment(): void { @@ -63,7 +61,7 @@ public function testNotHolidayBeforeEstablishment(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -74,7 +72,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Portugal/ChristmasTest.php b/tests/Portugal/ChristmasTest.php index eabff06f8..8545ea1c8 100644 --- a/tests/Portugal/ChristmasTest.php +++ b/tests/Portugal/ChristmasTest.php @@ -16,7 +16,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -37,8 +36,6 @@ class ChristmasTest extends PortugalBaseTestCase implements HolidayTestCase * * @param int $year the year for which Christmas Day needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testChristmasDay(int $year, DateTime $expected): void { @@ -60,7 +57,7 @@ public function ChristmasDayDataProvider(): array /** * Tests translated name of Christmas Day. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -75,7 +72,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Portugal/CorpusChristiTest.php b/tests/Portugal/CorpusChristiTest.php index 8fa96fe05..07450e48c 100644 --- a/tests/Portugal/CorpusChristiTest.php +++ b/tests/Portugal/CorpusChristiTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -44,7 +43,6 @@ class CorpusChristiTest extends PortugalBaseTestCase implements HolidayTestCase /** * Tests the holiday defined in this test. * - * @throws ReflectionException * @throws Exception */ public function testHoliday(): void @@ -57,7 +55,7 @@ public function testHoliday(): void /** * Test that the holiday did not happen in 2013-2015. * - * @throws ReflectionException + * @throws Exception */ public function testNotHoliday(): void { @@ -68,7 +66,7 @@ public function testNotHoliday(): void /** * Tests translated name of Corpus Christi. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -79,7 +77,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Portugal/EasterTest.php b/tests/Portugal/EasterTest.php index d3665dde3..f1d701ea2 100644 --- a/tests/Portugal/EasterTest.php +++ b/tests/Portugal/EasterTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -35,7 +34,6 @@ class EasterTest extends PortugalBaseTestCase implements HolidayTestCase * Tests the holiday defined in this test. * * @throws Exception - * @throws ReflectionException */ public function testHoliday(): void { @@ -51,7 +49,7 @@ public function testHoliday(): void /** * Tests translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -66,7 +64,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Portugal/GoodFridayTest.php b/tests/Portugal/GoodFridayTest.php index ba58e83df..33d85bb58 100644 --- a/tests/Portugal/GoodFridayTest.php +++ b/tests/Portugal/GoodFridayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -35,7 +34,6 @@ class GoodFridayTest extends PortugalBaseTestCase implements HolidayTestCase * Tests the holiday defined in this test. * * @throws Exception - * @throws ReflectionException */ public function testHoliday(): void { @@ -51,7 +49,7 @@ public function testHoliday(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -66,7 +64,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Portugal/ImmaculateConceptionTest.php b/tests/Portugal/ImmaculateConceptionTest.php index 3127130b6..dff7a043f 100644 --- a/tests/Portugal/ImmaculateConceptionTest.php +++ b/tests/Portugal/ImmaculateConceptionTest.php @@ -16,7 +16,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -37,8 +36,6 @@ class ImmaculateConceptionTest extends PortugalBaseTestCase implements HolidayTe * * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testHoliday(int $year, DateTime $expected): void { @@ -60,7 +57,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -75,7 +72,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Portugal/InternationalWorkersDayTest.php b/tests/Portugal/InternationalWorkersDayTest.php index 7a1dbac55..34ce61ac8 100644 --- a/tests/Portugal/InternationalWorkersDayTest.php +++ b/tests/Portugal/InternationalWorkersDayTest.php @@ -16,7 +16,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -37,8 +36,6 @@ class InternationalWorkersDayTest extends PortugalBaseTestCase implements Holida * * @param int $year the year for which International Workers' Day needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testInternationalWorkersDay(int $year, DateTime $expected): void { @@ -48,7 +45,7 @@ public function testInternationalWorkersDay(int $year, DateTime $expected): void /** * Tests translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -63,7 +60,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Portugal/NewYearsDayTest.php b/tests/Portugal/NewYearsDayTest.php index f8fe56a36..83219907f 100644 --- a/tests/Portugal/NewYearsDayTest.php +++ b/tests/Portugal/NewYearsDayTest.php @@ -16,7 +16,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -37,8 +36,6 @@ class NewYearsDayTest extends PortugalBaseTestCase implements HolidayTestCase * * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testHoliday(int $year, DateTime $expected): void { @@ -60,7 +57,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -75,7 +72,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Portugal/PortugalDayTest.php b/tests/Portugal/PortugalDayTest.php index 4e82be7f6..14802fef8 100644 --- a/tests/Portugal/PortugalDayTest.php +++ b/tests/Portugal/PortugalDayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\Provider\Portugal; use Yasumi\tests\HolidayTestCase; @@ -45,7 +44,6 @@ class PortugalDayTest extends PortugalBaseTestCase implements HolidayTestCase /** * Tests the holiday defined in this test before it was abolished. * - * @throws ReflectionException * @throws Exception * * @see Portugal::calculatePortugalDay() @@ -60,7 +58,6 @@ public function testHolidayBeforeAbolishment(): void /** * Tests the holiday defined in this test after it was restored. * - * @throws ReflectionException * @throws Exception * * @see Portugal::calculatePortugalDay() @@ -75,7 +72,7 @@ public function testHolidayAfterRestoration(): void /** * Tests that the holiday defined in this test does not exist during the period that it was abolished. * - * @throws ReflectionException + * @throws Exception * * @see Portugal::calculatePortugalDay() */ @@ -91,7 +88,7 @@ public function testNotHolidayDuringAbolishment(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -105,7 +102,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Portugal/PortugalTest.php b/tests/Portugal/PortugalTest.php index c61842d08..943cdd3fe 100644 --- a/tests/Portugal/PortugalTest.php +++ b/tests/Portugal/PortugalTest.php @@ -30,6 +30,8 @@ class PortugalTest extends PortugalBaseTestCase implements ProviderTestCase /** * Initial setup of this Test Case. + * + * @throws \Exception */ protected function setUp(): void { @@ -38,8 +40,6 @@ protected function setUp(): void /** * Tests if all official holidays in Portugal are defined by the provider class. - * - * @throws ReflectionException */ public function testOfficialHolidays(): void { @@ -66,8 +66,6 @@ public function testOfficialHolidays(): void /** * Tests if all observed holidays in Portugal are defined by the provider class. - * - * @throws ReflectionException */ public function testObservedHolidays(): void { @@ -76,8 +74,6 @@ public function testObservedHolidays(): void /** * Tests if all seasonal holidays in Portugal are defined by the provider class. - * - * @throws ReflectionException */ public function testSeasonalHolidays(): void { @@ -86,8 +82,6 @@ public function testSeasonalHolidays(): void /** * Tests if all bank holidays in Portugal are defined by the provider class. - * - * @throws ReflectionException */ public function testBankHolidays(): void { @@ -96,8 +90,6 @@ public function testBankHolidays(): void /** * Tests if all other holidays in PortugalPortugal are defined by the provider class. - * - * @throws ReflectionException */ public function testOtherHolidays(): void { @@ -112,6 +104,7 @@ public function testOtherHolidays(): void /** * @throws ReflectionException + * @throws \Exception */ public function testSources(): void { diff --git a/tests/Portugal/PortugueseRepublicDayTest.php b/tests/Portugal/PortugueseRepublicDayTest.php index 8c5f2fb4e..78159720f 100644 --- a/tests/Portugal/PortugueseRepublicDayTest.php +++ b/tests/Portugal/PortugueseRepublicDayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -32,7 +31,6 @@ class PortugueseRepublicDayTest extends PortugalBaseTestCase implements HolidayT public const HOLIDAY = 'portugueseRepublic'; /** - * @throws ReflectionException * @throws Exception */ public function testHolidayOnAfterRestoration(): void @@ -48,7 +46,7 @@ public function testHolidayOnAfterRestoration(): void } /** - * @throws ReflectionException + * @throws Exception */ public function testNotHolidayDuringAbolishment(): void { @@ -60,7 +58,6 @@ public function testNotHolidayDuringAbolishment(): void } /** - * @throws ReflectionException * @throws Exception */ public function testHolidayOnAfterEstablishment(): void @@ -75,68 +72,76 @@ public function testHolidayOnAfterEstablishment(): void } } - /** - * @throws ReflectionException - */ public function testHolidayBeforeEstablishment(): void { - foreach ($this->randomYearsBeforeEstablishment() as $year) { - $this->assertNotHoliday(self::REGION, self::HOLIDAY, $year); + try { + foreach ($this->randomYearsBeforeEstablishment() as $year) { + $this->assertNotHoliday(self::REGION, self::HOLIDAY, $year); + } + } catch (Exception $e) { } } - /** - * @throws ReflectionException - */ public function testTranslation(): void { - foreach ($this->randomEstablishedYear() as $year) { - $this->assertTranslatedHolidayName( - self::REGION, - self::HOLIDAY, - $year, - [self::LOCALE => 'Implantação da República Portuguesa'] - ); + try { + foreach ($this->randomEstablishedYear() as $year) { + $this->assertTranslatedHolidayName( + self::REGION, + self::HOLIDAY, + $year, + [self::LOCALE => 'Implantação da República Portuguesa'] + ); + } + } catch (Exception $e) { } } - /** - * @throws ReflectionException - */ public function testHolidayType(): void { - foreach ($this->randomEstablishedYear() as $year) { - $this->assertHolidayType( - self::REGION, - self::HOLIDAY, - $year, - Holiday::TYPE_OFFICIAL - ); + try { + foreach ($this->randomEstablishedYear() as $year) { + $this->assertHolidayType( + self::REGION, + self::HOLIDAY, + $year, + Holiday::TYPE_OFFICIAL + ); + } + } catch (Exception $e) { } } - /** @return \Generator */ + /** @return \Generator + * @throws Exception + */ private function randomEstablishedYear(): \Generator { yield $this->generateRandomYear(self::ESTABLISHMENT_YEAR, self::HOLIDAY_YEAR_SUSPENDED - 1); yield $this->generateRandomYear(self::HOLIDAY_YEAR_RESTORED); } - /** @return \Generator */ + /** @return \Generator + * @throws Exception + */ private function randomYearsBeforeEstablishment(): \Generator { yield $this->generateRandomYear(1000, self::ESTABLISHMENT_YEAR - 1); yield self::ESTABLISHMENT_YEAR - 1; } - /** @return \Generator */ + /** @return \Generator + * @throws Exception + */ private function randomYearsOnAfterEstablishment(): \Generator { yield $this->generateRandomYear(self::ESTABLISHMENT_YEAR); yield self::ESTABLISHMENT_YEAR; } - /** @return \Generator */ + /** @return \Generator + * @throws Exception + */ private function randomYearsOnAfterRestoration(): \Generator { yield $this->generateRandomYear(self::HOLIDAY_YEAR_RESTORED); diff --git a/tests/Portugal/RestorationOfIndependenceTest.php b/tests/Portugal/RestorationOfIndependenceTest.php index 87f2b362b..87204ab9d 100644 --- a/tests/Portugal/RestorationOfIndependenceTest.php +++ b/tests/Portugal/RestorationOfIndependenceTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -49,9 +48,6 @@ class RestorationOfIndependenceTest extends PortugalBaseTestCase implements Holi /** * Tests the holiday defined in this test on or after establishment. * - * @throws ReflectionException - * @throws Exception - * @throws ReflectionException * @throws Exception */ public function testHolidayOnAfterEstablishment(): void @@ -69,9 +65,7 @@ public function testHolidayOnAfterEstablishment(): void /** * Test that the holiday if in effect in 2016 and later dates. * - * @throws ReflectionException * @throws Exception - * @throws ReflectionException * @throws Exception */ public function testHolidayOnAfterRestoration(): void @@ -90,7 +84,7 @@ public function testHolidayOnAfterRestoration(): void /** * Test that the holiday did not happen in 2013-2015. * - * @throws ReflectionException + * @throws Exception */ public function testNotHolidayDuringAbolishment(): void { @@ -101,7 +95,7 @@ public function testNotHolidayDuringAbolishment(): void /** * Tests the holiday defined in this test before establishment. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayBeforeEstablishment(): void { @@ -115,7 +109,7 @@ public function testHolidayBeforeEstablishment(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -139,7 +133,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Romania/AssumptionOfMaryTest.php b/tests/Romania/AssumptionOfMaryTest.php index 913f3034c..22073f325 100644 --- a/tests/Romania/AssumptionOfMaryTest.php +++ b/tests/Romania/AssumptionOfMaryTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -40,7 +39,6 @@ class AssumptionOfMaryTest extends RomaniaBaseTestCase implements HolidayTestCas * Tests Assumption Of Mary Day on or after 2008. * * @throws Exception - * @throws ReflectionException */ public function testAssumptionOfMaryDayOnAfter2008(): void { @@ -56,7 +54,7 @@ public function testAssumptionOfMaryDayOnAfter2008(): void /** * Tests Assumption of Mary Day before 2008. * - * @throws ReflectionException + * @throws Exception */ public function testAssumptionOfMaryDayBefore2008(): void { @@ -70,7 +68,7 @@ public function testAssumptionOfMaryDayBefore2008(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -85,7 +83,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Romania/ChildrensDayTest.php b/tests/Romania/ChildrensDayTest.php index eca6ecfb0..c4d676297 100644 --- a/tests/Romania/ChildrensDayTest.php +++ b/tests/Romania/ChildrensDayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -40,7 +39,6 @@ class ChildrensDayTest extends RomaniaBaseTestCase implements HolidayTestCase * Tests Children's Day on or after 1950. * * @throws Exception - * @throws ReflectionException */ public function testChildrensDayOnAfter1950(): void { @@ -56,7 +54,7 @@ public function testChildrensDayOnAfter1950(): void /** * Tests Children's Day before 1950. * - * @throws ReflectionException + * @throws Exception */ public function testChildrensDayBefore1950(): void { @@ -70,7 +68,7 @@ public function testChildrensDayBefore1950(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -85,7 +83,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Romania/ChristmasDayTest.php b/tests/Romania/ChristmasDayTest.php index 3ac3d95b9..884446359 100644 --- a/tests/Romania/ChristmasDayTest.php +++ b/tests/Romania/ChristmasDayTest.php @@ -16,7 +16,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -37,8 +36,6 @@ class ChristmasDayTest extends RomaniaBaseTestCase implements HolidayTestCase * * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testHoliday(int $year, DateTime $expected): void { @@ -60,7 +57,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -75,7 +72,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Romania/ConstantinBrancusiDayTest.php b/tests/Romania/ConstantinBrancusiDayTest.php index 92fa37f8b..761907f19 100644 --- a/tests/Romania/ConstantinBrancusiDayTest.php +++ b/tests/Romania/ConstantinBrancusiDayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -40,7 +39,6 @@ class ConstantinBrancusiDayTest extends RomaniaBaseTestCase implements HolidayTe * Tests Constantin Brancusi Day on or after 2016. * * @throws Exception - * @throws ReflectionException */ public function testConstantinBrancusiDayOnAfter2016(): void { @@ -56,7 +54,7 @@ public function testConstantinBrancusiDayOnAfter2016(): void /** * Tests Constantin Brancusi Day before 2016. * - * @throws ReflectionException + * @throws Exception */ public function testConstantinBrancusiDayBefore2016(): void { @@ -70,7 +68,7 @@ public function testConstantinBrancusiDayBefore2016(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -85,7 +83,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Romania/DayAfterNewYearsDayTest.php b/tests/Romania/DayAfterNewYearsDayTest.php index 4f3287b71..d4137c9fa 100644 --- a/tests/Romania/DayAfterNewYearsDayTest.php +++ b/tests/Romania/DayAfterNewYearsDayTest.php @@ -16,7 +16,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -37,8 +36,6 @@ class DayAfterNewYearsDayTest extends RomaniaBaseTestCase implements HolidayTest * * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testHoliday(int $year, DateTime $expected): void { @@ -60,7 +57,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -75,7 +72,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Romania/EasterMondayTest.php b/tests/Romania/EasterMondayTest.php index a890d352f..a918af0a3 100755 --- a/tests/Romania/EasterMondayTest.php +++ b/tests/Romania/EasterMondayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -35,7 +34,6 @@ class EasterMondayTest extends RomaniaBaseTestCase implements HolidayTestCase * Tests the holiday defined in this test. * * @throws Exception - * @throws ReflectionException */ public function testHoliday(): void { @@ -51,7 +49,7 @@ public function testHoliday(): void /** * Tests translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -66,7 +64,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Romania/EasterTest.php b/tests/Romania/EasterTest.php index e0d369553..ff87b3532 100755 --- a/tests/Romania/EasterTest.php +++ b/tests/Romania/EasterTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -35,7 +34,6 @@ class EasterTest extends RomaniaBaseTestCase implements HolidayTestCase * Tests the holiday defined in this test. * * @throws Exception - * @throws ReflectionException */ public function testHoliday(): void { @@ -51,7 +49,7 @@ public function testHoliday(): void /** * Tests translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -66,7 +64,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Romania/InternationalWorkersDayTest.php b/tests/Romania/InternationalWorkersDayTest.php index 9688f852b..5f9e5f672 100755 --- a/tests/Romania/InternationalWorkersDayTest.php +++ b/tests/Romania/InternationalWorkersDayTest.php @@ -16,7 +16,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -37,8 +36,6 @@ class InternationalWorkersDayTest extends RomaniaBaseTestCase implements Holiday * * @param int $year the year for which International Workers' Day needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testInternationalWorkersDay(int $year, DateTime $expected): void { @@ -48,7 +45,7 @@ public function testInternationalWorkersDay(int $year, DateTime $expected): void /** * Tests translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -63,7 +60,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Romania/NationalDayTest.php b/tests/Romania/NationalDayTest.php index b6a4caf8a..151a1d83d 100644 --- a/tests/Romania/NationalDayTest.php +++ b/tests/Romania/NationalDayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -40,7 +39,6 @@ class NationalDayTest extends RomaniaBaseTestCase implements HolidayTestCase * Tests National Day on or after 1990. * * @throws Exception - * @throws ReflectionException */ public function testNationalDayOnAfter1990(): void { @@ -57,7 +55,6 @@ public function testNationalDayOnAfter1990(): void * Tests National Day between 1948 - 1989. * * @throws Exception - * @throws ReflectionException */ public function testNationalDayBetween19481989(): void { @@ -74,7 +71,6 @@ public function testNationalDayBetween19481989(): void * Tests National Day between 1866 - 1947. * * @throws Exception - * @throws ReflectionException */ public function testNationalDayBetween18661947(): void { @@ -90,7 +86,7 @@ public function testNationalDayBetween18661947(): void /** * Tests National Day before 1865. * - * @throws ReflectionException + * @throws Exception */ public function testNationalDayBefore1865(): void { @@ -104,7 +100,7 @@ public function testNationalDayBefore1865(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -119,7 +115,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Romania/NewYearsDayTest.php b/tests/Romania/NewYearsDayTest.php index 7364e5666..0057acbc7 100644 --- a/tests/Romania/NewYearsDayTest.php +++ b/tests/Romania/NewYearsDayTest.php @@ -16,7 +16,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -37,8 +36,6 @@ class NewYearsDayTest extends RomaniaBaseTestCase implements HolidayTestCase * * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testHoliday(int $year, DateTime $expected): void { @@ -60,7 +57,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -75,7 +72,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Romania/PentecostMondayTest.php b/tests/Romania/PentecostMondayTest.php index 2d8bfeb49..c9116adcd 100644 --- a/tests/Romania/PentecostMondayTest.php +++ b/tests/Romania/PentecostMondayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -40,7 +39,6 @@ class PentecostMondayTest extends RomaniaBaseTestCase implements HolidayTestCase * Tests the Pentecost Monday Day on and after 2008. * * @throws Exception - * @throws ReflectionException */ public function testPentecostMondayOnAfter2008(): void { @@ -56,7 +54,7 @@ public function testPentecostMondayOnAfter2008(): void /** * Tests the Pentecost Day before 2008. * - * @throws ReflectionException + * @throws Exception */ public function testPentecostMondayBefore2008(): void { @@ -70,7 +68,7 @@ public function testPentecostMondayBefore2008(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -85,7 +83,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Romania/PentecostTest.php b/tests/Romania/PentecostTest.php index a913ab387..a8eeff335 100644 --- a/tests/Romania/PentecostTest.php +++ b/tests/Romania/PentecostTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -40,7 +39,6 @@ class PentecostTest extends RomaniaBaseTestCase implements HolidayTestCase * Tests the Pentecost Day on and after 2008. * * @throws Exception - * @throws ReflectionException */ public function testPentecostDayOnAfter2008(): void { @@ -56,7 +54,7 @@ public function testPentecostDayOnAfter2008(): void /** * Tests the Pentecost Day before 2008. * - * @throws ReflectionException + * @throws Exception */ public function testPentecostDayBefore2008(): void { @@ -70,7 +68,7 @@ public function testPentecostDayBefore2008(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -85,7 +83,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Romania/RomaniaTest.php b/tests/Romania/RomaniaTest.php index da4d4ea9c..1d4d48a7e 100755 --- a/tests/Romania/RomaniaTest.php +++ b/tests/Romania/RomaniaTest.php @@ -31,6 +31,8 @@ class RomaniaTest extends RomaniaBaseTestCase implements ProviderTestCase /** * Initial setup of this Test Case. + * + * @throws \Exception */ protected function setUp(): void { @@ -39,8 +41,6 @@ protected function setUp(): void /** * Tests if all official holidays in Romania are defined by the provider class. - * - * @throws ReflectionException */ public function testOfficialHolidays(): void { @@ -69,8 +69,6 @@ public function testOfficialHolidays(): void /** * Tests if all observed holidays in Romania are defined by the provider class. - * - * @throws ReflectionException */ public function testObservedHolidays(): void { @@ -89,8 +87,6 @@ public function testObservedHolidays(): void /** * Tests if all seasonal holidays in Romania are defined by the provider class. - * - * @throws ReflectionException */ public function testSeasonalHolidays(): void { @@ -99,8 +95,6 @@ public function testSeasonalHolidays(): void /** * Tests if all bank holidays in Romania are defined by the provider class. - * - * @throws ReflectionException */ public function testBankHolidays(): void { @@ -109,8 +103,6 @@ public function testBankHolidays(): void /** * Tests if all other holidays in Romania are defined by the provider class. - * - * @throws ReflectionException */ public function testOtherHolidays(): void { @@ -119,6 +111,7 @@ public function testOtherHolidays(): void /** * @throws ReflectionException + * @throws \Exception */ public function testSources(): void { diff --git a/tests/Romania/SecondChristmasDayTest.php b/tests/Romania/SecondChristmasDayTest.php index 70ccfc7fb..f7f8229fa 100644 --- a/tests/Romania/SecondChristmasDayTest.php +++ b/tests/Romania/SecondChristmasDayTest.php @@ -16,7 +16,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -37,8 +36,6 @@ class SecondChristmasDayTest extends RomaniaBaseTestCase implements HolidayTestC * * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testHoliday(int $year, DateTime $expected): void { @@ -60,7 +57,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -75,7 +72,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Romania/StAndrewsDayTest.php b/tests/Romania/StAndrewsDayTest.php index 744d47c1f..f1dfe979a 100644 --- a/tests/Romania/StAndrewsDayTest.php +++ b/tests/Romania/StAndrewsDayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -40,7 +39,6 @@ class StAndrewsDayTest extends RomaniaBaseTestCase implements HolidayTestCase * Tests Saint Andrew Day on or after 2012. * * @throws Exception - * @throws ReflectionException */ public function testStAndrewDayOnAfter2012(): void { @@ -56,7 +54,7 @@ public function testStAndrewDayOnAfter2012(): void /** * Tests Saint Andrew before 2012. * - * @throws ReflectionException + * @throws Exception */ public function testStAndrewDayBefore2012(): void { @@ -70,7 +68,7 @@ public function testStAndrewDayBefore2012(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -85,7 +83,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Romania/UnitedPrincipalitiesDayTest.php b/tests/Romania/UnitedPrincipalitiesDayTest.php index 53e8a5a0d..9030e9f22 100644 --- a/tests/Romania/UnitedPrincipalitiesDayTest.php +++ b/tests/Romania/UnitedPrincipalitiesDayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -40,7 +39,6 @@ class UnitedPrincipalitiesDayTest extends RomaniaBaseTestCase implements Holiday * Tests united Principalities Day on or after 2015. * * @throws Exception - * @throws ReflectionException */ public function testUnitedPrincipalitiesDayOnAfter2015(): void { @@ -56,7 +54,7 @@ public function testUnitedPrincipalitiesDayOnAfter2015(): void /** * Tests unitedPrincipalitiesDay before 2015. * - * @throws ReflectionException + * @throws Exception */ public function testUnitedPrincipalitiesDayBefore2015(): void { @@ -70,7 +68,7 @@ public function testUnitedPrincipalitiesDayBefore2015(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -85,7 +83,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Russia/DefenceOfTheFatherlandDayTest.php b/tests/Russia/DefenceOfTheFatherlandDayTest.php index 88b552b60..a99f46505 100644 --- a/tests/Russia/DefenceOfTheFatherlandDayTest.php +++ b/tests/Russia/DefenceOfTheFatherlandDayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\Provider\Russia; use Yasumi\tests\HolidayTestCase; @@ -37,7 +36,7 @@ class DefenceOfTheFatherlandDayTest extends RussiaBaseTestCase implements Holida /** * Test if holiday is not defined before. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayBefore(): void { @@ -52,7 +51,6 @@ public function testHolidayBefore(): void * Test if holiday is defined after. * * @throws Exception - * @throws ReflectionException */ public function testHolidayAfter(): void { @@ -69,7 +67,7 @@ public function testHolidayAfter(): void /** * {@inheritdoc} * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -90,7 +88,7 @@ public function testTranslation(): void /** * {@inheritdoc} * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Russia/InternationalWomensDayTest.php b/tests/Russia/InternationalWomensDayTest.php index 0e176fc74..90e9554b7 100644 --- a/tests/Russia/InternationalWomensDayTest.php +++ b/tests/Russia/InternationalWomensDayTest.php @@ -17,7 +17,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -45,8 +44,6 @@ public function holidayDataProvider(): array /** * @dataProvider holidayDataProvider - * - * @throws ReflectionException */ public function testHoliday(int $year, DateTime $expected): void { @@ -56,7 +53,7 @@ public function testHoliday(int $year, DateTime $expected): void /** * {@inheritdoc} * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -71,7 +68,7 @@ public function testTranslation(): void /** * {@inheritdoc} * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Russia/NewYearHolidaysDay2Test.php b/tests/Russia/NewYearHolidaysDay2Test.php index e8a5294cc..09e4de01b 100644 --- a/tests/Russia/NewYearHolidaysDay2Test.php +++ b/tests/Russia/NewYearHolidaysDay2Test.php @@ -17,7 +17,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -45,8 +44,6 @@ public function holidayDataProvider(): array /** * @dataProvider holidayDataProvider - * - * @throws ReflectionException */ public function testHoliday(int $year, DateTime $expected): void { @@ -56,7 +53,7 @@ public function testHoliday(int $year, DateTime $expected): void /** * {@inheritdoc} * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -71,7 +68,7 @@ public function testTranslation(): void /** * {@inheritdoc} * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Russia/NewYearHolidaysDay3Test.php b/tests/Russia/NewYearHolidaysDay3Test.php index 202deec1f..cc43b19dd 100644 --- a/tests/Russia/NewYearHolidaysDay3Test.php +++ b/tests/Russia/NewYearHolidaysDay3Test.php @@ -17,7 +17,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -45,8 +44,6 @@ public function holidayDataProvider(): array /** * @dataProvider holidayDataProvider - * - * @throws ReflectionException */ public function testHoliday(int $year, DateTime $expected): void { @@ -56,7 +53,7 @@ public function testHoliday(int $year, DateTime $expected): void /** * {@inheritdoc} * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -71,7 +68,7 @@ public function testTranslation(): void /** * {@inheritdoc} * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Russia/NewYearHolidaysDay4Test.php b/tests/Russia/NewYearHolidaysDay4Test.php index cb4a3c4e0..a8b8f3fc6 100644 --- a/tests/Russia/NewYearHolidaysDay4Test.php +++ b/tests/Russia/NewYearHolidaysDay4Test.php @@ -16,7 +16,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -44,8 +43,6 @@ public function holidayDataProvider(): array /** * @dataProvider holidayDataProvider - * - * @throws ReflectionException */ public function testHoliday(int $year, DateTime $expected): void { @@ -55,7 +52,7 @@ public function testHoliday(int $year, DateTime $expected): void /** * {@inheritdoc} * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -70,7 +67,7 @@ public function testTranslation(): void /** * {@inheritdoc} * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Russia/NewYearHolidaysDay5Test.php b/tests/Russia/NewYearHolidaysDay5Test.php index fcf7b15f2..d58e6494a 100644 --- a/tests/Russia/NewYearHolidaysDay5Test.php +++ b/tests/Russia/NewYearHolidaysDay5Test.php @@ -17,7 +17,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -45,8 +44,6 @@ public function holidayDataProvider(): array /** * @dataProvider holidayDataProvider - * - * @throws ReflectionException */ public function testHoliday(int $year, DateTime $expected): void { @@ -56,7 +53,7 @@ public function testHoliday(int $year, DateTime $expected): void /** * {@inheritdoc} * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -71,7 +68,7 @@ public function testTranslation(): void /** * {@inheritdoc} * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Russia/NewYearHolidaysDay6Test.php b/tests/Russia/NewYearHolidaysDay6Test.php index 0ec5eea47..064b3fe0f 100644 --- a/tests/Russia/NewYearHolidaysDay6Test.php +++ b/tests/Russia/NewYearHolidaysDay6Test.php @@ -17,7 +17,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -45,8 +44,6 @@ public function holidayDataProvider(): array /** * @dataProvider holidayDataProvider - * - * @throws ReflectionException */ public function testHoliday(int $year, DateTime $expected): void { @@ -56,7 +53,7 @@ public function testHoliday(int $year, DateTime $expected): void /** * {@inheritdoc} * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -71,7 +68,7 @@ public function testTranslation(): void /** * {@inheritdoc} * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Russia/NewYearHolidaysDay8Test.php b/tests/Russia/NewYearHolidaysDay8Test.php index a044061ba..4d16962af 100644 --- a/tests/Russia/NewYearHolidaysDay8Test.php +++ b/tests/Russia/NewYearHolidaysDay8Test.php @@ -16,7 +16,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -44,8 +43,6 @@ public function holidayDataProvider(): array /** * @dataProvider holidayDataProvider - * - * @throws ReflectionException */ public function testHoliday(int $year, DateTime $expected): void { @@ -55,7 +52,7 @@ public function testHoliday(int $year, DateTime $expected): void /** * {@inheritdoc} * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -70,7 +67,7 @@ public function testTranslation(): void /** * {@inheritdoc} * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Russia/NewYearsDayTest.php b/tests/Russia/NewYearsDayTest.php index ddda23516..2d987158b 100644 --- a/tests/Russia/NewYearsDayTest.php +++ b/tests/Russia/NewYearsDayTest.php @@ -17,7 +17,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -45,8 +44,6 @@ public function holidayDataProvider(): array /** * @dataProvider holidayDataProvider - * - * @throws ReflectionException */ public function testHoliday(int $year, DateTime $expected): void { @@ -56,7 +53,7 @@ public function testHoliday(int $year, DateTime $expected): void /** * {@inheritdoc} * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -71,7 +68,7 @@ public function testTranslation(): void /** * {@inheritdoc} * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Russia/OrthodoxChristmasDayTest.php b/tests/Russia/OrthodoxChristmasDayTest.php index d06f102a6..a6d71f1ca 100644 --- a/tests/Russia/OrthodoxChristmasDayTest.php +++ b/tests/Russia/OrthodoxChristmasDayTest.php @@ -17,7 +17,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -45,8 +44,6 @@ public function holidayDataProvider(): array /** * @dataProvider holidayDataProvider - * - * @throws ReflectionException */ public function testHoliday(int $year, DateTime $expected): void { @@ -56,7 +53,7 @@ public function testHoliday(int $year, DateTime $expected): void /** * {@inheritdoc} * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -71,7 +68,7 @@ public function testTranslation(): void /** * {@inheritdoc} * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Russia/RussiaDayTest.php b/tests/Russia/RussiaDayTest.php index 65b39e495..ed068bed7 100644 --- a/tests/Russia/RussiaDayTest.php +++ b/tests/Russia/RussiaDayTest.php @@ -18,7 +18,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\Provider\Russia; use Yasumi\tests\HolidayTestCase; @@ -38,7 +37,7 @@ class RussiaDayTest extends RussiaBaseTestCase implements HolidayTestCase /** * Test if holiday is not defined before. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayBefore(): void { @@ -53,7 +52,6 @@ public function testHolidayBefore(): void * Test if holiday is defined after. * * @throws Exception - * @throws ReflectionException */ public function testHolidayAfter(): void { @@ -70,7 +68,7 @@ public function testHolidayAfter(): void /** * {@inheritdoc} * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -91,7 +89,7 @@ public function testTranslation(): void /** * {@inheritdoc} * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Russia/RussiaTest.php b/tests/Russia/RussiaTest.php index 0bcb60236..bb8fde6bf 100644 --- a/tests/Russia/RussiaTest.php +++ b/tests/Russia/RussiaTest.php @@ -30,7 +30,7 @@ class RussiaTest extends RussiaBaseTestCase implements ProviderTestCase /** * Tests if all official holidays in Russia are defined by the provider class. * - * @throws ReflectionException + * @throws \Exception */ public function testOfficialHolidays(): void { @@ -68,7 +68,7 @@ public function testOfficialHolidays(): void /** * Tests if all observed holidays in Russia are defined by the provider class. * - * @throws ReflectionException + * @throws \Exception */ public function testObservedHolidays(): void { @@ -78,7 +78,7 @@ public function testObservedHolidays(): void /** * Tests if all seasonal holidays in Russia are defined by the provider class. * - * @throws ReflectionException + * @throws \Exception */ public function testSeasonalHolidays(): void { @@ -88,7 +88,7 @@ public function testSeasonalHolidays(): void /** * Tests if all bank holidays in Russia are defined by the provider class. * - * @throws ReflectionException + * @throws \Exception */ public function testBankHolidays(): void { @@ -98,7 +98,7 @@ public function testBankHolidays(): void /** * Tests if all other holidays in Russia are defined by the provider class. * - * @throws ReflectionException + * @throws \Exception */ public function testOtherHolidays(): void { @@ -107,6 +107,7 @@ public function testOtherHolidays(): void /** * @throws ReflectionException + * @throws \Exception */ public function testSources(): void { diff --git a/tests/Russia/SpringAndLabourDayTest.php b/tests/Russia/SpringAndLabourDayTest.php index bce11c436..3801c7393 100644 --- a/tests/Russia/SpringAndLabourDayTest.php +++ b/tests/Russia/SpringAndLabourDayTest.php @@ -17,7 +17,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -45,8 +44,6 @@ public function holidayDataProvider(): array /** * @dataProvider holidayDataProvider - * - * @throws ReflectionException */ public function testHoliday(int $year, DateTime $expected): void { @@ -56,7 +53,7 @@ public function testHoliday(int $year, DateTime $expected): void /** * {@inheritdoc} * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -71,7 +68,7 @@ public function testTranslation(): void /** * {@inheritdoc} * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Russia/UnityDayTest.php b/tests/Russia/UnityDayTest.php index 64287fea7..2d071adab 100644 --- a/tests/Russia/UnityDayTest.php +++ b/tests/Russia/UnityDayTest.php @@ -18,7 +18,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\Provider\Russia; use Yasumi\tests\HolidayTestCase; @@ -38,7 +37,7 @@ class UnityDayTest extends RussiaBaseTestCase implements HolidayTestCase /** * Test if holiday is not defined before. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayBefore(): void { @@ -53,7 +52,6 @@ public function testHolidayBefore(): void * Test if holiday is defined after. * * @throws Exception - * @throws ReflectionException */ public function testHolidayAfter(): void { @@ -70,7 +68,7 @@ public function testHolidayAfter(): void /** * {@inheritdoc} * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -91,7 +89,7 @@ public function testTranslation(): void /** * {@inheritdoc} * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Russia/VictoryDayTest.php b/tests/Russia/VictoryDayTest.php index 2b2d29acd..db7980ac9 100644 --- a/tests/Russia/VictoryDayTest.php +++ b/tests/Russia/VictoryDayTest.php @@ -17,7 +17,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -45,8 +44,6 @@ public function holidayDataProvider(): array /** * @dataProvider holidayDataProvider - * - * @throws ReflectionException */ public function testHoliday(int $year, DateTime $expected): void { @@ -56,7 +53,7 @@ public function testHoliday(int $year, DateTime $expected): void /** * {@inheritdoc} * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -71,7 +68,7 @@ public function testTranslation(): void /** * {@inheritdoc} * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Slovakia/AllSaintsDayTest.php b/tests/Slovakia/AllSaintsDayTest.php index af032e4d7..1183fa017 100644 --- a/tests/Slovakia/AllSaintsDayTest.php +++ b/tests/Slovakia/AllSaintsDayTest.php @@ -17,7 +17,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -40,8 +39,6 @@ class AllSaintsDayTest extends SlovakiaBaseTestCase implements HolidayTestCase * * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testHoliday(int $year, DateTime $expected): void { @@ -63,7 +60,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -78,7 +75,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Slovakia/ChristmasDayTest.php b/tests/Slovakia/ChristmasDayTest.php index 3e07372b3..a36d375e5 100644 --- a/tests/Slovakia/ChristmasDayTest.php +++ b/tests/Slovakia/ChristmasDayTest.php @@ -17,7 +17,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -40,8 +39,6 @@ class ChristmasDayTest extends SlovakiaBaseTestCase implements HolidayTestCase * * @param int $year the year for which Christmas Day needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testChristmasDay(int $year, DateTime $expected): void { @@ -63,7 +60,7 @@ public function HolidayDataProvider(): array /** * Tests translated name of Christmas Day. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -78,7 +75,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Slovakia/ChristmasEveTest.php b/tests/Slovakia/ChristmasEveTest.php index eb94b65a7..94a6b9945 100644 --- a/tests/Slovakia/ChristmasEveTest.php +++ b/tests/Slovakia/ChristmasEveTest.php @@ -17,7 +17,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -40,8 +39,6 @@ class ChristmasEveTest extends SlovakiaBaseTestCase implements HolidayTestCase * * @param int $year the year for which Christmas Day needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testChristmasEve(int $year, DateTime $expected): void { @@ -63,7 +60,7 @@ public function HolidayDataProvider(): array /** * Tests translated name of Christmas Eve. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -78,7 +75,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Slovakia/EasterMondayTest.php b/tests/Slovakia/EasterMondayTest.php index 4aecaf8ad..385a52674 100644 --- a/tests/Slovakia/EasterMondayTest.php +++ b/tests/Slovakia/EasterMondayTest.php @@ -18,7 +18,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -41,8 +40,6 @@ class EasterMondayTest extends SlovakiaBaseTestCase implements HolidayTestCase * * @param int $year the year for which Christmas Day needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testHoliday(int $year, DateTime $expected): void { @@ -75,7 +72,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -90,7 +87,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Slovakia/EpiphanyTest.php b/tests/Slovakia/EpiphanyTest.php index 273ad8dd7..438759f41 100644 --- a/tests/Slovakia/EpiphanyTest.php +++ b/tests/Slovakia/EpiphanyTest.php @@ -17,7 +17,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -40,8 +39,6 @@ class EpiphanyTest extends SlovakiaBaseTestCase implements HolidayTestCase * * @param int $year the year for which Christmas Day needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testHoliday(int $year, DateTime $expected): void { @@ -63,7 +60,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -78,7 +75,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Slovakia/GoodFridayTest.php b/tests/Slovakia/GoodFridayTest.php index 8a19a81b8..3bf9ce0f2 100644 --- a/tests/Slovakia/GoodFridayTest.php +++ b/tests/Slovakia/GoodFridayTest.php @@ -18,7 +18,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -41,8 +40,6 @@ class GoodFridayTest extends SlovakiaBaseTestCase implements HolidayTestCase * * @param int $year the year for which Christmas Day needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testHoliday(int $year, DateTime $expected): void { @@ -75,7 +72,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -90,7 +87,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Slovakia/InternationalWorkersDayTest.php b/tests/Slovakia/InternationalWorkersDayTest.php index ff3c4ac88..a82d1dfa6 100644 --- a/tests/Slovakia/InternationalWorkersDayTest.php +++ b/tests/Slovakia/InternationalWorkersDayTest.php @@ -17,7 +17,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -40,8 +39,6 @@ class InternationalWorkersDayTest extends SlovakiaBaseTestCase implements Holida * * @param int $year the year for which Christmas Day needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testHoliday(int $year, DateTime $expected): void { @@ -63,7 +60,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -78,7 +75,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Slovakia/OurLadyOfSorrowsDayTest.php b/tests/Slovakia/OurLadyOfSorrowsDayTest.php index 86f1ba46d..be773eec0 100644 --- a/tests/Slovakia/OurLadyOfSorrowsDayTest.php +++ b/tests/Slovakia/OurLadyOfSorrowsDayTest.php @@ -17,7 +17,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -40,8 +39,6 @@ class OurLadyOfSorrowsDayTest extends SlovakiaBaseTestCase implements HolidayTes * * @param int $year the year for which Christmas Day needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testHoliday(int $year, DateTime $expected): void { @@ -63,7 +60,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -78,7 +75,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Slovakia/SaintsCyrilAndMethodiusDayTest.php b/tests/Slovakia/SaintsCyrilAndMethodiusDayTest.php index 12b9cf024..fc88c8d4e 100644 --- a/tests/Slovakia/SaintsCyrilAndMethodiusDayTest.php +++ b/tests/Slovakia/SaintsCyrilAndMethodiusDayTest.php @@ -17,7 +17,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -40,8 +39,6 @@ class SaintsCyrilAndMethodiusDayTest extends SlovakiaBaseTestCase implements Hol * * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testHoliday(int $year, DateTime $expected): void { @@ -63,7 +60,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -78,7 +75,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Slovakia/SecondChristmasDayTest.php b/tests/Slovakia/SecondChristmasDayTest.php index 1d2ffc773..1abc8bce3 100644 --- a/tests/Slovakia/SecondChristmasDayTest.php +++ b/tests/Slovakia/SecondChristmasDayTest.php @@ -17,7 +17,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -40,8 +39,6 @@ class SecondChristmasDayTest extends SlovakiaBaseTestCase implements HolidayTest * * @param int $year the year for which Christmas Day needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testHoliday(int $year, DateTime $expected): void { @@ -63,7 +60,7 @@ public function HolidayDataProvider(): array /** * Tests translated name of Second Christmas Day. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -78,7 +75,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Slovakia/SlovakConstitutionDayTest.php b/tests/Slovakia/SlovakConstitutionDayTest.php index 0393a0129..08bc7c15c 100644 --- a/tests/Slovakia/SlovakConstitutionDayTest.php +++ b/tests/Slovakia/SlovakConstitutionDayTest.php @@ -17,7 +17,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -40,8 +39,6 @@ class SlovakConstitutionDayTest extends SlovakiaBaseTestCase implements HolidayT * * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testHoliday(int $year, DateTime $expected): void { @@ -63,7 +60,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -78,7 +75,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Slovakia/SlovakIndependeceDayTest.php b/tests/Slovakia/SlovakIndependeceDayTest.php index ae1ef9d71..a81ba13ec 100644 --- a/tests/Slovakia/SlovakIndependeceDayTest.php +++ b/tests/Slovakia/SlovakIndependeceDayTest.php @@ -17,7 +17,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -41,8 +40,6 @@ class SlovakIndependeceDayTest extends SlovakiaBaseTestCase implements HolidayTe * * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testHoliday(int $year, DateTime $expected): void { @@ -64,7 +61,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -79,7 +76,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Slovakia/SlovakNationalUprisingDayTest.php b/tests/Slovakia/SlovakNationalUprisingDayTest.php index dbb667c89..2cef159b6 100644 --- a/tests/Slovakia/SlovakNationalUprisingDayTest.php +++ b/tests/Slovakia/SlovakNationalUprisingDayTest.php @@ -17,7 +17,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -40,8 +39,6 @@ class SlovakNationalUprisingDayTest extends SlovakiaBaseTestCase implements Holi * * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testHoliday(int $year, DateTime $expected): void { @@ -63,7 +60,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -78,7 +75,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Slovakia/SlovakiaTest.php b/tests/Slovakia/SlovakiaTest.php index 305821833..5cb85e7bf 100644 --- a/tests/Slovakia/SlovakiaTest.php +++ b/tests/Slovakia/SlovakiaTest.php @@ -33,6 +33,8 @@ class SlovakiaTest extends SlovakiaBaseTestCase implements ProviderTestCase /** * Initial setup of this Test Case. + * + * @throws \Exception */ protected function setUp(): void { @@ -42,8 +44,6 @@ protected function setUp(): void /** * Tests if all official holidays in Slovakia are defined by the provider class. - * - * @throws ReflectionException */ public function testOfficialHolidays(): void { @@ -58,8 +58,6 @@ public function testOfficialHolidays(): void /** * Tests if all bank holidays in Slovakia are defined by the provider class. - * - * @throws ReflectionException */ public function testBankHolidays(): void { @@ -79,8 +77,6 @@ public function testBankHolidays(): void /** * Tests if all observed holidays in Slovakia are defined by the provider class. - * - * @throws ReflectionException */ public function testObservedHolidays(): void { @@ -89,8 +85,6 @@ public function testObservedHolidays(): void /** * Tests if all seasonal holidays in Slovakia are defined by the provider class. - * - * @throws ReflectionException */ public function testSeasonalHolidays(): void { @@ -99,8 +93,6 @@ public function testSeasonalHolidays(): void /** * Tests if all other holidays in Slovakia are defined by the provider class. - * - * @throws ReflectionException */ public function testOtherHolidays(): void { @@ -109,6 +101,7 @@ public function testOtherHolidays(): void /** * @throws ReflectionException + * @throws \Exception */ public function testSources(): void { diff --git a/tests/Slovakia/StruggleForFreedomAndDemocracyDayTest.php b/tests/Slovakia/StruggleForFreedomAndDemocracyDayTest.php index 5946e66f6..162ac5a68 100644 --- a/tests/Slovakia/StruggleForFreedomAndDemocracyDayTest.php +++ b/tests/Slovakia/StruggleForFreedomAndDemocracyDayTest.php @@ -17,7 +17,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -40,8 +39,6 @@ class StruggleForFreedomAndDemocracyDayTest extends SlovakiaBaseTestCase impleme * * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testHoliday(int $year, DateTime $expected): void { @@ -63,7 +60,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -78,7 +75,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Slovakia/VictoryInEuropeDayTest.php b/tests/Slovakia/VictoryInEuropeDayTest.php index ee3b13e20..f8947bb31 100644 --- a/tests/Slovakia/VictoryInEuropeDayTest.php +++ b/tests/Slovakia/VictoryInEuropeDayTest.php @@ -17,7 +17,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -40,8 +39,6 @@ class VictoryInEuropeDayTest extends SlovakiaBaseTestCase implements HolidayTest * * @param int $year the year for which Christmas Day needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testHoliday(int $year, DateTime $expected): void { @@ -63,7 +60,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -78,7 +75,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/SouthAfrica/ChristmasDayTest.php b/tests/SouthAfrica/ChristmasDayTest.php index 5145ec17f..2cc97e540 100644 --- a/tests/SouthAfrica/ChristmasDayTest.php +++ b/tests/SouthAfrica/ChristmasDayTest.php @@ -18,7 +18,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -49,7 +48,6 @@ class ChristmasDayTest extends SouthAfricaBaseTestCase implements HolidayTestCas * @param int $year the year for which the holiday defined in this test needs to be tested * @param string $expected the expected date * - * @throws ReflectionException * @throws Exception */ public function testHoliday(int $year, string $expected): void @@ -87,7 +85,7 @@ public function HolidayDataProvider(): array /** * Tests the holiday defined in this test before establishment. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayBeforeEstablishment(): void { @@ -101,7 +99,7 @@ public function testHolidayBeforeEstablishment(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -116,7 +114,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/SouthAfrica/FamilyDayTest.php b/tests/SouthAfrica/FamilyDayTest.php index 1f635a0ef..751a70a48 100644 --- a/tests/SouthAfrica/FamilyDayTest.php +++ b/tests/SouthAfrica/FamilyDayTest.php @@ -18,7 +18,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -49,7 +48,6 @@ class FamilyDayTest extends SouthAfricaBaseTestCase implements HolidayTestCase * @param int $year the year for which the holiday defined in this test needs to be tested * @param string $expected the expected date * - * @throws ReflectionException * @throws Exception */ public function testHoliday(int $year, string $expected): void @@ -86,7 +84,7 @@ public function HolidayDataProvider(): array /** * Tests the holiday defined in this test before establishment. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayBeforeEstablishment(): void { @@ -100,7 +98,7 @@ public function testHolidayBeforeEstablishment(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -115,7 +113,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/SouthAfrica/FreedomDayTest.php b/tests/SouthAfrica/FreedomDayTest.php index fc9d7f641..4b9184b95 100644 --- a/tests/SouthAfrica/FreedomDayTest.php +++ b/tests/SouthAfrica/FreedomDayTest.php @@ -18,7 +18,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -49,7 +48,6 @@ class FreedomDayTest extends SouthAfricaBaseTestCase implements HolidayTestCase * @param int $year the year for which the holiday defined in this test needs to be tested * @param string $expected the expected date * - * @throws ReflectionException * @throws Exception */ public function testHoliday(int $year, string $expected): void @@ -87,7 +85,7 @@ public function HolidayDataProvider(): array /** * Tests the holiday defined in this test before establishment. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayBeforeEstablishment(): void { @@ -101,7 +99,7 @@ public function testHolidayBeforeEstablishment(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -116,7 +114,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/SouthAfrica/GoodFridayTest.php b/tests/SouthAfrica/GoodFridayTest.php index 440deff88..9bc753408 100644 --- a/tests/SouthAfrica/GoodFridayTest.php +++ b/tests/SouthAfrica/GoodFridayTest.php @@ -18,7 +18,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -49,7 +48,6 @@ class GoodFridayTest extends SouthAfricaBaseTestCase implements HolidayTestCase * @param int $year the year for which the holiday defined in this test needs to be tested * @param string $expected the expected date * - * @throws ReflectionException * @throws Exception */ public function testHoliday(int $year, string $expected): void @@ -86,7 +84,7 @@ public function HolidayDataProvider(): array /** * Tests the holiday defined in this test before establishment. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayBeforeEstablishment(): void { @@ -100,7 +98,7 @@ public function testHolidayBeforeEstablishment(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -115,7 +113,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/SouthAfrica/HeritageDayTest.php b/tests/SouthAfrica/HeritageDayTest.php index db48aefd8..06bb662f4 100644 --- a/tests/SouthAfrica/HeritageDayTest.php +++ b/tests/SouthAfrica/HeritageDayTest.php @@ -18,7 +18,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -49,7 +48,6 @@ class HeritageDayTest extends SouthAfricaBaseTestCase implements HolidayTestCase * @param int $year the year for which the holiday defined in this test needs to be tested * @param string $expected the expected date * - * @throws ReflectionException * @throws Exception */ public function testHoliday(int $year, string $expected): void @@ -87,7 +85,7 @@ public function HolidayDataProvider(): array /** * Tests the holiday defined in this test before establishment. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayBeforeEstablishment(): void { @@ -101,7 +99,7 @@ public function testHolidayBeforeEstablishment(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -116,7 +114,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/SouthAfrica/HumanRightsDayTest.php b/tests/SouthAfrica/HumanRightsDayTest.php index acc33a3e2..bfbd2d47e 100644 --- a/tests/SouthAfrica/HumanRightsDayTest.php +++ b/tests/SouthAfrica/HumanRightsDayTest.php @@ -18,7 +18,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -49,7 +48,6 @@ class HumanRightsDayTest extends SouthAfricaBaseTestCase implements HolidayTestC * @param int $year the year for which the holiday defined in this test needs to be tested * @param string $expected the expected date * - * @throws ReflectionException * @throws Exception */ public function testHoliday(int $year, string $expected): void @@ -87,7 +85,7 @@ public function HolidayDataProvider(): array /** * Tests the holiday defined in this test before establishment. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayBeforeEstablishment(): void { @@ -101,7 +99,7 @@ public function testHolidayBeforeEstablishment(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -116,7 +114,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/SouthAfrica/MunicipalElections2016DayTest.php b/tests/SouthAfrica/MunicipalElections2016DayTest.php index 644b7d90c..47c1ee4c9 100644 --- a/tests/SouthAfrica/MunicipalElections2016DayTest.php +++ b/tests/SouthAfrica/MunicipalElections2016DayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -44,7 +43,6 @@ class MunicipalElections2016DayTest extends SouthAfricaBaseTestCase implements H * Tests the holiday defined in this test on or after establishment. * * @throws Exception - * @throws ReflectionException */ public function testHolidayOnAfterEstablishment(): void { @@ -59,7 +57,7 @@ public function testHolidayOnAfterEstablishment(): void /** * Tests the holiday defined in this test before establishment. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayBeforeEstablishment(): void { @@ -73,7 +71,7 @@ public function testHolidayBeforeEstablishment(): void /** * Tests the holiday defined in this test after completion. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayDayAfterCompletion(): void { @@ -83,7 +81,7 @@ public function testHolidayDayAfterCompletion(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -98,7 +96,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/SouthAfrica/NationalWomensDayTest.php b/tests/SouthAfrica/NationalWomensDayTest.php index a75b61783..6c5c7bbd3 100644 --- a/tests/SouthAfrica/NationalWomensDayTest.php +++ b/tests/SouthAfrica/NationalWomensDayTest.php @@ -18,7 +18,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -49,7 +48,6 @@ class NationalWomensDayTest extends SouthAfricaBaseTestCase implements HolidayTe * @param int $year the year for which the holiday defined in this test needs to be tested * @param string $expected the expected date * - * @throws ReflectionException * @throws Exception */ public function testHoliday(int $year, string $expected): void @@ -87,7 +85,7 @@ public function HolidayDataProvider(): array /** * Tests the holiday defined in this test before establishment. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayBeforeEstablishment(): void { @@ -101,7 +99,7 @@ public function testHolidayBeforeEstablishment(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -116,7 +114,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/SouthAfrica/NewYearsDayTest.php b/tests/SouthAfrica/NewYearsDayTest.php index ac177ddf5..d8735dfe5 100644 --- a/tests/SouthAfrica/NewYearsDayTest.php +++ b/tests/SouthAfrica/NewYearsDayTest.php @@ -18,7 +18,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -49,7 +48,6 @@ class NewYearsDayTest extends SouthAfricaBaseTestCase implements HolidayTestCase * @param int $year the year for which the holiday defined in this test needs to be tested * @param string $expected the expected date * - * @throws ReflectionException * @throws Exception */ public function testHoliday(int $year, string $expected): void @@ -87,7 +85,7 @@ public function HolidayDataProvider(): array /** * Tests the holiday defined in this test before establishment. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayBeforeEstablishment(): void { @@ -101,7 +99,7 @@ public function testHolidayBeforeEstablishment(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -116,7 +114,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/SouthAfrica/ReconciliationDayTest.php b/tests/SouthAfrica/ReconciliationDayTest.php index e47f08359..010656e65 100644 --- a/tests/SouthAfrica/ReconciliationDayTest.php +++ b/tests/SouthAfrica/ReconciliationDayTest.php @@ -18,7 +18,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -49,7 +48,6 @@ class ReconciliationDayTest extends SouthAfricaBaseTestCase implements HolidayTe * @param int $year the year for which the holiday defined in this test needs to be tested * @param string $expected the expected date * - * @throws ReflectionException * @throws Exception */ public function testHoliday(int $year, string $expected): void @@ -87,7 +85,7 @@ public function HolidayDataProvider(): array /** * Tests the holiday defined in this test before establishment. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayBeforeEstablishment(): void { @@ -101,7 +99,7 @@ public function testHolidayBeforeEstablishment(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -116,7 +114,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/SouthAfrica/SecondChristmasDayTest.php b/tests/SouthAfrica/SecondChristmasDayTest.php index 6ef19f7d8..f4519ed06 100644 --- a/tests/SouthAfrica/SecondChristmasDayTest.php +++ b/tests/SouthAfrica/SecondChristmasDayTest.php @@ -18,7 +18,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -49,7 +48,6 @@ class SecondChristmasDayTest extends SouthAfricaBaseTestCase implements HolidayT * @param int $year the year for which the holiday defined in this test needs to be tested * @param string $expected the expected date * - * @throws ReflectionException * @throws Exception */ public function testHoliday(int $year, string $expected): void @@ -87,7 +85,7 @@ public function HolidayDataProvider(): array /** * Tests the holiday defined in this test before establishment. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayBeforeEstablishment(): void { @@ -101,7 +99,7 @@ public function testHolidayBeforeEstablishment(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -116,7 +114,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/SouthAfrica/SouthAfricaTest.php b/tests/SouthAfrica/SouthAfricaTest.php index c3dc937eb..66a882034 100644 --- a/tests/SouthAfrica/SouthAfricaTest.php +++ b/tests/SouthAfrica/SouthAfricaTest.php @@ -29,10 +29,12 @@ class SouthAfricaTest extends SouthAfricaBaseTestCase implements ProviderTestCas /** * @var int year random year number used for all tests in this Test Case */ - protected $year; + protected int $year; /** * Initial setup of this Test Case. + * + * @throws \Exception */ protected function setUp(): void { @@ -41,8 +43,6 @@ protected function setUp(): void /** * Tests if all official holidays in SouthAfrica are defined by the provider class. - * - * @throws ReflectionException */ public function testOfficialHolidays(): void { @@ -71,8 +71,6 @@ public function testOfficialHolidays(): void /** * Tests if all bank holidays in South Africa are defined by the provider class. - * - * @throws ReflectionException */ public function testBankHolidays(): void { @@ -81,8 +79,6 @@ public function testBankHolidays(): void /** * Tests if all observed holidays in South Africa are defined by the provider class. - * - * @throws ReflectionException */ public function testObservedHolidays(): void { @@ -91,8 +87,6 @@ public function testObservedHolidays(): void /** * Tests if all seasonal holidays in South Africa are defined by the provider class. - * - * @throws ReflectionException */ public function testSeasonalHolidays(): void { @@ -101,8 +95,6 @@ public function testSeasonalHolidays(): void /** * Tests if all other holidays in South Africa are defined by the provider class. - * - * @throws ReflectionException */ public function testOtherHolidays(): void { @@ -111,6 +103,7 @@ public function testOtherHolidays(): void /** * @throws ReflectionException + * @throws \Exception */ public function testSources(): void { diff --git a/tests/SouthAfrica/SubstituteDayOfGoodwillTest.php b/tests/SouthAfrica/SubstituteDayOfGoodwillTest.php index 0b660ee1a..26aaadb16 100644 --- a/tests/SouthAfrica/SubstituteDayOfGoodwillTest.php +++ b/tests/SouthAfrica/SubstituteDayOfGoodwillTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -44,7 +43,6 @@ class SubstituteDayOfGoodwillTest extends SouthAfricaBaseTestCase implements Hol * Tests the holiday defined in this test on or after establishment. * * @throws Exception - * @throws ReflectionException */ public function testHolidayOnAfterEstablishment(): void { @@ -59,7 +57,7 @@ public function testHolidayOnAfterEstablishment(): void /** * Tests the holiday defined in this test before establishment. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayBeforeEstablishment(): void { @@ -73,7 +71,7 @@ public function testHolidayBeforeEstablishment(): void /** * Tests the holiday defined in this test after completion. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayDayAfterCompletion(): void { @@ -83,7 +81,7 @@ public function testHolidayDayAfterCompletion(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -98,7 +96,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/SouthAfrica/WorkersDayTest.php b/tests/SouthAfrica/WorkersDayTest.php index 4c3f1d994..a0be0cf41 100644 --- a/tests/SouthAfrica/WorkersDayTest.php +++ b/tests/SouthAfrica/WorkersDayTest.php @@ -18,7 +18,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -49,7 +48,6 @@ class WorkersDayTest extends SouthAfricaBaseTestCase implements HolidayTestCase * @param int $year the year for which the holiday defined in this test needs to be tested * @param string $expected the expected date * - * @throws ReflectionException * @throws Exception */ public function testHoliday(int $year, string $expected): void @@ -87,7 +85,7 @@ public function HolidayDataProvider(): array /** * Tests the holiday defined in this test before establishment. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayBeforeEstablishment(): void { @@ -101,7 +99,7 @@ public function testHolidayBeforeEstablishment(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -116,7 +114,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/SouthAfrica/YouthDayTest.php b/tests/SouthAfrica/YouthDayTest.php index b736fded7..81ce3c8d7 100644 --- a/tests/SouthAfrica/YouthDayTest.php +++ b/tests/SouthAfrica/YouthDayTest.php @@ -18,7 +18,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -49,7 +48,6 @@ class YouthDayTest extends SouthAfricaBaseTestCase implements HolidayTestCase * @param int $year the year for which the holiday defined in this test needs to be tested * @param string $expected the expected date * - * @throws ReflectionException * @throws Exception */ public function testHoliday(int $year, string $expected): void @@ -87,7 +85,7 @@ public function HolidayDataProvider(): array /** * Tests the holiday defined in this test before establishment. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayBeforeEstablishment(): void { @@ -101,7 +99,7 @@ public function testHolidayBeforeEstablishment(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -116,7 +114,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/SouthKorea/ArborDayTest.php b/tests/SouthKorea/ArborDayTest.php index 396f8e92a..0e14aeea1 100644 --- a/tests/SouthKorea/ArborDayTest.php +++ b/tests/SouthKorea/ArborDayTest.php @@ -18,7 +18,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -50,7 +49,6 @@ class ArborDayTest extends SouthKoreaBaseTestCase implements HolidayTestCase * Tests the holiday defined in this test. * * @throws Exception - * @throws ReflectionException */ public function testHoliday(): void { @@ -74,7 +72,7 @@ public function testHoliday(): void /** * Tests the holiday defined in this test after removal. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayAfterRemoval(): void { @@ -88,7 +86,7 @@ public function testHolidayAfterRemoval(): void /** * Tests the holiday defined in this test before establishment. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayBeforeEstablishment(): void { @@ -102,7 +100,7 @@ public function testHolidayBeforeEstablishment(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -120,7 +118,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/SouthKorea/ArmedForcesDayTest.php b/tests/SouthKorea/ArmedForcesDayTest.php index 93169afc9..2a1399755 100644 --- a/tests/SouthKorea/ArmedForcesDayTest.php +++ b/tests/SouthKorea/ArmedForcesDayTest.php @@ -18,7 +18,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -46,7 +45,6 @@ class ArmedForcesDayTest extends SouthKoreaBaseTestCase implements HolidayTestCa * Tests the holiday defined in this test. * * @throws Exception - * @throws ReflectionException */ public function testHoliday(): void { @@ -62,7 +60,7 @@ public function testHoliday(): void /** * Tests the holiday defined in this test after removal. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayAfterRemoval(): void { @@ -76,7 +74,7 @@ public function testHolidayAfterRemoval(): void /** * Tests the holiday defined in this test before establishment. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayBeforeEstablishment(): void { @@ -90,7 +88,7 @@ public function testHolidayBeforeEstablishment(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -105,7 +103,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/SouthKorea/BuddhasBirthdayTest.php b/tests/SouthKorea/BuddhasBirthdayTest.php index aade35964..100e043f9 100644 --- a/tests/SouthKorea/BuddhasBirthdayTest.php +++ b/tests/SouthKorea/BuddhasBirthdayTest.php @@ -18,7 +18,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\Provider\SouthKorea; use Yasumi\tests\HolidayTestCase; @@ -42,7 +41,6 @@ class BuddhasBirthdayTest extends SouthKoreaBaseTestCase implements HolidayTestC * Tests the holiday defined in this test. * * @throws Exception - * @throws ReflectionException */ public function testHoliday(): void { @@ -60,7 +58,7 @@ public function testHoliday(): void /** * Tests the holiday defined in this test before establishment. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayBeforeEstablishment(): void { @@ -74,7 +72,7 @@ public function testHolidayBeforeEstablishment(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -92,7 +90,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/SouthKorea/ChildrensDayTest.php b/tests/SouthKorea/ChildrensDayTest.php index 5fd2a8b01..151a09430 100644 --- a/tests/SouthKorea/ChildrensDayTest.php +++ b/tests/SouthKorea/ChildrensDayTest.php @@ -18,7 +18,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -41,7 +40,6 @@ class ChildrensDayTest extends SouthKoreaBaseTestCase implements HolidayTestCase * Tests the holiday defined in this test. * * @throws Exception - * @throws ReflectionException */ public function testHoliday(): void { @@ -58,7 +56,6 @@ public function testHoliday(): void * Tests the substitute holiday defined in this test (conflict with Buddha's Birthday). * * @throws Exception - * @throws ReflectionException */ public function testSubstituteHolidayByBuddhasBirthday(): void { @@ -85,7 +82,6 @@ public function testSubstituteHolidayByBuddhasBirthday(): void * Tests the substitute holiday defined in this test. * * @throws Exception - * @throws ReflectionException */ public function testSubstituteHoliday(): void { @@ -120,7 +116,7 @@ public function testSubstituteHoliday(): void /** * Tests the holiday defined in this test before establishment. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayBeforeEstablishment(): void { @@ -134,7 +130,7 @@ public function testHolidayBeforeEstablishment(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -149,7 +145,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/SouthKorea/ChristmasDayTest.php b/tests/SouthKorea/ChristmasDayTest.php index 700358ce5..6ffa74eab 100644 --- a/tests/SouthKorea/ChristmasDayTest.php +++ b/tests/SouthKorea/ChristmasDayTest.php @@ -18,7 +18,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -41,7 +40,6 @@ class ChristmasDayTest extends SouthKoreaBaseTestCase implements HolidayTestCase * Tests the holiday defined in this test. * * @throws Exception - * @throws ReflectionException */ public function testHoliday(): void { @@ -57,7 +55,7 @@ public function testHoliday(): void /** * Tests the holiday defined in this test before establishment. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayBeforeEstablishment(): void { @@ -71,7 +69,7 @@ public function testHolidayBeforeEstablishment(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -86,7 +84,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/SouthKorea/ChuseokTest.php b/tests/SouthKorea/ChuseokTest.php index 3061323aa..18998348f 100644 --- a/tests/SouthKorea/ChuseokTest.php +++ b/tests/SouthKorea/ChuseokTest.php @@ -19,7 +19,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\Provider\SouthKorea; use Yasumi\tests\HolidayTestCase; @@ -43,7 +42,6 @@ class ChuseokTest extends SouthKoreaBaseTestCase implements HolidayTestCase * Tests the holiday defined in this test. * * @throws Exception - * @throws ReflectionException */ public function testHoliday(): void { @@ -80,7 +78,6 @@ public function testHoliday(): void * Tests the substitute holiday defined in this test (conflict with Gaecheonjeol). * * @throws Exception - * @throws ReflectionException */ public function testSubstituteHolidayByGaecheonjeol(): void { @@ -125,7 +122,6 @@ public function testSubstituteHolidayByGaecheonjeol(): void * Tests the substitute holiday defined in this test (conflict with Sunday). * * @throws Exception - * @throws ReflectionException */ public function testSubstituteHoliday(): void { @@ -163,7 +159,7 @@ public function testSubstituteHoliday(): void /** * Tests the holiday defined in this test before establishment. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayBeforeEstablishment(): void { @@ -177,7 +173,7 @@ public function testHolidayBeforeEstablishment(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -211,7 +207,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/SouthKorea/ConstitutionDayTest.php b/tests/SouthKorea/ConstitutionDayTest.php index 58e5de3ea..0933b6f1a 100644 --- a/tests/SouthKorea/ConstitutionDayTest.php +++ b/tests/SouthKorea/ConstitutionDayTest.php @@ -18,7 +18,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -46,7 +45,6 @@ class ConstitutionDayTest extends SouthKoreaBaseTestCase implements HolidayTestC * Tests the holiday defined in this test. * * @throws Exception - * @throws ReflectionException */ public function testHoliday(): void { @@ -62,7 +60,7 @@ public function testHoliday(): void /** * Tests the holiday defined in this test after removal. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayAfterRemoval(): void { @@ -76,7 +74,7 @@ public function testHolidayAfterRemoval(): void /** * Tests the holiday defined in this test before establishment. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayBeforeEstablishment(): void { @@ -90,7 +88,7 @@ public function testHolidayBeforeEstablishment(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -105,7 +103,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/SouthKorea/GaecheonjeolTest.php b/tests/SouthKorea/GaecheonjeolTest.php index 96e1e3f95..eea712535 100644 --- a/tests/SouthKorea/GaecheonjeolTest.php +++ b/tests/SouthKorea/GaecheonjeolTest.php @@ -18,7 +18,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -41,7 +40,6 @@ class GaecheonjeolTest extends SouthKoreaBaseTestCase implements HolidayTestCase * Tests the holiday defined in this test. * * @throws Exception - * @throws ReflectionException */ public function testHoliday(): void { @@ -58,7 +56,6 @@ public function testHoliday(): void * Tests the substitute holiday defined in this test (conflict with Chuseok). * * @throws Exception - * @throws ReflectionException */ public function testSubstituteByChuseok(): void { @@ -85,7 +82,6 @@ public function testSubstituteByChuseok(): void * Tests the substitute holiday defined in this test. * * @throws Exception - * @throws ReflectionException */ public function testSubstituteHoliday(): void { @@ -121,7 +117,7 @@ public function testSubstituteHoliday(): void /** * Tests the holiday defined in this test before establishment. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayBeforeEstablishment(): void { @@ -135,7 +131,7 @@ public function testHolidayBeforeEstablishment(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -150,7 +146,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/SouthKorea/HangulDayTest.php b/tests/SouthKorea/HangulDayTest.php index b1680a802..dd540e8a4 100644 --- a/tests/SouthKorea/HangulDayTest.php +++ b/tests/SouthKorea/HangulDayTest.php @@ -18,7 +18,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -41,7 +40,6 @@ class HangulDayTest extends SouthKoreaBaseTestCase implements HolidayTestCase * Tests the holiday defined in this test. * * @throws Exception - * @throws ReflectionException */ public function testHoliday(): void { @@ -66,7 +64,6 @@ public function testHoliday(): void * Tests the substitute holiday defined in this test. * * @throws Exception - * @throws ReflectionException */ public function testSubstituteHoliday(): void { @@ -101,7 +98,7 @@ public function testSubstituteHoliday(): void /** * Tests the holiday defined in this test before establishment. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayBeforeEstablishment(): void { @@ -115,7 +112,7 @@ public function testHolidayBeforeEstablishment(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -133,7 +130,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/SouthKorea/IndependenceMovementDayTest.php b/tests/SouthKorea/IndependenceMovementDayTest.php index 2985afb3b..9bc657de6 100644 --- a/tests/SouthKorea/IndependenceMovementDayTest.php +++ b/tests/SouthKorea/IndependenceMovementDayTest.php @@ -18,7 +18,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -41,7 +40,6 @@ class IndependenceMovementDayTest extends SouthKoreaBaseTestCase implements Holi * Tests the holiday defined in this test. * * @throws Exception - * @throws ReflectionException */ public function testHoliday(): void { @@ -58,7 +56,6 @@ public function testHoliday(): void * Tests the substitute holiday defined in this test. * * @throws Exception - * @throws ReflectionException */ public function testSubstituteHoliday(): void { @@ -100,7 +97,7 @@ public function testSubstituteHoliday(): void /** * Tests the holiday defined in this test before establishment. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayBeforeEstablishment(): void { @@ -114,7 +111,7 @@ public function testHolidayBeforeEstablishment(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -129,7 +126,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/SouthKorea/LiberationDayTest.php b/tests/SouthKorea/LiberationDayTest.php index bfb501cde..24ffec961 100644 --- a/tests/SouthKorea/LiberationDayTest.php +++ b/tests/SouthKorea/LiberationDayTest.php @@ -18,7 +18,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -41,7 +40,6 @@ class LiberationDayTest extends SouthKoreaBaseTestCase implements HolidayTestCas * Tests the holiday defined in this test. * * @throws Exception - * @throws ReflectionException */ public function testHoliday(): void { @@ -58,7 +56,6 @@ public function testHoliday(): void * Tests the substitute holiday defined in this test. * * @throws Exception - * @throws ReflectionException */ public function testSubstituteHoliday(): void { @@ -95,7 +92,7 @@ public function testSubstituteHoliday(): void /** * Tests the holiday defined in this test before establishment. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayBeforeEstablishment(): void { @@ -109,7 +106,7 @@ public function testHolidayBeforeEstablishment(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -124,7 +121,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/SouthKorea/MemorialDayTest.php b/tests/SouthKorea/MemorialDayTest.php index d4e41a8c7..7e71fbdf2 100644 --- a/tests/SouthKorea/MemorialDayTest.php +++ b/tests/SouthKorea/MemorialDayTest.php @@ -18,7 +18,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -41,7 +40,6 @@ class MemorialDayTest extends SouthKoreaBaseTestCase implements HolidayTestCase * Tests the holiday defined in this test. * * @throws Exception - * @throws ReflectionException */ public function testHoliday(): void { @@ -57,7 +55,7 @@ public function testHoliday(): void /** * Tests the holiday defined in this test before establishment. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayBeforeEstablishment(): void { @@ -71,7 +69,7 @@ public function testHolidayBeforeEstablishment(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -86,7 +84,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/SouthKorea/NewYearsDayTest.php b/tests/SouthKorea/NewYearsDayTest.php index a16c08613..7954c4e7c 100644 --- a/tests/SouthKorea/NewYearsDayTest.php +++ b/tests/SouthKorea/NewYearsDayTest.php @@ -19,7 +19,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -42,7 +41,6 @@ class NewYearsDayTest extends SouthKoreaBaseTestCase implements HolidayTestCase * Tests the holiday defined in this test. * * @throws Exception - * @throws ReflectionException */ public function testHoliday(): void { @@ -76,7 +74,7 @@ public function testHoliday(): void /** * Tests the holiday defined in this test after removal. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayAfterRemoval(): void { @@ -95,7 +93,7 @@ public function testHolidayAfterRemoval(): void /** * Tests the holiday defined in this test before establishment. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayBeforeEstablishment(): void { @@ -109,7 +107,7 @@ public function testHolidayBeforeEstablishment(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -136,7 +134,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/SouthKorea/SeollalTest.php b/tests/SouthKorea/SeollalTest.php index 933366b77..5da618126 100644 --- a/tests/SouthKorea/SeollalTest.php +++ b/tests/SouthKorea/SeollalTest.php @@ -19,7 +19,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\Provider\SouthKorea; use Yasumi\tests\HolidayTestCase; @@ -43,7 +42,6 @@ class SeollalTest extends SouthKoreaBaseTestCase implements HolidayTestCase * Tests the holiday defined in this test. * * @throws Exception - * @throws ReflectionException */ public function testHoliday(): void { @@ -78,7 +76,6 @@ public function testHoliday(): void * Tests the substitute holiday defined in this test (conflict with Sunday). * * @throws Exception - * @throws ReflectionException */ public function testSubstituteHoliday(): void { @@ -117,7 +114,7 @@ public function testSubstituteHoliday(): void /** * Tests the holiday defined in this test before establishment. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayBeforeEstablishment(): void { @@ -131,7 +128,7 @@ public function testHolidayBeforeEstablishment(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -163,7 +160,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/SouthKorea/SouthKoreaTest.php b/tests/SouthKorea/SouthKoreaTest.php index 85acd3b1d..00775c6f3 100644 --- a/tests/SouthKorea/SouthKoreaTest.php +++ b/tests/SouthKorea/SouthKoreaTest.php @@ -28,10 +28,12 @@ class SouthKoreaTest extends SouthKoreaBaseTestCase implements ProviderTestCase /** * @var int year random year number used for all tests in this Test Case */ - protected $year; + protected int $year; /** * Initial setup of this Test Case. + * + * @throws \Exception */ protected function setUp(): void { @@ -40,8 +42,6 @@ protected function setUp(): void /** * Tests if all official holidays in South Korea are defined by the provider class. - * - * @throws ReflectionException */ public function testOfficialHolidays(): void { @@ -103,8 +103,6 @@ public function testOfficialHolidays(): void /** * Tests if all observed holidays in South Korea are defined by the provider class. - * - * @throws ReflectionException */ public function testObservedHolidays(): void { @@ -113,8 +111,6 @@ public function testObservedHolidays(): void /** * Tests if all seasonal holidays in South Korea are defined by the provider class. - * - * @throws ReflectionException */ public function testSeasonalHolidays(): void { @@ -123,8 +119,6 @@ public function testSeasonalHolidays(): void /** * Tests if all bank holidays in South Korea are defined by the provider class. - * - * @throws ReflectionException */ public function testBankHolidays(): void { @@ -133,8 +127,6 @@ public function testBankHolidays(): void /** * Tests if all other holidays in South Korea are defined by the provider class. - * - * @throws ReflectionException */ public function testOtherHolidays(): void { @@ -143,6 +135,7 @@ public function testOtherHolidays(): void /** * @throws ReflectionException + * @throws \Exception */ public function testSources(): void { diff --git a/tests/Spain/AllSaintsDayTest.php b/tests/Spain/AllSaintsDayTest.php index ff7dbe2fd..1987ae311 100644 --- a/tests/Spain/AllSaintsDayTest.php +++ b/tests/Spain/AllSaintsDayTest.php @@ -16,7 +16,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -37,8 +36,6 @@ class AllSaintsDayTest extends SpainBaseTestCase implements HolidayTestCase * * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testHoliday(int $year, DateTime $expected): void { @@ -60,7 +57,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -75,7 +72,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Spain/Andalusia/AndalusiaDayTest.php b/tests/Spain/Andalusia/AndalusiaDayTest.php index 12e17e2fc..41d42e714 100644 --- a/tests/Spain/Andalusia/AndalusiaDayTest.php +++ b/tests/Spain/Andalusia/AndalusiaDayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -40,7 +39,6 @@ class AndalusiaDayTest extends AndalusiaBaseTestCase implements HolidayTestCase * Tests the holiday defined in this test on or after establishment. * * @throws Exception - * @throws ReflectionException */ public function testHolidayOnAfterEstablishment(): void { @@ -56,7 +54,7 @@ public function testHolidayOnAfterEstablishment(): void /** * Tests the holiday defined in this test before establishment. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayBeforeEstablishment(): void { @@ -70,7 +68,7 @@ public function testHolidayBeforeEstablishment(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -85,7 +83,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Spain/Andalusia/AndalusiaTest.php b/tests/Spain/Andalusia/AndalusiaTest.php index 6a2c8313f..028ecb24d 100644 --- a/tests/Spain/Andalusia/AndalusiaTest.php +++ b/tests/Spain/Andalusia/AndalusiaTest.php @@ -30,6 +30,8 @@ class AndalusiaTest extends AndalusiaBaseTestCase implements ProviderTestCase /** * Initial setup of this Test Case. + * + * @throws \Exception */ protected function setUp(): void { @@ -38,8 +40,6 @@ protected function setUp(): void /** * Tests if all official holidays in Andalusia (Spain) are defined by the provider class. - * - * @throws ReflectionException */ public function testOfficialHolidays(): void { @@ -60,8 +60,6 @@ public function testOfficialHolidays(): void /** * Tests if all observed holidays in Andalusia are defined by the provider class. - * - * @throws ReflectionException */ public function testObservedHolidays(): void { @@ -73,8 +71,6 @@ public function testObservedHolidays(): void /** * Tests if all seasonal holidays in Andalusia are defined by the provider class. - * - * @throws ReflectionException */ public function testSeasonalHolidays(): void { @@ -83,8 +79,6 @@ public function testSeasonalHolidays(): void /** * Tests if all bank holidays in Andalusia are defined by the provider class. - * - * @throws ReflectionException */ public function testBankHolidays(): void { @@ -93,8 +87,6 @@ public function testBankHolidays(): void /** * Tests if all other holidays in Andalusia are defined by the provider class. - * - * @throws ReflectionException */ public function testOtherHolidays(): void { @@ -103,6 +95,7 @@ public function testOtherHolidays(): void /** * @throws ReflectionException + * @throws \Exception */ public function testSources(): void { diff --git a/tests/Spain/Aragon/AragonTest.php b/tests/Spain/Aragon/AragonTest.php index 8948f83fd..4e4ab5a19 100644 --- a/tests/Spain/Aragon/AragonTest.php +++ b/tests/Spain/Aragon/AragonTest.php @@ -30,6 +30,8 @@ class AragonTest extends AragonBaseTestCase implements ProviderTestCase /** * Initial setup of this Test Case. + * + * @throws \Exception */ protected function setUp(): void { @@ -38,8 +40,6 @@ protected function setUp(): void /** * Tests if all official holidays in Aragon (Spain) are defined by the provider class. - * - * @throws ReflectionException */ public function testOfficialHolidays(): void { @@ -59,8 +59,6 @@ public function testOfficialHolidays(): void /** * Tests if all observed holidays in Aragon are defined by the provider class. - * - * @throws ReflectionException */ public function testObservedHolidays(): void { @@ -73,8 +71,6 @@ public function testObservedHolidays(): void /** * Tests if all seasonal holidays in Aragon are defined by the provider class. - * - * @throws ReflectionException */ public function testSeasonalHolidays(): void { @@ -83,8 +79,6 @@ public function testSeasonalHolidays(): void /** * Tests if all bank holidays in Aragon are defined by the provider class. - * - * @throws ReflectionException */ public function testBankHolidays(): void { @@ -93,8 +87,6 @@ public function testBankHolidays(): void /** * Tests if all other holidays in Aragon are defined by the provider class. - * - * @throws ReflectionException */ public function testOtherHolidays(): void { @@ -103,6 +95,7 @@ public function testOtherHolidays(): void /** * @throws ReflectionException + * @throws \Exception */ public function testSources(): void { diff --git a/tests/Spain/Aragon/StGeorgesDayTest.php b/tests/Spain/Aragon/StGeorgesDayTest.php index 5487aa677..bbf9c7167 100644 --- a/tests/Spain/Aragon/StGeorgesDayTest.php +++ b/tests/Spain/Aragon/StGeorgesDayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -35,7 +34,6 @@ class StGeorgesDayTest extends AragonBaseTestCase implements HolidayTestCase * Tests the holiday defined in this test. * * @throws Exception - * @throws ReflectionException */ public function testHoliday(): void { @@ -51,7 +49,7 @@ public function testHoliday(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -66,7 +64,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Spain/AssumptionOfMaryTest.php b/tests/Spain/AssumptionOfMaryTest.php index 9809dca74..7aca19680 100644 --- a/tests/Spain/AssumptionOfMaryTest.php +++ b/tests/Spain/AssumptionOfMaryTest.php @@ -16,7 +16,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -37,8 +36,6 @@ class AssumptionOfMaryTest extends SpainBaseTestCase implements HolidayTestCase * * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testHoliday(int $year, DateTime $expected): void { @@ -60,7 +57,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -75,7 +72,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Spain/Asturias/AsturiasDayTest.php b/tests/Spain/Asturias/AsturiasDayTest.php index 60740befd..09415ae02 100644 --- a/tests/Spain/Asturias/AsturiasDayTest.php +++ b/tests/Spain/Asturias/AsturiasDayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -40,7 +39,6 @@ class AsturiasDayTest extends AsturiasBaseTestCase implements HolidayTestCase * Tests the holiday defined in this test on or after establishment. * * @throws Exception - * @throws ReflectionException */ public function testHolidayOnAfterEstablishment(): void { @@ -56,7 +54,7 @@ public function testHolidayOnAfterEstablishment(): void /** * Tests the holiday defined in this test before establishment. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayBeforeEstablishment(): void { @@ -70,7 +68,7 @@ public function testHolidayBeforeEstablishment(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -85,7 +83,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Spain/Asturias/AsturiasTest.php b/tests/Spain/Asturias/AsturiasTest.php index 4606589e3..2ad468457 100644 --- a/tests/Spain/Asturias/AsturiasTest.php +++ b/tests/Spain/Asturias/AsturiasTest.php @@ -30,6 +30,8 @@ class AsturiasTest extends AsturiasBaseTestCase implements ProviderTestCase /** * Initial setup of this Test Case. + * + * @throws \Exception */ protected function setUp(): void { @@ -38,8 +40,6 @@ protected function setUp(): void /** * Tests if all official holidays in Asturias (Spain) are defined by the provider class. - * - * @throws ReflectionException */ public function testOfficialHolidays(): void { @@ -60,8 +60,6 @@ public function testOfficialHolidays(): void /** * Tests if all observed holidays in Asturias are defined by the provider class. - * - * @throws ReflectionException */ public function testObservedHolidays(): void { @@ -74,8 +72,6 @@ public function testObservedHolidays(): void /** * Tests if all seasonal holidays in Asturias are defined by the provider class. - * - * @throws ReflectionException */ public function testSeasonalHolidays(): void { @@ -84,8 +80,6 @@ public function testSeasonalHolidays(): void /** * Tests if all bank holidays in Asturias are defined by the provider class. - * - * @throws ReflectionException */ public function testBankHolidays(): void { @@ -94,8 +88,6 @@ public function testBankHolidays(): void /** * Tests if all other holidays in Asturias are defined by the provider class. - * - * @throws ReflectionException */ public function testOtherHolidays(): void { @@ -104,6 +96,7 @@ public function testOtherHolidays(): void /** * @throws ReflectionException + * @throws \Exception */ public function testSources(): void { diff --git a/tests/Spain/BalearicIslands/BalearicIslandsDayTest.php b/tests/Spain/BalearicIslands/BalearicIslandsDayTest.php index 089a8c38c..586a07618 100644 --- a/tests/Spain/BalearicIslands/BalearicIslandsDayTest.php +++ b/tests/Spain/BalearicIslands/BalearicIslandsDayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -40,7 +39,6 @@ class BalearicIslandsDayTest extends BalearicIslandsBaseTestCase implements Holi * Tests the holiday defined in this test on or after establishment. * * @throws Exception - * @throws ReflectionException */ public function testHolidayOnAfterEstablishment(): void { @@ -56,7 +54,7 @@ public function testHolidayOnAfterEstablishment(): void /** * Tests the holiday defined in this test before establishment. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayBeforeEstablishment(): void { @@ -70,7 +68,7 @@ public function testHolidayBeforeEstablishment(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -85,7 +83,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Spain/BalearicIslands/BalearicIslandsTest.php b/tests/Spain/BalearicIslands/BalearicIslandsTest.php index 287740337..62447a408 100644 --- a/tests/Spain/BalearicIslands/BalearicIslandsTest.php +++ b/tests/Spain/BalearicIslands/BalearicIslandsTest.php @@ -30,6 +30,8 @@ class BalearicIslandsTest extends BalearicIslandsBaseTestCase implements Provide /** * Initial setup of this Test Case. + * + * @throws \Exception */ protected function setUp(): void { @@ -38,8 +40,6 @@ protected function setUp(): void /** * Tests if all official holidays in the Balearic Islands (Spain) are defined by the provider class. - * - * @throws ReflectionException */ public function testOfficialHolidays(): void { @@ -65,8 +65,6 @@ public function testOfficialHolidays(): void /** * Tests if all observed holidays in the Balearic Islands are defined by the provider class. - * - * @throws ReflectionException */ public function testObservedHolidays(): void { @@ -81,8 +79,6 @@ public function testObservedHolidays(): void /** * Tests if all seasonal holidays in the Balearic Islands are defined by the provider class. - * - * @throws ReflectionException */ public function testSeasonalHolidays(): void { @@ -91,8 +87,6 @@ public function testSeasonalHolidays(): void /** * Tests if all bank holidays in the Balearic Islands are defined by the provider class. - * - * @throws ReflectionException */ public function testBankHolidays(): void { @@ -101,8 +95,6 @@ public function testBankHolidays(): void /** * Tests if all other holidays in the Balearic Islands are defined by the provider class. - * - * @throws ReflectionException */ public function testOtherHolidays(): void { @@ -111,6 +103,7 @@ public function testOtherHolidays(): void /** * @throws ReflectionException + * @throws \Exception */ public function testSources(): void { diff --git a/tests/Spain/BasqueCountry/BasqueCountryDayTest.php b/tests/Spain/BasqueCountry/BasqueCountryDayTest.php index d01fac12b..783c2acf0 100644 --- a/tests/Spain/BasqueCountry/BasqueCountryDayTest.php +++ b/tests/Spain/BasqueCountry/BasqueCountryDayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -45,7 +44,6 @@ class BasqueCountryDayTest extends BasqueCountryBaseTestCase implements HolidayT * Tests the holiday defined in this test on or after establishment. * * @throws Exception - * @throws ReflectionException */ public function testHolidayOnAfterEstablishment(): void { @@ -61,7 +59,7 @@ public function testHolidayOnAfterEstablishment(): void /** * Tests the holiday defined in this test before establishment. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayBeforeEstablishment(): void { @@ -75,7 +73,7 @@ public function testHolidayBeforeEstablishment(): void /** * Tests the holiday defined in this test after abolishment. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayDayAfterAbolishment(): void { @@ -85,7 +83,7 @@ public function testHolidayDayAfterAbolishment(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -100,7 +98,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Spain/BasqueCountry/BasqueCountryTest.php b/tests/Spain/BasqueCountry/BasqueCountryTest.php index 190999d8f..f447b6d23 100644 --- a/tests/Spain/BasqueCountry/BasqueCountryTest.php +++ b/tests/Spain/BasqueCountry/BasqueCountryTest.php @@ -30,6 +30,8 @@ class BasqueCountryTest extends BasqueCountryBaseTestCase implements ProviderTes /** * Initial setup of this Test Case. + * + * @throws \Exception */ protected function setUp(): void { @@ -38,8 +40,6 @@ protected function setUp(): void /** * Tests if all official holidays in Basque Country (Spain) are defined by the provider class. - * - * @throws ReflectionException */ public function testOfficialHolidays(): void { @@ -60,8 +60,6 @@ public function testOfficialHolidays(): void /** * Tests if all observed holidays in Basque Country are defined by the provider class. - * - * @throws ReflectionException */ public function testObservedHolidays(): void { @@ -74,8 +72,6 @@ public function testObservedHolidays(): void /** * Tests if all seasonal holidays in Basque Country are defined by the provider class. - * - * @throws ReflectionException */ public function testSeasonalHolidays(): void { @@ -84,8 +80,6 @@ public function testSeasonalHolidays(): void /** * Tests if all bank holidays in Basque Country are defined by the provider class. - * - * @throws ReflectionException */ public function testBankHolidays(): void { @@ -94,8 +88,6 @@ public function testBankHolidays(): void /** * Tests if all other holidays in Basque Country are defined by the provider class. - * - * @throws ReflectionException */ public function testOtherHolidays(): void { @@ -104,6 +96,7 @@ public function testOtherHolidays(): void /** * @throws ReflectionException + * @throws \Exception */ public function testSources(): void { diff --git a/tests/Spain/CanaryIslands/CanaryIslandsDayTest.php b/tests/Spain/CanaryIslands/CanaryIslandsDayTest.php index 25b690ed5..a1e7f035f 100644 --- a/tests/Spain/CanaryIslands/CanaryIslandsDayTest.php +++ b/tests/Spain/CanaryIslands/CanaryIslandsDayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -40,7 +39,6 @@ class CanaryIslandsDayTest extends CanaryIslandsBaseTestCase implements HolidayT * Tests the holiday defined in this test on or after establishment. * * @throws Exception - * @throws ReflectionException */ public function testHolidayOnAfterEstablishment(): void { @@ -56,7 +54,7 @@ public function testHolidayOnAfterEstablishment(): void /** * Tests the holiday defined in this test before establishment. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayBeforeEstablishment(): void { @@ -70,7 +68,7 @@ public function testHolidayBeforeEstablishment(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -85,7 +83,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Spain/CanaryIslands/CanaryIslandsTest.php b/tests/Spain/CanaryIslands/CanaryIslandsTest.php index 330a2abd9..97b996cb1 100644 --- a/tests/Spain/CanaryIslands/CanaryIslandsTest.php +++ b/tests/Spain/CanaryIslands/CanaryIslandsTest.php @@ -30,6 +30,8 @@ class CanaryIslandsTest extends CanaryIslandsBaseTestCase implements ProviderTes /** * Initial setup of this Test Case. + * + * @throws \Exception */ protected function setUp(): void { @@ -38,8 +40,6 @@ protected function setUp(): void /** * Tests if all official holidays in the Canary Islands (Spain) are defined by the provider class. - * - * @throws ReflectionException */ public function testOfficialHolidays(): void { @@ -60,8 +60,6 @@ public function testOfficialHolidays(): void /** * Tests if all observed holidays in the Canary Islands are defined by the provider class. - * - * @throws ReflectionException */ public function testObservedHolidays(): void { @@ -73,8 +71,6 @@ public function testObservedHolidays(): void /** * Tests if all seasonal holidays in the Canary Islands are defined by the provider class. - * - * @throws ReflectionException */ public function testSeasonalHolidays(): void { @@ -83,8 +79,6 @@ public function testSeasonalHolidays(): void /** * Tests if all bank holidays in the Canary Islands are defined by the provider class. - * - * @throws ReflectionException */ public function testBankHolidays(): void { @@ -93,8 +87,6 @@ public function testBankHolidays(): void /** * Tests if all other holidays in the Canary Islands are defined by the provider class. - * - * @throws ReflectionException */ public function testOtherHolidays(): void { @@ -103,6 +95,7 @@ public function testOtherHolidays(): void /** * @throws ReflectionException + * @throws \Exception */ public function testSources(): void { diff --git a/tests/Spain/Cantabria/CantabriaDayTest.php b/tests/Spain/Cantabria/CantabriaDayTest.php index 7d42068a7..a8ca80019 100644 --- a/tests/Spain/Cantabria/CantabriaDayTest.php +++ b/tests/Spain/Cantabria/CantabriaDayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -40,7 +39,6 @@ class CantabriaDayTest extends CantabriaBaseTestCase implements HolidayTestCase * Tests the holiday defined in this test on or after establishment. * * @throws Exception - * @throws ReflectionException */ public function testHolidayOnAfterEstablishment(): void { @@ -56,7 +54,7 @@ public function testHolidayOnAfterEstablishment(): void /** * Tests the holiday defined in this test before establishment. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayBeforeEstablishment(): void { @@ -70,7 +68,7 @@ public function testHolidayBeforeEstablishment(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -85,7 +83,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Spain/Cantabria/CantabriaTest.php b/tests/Spain/Cantabria/CantabriaTest.php index 3a4068286..276bfb00a 100644 --- a/tests/Spain/Cantabria/CantabriaTest.php +++ b/tests/Spain/Cantabria/CantabriaTest.php @@ -30,6 +30,8 @@ class CantabriaTest extends CantabriaBaseTestCase implements ProviderTestCase /** * Initial setup of this Test Case. + * + * @throws \Exception */ protected function setUp(): void { @@ -38,8 +40,6 @@ protected function setUp(): void /** * Tests if all official holidays in Cantabria (Spain) are defined by the provider class. - * - * @throws ReflectionException */ public function testOfficialHolidays(): void { @@ -60,8 +60,6 @@ public function testOfficialHolidays(): void /** * Tests if all observed holidays in Cantabria are defined by the provider class. - * - * @throws ReflectionException */ public function testObservedHolidays(): void { @@ -73,8 +71,6 @@ public function testObservedHolidays(): void /** * Tests if all seasonal holidays in Cantabria are defined by the provider class. - * - * @throws ReflectionException */ public function testSeasonalHolidays(): void { @@ -83,8 +79,6 @@ public function testSeasonalHolidays(): void /** * Tests if all bank holidays in Cantabria are defined by the provider class. - * - * @throws ReflectionException */ public function testBankHolidays(): void { @@ -93,8 +87,6 @@ public function testBankHolidays(): void /** * Tests if all other holidays in Cantabria are defined by the provider class. - * - * @throws ReflectionException */ public function testOtherHolidays(): void { @@ -103,6 +95,7 @@ public function testOtherHolidays(): void /** * @throws ReflectionException + * @throws \Exception */ public function testSources(): void { diff --git a/tests/Spain/CastileAndLeon/CastileAndLeonDayTest.php b/tests/Spain/CastileAndLeon/CastileAndLeonDayTest.php index 1896c1fbb..b408bf96b 100644 --- a/tests/Spain/CastileAndLeon/CastileAndLeonDayTest.php +++ b/tests/Spain/CastileAndLeon/CastileAndLeonDayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -40,7 +39,6 @@ class CastileAndLeonDayTest extends CastileAndLeonBaseTestCase implements Holida * Tests the holiday defined in this test on or after establishment. * * @throws Exception - * @throws ReflectionException */ public function testHolidayOnAfterEstablishment(): void { @@ -56,7 +54,7 @@ public function testHolidayOnAfterEstablishment(): void /** * Tests the holiday defined in this test before establishment. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayBeforeEstablishment(): void { @@ -70,7 +68,7 @@ public function testHolidayBeforeEstablishment(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -85,7 +83,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Spain/CastileAndLeon/CastileAndLeonTest.php b/tests/Spain/CastileAndLeon/CastileAndLeonTest.php index 674b1ac96..2a23d3a8c 100644 --- a/tests/Spain/CastileAndLeon/CastileAndLeonTest.php +++ b/tests/Spain/CastileAndLeon/CastileAndLeonTest.php @@ -30,6 +30,8 @@ class CastileAndLeonTest extends CastileAndLeonBaseTestCase implements ProviderT /** * Initial setup of this Test Case. + * + * @throws \Exception */ protected function setUp(): void { @@ -38,8 +40,6 @@ protected function setUp(): void /** * Tests if all official holidays in Castile And Leon (Spain) are defined by the provider class. - * - * @throws ReflectionException */ public function testOfficialHolidays(): void { @@ -60,8 +60,6 @@ public function testOfficialHolidays(): void /** * Tests if all observed holidays in Castile And Leon are defined by the provider class. - * - * @throws ReflectionException */ public function testObservedHolidays(): void { @@ -73,8 +71,6 @@ public function testObservedHolidays(): void /** * Tests if all seasonal holidays in Castile And Leon are defined by the provider class. - * - * @throws ReflectionException */ public function testSeasonalHolidays(): void { @@ -83,8 +79,6 @@ public function testSeasonalHolidays(): void /** * Tests if all bank holidays in Castile And Leon are defined by the provider class. - * - * @throws ReflectionException */ public function testBankHolidays(): void { @@ -93,8 +87,6 @@ public function testBankHolidays(): void /** * Tests if all other holidays in Castile And Leon are defined by the provider class. - * - * @throws ReflectionException */ public function testOtherHolidays(): void { @@ -103,6 +95,7 @@ public function testOtherHolidays(): void /** * @throws ReflectionException + * @throws \Exception */ public function testSources(): void { diff --git a/tests/Spain/CastillaLaMancha/CastillaLaManchaDayTest.php b/tests/Spain/CastillaLaMancha/CastillaLaManchaDayTest.php index c6a562083..966de18e0 100644 --- a/tests/Spain/CastillaLaMancha/CastillaLaManchaDayTest.php +++ b/tests/Spain/CastillaLaMancha/CastillaLaManchaDayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -40,7 +39,6 @@ class CastillaLaManchaDayTest extends CastillaLaManchaBaseTestCase implements Ho * Tests the holiday defined in this test on or after establishment. * * @throws Exception - * @throws ReflectionException */ public function testHolidayOnAfterEstablishment(): void { @@ -56,7 +54,7 @@ public function testHolidayOnAfterEstablishment(): void /** * Tests the holiday defined in this test before establishment. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayBeforeEstablishment(): void { @@ -70,7 +68,7 @@ public function testHolidayBeforeEstablishment(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -85,7 +83,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Spain/CastillaLaMancha/CastillaLaManchaTest.php b/tests/Spain/CastillaLaMancha/CastillaLaManchaTest.php index 252494046..6849f981f 100644 --- a/tests/Spain/CastillaLaMancha/CastillaLaManchaTest.php +++ b/tests/Spain/CastillaLaMancha/CastillaLaManchaTest.php @@ -30,6 +30,8 @@ class CastillaLaManchaTest extends CastillaLaManchaBaseTestCase implements Provi /** * Initial setup of this Test Case. + * + * @throws \Exception */ protected function setUp(): void { @@ -38,8 +40,6 @@ protected function setUp(): void /** * Tests if all official holidays in Castilla-La Mancha (Spain) are defined by the provider class. - * - * @throws ReflectionException */ public function testOfficialHolidays(): void { @@ -60,8 +60,6 @@ public function testOfficialHolidays(): void /** * Tests if all observed holidays in Castilla-La Mancha are defined by the provider class. - * - * @throws ReflectionException */ public function testObservedHolidays(): void { @@ -74,8 +72,6 @@ public function testObservedHolidays(): void /** * Tests if all seasonal holidays in Castilla-La Mancha are defined by the provider class. - * - * @throws ReflectionException */ public function testSeasonalHolidays(): void { @@ -84,8 +80,6 @@ public function testSeasonalHolidays(): void /** * Tests if all bank holidays in Castilla-La Mancha are defined by the provider class. - * - * @throws ReflectionException */ public function testBankHolidays(): void { @@ -94,8 +88,6 @@ public function testBankHolidays(): void /** * Tests if all other holidays in Castilla-La Mancha are defined by the provider class. - * - * @throws ReflectionException */ public function testOtherHolidays(): void { @@ -104,6 +96,7 @@ public function testOtherHolidays(): void /** * @throws ReflectionException + * @throws \Exception */ public function testSources(): void { diff --git a/tests/Spain/Catalonia/CataloniaTest.php b/tests/Spain/Catalonia/CataloniaTest.php index 0f3f0c49f..4a4a9381c 100644 --- a/tests/Spain/Catalonia/CataloniaTest.php +++ b/tests/Spain/Catalonia/CataloniaTest.php @@ -30,6 +30,8 @@ class CataloniaTest extends CataloniaBaseTestCase implements ProviderTestCase /** * Initial setup of this Test Case. + * + * @throws \Exception */ protected function setUp(): void { @@ -38,8 +40,6 @@ protected function setUp(): void /** * Tests if all official holidays in Catalonia (Spain) are defined by the provider class. - * - * @throws ReflectionException */ public function testOfficialHolidays(): void { @@ -60,8 +60,6 @@ public function testOfficialHolidays(): void /** * Tests if all observed holidays in Catalonia are defined by the provider class. - * - * @throws ReflectionException */ public function testObservedHolidays(): void { @@ -75,8 +73,6 @@ public function testObservedHolidays(): void /** * Tests if all seasonal holidays in Catalonia are defined by the provider class. - * - * @throws ReflectionException */ public function testSeasonalHolidays(): void { @@ -85,8 +81,6 @@ public function testSeasonalHolidays(): void /** * Tests if all bank holidays in Catalonia are defined by the provider class. - * - * @throws ReflectionException */ public function testBankHolidays(): void { @@ -95,8 +89,6 @@ public function testBankHolidays(): void /** * Tests if all other holidays in Catalonia are defined by the provider class. - * - * @throws ReflectionException */ public function testOtherHolidays(): void { @@ -105,6 +97,7 @@ public function testOtherHolidays(): void /** * @throws ReflectionException + * @throws \Exception */ public function testSources(): void { diff --git a/tests/Spain/Catalonia/nationalCataloniaDayTest.php b/tests/Spain/Catalonia/nationalCataloniaDayTest.php index 8f11b7807..6f1a8ad55 100644 --- a/tests/Spain/Catalonia/nationalCataloniaDayTest.php +++ b/tests/Spain/Catalonia/nationalCataloniaDayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -40,7 +39,6 @@ class nationalCataloniaDayTest extends CataloniaBaseTestCase implements HolidayT * Tests the holiday defined in this test on or after establishment. * * @throws Exception - * @throws ReflectionException */ public function testHolidayOnAfterEstablishment(): void { @@ -56,7 +54,7 @@ public function testHolidayOnAfterEstablishment(): void /** * Tests the holiday defined in this test before establishment. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayBeforeEstablishment(): void { @@ -70,7 +68,7 @@ public function testHolidayBeforeEstablishment(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -88,7 +86,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Spain/Catalonia/stJohnsDayTest.php b/tests/Spain/Catalonia/stJohnsDayTest.php index 6c807c7f5..2a37fc6b5 100644 --- a/tests/Spain/Catalonia/stJohnsDayTest.php +++ b/tests/Spain/Catalonia/stJohnsDayTest.php @@ -16,7 +16,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -37,8 +36,6 @@ class stJohnsDayTest extends CataloniaBaseTestCase implements HolidayTestCase * * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testHoliday(int $year, DateTime $expected): void { @@ -60,7 +57,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -75,7 +72,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Spain/Ceuta/CeutaTest.php b/tests/Spain/Ceuta/CeutaTest.php index babeb778b..db8fc7f67 100644 --- a/tests/Spain/Ceuta/CeutaTest.php +++ b/tests/Spain/Ceuta/CeutaTest.php @@ -30,6 +30,8 @@ class CeutaTest extends CeutaBaseTestCase implements ProviderTestCase /** * Initial setup of this Test Case. + * + * @throws \Exception */ protected function setUp(): void { @@ -38,8 +40,6 @@ protected function setUp(): void /** * Tests if all official holidays in Ceuta (Spain) are defined by the provider class. - * - * @throws ReflectionException */ public function testOfficialHolidays(): void { @@ -60,8 +60,6 @@ public function testOfficialHolidays(): void /** * Tests if all observed holidays in Ceuta are defined by the provider class. - * - * @throws ReflectionException */ public function testObservedHolidays(): void { @@ -73,8 +71,6 @@ public function testObservedHolidays(): void /** * Tests if all seasonal holidays in Ceuta are defined by the provider class. - * - * @throws ReflectionException */ public function testSeasonalHolidays(): void { @@ -83,8 +79,6 @@ public function testSeasonalHolidays(): void /** * Tests if all bank holidays in Ceuta are defined by the provider class. - * - * @throws ReflectionException */ public function testBankHolidays(): void { @@ -93,8 +87,6 @@ public function testBankHolidays(): void /** * Tests if all other holidays in Ceuta are defined by the provider class. - * - * @throws ReflectionException */ public function testOtherHolidays(): void { @@ -103,6 +95,7 @@ public function testOtherHolidays(): void /** * @throws ReflectionException + * @throws \Exception */ public function testSources(): void { diff --git a/tests/Spain/Ceuta/ceutaDayTest.php b/tests/Spain/Ceuta/ceutaDayTest.php index aca7596e9..f02c89d76 100644 --- a/tests/Spain/Ceuta/ceutaDayTest.php +++ b/tests/Spain/Ceuta/ceutaDayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -40,7 +39,6 @@ class ceutaDayTest extends CeutaBaseTestCase implements HolidayTestCase * Tests the holiday defined in this test on or after establishment. * * @throws Exception - * @throws ReflectionException */ public function testHolidayOnAfterEstablishment(): void { @@ -56,7 +54,7 @@ public function testHolidayOnAfterEstablishment(): void /** * Tests the holiday defined in this test before establishment. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayBeforeEstablishment(): void { @@ -70,7 +68,7 @@ public function testHolidayBeforeEstablishment(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -85,7 +83,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Spain/ChristmasTest.php b/tests/Spain/ChristmasTest.php index 47df8e030..66a835b97 100644 --- a/tests/Spain/ChristmasTest.php +++ b/tests/Spain/ChristmasTest.php @@ -16,7 +16,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -37,8 +36,6 @@ class ChristmasTest extends SpainBaseTestCase implements HolidayTestCase * * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testHoliday(int $year, DateTime $expected): void { @@ -60,7 +57,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -75,7 +72,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Spain/CommunityOfMadrid/CommunityOfMadridTest.php b/tests/Spain/CommunityOfMadrid/CommunityOfMadridTest.php index 49f5f17f9..f246a0fff 100644 --- a/tests/Spain/CommunityOfMadrid/CommunityOfMadridTest.php +++ b/tests/Spain/CommunityOfMadrid/CommunityOfMadridTest.php @@ -30,6 +30,8 @@ class CommunityOfMadridTest extends CommunityOfMadridBaseTestCase implements Pro /** * Initial setup of this Test Case. + * + * @throws \Exception */ protected function setUp(): void { @@ -38,8 +40,6 @@ protected function setUp(): void /** * Tests if all official holidays in the Community of Madrid (Spain) are defined by the provider class. - * - * @throws ReflectionException */ public function testOfficialHolidays(): void { @@ -60,8 +60,6 @@ public function testOfficialHolidays(): void /** * Tests if all observed holidays in the Community of Madrid are defined by the provider class. - * - * @throws ReflectionException */ public function testObservedHolidays(): void { @@ -75,8 +73,6 @@ public function testObservedHolidays(): void /** * Tests if all seasonal holidays in the Community of Madrid are defined by the provider class. - * - * @throws ReflectionException */ public function testSeasonalHolidays(): void { @@ -85,8 +81,6 @@ public function testSeasonalHolidays(): void /** * Tests if all bank holidays in the Community of Madrid are defined by the provider class. - * - * @throws ReflectionException */ public function testBankHolidays(): void { @@ -95,8 +89,6 @@ public function testBankHolidays(): void /** * Tests if all other holidays in the Community of Madrid are defined by the provider class. - * - * @throws ReflectionException */ public function testOtherHolidays(): void { @@ -105,6 +97,7 @@ public function testOtherHolidays(): void /** * @throws ReflectionException + * @throws \Exception */ public function testSources(): void { diff --git a/tests/Spain/CommunityOfMadrid/DosdeMayoUprisingDayTest.php b/tests/Spain/CommunityOfMadrid/DosdeMayoUprisingDayTest.php index 278ecea4d..1fbb84d8f 100644 --- a/tests/Spain/CommunityOfMadrid/DosdeMayoUprisingDayTest.php +++ b/tests/Spain/CommunityOfMadrid/DosdeMayoUprisingDayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -35,7 +34,6 @@ class DosdeMayoUprisingDayTest extends CommunityOfMadridBaseTestCase implements * Tests the holiday defined in this test. * * @throws Exception - * @throws ReflectionException */ public function testHoliday(): void { @@ -51,7 +49,7 @@ public function testHoliday(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -66,7 +64,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Spain/ConstitutionDayTest.php b/tests/Spain/ConstitutionDayTest.php index 2ce558f0a..224a8073a 100644 --- a/tests/Spain/ConstitutionDayTest.php +++ b/tests/Spain/ConstitutionDayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -40,7 +39,6 @@ class ConstitutionDayTest extends SpainBaseTestCase implements HolidayTestCase * Tests the holiday defined in this test on or after establishment. * * @throws Exception - * @throws ReflectionException */ public function testHolidayOnAfterEstablishment(): void { @@ -56,7 +54,7 @@ public function testHolidayOnAfterEstablishment(): void /** * Tests the holiday defined in this test before establishment. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayBeforeEstablishment(): void { @@ -70,7 +68,7 @@ public function testHolidayBeforeEstablishment(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -85,7 +83,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Spain/EasterMondayTest.php b/tests/Spain/EasterMondayTest.php index 4a7f65bcc..bd6e8dc07 100644 --- a/tests/Spain/EasterMondayTest.php +++ b/tests/Spain/EasterMondayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -41,7 +40,6 @@ class EasterMondayTest extends SpainBaseTestCase implements HolidayTestCase * Tests the holiday defined in this test. * * @throws Exception - * @throws ReflectionException */ public function testHoliday(): void { @@ -57,7 +55,7 @@ public function testHoliday(): void /** * Tests translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -72,7 +70,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Spain/EpiphanyTest.php b/tests/Spain/EpiphanyTest.php index 89c1b1874..35daabb4e 100644 --- a/tests/Spain/EpiphanyTest.php +++ b/tests/Spain/EpiphanyTest.php @@ -16,7 +16,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -37,8 +36,6 @@ class EpiphanyTest extends SpainBaseTestCase implements HolidayTestCase * * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testHoliday(int $year, DateTime $expected): void { @@ -60,7 +57,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -75,7 +72,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Spain/Extremadura/ExtremaduraDayTest.php b/tests/Spain/Extremadura/ExtremaduraDayTest.php index 3a44bee42..3bd8f3525 100644 --- a/tests/Spain/Extremadura/ExtremaduraDayTest.php +++ b/tests/Spain/Extremadura/ExtremaduraDayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -40,7 +39,6 @@ class ExtremaduraDayTest extends ExtremaduraBaseTestCase implements HolidayTestC * Tests the holiday defined in this test on or after establishment. * * @throws Exception - * @throws ReflectionException */ public function testHolidayOnAfterEstablishment(): void { @@ -56,7 +54,7 @@ public function testHolidayOnAfterEstablishment(): void /** * Tests the holiday defined in this test before establishment. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayBeforeEstablishment(): void { @@ -70,7 +68,7 @@ public function testHolidayBeforeEstablishment(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -85,7 +83,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Spain/Extremadura/ExtremaduraTest.php b/tests/Spain/Extremadura/ExtremaduraTest.php index 888b9f27f..494e93749 100644 --- a/tests/Spain/Extremadura/ExtremaduraTest.php +++ b/tests/Spain/Extremadura/ExtremaduraTest.php @@ -30,6 +30,8 @@ class ExtremaduraTest extends ExtremaduraBaseTestCase implements ProviderTestCas /** * Initial setup of this Test Case. + * + * @throws \Exception */ protected function setUp(): void { @@ -38,8 +40,6 @@ protected function setUp(): void /** * Tests if all official holidays in Extremadura (Spain) are defined by the provider class. - * - * @throws ReflectionException */ public function testOfficialHolidays(): void { @@ -60,8 +60,6 @@ public function testOfficialHolidays(): void /** * Tests if all observed holidays in Extremadura are defined by the provider class. - * - * @throws ReflectionException */ public function testObservedHolidays(): void { @@ -73,8 +71,6 @@ public function testObservedHolidays(): void /** * Tests if all seasonal holidays in Extremadura are defined by the provider class. - * - * @throws ReflectionException */ public function testSeasonalHolidays(): void { @@ -83,8 +79,6 @@ public function testSeasonalHolidays(): void /** * Tests if all bank holidays in Extremadura are defined by the provider class. - * - * @throws ReflectionException */ public function testBankHolidays(): void { @@ -93,8 +87,6 @@ public function testBankHolidays(): void /** * Tests if all other holidays in Extremadura are defined by the provider class. - * - * @throws ReflectionException */ public function testOtherHolidays(): void { @@ -103,6 +95,7 @@ public function testOtherHolidays(): void /** * @throws ReflectionException + * @throws \Exception */ public function testSources(): void { diff --git a/tests/Spain/Galicia/GaliciaTest.php b/tests/Spain/Galicia/GaliciaTest.php index 4bdc29dca..45113848e 100644 --- a/tests/Spain/Galicia/GaliciaTest.php +++ b/tests/Spain/Galicia/GaliciaTest.php @@ -30,6 +30,8 @@ class GaliciaTest extends GaliciaBaseTestCase implements ProviderTestCase /** * Initial setup of this Test Case. + * + * @throws \Exception */ protected function setUp(): void { @@ -38,8 +40,6 @@ protected function setUp(): void /** * Tests if all official holidays in Galicia (Spain) are defined by the provider class. - * - * @throws ReflectionException */ public function testOfficialHolidays(): void { @@ -61,8 +61,6 @@ public function testOfficialHolidays(): void /** * Tests if all observed holidays in Galicia are defined by the provider class. - * - * @throws ReflectionException */ public function testObservedHolidays(): void { @@ -75,8 +73,6 @@ public function testObservedHolidays(): void /** * Tests if all seasonal holidays in Galicia are defined by the provider class. - * - * @throws ReflectionException */ public function testSeasonalHolidays(): void { @@ -85,8 +81,6 @@ public function testSeasonalHolidays(): void /** * Tests if all bank holidays in Galicia are defined by the provider class. - * - * @throws ReflectionException */ public function testBankHolidays(): void { @@ -95,8 +89,6 @@ public function testBankHolidays(): void /** * Tests if all other holidays in Galicia are defined by the provider class. - * - * @throws ReflectionException */ public function testOtherHolidays(): void { @@ -105,6 +97,7 @@ public function testOtherHolidays(): void /** * @throws ReflectionException + * @throws \Exception */ public function testSources(): void { diff --git a/tests/Spain/Galicia/GalicianLiteratureDayTest.php b/tests/Spain/Galicia/GalicianLiteratureDayTest.php index 1ccac9795..f35fe8364 100644 --- a/tests/Spain/Galicia/GalicianLiteratureDayTest.php +++ b/tests/Spain/Galicia/GalicianLiteratureDayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -40,7 +39,6 @@ class GalicianLiteratureDayTest extends GaliciaBaseTestCase implements HolidayTe * Tests the holiday defined in this test on or after establishment. * * @throws Exception - * @throws ReflectionException */ public function testHolidayOnAfterEstablishment(): void { @@ -56,7 +54,7 @@ public function testHolidayOnAfterEstablishment(): void /** * Tests the holiday defined in this test before establishment. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayBeforeEstablishment(): void { @@ -70,7 +68,7 @@ public function testHolidayBeforeEstablishment(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -85,7 +83,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Spain/Galicia/stJamesDayTest.php b/tests/Spain/Galicia/stJamesDayTest.php index 548096095..3b753e87d 100644 --- a/tests/Spain/Galicia/stJamesDayTest.php +++ b/tests/Spain/Galicia/stJamesDayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -40,7 +39,6 @@ class stJamesDayTest extends GaliciaBaseTestCase implements HolidayTestCase * Tests the holiday defined in this test on or after establishment. * * @throws Exception - * @throws ReflectionException */ public function testHolidayOnAfterEstablishment(): void { @@ -56,7 +54,7 @@ public function testHolidayOnAfterEstablishment(): void /** * Tests the holiday defined in this test before establishment. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayBeforeEstablishment(): void { @@ -70,7 +68,7 @@ public function testHolidayBeforeEstablishment(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -85,7 +83,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Spain/GoodFridayTest.php b/tests/Spain/GoodFridayTest.php index 574af79f2..061b6adb0 100644 --- a/tests/Spain/GoodFridayTest.php +++ b/tests/Spain/GoodFridayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -35,7 +34,6 @@ class GoodFridayTest extends SpainBaseTestCase implements HolidayTestCase * Tests the holiday defined in this test. * * @throws Exception - * @throws ReflectionException */ public function testHoliday(): void { @@ -51,7 +49,7 @@ public function testHoliday(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -66,7 +64,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Spain/ImmaculateConceptionTest.php b/tests/Spain/ImmaculateConceptionTest.php index 89baa7c87..566157422 100644 --- a/tests/Spain/ImmaculateConceptionTest.php +++ b/tests/Spain/ImmaculateConceptionTest.php @@ -16,7 +16,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -37,8 +36,6 @@ class ImmaculateConceptionTest extends SpainBaseTestCase implements HolidayTestC * * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testHoliday(int $year, DateTime $expected): void { @@ -60,7 +57,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -75,7 +72,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Spain/InternationalWorkersDayTest.php b/tests/Spain/InternationalWorkersDayTest.php index 76697626a..579992e57 100644 --- a/tests/Spain/InternationalWorkersDayTest.php +++ b/tests/Spain/InternationalWorkersDayTest.php @@ -16,7 +16,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -37,8 +36,6 @@ class InternationalWorkersDayTest extends SpainBaseTestCase implements HolidayTe * * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testHoliday(int $year, DateTime $expected): void { @@ -60,7 +57,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -75,7 +72,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Spain/LaRioja/LaRiojaDayTest.php b/tests/Spain/LaRioja/LaRiojaDayTest.php index 12fb2e81e..aec5ff065 100644 --- a/tests/Spain/LaRioja/LaRiojaDayTest.php +++ b/tests/Spain/LaRioja/LaRiojaDayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -40,7 +39,6 @@ class LaRiojaDayTest extends LaRiojaBaseTestCase implements HolidayTestCase * Tests the holiday defined in this test on or after establishment. * * @throws Exception - * @throws ReflectionException */ public function testHolidayOnAfterEstablishment(): void { @@ -56,7 +54,7 @@ public function testHolidayOnAfterEstablishment(): void /** * Tests the holiday defined in this test before establishment. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayBeforeEstablishment(): void { @@ -70,7 +68,7 @@ public function testHolidayBeforeEstablishment(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -85,7 +83,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Spain/LaRioja/LaRiojaTest.php b/tests/Spain/LaRioja/LaRiojaTest.php index 34b39bf60..a58849595 100644 --- a/tests/Spain/LaRioja/LaRiojaTest.php +++ b/tests/Spain/LaRioja/LaRiojaTest.php @@ -30,6 +30,8 @@ class LaRiojaTest extends LaRiojaBaseTestCase implements ProviderTestCase /** * Initial setup of this Test Case. + * + * @throws \Exception */ protected function setUp(): void { @@ -38,8 +40,6 @@ protected function setUp(): void /** * Tests if all official holidays in La Rioja (Spain) are defined by the provider class. - * - * @throws ReflectionException */ public function testOfficialHolidays(): void { @@ -60,8 +60,6 @@ public function testOfficialHolidays(): void /** * Tests if all observed holidays in La Rioja are defined by the provider class. - * - * @throws ReflectionException */ public function testObservedHolidays(): void { @@ -73,8 +71,6 @@ public function testObservedHolidays(): void /** * Tests if all seasonal holidays in La Rioja are defined by the provider class. - * - * @throws ReflectionException */ public function testSeasonalHolidays(): void { @@ -83,8 +79,6 @@ public function testSeasonalHolidays(): void /** * Tests if all bank holidays in La Rioja are defined by the provider class. - * - * @throws ReflectionException */ public function testBankHolidays(): void { @@ -93,8 +87,6 @@ public function testBankHolidays(): void /** * Tests if all other holidays in La Rioja are defined by the provider class. - * - * @throws ReflectionException */ public function testOtherHolidays(): void { @@ -103,6 +95,7 @@ public function testOtherHolidays(): void /** * @throws ReflectionException + * @throws \Exception */ public function testSources(): void { diff --git a/tests/Spain/MaundyThursdayTest.php b/tests/Spain/MaundyThursdayTest.php index ae1697191..50c17e007 100644 --- a/tests/Spain/MaundyThursdayTest.php +++ b/tests/Spain/MaundyThursdayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -41,7 +40,6 @@ class MaundyThursdayTest extends SpainBaseTestCase implements HolidayTestCase * Tests the holiday defined in this test. * * @throws Exception - * @throws ReflectionException */ public function testHoliday(): void { @@ -57,7 +55,7 @@ public function testHoliday(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -72,7 +70,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Spain/Melilla/MelillaTest.php b/tests/Spain/Melilla/MelillaTest.php index 150e3e05c..ff0b17475 100644 --- a/tests/Spain/Melilla/MelillaTest.php +++ b/tests/Spain/Melilla/MelillaTest.php @@ -30,6 +30,8 @@ class MelillaTest extends MelillaBaseTestCase implements ProviderTestCase /** * Initial setup of this Test Case. + * + * @throws \Exception */ protected function setUp(): void { @@ -38,8 +40,6 @@ protected function setUp(): void /** * Tests if all official holidays in Melilla (Spain) are defined by the provider class. - * - * @throws ReflectionException */ public function testOfficialHolidays(): void { @@ -59,8 +59,6 @@ public function testOfficialHolidays(): void /** * Tests if all observed holidays in Melilla are defined by the provider class. - * - * @throws ReflectionException */ public function testObservedHolidays(): void { @@ -73,8 +71,6 @@ public function testObservedHolidays(): void /** * Tests if all seasonal holidays in Melilla are defined by the provider class. - * - * @throws ReflectionException */ public function testSeasonalHolidays(): void { @@ -83,8 +79,6 @@ public function testSeasonalHolidays(): void /** * Tests if all bank holidays in Melilla are defined by the provider class. - * - * @throws ReflectionException */ public function testBankHolidays(): void { @@ -93,8 +87,6 @@ public function testBankHolidays(): void /** * Tests if all other holidays in Melilla are defined by the provider class. - * - * @throws ReflectionException */ public function testOtherHolidays(): void { @@ -103,6 +95,7 @@ public function testOtherHolidays(): void /** * @throws ReflectionException + * @throws \Exception */ public function testSources(): void { diff --git a/tests/Spain/NationalDayTest.php b/tests/Spain/NationalDayTest.php index 2863ea09f..a466e23a5 100644 --- a/tests/Spain/NationalDayTest.php +++ b/tests/Spain/NationalDayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -40,7 +39,6 @@ class NationalDayTest extends SpainBaseTestCase implements HolidayTestCase * Tests the holiday defined in this test on or after establishment. * * @throws Exception - * @throws ReflectionException */ public function testHolidayOnAfterEstablishment(): void { @@ -56,7 +54,7 @@ public function testHolidayOnAfterEstablishment(): void /** * Tests the holiday defined in this test before establishment. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayBeforeEstablishment(): void { @@ -70,7 +68,7 @@ public function testHolidayBeforeEstablishment(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -85,7 +83,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Spain/Navarre/NavarreTest.php b/tests/Spain/Navarre/NavarreTest.php index 81225c9f3..980e7634b 100644 --- a/tests/Spain/Navarre/NavarreTest.php +++ b/tests/Spain/Navarre/NavarreTest.php @@ -30,6 +30,8 @@ class NavarreTest extends NavarreBaseTestCase implements ProviderTestCase /** * Initial setup of this Test Case. + * + * @throws \Exception */ protected function setUp(): void { @@ -38,8 +40,6 @@ protected function setUp(): void /** * Tests if all official holidays in Navarre (Spain) are defined by the provider class. - * - * @throws ReflectionException */ public function testOfficialHolidays(): void { @@ -59,8 +59,6 @@ public function testOfficialHolidays(): void /** * Tests if all observed holidays in Navarre are defined by the provider class. - * - * @throws ReflectionException */ public function testObservedHolidays(): void { @@ -74,8 +72,6 @@ public function testObservedHolidays(): void /** * Tests if all seasonal holidays in Navarre are defined by the provider class. - * - * @throws ReflectionException */ public function testSeasonalHolidays(): void { @@ -84,8 +80,6 @@ public function testSeasonalHolidays(): void /** * Tests if all bank holidays in Navarre are defined by the provider class. - * - * @throws ReflectionException */ public function testBankHolidays(): void { @@ -94,8 +88,6 @@ public function testBankHolidays(): void /** * Tests if all other holidays in Navarre are defined by the provider class. - * - * @throws ReflectionException */ public function testOtherHolidays(): void { @@ -104,6 +96,7 @@ public function testOtherHolidays(): void /** * @throws ReflectionException + * @throws \Exception */ public function testSources(): void { diff --git a/tests/Spain/NewYearsDayTest.php b/tests/Spain/NewYearsDayTest.php index 4cde99773..e56b2c2a0 100644 --- a/tests/Spain/NewYearsDayTest.php +++ b/tests/Spain/NewYearsDayTest.php @@ -16,7 +16,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -37,8 +36,6 @@ class NewYearsDayTest extends SpainBaseTestCase implements HolidayTestCase * * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testHoliday(int $year, DateTime $expected): void { @@ -60,7 +57,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -75,7 +72,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Spain/RegionOfMurcia/RegionOfMurciaDayTest.php b/tests/Spain/RegionOfMurcia/RegionOfMurciaDayTest.php index 351626ad7..a6e57311e 100644 --- a/tests/Spain/RegionOfMurcia/RegionOfMurciaDayTest.php +++ b/tests/Spain/RegionOfMurcia/RegionOfMurciaDayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -40,7 +39,6 @@ class RegionOfMurciaDayTest extends RegionOfMurciaBaseTestCase implements Holida * Tests the holiday defined in this test on or after establishment. * * @throws Exception - * @throws ReflectionException */ public function testHolidayOnAfterEstablishment(): void { @@ -56,7 +54,7 @@ public function testHolidayOnAfterEstablishment(): void /** * Tests the holiday defined in this test before establishment. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayBeforeEstablishment(): void { @@ -70,7 +68,7 @@ public function testHolidayBeforeEstablishment(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -85,7 +83,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Spain/RegionOfMurcia/RegionOfMurciaTest.php b/tests/Spain/RegionOfMurcia/RegionOfMurciaTest.php index a7989d3f3..8e0d5a411 100644 --- a/tests/Spain/RegionOfMurcia/RegionOfMurciaTest.php +++ b/tests/Spain/RegionOfMurcia/RegionOfMurciaTest.php @@ -30,6 +30,8 @@ class RegionOfMurciaTest extends RegionOfMurciaBaseTestCase implements ProviderT /** * Initial setup of this Test Case. + * + * @throws \Exception */ protected function setUp(): void { @@ -38,8 +40,6 @@ protected function setUp(): void /** * Tests if all official holidays in the Region of Murcia (Spain) are defined by the provider class. - * - * @throws ReflectionException */ public function testOfficialHolidays(): void { @@ -60,8 +60,6 @@ public function testOfficialHolidays(): void /** * Tests if all observed holidays in the Region of Murcia are defined by the provider class. - * - * @throws ReflectionException */ public function testObservedHolidays(): void { @@ -74,8 +72,6 @@ public function testObservedHolidays(): void /** * Tests if all seasonal holidays in the Region of Murcia are defined by the provider class. - * - * @throws ReflectionException */ public function testSeasonalHolidays(): void { @@ -84,8 +80,6 @@ public function testSeasonalHolidays(): void /** * Tests if all bank holidays in the Region of Murcia are defined by the provider class. - * - * @throws ReflectionException */ public function testBankHolidays(): void { @@ -94,8 +88,6 @@ public function testBankHolidays(): void /** * Tests if all other holidays in the Region of Murcia are defined by the provider class. - * - * @throws ReflectionException */ public function testOtherHolidays(): void { @@ -104,6 +96,7 @@ public function testOtherHolidays(): void /** * @throws ReflectionException + * @throws \Exception */ public function testSources(): void { diff --git a/tests/Spain/SpainTest.php b/tests/Spain/SpainTest.php index 829b84c54..891e184a2 100644 --- a/tests/Spain/SpainTest.php +++ b/tests/Spain/SpainTest.php @@ -30,6 +30,8 @@ class SpainTest extends SpainBaseTestCase implements ProviderTestCase /** * Initial setup of this Test Case. + * + * @throws \Exception */ protected function setUp(): void { @@ -38,8 +40,6 @@ protected function setUp(): void /** * Tests if all official holidays in Spain are defined by the provider class. - * - * @throws ReflectionException */ public function testOfficialHolidays(): void { @@ -59,8 +59,6 @@ public function testOfficialHolidays(): void /** * Tests if all observed holidays in Spain are defined by the provider class. - * - * @throws ReflectionException */ public function testObservedHolidays(): void { @@ -69,8 +67,6 @@ public function testObservedHolidays(): void /** * Tests if all seasonal holidays in Spain are defined by the provider class. - * - * @throws ReflectionException */ public function testSeasonalHolidays(): void { @@ -79,8 +75,6 @@ public function testSeasonalHolidays(): void /** * Tests if all bank holidays in Spain are defined by the provider class. - * - * @throws ReflectionException */ public function testBankHolidays(): void { @@ -89,8 +83,6 @@ public function testBankHolidays(): void /** * Tests if all other holidays in Spain are defined by the provider class. - * - * @throws ReflectionException */ public function testOtherHolidays(): void { @@ -99,6 +91,7 @@ public function testOtherHolidays(): void /** * @throws ReflectionException + * @throws \Exception */ public function testSources(): void { diff --git a/tests/Spain/ValencianCommunity/ValencianCommunityDayTest.php b/tests/Spain/ValencianCommunity/ValencianCommunityDayTest.php index 5f19ccbda..d5207e89c 100644 --- a/tests/Spain/ValencianCommunity/ValencianCommunityDayTest.php +++ b/tests/Spain/ValencianCommunity/ValencianCommunityDayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -40,7 +39,6 @@ class ValencianCommunityDayTest extends ValencianCommunityBaseTestCase implement * Tests the holiday defined in this test on or after establishment. * * @throws Exception - * @throws ReflectionException */ public function testHolidayOnAfterEstablishment(): void { @@ -56,7 +54,7 @@ public function testHolidayOnAfterEstablishment(): void /** * Tests the holiday defined in this test before establishment. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayBeforeEstablishment(): void { @@ -70,7 +68,7 @@ public function testHolidayBeforeEstablishment(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -85,7 +83,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Spain/ValencianCommunity/ValencianCommunityTest.php b/tests/Spain/ValencianCommunity/ValencianCommunityTest.php index 732deea27..d284ca657 100644 --- a/tests/Spain/ValencianCommunity/ValencianCommunityTest.php +++ b/tests/Spain/ValencianCommunity/ValencianCommunityTest.php @@ -30,6 +30,8 @@ class ValencianCommunityTest extends ValencianCommunityBaseTestCase implements P /** * Initial setup of this Test Case. + * + * @throws \Exception */ protected function setUp(): void { @@ -38,8 +40,6 @@ protected function setUp(): void /** * Tests if all official holidays in the Valencian Community (Spain) are defined by the provider class. - * - * @throws ReflectionException */ public function testOfficialHolidays(): void { @@ -60,8 +60,6 @@ public function testOfficialHolidays(): void /** * Tests if all observed holidays in the Valencian Community are defined by the provider class. - * - * @throws ReflectionException */ public function testObservedHolidays(): void { @@ -74,8 +72,6 @@ public function testObservedHolidays(): void /** * Tests if all seasonal holidays in the Valencian Community are defined by the provider class. - * - * @throws ReflectionException */ public function testSeasonalHolidays(): void { @@ -84,8 +80,6 @@ public function testSeasonalHolidays(): void /** * Tests if all bank holidays in the Valencian Community are defined by the provider class. - * - * @throws ReflectionException */ public function testBankHolidays(): void { @@ -94,8 +88,6 @@ public function testBankHolidays(): void /** * Tests if all other holidays in the Valencian Community are defined by the provider class. - * - * @throws ReflectionException */ public function testOtherHolidays(): void { @@ -104,6 +96,7 @@ public function testOtherHolidays(): void /** * @throws ReflectionException + * @throws \Exception */ public function testSources(): void { diff --git a/tests/Spain/ValentinesDayTest.php b/tests/Spain/ValentinesDayTest.php index dd830d65d..1ad39240f 100644 --- a/tests/Spain/ValentinesDayTest.php +++ b/tests/Spain/ValentinesDayTest.php @@ -16,7 +16,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -37,8 +36,6 @@ class ValentinesDayTest extends SpainBaseTestCase implements HolidayTestCase * * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testHoliday(int $year, DateTime $expected): void { @@ -60,7 +57,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -75,7 +72,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Spain/stJosephsDayTest.php b/tests/Spain/stJosephsDayTest.php index 3c811e549..de1c563df 100644 --- a/tests/Spain/stJosephsDayTest.php +++ b/tests/Spain/stJosephsDayTest.php @@ -16,7 +16,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -43,8 +42,6 @@ class stJosephsDayTest extends SpainBaseTestCase implements HolidayTestCase * * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testHoliday(int $year, DateTime $expected): void { @@ -66,7 +63,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -81,7 +78,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Sweden/AllSaintsDayTest.php b/tests/Sweden/AllSaintsDayTest.php index c2b0450a5..29dd0866e 100644 --- a/tests/Sweden/AllSaintsDayTest.php +++ b/tests/Sweden/AllSaintsDayTest.php @@ -18,7 +18,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -39,8 +38,6 @@ class AllSaintsDayTest extends SwedenBaseTestCase implements HolidayTestCase * * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testHoliday(int $year, DateTime $expected): void { @@ -78,7 +75,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -93,7 +90,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Sweden/AllSaintsEveTest.php b/tests/Sweden/AllSaintsEveTest.php index f1228d348..a78d0ab93 100644 --- a/tests/Sweden/AllSaintsEveTest.php +++ b/tests/Sweden/AllSaintsEveTest.php @@ -18,7 +18,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -39,8 +38,6 @@ class AllSaintsEveTest extends SwedenBaseTestCase implements HolidayTestCase * * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testHoliday(int $year, DateTime $expected): void { @@ -78,7 +75,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -93,7 +90,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Sweden/AscensionDayTest.php b/tests/Sweden/AscensionDayTest.php index 646d56268..93a7bee3b 100644 --- a/tests/Sweden/AscensionDayTest.php +++ b/tests/Sweden/AscensionDayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -35,7 +34,6 @@ class AscensionDayTest extends SwedenBaseTestCase implements HolidayTestCase * Tests Ascension Day. * * @throws Exception - * @throws ReflectionException */ public function testAscensionDay(): void { @@ -51,7 +49,7 @@ public function testAscensionDay(): void /** * Tests translated name of Ascension Day. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -66,7 +64,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Sweden/ChristmasDayTest.php b/tests/Sweden/ChristmasDayTest.php index d1414856d..26ba55640 100644 --- a/tests/Sweden/ChristmasDayTest.php +++ b/tests/Sweden/ChristmasDayTest.php @@ -16,7 +16,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -37,8 +36,6 @@ class ChristmasDayTest extends SwedenBaseTestCase implements HolidayTestCase * * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testHoliday(int $year, DateTime $expected): void { @@ -60,7 +57,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -75,7 +72,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Sweden/ChristmasEveTest.php b/tests/Sweden/ChristmasEveTest.php index 3f4aa1fb2..45574c0df 100644 --- a/tests/Sweden/ChristmasEveTest.php +++ b/tests/Sweden/ChristmasEveTest.php @@ -16,7 +16,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -37,8 +36,6 @@ class ChristmasEveTest extends SwedenBaseTestCase implements HolidayTestCase * * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testHoliday(int $year, DateTime $expected): void { @@ -60,7 +57,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -75,7 +72,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Sweden/EasterMondayTest.php b/tests/Sweden/EasterMondayTest.php index cd7965f4b..01cf4fcd8 100644 --- a/tests/Sweden/EasterMondayTest.php +++ b/tests/Sweden/EasterMondayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -35,7 +34,6 @@ class EasterMondayTest extends SwedenBaseTestCase implements HolidayTestCase * Tests the holiday defined in this test. * * @throws Exception - * @throws ReflectionException */ public function testHoliday(): void { @@ -51,7 +49,7 @@ public function testHoliday(): void /** * Tests translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -66,7 +64,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Sweden/EasterTest.php b/tests/Sweden/EasterTest.php index 4da370867..4ac2ac7ce 100644 --- a/tests/Sweden/EasterTest.php +++ b/tests/Sweden/EasterTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -35,7 +34,6 @@ class EasterTest extends SwedenBaseTestCase implements HolidayTestCase * Tests the holiday defined in this test. * * @throws Exception - * @throws ReflectionException */ public function testHoliday(): void { @@ -51,7 +49,7 @@ public function testHoliday(): void /** * Tests translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -66,7 +64,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Sweden/EpiphanyEveTest.php b/tests/Sweden/EpiphanyEveTest.php index 0e3f53c54..8d2ecb0b9 100644 --- a/tests/Sweden/EpiphanyEveTest.php +++ b/tests/Sweden/EpiphanyEveTest.php @@ -16,7 +16,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -37,8 +36,6 @@ class EpiphanyEveTest extends SwedenBaseTestCase implements HolidayTestCase * * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testHoliday(int $year, DateTime $expected): void { @@ -60,7 +57,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -75,7 +72,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Sweden/EpiphanyTest.php b/tests/Sweden/EpiphanyTest.php index 1e1bf999b..6084bf01d 100644 --- a/tests/Sweden/EpiphanyTest.php +++ b/tests/Sweden/EpiphanyTest.php @@ -16,7 +16,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -37,8 +36,6 @@ class EpiphanyTest extends SwedenBaseTestCase implements HolidayTestCase * * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testHoliday(int $year, DateTime $expected): void { @@ -60,7 +57,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -75,7 +72,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Sweden/GoodFridayTest.php b/tests/Sweden/GoodFridayTest.php index 3c1fb2e77..29bb6c651 100644 --- a/tests/Sweden/GoodFridayTest.php +++ b/tests/Sweden/GoodFridayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -35,7 +34,6 @@ class GoodFridayTest extends SwedenBaseTestCase implements HolidayTestCase * Tests the holiday defined in this test. * * @throws Exception - * @throws ReflectionException */ public function testHoliday(): void { @@ -51,7 +49,7 @@ public function testHoliday(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -66,7 +64,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Sweden/InternationalWorkersDayTest.php b/tests/Sweden/InternationalWorkersDayTest.php index 10b818889..0aa5eab57 100644 --- a/tests/Sweden/InternationalWorkersDayTest.php +++ b/tests/Sweden/InternationalWorkersDayTest.php @@ -16,7 +16,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -37,8 +36,6 @@ class InternationalWorkersDayTest extends SwedenBaseTestCase implements HolidayT * * @param int $year the year for which International Workers' Day needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testInternationalWorkersDay(int $year, DateTime $expected): void { @@ -48,7 +45,7 @@ public function testInternationalWorkersDay(int $year, DateTime $expected): void /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -63,7 +60,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Sweden/NationalDayTest.php b/tests/Sweden/NationalDayTest.php index 80ad69072..6be166472 100644 --- a/tests/Sweden/NationalDayTest.php +++ b/tests/Sweden/NationalDayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -40,7 +39,6 @@ class NationalDayTest extends SwedenBaseTestCase implements HolidayTestCase * Tests the holiday defined in this test on or after establishment. * * @throws Exception - * @throws ReflectionException */ public function testHolidayOnAfterEstablishment(): void { @@ -56,7 +54,7 @@ public function testHolidayOnAfterEstablishment(): void /** * Tests the holiday defined in this test before establishment. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayBeforeEstablishment(): void { @@ -70,7 +68,7 @@ public function testHolidayBeforeEstablishment(): void /** * Tests the translated name of the holiday defined in this test on or after establishment. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -85,7 +83,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { @@ -100,7 +98,7 @@ public function testHolidayType(): void /** * Tests the translated name of the holiday defined in this test on or after establishment. * - * @throws ReflectionException + * @throws Exception */ public function testTranslationOnAfterNameChange(): void { diff --git a/tests/Sweden/NewYearsDayTest.php b/tests/Sweden/NewYearsDayTest.php index 7dbf2cb77..bb291757d 100644 --- a/tests/Sweden/NewYearsDayTest.php +++ b/tests/Sweden/NewYearsDayTest.php @@ -16,7 +16,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -37,8 +36,6 @@ class NewYearsDayTest extends SwedenBaseTestCase implements HolidayTestCase * * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testHoliday(int $year, DateTime $expected): void { @@ -60,7 +57,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -75,7 +72,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Sweden/NewYearsEveTest.php b/tests/Sweden/NewYearsEveTest.php index d00fe33dd..8e12c7b07 100644 --- a/tests/Sweden/NewYearsEveTest.php +++ b/tests/Sweden/NewYearsEveTest.php @@ -16,7 +16,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -37,8 +36,6 @@ class NewYearsEveTest extends SwedenBaseTestCase implements HolidayTestCase * * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testHoliday(int $year, DateTime $expected): void { @@ -60,7 +57,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -75,7 +72,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Sweden/PentecostTest.php b/tests/Sweden/PentecostTest.php index 586badd4e..bd8f13281 100644 --- a/tests/Sweden/PentecostTest.php +++ b/tests/Sweden/PentecostTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -35,7 +34,6 @@ class PentecostTest extends SwedenBaseTestCase implements HolidayTestCase * Tests the holiday defined in this test. * * @throws Exception - * @throws ReflectionException */ public function testHoliday(): void { @@ -51,7 +49,7 @@ public function testHoliday(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -66,7 +64,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Sweden/SecondChristmasDayTest.php b/tests/Sweden/SecondChristmasDayTest.php index 8b6ca7ad5..e66f9a523 100644 --- a/tests/Sweden/SecondChristmasDayTest.php +++ b/tests/Sweden/SecondChristmasDayTest.php @@ -16,7 +16,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -37,8 +36,6 @@ class SecondChristmasDayTest extends SwedenBaseTestCase implements HolidayTestCa * * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testHoliday(int $year, DateTime $expected): void { @@ -60,7 +57,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -75,7 +72,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Sweden/StJohnsDayTest.php b/tests/Sweden/StJohnsDayTest.php index 4890117ba..91d5ea47a 100644 --- a/tests/Sweden/StJohnsDayTest.php +++ b/tests/Sweden/StJohnsDayTest.php @@ -14,7 +14,6 @@ namespace Yasumi\tests\Sweden; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; use Yasumi\Yasumi; @@ -32,7 +31,7 @@ class StJohnsDayTest extends SwedenBaseTestCase implements HolidayTestCase /** * Tests the holiday defined in this test. * - * @throws ReflectionException + * @throws \Exception */ public function testHoliday(): void { @@ -56,7 +55,7 @@ public function testHoliday(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws \Exception */ public function testTranslation(): void { @@ -71,7 +70,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Sweden/StJohnsEveTest.php b/tests/Sweden/StJohnsEveTest.php index 05dcac7bf..c540b5493 100644 --- a/tests/Sweden/StJohnsEveTest.php +++ b/tests/Sweden/StJohnsEveTest.php @@ -14,7 +14,6 @@ namespace Yasumi\tests\Sweden; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; use Yasumi\Yasumi; @@ -32,7 +31,7 @@ class StJohnsEveTest extends SwedenBaseTestCase implements HolidayTestCase /** * Tests the holiday defined in this test. * - * @throws ReflectionException + * @throws \Exception */ public function testHoliday(): void { @@ -56,7 +55,7 @@ public function testHoliday(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws \Exception */ public function testTranslation(): void { @@ -71,7 +70,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Sweden/SwedenTest.php b/tests/Sweden/SwedenTest.php index 111cd0755..bc688edaa 100644 --- a/tests/Sweden/SwedenTest.php +++ b/tests/Sweden/SwedenTest.php @@ -30,6 +30,8 @@ class SwedenTest extends SwedenBaseTestCase implements ProviderTestCase /** * Initial setup of this Test Case. + * + * @throws \Exception */ protected function setUp(): void { @@ -38,8 +40,6 @@ protected function setUp(): void /** * Tests if all official holidays in Sweden (Spain) are defined by the provider class. - * - * @throws ReflectionException */ public function testOfficialHolidays(): void { @@ -62,8 +62,6 @@ public function testOfficialHolidays(): void /** * Tests if all observed holidays in Sweden are defined by the provider class. - * - * @throws ReflectionException */ public function testObservedHolidays(): void { @@ -79,8 +77,6 @@ public function testObservedHolidays(): void /** * Tests if all seasonal holidays in Sweden are defined by the provider class. - * - * @throws ReflectionException */ public function testSeasonalHolidays(): void { @@ -89,8 +85,6 @@ public function testSeasonalHolidays(): void /** * Tests if all bank holidays in Sweden are defined by the provider class. - * - * @throws ReflectionException */ public function testBankHolidays(): void { @@ -99,8 +93,6 @@ public function testBankHolidays(): void /** * Tests if all other holidays in Sweden are defined by the provider class. - * - * @throws ReflectionException */ public function testOtherHolidays(): void { @@ -109,6 +101,7 @@ public function testOtherHolidays(): void /** * @throws ReflectionException + * @throws \Exception */ public function testSources(): void { diff --git a/tests/Sweden/WalpurgisEveTest.php b/tests/Sweden/WalpurgisEveTest.php index 4422afbd1..542cab9f0 100644 --- a/tests/Sweden/WalpurgisEveTest.php +++ b/tests/Sweden/WalpurgisEveTest.php @@ -16,7 +16,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -37,8 +36,6 @@ class WalpurgisEveTest extends SwedenBaseTestCase implements HolidayTestCase * * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testHoliday(int $year, DateTime $expected): void { @@ -60,7 +57,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -75,7 +72,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Aargau/AargauTest.php b/tests/Switzerland/Aargau/AargauTest.php index 1897542c2..e0bfab4b9 100644 --- a/tests/Switzerland/Aargau/AargauTest.php +++ b/tests/Switzerland/Aargau/AargauTest.php @@ -26,10 +26,12 @@ class AargauTest extends AargauBaseTestCase implements ProviderTestCase /** * @var int year random year number used for all tests in this Test Case */ - protected $year; + protected int $year; /** * Initial setup of this Test Case. + * + * @throws \Exception */ protected function setUp(): void { @@ -38,8 +40,6 @@ protected function setUp(): void /** * Tests if all official holidays in Aargau (Switzerland) are defined by the provider class. - * - * @throws ReflectionException */ public function testOfficialHolidays(): void { @@ -52,8 +52,6 @@ public function testOfficialHolidays(): void /** * Tests if all official holidays in Aargau (Switzerland) are defined by the provider class. - * - * @throws ReflectionException */ public function testRegionalHolidays(): void { @@ -67,8 +65,6 @@ public function testRegionalHolidays(): void /** * Tests if all observed holidays in Aargau (Switzerland) are defined by the provider class. - * - * @throws ReflectionException */ public function testObservedHolidays(): void { @@ -82,8 +78,6 @@ public function testObservedHolidays(): void /** * Tests if all seasonal holidays in Aargau (Switzerland) are defined by the provider class. - * - * @throws ReflectionException */ public function testSeasonalHolidays(): void { @@ -92,8 +86,6 @@ public function testSeasonalHolidays(): void /** * Tests if all bank holidays in Aargau (Switzerland) are defined by the provider class. - * - * @throws ReflectionException */ public function testBankHolidays(): void { @@ -102,8 +94,6 @@ public function testBankHolidays(): void /** * Tests if all other holidays in Aargau (Switzerland) are defined by the provider class. - * - * @throws ReflectionException */ public function testOtherHolidays(): void { @@ -112,6 +102,7 @@ public function testOtherHolidays(): void /** * @throws ReflectionException + * @throws \Exception */ public function testSources(): void { diff --git a/tests/Switzerland/Aargau/AscensionDayTest.php b/tests/Switzerland/Aargau/AscensionDayTest.php index 6955ce258..552f92c76 100644 --- a/tests/Switzerland/Aargau/AscensionDayTest.php +++ b/tests/Switzerland/Aargau/AscensionDayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -35,7 +34,6 @@ class AscensionDayTest extends AargauBaseTestCase implements HolidayTestCase * Tests Ascension Day. * * @throws Exception - * @throws ReflectionException */ public function testAscensionDay(): void { @@ -51,7 +49,7 @@ public function testAscensionDay(): void /** * Tests translated name of Ascension Day. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -66,7 +64,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Aargau/ChristmasDayTest.php b/tests/Switzerland/Aargau/ChristmasDayTest.php index c15531c02..1536b1889 100644 --- a/tests/Switzerland/Aargau/ChristmasDayTest.php +++ b/tests/Switzerland/Aargau/ChristmasDayTest.php @@ -16,7 +16,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -37,8 +36,6 @@ class ChristmasDayTest extends AargauBaseTestCase implements HolidayTestCase * * @param int $year the year for which Christmas Day needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testChristmasDay(int $year, DateTime $expected): void { @@ -60,7 +57,7 @@ public function ChristmasDayDataProvider(): array /** * Tests translated name of Christmas Day. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -75,7 +72,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Aargau/GoodFridayTest.php b/tests/Switzerland/Aargau/GoodFridayTest.php index d5b8881f4..405727beb 100644 --- a/tests/Switzerland/Aargau/GoodFridayTest.php +++ b/tests/Switzerland/Aargau/GoodFridayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -35,7 +34,6 @@ class GoodFridayTest extends AargauBaseTestCase implements HolidayTestCase * Tests the holiday defined in this test. * * @throws Exception - * @throws ReflectionException */ public function testHoliday(): void { @@ -51,7 +49,7 @@ public function testHoliday(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -66,7 +64,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Aargau/NewYearsDayTest.php b/tests/Switzerland/Aargau/NewYearsDayTest.php index 082609218..6594e5a8f 100644 --- a/tests/Switzerland/Aargau/NewYearsDayTest.php +++ b/tests/Switzerland/Aargau/NewYearsDayTest.php @@ -16,7 +16,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -37,8 +36,6 @@ class NewYearsDayTest extends AargauBaseTestCase implements HolidayTestCase * * @param int $year the year for which New Years Day needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testNewYearsDay(int $year, DateTime $expected): void { @@ -48,7 +45,7 @@ public function testNewYearsDay(int $year, DateTime $expected): void /** * Tests translated name of New Years Day. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -63,7 +60,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/AppenzellAusserrhoden/AppenzellAusserrhodenTest.php b/tests/Switzerland/AppenzellAusserrhoden/AppenzellAusserrhodenTest.php index aebf1ead1..f556be1d9 100644 --- a/tests/Switzerland/AppenzellAusserrhoden/AppenzellAusserrhodenTest.php +++ b/tests/Switzerland/AppenzellAusserrhoden/AppenzellAusserrhodenTest.php @@ -26,10 +26,12 @@ class AppenzellAusserrhodenTest extends AppenzellAusserrhodenBaseTestCase implem /** * @var int year random year number used for all tests in this Test Case */ - protected $year; + protected int $year; /** * Initial setup of this Test Case. + * + * @throws \Exception */ protected function setUp(): void { @@ -38,8 +40,6 @@ protected function setUp(): void /** * Tests if all official holidays in Appenzell Ausserrhoden (Switzerland) are defined by the provider class. - * - * @throws ReflectionException */ public function testOfficialHolidays(): void { @@ -52,8 +52,6 @@ public function testOfficialHolidays(): void /** * Tests if all regional holidays in Appenzell Ausserrhoden (Switzerland) are defined by the provider class. - * - * @throws ReflectionException */ public function testRegionalHolidays(): void { @@ -70,8 +68,6 @@ public function testRegionalHolidays(): void /** * Tests if all observed holidays in Appenzell Ausserrhoden (Switzerland) are defined by the provider class. - * - * @throws ReflectionException */ public function testObservedHolidays(): void { @@ -85,8 +81,6 @@ public function testObservedHolidays(): void /** * Tests if all seasonal holidays in Appenzell Ausserrhoden (Switzerland) are defined by the provider class. - * - * @throws ReflectionException */ public function testSeasonalHolidays(): void { @@ -95,8 +89,6 @@ public function testSeasonalHolidays(): void /** * Tests if all bank holidays in Appenzell Ausserrhoden (Switzerland) are defined by the provider class. - * - * @throws ReflectionException */ public function testBankHolidays(): void { @@ -105,8 +97,6 @@ public function testBankHolidays(): void /** * Tests if all other holidays in Appenzell Ausserrhoden (Switzerland) are defined by the provider class. - * - * @throws ReflectionException */ public function testOtherHolidays(): void { @@ -115,6 +105,7 @@ public function testOtherHolidays(): void /** * @throws ReflectionException + * @throws \Exception */ public function testSources(): void { diff --git a/tests/Switzerland/AppenzellAusserrhoden/AscensionDayTest.php b/tests/Switzerland/AppenzellAusserrhoden/AscensionDayTest.php index 5e072aa6d..c18542a83 100644 --- a/tests/Switzerland/AppenzellAusserrhoden/AscensionDayTest.php +++ b/tests/Switzerland/AppenzellAusserrhoden/AscensionDayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -35,7 +34,6 @@ class AscensionDayTest extends AppenzellAusserrhodenBaseTestCase implements Holi * Tests Ascension Day. * * @throws Exception - * @throws ReflectionException */ public function testAscensionDay(): void { @@ -51,7 +49,7 @@ public function testAscensionDay(): void /** * Tests translated name of Ascension Day. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -66,7 +64,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/AppenzellAusserrhoden/ChristmasDayTest.php b/tests/Switzerland/AppenzellAusserrhoden/ChristmasDayTest.php index 7a9656248..333ec69dd 100644 --- a/tests/Switzerland/AppenzellAusserrhoden/ChristmasDayTest.php +++ b/tests/Switzerland/AppenzellAusserrhoden/ChristmasDayTest.php @@ -16,7 +16,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -37,8 +36,6 @@ class ChristmasDayTest extends AppenzellAusserrhodenBaseTestCase implements Holi * * @param int $year the year for which Christmas Day needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testChristmasDay(int $year, DateTime $expected): void { @@ -60,7 +57,7 @@ public function ChristmasDayDataProvider(): array /** * Tests translated name of Christmas Day. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -75,7 +72,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/AppenzellAusserrhoden/EasterMondayTest.php b/tests/Switzerland/AppenzellAusserrhoden/EasterMondayTest.php index eff613788..5e53dc321 100644 --- a/tests/Switzerland/AppenzellAusserrhoden/EasterMondayTest.php +++ b/tests/Switzerland/AppenzellAusserrhoden/EasterMondayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -35,7 +34,6 @@ class EasterMondayTest extends AppenzellAusserrhodenBaseTestCase implements Holi * Tests Easter Monday. * * @throws Exception - * @throws ReflectionException */ public function testEasterMonday(): void { @@ -51,7 +49,7 @@ public function testEasterMonday(): void /** * Tests translated name of Easter Monday. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -66,7 +64,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/AppenzellAusserrhoden/GoodFridayTest.php b/tests/Switzerland/AppenzellAusserrhoden/GoodFridayTest.php index 1c5d4ba2e..46cecf959 100644 --- a/tests/Switzerland/AppenzellAusserrhoden/GoodFridayTest.php +++ b/tests/Switzerland/AppenzellAusserrhoden/GoodFridayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -35,7 +34,6 @@ class GoodFridayTest extends AppenzellAusserrhodenBaseTestCase implements Holida * Tests the holiday defined in this test. * * @throws Exception - * @throws ReflectionException */ public function testHoliday(): void { @@ -51,7 +49,7 @@ public function testHoliday(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -66,7 +64,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/AppenzellAusserrhoden/NewYearsDayTest.php b/tests/Switzerland/AppenzellAusserrhoden/NewYearsDayTest.php index 105f9102a..a00afc38f 100644 --- a/tests/Switzerland/AppenzellAusserrhoden/NewYearsDayTest.php +++ b/tests/Switzerland/AppenzellAusserrhoden/NewYearsDayTest.php @@ -16,7 +16,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -37,8 +36,6 @@ class NewYearsDayTest extends AppenzellAusserrhodenBaseTestCase implements Holid * * @param int $year the year for which New Years Day needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testNewYearsDay(int $year, DateTime $expected): void { @@ -48,7 +45,7 @@ public function testNewYearsDay(int $year, DateTime $expected): void /** * Tests translated name of New Years Day. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -63,7 +60,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/AppenzellAusserrhoden/PentecostMondayTest.php b/tests/Switzerland/AppenzellAusserrhoden/PentecostMondayTest.php index 46805ccdc..911f20286 100644 --- a/tests/Switzerland/AppenzellAusserrhoden/PentecostMondayTest.php +++ b/tests/Switzerland/AppenzellAusserrhoden/PentecostMondayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -35,7 +34,6 @@ class PentecostMondayTest extends AppenzellAusserrhodenBaseTestCase implements H * Tests Pentecost Monday. * * @throws Exception - * @throws ReflectionException */ public function testPentecostMonday(): void { @@ -51,7 +49,7 @@ public function testPentecostMonday(): void /** * Tests translated name of Pentecost Monday. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -66,7 +64,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/AppenzellAusserrhoden/StStephensDayTest.php b/tests/Switzerland/AppenzellAusserrhoden/StStephensDayTest.php index 18ba2953a..58ea4a56d 100644 --- a/tests/Switzerland/AppenzellAusserrhoden/StStephensDayTest.php +++ b/tests/Switzerland/AppenzellAusserrhoden/StStephensDayTest.php @@ -16,7 +16,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -37,8 +36,6 @@ class StStephensDayTest extends AppenzellAusserrhodenBaseTestCase implements Hol * * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testHoliday(int $year, DateTime $expected): void { @@ -60,7 +57,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -75,7 +72,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/AppenzellInnerrhoden/AllSaintsDayTest.php b/tests/Switzerland/AppenzellInnerrhoden/AllSaintsDayTest.php index d33b8fc7a..6eb3c8e56 100644 --- a/tests/Switzerland/AppenzellInnerrhoden/AllSaintsDayTest.php +++ b/tests/Switzerland/AppenzellInnerrhoden/AllSaintsDayTest.php @@ -16,7 +16,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -37,8 +36,6 @@ class AllSaintsDayTest extends AppenzellInnerrhodenBaseTestCase implements Holid * * @param int $year the year for which All Saints' Day needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testAllSaintsDay(int $year, DateTime $expected): void { @@ -48,7 +45,7 @@ public function testAllSaintsDay(int $year, DateTime $expected): void /** * Tests translated name of All Saints' Day. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -63,7 +60,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/AppenzellInnerrhoden/AppenzellInnerrhodenTest.php b/tests/Switzerland/AppenzellInnerrhoden/AppenzellInnerrhodenTest.php index d45a9379e..b56fb97b3 100644 --- a/tests/Switzerland/AppenzellInnerrhoden/AppenzellInnerrhodenTest.php +++ b/tests/Switzerland/AppenzellInnerrhoden/AppenzellInnerrhodenTest.php @@ -26,10 +26,12 @@ class AppenzellInnerrhodenTest extends AppenzellInnerrhodenBaseTestCase implemen /** * @var int year random year number used for all tests in this Test Case */ - protected $year; + protected int $year; /** * Initial setup of this Test Case. + * + * @throws \Exception */ protected function setUp(): void { @@ -38,8 +40,6 @@ protected function setUp(): void /** * Tests if all official holidays in Appenzell Innerrhoden (Switzerland) are defined by the provider class. - * - * @throws ReflectionException */ public function testOfficialHolidays(): void { @@ -52,8 +52,6 @@ public function testOfficialHolidays(): void /** * Tests if all regional holidays in Appenzell Innerrhoden (Switzerland) are defined by the provider class. - * - * @throws ReflectionException */ public function testRegionalHolidays(): void { @@ -74,8 +72,6 @@ public function testRegionalHolidays(): void /** * Tests if all observed holidays in Appenzell Innerrhoden (Switzerland) are defined by the provider class. - * - * @throws ReflectionException */ public function testObservedHolidays(): void { @@ -89,8 +85,6 @@ public function testObservedHolidays(): void /** * Tests if all seasonal holidays in Appenzell Innerrhoden (Switzerland) are defined by the provider class. - * - * @throws ReflectionException */ public function testSeasonalHolidays(): void { @@ -99,8 +93,6 @@ public function testSeasonalHolidays(): void /** * Tests if all bank holidays in Appenzell Innerrhoden (Switzerland) are defined by the provider class. - * - * @throws ReflectionException */ public function testBankHolidays(): void { @@ -109,8 +101,6 @@ public function testBankHolidays(): void /** * Tests if all other holidays in Appenzell Innerrhoden (Switzerland) are defined by the provider class. - * - * @throws ReflectionException */ public function testOtherHolidays(): void { @@ -119,6 +109,7 @@ public function testOtherHolidays(): void /** * @throws ReflectionException + * @throws \Exception */ public function testSources(): void { diff --git a/tests/Switzerland/AppenzellInnerrhoden/AscensionDayTest.php b/tests/Switzerland/AppenzellInnerrhoden/AscensionDayTest.php index 3ea14f4e2..b092728ba 100644 --- a/tests/Switzerland/AppenzellInnerrhoden/AscensionDayTest.php +++ b/tests/Switzerland/AppenzellInnerrhoden/AscensionDayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -35,7 +34,6 @@ class AscensionDayTest extends AppenzellInnerrhodenBaseTestCase implements Holid * Tests Ascension Day. * * @throws Exception - * @throws ReflectionException */ public function testAscensionDay(): void { @@ -51,7 +49,7 @@ public function testAscensionDay(): void /** * Tests translated name of Ascension Day. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -66,7 +64,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/AppenzellInnerrhoden/AssumptionOfMaryTest.php b/tests/Switzerland/AppenzellInnerrhoden/AssumptionOfMaryTest.php index a344238b5..a2a954a58 100644 --- a/tests/Switzerland/AppenzellInnerrhoden/AssumptionOfMaryTest.php +++ b/tests/Switzerland/AppenzellInnerrhoden/AssumptionOfMaryTest.php @@ -16,7 +16,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -37,8 +36,6 @@ class AssumptionOfMaryTest extends AppenzellInnerrhodenBaseTestCase implements H * * @param int $year the year for which the day of the Assumption of Mary needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testAssumptionOfMary(int $year, DateTime $expected): void { @@ -48,7 +45,7 @@ public function testAssumptionOfMary(int $year, DateTime $expected): void /** * Tests translated name of the day of the Assumption of Mary. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -63,7 +60,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/AppenzellInnerrhoden/ChristmasDayTest.php b/tests/Switzerland/AppenzellInnerrhoden/ChristmasDayTest.php index e656e644b..b41d31d81 100644 --- a/tests/Switzerland/AppenzellInnerrhoden/ChristmasDayTest.php +++ b/tests/Switzerland/AppenzellInnerrhoden/ChristmasDayTest.php @@ -16,7 +16,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -37,8 +36,6 @@ class ChristmasDayTest extends AppenzellInnerrhodenBaseTestCase implements Holid * * @param int $year the year for which Christmas Day needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testChristmasDay(int $year, DateTime $expected): void { @@ -60,7 +57,7 @@ public function ChristmasDayDataProvider(): array /** * Tests translated name of Christmas Day. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -75,7 +72,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/AppenzellInnerrhoden/CorpusChristiTest.php b/tests/Switzerland/AppenzellInnerrhoden/CorpusChristiTest.php index 3fe9d4a77..5e1f4290c 100644 --- a/tests/Switzerland/AppenzellInnerrhoden/CorpusChristiTest.php +++ b/tests/Switzerland/AppenzellInnerrhoden/CorpusChristiTest.php @@ -16,7 +16,6 @@ use DateInterval; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\Provider\ChristianHolidays; use Yasumi\tests\HolidayTestCase; @@ -37,7 +36,6 @@ class CorpusChristiTest extends AppenzellInnerrhodenBaseTestCase implements Holi * Tests Corpus Christi. * * @throws Exception - * @throws ReflectionException */ public function testCorpusChristi(): void { @@ -53,7 +51,7 @@ public function testCorpusChristi(): void /** * Tests translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -68,7 +66,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/AppenzellInnerrhoden/EasterMondayTest.php b/tests/Switzerland/AppenzellInnerrhoden/EasterMondayTest.php index 6718592f6..5abe0ba1b 100644 --- a/tests/Switzerland/AppenzellInnerrhoden/EasterMondayTest.php +++ b/tests/Switzerland/AppenzellInnerrhoden/EasterMondayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -35,7 +34,6 @@ class EasterMondayTest extends AppenzellInnerrhodenBaseTestCase implements Holid * Tests Easter Monday. * * @throws Exception - * @throws ReflectionException */ public function testEasterMonday(): void { @@ -51,7 +49,7 @@ public function testEasterMonday(): void /** * Tests translated name of Easter Monday. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -66,7 +64,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/AppenzellInnerrhoden/GoodFridayTest.php b/tests/Switzerland/AppenzellInnerrhoden/GoodFridayTest.php index 387a3f389..97be1b50b 100644 --- a/tests/Switzerland/AppenzellInnerrhoden/GoodFridayTest.php +++ b/tests/Switzerland/AppenzellInnerrhoden/GoodFridayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -35,7 +34,6 @@ class GoodFridayTest extends AppenzellInnerrhodenBaseTestCase implements Holiday * Tests the holiday defined in this test. * * @throws Exception - * @throws ReflectionException */ public function testHoliday(): void { @@ -51,7 +49,7 @@ public function testHoliday(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -66,7 +64,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/AppenzellInnerrhoden/ImmaculateConceptionTest.php b/tests/Switzerland/AppenzellInnerrhoden/ImmaculateConceptionTest.php index d708e4664..07f83542a 100644 --- a/tests/Switzerland/AppenzellInnerrhoden/ImmaculateConceptionTest.php +++ b/tests/Switzerland/AppenzellInnerrhoden/ImmaculateConceptionTest.php @@ -16,7 +16,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -37,8 +36,6 @@ class ImmaculateConceptionTest extends AppenzellInnerrhodenBaseTestCase implemen * * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testHoliday(int $year, DateTime $expected): void { @@ -60,7 +57,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -75,7 +72,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/AppenzellInnerrhoden/NewYearsDayTest.php b/tests/Switzerland/AppenzellInnerrhoden/NewYearsDayTest.php index caf6d3e44..32f9ad85a 100644 --- a/tests/Switzerland/AppenzellInnerrhoden/NewYearsDayTest.php +++ b/tests/Switzerland/AppenzellInnerrhoden/NewYearsDayTest.php @@ -16,7 +16,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -37,8 +36,6 @@ class NewYearsDayTest extends AppenzellInnerrhodenBaseTestCase implements Holida * * @param int $year the year for which New Years Day needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testNewYearsDay(int $year, DateTime $expected): void { @@ -48,7 +45,7 @@ public function testNewYearsDay(int $year, DateTime $expected): void /** * Tests translated name of New Years Day. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -63,7 +60,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/AppenzellInnerrhoden/PentecostMondayTest.php b/tests/Switzerland/AppenzellInnerrhoden/PentecostMondayTest.php index e086d9df4..823912e12 100644 --- a/tests/Switzerland/AppenzellInnerrhoden/PentecostMondayTest.php +++ b/tests/Switzerland/AppenzellInnerrhoden/PentecostMondayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -35,7 +34,6 @@ class PentecostMondayTest extends AppenzellInnerrhodenBaseTestCase implements Ho * Tests Pentecost Monday. * * @throws Exception - * @throws ReflectionException */ public function testPentecostMonday(): void { @@ -51,7 +49,7 @@ public function testPentecostMonday(): void /** * Tests translated name of Pentecost Monday. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -66,7 +64,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/AppenzellInnerrhoden/StStephensDayTest.php b/tests/Switzerland/AppenzellInnerrhoden/StStephensDayTest.php index e300a8db6..3a804ec7d 100644 --- a/tests/Switzerland/AppenzellInnerrhoden/StStephensDayTest.php +++ b/tests/Switzerland/AppenzellInnerrhoden/StStephensDayTest.php @@ -16,7 +16,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -37,8 +36,6 @@ class StStephensDayTest extends AppenzellInnerrhodenBaseTestCase implements Holi * * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testHoliday(int $year, DateTime $expected): void { @@ -60,7 +57,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -75,7 +72,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/BaselLandschaft/AscensionDayTest.php b/tests/Switzerland/BaselLandschaft/AscensionDayTest.php index 6c663465a..6ec32e6f3 100644 --- a/tests/Switzerland/BaselLandschaft/AscensionDayTest.php +++ b/tests/Switzerland/BaselLandschaft/AscensionDayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -35,7 +34,6 @@ class AscensionDayTest extends BaselLandschaftBaseTestCase implements HolidayTes * Tests Ascension Day. * * @throws Exception - * @throws ReflectionException */ public function testAscensionDay(): void { @@ -51,7 +49,7 @@ public function testAscensionDay(): void /** * Tests translated name of Ascension Day. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -66,7 +64,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/BaselLandschaft/BaselLandschaftTest.php b/tests/Switzerland/BaselLandschaft/BaselLandschaftTest.php index ed0c82d01..096f286e4 100644 --- a/tests/Switzerland/BaselLandschaft/BaselLandschaftTest.php +++ b/tests/Switzerland/BaselLandschaft/BaselLandschaftTest.php @@ -26,10 +26,12 @@ class BaselLandschaftTest extends BaselLandschaftBaseTestCase implements Provide /** * @var int year random year number used for all tests in this Test Case */ - protected $year; + protected int $year; /** * Initial setup of this Test Case. + * + * @throws \Exception */ protected function setUp(): void { @@ -38,8 +40,6 @@ protected function setUp(): void /** * Tests if all official holidays in BaselLandschaft (Switzerland) are defined by the provider class. - * - * @throws ReflectionException */ public function testOfficialHolidays(): void { @@ -52,8 +52,6 @@ public function testOfficialHolidays(): void /** * Tests if all regional holidays in BaselLandschaft (Switzerland) are defined by the provider class. - * - * @throws ReflectionException */ public function testRegionalHolidays(): void { @@ -71,8 +69,6 @@ public function testRegionalHolidays(): void /** * Tests if all observed holidays in BaselLandschaft (Switzerland) are defined by the provider class. - * - * @throws ReflectionException */ public function testObservedHolidays(): void { @@ -86,8 +82,6 @@ public function testObservedHolidays(): void /** * Tests if all seasonal holidays in BaselLandschaft (Switzerland) are defined by the provider class. - * - * @throws ReflectionException */ public function testSeasonalHolidays(): void { @@ -96,8 +90,6 @@ public function testSeasonalHolidays(): void /** * Tests if all bank holidays in BaselLandschaft (Switzerland) are defined by the provider class. - * - * @throws ReflectionException */ public function testBankHolidays(): void { @@ -106,8 +98,6 @@ public function testBankHolidays(): void /** * Tests if all other holidays in BaselLandschaft (Switzerland) are defined by the provider class. - * - * @throws ReflectionException */ public function testOtherHolidays(): void { @@ -116,6 +106,7 @@ public function testOtherHolidays(): void /** * @throws ReflectionException + * @throws \Exception */ public function testSources(): void { diff --git a/tests/Switzerland/BaselLandschaft/ChristmasDayTest.php b/tests/Switzerland/BaselLandschaft/ChristmasDayTest.php index cc5026060..d12d55c88 100644 --- a/tests/Switzerland/BaselLandschaft/ChristmasDayTest.php +++ b/tests/Switzerland/BaselLandschaft/ChristmasDayTest.php @@ -16,7 +16,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -37,8 +36,6 @@ class ChristmasDayTest extends BaselLandschaftBaseTestCase implements HolidayTes * * @param int $year the year for which Christmas Day needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testChristmasDay(int $year, DateTime $expected): void { @@ -60,7 +57,7 @@ public function ChristmasDayDataProvider(): array /** * Tests translated name of Christmas Day. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -75,7 +72,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/BaselLandschaft/EasterMondayTest.php b/tests/Switzerland/BaselLandschaft/EasterMondayTest.php index 3e239c195..ce78317cc 100644 --- a/tests/Switzerland/BaselLandschaft/EasterMondayTest.php +++ b/tests/Switzerland/BaselLandschaft/EasterMondayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -35,7 +34,6 @@ class EasterMondayTest extends BaselLandschaftBaseTestCase implements HolidayTes * Tests Easter Monday. * * @throws Exception - * @throws ReflectionException */ public function testEasterMonday(): void { @@ -51,7 +49,7 @@ public function testEasterMonday(): void /** * Tests translated name of Easter Monday. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -66,7 +64,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/BaselLandschaft/GoodFridayTest.php b/tests/Switzerland/BaselLandschaft/GoodFridayTest.php index 29c777812..cd352aa16 100644 --- a/tests/Switzerland/BaselLandschaft/GoodFridayTest.php +++ b/tests/Switzerland/BaselLandschaft/GoodFridayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -35,7 +34,6 @@ class GoodFridayTest extends BaselLandschaftBaseTestCase implements HolidayTestC * Tests the holiday defined in this test. * * @throws Exception - * @throws ReflectionException */ public function testHoliday(): void { @@ -51,7 +49,7 @@ public function testHoliday(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -66,7 +64,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/BaselLandschaft/NewYearsDayTest.php b/tests/Switzerland/BaselLandschaft/NewYearsDayTest.php index c4419aa44..e8654a7a8 100644 --- a/tests/Switzerland/BaselLandschaft/NewYearsDayTest.php +++ b/tests/Switzerland/BaselLandschaft/NewYearsDayTest.php @@ -16,7 +16,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -37,8 +36,6 @@ class NewYearsDayTest extends BaselLandschaftBaseTestCase implements HolidayTest * * @param int $year the year for which New Years Day needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testNewYearsDay(int $year, DateTime $expected): void { @@ -48,7 +45,7 @@ public function testNewYearsDay(int $year, DateTime $expected): void /** * Tests translated name of New Years Day. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -63,7 +60,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/BaselLandschaft/PentecostMondayTest.php b/tests/Switzerland/BaselLandschaft/PentecostMondayTest.php index b23b41756..15cb63e86 100644 --- a/tests/Switzerland/BaselLandschaft/PentecostMondayTest.php +++ b/tests/Switzerland/BaselLandschaft/PentecostMondayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -35,7 +34,6 @@ class PentecostMondayTest extends BaselLandschaftBaseTestCase implements Holiday * Tests Pentecost Monday. * * @throws Exception - * @throws ReflectionException */ public function testPentecostMonday(): void { @@ -51,7 +49,7 @@ public function testPentecostMonday(): void /** * Tests translated name of Pentecost Monday. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -66,7 +64,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/BaselLandschaft/StStephensDayTest.php b/tests/Switzerland/BaselLandschaft/StStephensDayTest.php index 0807b582a..b8c101bee 100644 --- a/tests/Switzerland/BaselLandschaft/StStephensDayTest.php +++ b/tests/Switzerland/BaselLandschaft/StStephensDayTest.php @@ -16,7 +16,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -37,8 +36,6 @@ class StStephensDayTest extends BaselLandschaftBaseTestCase implements HolidayTe * * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testHoliday(int $year, DateTime $expected): void { @@ -60,7 +57,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -75,7 +72,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/BaselLandschaft/WorkersDayTest.php b/tests/Switzerland/BaselLandschaft/WorkersDayTest.php index fe2656b60..46844b970 100644 --- a/tests/Switzerland/BaselLandschaft/WorkersDayTest.php +++ b/tests/Switzerland/BaselLandschaft/WorkersDayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -39,7 +38,6 @@ class WorkersDayTest extends BaselLandschaftBaseTestCase implements HolidayTestC * @param int $year the year for which the holiday defined in this test needs to be tested * @param string $expected the expected date * - * @throws ReflectionException * @throws Exception */ public function testHoliday(int $year, string $expected): void @@ -71,7 +69,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -86,7 +84,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/BaselStadt/AscensionDayTest.php b/tests/Switzerland/BaselStadt/AscensionDayTest.php index 9bb6d03e3..3c4e0dcba 100644 --- a/tests/Switzerland/BaselStadt/AscensionDayTest.php +++ b/tests/Switzerland/BaselStadt/AscensionDayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -35,7 +34,6 @@ class AscensionDayTest extends BaselStadtBaseTestCase implements HolidayTestCase * Tests Ascension Day. * * @throws Exception - * @throws ReflectionException */ public function testAscensionDay(): void { @@ -51,7 +49,7 @@ public function testAscensionDay(): void /** * Tests translated name of Ascension Day. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -66,7 +64,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/BaselStadt/BaselStadtTest.php b/tests/Switzerland/BaselStadt/BaselStadtTest.php index ccaa745e6..15db71787 100644 --- a/tests/Switzerland/BaselStadt/BaselStadtTest.php +++ b/tests/Switzerland/BaselStadt/BaselStadtTest.php @@ -26,10 +26,12 @@ class BaselStadtTest extends BaselStadtBaseTestCase implements ProviderTestCase /** * @var int year random year number used for all tests in this Test Case */ - protected $year; + protected int $year; /** * Initial setup of this Test Case. + * + * @throws \Exception */ protected function setUp(): void { @@ -38,8 +40,6 @@ protected function setUp(): void /** * Tests if all official holidays in Basel Stadt (Switzerland) are defined by the provider class. - * - * @throws ReflectionException */ public function testOfficialHolidays(): void { @@ -52,8 +52,6 @@ public function testOfficialHolidays(): void /** * Tests if all regional holidays in Basel Stadt (Switzerland) are defined by the provider class. - * - * @throws ReflectionException */ public function testRegionalHolidays(): void { @@ -71,8 +69,6 @@ public function testRegionalHolidays(): void /** * Tests if all observed holidays in Basel Stadt (Switzerland) are defined by the provider class. - * - * @throws ReflectionException */ public function testObservedHolidays(): void { @@ -86,8 +82,6 @@ public function testObservedHolidays(): void /** * Tests if all seasonal holidays in Basel Stadt (Switzerland) are defined by the provider class. - * - * @throws ReflectionException */ public function testSeasonalHolidays(): void { @@ -96,8 +90,6 @@ public function testSeasonalHolidays(): void /** * Tests if all bank holidays in Basel Stadt (Switzerland) are defined by the provider class. - * - * @throws ReflectionException */ public function testBankHolidays(): void { @@ -106,8 +98,6 @@ public function testBankHolidays(): void /** * Tests if all other holidays in Basel Stadt (Switzerland) are defined by the provider class. - * - * @throws ReflectionException */ public function testOtherHolidays(): void { @@ -116,6 +106,7 @@ public function testOtherHolidays(): void /** * @throws ReflectionException + * @throws \Exception */ public function testSources(): void { diff --git a/tests/Switzerland/BaselStadt/ChristmasDayTest.php b/tests/Switzerland/BaselStadt/ChristmasDayTest.php index 2e4fb20c2..d85d0b6c0 100644 --- a/tests/Switzerland/BaselStadt/ChristmasDayTest.php +++ b/tests/Switzerland/BaselStadt/ChristmasDayTest.php @@ -16,7 +16,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -37,8 +36,6 @@ class ChristmasDayTest extends BaselStadtBaseTestCase implements HolidayTestCase * * @param int $year the year for which Christmas Day needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testChristmasDay(int $year, DateTime $expected): void { @@ -60,7 +57,7 @@ public function ChristmasDayDataProvider(): array /** * Tests translated name of Christmas Day. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -75,7 +72,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/BaselStadt/EasterMondayTest.php b/tests/Switzerland/BaselStadt/EasterMondayTest.php index 08196decb..c924c35bc 100644 --- a/tests/Switzerland/BaselStadt/EasterMondayTest.php +++ b/tests/Switzerland/BaselStadt/EasterMondayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -35,7 +34,6 @@ class EasterMondayTest extends BaselStadtBaseTestCase implements HolidayTestCase * Tests Easter Monday. * * @throws Exception - * @throws ReflectionException */ public function testEasterMonday(): void { @@ -51,7 +49,7 @@ public function testEasterMonday(): void /** * Tests translated name of Easter Monday. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -66,7 +64,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/BaselStadt/GoodFridayTest.php b/tests/Switzerland/BaselStadt/GoodFridayTest.php index effafe53c..01453c993 100644 --- a/tests/Switzerland/BaselStadt/GoodFridayTest.php +++ b/tests/Switzerland/BaselStadt/GoodFridayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -35,7 +34,6 @@ class GoodFridayTest extends BaselStadtBaseTestCase implements HolidayTestCase * Tests the holiday defined in this test. * * @throws Exception - * @throws ReflectionException */ public function testHoliday(): void { @@ -51,7 +49,7 @@ public function testHoliday(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -66,7 +64,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/BaselStadt/NewYearsDayTest.php b/tests/Switzerland/BaselStadt/NewYearsDayTest.php index f8be83c24..d0c0b84a2 100644 --- a/tests/Switzerland/BaselStadt/NewYearsDayTest.php +++ b/tests/Switzerland/BaselStadt/NewYearsDayTest.php @@ -16,7 +16,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -37,8 +36,6 @@ class NewYearsDayTest extends BaselStadtBaseTestCase implements HolidayTestCase * * @param int $year the year for which New Years Day needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testNewYearsDay(int $year, DateTime $expected): void { @@ -48,7 +45,7 @@ public function testNewYearsDay(int $year, DateTime $expected): void /** * Tests translated name of New Years Day. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -63,7 +60,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/BaselStadt/PentecostMondayTest.php b/tests/Switzerland/BaselStadt/PentecostMondayTest.php index b15614b64..a56c0c32e 100644 --- a/tests/Switzerland/BaselStadt/PentecostMondayTest.php +++ b/tests/Switzerland/BaselStadt/PentecostMondayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -35,7 +34,6 @@ class PentecostMondayTest extends BaselStadtBaseTestCase implements HolidayTestC * Tests Pentecost Monday. * * @throws Exception - * @throws ReflectionException */ public function testPentecostMonday(): void { @@ -51,7 +49,7 @@ public function testPentecostMonday(): void /** * Tests translated name of Pentecost Monday. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -66,7 +64,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/BaselStadt/StStephensDayTest.php b/tests/Switzerland/BaselStadt/StStephensDayTest.php index 864939106..535038947 100644 --- a/tests/Switzerland/BaselStadt/StStephensDayTest.php +++ b/tests/Switzerland/BaselStadt/StStephensDayTest.php @@ -16,7 +16,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -37,8 +36,6 @@ class StStephensDayTest extends BaselStadtBaseTestCase implements HolidayTestCas * * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testHoliday(int $year, DateTime $expected): void { @@ -60,7 +57,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -75,7 +72,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/BaselStadt/WorkersDayTest.php b/tests/Switzerland/BaselStadt/WorkersDayTest.php index 2a772b678..0eb1d1ff0 100644 --- a/tests/Switzerland/BaselStadt/WorkersDayTest.php +++ b/tests/Switzerland/BaselStadt/WorkersDayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -39,7 +38,6 @@ class WorkersDayTest extends BaselStadtBaseTestCase implements HolidayTestCase * @param int $year the year for which the holiday defined in this test needs to be tested * @param string $expected the expected date * - * @throws ReflectionException * @throws Exception */ public function testHoliday(int $year, string $expected): void @@ -71,7 +69,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -86,7 +84,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Bern/AscensionDayTest.php b/tests/Switzerland/Bern/AscensionDayTest.php index a0c120914..cde186594 100644 --- a/tests/Switzerland/Bern/AscensionDayTest.php +++ b/tests/Switzerland/Bern/AscensionDayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -35,7 +34,6 @@ class AscensionDayTest extends BernBaseTestCase implements HolidayTestCase * Tests Ascension Day. * * @throws Exception - * @throws ReflectionException */ public function testAscensionDay(): void { @@ -51,7 +49,7 @@ public function testAscensionDay(): void /** * Tests translated name of Ascension Day. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -66,7 +64,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Bern/BerchtoldsTagTest.php b/tests/Switzerland/Bern/BerchtoldsTagTest.php index 13663debd..4b302fbc4 100644 --- a/tests/Switzerland/Bern/BerchtoldsTagTest.php +++ b/tests/Switzerland/Bern/BerchtoldsTagTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,7 +33,6 @@ class BerchtoldsTagTest extends BernBaseTestCase implements HolidayTestCase /** * Tests BerchtoldsTag. * - * @throws ReflectionException * @throws Exception */ public function testBerchtoldsTag(): void @@ -49,7 +47,7 @@ public function testBerchtoldsTag(): void /** * Tests translated name of BerchtoldsTag. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -64,7 +62,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Bern/BernTest.php b/tests/Switzerland/Bern/BernTest.php index 4ac9b2a0d..fb4ae83a2 100644 --- a/tests/Switzerland/Bern/BernTest.php +++ b/tests/Switzerland/Bern/BernTest.php @@ -26,10 +26,12 @@ class BernTest extends BernBaseTestCase implements ProviderTestCase /** * @var int year random year number used for all tests in this Test Case */ - protected $year; + protected int $year; /** * Initial setup of this Test Case. + * + * @throws \Exception */ protected function setUp(): void { @@ -38,8 +40,6 @@ protected function setUp(): void /** * Tests if all official holidays in Bern (Switzerland) are defined by the provider class. - * - * @throws ReflectionException */ public function testOfficialHolidays(): void { @@ -52,8 +52,6 @@ public function testOfficialHolidays(): void /** * Tests if all regional holidays in Bern (Switzerland) are defined by the provider class. - * - * @throws ReflectionException */ public function testRegionalHolidays(): void { @@ -71,8 +69,6 @@ public function testRegionalHolidays(): void /** * Tests if all observed holidays in Bern (Switzerland) are defined by the provider class. - * - * @throws ReflectionException */ public function testObservedHolidays(): void { @@ -86,8 +82,6 @@ public function testObservedHolidays(): void /** * Tests if all seasonal holidays in Bern (Switzerland) are defined by the provider class. - * - * @throws ReflectionException */ public function testSeasonalHolidays(): void { @@ -96,8 +90,6 @@ public function testSeasonalHolidays(): void /** * Tests if all bank holidays in Bern (Switzerland) are defined by the provider class. - * - * @throws ReflectionException */ public function testBankHolidays(): void { @@ -106,8 +98,6 @@ public function testBankHolidays(): void /** * Tests if all other holidays in Bern (Switzerland) are defined by the provider class. - * - * @throws ReflectionException */ public function testOtherHolidays(): void { @@ -116,6 +106,7 @@ public function testOtherHolidays(): void /** * @throws ReflectionException + * @throws \Exception */ public function testSources(): void { diff --git a/tests/Switzerland/Bern/ChristmasDayTest.php b/tests/Switzerland/Bern/ChristmasDayTest.php index b6585c5ce..2e35a2770 100644 --- a/tests/Switzerland/Bern/ChristmasDayTest.php +++ b/tests/Switzerland/Bern/ChristmasDayTest.php @@ -16,7 +16,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -37,8 +36,6 @@ class ChristmasDayTest extends BernBaseTestCase implements HolidayTestCase * * @param int $year the year for which Christmas Day needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testChristmasDay(int $year, DateTime $expected): void { @@ -60,7 +57,7 @@ public function ChristmasDayDataProvider(): array /** * Tests translated name of Christmas Day. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -75,7 +72,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Bern/EasterMondayTest.php b/tests/Switzerland/Bern/EasterMondayTest.php index 191ac1d5f..4a080cdb7 100644 --- a/tests/Switzerland/Bern/EasterMondayTest.php +++ b/tests/Switzerland/Bern/EasterMondayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -35,7 +34,6 @@ class EasterMondayTest extends BernBaseTestCase implements HolidayTestCase * Tests Easter Monday. * * @throws Exception - * @throws ReflectionException */ public function testEasterMonday(): void { @@ -51,7 +49,7 @@ public function testEasterMonday(): void /** * Tests translated name of Easter Monday. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -66,7 +64,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Bern/GoodFridayTest.php b/tests/Switzerland/Bern/GoodFridayTest.php index 666c512df..0d03e3e39 100644 --- a/tests/Switzerland/Bern/GoodFridayTest.php +++ b/tests/Switzerland/Bern/GoodFridayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -35,7 +34,6 @@ class GoodFridayTest extends BernBaseTestCase implements HolidayTestCase * Tests the holiday defined in this test. * * @throws Exception - * @throws ReflectionException */ public function testHoliday(): void { @@ -51,7 +49,7 @@ public function testHoliday(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -66,7 +64,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Bern/NewYearsDayTest.php b/tests/Switzerland/Bern/NewYearsDayTest.php index e2e06f262..002a0222d 100644 --- a/tests/Switzerland/Bern/NewYearsDayTest.php +++ b/tests/Switzerland/Bern/NewYearsDayTest.php @@ -16,7 +16,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -37,8 +36,6 @@ class NewYearsDayTest extends BernBaseTestCase implements HolidayTestCase * * @param int $year the year for which New Years Day needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testNewYearsDay(int $year, DateTime $expected): void { @@ -48,7 +45,7 @@ public function testNewYearsDay(int $year, DateTime $expected): void /** * Tests translated name of New Years Day. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -63,7 +60,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Bern/PentecostMondayTest.php b/tests/Switzerland/Bern/PentecostMondayTest.php index 0c537c754..3ee459695 100644 --- a/tests/Switzerland/Bern/PentecostMondayTest.php +++ b/tests/Switzerland/Bern/PentecostMondayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -35,7 +34,6 @@ class PentecostMondayTest extends BernBaseTestCase implements HolidayTestCase * Tests Pentecost Monday. * * @throws Exception - * @throws ReflectionException */ public function testPentecostMonday(): void { @@ -51,7 +49,7 @@ public function testPentecostMonday(): void /** * Tests translated name of Pentecost Monday. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -66,7 +64,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Bern/StStephensDayTest.php b/tests/Switzerland/Bern/StStephensDayTest.php index a98ac2519..2df96af62 100644 --- a/tests/Switzerland/Bern/StStephensDayTest.php +++ b/tests/Switzerland/Bern/StStephensDayTest.php @@ -16,7 +16,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -37,8 +36,6 @@ class StStephensDayTest extends BernBaseTestCase implements HolidayTestCase * * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testHoliday(int $year, DateTime $expected): void { @@ -60,7 +57,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -75,7 +72,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Fribourg/AllSaintsDayTest.php b/tests/Switzerland/Fribourg/AllSaintsDayTest.php index 7f109391a..f5e419d4c 100644 --- a/tests/Switzerland/Fribourg/AllSaintsDayTest.php +++ b/tests/Switzerland/Fribourg/AllSaintsDayTest.php @@ -16,7 +16,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -37,8 +36,6 @@ class AllSaintsDayTest extends FribourgBaseTestCase implements HolidayTestCase * * @param int $year the year for which All Saints' Day needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testAllSaintsDay(int $year, DateTime $expected): void { @@ -48,7 +45,7 @@ public function testAllSaintsDay(int $year, DateTime $expected): void /** * Tests translated name of All Saints' Day. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -63,7 +60,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Fribourg/AscensionDayTest.php b/tests/Switzerland/Fribourg/AscensionDayTest.php index 3c409fa35..3278a8e5d 100644 --- a/tests/Switzerland/Fribourg/AscensionDayTest.php +++ b/tests/Switzerland/Fribourg/AscensionDayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -35,7 +34,6 @@ class AscensionDayTest extends FribourgBaseTestCase implements HolidayTestCase * Tests Ascension Day. * * @throws Exception - * @throws ReflectionException */ public function testAscensionDay(): void { @@ -51,7 +49,7 @@ public function testAscensionDay(): void /** * Tests translated name of Ascension Day. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -66,7 +64,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Fribourg/AssumptionOfMaryTest.php b/tests/Switzerland/Fribourg/AssumptionOfMaryTest.php index 85f457e24..53b2e23f0 100644 --- a/tests/Switzerland/Fribourg/AssumptionOfMaryTest.php +++ b/tests/Switzerland/Fribourg/AssumptionOfMaryTest.php @@ -16,7 +16,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -37,8 +36,6 @@ class AssumptionOfMaryTest extends FribourgBaseTestCase implements HolidayTestCa * * @param int $year the year for which the day of the Assumption of Mary needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testAssumptionOfMary(int $year, DateTime $expected): void { @@ -48,7 +45,7 @@ public function testAssumptionOfMary(int $year, DateTime $expected): void /** * Tests translated name of the day of the Assumption of Mary. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -63,7 +60,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Fribourg/BerchtoldsTagTest.php b/tests/Switzerland/Fribourg/BerchtoldsTagTest.php index 1509d6e66..c19cb47b2 100644 --- a/tests/Switzerland/Fribourg/BerchtoldsTagTest.php +++ b/tests/Switzerland/Fribourg/BerchtoldsTagTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,7 +33,6 @@ class BerchtoldsTagTest extends FribourgBaseTestCase implements HolidayTestCase /** * Tests BerchtoldsTag. * - * @throws ReflectionException * @throws Exception */ public function testBerchtoldsTag(): void @@ -49,7 +47,7 @@ public function testBerchtoldsTag(): void /** * Tests translated name of BerchtoldsTag. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -64,7 +62,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Fribourg/ChristmasDayTest.php b/tests/Switzerland/Fribourg/ChristmasDayTest.php index 6673ba0c8..74204244d 100644 --- a/tests/Switzerland/Fribourg/ChristmasDayTest.php +++ b/tests/Switzerland/Fribourg/ChristmasDayTest.php @@ -16,7 +16,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -37,8 +36,6 @@ class ChristmasDayTest extends FribourgBaseTestCase implements HolidayTestCase * * @param int $year the year for which Christmas Day needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testChristmasDay(int $year, DateTime $expected): void { @@ -60,7 +57,7 @@ public function ChristmasDayDataProvider(): array /** * Tests translated name of Christmas Day. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -75,7 +72,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Fribourg/CorpusChristiTest.php b/tests/Switzerland/Fribourg/CorpusChristiTest.php index 0272d7a99..61e7fd979 100644 --- a/tests/Switzerland/Fribourg/CorpusChristiTest.php +++ b/tests/Switzerland/Fribourg/CorpusChristiTest.php @@ -16,7 +16,6 @@ use DateInterval; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\Provider\ChristianHolidays; use Yasumi\tests\HolidayTestCase; @@ -37,7 +36,6 @@ class CorpusChristiTest extends FribourgBaseTestCase implements HolidayTestCase * Tests Corpus Christi. * * @throws Exception - * @throws ReflectionException */ public function testCorpusChristi(): void { @@ -53,7 +51,7 @@ public function testCorpusChristi(): void /** * Tests translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -68,7 +66,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Fribourg/December26thTest.php b/tests/Switzerland/Fribourg/December26thTest.php index dd923e46a..ec6ccca35 100644 --- a/tests/Switzerland/Fribourg/December26thTest.php +++ b/tests/Switzerland/Fribourg/December26thTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -35,7 +34,6 @@ class December26thTest extends FribourgBaseTestCase implements HolidayTestCase * Tests December 26th. * * @throws Exception - * @throws ReflectionException */ public function testDecember26th(): void { @@ -51,7 +49,7 @@ public function testDecember26th(): void /** * Tests translated name of December 26th. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -66,7 +64,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Fribourg/EasterMondayTest.php b/tests/Switzerland/Fribourg/EasterMondayTest.php index 938044500..b6c718054 100644 --- a/tests/Switzerland/Fribourg/EasterMondayTest.php +++ b/tests/Switzerland/Fribourg/EasterMondayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -35,7 +34,6 @@ class EasterMondayTest extends FribourgBaseTestCase implements HolidayTestCase * Tests Easter Monday. * * @throws Exception - * @throws ReflectionException */ public function testEasterMonday(): void { @@ -51,7 +49,7 @@ public function testEasterMonday(): void /** * Tests translated name of Easter Monday. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -66,7 +64,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Fribourg/FribourgTest.php b/tests/Switzerland/Fribourg/FribourgTest.php index f1825b9d6..ff7095556 100644 --- a/tests/Switzerland/Fribourg/FribourgTest.php +++ b/tests/Switzerland/Fribourg/FribourgTest.php @@ -26,10 +26,12 @@ class FribourgTest extends FribourgBaseTestCase implements ProviderTestCase /** * @var int year random year number used for all tests in this Test Case */ - protected $year; + protected int $year; /** * Initial setup of this Test Case. + * + * @throws \Exception */ protected function setUp(): void { @@ -38,8 +40,6 @@ protected function setUp(): void /** * Tests if all official holidays in Fribourg (Switzerland) are defined by the provider class. - * - * @throws ReflectionException */ public function testOfficialHolidays(): void { @@ -52,8 +52,6 @@ public function testOfficialHolidays(): void /** * Tests if all regional holidays in Fribourg (Switzerland) are defined by the provider class. - * - * @throws ReflectionException */ public function testRegionalHolidays(): void { @@ -75,8 +73,6 @@ public function testRegionalHolidays(): void /** * Tests if all observed holidays in Fribourg (Switzerland) are defined by the provider class. - * - * @throws ReflectionException */ public function testObservedHolidays(): void { @@ -90,8 +86,6 @@ public function testObservedHolidays(): void /** * Tests if all seasonal holidays in Fribourg (Switzerland) are defined by the provider class. - * - * @throws ReflectionException */ public function testSeasonalHolidays(): void { @@ -100,8 +94,6 @@ public function testSeasonalHolidays(): void /** * Tests if all bank holidays in Fribourg (Switzerland) are defined by the provider class. - * - * @throws ReflectionException */ public function testBankHolidays(): void { @@ -110,8 +102,6 @@ public function testBankHolidays(): void /** * Tests if all other holidays in Fribourg (Switzerland) are defined by the provider class. - * - * @throws ReflectionException */ public function testOtherHolidays(): void { @@ -120,6 +110,7 @@ public function testOtherHolidays(): void /** * @throws ReflectionException + * @throws \Exception */ public function testSources(): void { diff --git a/tests/Switzerland/Fribourg/GoodFridayTest.php b/tests/Switzerland/Fribourg/GoodFridayTest.php index bd68f874b..922a6bc26 100644 --- a/tests/Switzerland/Fribourg/GoodFridayTest.php +++ b/tests/Switzerland/Fribourg/GoodFridayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -35,7 +34,6 @@ class GoodFridayTest extends FribourgBaseTestCase implements HolidayTestCase * Tests the holiday defined in this test. * * @throws Exception - * @throws ReflectionException */ public function testHoliday(): void { @@ -51,7 +49,7 @@ public function testHoliday(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -66,7 +64,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Fribourg/ImmaculateConceptionTest.php b/tests/Switzerland/Fribourg/ImmaculateConceptionTest.php index 2d65589c6..912fcd005 100644 --- a/tests/Switzerland/Fribourg/ImmaculateConceptionTest.php +++ b/tests/Switzerland/Fribourg/ImmaculateConceptionTest.php @@ -16,7 +16,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -37,8 +36,6 @@ class ImmaculateConceptionTest extends FribourgBaseTestCase implements HolidayTe * * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testHoliday(int $year, DateTime $expected): void { @@ -60,7 +57,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -75,7 +72,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Fribourg/NewYearsDayTest.php b/tests/Switzerland/Fribourg/NewYearsDayTest.php index d09cf73a3..22689c564 100644 --- a/tests/Switzerland/Fribourg/NewYearsDayTest.php +++ b/tests/Switzerland/Fribourg/NewYearsDayTest.php @@ -16,7 +16,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -37,8 +36,6 @@ class NewYearsDayTest extends FribourgBaseTestCase implements HolidayTestCase * * @param int $year the year for which New Years Day needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testNewYearsDay(int $year, DateTime $expected): void { @@ -48,7 +45,7 @@ public function testNewYearsDay(int $year, DateTime $expected): void /** * Tests translated name of New Years Day. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -63,7 +60,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Fribourg/PentecostMondayTest.php b/tests/Switzerland/Fribourg/PentecostMondayTest.php index ab5abf75e..2e489fe6a 100644 --- a/tests/Switzerland/Fribourg/PentecostMondayTest.php +++ b/tests/Switzerland/Fribourg/PentecostMondayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -35,7 +34,6 @@ class PentecostMondayTest extends FribourgBaseTestCase implements HolidayTestCas * Tests Pentecost Monday. * * @throws Exception - * @throws ReflectionException */ public function testPentecostMonday(): void { @@ -51,7 +49,7 @@ public function testPentecostMonday(): void /** * Tests translated name of Pentecost Monday. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -66,7 +64,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Geneva/AscensionDayTest.php b/tests/Switzerland/Geneva/AscensionDayTest.php index 172b4178e..7e50d76d0 100644 --- a/tests/Switzerland/Geneva/AscensionDayTest.php +++ b/tests/Switzerland/Geneva/AscensionDayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -35,7 +34,6 @@ class AscensionDayTest extends GenevaBaseTestCase implements HolidayTestCase * Tests Ascension Day. * * @throws Exception - * @throws ReflectionException */ public function testAscensionDay(): void { @@ -51,7 +49,7 @@ public function testAscensionDay(): void /** * Tests translated name of Ascension Day. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -66,7 +64,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Geneva/ChristmasDayTest.php b/tests/Switzerland/Geneva/ChristmasDayTest.php index 9592b1fb6..07196b248 100644 --- a/tests/Switzerland/Geneva/ChristmasDayTest.php +++ b/tests/Switzerland/Geneva/ChristmasDayTest.php @@ -16,7 +16,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -37,8 +36,6 @@ class ChristmasDayTest extends GenevaBaseTestCase implements HolidayTestCase * * @param int $year the year for which Christmas Day needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testChristmasDay(int $year, DateTime $expected): void { @@ -60,7 +57,7 @@ public function ChristmasDayDataProvider(): array /** * Tests translated name of Christmas Day. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -75,7 +72,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Geneva/EasterMondayTest.php b/tests/Switzerland/Geneva/EasterMondayTest.php index f4f24f69e..98ec27e7d 100644 --- a/tests/Switzerland/Geneva/EasterMondayTest.php +++ b/tests/Switzerland/Geneva/EasterMondayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -35,7 +34,6 @@ class EasterMondayTest extends GenevaBaseTestCase implements HolidayTestCase * Tests Easter Monday. * * @throws Exception - * @throws ReflectionException */ public function testEasterMonday(): void { @@ -51,7 +49,7 @@ public function testEasterMonday(): void /** * Tests translated name of Easter Monday. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -66,7 +64,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Geneva/GenevaTest.php b/tests/Switzerland/Geneva/GenevaTest.php index dc5e60b39..3e9c0e1af 100644 --- a/tests/Switzerland/Geneva/GenevaTest.php +++ b/tests/Switzerland/Geneva/GenevaTest.php @@ -26,10 +26,12 @@ class GenevaTest extends GenevaBaseTestCase implements ProviderTestCase /** * @var int year random year number used for all tests in this Test Case */ - protected $year; + protected int $year; /** * Initial setup of this Test Case. + * + * @throws \Exception */ protected function setUp(): void { @@ -38,8 +40,6 @@ protected function setUp(): void /** * Tests if all official holidays in Geneva (Switzerland) are defined by the provider class. - * - * @throws ReflectionException */ public function testOfficialHolidays(): void { @@ -52,8 +52,6 @@ public function testOfficialHolidays(): void /** * Tests if all regional holidays in Geneva (Switzerland) are defined by the provider class. - * - * @throws ReflectionException */ public function testRegionalHolidays(): void { @@ -75,8 +73,6 @@ public function testRegionalHolidays(): void /** * Tests if all observed holidays in Geneva (Switzerland) are defined by the provider class. - * - * @throws ReflectionException */ public function testObservedHolidays(): void { @@ -94,8 +90,6 @@ public function testObservedHolidays(): void /** * Tests if all seasonal holidays in Geneva (Switzerland) are defined by the provider class. - * - * @throws ReflectionException */ public function testSeasonalHolidays(): void { @@ -104,8 +98,6 @@ public function testSeasonalHolidays(): void /** * Tests if all bank holidays in Geneva (Switzerland) are defined by the provider class. - * - * @throws ReflectionException */ public function testBankHolidays(): void { @@ -114,8 +106,6 @@ public function testBankHolidays(): void /** * Tests if all other holidays in Geneva (Switzerland) are defined by the provider class. - * - * @throws ReflectionException */ public function testOtherHolidays(): void { @@ -129,6 +119,7 @@ public function testOtherHolidays(): void /** * @throws ReflectionException + * @throws \Exception */ public function testSources(): void { diff --git a/tests/Switzerland/Geneva/GoodFridayTest.php b/tests/Switzerland/Geneva/GoodFridayTest.php index ee1a30a91..6463a4d51 100644 --- a/tests/Switzerland/Geneva/GoodFridayTest.php +++ b/tests/Switzerland/Geneva/GoodFridayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -35,7 +34,6 @@ class GoodFridayTest extends GenevaBaseTestCase implements HolidayTestCase * Tests the holiday defined in this test. * * @throws Exception - * @throws ReflectionException */ public function testHoliday(): void { @@ -51,7 +49,7 @@ public function testHoliday(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -66,7 +64,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Geneva/JeuneGenevoisTest.php b/tests/Switzerland/Geneva/JeuneGenevoisTest.php index 235db191d..0ba45a649 100644 --- a/tests/Switzerland/Geneva/JeuneGenevoisTest.php +++ b/tests/Switzerland/Geneva/JeuneGenevoisTest.php @@ -18,7 +18,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\Provider\Switzerland\Geneva; use Yasumi\tests\HolidayTestCase; @@ -36,7 +35,6 @@ class JeuneGenevoisTest extends GenevaBaseTestCase implements HolidayTestCase /** * Tests Jeune Genevois between 1870 and 1965. * - * @throws ReflectionException * @throws Exception */ public function testJeuneGenevoisBetween1870And1965(): void @@ -54,7 +52,6 @@ public function testJeuneGenevoisBetween1870And1965(): void /** * Tests Jeune Genevois between 1840 and 1869. * - * @throws ReflectionException * @throws Exception */ public function testJeuneGenevoisBetween1840And1869(): void @@ -72,7 +69,7 @@ public function testJeuneGenevoisBetween1840And1869(): void /** * Tests Jeune Genevois before 1840. * - * @throws ReflectionException + * @throws Exception */ public function testJeuneGenevoisBefore1840(): void { @@ -83,7 +80,7 @@ public function testJeuneGenevoisBefore1840(): void /** * Tests translated name of Jeune Genevois. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -98,7 +95,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Geneva/NewYearsDayTest.php b/tests/Switzerland/Geneva/NewYearsDayTest.php index d3ea0a9d8..3dbca00d9 100644 --- a/tests/Switzerland/Geneva/NewYearsDayTest.php +++ b/tests/Switzerland/Geneva/NewYearsDayTest.php @@ -16,7 +16,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -37,8 +36,6 @@ class NewYearsDayTest extends GenevaBaseTestCase implements HolidayTestCase * * @param int $year the year for which New Years Day needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testNewYearsDay(int $year, DateTime $expected): void { @@ -48,7 +45,7 @@ public function testNewYearsDay(int $year, DateTime $expected): void /** * Tests translated name of New Years Day. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -63,7 +60,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Geneva/PentecostMondayTest.php b/tests/Switzerland/Geneva/PentecostMondayTest.php index 30220280b..6a547dcbd 100644 --- a/tests/Switzerland/Geneva/PentecostMondayTest.php +++ b/tests/Switzerland/Geneva/PentecostMondayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -35,7 +34,6 @@ class PentecostMondayTest extends GenevaBaseTestCase implements HolidayTestCase * Tests Pentecost Monday. * * @throws Exception - * @throws ReflectionException */ public function testPentecostMonday(): void { @@ -51,7 +49,7 @@ public function testPentecostMonday(): void /** * Tests translated name of Pentecost Monday. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -66,7 +64,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Geneva/RestaurationGenevoiseTest.php b/tests/Switzerland/Geneva/RestaurationGenevoiseTest.php index 8a8dd64d5..94a7c9950 100644 --- a/tests/Switzerland/Geneva/RestaurationGenevoiseTest.php +++ b/tests/Switzerland/Geneva/RestaurationGenevoiseTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -35,7 +34,6 @@ class RestaurationGenevoiseTest extends GenevaBaseTestCase implements HolidayTes * Tests Restauration Genevoise. * * @throws Exception - * @throws ReflectionException */ public function testRestaurationGenevoiseAfter1813(): void { @@ -52,7 +50,7 @@ public function testRestaurationGenevoiseAfter1813(): void /** * Tests translated name of Restauration Genevoise. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -67,7 +65,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Glarus/AllSaintsDayTest.php b/tests/Switzerland/Glarus/AllSaintsDayTest.php index 1aa755a79..44366b1f0 100644 --- a/tests/Switzerland/Glarus/AllSaintsDayTest.php +++ b/tests/Switzerland/Glarus/AllSaintsDayTest.php @@ -16,7 +16,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -37,8 +36,6 @@ class AllSaintsDayTest extends GlarusBaseTestCase implements HolidayTestCase * * @param int $year the year for which All Saints' Day needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testAllSaintsDay(int $year, DateTime $expected): void { @@ -48,7 +45,7 @@ public function testAllSaintsDay(int $year, DateTime $expected): void /** * Tests translated name of All Saints' Day. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -63,7 +60,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Glarus/AscensionDayTest.php b/tests/Switzerland/Glarus/AscensionDayTest.php index e9de23fd1..cb679fe65 100644 --- a/tests/Switzerland/Glarus/AscensionDayTest.php +++ b/tests/Switzerland/Glarus/AscensionDayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -35,7 +34,6 @@ class AscensionDayTest extends GlarusBaseTestCase implements HolidayTestCase * Tests Ascension Day. * * @throws Exception - * @throws ReflectionException */ public function testAscensionDay(): void { @@ -51,7 +49,7 @@ public function testAscensionDay(): void /** * Tests translated name of Ascension Day. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -66,7 +64,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Glarus/BerchtoldsTagTest.php b/tests/Switzerland/Glarus/BerchtoldsTagTest.php index a744f5e9b..65f547647 100644 --- a/tests/Switzerland/Glarus/BerchtoldsTagTest.php +++ b/tests/Switzerland/Glarus/BerchtoldsTagTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,7 +33,6 @@ class BerchtoldsTagTest extends GlarusBaseTestCase implements HolidayTestCase /** * Tests BerchtoldsTag. * - * @throws ReflectionException * @throws Exception */ public function testBerchtoldsTag(): void @@ -49,7 +47,7 @@ public function testBerchtoldsTag(): void /** * Tests translated name of BerchtoldsTag. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -64,7 +62,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Glarus/ChristmasDayTest.php b/tests/Switzerland/Glarus/ChristmasDayTest.php index e5a7fd966..5a50ca300 100644 --- a/tests/Switzerland/Glarus/ChristmasDayTest.php +++ b/tests/Switzerland/Glarus/ChristmasDayTest.php @@ -16,7 +16,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -37,8 +36,6 @@ class ChristmasDayTest extends GlarusBaseTestCase implements HolidayTestCase * * @param int $year the year for which Christmas Day needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testChristmasDay(int $year, DateTime $expected): void { @@ -60,7 +57,7 @@ public function ChristmasDayDataProvider(): array /** * Tests translated name of Christmas Day. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -75,7 +72,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Glarus/EasterMondayTest.php b/tests/Switzerland/Glarus/EasterMondayTest.php index fbf2d73aa..01695bcad 100644 --- a/tests/Switzerland/Glarus/EasterMondayTest.php +++ b/tests/Switzerland/Glarus/EasterMondayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -35,7 +34,6 @@ class EasterMondayTest extends GlarusBaseTestCase implements HolidayTestCase * Tests Easter Monday. * * @throws Exception - * @throws ReflectionException */ public function testEasterMonday(): void { @@ -51,7 +49,7 @@ public function testEasterMonday(): void /** * Tests translated name of Easter Monday. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -66,7 +64,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Glarus/GlarusTest.php b/tests/Switzerland/Glarus/GlarusTest.php index 39fa4994a..f545a7b83 100644 --- a/tests/Switzerland/Glarus/GlarusTest.php +++ b/tests/Switzerland/Glarus/GlarusTest.php @@ -26,10 +26,12 @@ class GlarusTest extends GlarusBaseTestCase implements ProviderTestCase /** * @var int year random year number used for all tests in this Test Case */ - protected $year; + protected int $year; /** * Initial setup of this Test Case. + * + * @throws \Exception */ protected function setUp(): void { @@ -38,8 +40,6 @@ protected function setUp(): void /** * Tests if all official holidays in Glarus (Switzerland) are defined by the provider class. - * - * @throws ReflectionException */ public function testOfficialHolidays(): void { @@ -52,8 +52,6 @@ public function testOfficialHolidays(): void /** * Tests if all regional holidays in Glarus (Switzerland) are defined by the provider class. - * - * @throws ReflectionException */ public function testRegionalHolidays(): void { @@ -73,8 +71,6 @@ public function testRegionalHolidays(): void /** * Tests if all observed holidays in Glarus (Switzerland) are defined by the provider class. - * - * @throws ReflectionException */ public function testObservedHolidays(): void { @@ -88,8 +84,6 @@ public function testObservedHolidays(): void /** * Tests if all seasonal holidays in Glarus (Switzerland) are defined by the provider class. - * - * @throws ReflectionException */ public function testSeasonalHolidays(): void { @@ -98,8 +92,6 @@ public function testSeasonalHolidays(): void /** * Tests if all bank holidays in Glarus (Switzerland) are defined by the provider class. - * - * @throws ReflectionException */ public function testBankHolidays(): void { @@ -108,8 +100,6 @@ public function testBankHolidays(): void /** * Tests if all other holidays in Glarus (Switzerland) are defined by the provider class. - * - * @throws ReflectionException */ public function testOtherHolidays(): void { @@ -118,6 +108,7 @@ public function testOtherHolidays(): void /** * @throws ReflectionException + * @throws \Exception */ public function testSources(): void { diff --git a/tests/Switzerland/Glarus/GoodFridayTest.php b/tests/Switzerland/Glarus/GoodFridayTest.php index ce0b420cf..46f25f2be 100644 --- a/tests/Switzerland/Glarus/GoodFridayTest.php +++ b/tests/Switzerland/Glarus/GoodFridayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -35,7 +34,6 @@ class GoodFridayTest extends GlarusBaseTestCase implements HolidayTestCase * Tests the holiday defined in this test. * * @throws Exception - * @throws ReflectionException */ public function testHoliday(): void { @@ -51,7 +49,7 @@ public function testHoliday(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -66,7 +64,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Glarus/NafelserFahrtTest.php b/tests/Switzerland/Glarus/NafelserFahrtTest.php index 26aa978a2..27ce99a41 100644 --- a/tests/Switzerland/Glarus/NafelserFahrtTest.php +++ b/tests/Switzerland/Glarus/NafelserFahrtTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -39,7 +38,6 @@ class NafelserFahrtTest extends GlarusBaseTestCase implements HolidayTestCase /** * Tests Näfelser Fahrt on or after 1389. * - * @throws ReflectionException * @throws Exception */ public function testNafelserFahrtOnAfter1389(): void @@ -53,7 +51,7 @@ public function testNafelserFahrtOnAfter1389(): void /** * Tests Näfelser Fahrt before 1389. * - * @throws ReflectionException + * @throws Exception */ public function testNafelserFahrtBefore1389(): void { @@ -64,7 +62,7 @@ public function testNafelserFahrtBefore1389(): void /** * Tests translated name of Näfelser Fahrt. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -79,7 +77,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Glarus/NewYearsDayTest.php b/tests/Switzerland/Glarus/NewYearsDayTest.php index a1f01d1a1..de3a2bcae 100644 --- a/tests/Switzerland/Glarus/NewYearsDayTest.php +++ b/tests/Switzerland/Glarus/NewYearsDayTest.php @@ -16,7 +16,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -37,8 +36,6 @@ class NewYearsDayTest extends GlarusBaseTestCase implements HolidayTestCase * * @param int $year the year for which New Years Day needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testNewYearsDay(int $year, DateTime $expected): void { @@ -48,7 +45,7 @@ public function testNewYearsDay(int $year, DateTime $expected): void /** * Tests translated name of New Years Day. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -63,7 +60,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Glarus/PentecostMondayTest.php b/tests/Switzerland/Glarus/PentecostMondayTest.php index 35f54fcd1..65cedcd95 100644 --- a/tests/Switzerland/Glarus/PentecostMondayTest.php +++ b/tests/Switzerland/Glarus/PentecostMondayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -35,7 +34,6 @@ class PentecostMondayTest extends GlarusBaseTestCase implements HolidayTestCase * Tests Pentecost Monday. * * @throws Exception - * @throws ReflectionException */ public function testPentecostMonday(): void { @@ -51,7 +49,7 @@ public function testPentecostMonday(): void /** * Tests translated name of Pentecost Monday. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -66,7 +64,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Glarus/StStephensDayTest.php b/tests/Switzerland/Glarus/StStephensDayTest.php index 80e5283c6..4a3d77caa 100644 --- a/tests/Switzerland/Glarus/StStephensDayTest.php +++ b/tests/Switzerland/Glarus/StStephensDayTest.php @@ -16,7 +16,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -37,8 +36,6 @@ class StStephensDayTest extends GlarusBaseTestCase implements HolidayTestCase * * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testHoliday(int $year, DateTime $expected): void { @@ -60,7 +57,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -75,7 +72,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Grisons/AscensionDayTest.php b/tests/Switzerland/Grisons/AscensionDayTest.php index 54ef008f1..ef6d8e7c2 100644 --- a/tests/Switzerland/Grisons/AscensionDayTest.php +++ b/tests/Switzerland/Grisons/AscensionDayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -35,7 +34,6 @@ class AscensionDayTest extends GrisonsBaseTestCase implements HolidayTestCase * Tests Ascension Day. * * @throws Exception - * @throws ReflectionException */ public function testAscensionDay(): void { @@ -51,7 +49,7 @@ public function testAscensionDay(): void /** * Tests translated name of Ascension Day. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -66,7 +64,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Grisons/ChristmasDayTest.php b/tests/Switzerland/Grisons/ChristmasDayTest.php index a42b1d742..a929b45b2 100644 --- a/tests/Switzerland/Grisons/ChristmasDayTest.php +++ b/tests/Switzerland/Grisons/ChristmasDayTest.php @@ -16,7 +16,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -37,8 +36,6 @@ class ChristmasDayTest extends GrisonsBaseTestCase implements HolidayTestCase * * @param int $year the year for which Christmas Day needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testChristmasDay(int $year, DateTime $expected): void { @@ -60,7 +57,7 @@ public function ChristmasDayDataProvider(): array /** * Tests translated name of Christmas Day. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -75,7 +72,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Grisons/EasterMondayTest.php b/tests/Switzerland/Grisons/EasterMondayTest.php index 2e4d2eb96..457fcded1 100644 --- a/tests/Switzerland/Grisons/EasterMondayTest.php +++ b/tests/Switzerland/Grisons/EasterMondayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -35,7 +34,6 @@ class EasterMondayTest extends GrisonsBaseTestCase implements HolidayTestCase * Tests Easter Monday. * * @throws Exception - * @throws ReflectionException */ public function testEasterMonday(): void { @@ -51,7 +49,7 @@ public function testEasterMonday(): void /** * Tests translated name of Easter Monday. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -66,7 +64,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Grisons/GoodFridayTest.php b/tests/Switzerland/Grisons/GoodFridayTest.php index eaebbf307..f4e46e512 100644 --- a/tests/Switzerland/Grisons/GoodFridayTest.php +++ b/tests/Switzerland/Grisons/GoodFridayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -35,7 +34,6 @@ class GoodFridayTest extends GrisonsBaseTestCase implements HolidayTestCase * Tests the holiday defined in this test. * * @throws Exception - * @throws ReflectionException */ public function testHoliday(): void { @@ -51,7 +49,7 @@ public function testHoliday(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -66,7 +64,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Grisons/GrisonsTest.php b/tests/Switzerland/Grisons/GrisonsTest.php index 1cdbe9360..f9098036f 100644 --- a/tests/Switzerland/Grisons/GrisonsTest.php +++ b/tests/Switzerland/Grisons/GrisonsTest.php @@ -26,10 +26,12 @@ class GrisonsTest extends GrisonsBaseTestCase implements ProviderTestCase /** * @var int year random year number used for all tests in this Test Case */ - protected $year; + protected int $year; /** * Initial setup of this Test Case. + * + * @throws \Exception */ protected function setUp(): void { @@ -38,8 +40,6 @@ protected function setUp(): void /** * Tests if all official holidays in Grisons (Switzerland) are defined by the provider class. - * - * @throws ReflectionException */ public function testOfficialHolidays(): void { @@ -52,8 +52,6 @@ public function testOfficialHolidays(): void /** * Tests if all regional holidays in Grisons (Switzerland) are defined by the provider class. - * - * @throws ReflectionException */ public function testRegionalHolidays(): void { @@ -70,8 +68,6 @@ public function testRegionalHolidays(): void /** * Tests if all observed holidays in Grisons (Switzerland) are defined by the provider class. - * - * @throws ReflectionException */ public function testObservedHolidays(): void { @@ -85,8 +81,6 @@ public function testObservedHolidays(): void /** * Tests if all seasonal holidays in Grisons (Switzerland) are defined by the provider class. - * - * @throws ReflectionException */ public function testSeasonalHolidays(): void { @@ -95,8 +89,6 @@ public function testSeasonalHolidays(): void /** * Tests if all bank holidays in Grisons (Switzerland) are defined by the provider class. - * - * @throws ReflectionException */ public function testBankHolidays(): void { @@ -105,8 +97,6 @@ public function testBankHolidays(): void /** * Tests if all other holidays in Grisons (Switzerland) are defined by the provider class. - * - * @throws ReflectionException */ public function testOtherHolidays(): void { @@ -115,6 +105,7 @@ public function testOtherHolidays(): void /** * @throws ReflectionException + * @throws \Exception */ public function testSources(): void { diff --git a/tests/Switzerland/Grisons/NewYearsDayTest.php b/tests/Switzerland/Grisons/NewYearsDayTest.php index cf596ac82..3019b3eca 100644 --- a/tests/Switzerland/Grisons/NewYearsDayTest.php +++ b/tests/Switzerland/Grisons/NewYearsDayTest.php @@ -16,7 +16,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -37,8 +36,6 @@ class NewYearsDayTest extends GrisonsBaseTestCase implements HolidayTestCase * * @param int $year the year for which New Years Day needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testNewYearsDay(int $year, DateTime $expected): void { @@ -48,7 +45,7 @@ public function testNewYearsDay(int $year, DateTime $expected): void /** * Tests translated name of New Years Day. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -63,7 +60,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Grisons/PentecostMondayTest.php b/tests/Switzerland/Grisons/PentecostMondayTest.php index 9f3b97518..61e3a33b2 100644 --- a/tests/Switzerland/Grisons/PentecostMondayTest.php +++ b/tests/Switzerland/Grisons/PentecostMondayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -35,7 +34,6 @@ class PentecostMondayTest extends GrisonsBaseTestCase implements HolidayTestCase * Tests Pentecost Monday. * * @throws Exception - * @throws ReflectionException */ public function testPentecostMonday(): void { @@ -51,7 +49,7 @@ public function testPentecostMonday(): void /** * Tests translated name of Pentecost Monday. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -66,7 +64,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Grisons/StStephensDayTest.php b/tests/Switzerland/Grisons/StStephensDayTest.php index ddb5cf96a..d9fde825f 100644 --- a/tests/Switzerland/Grisons/StStephensDayTest.php +++ b/tests/Switzerland/Grisons/StStephensDayTest.php @@ -16,7 +16,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -37,8 +36,6 @@ class StStephensDayTest extends GrisonsBaseTestCase implements HolidayTestCase * * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testHoliday(int $year, DateTime $expected): void { @@ -60,7 +57,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -75,7 +72,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Jura/AllSaintsDayTest.php b/tests/Switzerland/Jura/AllSaintsDayTest.php index 2452b2bef..68a19acae 100644 --- a/tests/Switzerland/Jura/AllSaintsDayTest.php +++ b/tests/Switzerland/Jura/AllSaintsDayTest.php @@ -16,7 +16,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -37,8 +36,6 @@ class AllSaintsDayTest extends JuraBaseTestCase implements HolidayTestCase * * @param int $year the year for which All Saints' Day needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testAllSaintsDay(int $year, DateTime $expected): void { @@ -48,7 +45,7 @@ public function testAllSaintsDay(int $year, DateTime $expected): void /** * Tests translated name of All Saints' Day. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -63,7 +60,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Jura/AscensionDayTest.php b/tests/Switzerland/Jura/AscensionDayTest.php index 498acc1d6..dc6a7e892 100644 --- a/tests/Switzerland/Jura/AscensionDayTest.php +++ b/tests/Switzerland/Jura/AscensionDayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -35,7 +34,6 @@ class AscensionDayTest extends JuraBaseTestCase implements HolidayTestCase * Tests Ascension Day. * * @throws Exception - * @throws ReflectionException */ public function testAscensionDay(): void { @@ -51,7 +49,7 @@ public function testAscensionDay(): void /** * Tests translated name of Ascension Day. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -66,7 +64,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Jura/AssumptionOfMaryTest.php b/tests/Switzerland/Jura/AssumptionOfMaryTest.php index 97ae5e632..f5edcb659 100644 --- a/tests/Switzerland/Jura/AssumptionOfMaryTest.php +++ b/tests/Switzerland/Jura/AssumptionOfMaryTest.php @@ -16,7 +16,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -37,8 +36,6 @@ class AssumptionOfMaryTest extends JuraBaseTestCase implements HolidayTestCase * * @param int $year the year for which the day of the Assumption of Mary needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testAssumptionOfMary(int $year, DateTime $expected): void { @@ -48,7 +45,7 @@ public function testAssumptionOfMary(int $year, DateTime $expected): void /** * Tests translated name of the day of the Assumption of Mary. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -63,7 +60,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Jura/BerchtoldsTagTest.php b/tests/Switzerland/Jura/BerchtoldsTagTest.php index 82e8d1d2d..2d3c7c6a7 100644 --- a/tests/Switzerland/Jura/BerchtoldsTagTest.php +++ b/tests/Switzerland/Jura/BerchtoldsTagTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,7 +33,6 @@ class BerchtoldsTagTest extends JuraBaseTestCase implements HolidayTestCase /** * Tests BerchtoldsTag. * - * @throws ReflectionException * @throws Exception */ public function testBerchtoldsTag(): void @@ -49,7 +47,7 @@ public function testBerchtoldsTag(): void /** * Tests translated name of BerchtoldsTag. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -64,7 +62,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Jura/BettagsMontagTest.php b/tests/Switzerland/Jura/BettagsMontagTest.php index 65422e706..b5d47655a 100644 --- a/tests/Switzerland/Jura/BettagsMontagTest.php +++ b/tests/Switzerland/Jura/BettagsMontagTest.php @@ -18,7 +18,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -35,7 +34,6 @@ class BettagsMontagTest extends JuraBaseTestCase implements HolidayTestCase /** * Tests Bettags Montag on or after 1832. * - * @throws ReflectionException * @throws Exception */ public function testBettagsMontagOnAfter1832(): void @@ -53,7 +51,7 @@ public function testBettagsMontagOnAfter1832(): void /** * Tests Bettags Montag before 1832. * - * @throws ReflectionException + * @throws Exception */ public function testBettagsMontagBefore1832(): void { @@ -64,7 +62,7 @@ public function testBettagsMontagBefore1832(): void /** * Tests translated name of Bettags Montag. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -79,7 +77,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Jura/ChristmasDayTest.php b/tests/Switzerland/Jura/ChristmasDayTest.php index a8918601a..4e98c93f9 100644 --- a/tests/Switzerland/Jura/ChristmasDayTest.php +++ b/tests/Switzerland/Jura/ChristmasDayTest.php @@ -16,7 +16,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -37,8 +36,6 @@ class ChristmasDayTest extends JuraBaseTestCase implements HolidayTestCase * * @param int $year the year for which Christmas Day needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testChristmasDay(int $year, DateTime $expected): void { @@ -60,7 +57,7 @@ public function ChristmasDayDataProvider(): array /** * Tests translated name of Christmas Day. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -75,7 +72,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Jura/CorpusChristiTest.php b/tests/Switzerland/Jura/CorpusChristiTest.php index c873bd806..2275752de 100644 --- a/tests/Switzerland/Jura/CorpusChristiTest.php +++ b/tests/Switzerland/Jura/CorpusChristiTest.php @@ -16,7 +16,6 @@ use DateInterval; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\Provider\ChristianHolidays; use Yasumi\tests\HolidayTestCase; @@ -37,7 +36,6 @@ class CorpusChristiTest extends JuraBaseTestCase implements HolidayTestCase * Tests Corpus Christi. * * @throws Exception - * @throws ReflectionException */ public function testCorpusChristi(): void { @@ -53,7 +51,7 @@ public function testCorpusChristi(): void /** * Tests translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -68,7 +66,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Jura/EasterMondayTest.php b/tests/Switzerland/Jura/EasterMondayTest.php index 5337477e2..6e227c418 100644 --- a/tests/Switzerland/Jura/EasterMondayTest.php +++ b/tests/Switzerland/Jura/EasterMondayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -35,7 +34,6 @@ class EasterMondayTest extends JuraBaseTestCase implements HolidayTestCase * Tests Easter Monday. * * @throws Exception - * @throws ReflectionException */ public function testEasterMonday(): void { @@ -51,7 +49,7 @@ public function testEasterMonday(): void /** * Tests translated name of Easter Monday. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -66,7 +64,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Jura/EasterTest.php b/tests/Switzerland/Jura/EasterTest.php index d0461b975..99b5eef91 100644 --- a/tests/Switzerland/Jura/EasterTest.php +++ b/tests/Switzerland/Jura/EasterTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -35,7 +34,6 @@ class EasterTest extends JuraBaseTestCase implements HolidayTestCase * Tests the holiday defined in this test. * * @throws Exception - * @throws ReflectionException */ public function testHoliday(): void { @@ -51,7 +49,7 @@ public function testHoliday(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -66,7 +64,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Jura/GoodFridayTest.php b/tests/Switzerland/Jura/GoodFridayTest.php index cc18f8703..007849631 100644 --- a/tests/Switzerland/Jura/GoodFridayTest.php +++ b/tests/Switzerland/Jura/GoodFridayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -35,7 +34,6 @@ class GoodFridayTest extends JuraBaseTestCase implements HolidayTestCase * Tests the holiday defined in this test. * * @throws Exception - * @throws ReflectionException */ public function testHoliday(): void { @@ -51,7 +49,7 @@ public function testHoliday(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -66,7 +64,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Jura/JuraTest.php b/tests/Switzerland/Jura/JuraTest.php index 4ef2af3c2..92c329d10 100644 --- a/tests/Switzerland/Jura/JuraTest.php +++ b/tests/Switzerland/Jura/JuraTest.php @@ -26,10 +26,12 @@ class JuraTest extends JuraBaseTestCase implements ProviderTestCase /** * @var int year random year number used for all tests in this Test Case */ - protected $year; + protected int $year; /** * Initial setup of this Test Case. + * + * @throws \Exception */ protected function setUp(): void { @@ -38,8 +40,6 @@ protected function setUp(): void /** * Tests if all official holidays in Jura (Switzerland) are defined by the provider class. - * - * @throws ReflectionException */ public function testOfficialHolidays(): void { @@ -52,8 +52,6 @@ public function testOfficialHolidays(): void /** * Tests if all regional holidays in Jura (Switzerland) are defined by the provider class. - * - * @throws ReflectionException */ public function testRegionalHolidays(): void { @@ -78,8 +76,6 @@ public function testRegionalHolidays(): void /** * Tests if all observed holidays in Jura (Switzerland) are defined by the provider class. - * - * @throws ReflectionException */ public function testObservedHolidays(): void { @@ -93,8 +89,6 @@ public function testObservedHolidays(): void /** * Tests if all seasonal holidays in Jura (Switzerland) are defined by the provider class. - * - * @throws ReflectionException */ public function testSeasonalHolidays(): void { @@ -103,8 +97,6 @@ public function testSeasonalHolidays(): void /** * Tests if all bank holidays in Jura (Switzerland) are defined by the provider class. - * - * @throws ReflectionException */ public function testBankHolidays(): void { @@ -113,8 +105,6 @@ public function testBankHolidays(): void /** * Tests if all other holidays in Jura (Switzerland) are defined by the provider class. - * - * @throws ReflectionException */ public function testOtherHolidays(): void { @@ -123,6 +113,7 @@ public function testOtherHolidays(): void /** * @throws ReflectionException + * @throws \Exception */ public function testSources(): void { diff --git a/tests/Switzerland/Jura/NewYearsDayTest.php b/tests/Switzerland/Jura/NewYearsDayTest.php index 01928d6bd..3f55f1f12 100644 --- a/tests/Switzerland/Jura/NewYearsDayTest.php +++ b/tests/Switzerland/Jura/NewYearsDayTest.php @@ -16,7 +16,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -37,8 +36,6 @@ class NewYearsDayTest extends JuraBaseTestCase implements HolidayTestCase * * @param int $year the year for which New Years Day needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testNewYearsDay(int $year, DateTime $expected): void { @@ -48,7 +45,7 @@ public function testNewYearsDay(int $year, DateTime $expected): void /** * Tests translated name of New Years Day. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -63,7 +60,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Jura/PentecostMondayTest.php b/tests/Switzerland/Jura/PentecostMondayTest.php index 34ec5edea..790dcf51b 100644 --- a/tests/Switzerland/Jura/PentecostMondayTest.php +++ b/tests/Switzerland/Jura/PentecostMondayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -35,7 +34,6 @@ class PentecostMondayTest extends JuraBaseTestCase implements HolidayTestCase * Tests Pentecost Monday. * * @throws Exception - * @throws ReflectionException */ public function testPentecostMonday(): void { @@ -51,7 +49,7 @@ public function testPentecostMonday(): void /** * Tests translated name of Pentecost Monday. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -66,7 +64,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Jura/PentecostTest.php b/tests/Switzerland/Jura/PentecostTest.php index d15f3364e..82b49296d 100644 --- a/tests/Switzerland/Jura/PentecostTest.php +++ b/tests/Switzerland/Jura/PentecostTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -35,7 +34,6 @@ class PentecostTest extends JuraBaseTestCase implements HolidayTestCase * Tests the holiday defined in this test. * * @throws Exception - * @throws ReflectionException */ public function testHoliday(): void { @@ -51,7 +49,7 @@ public function testHoliday(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -66,7 +64,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Jura/PlebisciteJurassienTest.php b/tests/Switzerland/Jura/PlebisciteJurassienTest.php index 3a2855690..1da9b798b 100644 --- a/tests/Switzerland/Jura/PlebisciteJurassienTest.php +++ b/tests/Switzerland/Jura/PlebisciteJurassienTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -40,7 +39,6 @@ class PlebisciteJurassienTest extends JuraBaseTestCase implements HolidayTestCas * Tests Plébiscite jurassien on or after 1975. * * @throws Exception - * @throws ReflectionException */ public function testInstaurationRepubliqueOnAfter1975(): void { @@ -56,7 +54,7 @@ public function testInstaurationRepubliqueOnAfter1975(): void /** * Tests Plébiscite jurassien before 1975. * - * @throws ReflectionException + * @throws Exception */ public function testInstaurationRepubliqueBefore1975(): void { @@ -70,7 +68,7 @@ public function testInstaurationRepubliqueBefore1975(): void /** * Tests translated name of Plébiscite jurassien. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -85,7 +83,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Jura/WorkersDayTest.php b/tests/Switzerland/Jura/WorkersDayTest.php index 6a6d7ab8a..ac2991b8b 100644 --- a/tests/Switzerland/Jura/WorkersDayTest.php +++ b/tests/Switzerland/Jura/WorkersDayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -39,7 +38,6 @@ class WorkersDayTest extends JuraBaseTestCase implements HolidayTestCase * @param int $year the year for which the holiday defined in this test needs to be tested * @param string $expected the expected date * - * @throws ReflectionException * @throws Exception */ public function testHoliday(int $year, string $expected): void @@ -71,7 +69,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -86,7 +84,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Lucerne/AllSaintsDayTest.php b/tests/Switzerland/Lucerne/AllSaintsDayTest.php index 17ba5b196..f01b394c1 100644 --- a/tests/Switzerland/Lucerne/AllSaintsDayTest.php +++ b/tests/Switzerland/Lucerne/AllSaintsDayTest.php @@ -16,7 +16,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -37,8 +36,6 @@ class AllSaintsDayTest extends LucerneBaseTestCase implements HolidayTestCase * * @param int $year the year for which All Saints' Day needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testAllSaintsDay(int $year, DateTime $expected): void { @@ -48,7 +45,7 @@ public function testAllSaintsDay(int $year, DateTime $expected): void /** * Tests translated name of All Saints' Day. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -63,7 +60,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Lucerne/AscensionDayTest.php b/tests/Switzerland/Lucerne/AscensionDayTest.php index eb69158bc..6ab3eea6b 100644 --- a/tests/Switzerland/Lucerne/AscensionDayTest.php +++ b/tests/Switzerland/Lucerne/AscensionDayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -35,7 +34,6 @@ class AscensionDayTest extends LucerneBaseTestCase implements HolidayTestCase * Tests Ascension Day. * * @throws Exception - * @throws ReflectionException */ public function testAscensionDay(): void { @@ -51,7 +49,7 @@ public function testAscensionDay(): void /** * Tests translated name of Ascension Day. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -66,7 +64,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Lucerne/AssumptionOfMaryTest.php b/tests/Switzerland/Lucerne/AssumptionOfMaryTest.php index 2396238b7..8aca43508 100644 --- a/tests/Switzerland/Lucerne/AssumptionOfMaryTest.php +++ b/tests/Switzerland/Lucerne/AssumptionOfMaryTest.php @@ -16,7 +16,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -37,8 +36,6 @@ class AssumptionOfMaryTest extends LucerneBaseTestCase implements HolidayTestCas * * @param int $year the year for which the day of the Assumption of Mary needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testAssumptionOfMary(int $year, DateTime $expected): void { @@ -48,7 +45,7 @@ public function testAssumptionOfMary(int $year, DateTime $expected): void /** * Tests translated name of the day of the Assumption of Mary. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -63,7 +60,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Lucerne/BerchtoldsTagTest.php b/tests/Switzerland/Lucerne/BerchtoldsTagTest.php index b68e0168e..d92c078a5 100644 --- a/tests/Switzerland/Lucerne/BerchtoldsTagTest.php +++ b/tests/Switzerland/Lucerne/BerchtoldsTagTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,7 +33,6 @@ class BerchtoldsTagTest extends LucerneBaseTestCase implements HolidayTestCase /** * Tests BerchtoldsTag. * - * @throws ReflectionException * @throws Exception */ public function testBerchtoldsTag(): void @@ -49,7 +47,7 @@ public function testBerchtoldsTag(): void /** * Tests translated name of BerchtoldsTag. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -64,7 +62,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Lucerne/ChristmasDayTest.php b/tests/Switzerland/Lucerne/ChristmasDayTest.php index 50cb199c9..df4857e02 100644 --- a/tests/Switzerland/Lucerne/ChristmasDayTest.php +++ b/tests/Switzerland/Lucerne/ChristmasDayTest.php @@ -16,7 +16,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -37,8 +36,6 @@ class ChristmasDayTest extends LucerneBaseTestCase implements HolidayTestCase * * @param int $year the year for which Christmas Day needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testChristmasDay(int $year, DateTime $expected): void { @@ -60,7 +57,7 @@ public function ChristmasDayDataProvider(): array /** * Tests translated name of Christmas Day. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -75,7 +72,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Lucerne/CorpusChristiTest.php b/tests/Switzerland/Lucerne/CorpusChristiTest.php index ee68d13d6..9abf07f8c 100644 --- a/tests/Switzerland/Lucerne/CorpusChristiTest.php +++ b/tests/Switzerland/Lucerne/CorpusChristiTest.php @@ -16,7 +16,6 @@ use DateInterval; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\Provider\ChristianHolidays; use Yasumi\tests\HolidayTestCase; @@ -37,7 +36,6 @@ class CorpusChristiTest extends LucerneBaseTestCase implements HolidayTestCase * Tests Corpus Christi. * * @throws Exception - * @throws ReflectionException */ public function testCorpusChristi(): void { @@ -53,7 +51,7 @@ public function testCorpusChristi(): void /** * Tests translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -68,7 +66,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Lucerne/EasterMondayTest.php b/tests/Switzerland/Lucerne/EasterMondayTest.php index 6c0db1b8f..3eba31f36 100644 --- a/tests/Switzerland/Lucerne/EasterMondayTest.php +++ b/tests/Switzerland/Lucerne/EasterMondayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -35,7 +34,6 @@ class EasterMondayTest extends LucerneBaseTestCase implements HolidayTestCase * Tests Easter Monday. * * @throws Exception - * @throws ReflectionException */ public function testEasterMonday(): void { @@ -51,7 +49,7 @@ public function testEasterMonday(): void /** * Tests translated name of Easter Monday. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -66,7 +64,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Lucerne/GoodFridayTest.php b/tests/Switzerland/Lucerne/GoodFridayTest.php index 66dd75231..9b23bfda8 100644 --- a/tests/Switzerland/Lucerne/GoodFridayTest.php +++ b/tests/Switzerland/Lucerne/GoodFridayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -35,7 +34,6 @@ class GoodFridayTest extends LucerneBaseTestCase implements HolidayTestCase * Tests the holiday defined in this test. * * @throws Exception - * @throws ReflectionException */ public function testHoliday(): void { @@ -51,7 +49,7 @@ public function testHoliday(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -66,7 +64,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Lucerne/ImmaculateConceptionTest.php b/tests/Switzerland/Lucerne/ImmaculateConceptionTest.php index 9f6299c67..f8cde7ea2 100644 --- a/tests/Switzerland/Lucerne/ImmaculateConceptionTest.php +++ b/tests/Switzerland/Lucerne/ImmaculateConceptionTest.php @@ -16,7 +16,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -37,8 +36,6 @@ class ImmaculateConceptionTest extends LucerneBaseTestCase implements HolidayTes * * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testHoliday(int $year, DateTime $expected): void { @@ -60,7 +57,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -75,7 +72,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Lucerne/LucerneTest.php b/tests/Switzerland/Lucerne/LucerneTest.php index c75ea0e5d..f9b78d4cb 100644 --- a/tests/Switzerland/Lucerne/LucerneTest.php +++ b/tests/Switzerland/Lucerne/LucerneTest.php @@ -26,10 +26,12 @@ class LucerneTest extends LucerneBaseTestCase implements ProviderTestCase /** * @var int year random year number used for all tests in this Test Case */ - protected $year; + protected int $year; /** * Initial setup of this Test Case. + * + * @throws \Exception */ protected function setUp(): void { @@ -38,8 +40,6 @@ protected function setUp(): void /** * Tests if all official holidays in Lucerne (Switzerland) are defined by the provider class. - * - * @throws ReflectionException */ public function testOfficialHolidays(): void { @@ -52,8 +52,6 @@ public function testOfficialHolidays(): void /** * Tests if all regional holidays in Lucerne (Switzerland) are defined by the provider class. - * - * @throws ReflectionException */ public function testRegionalHolidays(): void { @@ -75,8 +73,6 @@ public function testRegionalHolidays(): void /** * Tests if all observed holidays in Lucerne (Switzerland) are defined by the provider class. - * - * @throws ReflectionException */ public function testObservedHolidays(): void { @@ -90,8 +86,6 @@ public function testObservedHolidays(): void /** * Tests if all seasonal holidays in Lucerne (Switzerland) are defined by the provider class. - * - * @throws ReflectionException */ public function testSeasonalHolidays(): void { @@ -100,8 +94,6 @@ public function testSeasonalHolidays(): void /** * Tests if all bank holidays in Lucerne (Switzerland) are defined by the provider class. - * - * @throws ReflectionException */ public function testBankHolidays(): void { @@ -110,8 +102,6 @@ public function testBankHolidays(): void /** * Tests if all other holidays in Lucerne (Switzerland) are defined by the provider class. - * - * @throws ReflectionException */ public function testOtherHolidays(): void { @@ -120,6 +110,7 @@ public function testOtherHolidays(): void /** * @throws ReflectionException + * @throws \Exception */ public function testSources(): void { diff --git a/tests/Switzerland/Lucerne/NewYearsDayTest.php b/tests/Switzerland/Lucerne/NewYearsDayTest.php index c0b1b305d..be40eac19 100644 --- a/tests/Switzerland/Lucerne/NewYearsDayTest.php +++ b/tests/Switzerland/Lucerne/NewYearsDayTest.php @@ -16,7 +16,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -37,8 +36,6 @@ class NewYearsDayTest extends LucerneBaseTestCase implements HolidayTestCase * * @param int $year the year for which New Years Day needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testNewYearsDay(int $year, DateTime $expected): void { @@ -48,7 +45,7 @@ public function testNewYearsDay(int $year, DateTime $expected): void /** * Tests translated name of New Years Day. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -63,7 +60,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Lucerne/PentecostMondayTest.php b/tests/Switzerland/Lucerne/PentecostMondayTest.php index 73aa38138..14d3c2d78 100644 --- a/tests/Switzerland/Lucerne/PentecostMondayTest.php +++ b/tests/Switzerland/Lucerne/PentecostMondayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -35,7 +34,6 @@ class PentecostMondayTest extends LucerneBaseTestCase implements HolidayTestCase * Tests Pentecost Monday. * * @throws Exception - * @throws ReflectionException */ public function testPentecostMonday(): void { @@ -51,7 +49,7 @@ public function testPentecostMonday(): void /** * Tests translated name of Pentecost Monday. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -66,7 +64,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Lucerne/StStephensDayTest.php b/tests/Switzerland/Lucerne/StStephensDayTest.php index cc42010da..25dc1a879 100644 --- a/tests/Switzerland/Lucerne/StStephensDayTest.php +++ b/tests/Switzerland/Lucerne/StStephensDayTest.php @@ -16,7 +16,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -37,8 +36,6 @@ class StStephensDayTest extends LucerneBaseTestCase implements HolidayTestCase * * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testHoliday(int $year, DateTime $expected): void { @@ -60,7 +57,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -75,7 +72,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Neuchatel/AscensionDayTest.php b/tests/Switzerland/Neuchatel/AscensionDayTest.php index 3c7a98a0f..08d5d9364 100644 --- a/tests/Switzerland/Neuchatel/AscensionDayTest.php +++ b/tests/Switzerland/Neuchatel/AscensionDayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -35,7 +34,6 @@ class AscensionDayTest extends NeuchatelBaseTestCase implements HolidayTestCase * Tests Ascension Day. * * @throws Exception - * @throws ReflectionException */ public function testAscensionDay(): void { @@ -51,7 +49,7 @@ public function testAscensionDay(): void /** * Tests translated name of Ascension Day. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -66,7 +64,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Neuchatel/BettagsMontagTest.php b/tests/Switzerland/Neuchatel/BettagsMontagTest.php index ee5e504af..d0ab6cc20 100644 --- a/tests/Switzerland/Neuchatel/BettagsMontagTest.php +++ b/tests/Switzerland/Neuchatel/BettagsMontagTest.php @@ -18,7 +18,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -35,7 +34,6 @@ class BettagsMontagTest extends NeuchatelBaseTestCase implements HolidayTestCase /** * Tests Bettags Montag on or after 1832. * - * @throws ReflectionException * @throws Exception */ public function testBettagsMontagOnAfter1832(): void @@ -53,7 +51,7 @@ public function testBettagsMontagOnAfter1832(): void /** * Tests Bettags Montag before 1832. * - * @throws ReflectionException + * @throws Exception */ public function testBettagsMontagBefore1832(): void { @@ -64,7 +62,7 @@ public function testBettagsMontagBefore1832(): void /** * Tests translated name of Bettags Montag. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -79,7 +77,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Neuchatel/ChristmasDayTest.php b/tests/Switzerland/Neuchatel/ChristmasDayTest.php index 556fd9367..758fe9a3e 100644 --- a/tests/Switzerland/Neuchatel/ChristmasDayTest.php +++ b/tests/Switzerland/Neuchatel/ChristmasDayTest.php @@ -16,7 +16,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -37,8 +36,6 @@ class ChristmasDayTest extends NeuchatelBaseTestCase implements HolidayTestCase * * @param int $year the year for which Christmas Day needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testChristmasDay(int $year, DateTime $expected): void { @@ -60,7 +57,7 @@ public function ChristmasDayDataProvider(): array /** * Tests translated name of Christmas Day. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -75,7 +72,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Neuchatel/December26thTest.php b/tests/Switzerland/Neuchatel/December26thTest.php index a05031dc0..6fe797816 100644 --- a/tests/Switzerland/Neuchatel/December26thTest.php +++ b/tests/Switzerland/Neuchatel/December26thTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -40,7 +39,6 @@ class December26thTest extends NeuchatelBaseTestCase implements HolidayTestCase * Tests December 26th. * * @throws Exception - * @throws ReflectionException */ public function testDecember26th(): void { @@ -74,8 +72,6 @@ public function testDecember26th(): void /** * Tests translated name of December 26th. - * - * @throws ReflectionException */ public function testTranslation(): void { @@ -89,8 +85,6 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. - * - * @throws ReflectionException */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Neuchatel/EasterMondayTest.php b/tests/Switzerland/Neuchatel/EasterMondayTest.php index 35325a2c9..8ad62dffc 100644 --- a/tests/Switzerland/Neuchatel/EasterMondayTest.php +++ b/tests/Switzerland/Neuchatel/EasterMondayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -35,7 +34,6 @@ class EasterMondayTest extends NeuchatelBaseTestCase implements HolidayTestCase * Tests Easter Monday. * * @throws Exception - * @throws ReflectionException */ public function testEasterMonday(): void { @@ -51,7 +49,7 @@ public function testEasterMonday(): void /** * Tests translated name of Easter Monday. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -66,7 +64,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Neuchatel/GoodFridayTest.php b/tests/Switzerland/Neuchatel/GoodFridayTest.php index 39c5c56d9..80d39fad8 100644 --- a/tests/Switzerland/Neuchatel/GoodFridayTest.php +++ b/tests/Switzerland/Neuchatel/GoodFridayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -35,7 +34,6 @@ class GoodFridayTest extends NeuchatelBaseTestCase implements HolidayTestCase * Tests the holiday defined in this test. * * @throws Exception - * @throws ReflectionException */ public function testHoliday(): void { @@ -51,7 +49,7 @@ public function testHoliday(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -66,7 +64,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Neuchatel/InstaurationRepubliqueTest.php b/tests/Switzerland/Neuchatel/InstaurationRepubliqueTest.php index 5f21ede43..95e94fd3b 100644 --- a/tests/Switzerland/Neuchatel/InstaurationRepubliqueTest.php +++ b/tests/Switzerland/Neuchatel/InstaurationRepubliqueTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -40,7 +39,6 @@ class InstaurationRepubliqueTest extends NeuchatelBaseTestCase implements Holida * Tests Instauration de la République on or after 1849. * * @throws Exception - * @throws ReflectionException */ public function testInstaurationRepubliqueOnAfter1849(): void { @@ -56,7 +54,7 @@ public function testInstaurationRepubliqueOnAfter1849(): void /** * Tests Instauration de la République before 1849. * - * @throws ReflectionException + * @throws Exception */ public function testInstaurationRepubliqueBefore1849(): void { @@ -70,7 +68,7 @@ public function testInstaurationRepubliqueBefore1849(): void /** * Tests translated name of Instauration de la République. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -85,7 +83,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Neuchatel/January2ndTest.php b/tests/Switzerland/Neuchatel/January2ndTest.php index 34ebbc503..2c5ce1253 100644 --- a/tests/Switzerland/Neuchatel/January2ndTest.php +++ b/tests/Switzerland/Neuchatel/January2ndTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -40,7 +39,6 @@ class January2ndTest extends NeuchatelBaseTestCase implements HolidayTestCase * Tests January 2nd. * * @throws Exception - * @throws ReflectionException */ public function testJanuary2nd(): void { @@ -74,8 +72,6 @@ public function testJanuary2nd(): void /** * Tests translated name of January 2nd. - * - * @throws ReflectionException */ public function testTranslation(): void { @@ -89,8 +85,6 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. - * - * @throws ReflectionException */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Neuchatel/NeuchatelTest.php b/tests/Switzerland/Neuchatel/NeuchatelTest.php index 23ec6e30a..b01b82c46 100644 --- a/tests/Switzerland/Neuchatel/NeuchatelTest.php +++ b/tests/Switzerland/Neuchatel/NeuchatelTest.php @@ -26,10 +26,12 @@ class NeuchatelTest extends NeuchatelBaseTestCase implements ProviderTestCase /** * @var int year random year number used for all tests in this Test Case */ - protected $year; + protected int $year; /** * Initial setup of this Test Case. + * + * @throws \Exception */ protected function setUp(): void { @@ -38,8 +40,6 @@ protected function setUp(): void /** * Tests if all official holidays in Neuchatel (Switzerland) are defined by the provider class. - * - * @throws ReflectionException */ public function testOfficialHolidays(): void { @@ -52,8 +52,6 @@ public function testOfficialHolidays(): void /** * Tests if all regional holidays in Neuchatel (Switzerland) are defined by the provider class. - * - * @throws ReflectionException */ public function testRegionalHolidays(): void { @@ -72,8 +70,6 @@ public function testRegionalHolidays(): void /** * Tests if all observed holidays in Neuchatel (Switzerland) are defined by the provider class. - * - * @throws ReflectionException */ public function testObservedHolidays(): void { @@ -87,8 +83,6 @@ public function testObservedHolidays(): void /** * Tests if all seasonal holidays in Neuchatel (Switzerland) are defined by the provider class. - * - * @throws ReflectionException */ public function testSeasonalHolidays(): void { @@ -97,8 +91,6 @@ public function testSeasonalHolidays(): void /** * Tests if all bank holidays in Neuchatel (Switzerland) are defined by the provider class. - * - * @throws ReflectionException */ public function testBankHolidays(): void { @@ -107,8 +99,6 @@ public function testBankHolidays(): void /** * Tests if all other holidays in Neuchatel (Switzerland) are defined by the provider class. - * - * @throws ReflectionException */ public function testOtherHolidays(): void { @@ -117,6 +107,7 @@ public function testOtherHolidays(): void /** * @throws ReflectionException + * @throws \Exception */ public function testSources(): void { diff --git a/tests/Switzerland/Neuchatel/NewYearsDayTest.php b/tests/Switzerland/Neuchatel/NewYearsDayTest.php index 67dd2a8ef..c67696996 100644 --- a/tests/Switzerland/Neuchatel/NewYearsDayTest.php +++ b/tests/Switzerland/Neuchatel/NewYearsDayTest.php @@ -16,7 +16,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -37,8 +36,6 @@ class NewYearsDayTest extends NeuchatelBaseTestCase implements HolidayTestCase * * @param int $year the year for which New Years Day needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testNewYearsDay(int $year, DateTime $expected): void { @@ -48,7 +45,7 @@ public function testNewYearsDay(int $year, DateTime $expected): void /** * Tests translated name of New Years Day. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -63,7 +60,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Neuchatel/PentecostMondayTest.php b/tests/Switzerland/Neuchatel/PentecostMondayTest.php index 97204f46a..ed7b7f8de 100644 --- a/tests/Switzerland/Neuchatel/PentecostMondayTest.php +++ b/tests/Switzerland/Neuchatel/PentecostMondayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -35,7 +34,6 @@ class PentecostMondayTest extends NeuchatelBaseTestCase implements HolidayTestCa * Tests Pentecost Monday. * * @throws Exception - * @throws ReflectionException */ public function testPentecostMonday(): void { @@ -51,7 +49,7 @@ public function testPentecostMonday(): void /** * Tests translated name of Pentecost Monday. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -66,7 +64,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Neuchatel/WorkersDayTest.php b/tests/Switzerland/Neuchatel/WorkersDayTest.php index 102f3fb93..55cd66f90 100644 --- a/tests/Switzerland/Neuchatel/WorkersDayTest.php +++ b/tests/Switzerland/Neuchatel/WorkersDayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -39,7 +38,6 @@ class WorkersDayTest extends NeuchatelBaseTestCase implements HolidayTestCase * @param int $year the year for which the holiday defined in this test needs to be tested * @param string $expected the expected date * - * @throws ReflectionException * @throws Exception */ public function testHoliday(int $year, string $expected): void @@ -71,7 +69,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -86,7 +84,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Nidwalden/AllSaintsDayTest.php b/tests/Switzerland/Nidwalden/AllSaintsDayTest.php index 93a0ff464..cee7976bc 100644 --- a/tests/Switzerland/Nidwalden/AllSaintsDayTest.php +++ b/tests/Switzerland/Nidwalden/AllSaintsDayTest.php @@ -16,7 +16,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -37,8 +36,6 @@ class AllSaintsDayTest extends NidwaldenBaseTestCase implements HolidayTestCase * * @param int $year the year for which All Saints' Day needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testAllSaintsDay(int $year, DateTime $expected): void { @@ -48,7 +45,7 @@ public function testAllSaintsDay(int $year, DateTime $expected): void /** * Tests translated name of All Saints' Day. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -63,7 +60,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Nidwalden/AscensionDayTest.php b/tests/Switzerland/Nidwalden/AscensionDayTest.php index a1572c6b1..ab23f23a0 100644 --- a/tests/Switzerland/Nidwalden/AscensionDayTest.php +++ b/tests/Switzerland/Nidwalden/AscensionDayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -35,7 +34,6 @@ class AscensionDayTest extends NidwaldenBaseTestCase implements HolidayTestCase * Tests Ascension Day. * * @throws Exception - * @throws ReflectionException */ public function testAscensionDay(): void { @@ -51,7 +49,7 @@ public function testAscensionDay(): void /** * Tests translated name of Ascension Day. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -66,7 +64,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Nidwalden/AssumptionOfMaryTest.php b/tests/Switzerland/Nidwalden/AssumptionOfMaryTest.php index 572742fac..dc3994b96 100644 --- a/tests/Switzerland/Nidwalden/AssumptionOfMaryTest.php +++ b/tests/Switzerland/Nidwalden/AssumptionOfMaryTest.php @@ -16,7 +16,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -37,8 +36,6 @@ class AssumptionOfMaryTest extends NidwaldenBaseTestCase implements HolidayTestC * * @param int $year the year for which the day of the Assumption of Mary needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testAssumptionOfMary(int $year, DateTime $expected): void { @@ -48,7 +45,7 @@ public function testAssumptionOfMary(int $year, DateTime $expected): void /** * Tests translated name of the day of the Assumption of Mary. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -63,7 +60,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Nidwalden/ChristmasDayTest.php b/tests/Switzerland/Nidwalden/ChristmasDayTest.php index e905354a4..22a844dfd 100644 --- a/tests/Switzerland/Nidwalden/ChristmasDayTest.php +++ b/tests/Switzerland/Nidwalden/ChristmasDayTest.php @@ -16,7 +16,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -37,8 +36,6 @@ class ChristmasDayTest extends NidwaldenBaseTestCase implements HolidayTestCase * * @param int $year the year for which Christmas Day needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testChristmasDay(int $year, DateTime $expected): void { @@ -60,7 +57,7 @@ public function ChristmasDayDataProvider(): array /** * Tests translated name of Christmas Day. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -75,7 +72,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Nidwalden/CorpusChristiTest.php b/tests/Switzerland/Nidwalden/CorpusChristiTest.php index d50c8b9a0..77c6fa2f9 100644 --- a/tests/Switzerland/Nidwalden/CorpusChristiTest.php +++ b/tests/Switzerland/Nidwalden/CorpusChristiTest.php @@ -16,7 +16,6 @@ use DateInterval; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\Provider\ChristianHolidays; use Yasumi\tests\HolidayTestCase; @@ -37,7 +36,6 @@ class CorpusChristiTest extends NidwaldenBaseTestCase implements HolidayTestCase * Tests Corpus Christi. * * @throws Exception - * @throws ReflectionException */ public function testCorpusChristi(): void { @@ -53,7 +51,7 @@ public function testCorpusChristi(): void /** * Tests translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -68,7 +66,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Nidwalden/EasterMondayTest.php b/tests/Switzerland/Nidwalden/EasterMondayTest.php index 3480461f8..d11aa845d 100644 --- a/tests/Switzerland/Nidwalden/EasterMondayTest.php +++ b/tests/Switzerland/Nidwalden/EasterMondayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -35,7 +34,6 @@ class EasterMondayTest extends NidwaldenBaseTestCase implements HolidayTestCase * Tests Easter Monday. * * @throws Exception - * @throws ReflectionException */ public function testEasterMonday(): void { @@ -51,7 +49,7 @@ public function testEasterMonday(): void /** * Tests translated name of Easter Monday. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -66,7 +64,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Nidwalden/GoodFridayTest.php b/tests/Switzerland/Nidwalden/GoodFridayTest.php index ae61d1cc7..b655dff09 100644 --- a/tests/Switzerland/Nidwalden/GoodFridayTest.php +++ b/tests/Switzerland/Nidwalden/GoodFridayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -35,7 +34,6 @@ class GoodFridayTest extends NidwaldenBaseTestCase implements HolidayTestCase * Tests the holiday defined in this test. * * @throws Exception - * @throws ReflectionException */ public function testHoliday(): void { @@ -51,7 +49,7 @@ public function testHoliday(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -66,7 +64,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Nidwalden/ImmaculateConceptionTest.php b/tests/Switzerland/Nidwalden/ImmaculateConceptionTest.php index b49a246bf..330107f09 100644 --- a/tests/Switzerland/Nidwalden/ImmaculateConceptionTest.php +++ b/tests/Switzerland/Nidwalden/ImmaculateConceptionTest.php @@ -16,7 +16,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -37,8 +36,6 @@ class ImmaculateConceptionTest extends NidwaldenBaseTestCase implements HolidayT * * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testHoliday(int $year, DateTime $expected): void { @@ -60,7 +57,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -75,7 +72,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Nidwalden/NewYearsDayTest.php b/tests/Switzerland/Nidwalden/NewYearsDayTest.php index 3b3573f40..36ac14093 100644 --- a/tests/Switzerland/Nidwalden/NewYearsDayTest.php +++ b/tests/Switzerland/Nidwalden/NewYearsDayTest.php @@ -16,7 +16,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -37,8 +36,6 @@ class NewYearsDayTest extends NidwaldenBaseTestCase implements HolidayTestCase * * @param int $year the year for which New Years Day needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testNewYearsDay(int $year, DateTime $expected): void { @@ -48,7 +45,7 @@ public function testNewYearsDay(int $year, DateTime $expected): void /** * Tests translated name of New Years Day. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -63,7 +60,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Nidwalden/NidwaldenTest.php b/tests/Switzerland/Nidwalden/NidwaldenTest.php index e98427d7e..303f06f77 100644 --- a/tests/Switzerland/Nidwalden/NidwaldenTest.php +++ b/tests/Switzerland/Nidwalden/NidwaldenTest.php @@ -26,10 +26,12 @@ class NidwaldenTest extends NidwaldenBaseTestCase implements ProviderTestCase /** * @var int year random year number used for all tests in this Test Case */ - protected $year; + protected int $year; /** * Initial setup of this Test Case. + * + * @throws \Exception */ protected function setUp(): void { @@ -38,8 +40,6 @@ protected function setUp(): void /** * Tests if all official holidays in Nidwalden (Switzerland) are defined by the provider class. - * - * @throws ReflectionException */ public function testOfficialHolidays(): void { @@ -52,8 +52,6 @@ public function testOfficialHolidays(): void /** * Tests if all regional holidays in Nidwalden (Switzerland) are defined by the provider class. - * - * @throws ReflectionException */ public function testRegionalHolidays(): void { @@ -75,8 +73,6 @@ public function testRegionalHolidays(): void /** * Tests if all observed holidays in Nidwalden (Switzerland) are defined by the provider class. - * - * @throws ReflectionException */ public function testObservedHolidays(): void { @@ -90,8 +86,6 @@ public function testObservedHolidays(): void /** * Tests if all seasonal holidays in Nidwalden (Switzerland) are defined by the provider class. - * - * @throws ReflectionException */ public function testSeasonalHolidays(): void { @@ -100,8 +94,6 @@ public function testSeasonalHolidays(): void /** * Tests if all bank holidays in Nidwalden (Switzerland) are defined by the provider class. - * - * @throws ReflectionException */ public function testBankHolidays(): void { @@ -110,8 +102,6 @@ public function testBankHolidays(): void /** * Tests if all other holidays in Nidwalden (Switzerland) are defined by the provider class. - * - * @throws ReflectionException */ public function testOtherHolidays(): void { @@ -120,6 +110,7 @@ public function testOtherHolidays(): void /** * @throws ReflectionException + * @throws \Exception */ public function testSources(): void { diff --git a/tests/Switzerland/Nidwalden/PentecostMondayTest.php b/tests/Switzerland/Nidwalden/PentecostMondayTest.php index 4f321e905..adc57673e 100644 --- a/tests/Switzerland/Nidwalden/PentecostMondayTest.php +++ b/tests/Switzerland/Nidwalden/PentecostMondayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -35,7 +34,6 @@ class PentecostMondayTest extends NidwaldenBaseTestCase implements HolidayTestCa * Tests Pentecost Monday. * * @throws Exception - * @throws ReflectionException */ public function testPentecostMonday(): void { @@ -51,7 +49,7 @@ public function testPentecostMonday(): void /** * Tests translated name of Pentecost Monday. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -66,7 +64,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Nidwalden/StJosephDayTest.php b/tests/Switzerland/Nidwalden/StJosephDayTest.php index c755e1687..369b1d107 100644 --- a/tests/Switzerland/Nidwalden/StJosephDayTest.php +++ b/tests/Switzerland/Nidwalden/StJosephDayTest.php @@ -16,7 +16,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\Provider\ChristianHolidays; use Yasumi\tests\HolidayTestCase; @@ -40,8 +39,6 @@ class StJosephDayTest extends NidwaldenBaseTestCase implements HolidayTestCase * * @param int $year the year for which St. Joseph's Day needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testStJosephDay(int $year, DateTime $expected): void { @@ -63,7 +60,7 @@ public function StJosephDayDataProvider(): array /** * Tests translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -78,7 +75,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Nidwalden/StStephensDayTest.php b/tests/Switzerland/Nidwalden/StStephensDayTest.php index 222b738fe..baba85bd9 100644 --- a/tests/Switzerland/Nidwalden/StStephensDayTest.php +++ b/tests/Switzerland/Nidwalden/StStephensDayTest.php @@ -16,7 +16,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -37,8 +36,6 @@ class StStephensDayTest extends NidwaldenBaseTestCase implements HolidayTestCase * * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testHoliday(int $year, DateTime $expected): void { @@ -60,7 +57,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -75,7 +72,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Obwalden/AllSaintsDayTest.php b/tests/Switzerland/Obwalden/AllSaintsDayTest.php index e45f7a03f..e18040ef1 100644 --- a/tests/Switzerland/Obwalden/AllSaintsDayTest.php +++ b/tests/Switzerland/Obwalden/AllSaintsDayTest.php @@ -16,7 +16,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -37,8 +36,6 @@ class AllSaintsDayTest extends ObwaldenBaseTestCase implements HolidayTestCase * * @param int $year the year for which All Saints' Day needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testAllSaintsDay(int $year, DateTime $expected): void { @@ -48,7 +45,7 @@ public function testAllSaintsDay(int $year, DateTime $expected): void /** * Tests translated name of All Saints' Day. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -63,7 +60,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Obwalden/AscensionDayTest.php b/tests/Switzerland/Obwalden/AscensionDayTest.php index e093ad669..b4ba96c35 100644 --- a/tests/Switzerland/Obwalden/AscensionDayTest.php +++ b/tests/Switzerland/Obwalden/AscensionDayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -35,7 +34,6 @@ class AscensionDayTest extends ObwaldenBaseTestCase implements HolidayTestCase * Tests Ascension Day. * * @throws Exception - * @throws ReflectionException */ public function testAscensionDay(): void { @@ -51,7 +49,7 @@ public function testAscensionDay(): void /** * Tests translated name of Ascension Day. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -66,7 +64,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Obwalden/AssumptionOfMaryTest.php b/tests/Switzerland/Obwalden/AssumptionOfMaryTest.php index b984c240a..960714b49 100644 --- a/tests/Switzerland/Obwalden/AssumptionOfMaryTest.php +++ b/tests/Switzerland/Obwalden/AssumptionOfMaryTest.php @@ -16,7 +16,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -37,8 +36,6 @@ class AssumptionOfMaryTest extends ObwaldenBaseTestCase implements HolidayTestCa * * @param int $year the year for which the day of the Assumption of Mary needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testAssumptionOfMary(int $year, DateTime $expected): void { @@ -48,7 +45,7 @@ public function testAssumptionOfMary(int $year, DateTime $expected): void /** * Tests translated name of the day of the Assumption of Mary. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -63,7 +60,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Obwalden/BerchtoldsTagTest.php b/tests/Switzerland/Obwalden/BerchtoldsTagTest.php index 94ef8c76b..c29fa8f09 100644 --- a/tests/Switzerland/Obwalden/BerchtoldsTagTest.php +++ b/tests/Switzerland/Obwalden/BerchtoldsTagTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,7 +33,6 @@ class BerchtoldsTagTest extends ObwaldenBaseTestCase implements HolidayTestCase /** * Tests BerchtoldsTag. * - * @throws ReflectionException * @throws Exception */ public function testBerchtoldsTag(): void @@ -49,7 +47,7 @@ public function testBerchtoldsTag(): void /** * Tests translated name of BerchtoldsTag. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -64,7 +62,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Obwalden/BruderKlausenFestTest.php b/tests/Switzerland/Obwalden/BruderKlausenFestTest.php index 7f3cee3df..bdb19f111 100644 --- a/tests/Switzerland/Obwalden/BruderKlausenFestTest.php +++ b/tests/Switzerland/Obwalden/BruderKlausenFestTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,7 +33,6 @@ class BruderKlausenFestTest extends ObwaldenBaseTestCase implements HolidayTestC /** * Tests Bruder-Klausen-Fest on or after 1947. * - * @throws ReflectionException * @throws Exception */ public function testBruderKlausenFestOnAfter1947(): void @@ -49,7 +47,6 @@ public function testBruderKlausenFestOnAfter1947(): void /** * Tests Bruder-Klausen-Fest between 1649 and 1946. * - * @throws ReflectionException * @throws Exception */ public function testBruderKlausenFestBetween1649And1946(): void @@ -64,7 +61,7 @@ public function testBruderKlausenFestBetween1649And1946(): void /** * Tests Bruder-Klausen-Fest before 1648. * - * @throws ReflectionException + * @throws Exception */ public function testBruderKlausenFestBefore1648(): void { @@ -75,7 +72,7 @@ public function testBruderKlausenFestBefore1648(): void /** * Tests translated name of Bruder-Klausen-Fest. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -90,7 +87,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Obwalden/ChristmasDayTest.php b/tests/Switzerland/Obwalden/ChristmasDayTest.php index 859ddeaa1..9099e56a9 100644 --- a/tests/Switzerland/Obwalden/ChristmasDayTest.php +++ b/tests/Switzerland/Obwalden/ChristmasDayTest.php @@ -16,7 +16,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -37,8 +36,6 @@ class ChristmasDayTest extends ObwaldenBaseTestCase implements HolidayTestCase * * @param int $year the year for which Christmas Day needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testChristmasDay(int $year, DateTime $expected): void { @@ -60,7 +57,7 @@ public function ChristmasDayDataProvider(): array /** * Tests translated name of Christmas Day. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -75,7 +72,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Obwalden/CorpusChristiTest.php b/tests/Switzerland/Obwalden/CorpusChristiTest.php index 990cca57a..261ccac23 100644 --- a/tests/Switzerland/Obwalden/CorpusChristiTest.php +++ b/tests/Switzerland/Obwalden/CorpusChristiTest.php @@ -16,7 +16,6 @@ use DateInterval; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\Provider\ChristianHolidays; use Yasumi\tests\HolidayTestCase; @@ -37,7 +36,6 @@ class CorpusChristiTest extends ObwaldenBaseTestCase implements HolidayTestCase * Tests Corpus Christi. * * @throws Exception - * @throws ReflectionException */ public function testCorpusChristi(): void { @@ -53,7 +51,7 @@ public function testCorpusChristi(): void /** * Tests translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -68,7 +66,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Obwalden/EasterMondayTest.php b/tests/Switzerland/Obwalden/EasterMondayTest.php index 2885fd534..d4798722e 100644 --- a/tests/Switzerland/Obwalden/EasterMondayTest.php +++ b/tests/Switzerland/Obwalden/EasterMondayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -35,7 +34,6 @@ class EasterMondayTest extends ObwaldenBaseTestCase implements HolidayTestCase * Tests Easter Monday. * * @throws Exception - * @throws ReflectionException */ public function testEasterMonday(): void { @@ -51,7 +49,7 @@ public function testEasterMonday(): void /** * Tests translated name of Easter Monday. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -66,7 +64,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Obwalden/GoodFridayTest.php b/tests/Switzerland/Obwalden/GoodFridayTest.php index 822ab27aa..7c9759c43 100644 --- a/tests/Switzerland/Obwalden/GoodFridayTest.php +++ b/tests/Switzerland/Obwalden/GoodFridayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -35,7 +34,6 @@ class GoodFridayTest extends ObwaldenBaseTestCase implements HolidayTestCase * Tests the holiday defined in this test. * * @throws Exception - * @throws ReflectionException */ public function testHoliday(): void { @@ -51,7 +49,7 @@ public function testHoliday(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -66,7 +64,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Obwalden/ImmaculateConceptionTest.php b/tests/Switzerland/Obwalden/ImmaculateConceptionTest.php index f9d7a5cc9..5873e0341 100644 --- a/tests/Switzerland/Obwalden/ImmaculateConceptionTest.php +++ b/tests/Switzerland/Obwalden/ImmaculateConceptionTest.php @@ -16,7 +16,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -37,8 +36,6 @@ class ImmaculateConceptionTest extends ObwaldenBaseTestCase implements HolidayTe * * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testHoliday(int $year, DateTime $expected): void { @@ -60,7 +57,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -75,7 +72,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Obwalden/NewYearsDayTest.php b/tests/Switzerland/Obwalden/NewYearsDayTest.php index 23e29fdc4..8fa8b48d5 100644 --- a/tests/Switzerland/Obwalden/NewYearsDayTest.php +++ b/tests/Switzerland/Obwalden/NewYearsDayTest.php @@ -16,7 +16,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -37,8 +36,6 @@ class NewYearsDayTest extends ObwaldenBaseTestCase implements HolidayTestCase * * @param int $year the year for which New Years Day needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testNewYearsDay(int $year, DateTime $expected): void { @@ -48,7 +45,7 @@ public function testNewYearsDay(int $year, DateTime $expected): void /** * Tests translated name of New Years Day. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -63,7 +60,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Obwalden/ObwaldenTest.php b/tests/Switzerland/Obwalden/ObwaldenTest.php index 956a5cee5..764f41412 100644 --- a/tests/Switzerland/Obwalden/ObwaldenTest.php +++ b/tests/Switzerland/Obwalden/ObwaldenTest.php @@ -26,10 +26,12 @@ class ObwaldenTest extends ObwaldenBaseTestCase implements ProviderTestCase /** * @var int year random year number used for all tests in this Test Case */ - protected $year; + protected int $year; /** * Initial setup of this Test Case. + * + * @throws \Exception */ protected function setUp(): void { @@ -38,8 +40,6 @@ protected function setUp(): void /** * Tests if all official holidays in Obwalden (Switzerland) are defined by the provider class. - * - * @throws ReflectionException */ public function testOfficialHolidays(): void { @@ -52,8 +52,6 @@ public function testOfficialHolidays(): void /** * Tests if all regional holidays in Obwalden (Switzerland) are defined by the provider class. - * - * @throws ReflectionException */ public function testRegionalHolidays(): void { @@ -76,8 +74,6 @@ public function testRegionalHolidays(): void /** * Tests if all observed holidays in Obwalden (Switzerland) are defined by the provider class. - * - * @throws ReflectionException */ public function testObservedHolidays(): void { @@ -91,8 +87,6 @@ public function testObservedHolidays(): void /** * Tests if all seasonal holidays in Obwalden (Switzerland) are defined by the provider class. - * - * @throws ReflectionException */ public function testSeasonalHolidays(): void { @@ -101,8 +95,6 @@ public function testSeasonalHolidays(): void /** * Tests if all bank holidays in Obwalden (Switzerland) are defined by the provider class. - * - * @throws ReflectionException */ public function testBankHolidays(): void { @@ -111,8 +103,6 @@ public function testBankHolidays(): void /** * Tests if all other holidays in Obwalden (Switzerland) are defined by the provider class. - * - * @throws ReflectionException */ public function testOtherHolidays(): void { @@ -121,6 +111,7 @@ public function testOtherHolidays(): void /** * @throws ReflectionException + * @throws \Exception */ public function testSources(): void { diff --git a/tests/Switzerland/Obwalden/PentecostMondayTest.php b/tests/Switzerland/Obwalden/PentecostMondayTest.php index 94e1882b9..f5a8af66d 100644 --- a/tests/Switzerland/Obwalden/PentecostMondayTest.php +++ b/tests/Switzerland/Obwalden/PentecostMondayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -35,7 +34,6 @@ class PentecostMondayTest extends ObwaldenBaseTestCase implements HolidayTestCas * Tests Pentecost Monday. * * @throws Exception - * @throws ReflectionException */ public function testPentecostMonday(): void { @@ -51,7 +49,7 @@ public function testPentecostMonday(): void /** * Tests translated name of Pentecost Monday. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -66,7 +64,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Obwalden/StStephensDayTest.php b/tests/Switzerland/Obwalden/StStephensDayTest.php index 32d427e3d..8b84213aa 100644 --- a/tests/Switzerland/Obwalden/StStephensDayTest.php +++ b/tests/Switzerland/Obwalden/StStephensDayTest.php @@ -16,7 +16,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -37,8 +36,6 @@ class StStephensDayTest extends ObwaldenBaseTestCase implements HolidayTestCase * * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testHoliday(int $year, DateTime $expected): void { @@ -60,7 +57,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -75,7 +72,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Schaffhausen/AscensionDayTest.php b/tests/Switzerland/Schaffhausen/AscensionDayTest.php index 164171d2b..eee06a1bd 100644 --- a/tests/Switzerland/Schaffhausen/AscensionDayTest.php +++ b/tests/Switzerland/Schaffhausen/AscensionDayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -35,7 +34,6 @@ class AscensionDayTest extends SchaffhausenBaseTestCase implements HolidayTestCa * Tests Ascension Day. * * @throws Exception - * @throws ReflectionException */ public function testAscensionDay(): void { @@ -51,7 +49,7 @@ public function testAscensionDay(): void /** * Tests translated name of Ascension Day. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -66,7 +64,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Schaffhausen/BerchtoldsTagTest.php b/tests/Switzerland/Schaffhausen/BerchtoldsTagTest.php index 2f0915943..5b07a942c 100644 --- a/tests/Switzerland/Schaffhausen/BerchtoldsTagTest.php +++ b/tests/Switzerland/Schaffhausen/BerchtoldsTagTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,7 +33,6 @@ class BerchtoldsTagTest extends SchaffhausenBaseTestCase implements HolidayTestC /** * Tests BerchtoldsTag. * - * @throws ReflectionException * @throws Exception */ public function testBerchtoldsTag(): void @@ -49,7 +47,7 @@ public function testBerchtoldsTag(): void /** * Tests translated name of BerchtoldsTag. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -64,7 +62,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Schaffhausen/ChristmasDayTest.php b/tests/Switzerland/Schaffhausen/ChristmasDayTest.php index 274e8ced9..a91ffb037 100644 --- a/tests/Switzerland/Schaffhausen/ChristmasDayTest.php +++ b/tests/Switzerland/Schaffhausen/ChristmasDayTest.php @@ -16,7 +16,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -37,8 +36,6 @@ class ChristmasDayTest extends SchaffhausenBaseTestCase implements HolidayTestCa * * @param int $year the year for which Christmas Day needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testChristmasDay(int $year, DateTime $expected): void { @@ -60,7 +57,7 @@ public function ChristmasDayDataProvider(): array /** * Tests translated name of Christmas Day. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -75,7 +72,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Schaffhausen/EasterMondayTest.php b/tests/Switzerland/Schaffhausen/EasterMondayTest.php index 45cd9f651..5e85be451 100644 --- a/tests/Switzerland/Schaffhausen/EasterMondayTest.php +++ b/tests/Switzerland/Schaffhausen/EasterMondayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -35,7 +34,6 @@ class EasterMondayTest extends SchaffhausenBaseTestCase implements HolidayTestCa * Tests Easter Monday. * * @throws Exception - * @throws ReflectionException */ public function testEasterMonday(): void { @@ -51,7 +49,7 @@ public function testEasterMonday(): void /** * Tests translated name of Easter Monday. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -66,7 +64,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Schaffhausen/GoodFridayTest.php b/tests/Switzerland/Schaffhausen/GoodFridayTest.php index 3f674c86e..c46dc49a4 100644 --- a/tests/Switzerland/Schaffhausen/GoodFridayTest.php +++ b/tests/Switzerland/Schaffhausen/GoodFridayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -35,7 +34,6 @@ class GoodFridayTest extends SchaffhausenBaseTestCase implements HolidayTestCase * Tests the holiday defined in this test. * * @throws Exception - * @throws ReflectionException */ public function testHoliday(): void { @@ -51,7 +49,7 @@ public function testHoliday(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -66,7 +64,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Schaffhausen/NewYearsDayTest.php b/tests/Switzerland/Schaffhausen/NewYearsDayTest.php index 42eff7880..ac2828ae5 100644 --- a/tests/Switzerland/Schaffhausen/NewYearsDayTest.php +++ b/tests/Switzerland/Schaffhausen/NewYearsDayTest.php @@ -16,7 +16,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -37,8 +36,6 @@ class NewYearsDayTest extends SchaffhausenBaseTestCase implements HolidayTestCas * * @param int $year the year for which New Years Day needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testNewYearsDay(int $year, DateTime $expected): void { @@ -48,7 +45,7 @@ public function testNewYearsDay(int $year, DateTime $expected): void /** * Tests translated name of New Years Day. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -63,7 +60,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Schaffhausen/PentecostMondayTest.php b/tests/Switzerland/Schaffhausen/PentecostMondayTest.php index ae7436e1b..b3cce3e22 100644 --- a/tests/Switzerland/Schaffhausen/PentecostMondayTest.php +++ b/tests/Switzerland/Schaffhausen/PentecostMondayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -35,7 +34,6 @@ class PentecostMondayTest extends SchaffhausenBaseTestCase implements HolidayTes * Tests Pentecost Monday. * * @throws Exception - * @throws ReflectionException */ public function testPentecostMonday(): void { @@ -51,7 +49,7 @@ public function testPentecostMonday(): void /** * Tests translated name of Pentecost Monday. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -66,7 +64,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Schaffhausen/SchaffhausenTest.php b/tests/Switzerland/Schaffhausen/SchaffhausenTest.php index da7885121..b46aac95e 100644 --- a/tests/Switzerland/Schaffhausen/SchaffhausenTest.php +++ b/tests/Switzerland/Schaffhausen/SchaffhausenTest.php @@ -26,10 +26,12 @@ class SchaffhausenTest extends SchaffhausenBaseTestCase implements ProviderTestC /** * @var int year random year number used for all tests in this Test Case */ - protected $year; + protected int $year; /** * Initial setup of this Test Case. + * + * @throws \Exception */ protected function setUp(): void { @@ -38,8 +40,6 @@ protected function setUp(): void /** * Tests if all official holidays in Schaffhausen (Switzerland) are defined by the provider class. - * - * @throws ReflectionException */ public function testOfficialHolidays(): void { @@ -52,8 +52,6 @@ public function testOfficialHolidays(): void /** * Tests if all regional holidays in Schaffhausen (Switzerland) are defined by the provider class. - * - * @throws ReflectionException */ public function testRegionalHolidays(): void { @@ -72,8 +70,6 @@ public function testRegionalHolidays(): void /** * Tests if all observed holidays in Schaffhausen (Switzerland) are defined by the provider class. - * - * @throws ReflectionException */ public function testObservedHolidays(): void { @@ -87,8 +83,6 @@ public function testObservedHolidays(): void /** * Tests if all seasonal holidays in Schaffhausen (Switzerland) are defined by the provider class. - * - * @throws ReflectionException */ public function testSeasonalHolidays(): void { @@ -97,8 +91,6 @@ public function testSeasonalHolidays(): void /** * Tests if all bank holidays in Schaffhausen (Switzerland) are defined by the provider class. - * - * @throws ReflectionException */ public function testBankHolidays(): void { @@ -107,8 +99,6 @@ public function testBankHolidays(): void /** * Tests if all other holidays in Schaffhausen (Switzerland) are defined by the provider class. - * - * @throws ReflectionException */ public function testOtherHolidays(): void { @@ -117,6 +107,7 @@ public function testOtherHolidays(): void /** * @throws ReflectionException + * @throws \Exception */ public function testSources(): void { diff --git a/tests/Switzerland/Schaffhausen/StStephensDayTest.php b/tests/Switzerland/Schaffhausen/StStephensDayTest.php index 2af128680..85564d411 100644 --- a/tests/Switzerland/Schaffhausen/StStephensDayTest.php +++ b/tests/Switzerland/Schaffhausen/StStephensDayTest.php @@ -16,7 +16,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -37,8 +36,6 @@ class StStephensDayTest extends SchaffhausenBaseTestCase implements HolidayTestC * * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testHoliday(int $year, DateTime $expected): void { @@ -60,7 +57,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -75,7 +72,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Schaffhausen/WorkersDayTest.php b/tests/Switzerland/Schaffhausen/WorkersDayTest.php index efe1fe5d6..af78bacd2 100644 --- a/tests/Switzerland/Schaffhausen/WorkersDayTest.php +++ b/tests/Switzerland/Schaffhausen/WorkersDayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -39,7 +38,6 @@ class WorkersDayTest extends SchaffhausenBaseTestCase implements HolidayTestCase * @param int $year the year for which the holiday defined in this test needs to be tested * @param string $expected the expected date * - * @throws ReflectionException * @throws Exception */ public function testHoliday(int $year, string $expected): void @@ -71,7 +69,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -86,7 +84,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Schwyz/AllSaintsDayTest.php b/tests/Switzerland/Schwyz/AllSaintsDayTest.php index 29f38fbc0..b2fb1177d 100644 --- a/tests/Switzerland/Schwyz/AllSaintsDayTest.php +++ b/tests/Switzerland/Schwyz/AllSaintsDayTest.php @@ -16,7 +16,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -37,8 +36,6 @@ class AllSaintsDayTest extends SchwyzBaseTestCase implements HolidayTestCase * * @param int $year the year for which All Saints' Day needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testAllSaintsDay(int $year, DateTime $expected): void { @@ -48,7 +45,7 @@ public function testAllSaintsDay(int $year, DateTime $expected): void /** * Tests translated name of All Saints' Day. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -63,7 +60,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Schwyz/AscensionDayTest.php b/tests/Switzerland/Schwyz/AscensionDayTest.php index f6122f01b..1735a4960 100644 --- a/tests/Switzerland/Schwyz/AscensionDayTest.php +++ b/tests/Switzerland/Schwyz/AscensionDayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -35,7 +34,6 @@ class AscensionDayTest extends SchwyzBaseTestCase implements HolidayTestCase * Tests Ascension Day. * * @throws Exception - * @throws ReflectionException */ public function testAscensionDay(): void { @@ -51,7 +49,7 @@ public function testAscensionDay(): void /** * Tests translated name of Ascension Day. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -66,7 +64,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Schwyz/AssumptionOfMaryTest.php b/tests/Switzerland/Schwyz/AssumptionOfMaryTest.php index d3923041f..1d232dfd5 100644 --- a/tests/Switzerland/Schwyz/AssumptionOfMaryTest.php +++ b/tests/Switzerland/Schwyz/AssumptionOfMaryTest.php @@ -16,7 +16,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -37,8 +36,6 @@ class AssumptionOfMaryTest extends SchwyzBaseTestCase implements HolidayTestCase * * @param int $year the year for which the day of the Assumption of Mary needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testAssumptionOfMary(int $year, DateTime $expected): void { @@ -48,7 +45,7 @@ public function testAssumptionOfMary(int $year, DateTime $expected): void /** * Tests translated name of the day of the Assumption of Mary. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -63,7 +60,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Schwyz/ChristmasDayTest.php b/tests/Switzerland/Schwyz/ChristmasDayTest.php index 9a71d4e02..340e73c47 100644 --- a/tests/Switzerland/Schwyz/ChristmasDayTest.php +++ b/tests/Switzerland/Schwyz/ChristmasDayTest.php @@ -16,7 +16,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -37,8 +36,6 @@ class ChristmasDayTest extends SchwyzBaseTestCase implements HolidayTestCase * * @param int $year the year for which Christmas Day needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testChristmasDay(int $year, DateTime $expected): void { @@ -60,7 +57,7 @@ public function ChristmasDayDataProvider(): array /** * Tests translated name of Christmas Day. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -75,7 +72,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Schwyz/CorpusChristiTest.php b/tests/Switzerland/Schwyz/CorpusChristiTest.php index 5b20cbc4e..65fa94b84 100644 --- a/tests/Switzerland/Schwyz/CorpusChristiTest.php +++ b/tests/Switzerland/Schwyz/CorpusChristiTest.php @@ -16,7 +16,6 @@ use DateInterval; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\Provider\ChristianHolidays; use Yasumi\tests\HolidayTestCase; @@ -37,7 +36,6 @@ class CorpusChristiTest extends SchwyzBaseTestCase implements HolidayTestCase * Tests Corpus Christi. * * @throws Exception - * @throws ReflectionException */ public function testCorpusChristi(): void { @@ -53,7 +51,7 @@ public function testCorpusChristi(): void /** * Tests translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -68,7 +66,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Schwyz/EasterMondayTest.php b/tests/Switzerland/Schwyz/EasterMondayTest.php index 0c3119ff8..fef0231ff 100644 --- a/tests/Switzerland/Schwyz/EasterMondayTest.php +++ b/tests/Switzerland/Schwyz/EasterMondayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -35,7 +34,6 @@ class EasterMondayTest extends SchwyzBaseTestCase implements HolidayTestCase * Tests Easter Monday. * * @throws Exception - * @throws ReflectionException */ public function testEasterMonday(): void { @@ -51,7 +49,7 @@ public function testEasterMonday(): void /** * Tests translated name of Easter Monday. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -66,7 +64,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Schwyz/EpiphanyTest.php b/tests/Switzerland/Schwyz/EpiphanyTest.php index 38ff413c4..811415bd0 100644 --- a/tests/Switzerland/Schwyz/EpiphanyTest.php +++ b/tests/Switzerland/Schwyz/EpiphanyTest.php @@ -16,7 +16,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -37,8 +36,6 @@ class EpiphanyTest extends SchwyzBaseTestCase implements HolidayTestCase * * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testHoliday(int $year, DateTime $expected): void { @@ -60,7 +57,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -75,7 +72,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Schwyz/GoodFridayTest.php b/tests/Switzerland/Schwyz/GoodFridayTest.php index 5e61365ae..c869a1793 100644 --- a/tests/Switzerland/Schwyz/GoodFridayTest.php +++ b/tests/Switzerland/Schwyz/GoodFridayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -35,7 +34,6 @@ class GoodFridayTest extends SchwyzBaseTestCase implements HolidayTestCase * Tests the holiday defined in this test. * * @throws Exception - * @throws ReflectionException */ public function testHoliday(): void { @@ -51,7 +49,7 @@ public function testHoliday(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -66,7 +64,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Schwyz/ImmaculateConceptionTest.php b/tests/Switzerland/Schwyz/ImmaculateConceptionTest.php index af29abe19..2f273071d 100644 --- a/tests/Switzerland/Schwyz/ImmaculateConceptionTest.php +++ b/tests/Switzerland/Schwyz/ImmaculateConceptionTest.php @@ -16,7 +16,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -37,8 +36,6 @@ class ImmaculateConceptionTest extends SchwyzBaseTestCase implements HolidayTest * * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testHoliday(int $year, DateTime $expected): void { @@ -60,7 +57,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -75,7 +72,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Schwyz/NewYearsDayTest.php b/tests/Switzerland/Schwyz/NewYearsDayTest.php index cd7494ae5..dbd6b5495 100644 --- a/tests/Switzerland/Schwyz/NewYearsDayTest.php +++ b/tests/Switzerland/Schwyz/NewYearsDayTest.php @@ -16,7 +16,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -37,8 +36,6 @@ class NewYearsDayTest extends SchwyzBaseTestCase implements HolidayTestCase * * @param int $year the year for which New Years Day needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testNewYearsDay(int $year, DateTime $expected): void { @@ -48,7 +45,7 @@ public function testNewYearsDay(int $year, DateTime $expected): void /** * Tests translated name of New Years Day. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -63,7 +60,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Schwyz/PentecostMondayTest.php b/tests/Switzerland/Schwyz/PentecostMondayTest.php index dcf085522..d7ffd26ca 100644 --- a/tests/Switzerland/Schwyz/PentecostMondayTest.php +++ b/tests/Switzerland/Schwyz/PentecostMondayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -35,7 +34,6 @@ class PentecostMondayTest extends SchwyzBaseTestCase implements HolidayTestCase * Tests Pentecost Monday. * * @throws Exception - * @throws ReflectionException */ public function testPentecostMonday(): void { @@ -51,7 +49,7 @@ public function testPentecostMonday(): void /** * Tests translated name of Pentecost Monday. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -66,7 +64,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Schwyz/SchwyzTest.php b/tests/Switzerland/Schwyz/SchwyzTest.php index fc23c1365..d1f9650ed 100644 --- a/tests/Switzerland/Schwyz/SchwyzTest.php +++ b/tests/Switzerland/Schwyz/SchwyzTest.php @@ -26,10 +26,12 @@ class SchwyzTest extends SchwyzBaseTestCase implements ProviderTestCase /** * @var int year random year number used for all tests in this Test Case */ - protected $year; + protected int $year; /** * Initial setup of this Test Case. + * + * @throws \Exception */ protected function setUp(): void { @@ -38,8 +40,6 @@ protected function setUp(): void /** * Tests if all official holidays in Schwyz (Switzerland) are defined by the provider class. - * - * @throws ReflectionException */ public function testOfficialHolidays(): void { @@ -52,8 +52,6 @@ public function testOfficialHolidays(): void /** * Tests if all regional holidays in Schwyz (Switzerland) are defined by the provider class. - * - * @throws ReflectionException */ public function testRegionalHolidays(): void { @@ -76,8 +74,6 @@ public function testRegionalHolidays(): void /** * Tests if all observed holidays in Schwyz (Switzerland) are defined by the provider class. - * - * @throws ReflectionException */ public function testObservedHolidays(): void { @@ -91,8 +87,6 @@ public function testObservedHolidays(): void /** * Tests if all seasonal holidays in Schwyz (Switzerland) are defined by the provider class. - * - * @throws ReflectionException */ public function testSeasonalHolidays(): void { @@ -101,8 +95,6 @@ public function testSeasonalHolidays(): void /** * Tests if all bank holidays in Schwyz (Switzerland) are defined by the provider class. - * - * @throws ReflectionException */ public function testBankHolidays(): void { @@ -111,8 +103,6 @@ public function testBankHolidays(): void /** * Tests if all other holidays in Schwyz (Switzerland) are defined by the provider class. - * - * @throws ReflectionException */ public function testOtherHolidays(): void { @@ -121,6 +111,7 @@ public function testOtherHolidays(): void /** * @throws ReflectionException + * @throws \Exception */ public function testSources(): void { diff --git a/tests/Switzerland/Schwyz/StJosephDayTest.php b/tests/Switzerland/Schwyz/StJosephDayTest.php index 48a1bfd67..785686258 100644 --- a/tests/Switzerland/Schwyz/StJosephDayTest.php +++ b/tests/Switzerland/Schwyz/StJosephDayTest.php @@ -16,7 +16,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\Provider\ChristianHolidays; use Yasumi\tests\HolidayTestCase; @@ -40,8 +39,6 @@ class StJosephDayTest extends SchwyzBaseTestCase implements HolidayTestCase * * @param int $year the year for which St. Joseph's Day needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testStJosephDay(int $year, DateTime $expected): void { @@ -63,7 +60,7 @@ public function StJosephDayDataProvider(): array /** * Tests translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -78,7 +75,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Schwyz/StStephensDayTest.php b/tests/Switzerland/Schwyz/StStephensDayTest.php index 8843a3dc4..8408f56a1 100644 --- a/tests/Switzerland/Schwyz/StStephensDayTest.php +++ b/tests/Switzerland/Schwyz/StStephensDayTest.php @@ -16,7 +16,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -37,8 +36,6 @@ class StStephensDayTest extends SchwyzBaseTestCase implements HolidayTestCase * * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testHoliday(int $year, DateTime $expected): void { @@ -60,7 +57,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -75,7 +72,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Solothurn/AscensionDayTest.php b/tests/Switzerland/Solothurn/AscensionDayTest.php index e59d39c75..2b4253fa5 100644 --- a/tests/Switzerland/Solothurn/AscensionDayTest.php +++ b/tests/Switzerland/Solothurn/AscensionDayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -35,7 +34,6 @@ class AscensionDayTest extends SolothurnBaseTestCase implements HolidayTestCase * Tests Ascension Day. * * @throws Exception - * @throws ReflectionException */ public function testAscensionDay(): void { @@ -51,7 +49,7 @@ public function testAscensionDay(): void /** * Tests translated name of Ascension Day. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -66,7 +64,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Solothurn/BerchtoldsTagTest.php b/tests/Switzerland/Solothurn/BerchtoldsTagTest.php index 124cd8071..9b51471a4 100644 --- a/tests/Switzerland/Solothurn/BerchtoldsTagTest.php +++ b/tests/Switzerland/Solothurn/BerchtoldsTagTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,7 +33,6 @@ class BerchtoldsTagTest extends SolothurnBaseTestCase implements HolidayTestCase /** * Tests BerchtoldsTag. * - * @throws ReflectionException * @throws Exception */ public function testBerchtoldsTag(): void @@ -49,7 +47,7 @@ public function testBerchtoldsTag(): void /** * Tests translated name of BerchtoldsTag. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -64,7 +62,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Solothurn/ChristmasDayTest.php b/tests/Switzerland/Solothurn/ChristmasDayTest.php index e3117293d..b0b2b00da 100644 --- a/tests/Switzerland/Solothurn/ChristmasDayTest.php +++ b/tests/Switzerland/Solothurn/ChristmasDayTest.php @@ -16,7 +16,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -37,8 +36,6 @@ class ChristmasDayTest extends SolothurnBaseTestCase implements HolidayTestCase * * @param int $year the year for which Christmas Day needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testChristmasDay(int $year, DateTime $expected): void { @@ -60,7 +57,7 @@ public function ChristmasDayDataProvider(): array /** * Tests translated name of Christmas Day. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -75,7 +72,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Solothurn/GoodFridayTest.php b/tests/Switzerland/Solothurn/GoodFridayTest.php index 96e48ecad..8b1361c31 100644 --- a/tests/Switzerland/Solothurn/GoodFridayTest.php +++ b/tests/Switzerland/Solothurn/GoodFridayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -35,7 +34,6 @@ class GoodFridayTest extends SolothurnBaseTestCase implements HolidayTestCase * Tests the holiday defined in this test. * * @throws Exception - * @throws ReflectionException */ public function testHoliday(): void { @@ -51,7 +49,7 @@ public function testHoliday(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -66,7 +64,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Solothurn/NewYearsDayTest.php b/tests/Switzerland/Solothurn/NewYearsDayTest.php index 658e4dc5f..35541d83f 100644 --- a/tests/Switzerland/Solothurn/NewYearsDayTest.php +++ b/tests/Switzerland/Solothurn/NewYearsDayTest.php @@ -16,7 +16,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -37,8 +36,6 @@ class NewYearsDayTest extends SolothurnBaseTestCase implements HolidayTestCase * * @param int $year the year for which New Years Day needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testNewYearsDay(int $year, DateTime $expected): void { @@ -48,7 +45,7 @@ public function testNewYearsDay(int $year, DateTime $expected): void /** * Tests translated name of New Years Day. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -63,7 +60,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Solothurn/SolothurnTest.php b/tests/Switzerland/Solothurn/SolothurnTest.php index aa5f93eb2..ce2c28dfc 100644 --- a/tests/Switzerland/Solothurn/SolothurnTest.php +++ b/tests/Switzerland/Solothurn/SolothurnTest.php @@ -26,10 +26,12 @@ class SolothurnTest extends SolothurnBaseTestCase implements ProviderTestCase /** * @var int year random year number used for all tests in this Test Case */ - protected $year; + protected int $year; /** * Initial setup of this Test Case. + * + * @throws \Exception */ protected function setUp(): void { @@ -38,8 +40,6 @@ protected function setUp(): void /** * Tests if all official holidays in Solothurn (Switzerland) are defined by the provider class. - * - * @throws ReflectionException */ public function testOfficialHolidays(): void { @@ -53,8 +53,6 @@ public function testOfficialHolidays(): void /** * Tests if all regional holidays in Solothurn (Switzerland) are defined by the provider class. - * - * @throws ReflectionException */ public function testRegionalHolidays(): void { @@ -69,8 +67,6 @@ public function testRegionalHolidays(): void /** * Tests if all observed holidays in Solothurn (Switzerland) are defined by the provider class. - * - * @throws ReflectionException */ public function testObservedHolidays(): void { @@ -84,8 +80,6 @@ public function testObservedHolidays(): void /** * Tests if all seasonal holidays in Solothurn (Switzerland) are defined by the provider class. - * - * @throws ReflectionException */ public function testSeasonalHolidays(): void { @@ -94,8 +88,6 @@ public function testSeasonalHolidays(): void /** * Tests if all bank holidays in Solothurn (Switzerland) are defined by the provider class. - * - * @throws ReflectionException */ public function testBankHolidays(): void { @@ -104,8 +96,6 @@ public function testBankHolidays(): void /** * Tests if all other holidays in Solothurn (Switzerland) are defined by the provider class. - * - * @throws ReflectionException */ public function testOtherHolidays(): void { @@ -114,6 +104,7 @@ public function testOtherHolidays(): void /** * @throws ReflectionException + * @throws \Exception */ public function testSources(): void { diff --git a/tests/Switzerland/StGallen/AllSaintsDayTest.php b/tests/Switzerland/StGallen/AllSaintsDayTest.php index c8bb3cf9c..60989720d 100644 --- a/tests/Switzerland/StGallen/AllSaintsDayTest.php +++ b/tests/Switzerland/StGallen/AllSaintsDayTest.php @@ -16,7 +16,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -37,8 +36,6 @@ class AllSaintsDayTest extends StGallenBaseTestCase implements HolidayTestCase * * @param int $year the year for which All Saints' Day needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testAllSaintsDay(int $year, DateTime $expected): void { @@ -48,7 +45,7 @@ public function testAllSaintsDay(int $year, DateTime $expected): void /** * Tests translated name of All Saints' Day. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -63,7 +60,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/StGallen/AscensionDayTest.php b/tests/Switzerland/StGallen/AscensionDayTest.php index 9606ed4bd..ac22c2588 100644 --- a/tests/Switzerland/StGallen/AscensionDayTest.php +++ b/tests/Switzerland/StGallen/AscensionDayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -35,7 +34,6 @@ class AscensionDayTest extends StGallenBaseTestCase implements HolidayTestCase * Tests Ascension Day. * * @throws Exception - * @throws ReflectionException */ public function testAscensionDay(): void { @@ -51,7 +49,7 @@ public function testAscensionDay(): void /** * Tests translated name of Ascension Day. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -66,7 +64,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/StGallen/ChristmasDayTest.php b/tests/Switzerland/StGallen/ChristmasDayTest.php index 8eef44970..3bd4e13ef 100644 --- a/tests/Switzerland/StGallen/ChristmasDayTest.php +++ b/tests/Switzerland/StGallen/ChristmasDayTest.php @@ -16,7 +16,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -37,8 +36,6 @@ class ChristmasDayTest extends StGallenBaseTestCase implements HolidayTestCase * * @param int $year the year for which Christmas Day needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testChristmasDay(int $year, DateTime $expected): void { @@ -60,7 +57,7 @@ public function ChristmasDayDataProvider(): array /** * Tests translated name of Christmas Day. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -75,7 +72,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/StGallen/EasterMondayTest.php b/tests/Switzerland/StGallen/EasterMondayTest.php index a44b54e15..682cc2633 100644 --- a/tests/Switzerland/StGallen/EasterMondayTest.php +++ b/tests/Switzerland/StGallen/EasterMondayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -35,7 +34,6 @@ class EasterMondayTest extends StGallenBaseTestCase implements HolidayTestCase * Tests Easter Monday. * * @throws Exception - * @throws ReflectionException */ public function testEasterMonday(): void { @@ -51,7 +49,7 @@ public function testEasterMonday(): void /** * Tests translated name of Easter Monday. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -66,7 +64,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/StGallen/GoodFridayTest.php b/tests/Switzerland/StGallen/GoodFridayTest.php index ac917bb4e..dea1c7c96 100644 --- a/tests/Switzerland/StGallen/GoodFridayTest.php +++ b/tests/Switzerland/StGallen/GoodFridayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -35,7 +34,6 @@ class GoodFridayTest extends StGallenBaseTestCase implements HolidayTestCase * Tests the holiday defined in this test. * * @throws Exception - * @throws ReflectionException */ public function testHoliday(): void { @@ -51,7 +49,7 @@ public function testHoliday(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -66,7 +64,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/StGallen/NewYearsDayTest.php b/tests/Switzerland/StGallen/NewYearsDayTest.php index 80c22cb2e..bae4e38f5 100644 --- a/tests/Switzerland/StGallen/NewYearsDayTest.php +++ b/tests/Switzerland/StGallen/NewYearsDayTest.php @@ -16,7 +16,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -37,8 +36,6 @@ class NewYearsDayTest extends StGallenBaseTestCase implements HolidayTestCase * * @param int $year the year for which New Years Day needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testNewYearsDay(int $year, DateTime $expected): void { @@ -48,7 +45,7 @@ public function testNewYearsDay(int $year, DateTime $expected): void /** * Tests translated name of New Years Day. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -63,7 +60,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/StGallen/PentecostMondayTest.php b/tests/Switzerland/StGallen/PentecostMondayTest.php index 9ae921586..972cc621c 100644 --- a/tests/Switzerland/StGallen/PentecostMondayTest.php +++ b/tests/Switzerland/StGallen/PentecostMondayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -35,7 +34,6 @@ class PentecostMondayTest extends StGallenBaseTestCase implements HolidayTestCas * Tests Pentecost Monday. * * @throws Exception - * @throws ReflectionException */ public function testPentecostMonday(): void { @@ -51,7 +49,7 @@ public function testPentecostMonday(): void /** * Tests translated name of Pentecost Monday. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -66,7 +64,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/StGallen/StGallenTest.php b/tests/Switzerland/StGallen/StGallenTest.php index d87f698c4..23046de5c 100644 --- a/tests/Switzerland/StGallen/StGallenTest.php +++ b/tests/Switzerland/StGallen/StGallenTest.php @@ -26,10 +26,12 @@ class StGallenTest extends StGallenBaseTestCase implements ProviderTestCase /** * @var int year random year number used for all tests in this Test Case */ - protected $year; + protected int $year; /** * Initial setup of this Test Case. + * + * @throws \Exception */ protected function setUp(): void { @@ -38,8 +40,6 @@ protected function setUp(): void /** * Tests if all official holidays in St. Gallen (Switzerland) are defined by the provider class. - * - * @throws ReflectionException */ public function testOfficialHolidays(): void { @@ -52,8 +52,6 @@ public function testOfficialHolidays(): void /** * Tests if all regional holidays in St. Gallen (Switzerland) are defined by the provider class. - * - * @throws ReflectionException */ public function testRegionalHolidays(): void { @@ -71,8 +69,6 @@ public function testRegionalHolidays(): void /** * Tests if all observed holidays in St. Gallen (Switzerland) are defined by the provider class. - * - * @throws ReflectionException */ public function testObservedHolidays(): void { @@ -86,8 +82,6 @@ public function testObservedHolidays(): void /** * Tests if all seasonal holidays in St. Gallen (Switzerland) are defined by the provider class. - * - * @throws ReflectionException */ public function testSeasonalHolidays(): void { @@ -96,8 +90,6 @@ public function testSeasonalHolidays(): void /** * Tests if all bank holidays in St. Gallen (Switzerland) are defined by the provider class. - * - * @throws ReflectionException */ public function testBankHolidays(): void { @@ -106,8 +98,6 @@ public function testBankHolidays(): void /** * Tests if all other holidays in St. Gallen (Switzerland) are defined by the provider class. - * - * @throws ReflectionException */ public function testOtherHolidays(): void { @@ -116,6 +106,7 @@ public function testOtherHolidays(): void /** * @throws ReflectionException + * @throws \Exception */ public function testSources(): void { diff --git a/tests/Switzerland/StGallen/StStephensDayTest.php b/tests/Switzerland/StGallen/StStephensDayTest.php index 83e8d1470..89c3cced1 100644 --- a/tests/Switzerland/StGallen/StStephensDayTest.php +++ b/tests/Switzerland/StGallen/StStephensDayTest.php @@ -16,7 +16,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -37,8 +36,6 @@ class StStephensDayTest extends StGallenBaseTestCase implements HolidayTestCase * * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testHoliday(int $year, DateTime $expected): void { @@ -60,7 +57,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -75,7 +72,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/SwissNationalDayTest.php b/tests/Switzerland/SwissNationalDayTest.php index a0fa465b1..579b38228 100644 --- a/tests/Switzerland/SwissNationalDayTest.php +++ b/tests/Switzerland/SwissNationalDayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -50,7 +49,6 @@ class SwissNationalDayTest extends SwitzerlandBaseTestCase implements HolidayTes * Tests National Day on or after 1994. * * @throws Exception - * @throws ReflectionException */ public function testNationalDayOnAfter1994(): void { @@ -66,9 +64,7 @@ public function testNationalDayOnAfter1994(): void /** * Tests National Day on or after 1899 and before 1994. * - * @throws ReflectionException * @throws Exception - * @throws ReflectionException */ public function testNationalDayOnAfter1899(): void { @@ -85,9 +81,7 @@ public function testNationalDayOnAfter1899(): void /** * Tests National Day on 1891. * - * @throws ReflectionException * @throws Exception - * @throws ReflectionException */ public function testNationalDayOn1891(): void { @@ -104,7 +98,7 @@ public function testNationalDayOn1891(): void /** * Tests National Day before 1891. * - * @throws ReflectionException + * @throws Exception */ public function testNationalDayBefore1891(): void { @@ -118,7 +112,7 @@ public function testNationalDayBefore1891(): void /** * Tests National Day between 1891 and 1899. * - * @throws ReflectionException + * @throws Exception */ public function testNationalDayBetween1891And1899(): void { @@ -129,7 +123,7 @@ public function testNationalDayBetween1891And1899(): void /** * Tests translated name of National Day. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -144,7 +138,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/SwitzerlandTest.php b/tests/Switzerland/SwitzerlandTest.php index 1aab01217..28bded230 100644 --- a/tests/Switzerland/SwitzerlandTest.php +++ b/tests/Switzerland/SwitzerlandTest.php @@ -26,10 +26,12 @@ class SwitzerlandTest extends SwitzerlandBaseTestCase implements ProviderTestCas /** * @var int year random year number used for all tests in this Test Case */ - protected $year; + protected int $year; /** * Initial setup of this Test Case. + * + * @throws \Exception */ protected function setUp(): void { @@ -38,8 +40,6 @@ protected function setUp(): void /** * Tests if all official holidays in Switzerland are defined by the provider class. - * - * @throws ReflectionException */ public function testOfficialHolidays(): void { @@ -52,8 +52,6 @@ public function testOfficialHolidays(): void /** * Tests if all observed holidays in Switzerland are defined by the provider class. - * - * @throws ReflectionException */ public function testObservedHolidays(): void { @@ -67,8 +65,6 @@ public function testObservedHolidays(): void /** * Tests if all seasonal holidays in Switzerland are defined by the provider class. - * - * @throws ReflectionException */ public function testSeasonalHolidays(): void { @@ -77,8 +73,6 @@ public function testSeasonalHolidays(): void /** * Tests if all bank holidays in Switzerland are defined by the provider class. - * - * @throws ReflectionException */ public function testBankHolidays(): void { @@ -87,8 +81,6 @@ public function testBankHolidays(): void /** * Tests if all other holidays in Switzerland are defined by the provider class. - * - * @throws ReflectionException */ public function testOtherHolidays(): void { @@ -97,6 +89,7 @@ public function testOtherHolidays(): void /** * @throws ReflectionException + * @throws \Exception */ public function testSources(): void { diff --git a/tests/Switzerland/Thurgau/AscensionDayTest.php b/tests/Switzerland/Thurgau/AscensionDayTest.php index 808c6c865..a0a90bb72 100644 --- a/tests/Switzerland/Thurgau/AscensionDayTest.php +++ b/tests/Switzerland/Thurgau/AscensionDayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -35,7 +34,6 @@ class AscensionDayTest extends ThurgauBaseTestCase implements HolidayTestCase * Tests Ascension Day. * * @throws Exception - * @throws ReflectionException */ public function testAscensionDay(): void { @@ -51,7 +49,7 @@ public function testAscensionDay(): void /** * Tests translated name of Ascension Day. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -66,7 +64,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Thurgau/BerchtoldsTagTest.php b/tests/Switzerland/Thurgau/BerchtoldsTagTest.php index f8a25f391..23a138dcf 100644 --- a/tests/Switzerland/Thurgau/BerchtoldsTagTest.php +++ b/tests/Switzerland/Thurgau/BerchtoldsTagTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,7 +33,6 @@ class BerchtoldsTagTest extends ThurgauBaseTestCase implements HolidayTestCase /** * Tests BerchtoldsTag. * - * @throws ReflectionException * @throws Exception */ public function testBerchtoldsTag(): void @@ -49,7 +47,7 @@ public function testBerchtoldsTag(): void /** * Tests translated name of BerchtoldsTag. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -64,7 +62,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Thurgau/ChristmasDayTest.php b/tests/Switzerland/Thurgau/ChristmasDayTest.php index f8944fa49..e30bb9d22 100644 --- a/tests/Switzerland/Thurgau/ChristmasDayTest.php +++ b/tests/Switzerland/Thurgau/ChristmasDayTest.php @@ -16,7 +16,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -37,8 +36,6 @@ class ChristmasDayTest extends ThurgauBaseTestCase implements HolidayTestCase * * @param int $year the year for which Christmas Day needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testChristmasDay(int $year, DateTime $expected): void { @@ -60,7 +57,7 @@ public function ChristmasDayDataProvider(): array /** * Tests translated name of Christmas Day. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -75,7 +72,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Thurgau/EasterMondayTest.php b/tests/Switzerland/Thurgau/EasterMondayTest.php index 1ae22747f..bbfea0fcf 100644 --- a/tests/Switzerland/Thurgau/EasterMondayTest.php +++ b/tests/Switzerland/Thurgau/EasterMondayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -35,7 +34,6 @@ class EasterMondayTest extends ThurgauBaseTestCase implements HolidayTestCase * Tests Easter Monday. * * @throws Exception - * @throws ReflectionException */ public function testEasterMonday(): void { @@ -51,7 +49,7 @@ public function testEasterMonday(): void /** * Tests translated name of Easter Monday. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -66,7 +64,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Thurgau/GoodFridayTest.php b/tests/Switzerland/Thurgau/GoodFridayTest.php index ff1f43abe..9729446c6 100644 --- a/tests/Switzerland/Thurgau/GoodFridayTest.php +++ b/tests/Switzerland/Thurgau/GoodFridayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -35,7 +34,6 @@ class GoodFridayTest extends ThurgauBaseTestCase implements HolidayTestCase * Tests the holiday defined in this test. * * @throws Exception - * @throws ReflectionException */ public function testHoliday(): void { @@ -51,7 +49,7 @@ public function testHoliday(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -66,7 +64,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Thurgau/NewYearsDayTest.php b/tests/Switzerland/Thurgau/NewYearsDayTest.php index 731276734..7aaf432ed 100644 --- a/tests/Switzerland/Thurgau/NewYearsDayTest.php +++ b/tests/Switzerland/Thurgau/NewYearsDayTest.php @@ -16,7 +16,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -37,8 +36,6 @@ class NewYearsDayTest extends ThurgauBaseTestCase implements HolidayTestCase * * @param int $year the year for which New Years Day needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testNewYearsDay(int $year, DateTime $expected): void { @@ -48,7 +45,7 @@ public function testNewYearsDay(int $year, DateTime $expected): void /** * Tests translated name of New Years Day. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -63,7 +60,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Thurgau/PentecostMondayTest.php b/tests/Switzerland/Thurgau/PentecostMondayTest.php index e7ba6ac25..344c9e7c1 100644 --- a/tests/Switzerland/Thurgau/PentecostMondayTest.php +++ b/tests/Switzerland/Thurgau/PentecostMondayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -35,7 +34,6 @@ class PentecostMondayTest extends ThurgauBaseTestCase implements HolidayTestCase * Tests Pentecost Monday. * * @throws Exception - * @throws ReflectionException */ public function testPentecostMonday(): void { @@ -51,7 +49,7 @@ public function testPentecostMonday(): void /** * Tests translated name of Pentecost Monday. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -66,7 +64,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Thurgau/StStephensDayTest.php b/tests/Switzerland/Thurgau/StStephensDayTest.php index 19a1eebff..8b8a72fc9 100644 --- a/tests/Switzerland/Thurgau/StStephensDayTest.php +++ b/tests/Switzerland/Thurgau/StStephensDayTest.php @@ -16,7 +16,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -37,8 +36,6 @@ class StStephensDayTest extends ThurgauBaseTestCase implements HolidayTestCase * * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testHoliday(int $year, DateTime $expected): void { @@ -60,7 +57,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -75,7 +72,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Thurgau/ThurgauTest.php b/tests/Switzerland/Thurgau/ThurgauTest.php index 30f1f6704..494a1999d 100644 --- a/tests/Switzerland/Thurgau/ThurgauTest.php +++ b/tests/Switzerland/Thurgau/ThurgauTest.php @@ -26,10 +26,12 @@ class ThurgauTest extends ThurgauBaseTestCase implements ProviderTestCase /** * @var int year random year number used for all tests in this Test Case */ - protected $year; + protected int $year; /** * Initial setup of this Test Case. + * + * @throws \Exception */ protected function setUp(): void { @@ -38,8 +40,6 @@ protected function setUp(): void /** * Tests if all official holidays in Thurgau (Switzerland) are defined by the provider class. - * - * @throws ReflectionException */ public function testOfficialHolidays(): void { @@ -52,8 +52,6 @@ public function testOfficialHolidays(): void /** * Tests if all regional holidays in Thurgau (Switzerland) are defined by the provider class. - * - * @throws ReflectionException */ public function testRegionalHolidays(): void { @@ -72,8 +70,6 @@ public function testRegionalHolidays(): void /** * Tests if all observed holidays in Thurgau (Switzerland) are defined by the provider class. - * - * @throws ReflectionException */ public function testObservedHolidays(): void { @@ -87,8 +83,6 @@ public function testObservedHolidays(): void /** * Tests if all seasonal holidays in Thurgau (Switzerland) are defined by the provider class. - * - * @throws ReflectionException */ public function testSeasonalHolidays(): void { @@ -97,8 +91,6 @@ public function testSeasonalHolidays(): void /** * Tests if all bank holidays in Thurgau (Switzerland) are defined by the provider class. - * - * @throws ReflectionException */ public function testBankHolidays(): void { @@ -107,8 +99,6 @@ public function testBankHolidays(): void /** * Tests if all other holidays in Thurgau (Switzerland) are defined by the provider class. - * - * @throws ReflectionException */ public function testOtherHolidays(): void { @@ -117,6 +107,7 @@ public function testOtherHolidays(): void /** * @throws ReflectionException + * @throws \Exception */ public function testSources(): void { diff --git a/tests/Switzerland/Thurgau/WorkersDayTest.php b/tests/Switzerland/Thurgau/WorkersDayTest.php index f01f8926b..f65c71514 100644 --- a/tests/Switzerland/Thurgau/WorkersDayTest.php +++ b/tests/Switzerland/Thurgau/WorkersDayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -39,7 +38,6 @@ class WorkersDayTest extends ThurgauBaseTestCase implements HolidayTestCase * @param int $year the year for which the holiday defined in this test needs to be tested * @param string $expected the expected date * - * @throws ReflectionException * @throws Exception */ public function testHoliday(int $year, string $expected): void @@ -71,7 +69,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -86,7 +84,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Ticino/AllSaintsDayTest.php b/tests/Switzerland/Ticino/AllSaintsDayTest.php index 3495fc29e..91a7196c1 100644 --- a/tests/Switzerland/Ticino/AllSaintsDayTest.php +++ b/tests/Switzerland/Ticino/AllSaintsDayTest.php @@ -16,7 +16,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -37,8 +36,6 @@ class AllSaintsDayTest extends TicinoBaseTestCase implements HolidayTestCase * * @param int $year the year for which All Saints' Day needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testAllSaintsDay(int $year, DateTime $expected): void { @@ -48,7 +45,7 @@ public function testAllSaintsDay(int $year, DateTime $expected): void /** * Tests translated name of All Saints' Day. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -63,7 +60,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Ticino/AscensionDayTest.php b/tests/Switzerland/Ticino/AscensionDayTest.php index e4e23dd8d..1867ea58d 100644 --- a/tests/Switzerland/Ticino/AscensionDayTest.php +++ b/tests/Switzerland/Ticino/AscensionDayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -35,7 +34,6 @@ class AscensionDayTest extends TicinoBaseTestCase implements HolidayTestCase * Tests Ascension Day. * * @throws Exception - * @throws ReflectionException */ public function testAscensionDay(): void { @@ -51,7 +49,7 @@ public function testAscensionDay(): void /** * Tests translated name of Ascension Day. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -66,7 +64,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Ticino/AssumptionOfMaryTest.php b/tests/Switzerland/Ticino/AssumptionOfMaryTest.php index 940f711ad..eedf1144c 100644 --- a/tests/Switzerland/Ticino/AssumptionOfMaryTest.php +++ b/tests/Switzerland/Ticino/AssumptionOfMaryTest.php @@ -16,7 +16,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -37,8 +36,6 @@ class AssumptionOfMaryTest extends TicinoBaseTestCase implements HolidayTestCase * * @param int $year the year for which the day of the Assumption of Mary needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testAssumptionOfMary(int $year, DateTime $expected): void { @@ -48,7 +45,7 @@ public function testAssumptionOfMary(int $year, DateTime $expected): void /** * Tests translated name of the day of the Assumption of Mary. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -63,7 +60,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Ticino/ChristmasDayTest.php b/tests/Switzerland/Ticino/ChristmasDayTest.php index 861d96a92..2e7fb5ed2 100644 --- a/tests/Switzerland/Ticino/ChristmasDayTest.php +++ b/tests/Switzerland/Ticino/ChristmasDayTest.php @@ -16,7 +16,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -37,8 +36,6 @@ class ChristmasDayTest extends TicinoBaseTestCase implements HolidayTestCase * * @param int $year the year for which Christmas Day needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testChristmasDay(int $year, DateTime $expected): void { @@ -60,7 +57,7 @@ public function ChristmasDayDataProvider(): array /** * Tests translated name of Christmas Day. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -75,7 +72,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Ticino/CorpusChristiTest.php b/tests/Switzerland/Ticino/CorpusChristiTest.php index 458d8ffdb..d345a7a0d 100644 --- a/tests/Switzerland/Ticino/CorpusChristiTest.php +++ b/tests/Switzerland/Ticino/CorpusChristiTest.php @@ -16,7 +16,6 @@ use DateInterval; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\Provider\ChristianHolidays; use Yasumi\tests\HolidayTestCase; @@ -37,7 +36,6 @@ class CorpusChristiTest extends TicinoBaseTestCase implements HolidayTestCase * Tests Corpus Christi. * * @throws Exception - * @throws ReflectionException */ public function testCorpusChristi(): void { @@ -53,7 +51,7 @@ public function testCorpusChristi(): void /** * Tests translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -68,7 +66,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Ticino/EasterMondayTest.php b/tests/Switzerland/Ticino/EasterMondayTest.php index dbd42a209..9db726d3a 100644 --- a/tests/Switzerland/Ticino/EasterMondayTest.php +++ b/tests/Switzerland/Ticino/EasterMondayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -35,7 +34,6 @@ class EasterMondayTest extends TicinoBaseTestCase implements HolidayTestCase * Tests Easter Monday. * * @throws Exception - * @throws ReflectionException */ public function testEasterMonday(): void { @@ -51,7 +49,7 @@ public function testEasterMonday(): void /** * Tests translated name of Easter Monday. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -66,7 +64,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Ticino/EpiphanyTest.php b/tests/Switzerland/Ticino/EpiphanyTest.php index f7ee9df0f..9b5e69922 100644 --- a/tests/Switzerland/Ticino/EpiphanyTest.php +++ b/tests/Switzerland/Ticino/EpiphanyTest.php @@ -16,7 +16,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -37,8 +36,6 @@ class EpiphanyTest extends TicinoBaseTestCase implements HolidayTestCase * * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testHoliday(int $year, DateTime $expected): void { @@ -60,7 +57,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -75,7 +72,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Ticino/ImmaculateConceptionTest.php b/tests/Switzerland/Ticino/ImmaculateConceptionTest.php index 613bd96bd..d707c44cb 100644 --- a/tests/Switzerland/Ticino/ImmaculateConceptionTest.php +++ b/tests/Switzerland/Ticino/ImmaculateConceptionTest.php @@ -16,7 +16,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -37,8 +36,6 @@ class ImmaculateConceptionTest extends TicinoBaseTestCase implements HolidayTest * * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testHoliday(int $year, DateTime $expected): void { @@ -60,7 +57,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -75,7 +72,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Ticino/NewYearsDayTest.php b/tests/Switzerland/Ticino/NewYearsDayTest.php index e91d08956..345238ce4 100644 --- a/tests/Switzerland/Ticino/NewYearsDayTest.php +++ b/tests/Switzerland/Ticino/NewYearsDayTest.php @@ -16,7 +16,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -37,8 +36,6 @@ class NewYearsDayTest extends TicinoBaseTestCase implements HolidayTestCase * * @param int $year the year for which New Years Day needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testNewYearsDay(int $year, DateTime $expected): void { @@ -48,7 +45,7 @@ public function testNewYearsDay(int $year, DateTime $expected): void /** * Tests translated name of New Years Day. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -63,7 +60,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Ticino/PentecostMondayTest.php b/tests/Switzerland/Ticino/PentecostMondayTest.php index 0b9d28174..90fd7b218 100644 --- a/tests/Switzerland/Ticino/PentecostMondayTest.php +++ b/tests/Switzerland/Ticino/PentecostMondayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -35,7 +34,6 @@ class PentecostMondayTest extends TicinoBaseTestCase implements HolidayTestCase * Tests Pentecost Monday. * * @throws Exception - * @throws ReflectionException */ public function testPentecostMonday(): void { @@ -51,7 +49,7 @@ public function testPentecostMonday(): void /** * Tests translated name of Pentecost Monday. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -66,7 +64,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Ticino/StJosephDayTest.php b/tests/Switzerland/Ticino/StJosephDayTest.php index 24562f239..0ec537701 100644 --- a/tests/Switzerland/Ticino/StJosephDayTest.php +++ b/tests/Switzerland/Ticino/StJosephDayTest.php @@ -16,7 +16,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\Provider\ChristianHolidays; use Yasumi\tests\HolidayTestCase; @@ -40,8 +39,6 @@ class StJosephDayTest extends TicinoBaseTestCase implements HolidayTestCase * * @param int $year the year for which St. Joseph's Day needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testStJosephDay(int $year, DateTime $expected): void { @@ -63,7 +60,7 @@ public function StJosephDayDataProvider(): array /** * Tests translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -78,7 +75,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Ticino/StPeterPaulTest.php b/tests/Switzerland/Ticino/StPeterPaulTest.php index 80af96580..df595e7b1 100644 --- a/tests/Switzerland/Ticino/StPeterPaulTest.php +++ b/tests/Switzerland/Ticino/StPeterPaulTest.php @@ -16,7 +16,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -37,8 +36,6 @@ class StPeterPaulTest extends TicinoBaseTestCase implements HolidayTestCase * * @param int $year the year for which Feast of Saints Peter and Paul needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testStPeterPaul(int $year, DateTime $expected): void { @@ -60,7 +57,7 @@ public function StPeterPaulDataProvider(): array /** * Tests translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -75,7 +72,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Ticino/StStephensDayTest.php b/tests/Switzerland/Ticino/StStephensDayTest.php index c753c859c..532286355 100644 --- a/tests/Switzerland/Ticino/StStephensDayTest.php +++ b/tests/Switzerland/Ticino/StStephensDayTest.php @@ -16,7 +16,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -37,8 +36,6 @@ class StStephensDayTest extends TicinoBaseTestCase implements HolidayTestCase * * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testHoliday(int $year, DateTime $expected): void { @@ -60,7 +57,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -75,7 +72,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Ticino/TicinoTest.php b/tests/Switzerland/Ticino/TicinoTest.php index 549853f56..18f22380b 100644 --- a/tests/Switzerland/Ticino/TicinoTest.php +++ b/tests/Switzerland/Ticino/TicinoTest.php @@ -26,10 +26,12 @@ class TicinoTest extends TicinoBaseTestCase implements ProviderTestCase /** * @var int year random year number used for all tests in this Test Case */ - protected $year; + protected int $year; /** * Initial setup of this Test Case. + * + * @throws \Exception */ protected function setUp(): void { @@ -38,8 +40,6 @@ protected function setUp(): void /** * Tests if all official holidays in Ticino (Switzerland) are defined by the provider class. - * - * @throws ReflectionException */ public function testOfficialHolidays(): void { @@ -52,8 +52,6 @@ public function testOfficialHolidays(): void /** * Tests if all regional holidays in Ticino (Switzerland) are defined by the provider class. - * - * @throws ReflectionException */ public function testRegionalHolidays(): void { @@ -77,8 +75,6 @@ public function testRegionalHolidays(): void /** * Tests if all observed holidays in Ticino (Switzerland) are defined by the provider class. - * - * @throws ReflectionException */ public function testObservedHolidays(): void { @@ -92,8 +88,6 @@ public function testObservedHolidays(): void /** * Tests if all seasonal holidays in Ticino (Switzerland) are defined by the provider class. - * - * @throws ReflectionException */ public function testSeasonalHolidays(): void { @@ -102,8 +96,6 @@ public function testSeasonalHolidays(): void /** * Tests if all bank holidays in Ticino (Switzerland) are defined by the provider class. - * - * @throws ReflectionException */ public function testBankHolidays(): void { @@ -112,8 +104,6 @@ public function testBankHolidays(): void /** * Tests if all other holidays in Ticino (Switzerland) are defined by the provider class. - * - * @throws ReflectionException */ public function testOtherHolidays(): void { @@ -122,6 +112,7 @@ public function testOtherHolidays(): void /** * @throws ReflectionException + * @throws \Exception */ public function testSources(): void { diff --git a/tests/Switzerland/Ticino/WorkersDayTest.php b/tests/Switzerland/Ticino/WorkersDayTest.php index 3562dd3e6..bba2bf48a 100644 --- a/tests/Switzerland/Ticino/WorkersDayTest.php +++ b/tests/Switzerland/Ticino/WorkersDayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -39,7 +38,6 @@ class WorkersDayTest extends TicinoBaseTestCase implements HolidayTestCase * @param int $year the year for which the holiday defined in this test needs to be tested * @param string $expected the expected date * - * @throws ReflectionException * @throws Exception */ public function testHoliday(int $year, string $expected): void @@ -71,7 +69,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -86,7 +84,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Uri/AllSaintsDayTest.php b/tests/Switzerland/Uri/AllSaintsDayTest.php index 41c7f8ac5..a8372cad6 100644 --- a/tests/Switzerland/Uri/AllSaintsDayTest.php +++ b/tests/Switzerland/Uri/AllSaintsDayTest.php @@ -16,7 +16,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -37,8 +36,6 @@ class AllSaintsDayTest extends UriBaseTestCase implements HolidayTestCase * * @param int $year the year for which All Saints' Day needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testAllSaintsDay(int $year, DateTime $expected): void { @@ -48,7 +45,7 @@ public function testAllSaintsDay(int $year, DateTime $expected): void /** * Tests translated name of All Saints' Day. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -63,7 +60,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Uri/AscensionDayTest.php b/tests/Switzerland/Uri/AscensionDayTest.php index 2b6a2adc2..f9daafea8 100644 --- a/tests/Switzerland/Uri/AscensionDayTest.php +++ b/tests/Switzerland/Uri/AscensionDayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -35,7 +34,6 @@ class AscensionDayTest extends UriBaseTestCase implements HolidayTestCase * Tests Ascension Day. * * @throws Exception - * @throws ReflectionException */ public function testAscensionDay(): void { @@ -51,7 +49,7 @@ public function testAscensionDay(): void /** * Tests translated name of Ascension Day. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -66,7 +64,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Uri/AssumptionOfMaryTest.php b/tests/Switzerland/Uri/AssumptionOfMaryTest.php index 3328befff..9db214b1b 100644 --- a/tests/Switzerland/Uri/AssumptionOfMaryTest.php +++ b/tests/Switzerland/Uri/AssumptionOfMaryTest.php @@ -16,7 +16,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -37,8 +36,6 @@ class AssumptionOfMaryTest extends UriBaseTestCase implements HolidayTestCase * * @param int $year the year for which the day of the Assumption of Mary needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testAssumptionOfMary(int $year, DateTime $expected): void { @@ -48,7 +45,7 @@ public function testAssumptionOfMary(int $year, DateTime $expected): void /** * Tests translated name of the day of the Assumption of Mary. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -63,7 +60,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Uri/ChristmasDayTest.php b/tests/Switzerland/Uri/ChristmasDayTest.php index 128d3814e..c90737c2a 100644 --- a/tests/Switzerland/Uri/ChristmasDayTest.php +++ b/tests/Switzerland/Uri/ChristmasDayTest.php @@ -16,7 +16,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -37,8 +36,6 @@ class ChristmasDayTest extends UriBaseTestCase implements HolidayTestCase * * @param int $year the year for which Christmas Day needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testChristmasDay(int $year, DateTime $expected): void { @@ -60,7 +57,7 @@ public function ChristmasDayDataProvider(): array /** * Tests translated name of Christmas Day. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -75,7 +72,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Uri/CorpusChristiTest.php b/tests/Switzerland/Uri/CorpusChristiTest.php index 0293d9e1e..95fba1201 100644 --- a/tests/Switzerland/Uri/CorpusChristiTest.php +++ b/tests/Switzerland/Uri/CorpusChristiTest.php @@ -16,7 +16,6 @@ use DateInterval; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\Provider\ChristianHolidays; use Yasumi\tests\HolidayTestCase; @@ -37,7 +36,6 @@ class CorpusChristiTest extends UriBaseTestCase implements HolidayTestCase * Tests Corpus Christi. * * @throws Exception - * @throws ReflectionException */ public function testCorpusChristi(): void { @@ -53,7 +51,7 @@ public function testCorpusChristi(): void /** * Tests translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -68,7 +66,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Uri/EasterMondayTest.php b/tests/Switzerland/Uri/EasterMondayTest.php index c2da0431a..24e14025f 100644 --- a/tests/Switzerland/Uri/EasterMondayTest.php +++ b/tests/Switzerland/Uri/EasterMondayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -35,7 +34,6 @@ class EasterMondayTest extends UriBaseTestCase implements HolidayTestCase * Tests Easter Monday. * * @throws Exception - * @throws ReflectionException */ public function testEasterMonday(): void { @@ -51,7 +49,7 @@ public function testEasterMonday(): void /** * Tests translated name of Easter Monday. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -66,7 +64,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Uri/EpiphanyTest.php b/tests/Switzerland/Uri/EpiphanyTest.php index a3ab97aab..88e3d3d24 100644 --- a/tests/Switzerland/Uri/EpiphanyTest.php +++ b/tests/Switzerland/Uri/EpiphanyTest.php @@ -16,7 +16,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -37,8 +36,6 @@ class EpiphanyTest extends UriBaseTestCase implements HolidayTestCase * * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testHoliday(int $year, DateTime $expected): void { @@ -60,7 +57,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -75,7 +72,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Uri/GoodFridayTest.php b/tests/Switzerland/Uri/GoodFridayTest.php index 66dbdf721..f27e9418b 100644 --- a/tests/Switzerland/Uri/GoodFridayTest.php +++ b/tests/Switzerland/Uri/GoodFridayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -35,7 +34,6 @@ class GoodFridayTest extends UriBaseTestCase implements HolidayTestCase * Tests the holiday defined in this test. * * @throws Exception - * @throws ReflectionException */ public function testHoliday(): void { @@ -51,7 +49,7 @@ public function testHoliday(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -66,7 +64,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Uri/ImmaculateConceptionTest.php b/tests/Switzerland/Uri/ImmaculateConceptionTest.php index 565cfeaca..1a1ce7351 100644 --- a/tests/Switzerland/Uri/ImmaculateConceptionTest.php +++ b/tests/Switzerland/Uri/ImmaculateConceptionTest.php @@ -16,7 +16,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -37,8 +36,6 @@ class ImmaculateConceptionTest extends UriBaseTestCase implements HolidayTestCas * * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testHoliday(int $year, DateTime $expected): void { @@ -60,7 +57,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -75,7 +72,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Uri/NewYearsDayTest.php b/tests/Switzerland/Uri/NewYearsDayTest.php index 2c96268e6..1d241eeee 100644 --- a/tests/Switzerland/Uri/NewYearsDayTest.php +++ b/tests/Switzerland/Uri/NewYearsDayTest.php @@ -16,7 +16,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -37,8 +36,6 @@ class NewYearsDayTest extends UriBaseTestCase implements HolidayTestCase * * @param int $year the year for which New Years Day needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testNewYearsDay(int $year, DateTime $expected): void { @@ -48,7 +45,7 @@ public function testNewYearsDay(int $year, DateTime $expected): void /** * Tests translated name of New Years Day. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -63,7 +60,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Uri/PentecostMondayTest.php b/tests/Switzerland/Uri/PentecostMondayTest.php index 56dc947a3..6203a26c4 100644 --- a/tests/Switzerland/Uri/PentecostMondayTest.php +++ b/tests/Switzerland/Uri/PentecostMondayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -35,7 +34,6 @@ class PentecostMondayTest extends UriBaseTestCase implements HolidayTestCase * Tests Pentecost Monday. * * @throws Exception - * @throws ReflectionException */ public function testPentecostMonday(): void { @@ -51,7 +49,7 @@ public function testPentecostMonday(): void /** * Tests translated name of Pentecost Monday. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -66,7 +64,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Uri/StJosephDayTest.php b/tests/Switzerland/Uri/StJosephDayTest.php index 15527ccfd..ef1247487 100644 --- a/tests/Switzerland/Uri/StJosephDayTest.php +++ b/tests/Switzerland/Uri/StJosephDayTest.php @@ -16,7 +16,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\Provider\ChristianHolidays; use Yasumi\tests\HolidayTestCase; @@ -40,8 +39,6 @@ class StJosephDayTest extends UriBaseTestCase implements HolidayTestCase * * @param int $year the year for which St. Joseph's Day needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testStJosephDay(int $year, DateTime $expected): void { @@ -63,7 +60,7 @@ public function StJosephDayDataProvider(): array /** * Tests translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -78,7 +75,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Uri/StStephensDayTest.php b/tests/Switzerland/Uri/StStephensDayTest.php index c24a86761..4e52a9858 100644 --- a/tests/Switzerland/Uri/StStephensDayTest.php +++ b/tests/Switzerland/Uri/StStephensDayTest.php @@ -16,7 +16,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -37,8 +36,6 @@ class StStephensDayTest extends UriBaseTestCase implements HolidayTestCase * * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testHoliday(int $year, DateTime $expected): void { @@ -60,7 +57,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -75,7 +72,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Uri/UriTest.php b/tests/Switzerland/Uri/UriTest.php index 491aebf1c..b6b9882f0 100644 --- a/tests/Switzerland/Uri/UriTest.php +++ b/tests/Switzerland/Uri/UriTest.php @@ -26,10 +26,12 @@ class UriTest extends UriBaseTestCase implements ProviderTestCase /** * @var int year random year number used for all tests in this Test Case */ - protected $year; + protected int $year; /** * Initial setup of this Test Case. + * + * @throws \Exception */ protected function setUp(): void { @@ -38,8 +40,6 @@ protected function setUp(): void /** * Tests if all official holidays in Uri (Switzerland) are defined by the provider class. - * - * @throws ReflectionException */ public function testOfficialHolidays(): void { @@ -52,8 +52,6 @@ public function testOfficialHolidays(): void /** * Tests if all regional holidays in Uri (Switzerland) are defined by the provider class. - * - * @throws ReflectionException */ public function testRegionalHolidays(): void { @@ -76,8 +74,6 @@ public function testRegionalHolidays(): void /** * Tests if all observed holidays in Uri (Switzerland) are defined by the provider class. - * - * @throws ReflectionException */ public function testObservedHolidays(): void { @@ -91,8 +87,6 @@ public function testObservedHolidays(): void /** * Tests if all seasonal holidays in Uri (Switzerland) are defined by the provider class. - * - * @throws ReflectionException */ public function testSeasonalHolidays(): void { @@ -101,8 +95,6 @@ public function testSeasonalHolidays(): void /** * Tests if all bank holidays in Uri (Switzerland) are defined by the provider class. - * - * @throws ReflectionException */ public function testBankHolidays(): void { @@ -111,8 +103,6 @@ public function testBankHolidays(): void /** * Tests if all other holidays in Uri (Switzerland) are defined by the provider class. - * - * @throws ReflectionException */ public function testOtherHolidays(): void { @@ -121,6 +111,7 @@ public function testOtherHolidays(): void /** * @throws ReflectionException + * @throws \Exception */ public function testSources(): void { diff --git a/tests/Switzerland/Valais/AllSaintsDayTest.php b/tests/Switzerland/Valais/AllSaintsDayTest.php index 4d4afebde..8e65a2e6a 100644 --- a/tests/Switzerland/Valais/AllSaintsDayTest.php +++ b/tests/Switzerland/Valais/AllSaintsDayTest.php @@ -16,7 +16,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -37,8 +36,6 @@ class AllSaintsDayTest extends ValaisBaseTestCase implements HolidayTestCase * * @param int $year the year for which All Saints' Day needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testAllSaintsDay(int $year, DateTime $expected): void { @@ -48,7 +45,7 @@ public function testAllSaintsDay(int $year, DateTime $expected): void /** * Tests translated name of All Saints' Day. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -63,7 +60,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Valais/AscensionDayTest.php b/tests/Switzerland/Valais/AscensionDayTest.php index c9c0accd0..247a38047 100644 --- a/tests/Switzerland/Valais/AscensionDayTest.php +++ b/tests/Switzerland/Valais/AscensionDayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -35,7 +34,6 @@ class AscensionDayTest extends ValaisBaseTestCase implements HolidayTestCase * Tests Ascension Day. * * @throws Exception - * @throws ReflectionException */ public function testAscensionDay(): void { @@ -51,7 +49,7 @@ public function testAscensionDay(): void /** * Tests translated name of Ascension Day. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -66,7 +64,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Valais/AssumptionOfMaryTest.php b/tests/Switzerland/Valais/AssumptionOfMaryTest.php index 7caa0c699..80331eac5 100644 --- a/tests/Switzerland/Valais/AssumptionOfMaryTest.php +++ b/tests/Switzerland/Valais/AssumptionOfMaryTest.php @@ -16,7 +16,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -37,8 +36,6 @@ class AssumptionOfMaryTest extends ValaisBaseTestCase implements HolidayTestCase * * @param int $year the year for which the day of the Assumption of Mary needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testAssumptionOfMary(int $year, DateTime $expected): void { @@ -48,7 +45,7 @@ public function testAssumptionOfMary(int $year, DateTime $expected): void /** * Tests translated name of the day of the Assumption of Mary. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -63,7 +60,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Valais/ChristmasDayTest.php b/tests/Switzerland/Valais/ChristmasDayTest.php index 3f6aff06f..42683bc37 100644 --- a/tests/Switzerland/Valais/ChristmasDayTest.php +++ b/tests/Switzerland/Valais/ChristmasDayTest.php @@ -16,7 +16,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -37,8 +36,6 @@ class ChristmasDayTest extends ValaisBaseTestCase implements HolidayTestCase * * @param int $year the year for which Christmas Day needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testChristmasDay(int $year, DateTime $expected): void { @@ -60,7 +57,7 @@ public function ChristmasDayDataProvider(): array /** * Tests translated name of Christmas Day. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -75,7 +72,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Valais/CorpusChristiTest.php b/tests/Switzerland/Valais/CorpusChristiTest.php index 3d73b2672..84f2c7bdd 100644 --- a/tests/Switzerland/Valais/CorpusChristiTest.php +++ b/tests/Switzerland/Valais/CorpusChristiTest.php @@ -16,7 +16,6 @@ use DateInterval; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\Provider\ChristianHolidays; use Yasumi\tests\HolidayTestCase; @@ -37,7 +36,6 @@ class CorpusChristiTest extends ValaisBaseTestCase implements HolidayTestCase * Tests Corpus Christi. * * @throws Exception - * @throws ReflectionException */ public function testCorpusChristi(): void { @@ -53,7 +51,7 @@ public function testCorpusChristi(): void /** * Tests translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -68,7 +66,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Valais/ImmaculateConceptionTest.php b/tests/Switzerland/Valais/ImmaculateConceptionTest.php index db7bde5d0..2e6167448 100644 --- a/tests/Switzerland/Valais/ImmaculateConceptionTest.php +++ b/tests/Switzerland/Valais/ImmaculateConceptionTest.php @@ -16,7 +16,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -37,8 +36,6 @@ class ImmaculateConceptionTest extends ValaisBaseTestCase implements HolidayTest * * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testHoliday(int $year, DateTime $expected): void { @@ -60,7 +57,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -75,7 +72,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Valais/NewYearsDayTest.php b/tests/Switzerland/Valais/NewYearsDayTest.php index 0a6dc8dbb..2209567b2 100644 --- a/tests/Switzerland/Valais/NewYearsDayTest.php +++ b/tests/Switzerland/Valais/NewYearsDayTest.php @@ -16,7 +16,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -37,8 +36,6 @@ class NewYearsDayTest extends ValaisBaseTestCase implements HolidayTestCase * * @param int $year the year for which New Years Day needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testNewYearsDay(int $year, DateTime $expected): void { @@ -48,7 +45,7 @@ public function testNewYearsDay(int $year, DateTime $expected): void /** * Tests translated name of New Years Day. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -63,7 +60,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Valais/StJosephDayTest.php b/tests/Switzerland/Valais/StJosephDayTest.php index 0df7761f6..c385e900a 100644 --- a/tests/Switzerland/Valais/StJosephDayTest.php +++ b/tests/Switzerland/Valais/StJosephDayTest.php @@ -16,7 +16,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\Provider\ChristianHolidays; use Yasumi\tests\HolidayTestCase; @@ -40,8 +39,6 @@ class StJosephDayTest extends ValaisBaseTestCase implements HolidayTestCase * * @param int $year the year for which St. Joseph's Day needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testStJosephDay(int $year, DateTime $expected): void { @@ -63,7 +60,7 @@ public function StJosephDayDataProvider(): array /** * Tests translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -78,7 +75,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Valais/ValaisTest.php b/tests/Switzerland/Valais/ValaisTest.php index 3d7199e3e..ff3f3bac8 100644 --- a/tests/Switzerland/Valais/ValaisTest.php +++ b/tests/Switzerland/Valais/ValaisTest.php @@ -26,10 +26,12 @@ class ValaisTest extends ValaisBaseTestCase implements ProviderTestCase /** * @var int year random year number used for all tests in this Test Case */ - protected $year; + protected int $year; /** * Initial setup of this Test Case. + * + * @throws \Exception */ protected function setUp(): void { @@ -38,8 +40,6 @@ protected function setUp(): void /** * Tests if all official holidays in Valais (Switzerland) are defined by the provider class. - * - * @throws ReflectionException */ public function testOfficialHolidays(): void { @@ -52,8 +52,6 @@ public function testOfficialHolidays(): void /** * Tests if all regional holidays in Valais (Switzerland) are defined by the provider class. - * - * @throws ReflectionException */ public function testRegionalHolidays(): void { @@ -71,8 +69,6 @@ public function testRegionalHolidays(): void /** * Tests if all observed holidays in Valais (Switzerland) are defined by the provider class. - * - * @throws ReflectionException */ public function testObservedHolidays(): void { @@ -86,8 +82,6 @@ public function testObservedHolidays(): void /** * Tests if all seasonal holidays in Valais (Switzerland) are defined by the provider class. - * - * @throws ReflectionException */ public function testSeasonalHolidays(): void { @@ -96,8 +90,6 @@ public function testSeasonalHolidays(): void /** * Tests if all bank holidays in Valais (Switzerland) are defined by the provider class. - * - * @throws ReflectionException */ public function testBankHolidays(): void { @@ -106,8 +98,6 @@ public function testBankHolidays(): void /** * Tests if all other holidays in Valais (Switzerland) are defined by the provider class. - * - * @throws ReflectionException */ public function testOtherHolidays(): void { @@ -116,6 +106,7 @@ public function testOtherHolidays(): void /** * @throws ReflectionException + * @throws \Exception */ public function testSources(): void { diff --git a/tests/Switzerland/Vaud/AscensionDayTest.php b/tests/Switzerland/Vaud/AscensionDayTest.php index 6a033fcfb..7a5d17893 100644 --- a/tests/Switzerland/Vaud/AscensionDayTest.php +++ b/tests/Switzerland/Vaud/AscensionDayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -35,7 +34,6 @@ class AscensionDayTest extends VaudBaseTestCase implements HolidayTestCase * Tests Ascension Day. * * @throws Exception - * @throws ReflectionException */ public function testAscensionDay(): void { @@ -51,7 +49,7 @@ public function testAscensionDay(): void /** * Tests translated name of Ascension Day. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -66,7 +64,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Vaud/BerchtoldsTagTest.php b/tests/Switzerland/Vaud/BerchtoldsTagTest.php index 3b2b066df..d579d136a 100644 --- a/tests/Switzerland/Vaud/BerchtoldsTagTest.php +++ b/tests/Switzerland/Vaud/BerchtoldsTagTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,7 +33,6 @@ class BerchtoldsTagTest extends VaudBaseTestCase implements HolidayTestCase /** * Tests BerchtoldsTag. * - * @throws ReflectionException * @throws Exception */ public function testBerchtoldsTag(): void @@ -49,7 +47,7 @@ public function testBerchtoldsTag(): void /** * Tests translated name of BerchtoldsTag. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -64,7 +62,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Vaud/BettagsMontagTest.php b/tests/Switzerland/Vaud/BettagsMontagTest.php index 91683f0f6..191983a7b 100644 --- a/tests/Switzerland/Vaud/BettagsMontagTest.php +++ b/tests/Switzerland/Vaud/BettagsMontagTest.php @@ -18,7 +18,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -35,7 +34,6 @@ class BettagsMontagTest extends VaudBaseTestCase implements HolidayTestCase /** * Tests Bettags Montag on or after 1832. * - * @throws ReflectionException * @throws Exception */ public function testBettagsMontagOnAfter1832(): void @@ -53,7 +51,7 @@ public function testBettagsMontagOnAfter1832(): void /** * Tests Bettags Montag before 1832. * - * @throws ReflectionException + * @throws Exception */ public function testBettagsMontagBefore1832(): void { @@ -64,7 +62,7 @@ public function testBettagsMontagBefore1832(): void /** * Tests translated name of Bettags Montag. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -79,7 +77,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Vaud/ChristmasDayTest.php b/tests/Switzerland/Vaud/ChristmasDayTest.php index 4d5a2c1de..b4cbad386 100644 --- a/tests/Switzerland/Vaud/ChristmasDayTest.php +++ b/tests/Switzerland/Vaud/ChristmasDayTest.php @@ -16,7 +16,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -37,8 +36,6 @@ class ChristmasDayTest extends VaudBaseTestCase implements HolidayTestCase * * @param int $year the year for which Christmas Day needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testChristmasDay(int $year, DateTime $expected): void { @@ -60,7 +57,7 @@ public function ChristmasDayDataProvider(): array /** * Tests translated name of Christmas Day. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -75,7 +72,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Vaud/EasterMondayTest.php b/tests/Switzerland/Vaud/EasterMondayTest.php index 482b041c2..1c8296a26 100644 --- a/tests/Switzerland/Vaud/EasterMondayTest.php +++ b/tests/Switzerland/Vaud/EasterMondayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -35,7 +34,6 @@ class EasterMondayTest extends VaudBaseTestCase implements HolidayTestCase * Tests Easter Monday. * * @throws Exception - * @throws ReflectionException */ public function testEasterMonday(): void { @@ -51,7 +49,7 @@ public function testEasterMonday(): void /** * Tests translated name of Easter Monday. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -66,7 +64,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Vaud/GoodFridayTest.php b/tests/Switzerland/Vaud/GoodFridayTest.php index 16ea9b198..a50740efd 100644 --- a/tests/Switzerland/Vaud/GoodFridayTest.php +++ b/tests/Switzerland/Vaud/GoodFridayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -35,7 +34,6 @@ class GoodFridayTest extends VaudBaseTestCase implements HolidayTestCase * Tests the holiday defined in this test. * * @throws Exception - * @throws ReflectionException */ public function testHoliday(): void { @@ -51,7 +49,7 @@ public function testHoliday(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -66,7 +64,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Vaud/NewYearsDayTest.php b/tests/Switzerland/Vaud/NewYearsDayTest.php index 859a9f2e5..36f21f89c 100644 --- a/tests/Switzerland/Vaud/NewYearsDayTest.php +++ b/tests/Switzerland/Vaud/NewYearsDayTest.php @@ -16,7 +16,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -37,8 +36,6 @@ class NewYearsDayTest extends VaudBaseTestCase implements HolidayTestCase * * @param int $year the year for which New Years Day needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testNewYearsDay(int $year, DateTime $expected): void { @@ -48,7 +45,7 @@ public function testNewYearsDay(int $year, DateTime $expected): void /** * Tests translated name of New Years Day. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -63,7 +60,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Vaud/PentecostMondayTest.php b/tests/Switzerland/Vaud/PentecostMondayTest.php index b114c71fa..ab5f4fbc6 100644 --- a/tests/Switzerland/Vaud/PentecostMondayTest.php +++ b/tests/Switzerland/Vaud/PentecostMondayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -35,7 +34,6 @@ class PentecostMondayTest extends VaudBaseTestCase implements HolidayTestCase * Tests Pentecost Monday. * * @throws Exception - * @throws ReflectionException */ public function testPentecostMonday(): void { @@ -51,7 +49,7 @@ public function testPentecostMonday(): void /** * Tests translated name of Pentecost Monday. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -66,7 +64,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Vaud/VaudTest.php b/tests/Switzerland/Vaud/VaudTest.php index 76cbe97bd..c6a1f36bc 100644 --- a/tests/Switzerland/Vaud/VaudTest.php +++ b/tests/Switzerland/Vaud/VaudTest.php @@ -26,10 +26,12 @@ class VaudTest extends VaudBaseTestCase implements ProviderTestCase /** * @var int year random year number used for all tests in this Test Case */ - protected $year; + protected int $year; /** * Initial setup of this Test Case. + * + * @throws \Exception */ protected function setUp(): void { @@ -38,8 +40,6 @@ protected function setUp(): void /** * Tests if all official holidays in Vaud (Switzerland) are defined by the provider class. - * - * @throws ReflectionException */ public function testOfficialHolidays(): void { @@ -52,8 +52,6 @@ public function testOfficialHolidays(): void /** * Tests if all regional holidays in Vaud (Switzerland) are defined by the provider class. - * - * @throws ReflectionException */ public function testRegionalHolidays(): void { @@ -71,8 +69,6 @@ public function testRegionalHolidays(): void /** * Tests if all observed holidays in Vaud (Switzerland) are defined by the provider class. - * - * @throws ReflectionException */ public function testObservedHolidays(): void { @@ -86,8 +82,6 @@ public function testObservedHolidays(): void /** * Tests if all seasonal holidays in Vaud (Switzerland) are defined by the provider class. - * - * @throws ReflectionException */ public function testSeasonalHolidays(): void { @@ -96,8 +90,6 @@ public function testSeasonalHolidays(): void /** * Tests if all bank holidays in Vaud (Switzerland) are defined by the provider class. - * - * @throws ReflectionException */ public function testBankHolidays(): void { @@ -106,8 +98,6 @@ public function testBankHolidays(): void /** * Tests if all other holidays in Vaud (Switzerland) are defined by the provider class. - * - * @throws ReflectionException */ public function testOtherHolidays(): void { @@ -116,6 +106,7 @@ public function testOtherHolidays(): void /** * @throws ReflectionException + * @throws \Exception */ public function testSources(): void { diff --git a/tests/Switzerland/Zug/AllSaintsDayTest.php b/tests/Switzerland/Zug/AllSaintsDayTest.php index 09b360dba..08de7d99d 100644 --- a/tests/Switzerland/Zug/AllSaintsDayTest.php +++ b/tests/Switzerland/Zug/AllSaintsDayTest.php @@ -16,7 +16,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -37,8 +36,6 @@ class AllSaintsDayTest extends ZugBaseTestCase implements HolidayTestCase * * @param int $year the year for which All Saints' Day needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testAllSaintsDay(int $year, DateTime $expected): void { @@ -48,7 +45,7 @@ public function testAllSaintsDay(int $year, DateTime $expected): void /** * Tests translated name of All Saints' Day. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -63,7 +60,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Zug/AscensionDayTest.php b/tests/Switzerland/Zug/AscensionDayTest.php index 01a2e35a7..b302d214a 100644 --- a/tests/Switzerland/Zug/AscensionDayTest.php +++ b/tests/Switzerland/Zug/AscensionDayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -35,7 +34,6 @@ class AscensionDayTest extends ZugBaseTestCase implements HolidayTestCase * Tests Ascension Day. * * @throws Exception - * @throws ReflectionException */ public function testAscensionDay(): void { @@ -51,7 +49,7 @@ public function testAscensionDay(): void /** * Tests translated name of Ascension Day. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -66,7 +64,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Zug/AssumptionOfMaryTest.php b/tests/Switzerland/Zug/AssumptionOfMaryTest.php index debe5c3e4..5c44ef067 100644 --- a/tests/Switzerland/Zug/AssumptionOfMaryTest.php +++ b/tests/Switzerland/Zug/AssumptionOfMaryTest.php @@ -16,7 +16,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -37,8 +36,6 @@ class AssumptionOfMaryTest extends ZugBaseTestCase implements HolidayTestCase * * @param int $year the year for which the day of the Assumption of Mary needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testAssumptionOfMary(int $year, DateTime $expected): void { @@ -48,7 +45,7 @@ public function testAssumptionOfMary(int $year, DateTime $expected): void /** * Tests translated name of the day of the Assumption of Mary. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -63,7 +60,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Zug/BerchtoldsTagTest.php b/tests/Switzerland/Zug/BerchtoldsTagTest.php index 0e21d1409..6aa48e330 100644 --- a/tests/Switzerland/Zug/BerchtoldsTagTest.php +++ b/tests/Switzerland/Zug/BerchtoldsTagTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,7 +33,6 @@ class BerchtoldsTagTest extends ZugBaseTestCase implements HolidayTestCase /** * Tests BerchtoldsTag. * - * @throws ReflectionException * @throws Exception */ public function testBerchtoldsTag(): void @@ -49,7 +47,7 @@ public function testBerchtoldsTag(): void /** * Tests translated name of BerchtoldsTag. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -64,7 +62,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Zug/ChristmasDayTest.php b/tests/Switzerland/Zug/ChristmasDayTest.php index 0ecd66210..a4db02be6 100644 --- a/tests/Switzerland/Zug/ChristmasDayTest.php +++ b/tests/Switzerland/Zug/ChristmasDayTest.php @@ -16,7 +16,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -37,8 +36,6 @@ class ChristmasDayTest extends ZugBaseTestCase implements HolidayTestCase * * @param int $year the year for which Christmas Day needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testChristmasDay(int $year, DateTime $expected): void { @@ -60,7 +57,7 @@ public function ChristmasDayDataProvider(): array /** * Tests translated name of Christmas Day. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -75,7 +72,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Zug/CorpusChristiTest.php b/tests/Switzerland/Zug/CorpusChristiTest.php index 07687af9e..d1d83cb20 100644 --- a/tests/Switzerland/Zug/CorpusChristiTest.php +++ b/tests/Switzerland/Zug/CorpusChristiTest.php @@ -16,7 +16,6 @@ use DateInterval; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\Provider\ChristianHolidays; use Yasumi\tests\HolidayTestCase; @@ -37,7 +36,6 @@ class CorpusChristiTest extends ZugBaseTestCase implements HolidayTestCase * Tests Corpus Christi. * * @throws Exception - * @throws ReflectionException */ public function testCorpusChristi(): void { @@ -53,7 +51,7 @@ public function testCorpusChristi(): void /** * Tests translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -68,7 +66,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Zug/EasterMondayTest.php b/tests/Switzerland/Zug/EasterMondayTest.php index 155dcac3b..54dec7651 100644 --- a/tests/Switzerland/Zug/EasterMondayTest.php +++ b/tests/Switzerland/Zug/EasterMondayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -35,7 +34,6 @@ class EasterMondayTest extends ZugBaseTestCase implements HolidayTestCase * Tests Easter Monday. * * @throws Exception - * @throws ReflectionException */ public function testEasterMonday(): void { @@ -51,7 +49,7 @@ public function testEasterMonday(): void /** * Tests translated name of Easter Monday. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -66,7 +64,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Zug/GoodFridayTest.php b/tests/Switzerland/Zug/GoodFridayTest.php index 285cb82a8..908868ac9 100644 --- a/tests/Switzerland/Zug/GoodFridayTest.php +++ b/tests/Switzerland/Zug/GoodFridayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -35,7 +34,6 @@ class GoodFridayTest extends ZugBaseTestCase implements HolidayTestCase * Tests the holiday defined in this test. * * @throws Exception - * @throws ReflectionException */ public function testHoliday(): void { @@ -51,7 +49,7 @@ public function testHoliday(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -66,7 +64,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Zug/ImmaculateConceptionTest.php b/tests/Switzerland/Zug/ImmaculateConceptionTest.php index ac2cd7d1a..0247e06ca 100644 --- a/tests/Switzerland/Zug/ImmaculateConceptionTest.php +++ b/tests/Switzerland/Zug/ImmaculateConceptionTest.php @@ -16,7 +16,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -37,8 +36,6 @@ class ImmaculateConceptionTest extends ZugBaseTestCase implements HolidayTestCas * * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testHoliday(int $year, DateTime $expected): void { @@ -60,7 +57,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -75,7 +72,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Zug/NewYearsDayTest.php b/tests/Switzerland/Zug/NewYearsDayTest.php index 4bbefbfac..0b254e59b 100644 --- a/tests/Switzerland/Zug/NewYearsDayTest.php +++ b/tests/Switzerland/Zug/NewYearsDayTest.php @@ -16,7 +16,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -37,8 +36,6 @@ class NewYearsDayTest extends ZugBaseTestCase implements HolidayTestCase * * @param int $year the year for which New Years Day needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testNewYearsDay(int $year, DateTime $expected): void { @@ -48,7 +45,7 @@ public function testNewYearsDay(int $year, DateTime $expected): void /** * Tests translated name of New Years Day. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -63,7 +60,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Zug/PentecostMondayTest.php b/tests/Switzerland/Zug/PentecostMondayTest.php index 51b48e677..c096f9cc0 100644 --- a/tests/Switzerland/Zug/PentecostMondayTest.php +++ b/tests/Switzerland/Zug/PentecostMondayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -35,7 +34,6 @@ class PentecostMondayTest extends ZugBaseTestCase implements HolidayTestCase * Tests Pentecost Monday. * * @throws Exception - * @throws ReflectionException */ public function testPentecostMonday(): void { @@ -51,7 +49,7 @@ public function testPentecostMonday(): void /** * Tests translated name of Pentecost Monday. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -66,7 +64,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Zug/StStephensDayTest.php b/tests/Switzerland/Zug/StStephensDayTest.php index 2f0e0a4cd..6f7bbbe3a 100644 --- a/tests/Switzerland/Zug/StStephensDayTest.php +++ b/tests/Switzerland/Zug/StStephensDayTest.php @@ -16,7 +16,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -37,8 +36,6 @@ class StStephensDayTest extends ZugBaseTestCase implements HolidayTestCase * * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testHoliday(int $year, DateTime $expected): void { @@ -60,7 +57,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -75,7 +72,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Zug/ZugTest.php b/tests/Switzerland/Zug/ZugTest.php index 007de3982..a5c3822c9 100644 --- a/tests/Switzerland/Zug/ZugTest.php +++ b/tests/Switzerland/Zug/ZugTest.php @@ -26,10 +26,12 @@ class ZugTest extends ZugBaseTestCase implements ProviderTestCase /** * @var int year random year number used for all tests in this Test Case */ - protected $year; + protected int $year; /** * Initial setup of this Test Case. + * + * @throws \Exception */ protected function setUp(): void { @@ -38,8 +40,6 @@ protected function setUp(): void /** * Tests if all official holidays in Zug (Switzerland) are defined by the provider class. - * - * @throws ReflectionException */ public function testOfficialHolidays(): void { @@ -52,8 +52,6 @@ public function testOfficialHolidays(): void /** * Tests if all regional holidays in Zug (Switzerland) are defined by the provider class. - * - * @throws ReflectionException */ public function testRegionalHolidays(): void { @@ -75,8 +73,6 @@ public function testRegionalHolidays(): void /** * Tests if all observed holidays in Zug (Switzerland) are defined by the provider class. - * - * @throws ReflectionException */ public function testObservedHolidays(): void { @@ -90,8 +86,6 @@ public function testObservedHolidays(): void /** * Tests if all seasonal holidays in Zug (Switzerland) are defined by the provider class. - * - * @throws ReflectionException */ public function testSeasonalHolidays(): void { @@ -100,8 +94,6 @@ public function testSeasonalHolidays(): void /** * Tests if all bank holidays in Zug (Switzerland) are defined by the provider class. - * - * @throws ReflectionException */ public function testBankHolidays(): void { @@ -110,8 +102,6 @@ public function testBankHolidays(): void /** * Tests if all other holidays in Zug (Switzerland) are defined by the provider class. - * - * @throws ReflectionException */ public function testOtherHolidays(): void { @@ -120,6 +110,7 @@ public function testOtherHolidays(): void /** * @throws ReflectionException + * @throws \Exception */ public function testSources(): void { diff --git a/tests/Switzerland/Zurich/AscensionDayTest.php b/tests/Switzerland/Zurich/AscensionDayTest.php index d4eb92dae..482052bb8 100644 --- a/tests/Switzerland/Zurich/AscensionDayTest.php +++ b/tests/Switzerland/Zurich/AscensionDayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -35,7 +34,6 @@ class AscensionDayTest extends ZurichBaseTestCase implements HolidayTestCase * Tests Ascension Day. * * @throws Exception - * @throws ReflectionException */ public function testAscensionDay(): void { @@ -51,7 +49,7 @@ public function testAscensionDay(): void /** * Tests translated name of Ascension Day. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -66,7 +64,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Zurich/ChristmasDayTest.php b/tests/Switzerland/Zurich/ChristmasDayTest.php index 6b5d8c464..9866f263a 100644 --- a/tests/Switzerland/Zurich/ChristmasDayTest.php +++ b/tests/Switzerland/Zurich/ChristmasDayTest.php @@ -16,7 +16,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -37,8 +36,6 @@ class ChristmasDayTest extends ZurichBaseTestCase implements HolidayTestCase * * @param int $year the year for which Christmas Day needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testChristmasDay(int $year, DateTime $expected): void { @@ -60,7 +57,7 @@ public function ChristmasDayDataProvider(): array /** * Tests translated name of Christmas Day. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -75,7 +72,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Zurich/EasterMondayTest.php b/tests/Switzerland/Zurich/EasterMondayTest.php index 56d99ee15..ef2d00989 100644 --- a/tests/Switzerland/Zurich/EasterMondayTest.php +++ b/tests/Switzerland/Zurich/EasterMondayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -35,7 +34,6 @@ class EasterMondayTest extends ZurichBaseTestCase implements HolidayTestCase * Tests Easter Monday. * * @throws Exception - * @throws ReflectionException */ public function testEasterMonday(): void { @@ -51,7 +49,7 @@ public function testEasterMonday(): void /** * Tests translated name of Easter Monday. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -66,7 +64,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Zurich/GoodFridayTest.php b/tests/Switzerland/Zurich/GoodFridayTest.php index 6fd945738..a599f9b93 100644 --- a/tests/Switzerland/Zurich/GoodFridayTest.php +++ b/tests/Switzerland/Zurich/GoodFridayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -35,7 +34,6 @@ class GoodFridayTest extends ZurichBaseTestCase implements HolidayTestCase * Tests the holiday defined in this test. * * @throws Exception - * @throws ReflectionException */ public function testHoliday(): void { @@ -51,7 +49,7 @@ public function testHoliday(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -66,7 +64,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Zurich/NewYearsDayTest.php b/tests/Switzerland/Zurich/NewYearsDayTest.php index 46568c6ba..d3603237c 100644 --- a/tests/Switzerland/Zurich/NewYearsDayTest.php +++ b/tests/Switzerland/Zurich/NewYearsDayTest.php @@ -16,7 +16,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -37,8 +36,6 @@ class NewYearsDayTest extends ZurichBaseTestCase implements HolidayTestCase * * @param int $year the year for which New Years Day needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testNewYearsDay(int $year, DateTime $expected): void { @@ -48,7 +45,7 @@ public function testNewYearsDay(int $year, DateTime $expected): void /** * Tests translated name of New Years Day. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -63,7 +60,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Zurich/PentecostMondayTest.php b/tests/Switzerland/Zurich/PentecostMondayTest.php index 4b43eb833..94c642bde 100644 --- a/tests/Switzerland/Zurich/PentecostMondayTest.php +++ b/tests/Switzerland/Zurich/PentecostMondayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -35,7 +34,6 @@ class PentecostMondayTest extends ZurichBaseTestCase implements HolidayTestCase * Tests Pentecost Monday. * * @throws Exception - * @throws ReflectionException */ public function testPentecostMonday(): void { @@ -51,7 +49,7 @@ public function testPentecostMonday(): void /** * Tests translated name of Pentecost Monday. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -66,7 +64,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Zurich/StStephensDayTest.php b/tests/Switzerland/Zurich/StStephensDayTest.php index 426b0dd45..23748f3a6 100644 --- a/tests/Switzerland/Zurich/StStephensDayTest.php +++ b/tests/Switzerland/Zurich/StStephensDayTest.php @@ -16,7 +16,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -37,8 +36,6 @@ class StStephensDayTest extends ZurichBaseTestCase implements HolidayTestCase * * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testHoliday(int $year, DateTime $expected): void { @@ -60,7 +57,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -75,7 +72,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Zurich/WorkersDayTest.php b/tests/Switzerland/Zurich/WorkersDayTest.php index 3ca643dc4..e858ad7b2 100644 --- a/tests/Switzerland/Zurich/WorkersDayTest.php +++ b/tests/Switzerland/Zurich/WorkersDayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -39,7 +38,6 @@ class WorkersDayTest extends ZurichBaseTestCase implements HolidayTestCase * @param int $year the year for which the holiday defined in this test needs to be tested * @param string $expected the expected date * - * @throws ReflectionException * @throws Exception */ public function testHoliday(int $year, string $expected): void @@ -71,7 +69,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -86,7 +84,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Zurich/ZurichTest.php b/tests/Switzerland/Zurich/ZurichTest.php index 69aa7d830..d0524262a 100644 --- a/tests/Switzerland/Zurich/ZurichTest.php +++ b/tests/Switzerland/Zurich/ZurichTest.php @@ -26,10 +26,12 @@ class ZurichTest extends ZurichBaseTestCase implements ProviderTestCase /** * @var int year random year number used for all tests in this Test Case */ - protected $year; + protected int $year; /** * Initial setup of this Test Case. + * + * @throws \Exception */ protected function setUp(): void { @@ -38,8 +40,6 @@ protected function setUp(): void /** * Tests if all official holidays in Zurich (Switzerland) are defined by the provider class. - * - * @throws ReflectionException */ public function testOfficialHolidays(): void { @@ -52,8 +52,6 @@ public function testOfficialHolidays(): void /** * Tests if all regional holidays in Zurich (Switzerland) are defined by the provider class. - * - * @throws ReflectionException */ public function testRegionalHolidays(): void { @@ -71,8 +69,6 @@ public function testRegionalHolidays(): void /** * Tests if all observed holidays in Zurich (Switzerland) are defined by the provider class. - * - * @throws ReflectionException */ public function testObservedHolidays(): void { @@ -86,8 +82,6 @@ public function testObservedHolidays(): void /** * Tests if all seasonal holidays in Zurich (Switzerland) are defined by the provider class. - * - * @throws ReflectionException */ public function testSeasonalHolidays(): void { @@ -96,8 +90,6 @@ public function testSeasonalHolidays(): void /** * Tests if all bank holidays in Zurich (Switzerland) are defined by the provider class. - * - * @throws ReflectionException */ public function testBankHolidays(): void { @@ -106,8 +98,6 @@ public function testBankHolidays(): void /** * Tests if all other holidays in Zurich (Switzerland) are defined by the provider class. - * - * @throws ReflectionException */ public function testOtherHolidays(): void { @@ -116,6 +106,7 @@ public function testOtherHolidays(): void /** * @throws ReflectionException + * @throws \Exception */ public function testSources(): void { diff --git a/tests/Turkey/CommemorationOfAtaturkTest.php b/tests/Turkey/CommemorationOfAtaturkTest.php index 0867b75e9..6f4f07739 100644 --- a/tests/Turkey/CommemorationOfAtaturkTest.php +++ b/tests/Turkey/CommemorationOfAtaturkTest.php @@ -14,7 +14,6 @@ namespace Yasumi\tests\Turkey; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; use Yasumi\Yasumi; @@ -26,7 +25,7 @@ class CommemorationOfAtaturkTest extends TurkeyBaseTestCase implements HolidayTe public const ESTABLISHMENT_YEAR = 1920; /** - * @throws ReflectionException + * @throws \Exception */ public function testHolidayBeforeEstablishment(): void { @@ -38,7 +37,6 @@ public function testHolidayBeforeEstablishment(): void } /** - * @throws ReflectionException * @throws \Exception */ public function testHolidayOnAfterEstablishment(): void @@ -53,7 +51,7 @@ public function testHolidayOnAfterEstablishment(): void } /** - * @throws ReflectionException + * @throws \Exception */ public function testTranslation(): void { @@ -66,7 +64,7 @@ public function testTranslation(): void } /** - * @throws ReflectionException + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Turkey/DemocracyDayTest.php b/tests/Turkey/DemocracyDayTest.php index c1417c808..6836183e3 100644 --- a/tests/Turkey/DemocracyDayTest.php +++ b/tests/Turkey/DemocracyDayTest.php @@ -14,7 +14,6 @@ namespace Yasumi\tests\Turkey; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; use Yasumi\Yasumi; @@ -26,7 +25,7 @@ class DemocracyDayTest extends TurkeyBaseTestCase implements HolidayTestCase public const ESTABLISHMENT_YEAR = 2017; /** - * @throws ReflectionException + * @throws \Exception */ public function testHoliday(): void { @@ -41,7 +40,7 @@ public function testHoliday(): void } /** - * @throws ReflectionException + * @throws \Exception */ public function testHolidayBeforeEstablishment(): void { @@ -53,7 +52,7 @@ public function testHolidayBeforeEstablishment(): void } /** - * @throws ReflectionException + * @throws \Exception */ public function testTranslation(): void { @@ -66,7 +65,7 @@ public function testTranslation(): void } /** - * @throws ReflectionException + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Turkey/LabourDayTest.php b/tests/Turkey/LabourDayTest.php index 20069558b..af84b7786 100644 --- a/tests/Turkey/LabourDayTest.php +++ b/tests/Turkey/LabourDayTest.php @@ -16,7 +16,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -29,8 +28,6 @@ class LabourDayTest extends TurkeyBaseTestCase implements HolidayTestCase * * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testHoliday(int $year, DateTime $expected): void { @@ -38,7 +35,7 @@ public function testHoliday(int $year, DateTime $expected): void } /** - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -51,7 +48,7 @@ public function testTranslation(): void } /** - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Turkey/NationalSovereigntyDayTest.php b/tests/Turkey/NationalSovereigntyDayTest.php index b8d7352bb..28d4e6c91 100644 --- a/tests/Turkey/NationalSovereigntyDayTest.php +++ b/tests/Turkey/NationalSovereigntyDayTest.php @@ -14,7 +14,6 @@ namespace Yasumi\tests\Turkey; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; use Yasumi\Yasumi; @@ -30,7 +29,7 @@ class NationalSovereigntyDayTest extends TurkeyBaseTestCase implements HolidayTe public const NAME_CHANGED_YEAR = 1981; /** - * @throws ReflectionException + * @throws \Exception */ public function testHolidayBeforeEstablishment(): void { @@ -42,7 +41,6 @@ public function testHolidayBeforeEstablishment(): void } /** - * @throws ReflectionException * @throws \Exception */ public function testHolidayOnAfterEstablishment(): void @@ -57,7 +55,7 @@ public function testHolidayOnAfterEstablishment(): void } /** - * @throws ReflectionException + * @throws \Exception */ public function testTranslation(): void { @@ -70,7 +68,7 @@ public function testTranslation(): void } /** - * @throws ReflectionException + * @throws \Exception */ public function testTranslationOnAfterNameChange(): void { @@ -83,7 +81,7 @@ public function testTranslationOnAfterNameChange(): void } /** - * @throws ReflectionException + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Turkey/NewYearsDayTest.php b/tests/Turkey/NewYearsDayTest.php index 5480a2757..0d3c3da0e 100644 --- a/tests/Turkey/NewYearsDayTest.php +++ b/tests/Turkey/NewYearsDayTest.php @@ -16,7 +16,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -29,8 +28,6 @@ class NewYearsDayTest extends TurkeyBaseTestCase implements HolidayTestCase * * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testHoliday(int $year, DateTime $expected): void { @@ -48,7 +45,7 @@ public function HolidayDataProvider(): array } /** - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -61,7 +58,7 @@ public function testTranslation(): void } /** - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Turkey/RepublicDayTest.php b/tests/Turkey/RepublicDayTest.php index 770a788f3..98424f9d8 100644 --- a/tests/Turkey/RepublicDayTest.php +++ b/tests/Turkey/RepublicDayTest.php @@ -14,7 +14,6 @@ namespace Yasumi\tests\Turkey; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; use Yasumi\Yasumi; @@ -26,7 +25,7 @@ class RepublicDayTest extends TurkeyBaseTestCase implements HolidayTestCase public const ESTABLISHMENT_YEAR = 1924; /** - * @throws ReflectionException + * @throws \Exception */ public function testHoliday(): void { @@ -41,7 +40,7 @@ public function testHoliday(): void } /** - * @throws ReflectionException + * @throws \Exception */ public function testHolidayBeforeEstablishment(): void { @@ -53,7 +52,7 @@ public function testHolidayBeforeEstablishment(): void } /** - * @throws ReflectionException + * @throws \Exception */ public function testTranslation(): void { @@ -66,7 +65,7 @@ public function testTranslation(): void } /** - * @throws ReflectionException + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Turkey/TurkeyTest.php b/tests/Turkey/TurkeyTest.php index 1edffc74c..390b3a65f 100755 --- a/tests/Turkey/TurkeyTest.php +++ b/tests/Turkey/TurkeyTest.php @@ -26,14 +26,14 @@ class TurkeyTest extends TurkeyBaseTestCase implements ProviderTestCase */ protected int $year; + /** + * @throws \Exception + */ protected function setUp(): void { $this->year = $this->generateRandomYear(); } - /** - * @throws ReflectionException - */ public function testOfficialHolidays(): void { $holidays = [ @@ -69,9 +69,6 @@ public function testOfficialHolidays(): void $this->assertDefinedHolidays($holidays, self::REGION, $this->year, Holiday::TYPE_OFFICIAL); } - /** - * @throws ReflectionException - */ public function testObservedHolidays(): void { $holidays = []; @@ -83,25 +80,16 @@ public function testObservedHolidays(): void $this->assertDefinedHolidays($holidays, self::REGION, $this->year, Holiday::TYPE_OBSERVANCE); } - /** - * @throws ReflectionException - */ public function testSeasonalHolidays(): void { $this->assertDefinedHolidays([], self::REGION, $this->year, Holiday::TYPE_SEASON); } - /** - * @throws ReflectionException - */ public function testBankHolidays(): void { $this->assertDefinedHolidays([], self::REGION, $this->year, Holiday::TYPE_BANK); } - /** - * @throws ReflectionException - */ public function testOtherHolidays(): void { $this->assertDefinedHolidays([], self::REGION, $this->year, Holiday::TYPE_OTHER); @@ -109,6 +97,7 @@ public function testOtherHolidays(): void /** * @throws ReflectionException + * @throws \Exception */ public function testSources(): void { diff --git a/tests/Turkey/VictoryDayTest.php b/tests/Turkey/VictoryDayTest.php index 9d796b035..21559f849 100644 --- a/tests/Turkey/VictoryDayTest.php +++ b/tests/Turkey/VictoryDayTest.php @@ -14,7 +14,6 @@ namespace Yasumi\tests\Turkey; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; use Yasumi\Yasumi; @@ -28,7 +27,7 @@ class VictoryDayTest extends TurkeyBaseTestCase implements HolidayTestCase public const CELEBRATION_YEAR = 1923; /** - * @throws ReflectionException + * @throws \Exception */ public function testHoliday(): void { @@ -43,7 +42,7 @@ public function testHoliday(): void } /** - * @throws ReflectionException + * @throws \Exception */ public function testHolidayBeforeCelebration(): void { @@ -55,7 +54,7 @@ public function testHolidayBeforeCelebration(): void } /** - * @throws ReflectionException + * @throws \Exception */ public function testTranslation(): void { @@ -68,7 +67,7 @@ public function testTranslation(): void } /** - * @throws ReflectionException + * @throws \Exception */ public function testHolidayType(): void { @@ -81,7 +80,7 @@ public function testHolidayType(): void } /** - * @throws ReflectionException + * @throws \Exception */ public function testHolidayTypeBeforeEstablishment(): void { diff --git a/tests/USA/ChristmasDayTest.php b/tests/USA/ChristmasDayTest.php index 41405bed3..e3e00ee09 100644 --- a/tests/USA/ChristmasDayTest.php +++ b/tests/USA/ChristmasDayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -35,7 +34,6 @@ class ChristmasDayTest extends USABaseTestCase implements HolidayTestCase * Tests Christmas Day. Christmas Day is celebrated on December 25th. * * @throws Exception - * @throws ReflectionException */ public function testChristmasDay(): void { @@ -52,7 +50,6 @@ public function testChristmasDay(): void * Tests Christmas Day substituted on Monday (when Christmas Day falls on Sunday). * * @throws Exception - * @throws ReflectionException */ public function testChristmasDaySubstitutedMonday(): void { @@ -70,7 +67,6 @@ public function testChristmasDaySubstitutedMonday(): void * Tests Christmas Day substituted on Monday (when Christmas Day falls on Saturday). * * @throws Exception - * @throws ReflectionException */ public function testChristmasDaySubstitutedFriday(): void { @@ -87,7 +83,7 @@ public function testChristmasDaySubstitutedFriday(): void /** * Tests translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -102,7 +98,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/USA/ColumbusDayTest.php b/tests/USA/ColumbusDayTest.php index 100cf175f..3ce5c3b11 100644 --- a/tests/USA/ColumbusDayTest.php +++ b/tests/USA/ColumbusDayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -41,7 +40,6 @@ class ColumbusDayTest extends USABaseTestCase implements HolidayTestCase * the second Monday in October since 1970. * * @throws Exception - * @throws ReflectionException */ public function testColumbusDayOnAfter1970(): void { @@ -59,7 +57,6 @@ public function testColumbusDayOnAfter1970(): void * fixed to the second Monday in October since 1970. * * @throws Exception - * @throws ReflectionException */ public function testColumbusBetween1937And1969(): void { @@ -76,7 +73,7 @@ public function testColumbusBetween1937And1969(): void * Tests Columbus Day before 1937. Columbus Day was established in 1937 on October 12th, but has been fixed to * the second Monday in October since 1970. * - * @throws ReflectionException + * @throws Exception */ public function testColumbusDayBefore1937(): void { @@ -90,7 +87,7 @@ public function testColumbusDayBefore1937(): void /** * Tests translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -105,7 +102,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/USA/IndependenceDayTest.php b/tests/USA/IndependenceDayTest.php index da1e3dac2..6b6dad10b 100644 --- a/tests/USA/IndependenceDayTest.php +++ b/tests/USA/IndependenceDayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -40,7 +39,6 @@ class IndependenceDayTest extends USABaseTestCase implements HolidayTestCase * Tests Independence Day on or after 1776. Independence Day is celebrated since 1776 on July 4th. * * @throws Exception - * @throws ReflectionException */ public function testIndependenceDayOnAfter1776(): void { @@ -57,7 +55,6 @@ public function testIndependenceDayOnAfter1776(): void * Tests Independence Day on or after 1776 when substituted on Monday (when Independence Day falls on Sunday). * * @throws Exception - * @throws ReflectionException */ public function testIndependenceDayOnAfter1776SubstitutedMonday(): void { @@ -74,7 +71,6 @@ public function testIndependenceDayOnAfter1776SubstitutedMonday(): void * Tests Independence Day on or after 1776 when substituted on Friday (when Independence Day falls on Saturday). * * @throws Exception - * @throws ReflectionException */ public function testIndependenceDayOnAfter1776SubstitutedFriday(): void { @@ -90,7 +86,7 @@ public function testIndependenceDayOnAfter1776SubstitutedFriday(): void /** * Tests Independence Day before 1776. Independence Day is celebrated since 1776 on July 4th. * - * @throws ReflectionException + * @throws Exception */ public function testIndependenceDayBefore1776(): void { @@ -104,7 +100,7 @@ public function testIndependenceDayBefore1776(): void /** * Tests translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -119,7 +115,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/USA/JuneteenthTest.php b/tests/USA/JuneteenthTest.php index 56427c7f6..7df2d81cd 100644 --- a/tests/USA/JuneteenthTest.php +++ b/tests/USA/JuneteenthTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -40,7 +39,6 @@ class JuneteenthTest extends USABaseTestCase implements HolidayTestCase * Tests Juneteenth on or after 2021. Juneteenth is celebrated since 2021 on June 19th. * * @throws Exception - * @throws ReflectionException */ public function testJuneteenthOnAfter2021(): void { @@ -57,7 +55,6 @@ public function testJuneteenthOnAfter2021(): void * Tests Juneteenth on or after 2021 when substituted on Monday (when Juneteenth falls on Sunday). * * @throws Exception - * @throws ReflectionException */ public function testJuneteenthOnAfter2021SubstitutedMonday(): void { @@ -74,7 +71,6 @@ public function testJuneteenthOnAfter2021SubstitutedMonday(): void * Tests Juneteenth on or after 2021 when substituted on Friday (when Juneteenth falls on Saturday). * * @throws Exception - * @throws ReflectionException */ public function testJuneteenthOnAfter2021SubstitutedFriday(): void { @@ -90,7 +86,7 @@ public function testJuneteenthOnAfter2021SubstitutedFriday(): void /** * Tests Juneteenth before 2021. Juneteenth is celebrated since 2021 on June 19th. * - * @throws ReflectionException + * @throws Exception */ public function testJuneteenthBefore2021(): void { @@ -104,7 +100,7 @@ public function testJuneteenthBefore2021(): void /** * Tests translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -119,7 +115,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/USA/LabourDayTest.php b/tests/USA/LabourDayTest.php index 00f46ee78..5b4dad368 100644 --- a/tests/USA/LabourDayTest.php +++ b/tests/USA/LabourDayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -40,7 +39,6 @@ class LabourDayTest extends USABaseTestCase implements HolidayTestCase * Tests Labour Day on or after 1887. Labour Day was established since 1887 on the first Monday of September. * * @throws Exception - * @throws ReflectionException */ public function testLabourDayOnAfter1887(): void { @@ -56,7 +54,7 @@ public function testLabourDayOnAfter1887(): void /** * Tests Labour Day before 1887. Labour Day was established since 1887 on the first Monday of September. * - * @throws ReflectionException + * @throws Exception */ public function testLabourDayBefore1887(): void { @@ -70,7 +68,7 @@ public function testLabourDayBefore1887(): void /** * Tests translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -85,7 +83,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/USA/MartinLutherKingDayTest.php b/tests/USA/MartinLutherKingDayTest.php index 6151b1f97..fc9c4c18c 100644 --- a/tests/USA/MartinLutherKingDayTest.php +++ b/tests/USA/MartinLutherKingDayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -41,7 +40,6 @@ class MartinLutherKingDayTest extends USABaseTestCase implements HolidayTestCase * third Monday of January. * * @throws Exception - * @throws ReflectionException */ public function testMartinLutherKingDayOnAfter1986(): void { @@ -58,7 +56,7 @@ public function testMartinLutherKingDayOnAfter1986(): void * Tests Dr. Martin Luther King Day before 1986. Dr. Martin Luther King Day was established since 1996 on the third * Monday of January. * - * @throws ReflectionException + * @throws Exception */ public function testMartinLutherKingDayBefore1986(): void { @@ -72,7 +70,7 @@ public function testMartinLutherKingDayBefore1986(): void /** * Tests translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -87,7 +85,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/USA/MemorialDayTest.php b/tests/USA/MemorialDayTest.php index 880174a2c..4d2011b51 100644 --- a/tests/USA/MemorialDayTest.php +++ b/tests/USA/MemorialDayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -41,7 +40,6 @@ class MemorialDayTest extends USABaseTestCase implements HolidayTestCase * to the last Monday in May. * * @throws Exception - * @throws ReflectionException */ public function testMemorialDayOnAfter1968(): void { @@ -59,7 +57,6 @@ public function testMemorialDayOnAfter1968(): void * 1968 to the last Monday in May. * * @throws Exception - * @throws ReflectionException */ public function testMemorialDayBetween1865And1967(): void { @@ -76,7 +73,7 @@ public function testMemorialDayBetween1865And1967(): void * Tests Memorial Day before 1865. Memorial Day was established since 1865 on May 30 and was changed in 1968 to the * last Monday in May. * - * @throws ReflectionException + * @throws Exception */ public function testMemorialDayBefore1865(): void { @@ -90,7 +87,7 @@ public function testMemorialDayBefore1865(): void /** * Tests translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -105,7 +102,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/USA/NewYearsDayTest.php b/tests/USA/NewYearsDayTest.php index 24496b593..456a9b084 100644 --- a/tests/USA/NewYearsDayTest.php +++ b/tests/USA/NewYearsDayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -35,7 +34,6 @@ class NewYearsDayTest extends USABaseTestCase implements HolidayTestCase * Tests New Years Day. * * @throws Exception - * @throws ReflectionException */ public function testNewYearsDay(): void { @@ -52,7 +50,6 @@ public function testNewYearsDay(): void * Tests New Years Day when substituted on Monday (when New Years Day falls on Sunday). * * @throws Exception - * @throws ReflectionException */ public function testNewYearsDaySubstitutedMonday(): void { @@ -69,7 +66,6 @@ public function testNewYearsDaySubstitutedMonday(): void * Tests New Years Day when substituted on Friday (when New Years Day falls on Saturday). * * @throws Exception - * @throws ReflectionException */ public function testNewYearsDaySubstitutedFriday(): void { @@ -86,7 +82,7 @@ public function testNewYearsDaySubstitutedFriday(): void /** * Tests translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -101,7 +97,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/USA/ThanksgivingDayTest.php b/tests/USA/ThanksgivingDayTest.php index bd581c37a..47c7e8e60 100644 --- a/tests/USA/ThanksgivingDayTest.php +++ b/tests/USA/ThanksgivingDayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -41,7 +40,6 @@ class ThanksgivingDayTest extends USABaseTestCase implements HolidayTestCase * of November. * * @throws Exception - * @throws ReflectionException */ public function testThanksgivingDayOnAfter1863(): void { @@ -58,7 +56,7 @@ public function testThanksgivingDayOnAfter1863(): void * Tests Thanksgiving Day before 1863. ThanksgivingDay Day is celebrated since 1863 on the fourth Thursday * of November. * - * @throws ReflectionException + * @throws Exception */ public function testThanksgivingDayBefore1863(): void { @@ -72,7 +70,7 @@ public function testThanksgivingDayBefore1863(): void /** * Tests translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -87,7 +85,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/USA/USATest.php b/tests/USA/USATest.php index 235f702af..df8e01d9e 100644 --- a/tests/USA/USATest.php +++ b/tests/USA/USATest.php @@ -30,6 +30,8 @@ class USATest extends USABaseTestCase implements ProviderTestCase /** * Initial setup of this Test Case. + * + * @throws \Exception */ protected function setUp(): void { @@ -38,8 +40,6 @@ protected function setUp(): void /** * Tests if all official holidays in the USA are defined by the provider class. - * - * @throws ReflectionException */ public function testOfficialHolidays(): void { @@ -65,8 +65,6 @@ public function testOfficialHolidays(): void /** * Tests if all observed holidays in the USA are defined by the provider class. - * - * @throws ReflectionException */ public function testObservedHolidays(): void { @@ -75,8 +73,6 @@ public function testObservedHolidays(): void /** * Tests if all seasonal holidays in the USA are defined by the provider class. - * - * @throws ReflectionException */ public function testSeasonalHolidays(): void { @@ -85,8 +81,6 @@ public function testSeasonalHolidays(): void /** * Tests if all bank holidays in the USA are defined by the provider class. - * - * @throws ReflectionException */ public function testBankHolidays(): void { @@ -95,8 +89,6 @@ public function testBankHolidays(): void /** * Tests if all other holidays in the USA are defined by the provider class. - * - * @throws ReflectionException */ public function testOtherHolidays(): void { @@ -105,6 +97,7 @@ public function testOtherHolidays(): void /** * @throws ReflectionException + * @throws \Exception */ public function testSources(): void { diff --git a/tests/USA/VeteransDayTest.php b/tests/USA/VeteransDayTest.php index 7c976db51..b7a4bdb89 100644 --- a/tests/USA/VeteransDayTest.php +++ b/tests/USA/VeteransDayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Exception\MissingTranslationException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -42,7 +41,6 @@ class VeteransDayTest extends USABaseTestCase implements HolidayTestCase * Tests Veterans Day on or after 1919. Veterans Day was established in 1919 on November 11. * * @throws Exception - * @throws ReflectionException */ public function testVeteransDayOnAfter1919(): void { @@ -59,7 +57,6 @@ public function testVeteransDayOnAfter1919(): void * Tests Veterans Day on or after 1919 when substituted on Monday (when Veterans Day falls on Sunday). * * @throws Exception - * @throws ReflectionException */ public function testVeteransDayOnAfter1919SubstitutedMonday(): void { @@ -76,7 +73,6 @@ public function testVeteransDayOnAfter1919SubstitutedMonday(): void * Tests Veterans Day on or after 1919 when substituted on Friday (when Veterans Day falls on Saturday). * * @throws Exception - * @throws ReflectionException */ public function testVeteransDayOnAfter1919SubstitutedFriday(): void { @@ -92,7 +88,7 @@ public function testVeteransDayOnAfter1919SubstitutedFriday(): void /** * Tests Veterans Day before 1919. Veterans Day was established in 1919 on November 11. * - * @throws ReflectionException + * @throws Exception */ public function testVeteransDayBefore1919(): void { @@ -106,12 +102,14 @@ public function testVeteransDayBefore1919(): void /** * Tests name of Veterans Day before 1954. Veterans Day was named 'Armistice Day' before 1954. * - * @throws ReflectionException * @throws MissingTranslationException */ public function testVeteransDayNameBefore1954(): void { - $year = $this->generateRandomYear(self::ESTABLISHMENT_YEAR, 1953); + try { + $year = $this->generateRandomYear(self::ESTABLISHMENT_YEAR, 1953); + } catch (Exception $e) { + } $holidays = Yasumi::create(self::REGION, $year); $holiday = $holidays->getHoliday(self::HOLIDAY); @@ -121,12 +119,14 @@ public function testVeteransDayNameBefore1954(): void /** * Tests name of Veterans Day after 1954. Veterans Day was named 'Armistice Day' before 1954. * - * @throws ReflectionException * @throws MissingTranslationException */ public function testVeteransDayNameAfter1954(): void { - $year = $this->generateRandomYear(1954); + try { + $year = $this->generateRandomYear(1954); + } catch (Exception $e) { + } $holidays = Yasumi::create(self::REGION, $year); $holiday = $holidays->getHoliday(self::HOLIDAY); @@ -136,7 +136,7 @@ public function testVeteransDayNameAfter1954(): void /** * Tests translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -151,7 +151,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/USA/WashingtonsBirthdayTest.php b/tests/USA/WashingtonsBirthdayTest.php index e6aa98c93..be5778f85 100644 --- a/tests/USA/WashingtonsBirthdayTest.php +++ b/tests/USA/WashingtonsBirthdayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -41,7 +40,6 @@ class WashingtonsBirthdayTest extends USABaseTestCase implements HolidayTestCase * and was changed in 1968 to the third Monday in February. * * @throws Exception - * @throws ReflectionException */ public function testWashingtonsBirthdayOnAfter1968(): void { @@ -59,7 +57,6 @@ public function testWashingtonsBirthdayOnAfter1968(): void * 22 and was changed in 1968 to the third Monday in February. * * @throws Exception - * @throws ReflectionException */ public function testWashingtonsBirthdayBetween1879And1967(): void { @@ -76,7 +73,7 @@ public function testWashingtonsBirthdayBetween1879And1967(): void * Tests Washington's Birthday before 1879. Washington's Birthday was established since 1879 on February 22 and was * changed in 1968 to the third Monday in February. * - * @throws ReflectionException + * @throws Exception */ public function testWashingtonsBirthdayBefore1879(): void { @@ -90,7 +87,7 @@ public function testWashingtonsBirthdayBefore1879(): void /** * Tests translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -105,7 +102,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Ukraine/CatholicChristmasDayTest.php b/tests/Ukraine/CatholicChristmasDayTest.php index 6f55216d6..6118e7b57 100644 --- a/tests/Ukraine/CatholicChristmasDayTest.php +++ b/tests/Ukraine/CatholicChristmasDayTest.php @@ -17,7 +17,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; use Yasumi\Yasumi; @@ -39,8 +38,6 @@ class CatholicChristmasDayTest extends UkraineBaseTestCase implements HolidayTes * * @param int $year the year for which International Workers' Day needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testCatholicChristmasDay(int $year, DateTime $expected): void { @@ -50,7 +47,7 @@ public function testCatholicChristmasDay(int $year, DateTime $expected): void /** * Tests Catholic Christmas Day before 2017. * - * @throws ReflectionException + * @throws Exception */ public function testNoCatholicChristmasDayBefore2017(): void { @@ -66,7 +63,7 @@ public function testNoCatholicChristmasDayBefore2017(): void /** * Tests translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -81,7 +78,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Ukraine/ChristmasDayTest.php b/tests/Ukraine/ChristmasDayTest.php index 4db0562f5..0eddc717a 100644 --- a/tests/Ukraine/ChristmasDayTest.php +++ b/tests/Ukraine/ChristmasDayTest.php @@ -16,7 +16,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -37,8 +36,6 @@ class ChristmasDayTest extends UkraineBaseTestCase implements HolidayTestCase * * @param int $year the year for which Christmas Day needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testChristmasDay(int $year, DateTime $expected): void { @@ -60,7 +57,7 @@ public function HolidayDataProvider(): array /** * Tests translated name of Christmas Day. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -75,7 +72,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Ukraine/ConstitutionDayTest.php b/tests/Ukraine/ConstitutionDayTest.php index 3daedd9a6..471bd9f53 100644 --- a/tests/Ukraine/ConstitutionDayTest.php +++ b/tests/Ukraine/ConstitutionDayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -32,7 +31,6 @@ class ConstitutionDayTest extends UkraineBaseTestCase implements HolidayTestCase public const HOLIDAY = 'constitutionDay'; /** - * @throws ReflectionException * @throws Exception */ public function testHoliday(): void @@ -48,8 +46,6 @@ public function testHoliday(): void /** * Tests the translated name of the holiday defined in this test. - * - * @throws ReflectionException */ public function testTranslation(): void { @@ -58,8 +54,6 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. - * - * @throws ReflectionException */ public function testHolidayType(): void { diff --git a/tests/Ukraine/DefenderOfUkraineDayTest.php b/tests/Ukraine/DefenderOfUkraineDayTest.php index 7615d2963..bb3725ddb 100644 --- a/tests/Ukraine/DefenderOfUkraineDayTest.php +++ b/tests/Ukraine/DefenderOfUkraineDayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -32,7 +31,6 @@ class DefenderOfUkraineDayTest extends UkraineBaseTestCase implements HolidayTes public const HOLIDAY = 'defenderOfUkraineDay'; /** - * @throws ReflectionException * @throws Exception */ public function testHoliday(): void @@ -48,8 +46,6 @@ public function testHoliday(): void /** * Tests the translated name of the holiday defined in this test. - * - * @throws ReflectionException */ public function testTranslation(): void { @@ -63,8 +59,6 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. - * - * @throws ReflectionException */ public function testHolidayType(): void { diff --git a/tests/Ukraine/EasterTest.php b/tests/Ukraine/EasterTest.php index ca153ea56..b5eefe709 100644 --- a/tests/Ukraine/EasterTest.php +++ b/tests/Ukraine/EasterTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -35,7 +34,6 @@ class EasterTest extends UkraineBaseTestCase implements HolidayTestCase * Tests the holiday defined in this test. * * @throws Exception - * @throws ReflectionException */ public function testHoliday(): void { @@ -51,7 +49,7 @@ public function testHoliday(): void /** * Tests translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -66,7 +64,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Ukraine/IndependenceDayTest.php b/tests/Ukraine/IndependenceDayTest.php index 3b1933b18..55bacedea 100644 --- a/tests/Ukraine/IndependenceDayTest.php +++ b/tests/Ukraine/IndependenceDayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -32,7 +31,6 @@ class IndependenceDayTest extends UkraineBaseTestCase implements HolidayTestCase public const HOLIDAY = 'independenceDay'; /** - * @throws ReflectionException * @throws Exception */ public function testHoliday(): void @@ -48,8 +46,6 @@ public function testHoliday(): void /** * Tests the translated name of the holiday defined in this test. - * - * @throws ReflectionException */ public function testTranslation(): void { @@ -58,8 +54,6 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. - * - * @throws ReflectionException */ public function testHolidayType(): void { diff --git a/tests/Ukraine/InternationalWomensDayTest.php b/tests/Ukraine/InternationalWomensDayTest.php index a46b46f21..09e4aaf0b 100644 --- a/tests/Ukraine/InternationalWomensDayTest.php +++ b/tests/Ukraine/InternationalWomensDayTest.php @@ -16,7 +16,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -32,8 +31,6 @@ class InternationalWomensDayTest extends UkraineBaseTestCase implements HolidayT /** * @dataProvider HolidayDataProvider - * - * @throws ReflectionException */ public function testHoliday(int $year, DateTime $expected): void { @@ -55,7 +52,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -70,7 +67,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Ukraine/InternationalWorkersDayTest.php b/tests/Ukraine/InternationalWorkersDayTest.php index 46407353d..231a36c1a 100644 --- a/tests/Ukraine/InternationalWorkersDayTest.php +++ b/tests/Ukraine/InternationalWorkersDayTest.php @@ -16,7 +16,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -37,8 +36,6 @@ class InternationalWorkersDayTest extends UkraineBaseTestCase implements Holiday * * @param int $year the year for which International Workers' Day needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testInternationalWorkersDay(int $year, DateTime $expected): void { @@ -48,7 +45,7 @@ public function testInternationalWorkersDay(int $year, DateTime $expected): void /** * Tests translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -63,7 +60,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Ukraine/NewYearsDayTest.php b/tests/Ukraine/NewYearsDayTest.php index 6899ec9e1..017418786 100644 --- a/tests/Ukraine/NewYearsDayTest.php +++ b/tests/Ukraine/NewYearsDayTest.php @@ -16,7 +16,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -37,8 +36,6 @@ class NewYearsDayTest extends UkraineBaseTestCase implements HolidayTestCase * * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testHoliday(int $year, DateTime $expected): void { @@ -60,7 +57,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -75,7 +72,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Ukraine/PentecostTest.php b/tests/Ukraine/PentecostTest.php index 95efecd72..5a00d538c 100644 --- a/tests/Ukraine/PentecostTest.php +++ b/tests/Ukraine/PentecostTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -35,7 +34,6 @@ class PentecostTest extends UkraineBaseTestCase implements HolidayTestCase * Tests the holiday defined in this test. * * @throws Exception - * @throws ReflectionException */ public function testHoliday(): void { @@ -51,7 +49,7 @@ public function testHoliday(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -66,7 +64,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/Ukraine/SecondInternationalWorkersDayTest.php b/tests/Ukraine/SecondInternationalWorkersDayTest.php index 55bc24cf3..63b01456e 100644 --- a/tests/Ukraine/SecondInternationalWorkersDayTest.php +++ b/tests/Ukraine/SecondInternationalWorkersDayTest.php @@ -16,7 +16,6 @@ namespace Yasumi\tests\Ukraine; use DateTime; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; use Yasumi\Yasumi; @@ -38,8 +37,6 @@ class SecondInternationalWorkersDayTest extends UkraineBaseTestCase implements H * * @param int $year the year for which International Workers' Day needs to be tested * @param DateTime $expected the expected date - * - * @throws ReflectionException */ public function testSecondInternationalWorkersDay(int $year, DateTime $expected): void { @@ -49,7 +46,7 @@ public function testSecondInternationalWorkersDay(int $year, DateTime $expected) /** * Tests International Workers' Day since 2018. * - * @throws ReflectionException + * @throws \Exception */ public function testNoSecondInternationalWorkersDaySince2018(): void { @@ -65,7 +62,7 @@ public function testNoSecondInternationalWorkersDaySince2018(): void /** * Tests translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws \Exception */ public function testTranslation(): void { @@ -80,7 +77,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Ukraine/SubstitutedHolidayTest.php b/tests/Ukraine/SubstitutedHolidayTest.php index 000fef5bf..a409f6104 100644 --- a/tests/Ukraine/SubstitutedHolidayTest.php +++ b/tests/Ukraine/SubstitutedHolidayTest.php @@ -60,8 +60,6 @@ public function testSaturdaySubstitution(): void * @param int $year holiday calendar year * @param DateTime $expectedOfficial the official date to be checked against * @param DateTime|null $expectedSubstitution the substituted date to be checked against - * - * @throws ReflectionException */ public function assertHolidayWithSubstitution( string $provider, diff --git a/tests/Ukraine/UkraineTest.php b/tests/Ukraine/UkraineTest.php index f142186a5..6df25c7f9 100644 --- a/tests/Ukraine/UkraineTest.php +++ b/tests/Ukraine/UkraineTest.php @@ -31,6 +31,8 @@ class UkraineTest extends UkraineBaseTestCase implements ProviderTestCase /** * Initial setup of this Test Case. + * + * @throws \Exception */ protected function setUp(): void { @@ -39,8 +41,6 @@ protected function setUp(): void /** * Tests if all official holidays in Ukraine are defined by the provider class. - * - * @throws ReflectionException */ public function testOfficialHolidays(): void { @@ -84,8 +84,6 @@ public function testOfficialHolidays(): void /** * Tests if all observed holidays in Ukraine are defined by the provider class. - * - * @throws ReflectionException */ public function testObservedHolidays(): void { @@ -94,8 +92,6 @@ public function testObservedHolidays(): void /** * Tests if all seasonal holidays in Ukraine are defined by the provider class. - * - * @throws ReflectionException */ public function testSeasonalHolidays(): void { @@ -104,8 +100,6 @@ public function testSeasonalHolidays(): void /** * Tests if all bank holidays in Ukraine are defined by the provider class. - * - * @throws ReflectionException */ public function testBankHolidays(): void { @@ -114,8 +108,6 @@ public function testBankHolidays(): void /** * Tests if all other holidays in Ukraine are defined by the provider class. - * - * @throws ReflectionException */ public function testOtherHolidays(): void { @@ -124,6 +116,7 @@ public function testOtherHolidays(): void /** * @throws ReflectionException + * @throws \Exception */ public function testSources(): void { diff --git a/tests/Ukraine/VictoryDayTest.php b/tests/Ukraine/VictoryDayTest.php index 08c573511..4d686b93b 100644 --- a/tests/Ukraine/VictoryDayTest.php +++ b/tests/Ukraine/VictoryDayTest.php @@ -16,7 +16,6 @@ use DateTime; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -32,8 +31,6 @@ class VictoryDayTest extends UkraineBaseTestCase implements HolidayTestCase /** * @dataProvider HolidayDataProvider - * - * @throws ReflectionException */ public function testHoliday(int $year, DateTime $expected): void { @@ -55,7 +52,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -70,7 +67,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/UnitedKingdom/BoxingDayTest.php b/tests/UnitedKingdom/BoxingDayTest.php index 1bb47bb2c..1c2015824 100644 --- a/tests/UnitedKingdom/BoxingDayTest.php +++ b/tests/UnitedKingdom/BoxingDayTest.php @@ -18,7 +18,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -40,7 +39,6 @@ class BoxingDayTest extends UnitedKingdomBaseTestCase implements HolidayTestCase * @param int $year the year for which the holiday defined in this test needs to be tested * @param string $expected the expected date * - * @throws ReflectionException * @throws Exception */ public function testHoliday(int $year, string $expected): void @@ -79,7 +77,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -94,7 +92,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/UnitedKingdom/ChristmasDayTest.php b/tests/UnitedKingdom/ChristmasDayTest.php index 3b4c3f4f8..9c46a7d30 100644 --- a/tests/UnitedKingdom/ChristmasDayTest.php +++ b/tests/UnitedKingdom/ChristmasDayTest.php @@ -18,7 +18,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -40,7 +39,6 @@ class ChristmasDayTest extends UnitedKingdomBaseTestCase implements HolidayTestC * @param int $year the year for which the holiday defined in this test needs to be tested * @param string $expected the expected date * - * @throws ReflectionException * @throws Exception */ public function testHoliday(int $year, string $expected): void @@ -79,7 +77,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -94,7 +92,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/UnitedKingdom/EasterMondayTest.php b/tests/UnitedKingdom/EasterMondayTest.php index 29806a8b0..3d8b181fd 100644 --- a/tests/UnitedKingdom/EasterMondayTest.php +++ b/tests/UnitedKingdom/EasterMondayTest.php @@ -18,7 +18,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -40,7 +39,6 @@ class EasterMondayTest extends UnitedKingdomBaseTestCase implements HolidayTestC * @param int $year the year for which the holiday defined in this test needs to be tested * @param string $expected the expected date * - * @throws ReflectionException * @throws Exception */ public function testHoliday(int $year, string $expected): void @@ -78,7 +76,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -93,7 +91,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/UnitedKingdom/England/BoxingDayTest.php b/tests/UnitedKingdom/England/BoxingDayTest.php index f5ac58fbf..7b5216a22 100644 --- a/tests/UnitedKingdom/England/BoxingDayTest.php +++ b/tests/UnitedKingdom/England/BoxingDayTest.php @@ -18,7 +18,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -40,7 +39,6 @@ class BoxingDayTest extends EnglandBaseTestCase implements HolidayTestCase * @param int $year the year for which the holiday defined in this test needs to be tested * @param string $expected the expected date * - * @throws ReflectionException * @throws Exception */ public function testHoliday(int $year, string $expected): void @@ -79,7 +77,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -94,7 +92,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/UnitedKingdom/England/ChristmasDayTest.php b/tests/UnitedKingdom/England/ChristmasDayTest.php index 1a244d78f..e292d6c70 100644 --- a/tests/UnitedKingdom/England/ChristmasDayTest.php +++ b/tests/UnitedKingdom/England/ChristmasDayTest.php @@ -18,7 +18,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -40,7 +39,6 @@ class ChristmasDayTest extends EnglandBaseTestCase implements HolidayTestCase * @param int $year the year for which the holiday defined in this test needs to be tested * @param string $expected the expected date * - * @throws ReflectionException * @throws Exception */ public function testHoliday(int $year, string $expected): void @@ -79,7 +77,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -94,7 +92,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/UnitedKingdom/England/EasterMondayTest.php b/tests/UnitedKingdom/England/EasterMondayTest.php index 0bc947d45..44621dea9 100644 --- a/tests/UnitedKingdom/England/EasterMondayTest.php +++ b/tests/UnitedKingdom/England/EasterMondayTest.php @@ -18,7 +18,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -40,7 +39,6 @@ class EasterMondayTest extends EnglandBaseTestCase implements HolidayTestCase * @param int $year the year for which the holiday defined in this test needs to be tested * @param string $expected the expected date * - * @throws ReflectionException * @throws Exception */ public function testHoliday(int $year, string $expected): void @@ -78,7 +76,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -93,7 +91,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/UnitedKingdom/England/EnglandTest.php b/tests/UnitedKingdom/England/EnglandTest.php index a03903792..8ee8ca65a 100644 --- a/tests/UnitedKingdom/England/EnglandTest.php +++ b/tests/UnitedKingdom/England/EnglandTest.php @@ -26,10 +26,12 @@ class EnglandTest extends EnglandBaseTestCase implements ProviderTestCase /** * @var int year random year number used for all tests in this Test Case */ - protected $year; + protected int $year; /** * Initial setup of this Test Case. + * + * @throws \Exception */ protected function setUp(): void { @@ -38,8 +40,6 @@ protected function setUp(): void /** * Tests if all official holidays in England are defined by the provider class. - * - * @throws ReflectionException */ public function testOfficialHolidays(): void { @@ -51,8 +51,6 @@ public function testOfficialHolidays(): void /** * Tests if all observed holidays in England are defined by the provider class. - * - * @throws ReflectionException */ public function testObservedHolidays(): void { @@ -61,8 +59,6 @@ public function testObservedHolidays(): void /** * Tests if all seasonal holidays in England are defined by the provider class. - * - * @throws ReflectionException */ public function testSeasonalHolidays(): void { @@ -71,8 +67,6 @@ public function testSeasonalHolidays(): void /** * Tests if all bank holidays in England are defined by the provider class. - * - * @throws ReflectionException */ public function testBankHolidays(): void { @@ -87,8 +81,6 @@ public function testBankHolidays(): void /** * Tests if all other holidays in England are defined by the provider class. - * - * @throws ReflectionException */ public function testOtherHolidays(): void { @@ -97,6 +89,7 @@ public function testOtherHolidays(): void /** * @throws ReflectionException + * @throws \Exception */ public function testSources(): void { diff --git a/tests/UnitedKingdom/England/GoodFridayTest.php b/tests/UnitedKingdom/England/GoodFridayTest.php index 601b64b55..dbefe0c33 100644 --- a/tests/UnitedKingdom/England/GoodFridayTest.php +++ b/tests/UnitedKingdom/England/GoodFridayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -35,7 +34,6 @@ class GoodFridayTest extends EnglandBaseTestCase implements HolidayTestCase * Tests the holiday defined in this test. * * @throws Exception - * @throws ReflectionException */ public function testHoliday(): void { @@ -51,7 +49,7 @@ public function testHoliday(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -66,7 +64,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/UnitedKingdom/England/MayDayBankHolidayTest.php b/tests/UnitedKingdom/England/MayDayBankHolidayTest.php index 8c4dc869e..8844c7daf 100644 --- a/tests/UnitedKingdom/England/MayDayBankHolidayTest.php +++ b/tests/UnitedKingdom/England/MayDayBankHolidayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -40,7 +39,6 @@ class MayDayBankHolidayTest extends EnglandBaseTestCase implements HolidayTestCa * Tests the holiday defined in this test. * * @throws Exception - * @throws ReflectionException */ public function testHoliday(): void { @@ -56,7 +54,6 @@ public function testHoliday(): void /** * Tests the holiday exception in 1995 and 2020. * - * @throws ReflectionException * @throws Exception */ public function testHolidayExceptions(): void @@ -79,7 +76,7 @@ public function testHolidayExceptions(): void /** * Tests the holiday defined in this test before establishment. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayBeforeEstablishment(): void { @@ -93,7 +90,7 @@ public function testHolidayBeforeEstablishment(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -108,7 +105,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/UnitedKingdom/England/NewYearsDayTest.php b/tests/UnitedKingdom/England/NewYearsDayTest.php index 8aadfd6e8..c62264820 100644 --- a/tests/UnitedKingdom/England/NewYearsDayTest.php +++ b/tests/UnitedKingdom/England/NewYearsDayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -49,7 +48,6 @@ class NewYearsDayTest extends EnglandBaseTestCase implements HolidayTestCase * @param int $year the year for which the holiday defined in this test needs to be tested * @param string $expected the expected date * - * @throws ReflectionException * @throws Exception */ public function testHolidayOnAfterEstablishment(int $year, string $expected): void @@ -65,7 +63,7 @@ public function testHolidayOnAfterEstablishment(int $year, string $expected): vo /** * Tests the holiday defined in this test before establishment. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayBeforeEstablishment(): void { @@ -79,7 +77,7 @@ public function testHolidayBeforeEstablishment(): void /** * Tests that the holiday defined in this test is of the type 'observance' before the year it was changed. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayIsObservedTypeBeforeChange(): void { @@ -106,7 +104,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -121,7 +119,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/UnitedKingdom/England/SpringBankHolidayTest.php b/tests/UnitedKingdom/England/SpringBankHolidayTest.php index 738ed55b6..5bb5d6744 100644 --- a/tests/UnitedKingdom/England/SpringBankHolidayTest.php +++ b/tests/UnitedKingdom/England/SpringBankHolidayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -40,7 +39,6 @@ class SpringBankHolidayTest extends EnglandBaseTestCase implements HolidayTestCa * Tests the holiday defined in this test. * * @throws Exception - * @throws ReflectionException */ public function testHoliday(): void { @@ -56,7 +54,6 @@ public function testHoliday(): void /** * Tests the holiday exceptions in 2002 and 2012. * - * @throws ReflectionException * @throws Exception */ public function testHolidayException(): void @@ -79,7 +76,7 @@ public function testHolidayException(): void /** * Tests the holiday defined in this test before establishment. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayBeforeEstablishment(): void { @@ -93,7 +90,7 @@ public function testHolidayBeforeEstablishment(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -108,7 +105,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/UnitedKingdom/England/SummerBankHolidayTest.php b/tests/UnitedKingdom/England/SummerBankHolidayTest.php index 54070539a..f292efbd1 100644 --- a/tests/UnitedKingdom/England/SummerBankHolidayTest.php +++ b/tests/UnitedKingdom/England/SummerBankHolidayTest.php @@ -43,7 +43,6 @@ class SummerBankHolidayTest extends EnglandBaseTestCase implements HolidayTestCa * Tests the holiday defined in this test. * * @throws \Exception - * @throws \ReflectionException */ public function testHoliday(): void { @@ -60,7 +59,6 @@ public function testHoliday(): void * Tests the holiday exception in 2020. * * @throws \Exception - * @throws \ReflectionException */ public function testHolidayBefore1965(): void { @@ -76,7 +74,6 @@ public function testHolidayBefore1965(): void /** * Tests the holiday during trial period in 1965-1970. * - * @throws \ReflectionException * @throws \Exception */ public function testHolidayTrialPeriod(): void @@ -122,7 +119,7 @@ public function testHolidayTrialPeriod(): void /** * Tests the holiday defined in this test before establishment. * - * @throws \ReflectionException + * @throws \Exception */ public function testHolidayBeforeEstablishment(): void { @@ -136,7 +133,7 @@ public function testHolidayBeforeEstablishment(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws \ReflectionException + * @throws \Exception */ public function testTranslation(): void { @@ -151,7 +148,7 @@ public function testTranslation(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws \ReflectionException + * @throws \Exception */ public function testTranslationBeforeRename(): void { @@ -166,7 +163,7 @@ public function testTranslationBeforeRename(): void /** * Tests type of the holiday defined in this test. * - * @throws \ReflectionException + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/UnitedKingdom/GoodFridayTest.php b/tests/UnitedKingdom/GoodFridayTest.php index 3e8170d8f..e1b6c2d66 100644 --- a/tests/UnitedKingdom/GoodFridayTest.php +++ b/tests/UnitedKingdom/GoodFridayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -35,7 +34,6 @@ class GoodFridayTest extends UnitedKingdomBaseTestCase implements HolidayTestCas * Tests the holiday defined in this test. * * @throws Exception - * @throws ReflectionException */ public function testHoliday(): void { @@ -51,7 +49,7 @@ public function testHoliday(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -66,7 +64,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/UnitedKingdom/MayDayBankHolidayTest.php b/tests/UnitedKingdom/MayDayBankHolidayTest.php index d4f91680e..dd444a56d 100644 --- a/tests/UnitedKingdom/MayDayBankHolidayTest.php +++ b/tests/UnitedKingdom/MayDayBankHolidayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -40,7 +39,6 @@ class MayDayBankHolidayTest extends UnitedKingdomBaseTestCase implements Holiday * Tests the holiday defined in this test. * * @throws Exception - * @throws ReflectionException */ public function testHoliday(): void { @@ -56,7 +54,6 @@ public function testHoliday(): void /** * Tests the holiday exception in 1995 and 2020. * - * @throws ReflectionException * @throws Exception */ public function testHolidayExceptions(): void @@ -79,7 +76,7 @@ public function testHolidayExceptions(): void /** * Tests the holiday defined in this test before establishment. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayBeforeEstablishment(): void { @@ -93,7 +90,7 @@ public function testHolidayBeforeEstablishment(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -108,7 +105,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/UnitedKingdom/MotheringSundayTest.php b/tests/UnitedKingdom/MotheringSundayTest.php index 4717b09d8..75db801ba 100644 --- a/tests/UnitedKingdom/MotheringSundayTest.php +++ b/tests/UnitedKingdom/MotheringSundayTest.php @@ -19,7 +19,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; use Yasumi\tests\UnitedKingdom\England\EnglandBaseTestCase; @@ -31,7 +30,6 @@ class MotheringSundayTest extends EnglandBaseTestCase implements HolidayTestCase /** * @dataProvider HolidayDataProvider * - * @throws ReflectionException * @throws Exception */ public function testHoliday(int $year, string $expected): void @@ -69,7 +67,7 @@ public function HolidayDataProvider(): array } /** - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -82,7 +80,7 @@ public function testTranslation(): void } /** - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/UnitedKingdom/NewYearsDayTest.php b/tests/UnitedKingdom/NewYearsDayTest.php index 7c20b464f..322de63bd 100644 --- a/tests/UnitedKingdom/NewYearsDayTest.php +++ b/tests/UnitedKingdom/NewYearsDayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -49,7 +48,6 @@ class NewYearsDayTest extends UnitedKingdomBaseTestCase implements HolidayTestCa * @param int $year the year for which the holiday defined in this test needs to be tested * @param string $expected the expected date * - * @throws ReflectionException * @throws Exception */ public function testHolidayOnAfterEstablishment(int $year, string $expected): void @@ -65,7 +63,7 @@ public function testHolidayOnAfterEstablishment(int $year, string $expected): vo /** * Tests the holiday defined in this test before establishment. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayBeforeEstablishment(): void { @@ -79,7 +77,7 @@ public function testHolidayBeforeEstablishment(): void /** * Tests that the holiday defined in this test is of the type 'observance' before the year it was changed. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayIsObservedTypeBeforeChange(): void { @@ -106,7 +104,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -121,7 +119,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/UnitedKingdom/NorthernIreland/BattleOfTheBoyneTest.php b/tests/UnitedKingdom/NorthernIreland/BattleOfTheBoyneTest.php index e7afbc512..6e7ebb871 100644 --- a/tests/UnitedKingdom/NorthernIreland/BattleOfTheBoyneTest.php +++ b/tests/UnitedKingdom/NorthernIreland/BattleOfTheBoyneTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -44,7 +43,6 @@ class BattleOfTheBoyneTest extends NorthernIrelandBaseTestCase implements Holida * @param int $year the year for which the holiday defined in this test needs to be tested * @param string $expected the expected date * - * @throws ReflectionException * @throws Exception */ public function testHoliday(int $year, string $expected): void @@ -61,7 +59,7 @@ public function testHoliday(int $year, string $expected): void /** * Tests the holiday defined in this test before establishment. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayBeforeEstablishment(): void { @@ -95,7 +93,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -110,7 +108,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/UnitedKingdom/NorthernIreland/BoxingDayTest.php b/tests/UnitedKingdom/NorthernIreland/BoxingDayTest.php index 61b11a906..c878a95c9 100644 --- a/tests/UnitedKingdom/NorthernIreland/BoxingDayTest.php +++ b/tests/UnitedKingdom/NorthernIreland/BoxingDayTest.php @@ -18,7 +18,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -40,7 +39,6 @@ class BoxingDayTest extends NorthernIrelandBaseTestCase implements HolidayTestCa * @param int $year the year for which the holiday defined in this test needs to be tested * @param string $expected the expected date * - * @throws ReflectionException * @throws Exception */ public function testHoliday(int $year, string $expected): void @@ -79,7 +77,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -94,7 +92,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/UnitedKingdom/NorthernIreland/ChristmasDayTest.php b/tests/UnitedKingdom/NorthernIreland/ChristmasDayTest.php index a95578df8..d850fdff8 100644 --- a/tests/UnitedKingdom/NorthernIreland/ChristmasDayTest.php +++ b/tests/UnitedKingdom/NorthernIreland/ChristmasDayTest.php @@ -18,7 +18,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -40,7 +39,6 @@ class ChristmasDayTest extends NorthernIrelandBaseTestCase implements HolidayTes * @param int $year the year for which the holiday defined in this test needs to be tested * @param string $expected the expected date * - * @throws ReflectionException * @throws Exception */ public function testHoliday(int $year, string $expected): void @@ -79,7 +77,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -94,7 +92,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/UnitedKingdom/NorthernIreland/EasterMondayTest.php b/tests/UnitedKingdom/NorthernIreland/EasterMondayTest.php index ea65fae74..6b507e5b7 100644 --- a/tests/UnitedKingdom/NorthernIreland/EasterMondayTest.php +++ b/tests/UnitedKingdom/NorthernIreland/EasterMondayTest.php @@ -18,7 +18,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -40,7 +39,6 @@ class EasterMondayTest extends NorthernIrelandBaseTestCase implements HolidayTes * @param int $year the year for which the holiday defined in this test needs to be tested * @param string $expected the expected date * - * @throws ReflectionException * @throws Exception */ public function testHoliday(int $year, string $expected): void @@ -78,7 +76,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -93,7 +91,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/UnitedKingdom/NorthernIreland/GoodFridayTest.php b/tests/UnitedKingdom/NorthernIreland/GoodFridayTest.php index 74bbcbdcd..48a9a20d2 100644 --- a/tests/UnitedKingdom/NorthernIreland/GoodFridayTest.php +++ b/tests/UnitedKingdom/NorthernIreland/GoodFridayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -35,7 +34,6 @@ class GoodFridayTest extends NorthernIrelandBaseTestCase implements HolidayTestC * Tests the holiday defined in this test. * * @throws Exception - * @throws ReflectionException */ public function testHoliday(): void { @@ -51,7 +49,7 @@ public function testHoliday(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -66,7 +64,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/UnitedKingdom/NorthernIreland/MayDayBankHolidayTest.php b/tests/UnitedKingdom/NorthernIreland/MayDayBankHolidayTest.php index a60cb5f4d..d8005ad3d 100644 --- a/tests/UnitedKingdom/NorthernIreland/MayDayBankHolidayTest.php +++ b/tests/UnitedKingdom/NorthernIreland/MayDayBankHolidayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -40,7 +39,6 @@ class MayDayBankHolidayTest extends NorthernIrelandBaseTestCase implements Holid * Tests the holiday defined in this test. * * @throws Exception - * @throws ReflectionException */ public function testHoliday(): void { @@ -56,7 +54,6 @@ public function testHoliday(): void /** * Tests the holiday exception in 1995 and 2020. * - * @throws ReflectionException * @throws Exception */ public function testHolidayExceptions(): void @@ -79,7 +76,7 @@ public function testHolidayExceptions(): void /** * Tests the holiday defined in this test before establishment. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayBeforeEstablishment(): void { @@ -93,7 +90,7 @@ public function testHolidayBeforeEstablishment(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -108,7 +105,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/UnitedKingdom/NorthernIreland/NewYearsDayTest.php b/tests/UnitedKingdom/NorthernIreland/NewYearsDayTest.php index 54d318d15..3e2bae4c5 100644 --- a/tests/UnitedKingdom/NorthernIreland/NewYearsDayTest.php +++ b/tests/UnitedKingdom/NorthernIreland/NewYearsDayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -49,7 +48,6 @@ class NewYearsDayTest extends NorthernIrelandBaseTestCase implements HolidayTest * @param int $year the year for which the holiday defined in this test needs to be tested * @param string $expected the expected date * - * @throws ReflectionException * @throws Exception */ public function testHolidayOnAfterEstablishment(int $year, string $expected): void @@ -65,7 +63,7 @@ public function testHolidayOnAfterEstablishment(int $year, string $expected): vo /** * Tests the holiday defined in this test before establishment. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayBeforeEstablishment(): void { @@ -79,7 +77,7 @@ public function testHolidayBeforeEstablishment(): void /** * Tests that the holiday defined in this test is of the type 'observance' before the year it was changed. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayIsObservedTypeBeforeChange(): void { @@ -106,7 +104,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -121,7 +119,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/UnitedKingdom/NorthernIreland/NorthernIrelandTest.php b/tests/UnitedKingdom/NorthernIreland/NorthernIrelandTest.php index 203b91f2f..025f804a8 100644 --- a/tests/UnitedKingdom/NorthernIreland/NorthernIrelandTest.php +++ b/tests/UnitedKingdom/NorthernIreland/NorthernIrelandTest.php @@ -26,10 +26,12 @@ class NorthernIrelandTest extends NorthernIrelandBaseTestCase implements Provide /** * @var int year random year number used for all tests in this Test Case */ - protected $year; + protected int $year; /** * Initial setup of this Test Case. + * + * @throws \Exception */ protected function setUp(): void { @@ -38,8 +40,6 @@ protected function setUp(): void /** * Tests if all official holidays in Northern Ireland are defined by the provider class. - * - * @throws ReflectionException */ public function testOfficialHolidays(): void { @@ -51,8 +51,6 @@ public function testOfficialHolidays(): void /** * Tests if all observed holidays in Northern Ireland are defined by the provider class. - * - * @throws ReflectionException */ public function testObservedHolidays(): void { @@ -61,8 +59,6 @@ public function testObservedHolidays(): void /** * Tests if all seasonal holidays in Northern Ireland are defined by the provider class. - * - * @throws ReflectionException */ public function testSeasonalHolidays(): void { @@ -71,8 +67,6 @@ public function testSeasonalHolidays(): void /** * Tests if all bank holidays in Northern Ireland are defined by the provider class. - * - * @throws ReflectionException */ public function testBankHolidays(): void { @@ -88,8 +82,6 @@ public function testBankHolidays(): void /** * Tests if all other holidays in Northern Ireland are defined by the provider class. - * - * @throws ReflectionException */ public function testOtherHolidays(): void { @@ -98,6 +90,7 @@ public function testOtherHolidays(): void /** * @throws ReflectionException + * @throws \Exception */ public function testSources(): void { diff --git a/tests/UnitedKingdom/NorthernIreland/SpringBankHolidayTest.php b/tests/UnitedKingdom/NorthernIreland/SpringBankHolidayTest.php index dedf403a3..1e52e9d81 100644 --- a/tests/UnitedKingdom/NorthernIreland/SpringBankHolidayTest.php +++ b/tests/UnitedKingdom/NorthernIreland/SpringBankHolidayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -40,7 +39,6 @@ class SpringBankHolidayTest extends NorthernIrelandBaseTestCase implements Holid * Tests the holiday defined in this test. * * @throws Exception - * @throws ReflectionException */ public function testHoliday(): void { @@ -56,7 +54,7 @@ public function testHoliday(): void /** * Tests the holiday defined in this test before establishment. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayBeforeEstablishment(): void { @@ -70,7 +68,7 @@ public function testHolidayBeforeEstablishment(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -85,7 +83,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/UnitedKingdom/NorthernIreland/StPatricksDayTest.php b/tests/UnitedKingdom/NorthernIreland/StPatricksDayTest.php index 85430e391..c104f7a83 100644 --- a/tests/UnitedKingdom/NorthernIreland/StPatricksDayTest.php +++ b/tests/UnitedKingdom/NorthernIreland/StPatricksDayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -44,7 +43,6 @@ class StPatricksDayTest extends NorthernIrelandBaseTestCase implements HolidayTe * @param int $year the year for which the holiday defined in this test needs to be tested * @param string $expected the expected date * - * @throws ReflectionException * @throws Exception */ public function testHoliday(int $year, string $expected): void @@ -61,7 +59,7 @@ public function testHoliday(int $year, string $expected): void /** * Tests the holiday defined in this test before establishment. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayBeforeEstablishment(): void { @@ -95,7 +93,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -110,7 +108,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/UnitedKingdom/NorthernIreland/SummerBankHolidayTest.php b/tests/UnitedKingdom/NorthernIreland/SummerBankHolidayTest.php index 6678181c9..7528be410 100644 --- a/tests/UnitedKingdom/NorthernIreland/SummerBankHolidayTest.php +++ b/tests/UnitedKingdom/NorthernIreland/SummerBankHolidayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -45,7 +44,6 @@ class SummerBankHolidayTest extends NorthernIrelandBaseTestCase implements Holid * Tests the holiday defined in this test. * * @throws Exception - * @throws ReflectionException */ public function testHoliday(): void { @@ -61,7 +59,6 @@ public function testHoliday(): void /** * Tests the holiday exception in 2020. * - * @throws ReflectionException * @throws Exception */ public function testHolidayBefore1965(): void @@ -78,7 +75,6 @@ public function testHolidayBefore1965(): void /** * Tests the holiday during trial period in 1965-1970. * - * @throws ReflectionException * @throws Exception */ public function testHolidayTrialPeriod(): void @@ -124,7 +120,7 @@ public function testHolidayTrialPeriod(): void /** * Tests the holiday defined in this test before establishment. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayBeforeEstablishment(): void { @@ -138,7 +134,7 @@ public function testHolidayBeforeEstablishment(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -153,7 +149,7 @@ public function testTranslation(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslationBeforeRename(): void { @@ -168,7 +164,7 @@ public function testTranslationBeforeRename(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/UnitedKingdom/PlatinumJubileeBankHolidayTest.php b/tests/UnitedKingdom/PlatinumJubileeBankHolidayTest.php index 1a5200b2d..2dd9bbbb7 100644 --- a/tests/UnitedKingdom/PlatinumJubileeBankHolidayTest.php +++ b/tests/UnitedKingdom/PlatinumJubileeBankHolidayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -45,7 +44,6 @@ class PlatinumJubileeBankHolidayTest extends UnitedKingdomBaseTestCase implement * Tests the holiday defined in this test. * * @throws Exception - * @throws ReflectionException */ public function testHoliday(): void { @@ -60,7 +58,7 @@ public function testHoliday(): void /** * Tests the holiday defined in this test before the year in which it occurred. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayBeforeActive(): void { @@ -74,7 +72,7 @@ public function testHolidayBeforeActive(): void /** * Tests the holiday defined in this test after the year in which it occurred. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayAfterActive(): void { @@ -87,8 +85,6 @@ public function testHolidayAfterActive(): void /** * Tests the translated name of the holiday defined in this test. - * - * @throws ReflectionException */ public function testTranslation(): void { @@ -102,8 +98,6 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. - * - * @throws ReflectionException */ public function testHolidayType(): void { diff --git a/tests/UnitedKingdom/Scotland/BoxingDayTest.php b/tests/UnitedKingdom/Scotland/BoxingDayTest.php index 37e14d9f5..bc70ff8f2 100644 --- a/tests/UnitedKingdom/Scotland/BoxingDayTest.php +++ b/tests/UnitedKingdom/Scotland/BoxingDayTest.php @@ -18,7 +18,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -40,7 +39,6 @@ class BoxingDayTest extends ScotlandBaseTestCase implements HolidayTestCase * @param int $year the year for which the holiday defined in this test needs to be tested * @param string $expected the expected date * - * @throws ReflectionException * @throws Exception */ public function testHoliday(int $year, string $expected): void @@ -79,7 +77,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -94,7 +92,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/UnitedKingdom/Scotland/ChristmasDayTest.php b/tests/UnitedKingdom/Scotland/ChristmasDayTest.php index c00ae6d06..2b74cac48 100644 --- a/tests/UnitedKingdom/Scotland/ChristmasDayTest.php +++ b/tests/UnitedKingdom/Scotland/ChristmasDayTest.php @@ -18,7 +18,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -40,7 +39,6 @@ class ChristmasDayTest extends ScotlandBaseTestCase implements HolidayTestCase * @param int $year the year for which the holiday defined in this test needs to be tested * @param string $expected the expected date * - * @throws ReflectionException * @throws Exception */ public function testHoliday(int $year, string $expected): void @@ -79,7 +77,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -94,7 +92,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/UnitedKingdom/Scotland/GoodFridayTest.php b/tests/UnitedKingdom/Scotland/GoodFridayTest.php index b33bf19c0..af9c34112 100644 --- a/tests/UnitedKingdom/Scotland/GoodFridayTest.php +++ b/tests/UnitedKingdom/Scotland/GoodFridayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -35,7 +34,6 @@ class GoodFridayTest extends ScotlandBaseTestCase implements HolidayTestCase * Tests the holiday defined in this test. * * @throws Exception - * @throws ReflectionException */ public function testHoliday(): void { @@ -51,7 +49,7 @@ public function testHoliday(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -66,7 +64,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/UnitedKingdom/Scotland/MayDayBankHolidayTest.php b/tests/UnitedKingdom/Scotland/MayDayBankHolidayTest.php index d2616bfa0..6b58ed22d 100644 --- a/tests/UnitedKingdom/Scotland/MayDayBankHolidayTest.php +++ b/tests/UnitedKingdom/Scotland/MayDayBankHolidayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -40,7 +39,6 @@ class MayDayBankHolidayTest extends ScotlandBaseTestCase implements HolidayTestC * Tests the holiday defined in this test. * * @throws Exception - * @throws ReflectionException */ public function testHoliday(): void { @@ -56,7 +54,6 @@ public function testHoliday(): void /** * Tests the holiday exception in 1995 and 2020. * - * @throws ReflectionException * @throws Exception */ public function testHolidayExceptions(): void @@ -79,7 +76,7 @@ public function testHolidayExceptions(): void /** * Tests the holiday defined in this test before establishment. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayBeforeEstablishment(): void { @@ -93,7 +90,7 @@ public function testHolidayBeforeEstablishment(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -108,7 +105,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/UnitedKingdom/Scotland/NewYearsDayTest.php b/tests/UnitedKingdom/Scotland/NewYearsDayTest.php index 08913d82a..275e382f1 100644 --- a/tests/UnitedKingdom/Scotland/NewYearsDayTest.php +++ b/tests/UnitedKingdom/Scotland/NewYearsDayTest.php @@ -18,7 +18,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -50,7 +49,6 @@ class NewYearsDayTest extends ScotlandBaseTestCase implements HolidayTestCase * @param int $year the year for which the holiday defined in this test needs to be tested * @param string $expected the expected date * - * @throws ReflectionException * @throws Exception */ public function testHolidayOnAfterEstablishment(int $year, string $expected): void @@ -67,7 +65,7 @@ public function testHolidayOnAfterEstablishment(int $year, string $expected): vo /** * Tests the holiday defined in this test before establishment. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayBeforeEstablishment(): void { @@ -81,7 +79,7 @@ public function testHolidayBeforeEstablishment(): void /** * Tests that the holiday defined in this test is of the type 'observance' before the year it was changed. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayIsObservedTypeBeforeChange(): void { @@ -116,7 +114,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -131,7 +129,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/UnitedKingdom/Scotland/ScotlandTest.php b/tests/UnitedKingdom/Scotland/ScotlandTest.php index 53162b0ef..49d78a0c1 100644 --- a/tests/UnitedKingdom/Scotland/ScotlandTest.php +++ b/tests/UnitedKingdom/Scotland/ScotlandTest.php @@ -26,10 +26,12 @@ class ScotlandTest extends ScotlandBaseTestCase implements ProviderTestCase /** * @var int year random year number used for all tests in this Test Case */ - protected $year; + protected int $year; /** * Initial setup of this Test Case. + * + * @throws \Exception */ protected function setUp(): void { @@ -38,8 +40,6 @@ protected function setUp(): void /** * Tests if all official holidays in Scotland are defined by the provider class. - * - * @throws ReflectionException */ public function testOfficialHolidays(): void { @@ -49,8 +49,6 @@ public function testOfficialHolidays(): void /** * Tests if all observed holidays in Scotland are defined by the provider class. - * - * @throws ReflectionException */ public function testObservedHolidays(): void { @@ -59,8 +57,6 @@ public function testObservedHolidays(): void /** * Tests if all seasonal holidays in Scotland are defined by the provider class. - * - * @throws ReflectionException */ public function testSeasonalHolidays(): void { @@ -69,8 +65,6 @@ public function testSeasonalHolidays(): void /** * Tests if all bank holidays in Scotland are defined by the provider class. - * - * @throws ReflectionException */ public function testBankHolidays(): void { @@ -86,8 +80,6 @@ public function testBankHolidays(): void /** * Tests if all other holidays in Scotland are defined by the provider class. - * - * @throws ReflectionException */ public function testOtherHolidays(): void { @@ -96,6 +88,7 @@ public function testOtherHolidays(): void /** * @throws ReflectionException + * @throws \Exception */ public function testSources(): void { diff --git a/tests/UnitedKingdom/Scotland/SecondNewYearsDayTest.php b/tests/UnitedKingdom/Scotland/SecondNewYearsDayTest.php index a4492d69c..9abfc0a8d 100644 --- a/tests/UnitedKingdom/Scotland/SecondNewYearsDayTest.php +++ b/tests/UnitedKingdom/Scotland/SecondNewYearsDayTest.php @@ -18,7 +18,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -50,7 +49,6 @@ class SecondNewYearsDayTest extends ScotlandBaseTestCase implements HolidayTestC * @param int $year the year for which the holiday defined in this test needs to be tested * @param string $expected the expected date * - * @throws ReflectionException * @throws Exception */ public function testHolidayOnAfterEstablishment(int $year, string $expected): void @@ -67,7 +65,7 @@ public function testHolidayOnAfterEstablishment(int $year, string $expected): vo /** * Tests the holiday defined in this test before establishment. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayBeforeEstablishment(): void { @@ -81,7 +79,7 @@ public function testHolidayBeforeEstablishment(): void /** * Tests that the holiday defined in this test is of the type 'observance' before the year it was changed. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayIsObservedTypeBeforeChange(): void { @@ -116,7 +114,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -131,7 +129,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/UnitedKingdom/Scotland/SpringBankHolidayTest.php b/tests/UnitedKingdom/Scotland/SpringBankHolidayTest.php index 5e6a83e3f..4c3a26747 100644 --- a/tests/UnitedKingdom/Scotland/SpringBankHolidayTest.php +++ b/tests/UnitedKingdom/Scotland/SpringBankHolidayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -40,7 +39,6 @@ class SpringBankHolidayTest extends ScotlandBaseTestCase implements HolidayTestC * Tests the holiday defined in this test. * * @throws Exception - * @throws ReflectionException */ public function testHoliday(): void { @@ -56,7 +54,7 @@ public function testHoliday(): void /** * Tests the holiday defined in this test before establishment. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayBeforeEstablishment(): void { @@ -70,7 +68,7 @@ public function testHolidayBeforeEstablishment(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -85,7 +83,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/UnitedKingdom/Scotland/StAndrewsDayTest.php b/tests/UnitedKingdom/Scotland/StAndrewsDayTest.php index a2b39a341..a5d5980b8 100644 --- a/tests/UnitedKingdom/Scotland/StAndrewsDayTest.php +++ b/tests/UnitedKingdom/Scotland/StAndrewsDayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -44,7 +43,6 @@ class StAndrewsDayTest extends ScotlandBaseTestCase implements HolidayTestCase * @param int $year the year for which the holiday defined in this test needs to be tested * @param string $expected the expected date * - * @throws ReflectionException * @throws Exception */ public function testHoliday(int $year, string $expected): void @@ -81,7 +79,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -96,7 +94,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/UnitedKingdom/Scotland/SummerBankHolidayTest.php b/tests/UnitedKingdom/Scotland/SummerBankHolidayTest.php index 59dad9593..dc5823834 100644 --- a/tests/UnitedKingdom/Scotland/SummerBankHolidayTest.php +++ b/tests/UnitedKingdom/Scotland/SummerBankHolidayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -40,7 +39,6 @@ class SummerBankHolidayTest extends ScotlandBaseTestCase implements HolidayTestC * Tests the holiday defined in this test. * * @throws Exception - * @throws ReflectionException */ public function testHoliday(): void { @@ -56,7 +54,7 @@ public function testHoliday(): void /** * Tests the holiday defined in this test before establishment. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayBeforeEstablishment(): void { @@ -70,7 +68,7 @@ public function testHolidayBeforeEstablishment(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -85,7 +83,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/UnitedKingdom/SpringBankHolidayTest.php b/tests/UnitedKingdom/SpringBankHolidayTest.php index 9762e0078..c969a4d37 100644 --- a/tests/UnitedKingdom/SpringBankHolidayTest.php +++ b/tests/UnitedKingdom/SpringBankHolidayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -40,7 +39,6 @@ class SpringBankHolidayTest extends UnitedKingdomBaseTestCase implements Holiday * Tests the holiday defined in this test. * * @throws Exception - * @throws ReflectionException */ public function testHoliday(): void { @@ -56,7 +54,6 @@ public function testHoliday(): void /** * Tests the holiday exceptions in 2002, 2012 and 2022. * - * @throws ReflectionException * @throws Exception */ public function testHolidayException(): void @@ -86,7 +83,7 @@ public function testHolidayException(): void /** * Tests the holiday defined in this test before establishment. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayBeforeEstablishment(): void { @@ -100,7 +97,7 @@ public function testHolidayBeforeEstablishment(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -115,7 +112,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/UnitedKingdom/SummerBankHolidayTest.php b/tests/UnitedKingdom/SummerBankHolidayTest.php index 104a6a95e..7a5d6856b 100644 --- a/tests/UnitedKingdom/SummerBankHolidayTest.php +++ b/tests/UnitedKingdom/SummerBankHolidayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -45,7 +44,6 @@ class SummerBankHolidayTest extends UnitedKingdomBaseTestCase implements Holiday * Tests the holiday defined in this test. * * @throws Exception - * @throws ReflectionException */ public function testHoliday(): void { @@ -61,7 +59,6 @@ public function testHoliday(): void /** * Tests the holiday exception in 2020. * - * @throws ReflectionException * @throws Exception */ public function testHolidayBefore1965(): void @@ -78,7 +75,6 @@ public function testHolidayBefore1965(): void /** * Tests the holiday during trial period in 1965-1970. * - * @throws ReflectionException * @throws Exception */ public function testHolidayTrialPeriod(): void @@ -124,7 +120,7 @@ public function testHolidayTrialPeriod(): void /** * Tests the holiday defined in this test before establishment. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayBeforeEstablishment(): void { @@ -138,7 +134,7 @@ public function testHolidayBeforeEstablishment(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -153,7 +149,7 @@ public function testTranslation(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslationBeforeRename(): void { @@ -168,7 +164,7 @@ public function testTranslationBeforeRename(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/UnitedKingdom/UnitedKingdomTest.php b/tests/UnitedKingdom/UnitedKingdomTest.php index e50979293..4a4a049f3 100644 --- a/tests/UnitedKingdom/UnitedKingdomTest.php +++ b/tests/UnitedKingdom/UnitedKingdomTest.php @@ -26,10 +26,12 @@ class UnitedKingdomTest extends UnitedKingdomBaseTestCase implements ProviderTes /** * @var int year random year number used for all tests in this Test Case */ - protected $year; + protected int $year; /** * Initial setup of this Test Case. + * + * @throws \Exception */ protected function setUp(): void { @@ -38,8 +40,6 @@ protected function setUp(): void /** * Tests if all official holidays in the United Kingdom are defined by the provider class. - * - * @throws ReflectionException */ public function testOfficialHolidays(): void { @@ -51,8 +51,6 @@ public function testOfficialHolidays(): void /** * Tests if all observed holidays in the United Kingdom are defined by the provider class. - * - * @throws ReflectionException */ public function testObservedHolidays(): void { @@ -61,8 +59,6 @@ public function testObservedHolidays(): void /** * Tests if all seasonal holidays in the United Kingdom are defined by the provider class. - * - * @throws ReflectionException */ public function testSeasonalHolidays(): void { @@ -71,8 +67,6 @@ public function testSeasonalHolidays(): void /** * Tests if all bank holidays in the United Kingdom are defined by the provider class. - * - * @throws ReflectionException */ public function testBankHolidays(): void { @@ -87,8 +81,6 @@ public function testBankHolidays(): void /** * Tests if all other holidays in the United Kingdom are defined by the provider class. - * - * @throws ReflectionException */ public function testOtherHolidays(): void { @@ -97,6 +89,7 @@ public function testOtherHolidays(): void /** * @throws ReflectionException + * @throws \Exception */ public function testSources(): void { diff --git a/tests/UnitedKingdom/Wales/BoxingDayTest.php b/tests/UnitedKingdom/Wales/BoxingDayTest.php index dcd153923..b16cebac0 100644 --- a/tests/UnitedKingdom/Wales/BoxingDayTest.php +++ b/tests/UnitedKingdom/Wales/BoxingDayTest.php @@ -18,7 +18,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -40,7 +39,6 @@ class BoxingDayTest extends WalesBaseTestCase implements HolidayTestCase * @param int $year the year for which the holiday defined in this test needs to be tested * @param string $expected the expected date * - * @throws ReflectionException * @throws Exception */ public function testHoliday(int $year, string $expected): void @@ -79,7 +77,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -94,7 +92,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/UnitedKingdom/Wales/ChristmasDayTest.php b/tests/UnitedKingdom/Wales/ChristmasDayTest.php index 2fb282aef..27ab6f961 100644 --- a/tests/UnitedKingdom/Wales/ChristmasDayTest.php +++ b/tests/UnitedKingdom/Wales/ChristmasDayTest.php @@ -18,7 +18,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -40,7 +39,6 @@ class ChristmasDayTest extends WalesBaseTestCase implements HolidayTestCase * @param int $year the year for which the holiday defined in this test needs to be tested * @param string $expected the expected date * - * @throws ReflectionException * @throws Exception */ public function testHoliday(int $year, string $expected): void @@ -79,7 +77,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -94,7 +92,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/UnitedKingdom/Wales/EasterMondayTest.php b/tests/UnitedKingdom/Wales/EasterMondayTest.php index 8e07b0d95..a7c6fc014 100644 --- a/tests/UnitedKingdom/Wales/EasterMondayTest.php +++ b/tests/UnitedKingdom/Wales/EasterMondayTest.php @@ -18,7 +18,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -40,7 +39,6 @@ class EasterMondayTest extends WalesBaseTestCase implements HolidayTestCase * @param int $year the year for which the holiday defined in this test needs to be tested * @param string $expected the expected date * - * @throws ReflectionException * @throws Exception */ public function testHoliday(int $year, string $expected): void @@ -78,7 +76,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -93,7 +91,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/UnitedKingdom/Wales/GoodFridayTest.php b/tests/UnitedKingdom/Wales/GoodFridayTest.php index d31ee8e8a..6883ffc44 100644 --- a/tests/UnitedKingdom/Wales/GoodFridayTest.php +++ b/tests/UnitedKingdom/Wales/GoodFridayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -35,7 +34,6 @@ class GoodFridayTest extends WalesBaseTestCase implements HolidayTestCase * Tests the holiday defined in this test. * * @throws Exception - * @throws ReflectionException */ public function testHoliday(): void { @@ -51,7 +49,7 @@ public function testHoliday(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -66,7 +64,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/UnitedKingdom/Wales/MayDayBankHolidayTest.php b/tests/UnitedKingdom/Wales/MayDayBankHolidayTest.php index f43fe3d68..7a4429788 100644 --- a/tests/UnitedKingdom/Wales/MayDayBankHolidayTest.php +++ b/tests/UnitedKingdom/Wales/MayDayBankHolidayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -40,7 +39,6 @@ class MayDayBankHolidayTest extends WalesBaseTestCase implements HolidayTestCase * Tests the holiday defined in this test. * * @throws Exception - * @throws ReflectionException */ public function testHoliday(): void { @@ -56,7 +54,6 @@ public function testHoliday(): void /** * Tests the holiday exception in 1995 and 2020. * - * @throws ReflectionException * @throws Exception */ public function testHolidayExceptions(): void @@ -79,7 +76,7 @@ public function testHolidayExceptions(): void /** * Tests the holiday defined in this test before establishment. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayBeforeEstablishment(): void { @@ -93,7 +90,7 @@ public function testHolidayBeforeEstablishment(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -108,7 +105,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/UnitedKingdom/Wales/NewYearsDayTest.php b/tests/UnitedKingdom/Wales/NewYearsDayTest.php index 77d673e3f..a845eadbd 100644 --- a/tests/UnitedKingdom/Wales/NewYearsDayTest.php +++ b/tests/UnitedKingdom/Wales/NewYearsDayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -49,7 +48,6 @@ class NewYearsDayTest extends WalesBaseTestCase implements HolidayTestCase * @param int $year the year for which the holiday defined in this test needs to be tested * @param string $expected the expected date * - * @throws ReflectionException * @throws Exception */ public function testHolidayOnAfterEstablishment(int $year, string $expected): void @@ -65,7 +63,7 @@ public function testHolidayOnAfterEstablishment(int $year, string $expected): vo /** * Tests the holiday defined in this test before establishment. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayBeforeEstablishment(): void { @@ -79,7 +77,7 @@ public function testHolidayBeforeEstablishment(): void /** * Tests that the holiday defined in this test is of the type 'observance' before the year it was changed. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayIsObservedTypeBeforeChange(): void { @@ -106,7 +104,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -121,7 +119,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/UnitedKingdom/Wales/SpringBankHolidayTest.php b/tests/UnitedKingdom/Wales/SpringBankHolidayTest.php index 1bed1806d..0aebb0e3c 100644 --- a/tests/UnitedKingdom/Wales/SpringBankHolidayTest.php +++ b/tests/UnitedKingdom/Wales/SpringBankHolidayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -40,7 +39,6 @@ class SpringBankHolidayTest extends WalesBaseTestCase implements HolidayTestCase * Tests the holiday defined in this test. * * @throws Exception - * @throws ReflectionException */ public function testHoliday(): void { @@ -56,7 +54,6 @@ public function testHoliday(): void /** * Tests the holiday exceptions in 2002 and 2012. * - * @throws ReflectionException * @throws Exception */ public function testHolidayException(): void @@ -79,7 +76,7 @@ public function testHolidayException(): void /** * Tests the holiday defined in this test before establishment. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayBeforeEstablishment(): void { @@ -93,7 +90,7 @@ public function testHolidayBeforeEstablishment(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -108,7 +105,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/UnitedKingdom/Wales/SummerBankHolidayTest.php b/tests/UnitedKingdom/Wales/SummerBankHolidayTest.php index 9cc37231e..f874b675c 100644 --- a/tests/UnitedKingdom/Wales/SummerBankHolidayTest.php +++ b/tests/UnitedKingdom/Wales/SummerBankHolidayTest.php @@ -17,7 +17,6 @@ use DateTime; use DateTimeZone; use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -45,7 +44,6 @@ class SummerBankHolidayTest extends WalesBaseTestCase implements HolidayTestCase * Tests the holiday defined in this test. * * @throws Exception - * @throws ReflectionException */ public function testHoliday(): void { @@ -61,7 +59,6 @@ public function testHoliday(): void /** * Tests the holiday exception in 2020. * - * @throws ReflectionException * @throws Exception */ public function testHolidayBefore1965(): void @@ -78,7 +75,6 @@ public function testHolidayBefore1965(): void /** * Tests the holiday during trial period in 1965-1970. * - * @throws ReflectionException * @throws Exception */ public function testHolidayTrialPeriod(): void @@ -124,7 +120,7 @@ public function testHolidayTrialPeriod(): void /** * Tests the holiday defined in this test before establishment. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayBeforeEstablishment(): void { @@ -138,7 +134,7 @@ public function testHolidayBeforeEstablishment(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslation(): void { @@ -153,7 +149,7 @@ public function testTranslation(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testTranslationBeforeRename(): void { @@ -168,7 +164,7 @@ public function testTranslationBeforeRename(): void /** * Tests type of the holiday defined in this test. * - * @throws ReflectionException + * @throws Exception */ public function testHolidayType(): void { diff --git a/tests/UnitedKingdom/Wales/WalesTest.php b/tests/UnitedKingdom/Wales/WalesTest.php index 7eda1f42e..3d7b0835e 100644 --- a/tests/UnitedKingdom/Wales/WalesTest.php +++ b/tests/UnitedKingdom/Wales/WalesTest.php @@ -26,10 +26,12 @@ class WalesTest extends WalesBaseTestCase implements ProviderTestCase /** * @var int year random year number used for all tests in this Test Case */ - protected $year; + protected int $year; /** * Initial setup of this Test Case. + * + * @throws \Exception */ protected function setUp(): void { @@ -38,8 +40,6 @@ protected function setUp(): void /** * Tests if all official holidays in Wales are defined by the provider class. - * - * @throws ReflectionException */ public function testOfficialHolidays(): void { @@ -51,8 +51,6 @@ public function testOfficialHolidays(): void /** * Tests if all observed holidays in Wales are defined by the provider class. - * - * @throws ReflectionException */ public function testObservedHolidays(): void { @@ -61,8 +59,6 @@ public function testObservedHolidays(): void /** * Tests if all seasonal holidays in Wales are defined by the provider class. - * - * @throws ReflectionException */ public function testSeasonalHolidays(): void { @@ -71,8 +67,6 @@ public function testSeasonalHolidays(): void /** * Tests if all bank holidays in Wales are defined by the provider class. - * - * @throws ReflectionException */ public function testBankHolidays(): void { @@ -87,8 +81,6 @@ public function testBankHolidays(): void /** * Tests if all other holidays in Wales are defined by the provider class. - * - * @throws ReflectionException */ public function testOtherHolidays(): void { @@ -97,6 +89,7 @@ public function testOtherHolidays(): void /** * @throws ReflectionException + * @throws \Exception */ public function testSources(): void { diff --git a/tests/YasumiBase.php b/tests/YasumiBase.php index e5f183323..b391c7cda 100644 --- a/tests/YasumiBase.php +++ b/tests/YasumiBase.php @@ -218,7 +218,7 @@ public function assertTranslatedHolidayName( self::assertInstanceOf(Holiday::class, $holiday); self::assertTrue($holidays->isHoliday($holiday)); - if (\is_array($translations) && !empty($translations)) { + if (!empty($translations)) { foreach ($translations as $locale => $name) { $locales = [$locale]; $parts = explode('_', $locale); @@ -709,14 +709,14 @@ protected function calculateEaster(int $year, string $timezone): DateTimeInterfa protected static function getMaxTimestamp($max = 'now') { if (is_numeric($max)) { - return (int) $max; - } - - if ($max instanceof \DateTime) { - return $max->getTimestamp(); + $ts = (int) $max; + } elseif ($max instanceof \DateTime) { + $ts = $max->getTimestamp(); + } else { + $ts = strtotime(empty($max) ? 'now' : $max); } - return strtotime(empty($max) ? 'now' : $max); + return $ts; } /** From abdaa729e7cfd39f3192d5a960650d16210fc186 Mon Sep 17 00:00:00 2001 From: Sacha Telgenhof Date: Sat, 5 Feb 2022 16:59:50 +0900 Subject: [PATCH 018/142] Reverted Phan's config to analyse only the src directory. --- .phan/config.php | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/.phan/config.php b/.phan/config.php index 1b53e48ef..5ec6e6b5f 100644 --- a/.phan/config.php +++ b/.phan/config.php @@ -349,14 +349,12 @@ // Thus, both first-party and third-party code being used by // your application should be included in this list. 'directory_list' => [ - 'src', - 'test' + 'src' ], // A list of individual files to include in analysis // with a path relative to the root directory of the // project. 'file_list' => [ - 'vendor/phpunit/phpunit/src/Framework/Assert.php' ], ]; From 4632a8283cf0aae2aad06224fb268be8dbd7e48b Mon Sep 17 00:00:00 2001 From: Sacha Telgenhof Date: Sat, 5 Feb 2022 17:15:54 +0900 Subject: [PATCH 019/142] Cast the output to allow for strict type comparison. Signed-off-by: Sacha Telgenhof --- src/Yasumi/Yasumi.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/Yasumi/Yasumi.php b/src/Yasumi/Yasumi.php index fbefba16e..edc389a5b 100755 --- a/src/Yasumi/Yasumi.php +++ b/src/Yasumi/Yasumi.php @@ -90,7 +90,7 @@ public static function nextWorkingDay( if (!$provider instanceof ProviderInterface) { $provider = self::create($class, (int) $date->format('Y')); - } elseif ($provider->getYear() !== $date->format('Y')) { + } elseif ($provider->getYear() !== (int) $date->format('Y')) { $provider = self::create($class, (int) $date->format('Y')); } @@ -280,7 +280,7 @@ public static function prevWorkingDay( if (!$provider instanceof ProviderInterface) { $provider = self::create($class, (int) $date->format('Y')); - } elseif ($provider->getYear() !== $date->format('Y')) { + } elseif ($provider->getYear() !== (int) $date->format('Y')) { $provider = self::create($class, (int) $date->format('Y')); } From 7e4fcc3c3aebf1cc04a0271d1a7b4addaadcf1e5 Mon Sep 17 00:00:00 2001 From: Sacha Telgenhof Date: Sat, 5 Feb 2022 17:40:55 +0900 Subject: [PATCH 020/142] `calculateSummerWinterTime` is an internal method and shouldn't be accessible directly. --- src/Yasumi/Provider/CommonHolidays.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/Yasumi/Provider/CommonHolidays.php b/src/Yasumi/Provider/CommonHolidays.php index aea86a0eb..23eb17759 100644 --- a/src/Yasumi/Provider/CommonHolidays.php +++ b/src/Yasumi/Provider/CommonHolidays.php @@ -503,7 +503,7 @@ protected function winterTime( * * @throws \Exception */ - protected function calculateSummerWinterTime( + private function calculateSummerWinterTime( int $year, string $timezone, bool $summer From 039edc923cb195872f96c3d76ce68fe562c9861b Mon Sep 17 00:00:00 2001 From: Sacha Telgenhof Date: Sat, 5 Feb 2022 17:42:02 +0900 Subject: [PATCH 021/142] Removed tests folder from analysis (the large number of files make running analysis take a long time). --- phpstan.neon.dist | 1 - 1 file changed, 1 deletion(-) diff --git a/phpstan.neon.dist b/phpstan.neon.dist index d5383d22d..2faf82185 100644 --- a/phpstan.neon.dist +++ b/phpstan.neon.dist @@ -2,7 +2,6 @@ parameters: level: 6 paths: - src - - tests ignoreErrors: - message: '#Comparison operation "<=" between [0-9]+ and int<[0-9]+, max> is always true.#' From f0904c3cfcb5ad44bc6605fc1af247cc088a1dbb Mon Sep 17 00:00:00 2001 From: Sacha Telgenhof Date: Sat, 5 Feb 2022 17:51:01 +0900 Subject: [PATCH 022/142] Documented correct data type for arrays. --- src/Yasumi/Filters/BetweenFilter.php | 11 ++++++----- src/Yasumi/Filters/OnFilter.php | 5 +++-- src/Yasumi/Provider/AbstractProvider.php | 6 +++--- src/Yasumi/Translations.php | 2 +- 4 files changed, 13 insertions(+), 11 deletions(-) diff --git a/src/Yasumi/Filters/BetweenFilter.php b/src/Yasumi/Filters/BetweenFilter.php index 8bb8865ba..5f3096811 100644 --- a/src/Yasumi/Filters/BetweenFilter.php +++ b/src/Yasumi/Filters/BetweenFilter.php @@ -17,6 +17,7 @@ use Iterator; use Yasumi\Provider\AbstractProvider; +use Yasumi\ProviderInterface; /** * BetweenFilter is a class used for filtering holidays based on given date range. @@ -40,11 +41,11 @@ class BetweenFilter extends AbstractFilter /** * Construct the Between FilterIterator Object. * - * @param Iterator $iterator Iterator object of the Holidays Provider - * @param \DateTimeInterface $startDate Start date of the time frame to check against - * @param \DateTimeInterface $endDate End date of the time frame to check against - * @param bool $equal Indicate whether the start and end dates should be included in the - * comparison + * @param Iterator $iterator Iterator object of the Holidays Provider + * @param \DateTimeInterface $startDate Start date of the time frame to check against + * @param \DateTimeInterface $endDate End date of the time frame to check against + * @param bool $equal Indicate whether the start and end dates should be included in the + * comparison */ public function __construct( Iterator $iterator, diff --git a/src/Yasumi/Filters/OnFilter.php b/src/Yasumi/Filters/OnFilter.php index b45fcc7d1..ccf4f8565 100644 --- a/src/Yasumi/Filters/OnFilter.php +++ b/src/Yasumi/Filters/OnFilter.php @@ -17,6 +17,7 @@ use Iterator; use Yasumi\Provider\AbstractProvider; +use Yasumi\ProviderInterface; /** * OnFilter is a class used for filtering holidays based on a given date. @@ -33,8 +34,8 @@ class OnFilter extends AbstractFilter /** * Construct the On FilterIterator Object. * - * @param Iterator $iterator Iterator object of the Holidays Provider - * @param \DateTimeInterface $date Start date of the time frame to check against + * @param Iterator $iterator Iterator object of the Holidays Provider + * @param \DateTimeInterface $date Start date of the time frame to check against */ public function __construct( Iterator $iterator, diff --git a/src/Yasumi/Provider/AbstractProvider.php b/src/Yasumi/Provider/AbstractProvider.php index ae9886305..1e13d69dd 100755 --- a/src/Yasumi/Provider/AbstractProvider.php +++ b/src/Yasumi/Provider/AbstractProvider.php @@ -39,9 +39,9 @@ abstract class AbstractProvider implements Countable, ProviderInterface, Iterato public const ID = 'US'; /** - * @var array list of the days of the week (the index of the weekdays) that are considered weekend days. - * This list only concerns those countries that deviate from the global common definition, - * where the weekend starts on Saturday and ends on Sunday (0 = Sunday, 1 = Monday, etc.). + * @var array> list of the days of the week (the index of the weekdays) that are considered weekend days. + * This list only concerns those countries that deviate from the global common definition, + * where the weekend starts on Saturday and ends on Sunday (0 = Sunday, 1 = Monday, etc.). */ public const WEEKEND_DATA = [ // Thursday and Friday diff --git a/src/Yasumi/Translations.php b/src/Yasumi/Translations.php index 9717e592c..5f3990e50 100644 --- a/src/Yasumi/Translations.php +++ b/src/Yasumi/Translations.php @@ -25,7 +25,7 @@ class Translations implements TranslationsInterface { /** - * @var array translations array: ['' => ['' => 'translation', ...], ... ] + * @var array> translations array: ['' => ['' => 'translation', ...], ... ] */ public array $translations = []; From f629bafb02da6c8c6deae940a41703514e354bce Mon Sep 17 00:00:00 2001 From: Sacha Telgenhof Date: Sat, 26 Mar 2022 01:06:46 +0900 Subject: [PATCH 023/142] Removed executable flag. Signed-off-by: Sacha Telgenhof --- composer.json | 0 1 file changed, 0 insertions(+), 0 deletions(-) mode change 100755 => 100644 composer.json diff --git a/composer.json b/composer.json old mode 100755 new mode 100644 From b2267903d6197a8d1f3c59c54b74ef60523c5ffd Mon Sep 17 00:00:00 2001 From: Sacha Telgenhof Date: Thu, 7 Apr 2022 00:42:21 +0900 Subject: [PATCH 024/142] Upgraded PHP CS Fixer. CS fixes. Signed-off-by: Sacha Telgenhof --- composer.json | 2 +- src/Yasumi/Provider/Romania.php | 10 +++++----- tests/Ireland/PentecostTest.php | 2 +- 3 files changed, 7 insertions(+), 7 deletions(-) diff --git a/composer.json b/composer.json index 5b85e464c..718d7f715 100644 --- a/composer.json +++ b/composer.json @@ -40,7 +40,7 @@ "ext-json": "*" }, "require-dev": { - "friendsofphp/php-cs-fixer": "v2.19 | v3.5", + "friendsofphp/php-cs-fixer": "v2.19 | v3.8", "infection/infection": "^0.17 | ^0.26", "mikey179/vfsstream": "^1.6", "phan/phan": "^5.2", diff --git a/src/Yasumi/Provider/Romania.php b/src/Yasumi/Provider/Romania.php index 6efb5fa0c..13042e1f5 100755 --- a/src/Yasumi/Provider/Romania.php +++ b/src/Yasumi/Provider/Romania.php @@ -68,10 +68,10 @@ public function initialize(): void } // Add other holidays - $this->calculateDayAfterNewYearsDay(); //2nd of January - $this->calculateUnitedPrincipalitiesDay(); //since 21.12.2014 (Law 171/2014), celebrated on 24th of January - $this->calculateStAndrewDay(); //since 24.07.2012 (Law 147/2012), celebrated on 30th of November - $this->calculateNationalDay(); //after 1990, celebrated on December 1st + $this->calculateDayAfterNewYearsDay(); // 2nd of January + $this->calculateUnitedPrincipalitiesDay(); // since 21.12.2014 (Law 171/2014), celebrated on 24th of January + $this->calculateStAndrewDay(); // since 24.07.2012 (Law 147/2012), celebrated on 30th of November + $this->calculateNationalDay(); // after 1990, celebrated on December 1st $this->calculateConstantinBrancusiDay(); $this->calculateChildrensDay(); // Since 18.11.2016 (Law 220/2016), Celebrated on 1st of June } @@ -185,7 +185,7 @@ private function calculateNationalDay(): void { $nationalDay = null; - //@link https://en.wikipedia.org/wiki/Great_Union_Day + // @link https://en.wikipedia.org/wiki/Great_Union_Day if ($this->year >= 1990) { $nationalDay = "$this->year-12-01"; } diff --git a/tests/Ireland/PentecostTest.php b/tests/Ireland/PentecostTest.php index 60a2c311a..61bf739a3 100644 --- a/tests/Ireland/PentecostTest.php +++ b/tests/Ireland/PentecostTest.php @@ -62,7 +62,7 @@ public function HolidayDataProvider(): array { $data = []; - //for ($y = 0; $y < self::TEST_ITERATIONS; $y++) { + // for ($y = 0; $y < self::TEST_ITERATIONS; $y++) { for ($y = 0; $y < 2; ++$y) { $year = $this->generateRandomYear(); $date = $this->calculateEaster($year, self::TIMEZONE); From 7971dc0b55c69bea5335c123754292f400cefc41 Mon Sep 17 00:00:00 2001 From: Daan Roet Date: Wed, 11 May 2022 14:28:13 +0200 Subject: [PATCH 025/142] Netherlands Liberation day is only an official holiday every 5 years (#280) * fix: Liberation day is only an official holiday every 5 years * fix: add test cases for liberation day and run php-cs-fixer * fix: resolve the official/observed holiday tests * feat: add changelog entry for the addressed changes --- CHANGELOG.md | 1 + src/Yasumi/Provider/Netherlands.php | 4 +++- tests/Netherlands/LiberationDayTest.php | 16 ++++++++++++++-- tests/Netherlands/NetherlandsTest.php | 13 ++++++++++++- 4 files changed, 30 insertions(+), 4 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index e2ee0927f..695f3ed1f 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -21,6 +21,7 @@ to [Semantic Versioning](https://semver.org). type of the Yasumi factory methods is now `ProviderInterface`, those missing methods generated errors especially by statistic analyzers. - Included the data type for test methods that return an array. +- Liberation day for the Netherlands is only an official holiday every 5 years [\#280](https://github.com/azuyalabs/yasumi/pull/280) ### Deprecated diff --git a/src/Yasumi/Provider/Netherlands.php b/src/Yasumi/Provider/Netherlands.php index 0c81a78a7..ff95d4796 100755 --- a/src/Yasumi/Provider/Netherlands.php +++ b/src/Yasumi/Provider/Netherlands.php @@ -319,12 +319,14 @@ private function calculateCommemorationLiberationDay(): void $this->locale, Holiday::TYPE_OBSERVANCE )); + // Liberation day is only an official holiday every 5 years + $holidayType = (0 === $this->year % 5) ? Holiday::TYPE_OFFICIAL : Holiday::TYPE_OBSERVANCE; $this->addHoliday(new Holiday( 'liberationDay', ['en' => 'Liberation Day', 'nl' => 'Bevrijdingsdag'], new DateTime("$this->year-5-5", DateTimeZoneFactory::getDateTimeZone($this->timezone)), $this->locale, - Holiday::TYPE_OFFICIAL + $holidayType )); } } diff --git a/tests/Netherlands/LiberationDayTest.php b/tests/Netherlands/LiberationDayTest.php index 39cdc4ce7..b90be24e8 100644 --- a/tests/Netherlands/LiberationDayTest.php +++ b/tests/Netherlands/LiberationDayTest.php @@ -81,7 +81,7 @@ public function testTranslation(): void } /** - * Tests type of the holiday defined in this test. + * Tests Liberation Day official holiday type every 5 years, observance type on other years. * * @throws Exception */ @@ -90,7 +90,19 @@ public function testHolidayType(): void $this->assertHolidayType( self::REGION, self::HOLIDAY, - $this->generateRandomYear(self::ESTABLISHMENT_YEAR), + $this->generateRandomYear(2001, 2004), + Holiday::TYPE_OBSERVANCE + ); + $this->assertHolidayType( + self::REGION, + self::HOLIDAY, + 2000, + Holiday::TYPE_OFFICIAL + ); + $this->assertHolidayType( + self::REGION, + self::HOLIDAY, + 2005, Holiday::TYPE_OFFICIAL ); } diff --git a/tests/Netherlands/NetherlandsTest.php b/tests/Netherlands/NetherlandsTest.php index b10b702ce..d082935e0 100644 --- a/tests/Netherlands/NetherlandsTest.php +++ b/tests/Netherlands/NetherlandsTest.php @@ -51,10 +51,17 @@ public function testOfficialHolidays(): void 'ascensionDay', 'pentecost', 'pentecostMonday', - 'liberationDay', 'christmasDay', 'secondChristmasDay', ], self::REGION, $this->year, Holiday::TYPE_OFFICIAL); + + $this->assertDefinedHolidays([ + 'liberationDay', + ], self::REGION, 2015, Holiday::TYPE_OFFICIAL); + + $this->assertDefinedHolidays([ + 'liberationDay', + ], self::REGION, 2020, Holiday::TYPE_OFFICIAL); } /** @@ -73,6 +80,10 @@ public function testObservedHolidays(): void 'secondCarnivalDay', 'thirdCarnivalDay', ], self::REGION, $this->year, Holiday::TYPE_OBSERVANCE); + + $this->assertDefinedHolidays([ + 'liberationDay', + ], self::REGION, $this->generateRandomYear(2011, 2014), Holiday::TYPE_OBSERVANCE); } /** From e6973e711e95a6b0efebc441fe3aaeb3b71e9530 Mon Sep 17 00:00:00 2001 From: Sacha Telgenhof Date: Sun, 5 Jun 2022 15:41:34 +0900 Subject: [PATCH 026/142] Removed redundant class comment. Signed-off-by: Sacha Telgenhof --- src/Yasumi/TranslationsInterface.php | 3 --- 1 file changed, 3 deletions(-) diff --git a/src/Yasumi/TranslationsInterface.php b/src/Yasumi/TranslationsInterface.php index b20abe1c8..8b37128ee 100644 --- a/src/Yasumi/TranslationsInterface.php +++ b/src/Yasumi/TranslationsInterface.php @@ -14,9 +14,6 @@ namespace Yasumi; -/** - * Interface TranslationsInterface. - */ interface TranslationsInterface { /** From badc878d5ee1dfb143f5ccecb03455514e9f0a84 Mon Sep 17 00:00:00 2001 From: Sacha Telgenhof Date: Sun, 5 Jun 2022 15:59:49 +0900 Subject: [PATCH 027/142] Removed execute permissions of some files. Yasumi is a library and does not have any files that require execute permissions. Signed-off-by: Sacha Telgenhof --- src/Yasumi/Holiday.php | 0 src/Yasumi/Provider/AbstractProvider.php | 0 src/Yasumi/Provider/Australia.php | 0 src/Yasumi/Provider/Austria/Burgenland.php | 0 src/Yasumi/Provider/Austria/Carinthia.php | 0 src/Yasumi/Provider/Austria/LowerAustria.php | 0 src/Yasumi/Provider/Austria/Salzburg.php | 0 src/Yasumi/Provider/Austria/Styria.php | 0 src/Yasumi/Provider/Austria/Tyrol.php | 0 src/Yasumi/Provider/Austria/UpperAustria.php | 0 src/Yasumi/Provider/Austria/Vienna.php | 0 src/Yasumi/Provider/Austria/Vorarlberg.php | 0 src/Yasumi/Provider/Belgium.php | 0 src/Yasumi/Provider/France.php | 0 src/Yasumi/Provider/France/BasRhin.php | 0 src/Yasumi/Provider/France/HautRhin.php | 0 src/Yasumi/Provider/France/Moselle.php | 0 src/Yasumi/Provider/Germany/BadenWurttemberg.php | 0 src/Yasumi/Provider/Germany/Bavaria.php | 0 src/Yasumi/Provider/Germany/Berlin.php | 0 src/Yasumi/Provider/Germany/Brandenburg.php | 0 src/Yasumi/Provider/Germany/Bremen.php | 0 src/Yasumi/Provider/Germany/Hamburg.php | 0 src/Yasumi/Provider/Germany/Hesse.php | 0 src/Yasumi/Provider/Germany/LowerSaxony.php | 0 src/Yasumi/Provider/Germany/MecklenburgWesternPomerania.php | 0 src/Yasumi/Provider/Germany/NorthRhineWestphalia.php | 0 src/Yasumi/Provider/Germany/RhinelandPalatinate.php | 0 src/Yasumi/Provider/Germany/Saarland.php | 0 src/Yasumi/Provider/Germany/Saxony.php | 0 src/Yasumi/Provider/Germany/SaxonyAnhalt.php | 0 src/Yasumi/Provider/Germany/SchleswigHolstein.php | 0 src/Yasumi/Provider/Germany/Thuringia.php | 0 src/Yasumi/Provider/Italy.php | 0 src/Yasumi/Provider/Japan.php | 0 src/Yasumi/Provider/Luxembourg.php | 0 src/Yasumi/Provider/Netherlands.php | 0 src/Yasumi/Provider/Poland.php | 0 src/Yasumi/Provider/Romania.php | 0 src/Yasumi/Provider/Spain.php | 0 src/Yasumi/Provider/Spain/Andalusia.php | 0 src/Yasumi/Provider/Spain/Aragon.php | 0 src/Yasumi/Provider/Spain/Asturias.php | 0 src/Yasumi/Provider/Spain/BalearicIslands.php | 0 src/Yasumi/Provider/Spain/BasqueCountry.php | 0 src/Yasumi/Provider/Spain/CanaryIslands.php | 0 src/Yasumi/Provider/Spain/Cantabria.php | 0 src/Yasumi/Provider/Spain/CastileAndLeon.php | 0 src/Yasumi/Provider/Spain/CastillaLaMancha.php | 0 src/Yasumi/Provider/Spain/Catalonia.php | 0 src/Yasumi/Provider/Spain/Ceuta.php | 0 src/Yasumi/Provider/Spain/CommunityOfMadrid.php | 0 src/Yasumi/Provider/Spain/Extremadura.php | 0 src/Yasumi/Provider/Spain/Galicia.php | 0 src/Yasumi/Provider/Spain/LaRioja.php | 0 src/Yasumi/Provider/Spain/Melilla.php | 0 src/Yasumi/Provider/Spain/Navarre.php | 0 src/Yasumi/Provider/Spain/RegionOfMurcia.php | 0 src/Yasumi/Provider/Spain/ValencianCommunity.php | 0 src/Yasumi/Provider/Turkey.php | 0 src/Yasumi/Provider/USA.php | 0 src/Yasumi/ProviderInterface.php | 0 src/Yasumi/SubstituteHoliday.php | 0 src/Yasumi/Yasumi.php | 0 src/Yasumi/data/translations/allSaintsDay.php | 0 src/Yasumi/data/translations/allSaintsEve.php | 0 src/Yasumi/data/translations/assumptionOfMary.php | 0 src/Yasumi/data/translations/christmasDay.php | 0 src/Yasumi/data/translations/christmasEve.php | 0 src/Yasumi/data/translations/dayOfReformation.php | 0 src/Yasumi/data/translations/fathersDay.php | 0 src/Yasumi/data/translations/internationalWomensDay.php | 0 src/Yasumi/data/translations/internationalWorkersDay.php | 0 src/Yasumi/data/translations/mothersDay.php | 0 src/Yasumi/data/translations/newYearsDay.php | 0 src/Yasumi/data/translations/newYearsEve.php | 0 src/Yasumi/data/translations/pentecost.php | 0 src/Yasumi/data/translations/pentecostMonday.php | 0 src/Yasumi/data/translations/reformationDay.php | 0 src/Yasumi/data/translations/secondChristmasDay.php | 0 src/Yasumi/data/translations/secondNewYearsDay.php | 0 src/Yasumi/data/translations/substituteHoliday.php | 0 src/Yasumi/data/translations/walpurgisEve.php | 0 tests/Romania/EasterMondayTest.php | 0 tests/Romania/EasterTest.php | 0 tests/Romania/InternationalWorkersDayTest.php | 0 tests/Romania/RomaniaBaseTestCase.php | 0 tests/Romania/RomaniaTest.php | 0 tests/Turkey/TurkeyBaseTestCase.php | 0 tests/Turkey/TurkeyTest.php | 0 90 files changed, 0 insertions(+), 0 deletions(-) mode change 100755 => 100644 src/Yasumi/Holiday.php mode change 100755 => 100644 src/Yasumi/Provider/AbstractProvider.php mode change 100755 => 100644 src/Yasumi/Provider/Australia.php mode change 100755 => 100644 src/Yasumi/Provider/Austria/Burgenland.php mode change 100755 => 100644 src/Yasumi/Provider/Austria/Carinthia.php mode change 100755 => 100644 src/Yasumi/Provider/Austria/LowerAustria.php mode change 100755 => 100644 src/Yasumi/Provider/Austria/Salzburg.php mode change 100755 => 100644 src/Yasumi/Provider/Austria/Styria.php mode change 100755 => 100644 src/Yasumi/Provider/Austria/Tyrol.php mode change 100755 => 100644 src/Yasumi/Provider/Austria/UpperAustria.php mode change 100755 => 100644 src/Yasumi/Provider/Austria/Vienna.php mode change 100755 => 100644 src/Yasumi/Provider/Austria/Vorarlberg.php mode change 100755 => 100644 src/Yasumi/Provider/Belgium.php mode change 100755 => 100644 src/Yasumi/Provider/France.php mode change 100755 => 100644 src/Yasumi/Provider/France/BasRhin.php mode change 100755 => 100644 src/Yasumi/Provider/France/HautRhin.php mode change 100755 => 100644 src/Yasumi/Provider/France/Moselle.php mode change 100755 => 100644 src/Yasumi/Provider/Germany/BadenWurttemberg.php mode change 100755 => 100644 src/Yasumi/Provider/Germany/Bavaria.php mode change 100755 => 100644 src/Yasumi/Provider/Germany/Berlin.php mode change 100755 => 100644 src/Yasumi/Provider/Germany/Brandenburg.php mode change 100755 => 100644 src/Yasumi/Provider/Germany/Bremen.php mode change 100755 => 100644 src/Yasumi/Provider/Germany/Hamburg.php mode change 100755 => 100644 src/Yasumi/Provider/Germany/Hesse.php mode change 100755 => 100644 src/Yasumi/Provider/Germany/LowerSaxony.php mode change 100755 => 100644 src/Yasumi/Provider/Germany/MecklenburgWesternPomerania.php mode change 100755 => 100644 src/Yasumi/Provider/Germany/NorthRhineWestphalia.php mode change 100755 => 100644 src/Yasumi/Provider/Germany/RhinelandPalatinate.php mode change 100755 => 100644 src/Yasumi/Provider/Germany/Saarland.php mode change 100755 => 100644 src/Yasumi/Provider/Germany/Saxony.php mode change 100755 => 100644 src/Yasumi/Provider/Germany/SaxonyAnhalt.php mode change 100755 => 100644 src/Yasumi/Provider/Germany/SchleswigHolstein.php mode change 100755 => 100644 src/Yasumi/Provider/Germany/Thuringia.php mode change 100755 => 100644 src/Yasumi/Provider/Italy.php mode change 100755 => 100644 src/Yasumi/Provider/Japan.php mode change 100755 => 100644 src/Yasumi/Provider/Luxembourg.php mode change 100755 => 100644 src/Yasumi/Provider/Netherlands.php mode change 100755 => 100644 src/Yasumi/Provider/Poland.php mode change 100755 => 100644 src/Yasumi/Provider/Romania.php mode change 100755 => 100644 src/Yasumi/Provider/Spain.php mode change 100755 => 100644 src/Yasumi/Provider/Spain/Andalusia.php mode change 100755 => 100644 src/Yasumi/Provider/Spain/Aragon.php mode change 100755 => 100644 src/Yasumi/Provider/Spain/Asturias.php mode change 100755 => 100644 src/Yasumi/Provider/Spain/BalearicIslands.php mode change 100755 => 100644 src/Yasumi/Provider/Spain/BasqueCountry.php mode change 100755 => 100644 src/Yasumi/Provider/Spain/CanaryIslands.php mode change 100755 => 100644 src/Yasumi/Provider/Spain/Cantabria.php mode change 100755 => 100644 src/Yasumi/Provider/Spain/CastileAndLeon.php mode change 100755 => 100644 src/Yasumi/Provider/Spain/CastillaLaMancha.php mode change 100755 => 100644 src/Yasumi/Provider/Spain/Catalonia.php mode change 100755 => 100644 src/Yasumi/Provider/Spain/Ceuta.php mode change 100755 => 100644 src/Yasumi/Provider/Spain/CommunityOfMadrid.php mode change 100755 => 100644 src/Yasumi/Provider/Spain/Extremadura.php mode change 100755 => 100644 src/Yasumi/Provider/Spain/Galicia.php mode change 100755 => 100644 src/Yasumi/Provider/Spain/LaRioja.php mode change 100755 => 100644 src/Yasumi/Provider/Spain/Melilla.php mode change 100755 => 100644 src/Yasumi/Provider/Spain/Navarre.php mode change 100755 => 100644 src/Yasumi/Provider/Spain/RegionOfMurcia.php mode change 100755 => 100644 src/Yasumi/Provider/Spain/ValencianCommunity.php mode change 100755 => 100644 src/Yasumi/Provider/Turkey.php mode change 100755 => 100644 src/Yasumi/Provider/USA.php mode change 100755 => 100644 src/Yasumi/ProviderInterface.php mode change 100755 => 100644 src/Yasumi/SubstituteHoliday.php mode change 100755 => 100644 src/Yasumi/Yasumi.php mode change 100755 => 100644 src/Yasumi/data/translations/allSaintsDay.php mode change 100755 => 100644 src/Yasumi/data/translations/allSaintsEve.php mode change 100755 => 100644 src/Yasumi/data/translations/assumptionOfMary.php mode change 100755 => 100644 src/Yasumi/data/translations/christmasDay.php mode change 100755 => 100644 src/Yasumi/data/translations/christmasEve.php mode change 100755 => 100644 src/Yasumi/data/translations/dayOfReformation.php mode change 100755 => 100644 src/Yasumi/data/translations/fathersDay.php mode change 100755 => 100644 src/Yasumi/data/translations/internationalWomensDay.php mode change 100755 => 100644 src/Yasumi/data/translations/internationalWorkersDay.php mode change 100755 => 100644 src/Yasumi/data/translations/mothersDay.php mode change 100755 => 100644 src/Yasumi/data/translations/newYearsDay.php mode change 100755 => 100644 src/Yasumi/data/translations/newYearsEve.php mode change 100755 => 100644 src/Yasumi/data/translations/pentecost.php mode change 100755 => 100644 src/Yasumi/data/translations/pentecostMonday.php mode change 100755 => 100644 src/Yasumi/data/translations/reformationDay.php mode change 100755 => 100644 src/Yasumi/data/translations/secondChristmasDay.php mode change 100755 => 100644 src/Yasumi/data/translations/secondNewYearsDay.php mode change 100755 => 100644 src/Yasumi/data/translations/substituteHoliday.php mode change 100755 => 100644 src/Yasumi/data/translations/walpurgisEve.php mode change 100755 => 100644 tests/Romania/EasterMondayTest.php mode change 100755 => 100644 tests/Romania/EasterTest.php mode change 100755 => 100644 tests/Romania/InternationalWorkersDayTest.php mode change 100755 => 100644 tests/Romania/RomaniaBaseTestCase.php mode change 100755 => 100644 tests/Romania/RomaniaTest.php mode change 100755 => 100644 tests/Turkey/TurkeyBaseTestCase.php mode change 100755 => 100644 tests/Turkey/TurkeyTest.php diff --git a/src/Yasumi/Holiday.php b/src/Yasumi/Holiday.php old mode 100755 new mode 100644 diff --git a/src/Yasumi/Provider/AbstractProvider.php b/src/Yasumi/Provider/AbstractProvider.php old mode 100755 new mode 100644 diff --git a/src/Yasumi/Provider/Australia.php b/src/Yasumi/Provider/Australia.php old mode 100755 new mode 100644 diff --git a/src/Yasumi/Provider/Austria/Burgenland.php b/src/Yasumi/Provider/Austria/Burgenland.php old mode 100755 new mode 100644 diff --git a/src/Yasumi/Provider/Austria/Carinthia.php b/src/Yasumi/Provider/Austria/Carinthia.php old mode 100755 new mode 100644 diff --git a/src/Yasumi/Provider/Austria/LowerAustria.php b/src/Yasumi/Provider/Austria/LowerAustria.php old mode 100755 new mode 100644 diff --git a/src/Yasumi/Provider/Austria/Salzburg.php b/src/Yasumi/Provider/Austria/Salzburg.php old mode 100755 new mode 100644 diff --git a/src/Yasumi/Provider/Austria/Styria.php b/src/Yasumi/Provider/Austria/Styria.php old mode 100755 new mode 100644 diff --git a/src/Yasumi/Provider/Austria/Tyrol.php b/src/Yasumi/Provider/Austria/Tyrol.php old mode 100755 new mode 100644 diff --git a/src/Yasumi/Provider/Austria/UpperAustria.php b/src/Yasumi/Provider/Austria/UpperAustria.php old mode 100755 new mode 100644 diff --git a/src/Yasumi/Provider/Austria/Vienna.php b/src/Yasumi/Provider/Austria/Vienna.php old mode 100755 new mode 100644 diff --git a/src/Yasumi/Provider/Austria/Vorarlberg.php b/src/Yasumi/Provider/Austria/Vorarlberg.php old mode 100755 new mode 100644 diff --git a/src/Yasumi/Provider/Belgium.php b/src/Yasumi/Provider/Belgium.php old mode 100755 new mode 100644 diff --git a/src/Yasumi/Provider/France.php b/src/Yasumi/Provider/France.php old mode 100755 new mode 100644 diff --git a/src/Yasumi/Provider/France/BasRhin.php b/src/Yasumi/Provider/France/BasRhin.php old mode 100755 new mode 100644 diff --git a/src/Yasumi/Provider/France/HautRhin.php b/src/Yasumi/Provider/France/HautRhin.php old mode 100755 new mode 100644 diff --git a/src/Yasumi/Provider/France/Moselle.php b/src/Yasumi/Provider/France/Moselle.php old mode 100755 new mode 100644 diff --git a/src/Yasumi/Provider/Germany/BadenWurttemberg.php b/src/Yasumi/Provider/Germany/BadenWurttemberg.php old mode 100755 new mode 100644 diff --git a/src/Yasumi/Provider/Germany/Bavaria.php b/src/Yasumi/Provider/Germany/Bavaria.php old mode 100755 new mode 100644 diff --git a/src/Yasumi/Provider/Germany/Berlin.php b/src/Yasumi/Provider/Germany/Berlin.php old mode 100755 new mode 100644 diff --git a/src/Yasumi/Provider/Germany/Brandenburg.php b/src/Yasumi/Provider/Germany/Brandenburg.php old mode 100755 new mode 100644 diff --git a/src/Yasumi/Provider/Germany/Bremen.php b/src/Yasumi/Provider/Germany/Bremen.php old mode 100755 new mode 100644 diff --git a/src/Yasumi/Provider/Germany/Hamburg.php b/src/Yasumi/Provider/Germany/Hamburg.php old mode 100755 new mode 100644 diff --git a/src/Yasumi/Provider/Germany/Hesse.php b/src/Yasumi/Provider/Germany/Hesse.php old mode 100755 new mode 100644 diff --git a/src/Yasumi/Provider/Germany/LowerSaxony.php b/src/Yasumi/Provider/Germany/LowerSaxony.php old mode 100755 new mode 100644 diff --git a/src/Yasumi/Provider/Germany/MecklenburgWesternPomerania.php b/src/Yasumi/Provider/Germany/MecklenburgWesternPomerania.php old mode 100755 new mode 100644 diff --git a/src/Yasumi/Provider/Germany/NorthRhineWestphalia.php b/src/Yasumi/Provider/Germany/NorthRhineWestphalia.php old mode 100755 new mode 100644 diff --git a/src/Yasumi/Provider/Germany/RhinelandPalatinate.php b/src/Yasumi/Provider/Germany/RhinelandPalatinate.php old mode 100755 new mode 100644 diff --git a/src/Yasumi/Provider/Germany/Saarland.php b/src/Yasumi/Provider/Germany/Saarland.php old mode 100755 new mode 100644 diff --git a/src/Yasumi/Provider/Germany/Saxony.php b/src/Yasumi/Provider/Germany/Saxony.php old mode 100755 new mode 100644 diff --git a/src/Yasumi/Provider/Germany/SaxonyAnhalt.php b/src/Yasumi/Provider/Germany/SaxonyAnhalt.php old mode 100755 new mode 100644 diff --git a/src/Yasumi/Provider/Germany/SchleswigHolstein.php b/src/Yasumi/Provider/Germany/SchleswigHolstein.php old mode 100755 new mode 100644 diff --git a/src/Yasumi/Provider/Germany/Thuringia.php b/src/Yasumi/Provider/Germany/Thuringia.php old mode 100755 new mode 100644 diff --git a/src/Yasumi/Provider/Italy.php b/src/Yasumi/Provider/Italy.php old mode 100755 new mode 100644 diff --git a/src/Yasumi/Provider/Japan.php b/src/Yasumi/Provider/Japan.php old mode 100755 new mode 100644 diff --git a/src/Yasumi/Provider/Luxembourg.php b/src/Yasumi/Provider/Luxembourg.php old mode 100755 new mode 100644 diff --git a/src/Yasumi/Provider/Netherlands.php b/src/Yasumi/Provider/Netherlands.php old mode 100755 new mode 100644 diff --git a/src/Yasumi/Provider/Poland.php b/src/Yasumi/Provider/Poland.php old mode 100755 new mode 100644 diff --git a/src/Yasumi/Provider/Romania.php b/src/Yasumi/Provider/Romania.php old mode 100755 new mode 100644 diff --git a/src/Yasumi/Provider/Spain.php b/src/Yasumi/Provider/Spain.php old mode 100755 new mode 100644 diff --git a/src/Yasumi/Provider/Spain/Andalusia.php b/src/Yasumi/Provider/Spain/Andalusia.php old mode 100755 new mode 100644 diff --git a/src/Yasumi/Provider/Spain/Aragon.php b/src/Yasumi/Provider/Spain/Aragon.php old mode 100755 new mode 100644 diff --git a/src/Yasumi/Provider/Spain/Asturias.php b/src/Yasumi/Provider/Spain/Asturias.php old mode 100755 new mode 100644 diff --git a/src/Yasumi/Provider/Spain/BalearicIslands.php b/src/Yasumi/Provider/Spain/BalearicIslands.php old mode 100755 new mode 100644 diff --git a/src/Yasumi/Provider/Spain/BasqueCountry.php b/src/Yasumi/Provider/Spain/BasqueCountry.php old mode 100755 new mode 100644 diff --git a/src/Yasumi/Provider/Spain/CanaryIslands.php b/src/Yasumi/Provider/Spain/CanaryIslands.php old mode 100755 new mode 100644 diff --git a/src/Yasumi/Provider/Spain/Cantabria.php b/src/Yasumi/Provider/Spain/Cantabria.php old mode 100755 new mode 100644 diff --git a/src/Yasumi/Provider/Spain/CastileAndLeon.php b/src/Yasumi/Provider/Spain/CastileAndLeon.php old mode 100755 new mode 100644 diff --git a/src/Yasumi/Provider/Spain/CastillaLaMancha.php b/src/Yasumi/Provider/Spain/CastillaLaMancha.php old mode 100755 new mode 100644 diff --git a/src/Yasumi/Provider/Spain/Catalonia.php b/src/Yasumi/Provider/Spain/Catalonia.php old mode 100755 new mode 100644 diff --git a/src/Yasumi/Provider/Spain/Ceuta.php b/src/Yasumi/Provider/Spain/Ceuta.php old mode 100755 new mode 100644 diff --git a/src/Yasumi/Provider/Spain/CommunityOfMadrid.php b/src/Yasumi/Provider/Spain/CommunityOfMadrid.php old mode 100755 new mode 100644 diff --git a/src/Yasumi/Provider/Spain/Extremadura.php b/src/Yasumi/Provider/Spain/Extremadura.php old mode 100755 new mode 100644 diff --git a/src/Yasumi/Provider/Spain/Galicia.php b/src/Yasumi/Provider/Spain/Galicia.php old mode 100755 new mode 100644 diff --git a/src/Yasumi/Provider/Spain/LaRioja.php b/src/Yasumi/Provider/Spain/LaRioja.php old mode 100755 new mode 100644 diff --git a/src/Yasumi/Provider/Spain/Melilla.php b/src/Yasumi/Provider/Spain/Melilla.php old mode 100755 new mode 100644 diff --git a/src/Yasumi/Provider/Spain/Navarre.php b/src/Yasumi/Provider/Spain/Navarre.php old mode 100755 new mode 100644 diff --git a/src/Yasumi/Provider/Spain/RegionOfMurcia.php b/src/Yasumi/Provider/Spain/RegionOfMurcia.php old mode 100755 new mode 100644 diff --git a/src/Yasumi/Provider/Spain/ValencianCommunity.php b/src/Yasumi/Provider/Spain/ValencianCommunity.php old mode 100755 new mode 100644 diff --git a/src/Yasumi/Provider/Turkey.php b/src/Yasumi/Provider/Turkey.php old mode 100755 new mode 100644 diff --git a/src/Yasumi/Provider/USA.php b/src/Yasumi/Provider/USA.php old mode 100755 new mode 100644 diff --git a/src/Yasumi/ProviderInterface.php b/src/Yasumi/ProviderInterface.php old mode 100755 new mode 100644 diff --git a/src/Yasumi/SubstituteHoliday.php b/src/Yasumi/SubstituteHoliday.php old mode 100755 new mode 100644 diff --git a/src/Yasumi/Yasumi.php b/src/Yasumi/Yasumi.php old mode 100755 new mode 100644 diff --git a/src/Yasumi/data/translations/allSaintsDay.php b/src/Yasumi/data/translations/allSaintsDay.php old mode 100755 new mode 100644 diff --git a/src/Yasumi/data/translations/allSaintsEve.php b/src/Yasumi/data/translations/allSaintsEve.php old mode 100755 new mode 100644 diff --git a/src/Yasumi/data/translations/assumptionOfMary.php b/src/Yasumi/data/translations/assumptionOfMary.php old mode 100755 new mode 100644 diff --git a/src/Yasumi/data/translations/christmasDay.php b/src/Yasumi/data/translations/christmasDay.php old mode 100755 new mode 100644 diff --git a/src/Yasumi/data/translations/christmasEve.php b/src/Yasumi/data/translations/christmasEve.php old mode 100755 new mode 100644 diff --git a/src/Yasumi/data/translations/dayOfReformation.php b/src/Yasumi/data/translations/dayOfReformation.php old mode 100755 new mode 100644 diff --git a/src/Yasumi/data/translations/fathersDay.php b/src/Yasumi/data/translations/fathersDay.php old mode 100755 new mode 100644 diff --git a/src/Yasumi/data/translations/internationalWomensDay.php b/src/Yasumi/data/translations/internationalWomensDay.php old mode 100755 new mode 100644 diff --git a/src/Yasumi/data/translations/internationalWorkersDay.php b/src/Yasumi/data/translations/internationalWorkersDay.php old mode 100755 new mode 100644 diff --git a/src/Yasumi/data/translations/mothersDay.php b/src/Yasumi/data/translations/mothersDay.php old mode 100755 new mode 100644 diff --git a/src/Yasumi/data/translations/newYearsDay.php b/src/Yasumi/data/translations/newYearsDay.php old mode 100755 new mode 100644 diff --git a/src/Yasumi/data/translations/newYearsEve.php b/src/Yasumi/data/translations/newYearsEve.php old mode 100755 new mode 100644 diff --git a/src/Yasumi/data/translations/pentecost.php b/src/Yasumi/data/translations/pentecost.php old mode 100755 new mode 100644 diff --git a/src/Yasumi/data/translations/pentecostMonday.php b/src/Yasumi/data/translations/pentecostMonday.php old mode 100755 new mode 100644 diff --git a/src/Yasumi/data/translations/reformationDay.php b/src/Yasumi/data/translations/reformationDay.php old mode 100755 new mode 100644 diff --git a/src/Yasumi/data/translations/secondChristmasDay.php b/src/Yasumi/data/translations/secondChristmasDay.php old mode 100755 new mode 100644 diff --git a/src/Yasumi/data/translations/secondNewYearsDay.php b/src/Yasumi/data/translations/secondNewYearsDay.php old mode 100755 new mode 100644 diff --git a/src/Yasumi/data/translations/substituteHoliday.php b/src/Yasumi/data/translations/substituteHoliday.php old mode 100755 new mode 100644 diff --git a/src/Yasumi/data/translations/walpurgisEve.php b/src/Yasumi/data/translations/walpurgisEve.php old mode 100755 new mode 100644 diff --git a/tests/Romania/EasterMondayTest.php b/tests/Romania/EasterMondayTest.php old mode 100755 new mode 100644 diff --git a/tests/Romania/EasterTest.php b/tests/Romania/EasterTest.php old mode 100755 new mode 100644 diff --git a/tests/Romania/InternationalWorkersDayTest.php b/tests/Romania/InternationalWorkersDayTest.php old mode 100755 new mode 100644 diff --git a/tests/Romania/RomaniaBaseTestCase.php b/tests/Romania/RomaniaBaseTestCase.php old mode 100755 new mode 100644 diff --git a/tests/Romania/RomaniaTest.php b/tests/Romania/RomaniaTest.php old mode 100755 new mode 100644 diff --git a/tests/Turkey/TurkeyBaseTestCase.php b/tests/Turkey/TurkeyBaseTestCase.php old mode 100755 new mode 100644 diff --git a/tests/Turkey/TurkeyTest.php b/tests/Turkey/TurkeyTest.php old mode 100755 new mode 100644 From 538a89af96eb5bb0eb1833228fb59969a611b36b Mon Sep 17 00:00:00 2001 From: Sacha Telgenhof Date: Tue, 14 Jun 2022 01:31:54 +0900 Subject: [PATCH 028/142] Altered test to include condition that Pentecost Monday was only a holiday up to 2004. Signed-off-by: Sacha Telgenhof --- tests/France/PentecostMondayTest.php | 22 +++++++++++++++++++++- 1 file changed, 21 insertions(+), 1 deletion(-) diff --git a/tests/France/PentecostMondayTest.php b/tests/France/PentecostMondayTest.php index 789b0316e..1326970a4 100644 --- a/tests/France/PentecostMondayTest.php +++ b/tests/France/PentecostMondayTest.php @@ -22,6 +22,12 @@ /** * Class for testing Pentecost Monday in France. + * + * Until 2004, Pentecost Monday was an official holiday. Since 2004, the holiday is considered a 'working holiday', + * imposed by law to be by default on Pentecost Monday. Pentecost Monday is still a holiday (but a working holiday). + * + * @see: https://en.wikipedia.org/wiki/Journ%C3%A9e_de_solidarit%C3%A9_envers_les_personnes_%C3%A2g%C3%A9es + * @see: https://fr.wikipedia.org/w/index.php?title=Journ%C3%A9e_de_solidarit%C3%A9_envers_les_personnes_%C3%A2g%C3%A9es_et_handicap%C3%A9es&tableofcontents=0 */ class PentecostMondayTest extends FranceBaseTestCase implements HolidayTestCase { @@ -30,6 +36,8 @@ class PentecostMondayTest extends FranceBaseTestCase implements HolidayTestCase */ public const HOLIDAY = 'pentecostMonday'; + public const EST_YEAR_DAY_OF_SOLIDARITY_WITH_ELDERLY = 2004; + /** * Tests Pentecost Monday. * @@ -68,6 +76,18 @@ public function testTranslation(): void */ public function testHolidayType(): void { - $this->assertHolidayType(self::REGION, self::HOLIDAY, $this->generateRandomYear(), Holiday::TYPE_OFFICIAL); + $this->assertHolidayType( + self::REGION, + self::HOLIDAY, + $this->generateRandomYear(null, self::EST_YEAR_DAY_OF_SOLIDARITY_WITH_ELDERLY - 1), + Holiday::TYPE_OFFICIAL + ); + + $this->assertHolidayType( + self::REGION, + self::HOLIDAY, + $this->generateRandomYear(self::EST_YEAR_DAY_OF_SOLIDARITY_WITH_ELDERLY), + Holiday::TYPE_OBSERVANCE + ); } } From d47b7c45dbfc08d33deb047139396384477c8aed Mon Sep 17 00:00:00 2001 From: Sacha Telgenhof Date: Tue, 14 Jun 2022 09:15:01 +0900 Subject: [PATCH 029/142] Extracted method to determine Pentecost Monday. Adjusted the France base test accordingly. Signed-off-by: Sacha Telgenhof --- src/Yasumi/Provider/France.php | 26 +++++++++++++++++- tests/France/FranceTest.php | 40 ++++++++++++++++++---------- tests/France/PentecostMondayTest.php | 13 +++------ 3 files changed, 54 insertions(+), 25 deletions(-) diff --git a/src/Yasumi/Provider/France.php b/src/Yasumi/Provider/France.php index 7be3329eb..291e70753 100644 --- a/src/Yasumi/Provider/France.php +++ b/src/Yasumi/Provider/France.php @@ -33,6 +33,8 @@ class France extends AbstractProvider */ public const ID = 'FR'; + public const EST_YEAR_DAY_OF_SOLIDARITY_WITH_ELDERLY = 2004; + /** * Initialize holidays for France. * @@ -56,7 +58,6 @@ public function initialize(): void $this->addHoliday($this->easterMonday($this->year, $this->timezone, $this->locale)); $this->addHoliday($this->internationalWorkersDay($this->year, $this->timezone, $this->locale)); $this->addHoliday($this->ascensionDay($this->year, $this->timezone, $this->locale)); - $this->addHoliday($this->pentecostMonday($this->year, $this->timezone, $this->locale)); $this->addHoliday($this->assumptionOfMary($this->year, $this->timezone, $this->locale)); $this->addHoliday($this->allSaintsDay($this->year, $this->timezone, $this->locale)); @@ -68,6 +69,7 @@ public function initialize(): void // Calculate other holidays $this->calculateBastilleDay(); + $this->calculatePentecostMonday(); } public function getSources(): array @@ -103,4 +105,26 @@ private function calculateBastilleDay(): void ], new DateTime("$this->year-7-14", DateTimeZoneFactory::getDateTimeZone($this->timezone)), $this->locale)); } } + + /** + * Pentecost Monday. + * + * Until 2004, Pentecost Monday was an official holiday. Since 2004, the holiday is considered a 'working holiday', + * imposed by law to be by default on Pentecost Monday. Pentecost Monday is still a holiday (but a working holiday). + * + * @see: https://en.wikipedia.org/wiki/Journ%C3%A9e_de_solidarit%C3%A9_envers_les_personnes_%C3%A2g%C3%A9es + * @see: https://fr.wikipedia.org/w/index.php?title=Journ%C3%A9e_de_solidarit%C3%A9_envers_les_personnes_%C3%A2g%C3%A9es_et_handicap%C3%A9es&tableofcontents=0 + * + * @throws \Exception + */ + private function calculatePentecostMonday(): void + { + $type = Holiday::TYPE_OFFICIAL; + + if ($this->year >= 2004) { + $type = Holiday::TYPE_OBSERVANCE; + } + + $this->addHoliday($this->pentecostMonday($this->year, $this->timezone, $this->locale, $type)); + } } diff --git a/tests/France/FranceTest.php b/tests/France/FranceTest.php index 84228f7e7..2803d2b20 100644 --- a/tests/France/FranceTest.php +++ b/tests/France/FranceTest.php @@ -16,6 +16,7 @@ use ReflectionException; use Yasumi\Holiday; +use Yasumi\Provider\France; use Yasumi\tests\ProviderTestCase; /** @@ -43,19 +44,25 @@ protected function setUp(): void */ public function testOfficialHolidays(): void { - $this->assertDefinedHolidays([ - 'newYearsDay', - 'victoryInEuropeDay', - 'easterMonday', - 'internationalWorkersDay', - 'ascensionDay', - 'pentecostMonday', - 'assumptionOfMary', - 'allSaintsDay', - 'armisticeDay', - 'christmasDay', - 'bastilleDay', - ], self::REGION, $this->year, Holiday::TYPE_OFFICIAL); + $holidays = + [ + 'newYearsDay', + 'victoryInEuropeDay', + 'easterMonday', + 'internationalWorkersDay', + 'ascensionDay', + 'assumptionOfMary', + 'allSaintsDay', + 'armisticeDay', + 'christmasDay', + 'bastilleDay', + ]; + + if ($this->year < France::EST_YEAR_DAY_OF_SOLIDARITY_WITH_ELDERLY) { + $holidays[] = 'pentecostMonday'; + } + + $this->assertDefinedHolidays($holidays, self::REGION, $this->year, Holiday::TYPE_OFFICIAL); } /** @@ -63,7 +70,12 @@ public function testOfficialHolidays(): void */ public function testObservedHolidays(): void { - $this->assertDefinedHolidays([], self::REGION, $this->year, Holiday::TYPE_OBSERVANCE); + $holidays = []; + if ($this->year >= France::EST_YEAR_DAY_OF_SOLIDARITY_WITH_ELDERLY) { + $holidays[] = 'pentecostMonday'; + } + + $this->assertDefinedHolidays($holidays, self::REGION, $this->year, Holiday::TYPE_OBSERVANCE); } /** diff --git a/tests/France/PentecostMondayTest.php b/tests/France/PentecostMondayTest.php index 1326970a4..8b9060f06 100644 --- a/tests/France/PentecostMondayTest.php +++ b/tests/France/PentecostMondayTest.php @@ -18,16 +18,11 @@ use DateTimeZone; use Exception; use Yasumi\Holiday; +use Yasumi\Provider\France; use Yasumi\tests\HolidayTestCase; /** * Class for testing Pentecost Monday in France. - * - * Until 2004, Pentecost Monday was an official holiday. Since 2004, the holiday is considered a 'working holiday', - * imposed by law to be by default on Pentecost Monday. Pentecost Monday is still a holiday (but a working holiday). - * - * @see: https://en.wikipedia.org/wiki/Journ%C3%A9e_de_solidarit%C3%A9_envers_les_personnes_%C3%A2g%C3%A9es - * @see: https://fr.wikipedia.org/w/index.php?title=Journ%C3%A9e_de_solidarit%C3%A9_envers_les_personnes_%C3%A2g%C3%A9es_et_handicap%C3%A9es&tableofcontents=0 */ class PentecostMondayTest extends FranceBaseTestCase implements HolidayTestCase { @@ -36,8 +31,6 @@ class PentecostMondayTest extends FranceBaseTestCase implements HolidayTestCase */ public const HOLIDAY = 'pentecostMonday'; - public const EST_YEAR_DAY_OF_SOLIDARITY_WITH_ELDERLY = 2004; - /** * Tests Pentecost Monday. * @@ -79,14 +72,14 @@ public function testHolidayType(): void $this->assertHolidayType( self::REGION, self::HOLIDAY, - $this->generateRandomYear(null, self::EST_YEAR_DAY_OF_SOLIDARITY_WITH_ELDERLY - 1), + $this->generateRandomYear(null, France::EST_YEAR_DAY_OF_SOLIDARITY_WITH_ELDERLY - 1), Holiday::TYPE_OFFICIAL ); $this->assertHolidayType( self::REGION, self::HOLIDAY, - $this->generateRandomYear(self::EST_YEAR_DAY_OF_SOLIDARITY_WITH_ELDERLY), + $this->generateRandomYear(France::EST_YEAR_DAY_OF_SOLIDARITY_WITH_ELDERLY), Holiday::TYPE_OBSERVANCE ); } From 6306fc763b8d16620b896b742aa2d2eb0b20d868 Mon Sep 17 00:00:00 2001 From: Sacha Telgenhof Date: Tue, 14 Jun 2022 21:05:27 +0900 Subject: [PATCH 030/142] Adjusted tests for the regions Bas-Rhin, Haut-Rhin and Moselle accordingly. Signed-off-by: Sacha Telgenhof --- CHANGELOG.md | 7 +++-- tests/France/BasRhin/BasRhinTest.php | 43 ++++++++++++++++---------- tests/France/FranceTest.php | 1 + tests/France/HautRhin/HautRhinTest.php | 43 ++++++++++++++++---------- tests/France/Moselle/MoselleTest.php | 43 ++++++++++++++++---------- 5 files changed, 87 insertions(+), 50 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 695f3ed1f..db8d5074a 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -15,13 +15,16 @@ to [Semantic Versioning](https://semver.org). ### Fixed +- Pentecost Monday in France was only until 2004 recognized as an official holiday. Since 2004 it is considered a + special holiday, a so called 'working holiday'. Hence, it is therefore classified as an observed holiday in Yasumi + from 2004 and forward. [\#281](https://github.com/azuyalabs/yasumi/issues/281). - The test for Remembrance Day (Argentina) in that Remembrance Day was considered for all years: it is only celebrated since 2006. - Created the interface methods of the `ProviderInterface` that the abstract provider class implements. Since the return type of the Yasumi factory methods is now `ProviderInterface`, those missing methods generated errors especially by - statistic analyzers. + statistic analysers. - Included the data type for test methods that return an array. -- Liberation day for the Netherlands is only an official holiday every 5 years [\#280](https://github.com/azuyalabs/yasumi/pull/280) +- Liberation day for the Netherlands is only an official holiday every 5 years [\#280](https://github.com/azuyalabs/yasumi/pull/280). ### Deprecated diff --git a/tests/France/BasRhin/BasRhinTest.php b/tests/France/BasRhin/BasRhinTest.php index 3d7733a62..f9989c4be 100644 --- a/tests/France/BasRhin/BasRhinTest.php +++ b/tests/France/BasRhin/BasRhinTest.php @@ -16,6 +16,7 @@ use ReflectionException; use Yasumi\Holiday; +use Yasumi\Provider\France; use Yasumi\tests\ProviderTestCase; /** @@ -43,21 +44,25 @@ protected function setUp(): void */ public function testOfficialHolidays(): void { - $this->assertDefinedHolidays([ - 'newYearsDay', - 'victoryInEuropeDay', - 'goodFriday', - 'easterMonday', - 'internationalWorkersDay', - 'ascensionDay', - 'pentecostMonday', - 'assumptionOfMary', - 'allSaintsDay', - 'armisticeDay', - 'christmasDay', - 'stStephensDay', - 'bastilleDay', - ], self::REGION, $this->year, Holiday::TYPE_OFFICIAL); + $holidays = + [ + 'newYearsDay', + 'victoryInEuropeDay', + 'easterMonday', + 'internationalWorkersDay', + 'ascensionDay', + 'assumptionOfMary', + 'allSaintsDay', + 'armisticeDay', + 'christmasDay', + 'bastilleDay', + ]; + + if ($this->year < France::EST_YEAR_DAY_OF_SOLIDARITY_WITH_ELDERLY) { + $holidays[] = 'pentecostMonday'; + } + + $this->assertDefinedHolidays($holidays, self::REGION, $this->year, Holiday::TYPE_OFFICIAL); } /** @@ -65,7 +70,13 @@ public function testOfficialHolidays(): void */ public function testObservedHolidays(): void { - $this->assertDefinedHolidays([], self::REGION, $this->year, Holiday::TYPE_OBSERVANCE); + $holidays = []; + + if ($this->year >= France::EST_YEAR_DAY_OF_SOLIDARITY_WITH_ELDERLY) { + $holidays[] = 'pentecostMonday'; + } + + $this->assertDefinedHolidays($holidays, self::REGION, $this->year, Holiday::TYPE_OBSERVANCE); } /** diff --git a/tests/France/FranceTest.php b/tests/France/FranceTest.php index 2803d2b20..d73298a89 100644 --- a/tests/France/FranceTest.php +++ b/tests/France/FranceTest.php @@ -71,6 +71,7 @@ public function testOfficialHolidays(): void public function testObservedHolidays(): void { $holidays = []; + if ($this->year >= France::EST_YEAR_DAY_OF_SOLIDARITY_WITH_ELDERLY) { $holidays[] = 'pentecostMonday'; } diff --git a/tests/France/HautRhin/HautRhinTest.php b/tests/France/HautRhin/HautRhinTest.php index 3bdefdaaa..245177756 100644 --- a/tests/France/HautRhin/HautRhinTest.php +++ b/tests/France/HautRhin/HautRhinTest.php @@ -16,6 +16,7 @@ use ReflectionException; use Yasumi\Holiday; +use Yasumi\Provider\France; use Yasumi\tests\ProviderTestCase; /** @@ -43,21 +44,25 @@ protected function setUp(): void */ public function testOfficialHolidays(): void { - $this->assertDefinedHolidays([ - 'newYearsDay', - 'victoryInEuropeDay', - 'goodFriday', - 'easterMonday', - 'internationalWorkersDay', - 'ascensionDay', - 'pentecostMonday', - 'assumptionOfMary', - 'allSaintsDay', - 'armisticeDay', - 'christmasDay', - 'stStephensDay', - 'bastilleDay', - ], self::REGION, $this->year, Holiday::TYPE_OFFICIAL); + $holidays = + [ + 'newYearsDay', + 'victoryInEuropeDay', + 'easterMonday', + 'internationalWorkersDay', + 'ascensionDay', + 'assumptionOfMary', + 'allSaintsDay', + 'armisticeDay', + 'christmasDay', + 'bastilleDay', + ]; + + if ($this->year < France::EST_YEAR_DAY_OF_SOLIDARITY_WITH_ELDERLY) { + $holidays[] = 'pentecostMonday'; + } + + $this->assertDefinedHolidays($holidays, self::REGION, $this->year, Holiday::TYPE_OFFICIAL); } /** @@ -65,7 +70,13 @@ public function testOfficialHolidays(): void */ public function testObservedHolidays(): void { - $this->assertDefinedHolidays([], self::REGION, $this->year, Holiday::TYPE_OBSERVANCE); + $holidays = []; + + if ($this->year >= France::EST_YEAR_DAY_OF_SOLIDARITY_WITH_ELDERLY) { + $holidays[] = 'pentecostMonday'; + } + + $this->assertDefinedHolidays($holidays, self::REGION, $this->year, Holiday::TYPE_OBSERVANCE); } /** diff --git a/tests/France/Moselle/MoselleTest.php b/tests/France/Moselle/MoselleTest.php index 8a097222c..12ed17a99 100644 --- a/tests/France/Moselle/MoselleTest.php +++ b/tests/France/Moselle/MoselleTest.php @@ -16,6 +16,7 @@ use ReflectionException; use Yasumi\Holiday; +use Yasumi\Provider\France; use Yasumi\tests\ProviderTestCase; /** @@ -43,21 +44,25 @@ protected function setUp(): void */ public function testOfficialHolidays(): void { - $this->assertDefinedHolidays([ - 'newYearsDay', - 'victoryInEuropeDay', - 'goodFriday', - 'easterMonday', - 'internationalWorkersDay', - 'ascensionDay', - 'pentecostMonday', - 'assumptionOfMary', - 'allSaintsDay', - 'armisticeDay', - 'christmasDay', - 'stStephensDay', - 'bastilleDay', - ], self::REGION, $this->year, Holiday::TYPE_OFFICIAL); + $holidays = + [ + 'newYearsDay', + 'victoryInEuropeDay', + 'easterMonday', + 'internationalWorkersDay', + 'ascensionDay', + 'assumptionOfMary', + 'allSaintsDay', + 'armisticeDay', + 'christmasDay', + 'bastilleDay', + ]; + + if ($this->year < France::EST_YEAR_DAY_OF_SOLIDARITY_WITH_ELDERLY) { + $holidays[] = 'pentecostMonday'; + } + + $this->assertDefinedHolidays($holidays, self::REGION, $this->year, Holiday::TYPE_OFFICIAL); } /** @@ -65,7 +70,13 @@ public function testOfficialHolidays(): void */ public function testObservedHolidays(): void { - $this->assertDefinedHolidays([], self::REGION, $this->year, Holiday::TYPE_OBSERVANCE); + $holidays = []; + + if ($this->year >= France::EST_YEAR_DAY_OF_SOLIDARITY_WITH_ELDERLY) { + $holidays[] = 'pentecostMonday'; + } + + $this->assertDefinedHolidays($holidays, self::REGION, $this->year, Holiday::TYPE_OBSERVANCE); } /** From abdcbf88755aa89d35f0995ea4e3441bdefd12c7 Mon Sep 17 00:00:00 2001 From: Sacha Telgenhof Date: Wed, 15 Jun 2022 00:30:53 +0900 Subject: [PATCH 031/142] Formatting cleanup. Signed-off-by: Sacha Telgenhof --- CONTRIBUTING.md | 18 +++++++++--------- 1 file changed, 9 insertions(+), 9 deletions(-) diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md index 3317cab59..49c1c9f31 100644 --- a/CONTRIBUTING.md +++ b/CONTRIBUTING.md @@ -10,8 +10,8 @@ When contributing there are a few guidelines we'd like you to keep in mind: - **[PSR-12 Coding Standard](https://www.php-fig.org/psr/psr-12/)** Please use the following command after you have completed your work: - ``` bash - $ composer format + ``` shell + composer format ``` This will check/correct all the code for the PSR-12 Coding Standard using the @@ -20,9 +20,9 @@ When contributing there are a few guidelines we'd like you to keep in mind: - **Add unit tests!** - Your Pull Request won't be accepted if it does not have tests: 1. Ensure your new Holiday Provider contains all the necessary unit tests. - 2. Next to the file 'BaseTestCase.php', a file called 'Test.php' needs to be present. This + 2. Next to the file `{REGIONNAME}BaseTestCase.php`, a file called `{REGIONNAME}Test.php` needs to be present. This file needs to include region/country level tests and requires assertion of all expected holidays. - 3. All the unit tests and the implementation Holiday Provider require to have the correct locale, timezone and + 3. All the unit tests and the implementation Holiday Provider require to have the correct locale, time zone and region/country name. 4. As almost all tests use automatic iterations, make sure the year for which the test is executed is a valid year. Some holidays are only established from a certain year and having the test year number smaller than the minimum @@ -39,12 +39,12 @@ When contributing there are a few guidelines we'd like you to keep in mind: ## Running Tests -``` bash -$ composer test +``` shell +composer test ``` -or alternatively run with: +Or, alternatively run with: -``` bash -$ vendor/bin/phpunit +``` shell +vendor/bin/phpunit ``` From beb85aa0167095f35209f981da0c3a2003771eee Mon Sep 17 00:00:00 2001 From: Sacha Telgenhof Date: Thu, 11 Aug 2022 16:24:41 +0900 Subject: [PATCH 032/142] Upgraded rector configuration. Signed-off-by: Sacha Telgenhof --- rector.php | 24 +++++++++++++----------- 1 file changed, 13 insertions(+), 11 deletions(-) diff --git a/rector.php b/rector.php index 0b826aa72..d9bd2f07f 100644 --- a/rector.php +++ b/rector.php @@ -2,21 +2,23 @@ declare(strict_types=1); -use Rector\Core\Configuration\Option; +use Rector\CodeQuality\Rector\Class_\InlineConstructorDefaultToPropertyRector; +use Rector\Config\RectorConfig; use Rector\Set\ValueObject\SetList; -use Symfony\Component\DependencyInjection\Loader\Configurator\ContainerConfigurator; -return static function (ContainerConfigurator $containerConfigurator): void { - $parameters = $containerConfigurator->parameters(); - $parameters->set(Option::PATHS, [ +return static function (RectorConfig $rectorConfig): void { + $rectorConfig->paths([ __DIR__.'/src', ]); - $parameters->set(Option::AUTOLOAD_PATHS, [ - ]); + // single rules + $rectorConfig->rule(InlineConstructorDefaultToPropertyRector::class); - $containerConfigurator->import(SetList::CODE_QUALITY); - $containerConfigurator->import(SetList::TYPE_DECLARATION_STRICT); - $containerConfigurator->import(SetList::PHP_74); - $containerConfigurator->import(SetList::DEAD_CODE); + // sets of rules + $rectorConfig->sets([ + SetList::PHP_74, + SetList::CODE_QUALITY, + SetList::TYPE_DECLARATION_STRICT, + SetList::DEAD_CODE, + ]); }; From d775b3ef54595bacf6d46fefa86997bae3e45ba1 Mon Sep 17 00:00:00 2001 From: Sacha Telgenhof Date: Thu, 11 Aug 2022 16:25:51 +0900 Subject: [PATCH 033/142] Added missing type. Signed-off-by: Sacha Telgenhof --- src/Yasumi/Provider/AbstractProvider.php | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/src/Yasumi/Provider/AbstractProvider.php b/src/Yasumi/Provider/AbstractProvider.php index 1e13d69dd..82115ab11 100644 --- a/src/Yasumi/Provider/AbstractProvider.php +++ b/src/Yasumi/Provider/AbstractProvider.php @@ -73,10 +73,8 @@ abstract class AbstractProvider implements Countable, ProviderInterface, Iterato 'IN' => [0], // India ]; - /** - * @var int the object's current year - */ - protected $year; + /** @var int the object's current year */ + protected int $year; /** the object's current timezone */ protected string $timezone; From a57bf1878be97f2ef0f384cea8ba88a041824a49 Mon Sep 17 00:00:00 2001 From: Sacha Telgenhof Date: Thu, 11 Aug 2022 18:43:27 +0900 Subject: [PATCH 034/142] Added missing method return type. Signed-off-by: Sacha Telgenhof --- tests/Netherlands/ChristmasDayTest.php | 2 +- tests/Netherlands/EpiphanyTest.php | 2 +- tests/Netherlands/HalloweenTest.php | 2 +- tests/Netherlands/InternationalWorkersDayTest.php | 2 +- tests/Netherlands/NewYearsDayTest.php | 2 +- tests/Netherlands/ValentinesDayTest.php | 2 +- tests/Netherlands/secondChristmasdayTest.php | 2 +- tests/Netherlands/stMartinsDayTest.php | 2 +- tests/Netherlands/stNicholasDayTest.php | 2 +- tests/NewZealand/AnzacDayTest.php | 2 +- tests/NewZealand/QueensBirthdayTest.php | 2 +- tests/NewZealand/WaitangiDayTest.php | 2 +- 12 files changed, 12 insertions(+), 12 deletions(-) diff --git a/tests/Netherlands/ChristmasDayTest.php b/tests/Netherlands/ChristmasDayTest.php index 6101e7e86..35af70baa 100644 --- a/tests/Netherlands/ChristmasDayTest.php +++ b/tests/Netherlands/ChristmasDayTest.php @@ -37,7 +37,7 @@ class ChristmasDayTest extends NetherlandsBaseTestCase implements HolidayTestCas * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date */ - public function testHoliday(int $year, DateTime $expected): void + public function testHoliday(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Netherlands/EpiphanyTest.php b/tests/Netherlands/EpiphanyTest.php index c9db4a0ab..0ae287ac4 100644 --- a/tests/Netherlands/EpiphanyTest.php +++ b/tests/Netherlands/EpiphanyTest.php @@ -37,7 +37,7 @@ class EpiphanyTest extends NetherlandsBaseTestCase implements HolidayTestCase * @param int $year the year for which Epiphany needs to be tested * @param DateTime $expected the expected date */ - public function testEpiphany(int $year, DateTime $expected): void + public function testEpiphany(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Netherlands/HalloweenTest.php b/tests/Netherlands/HalloweenTest.php index 783949fec..d3857c14e 100644 --- a/tests/Netherlands/HalloweenTest.php +++ b/tests/Netherlands/HalloweenTest.php @@ -37,7 +37,7 @@ class HalloweenTest extends NetherlandsBaseTestCase implements HolidayTestCase * @param int $year the year for which Halloween needs to be tested * @param DateTime $expected the expected date */ - public function testHoliday(int $year, DateTime $expected): void + public function testHoliday(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Netherlands/InternationalWorkersDayTest.php b/tests/Netherlands/InternationalWorkersDayTest.php index a00e1e2f1..259d62bb1 100644 --- a/tests/Netherlands/InternationalWorkersDayTest.php +++ b/tests/Netherlands/InternationalWorkersDayTest.php @@ -37,7 +37,7 @@ class InternationalWorkersDayTest extends NetherlandsBaseTestCase implements Hol * @param int $year the year for which International Workers' Day needs to be tested * @param DateTime $expected the expected date */ - public function testInternationalWorkersDay(int $year, DateTime $expected): void + public function testInternationalWorkersDay(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Netherlands/NewYearsDayTest.php b/tests/Netherlands/NewYearsDayTest.php index e71cc80f9..5bcbe7845 100644 --- a/tests/Netherlands/NewYearsDayTest.php +++ b/tests/Netherlands/NewYearsDayTest.php @@ -37,7 +37,7 @@ class NewYearsDayTest extends NetherlandsBaseTestCase implements HolidayTestCase * @param int $year the year for which New Years Day needs to be tested * @param DateTime $expected the expected date */ - public function testNewYearsDay(int $year, DateTime $expected): void + public function testNewYearsDay(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Netherlands/ValentinesDayTest.php b/tests/Netherlands/ValentinesDayTest.php index 5c302cf54..1d4445749 100644 --- a/tests/Netherlands/ValentinesDayTest.php +++ b/tests/Netherlands/ValentinesDayTest.php @@ -37,7 +37,7 @@ class ValentinesDayTest extends NetherlandsBaseTestCase implements HolidayTestCa * @param int $year the year for which Valentines Day needs to be tested * @param DateTime $expected the expected date */ - public function testValentinesDay(int $year, DateTime $expected): void + public function testValentinesDay(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Netherlands/secondChristmasdayTest.php b/tests/Netherlands/secondChristmasdayTest.php index f8858adbd..8fed083af 100644 --- a/tests/Netherlands/secondChristmasdayTest.php +++ b/tests/Netherlands/secondChristmasdayTest.php @@ -37,7 +37,7 @@ class secondChristmasdayTest extends NetherlandsBaseTestCase implements HolidayT * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date */ - public function testHoliday(int $year, DateTime $expected): void + public function testHoliday(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Netherlands/stMartinsDayTest.php b/tests/Netherlands/stMartinsDayTest.php index f64e5b72a..f3a1dbe5c 100644 --- a/tests/Netherlands/stMartinsDayTest.php +++ b/tests/Netherlands/stMartinsDayTest.php @@ -37,7 +37,7 @@ class stMartinsDayTest extends NetherlandsBaseTestCase implements HolidayTestCas * @param int $year the year for which Sint Martins Day needs to be tested * @param DateTime $expected the expected date */ - public function teststMartinsDay(int $year, DateTime $expected): void + public function teststMartinsDay(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Netherlands/stNicholasDayTest.php b/tests/Netherlands/stNicholasDayTest.php index bc690befe..010ffa124 100644 --- a/tests/Netherlands/stNicholasDayTest.php +++ b/tests/Netherlands/stNicholasDayTest.php @@ -37,7 +37,7 @@ class stNicholasDayTest extends NetherlandsBaseTestCase implements HolidayTestCa * @param int $year the year for which Sint Nicholas Day needs to be tested * @param DateTime $expected the expected date */ - public function teststNicholasDay(int $year, DateTime $expected): void + public function teststNicholasDay(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/NewZealand/AnzacDayTest.php b/tests/NewZealand/AnzacDayTest.php index 48025121f..c5d58576f 100644 --- a/tests/NewZealand/AnzacDayTest.php +++ b/tests/NewZealand/AnzacDayTest.php @@ -72,7 +72,7 @@ public function testNotHoliday(): void */ public function HolidayDataProvider(): array { - return $this->generateRandomDatesWithModifier(4, 25, function ($year, DateTime $date) { + return $this->generateRandomDatesWithModifier(4, 25, function ($year, DateTime $date): void { // in 2015 some policy was introduced to make sure this holiday was celebrated during the working week. if ($year >= 2015 && $this->isWeekend($date)) { $date->modify('next monday'); diff --git a/tests/NewZealand/QueensBirthdayTest.php b/tests/NewZealand/QueensBirthdayTest.php index 9cb0ba085..e5189c918 100644 --- a/tests/NewZealand/QueensBirthdayTest.php +++ b/tests/NewZealand/QueensBirthdayTest.php @@ -43,7 +43,7 @@ class QueensBirthdayTest extends NewZealandBaseTestCase implements HolidayTestCa * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date */ - public function testHoliday(int $year, DateTime $expected): void + public function testHoliday(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/NewZealand/WaitangiDayTest.php b/tests/NewZealand/WaitangiDayTest.php index ea79aa5ca..c03902f14 100644 --- a/tests/NewZealand/WaitangiDayTest.php +++ b/tests/NewZealand/WaitangiDayTest.php @@ -102,7 +102,7 @@ public function testHolidayType(): void */ public function HolidayDataProvider(): array { - return $this->generateRandomDatesWithModifier(2, 06, function ($year, DateTime $date) { + return $this->generateRandomDatesWithModifier(2, 06, function ($year, DateTime $date): void { // in 2015 some policy was introduced to make sure this holiday was celebrated during the working week. if ($year >= 2015 && $this->isWeekend($date)) { $date->modify('next monday'); From 0829e012a637e35ce02be027b4423612698149f4 Mon Sep 17 00:00:00 2001 From: Sacha Telgenhof Date: Thu, 11 Aug 2022 20:13:18 +0900 Subject: [PATCH 035/142] Replaced DateTime with DateTimeInterface (Always use interface where possible). Signed-off-by: Sacha Telgenhof --- tests/Australia/AustraliaDayTest.php | 2 +- tests/Austria/AllSaintsDayTest.php | 2 +- tests/Austria/AssumptionOfMaryTest.php | 2 +- tests/Austria/Burgenland/stMartinsDayTest.php | 2 +- tests/Austria/Carinthia/PlebisciteDayTest.php | 2 +- tests/Austria/Carinthia/StJosephsDayTest.php | 2 +- tests/Austria/ChristmasTest.php | 2 +- tests/Austria/EpiphanyTest.php | 2 +- tests/Austria/ImmaculateConceptionTest.php | 2 +- tests/Austria/InternationalWorkersDayTest.php | 2 +- tests/Austria/LowerAustria/StLeopoldsDayTest.php | 2 +- tests/Austria/NewYearsDayTest.php | 2 +- tests/Austria/Salzburg/StRupertsDayTest.php | 2 +- tests/Austria/SecondChristmasDayTest.php | 2 +- tests/Austria/Styria/StJosephsDayTest.php | 2 +- tests/Austria/Tyrol/StJosephsDayTest.php | 2 +- tests/Austria/UpperAustria/StFloriansDayTest.php | 2 +- tests/Austria/Vienna/StLeopoldsDayTest.php | 2 +- tests/Austria/Vorarlberg/StJosephsDayTest.php | 2 +- tests/Belgium/AllSaintsDayTest.php | 2 +- tests/Belgium/ArmisticeDayTest.php | 2 +- tests/Belgium/AssumptionOfMaryTest.php | 2 +- tests/Belgium/ChristmasTest.php | 2 +- tests/Belgium/InternationalWorkersDayTest.php | 2 +- tests/Belgium/NationalDayTest.php | 2 +- tests/Belgium/NewYearsDayTest.php | 2 +- tests/Bosnia/ChristmasDayTest.php | 2 +- tests/Bosnia/DayAfterNewYearsDay.php | 2 +- tests/Bosnia/InternationalWorkersDayTest.php | 2 +- tests/Bosnia/NewYearsDayTest.php | 2 +- tests/Bosnia/OrthodoxChristmasDay.php | 3 +-- tests/Bosnia/SecondLabourDay.php | 2 +- tests/Croatia/AllSaintsDayTest.php | 2 +- tests/Croatia/AssumptionOfMaryTest.php | 2 +- tests/Croatia/ChristmasDayTest.php | 2 +- tests/Croatia/EpiphanyTest.php | 2 +- tests/Croatia/InternationalWorkersDayTest.php | 2 +- tests/Croatia/NewYearsDayTest.php | 2 +- tests/Croatia/StStephensDayTest.php | 2 +- tests/CzechRepublic/ChristmasDayTest.php | 2 +- tests/CzechRepublic/ChristmasEveTest.php | 2 +- tests/CzechRepublic/CzechStateHoodDayTest.php | 2 +- .../IndependentCzechoslovakStateDayTest.php | 2 +- .../CzechRepublic/InternationalWorkersDayTest.php | 2 +- tests/CzechRepublic/JanHusDayTest.php | 2 +- tests/CzechRepublic/NewYearsDayTest.php | 2 +- .../RenewalOfIndependentCzechStateDayTest.php | 2 +- .../SaintsCyrilAndMethodiusDayTest.php | 2 +- tests/CzechRepublic/SecondChristmasDayTest.php | 2 +- .../StruggleForFreedomAndDemocracyDayTest.php | 2 +- tests/CzechRepublic/VictoryInEuropeDayTest.php | 2 +- tests/Denmark/ChristmasDayTest.php | 2 +- tests/Denmark/ChristmasEveTest.php | 2 +- tests/Denmark/InternationalWorkersDayTest.php | 2 +- tests/Denmark/NewYearsDayTest.php | 2 +- tests/Denmark/NewYearsEveTest.php | 2 +- tests/Denmark/SecondChristmasDayTest.php | 2 +- tests/Estonia/ChristmasDayTest.php | 3 +-- tests/Estonia/ChristmasEveDayTest.php | 3 +-- tests/Estonia/InternationalWorkersDayTest.php | 3 +-- tests/Estonia/NewYearsDayTest.php | 3 +-- tests/Estonia/SecondChristmasDayTest.php | 3 +-- tests/Estonia/StJohnsDayTest.php | 3 +-- tests/Finland/AllSaintsDayTest.php | 2 +- tests/Finland/ChristmasDayTest.php | 2 +- tests/Finland/EpiphanyTest.php | 2 +- tests/Finland/InternationalWorkersDayTest.php | 2 +- tests/Finland/NewYearsDayTest.php | 2 +- tests/Finland/SecondChristmasDayTest.php | 2 +- tests/France/AllSaintsDayTest.php | 2 +- tests/France/AssumptionOfMaryTest.php | 2 +- tests/France/BasRhin/stStephensDayTest.php | 2 +- tests/France/ChristmasDayTest.php | 2 +- tests/France/HautRhin/stStephensDayTest.php | 2 +- tests/France/InternationalWorkersDayTest.php | 2 +- tests/France/Moselle/stStephensDayTest.php | 2 +- tests/France/NewYearsDayTest.php | 2 +- tests/Georgia/InternationalWomensDayTest.php | 3 +-- tests/Georgia/MtskhetobaDayTest.php | 3 +-- tests/Georgia/NewYearsDayTest.php | 3 +-- tests/Georgia/OrthodoxChristmasDayTest.php | 3 +-- tests/Georgia/OrthodoxEpiphanyDayTest.php | 3 +-- tests/Georgia/SecondNewYearDayTest.php | 3 +-- tests/Georgia/StAndrewsDayTest.php | 3 +-- tests/Georgia/StGeorgesDayTest.php | 3 +-- tests/Georgia/StMarysDayTest.php | 3 +-- tests/Georgia/VictoryDayTest.php | 3 +-- .../Germany/BadenWurttemberg/AllSaintsDayTest.php | 2 +- tests/Germany/BadenWurttemberg/EpiphanyTest.php | 2 +- tests/Germany/Bavaria/AllSaintsDayTest.php | 2 +- tests/Germany/Bavaria/EpiphanyTest.php | 2 +- tests/Germany/Brandenburg/ReformationDayTest.php | 2 +- tests/Germany/Bremen/ReformationDayTest.php | 2 +- tests/Germany/ChristmasTest.php | 2 +- tests/Germany/Hamburg/DayOfReformationTest.php | 2 +- tests/Germany/InternationalWorkersDayTest.php | 2 +- tests/Germany/LowerSaxony/ReformationDayTest.php | 2 +- tests/Germany/NewYearsDayTest.php | 2 +- tests/Germany/NewYearsEveTest.php | 2 +- .../NorthRhineWestphalia/AllSaintsDayTest.php | 2 +- .../RhinelandPalatinate/AllSaintsDayTest.php | 2 +- tests/Germany/Saarland/AllSaintsDayTest.php | 2 +- tests/Germany/Saarland/AssumptionOfMaryTest.php | 2 +- tests/Germany/Saxony/ReformationDayTest.php | 2 +- tests/Germany/SaxonyAnhalt/EpiphanyTest.php | 2 +- tests/Germany/SaxonyAnhalt/ReformationDayTest.php | 2 +- .../SchleswigHolstein/ReformationDayTest.php | 2 +- tests/Germany/SecondChristmasDayTest.php | 2 +- tests/Germany/Thuringia/ReformationDayTest.php | 2 +- tests/Germany/Thuringia/WorldChildrensDayTest.php | 2 +- tests/Greece/AnnunciationTest.php | 2 +- tests/Greece/AssumptionOfMaryTest.php | 2 +- tests/Greece/ChristmasDayTest.php | 2 +- tests/Greece/EpiphanyTest.php | 2 +- tests/Greece/InternationalWorkersDayTest.php | 2 +- tests/Greece/NewYearsDayTest.php | 2 +- tests/Greece/ThreeHolyHierarchsTest.php | 2 +- tests/Hungary/AllSaintsDayTest.php | 2 +- tests/Hungary/ChristmasTest.php | 2 +- tests/Hungary/InternationalWorkersDayTest.php | 2 +- tests/Hungary/NewYearsDayTest.php | 2 +- tests/Hungary/SecondChristmasDayTest.php | 2 +- tests/Italy/AllSaintsDayTest.php | 2 +- tests/Italy/AssumptionOfMaryTest.php | 2 +- tests/Italy/ChristmasTest.php | 2 +- tests/Italy/EpiphanyTest.php | 2 +- tests/Italy/ImmaculateConceptionTest.php | 2 +- tests/Italy/InternationalWorkersDayTest.php | 2 +- tests/Italy/NewYearsDayTest.php | 2 +- tests/Italy/stStephensDayTest.php | 2 +- tests/Latvia/ChristmasDayTest.php | 3 +-- tests/Latvia/ChristmasEveDayTest.php | 3 +-- tests/Latvia/InternationalWorkersDayTest.php | 3 +-- tests/Latvia/MidsummerEveDayTest.php | 3 +-- tests/Latvia/NewYearsDayTest.php | 3 +-- tests/Latvia/NewYearsEveDayTest.php | 3 +-- tests/Latvia/SecondChristmasDayTest.php | 3 +-- tests/Latvia/StJohnsDayTest.php | 3 +-- tests/Lithuania/AllSaintsDayTest.php | 3 +-- tests/Lithuania/AssumptionOfMaryDayTest.php | 3 +-- tests/Lithuania/ChristmasDayTest.php | 3 +-- tests/Lithuania/ChristmasEveDayTest.php | 3 +-- tests/Lithuania/InternationalWorkersDayTest.php | 3 +-- tests/Lithuania/NewYearsDayTest.php | 3 +-- tests/Lithuania/SecondChristmasDayTest.php | 3 +-- tests/Lithuania/StJohnsDayTest.php | 3 +-- tests/Luxembourg/AllSaintsDayTest.php | 2 +- tests/Luxembourg/AssumptionOfMaryTest.php | 2 +- tests/Luxembourg/ChristmasDayTest.php | 2 +- tests/Luxembourg/InternationalWorkersDayTest.php | 2 +- tests/Luxembourg/NationalDayTest.php | 2 +- tests/Luxembourg/NewYearsDayTest.php | 2 +- tests/Luxembourg/SecondChristmasDayTest.php | 2 +- tests/Norway/ChristmasDayTest.php | 2 +- tests/Norway/InternationalWorkersDayTest.php | 2 +- tests/Norway/NewYearsDayTest.php | 2 +- tests/Norway/SecondChristmasDayTest.php | 2 +- tests/Poland/AllSaintsDayTest.php | 2 +- tests/Poland/AssumptionOfMaryTest.php | 2 +- tests/Poland/ChristmasTest.php | 2 +- tests/Poland/EpiphanyTest.php | 2 +- tests/Poland/InternationalWorkersDayTest.php | 2 +- tests/Poland/NewYearsDayTest.php | 2 +- tests/Poland/SecondChristmasDayTest.php | 2 +- tests/Portugal/AssumptionOfMaryTest.php | 2 +- tests/Portugal/ChristmasTest.php | 2 +- tests/Portugal/ImmaculateConceptionTest.php | 2 +- tests/Portugal/InternationalWorkersDayTest.php | 2 +- tests/Portugal/NewYearsDayTest.php | 2 +- tests/Romania/ChristmasDayTest.php | 2 +- tests/Romania/DayAfterNewYearsDayTest.php | 2 +- tests/Romania/InternationalWorkersDayTest.php | 2 +- tests/Romania/NewYearsDayTest.php | 2 +- tests/Romania/SecondChristmasDayTest.php | 2 +- tests/Russia/InternationalWomensDayTest.php | 3 +-- tests/Russia/NewYearHolidaysDay2Test.php | 3 +-- tests/Russia/NewYearHolidaysDay3Test.php | 3 +-- tests/Russia/NewYearHolidaysDay4Test.php | 3 +-- tests/Russia/NewYearHolidaysDay5Test.php | 3 +-- tests/Russia/NewYearHolidaysDay6Test.php | 3 +-- tests/Russia/NewYearHolidaysDay8Test.php | 3 +-- tests/Russia/NewYearsDayTest.php | 3 +-- tests/Russia/OrthodoxChristmasDayTest.php | 3 +-- tests/Russia/SpringAndLabourDayTest.php | 3 +-- tests/Russia/VictoryDayTest.php | 3 +-- tests/Slovakia/AllSaintsDayTest.php | 2 +- tests/Slovakia/ChristmasDayTest.php | 2 +- tests/Slovakia/ChristmasEveTest.php | 2 +- tests/Slovakia/EasterMondayTest.php | 2 +- tests/Slovakia/EpiphanyTest.php | 2 +- tests/Slovakia/GoodFridayTest.php | 2 +- tests/Slovakia/InternationalWorkersDayTest.php | 2 +- tests/Slovakia/OurLadyOfSorrowsDayTest.php | 2 +- tests/Slovakia/SaintsCyrilAndMethodiusDayTest.php | 2 +- tests/Slovakia/SecondChristmasDayTest.php | 2 +- tests/Slovakia/SlovakConstitutionDayTest.php | 2 +- tests/Slovakia/SlovakIndependeceDayTest.php | 2 +- tests/Slovakia/SlovakNationalUprisingDayTest.php | 2 +- .../StruggleForFreedomAndDemocracyDayTest.php | 2 +- tests/Slovakia/VictoryInEuropeDayTest.php | 2 +- tests/Spain/AllSaintsDayTest.php | 2 +- tests/Spain/AssumptionOfMaryTest.php | 2 +- tests/Spain/Catalonia/stJohnsDayTest.php | 2 +- tests/Spain/ChristmasTest.php | 2 +- tests/Spain/EpiphanyTest.php | 2 +- tests/Spain/ImmaculateConceptionTest.php | 2 +- tests/Spain/InternationalWorkersDayTest.php | 2 +- tests/Spain/NewYearsDayTest.php | 2 +- tests/Spain/ValentinesDayTest.php | 2 +- tests/Spain/stJosephsDayTest.php | 2 +- tests/Sweden/AllSaintsDayTest.php | 2 +- tests/Sweden/AllSaintsEveTest.php | 2 +- tests/Sweden/ChristmasDayTest.php | 2 +- tests/Sweden/ChristmasEveTest.php | 2 +- tests/Sweden/EpiphanyEveTest.php | 2 +- tests/Sweden/EpiphanyTest.php | 2 +- tests/Sweden/InternationalWorkersDayTest.php | 2 +- tests/Sweden/NewYearsDayTest.php | 2 +- tests/Sweden/NewYearsEveTest.php | 2 +- tests/Sweden/SecondChristmasDayTest.php | 2 +- tests/Sweden/WalpurgisEveTest.php | 2 +- tests/Switzerland/Aargau/ChristmasDayTest.php | 2 +- tests/Switzerland/Aargau/NewYearsDayTest.php | 2 +- .../AppenzellAusserrhoden/ChristmasDayTest.php | 2 +- .../AppenzellAusserrhoden/NewYearsDayTest.php | 2 +- .../AppenzellAusserrhoden/StStephensDayTest.php | 2 +- .../AppenzellInnerrhoden/AllSaintsDayTest.php | 2 +- .../AppenzellInnerrhoden/AssumptionOfMaryTest.php | 2 +- .../AppenzellInnerrhoden/ChristmasDayTest.php | 2 +- .../ImmaculateConceptionTest.php | 2 +- .../AppenzellInnerrhoden/NewYearsDayTest.php | 2 +- .../AppenzellInnerrhoden/StStephensDayTest.php | 2 +- .../BaselLandschaft/ChristmasDayTest.php | 2 +- .../BaselLandschaft/NewYearsDayTest.php | 2 +- .../BaselLandschaft/StStephensDayTest.php | 2 +- tests/Switzerland/BaselStadt/ChristmasDayTest.php | 2 +- tests/Switzerland/BaselStadt/NewYearsDayTest.php | 2 +- tests/Switzerland/BaselStadt/StStephensDayTest.php | 2 +- tests/Switzerland/Bern/ChristmasDayTest.php | 2 +- tests/Switzerland/Bern/NewYearsDayTest.php | 2 +- tests/Switzerland/Bern/StStephensDayTest.php | 2 +- tests/Switzerland/Fribourg/AllSaintsDayTest.php | 2 +- .../Switzerland/Fribourg/AssumptionOfMaryTest.php | 2 +- tests/Switzerland/Fribourg/ChristmasDayTest.php | 2 +- .../Fribourg/ImmaculateConceptionTest.php | 2 +- tests/Switzerland/Fribourg/NewYearsDayTest.php | 2 +- tests/Switzerland/Geneva/ChristmasDayTest.php | 2 +- tests/Switzerland/Geneva/NewYearsDayTest.php | 2 +- tests/Switzerland/Glarus/AllSaintsDayTest.php | 2 +- tests/Switzerland/Glarus/ChristmasDayTest.php | 2 +- tests/Switzerland/Glarus/NewYearsDayTest.php | 2 +- tests/Switzerland/Glarus/StStephensDayTest.php | 2 +- tests/Switzerland/Grisons/ChristmasDayTest.php | 2 +- tests/Switzerland/Grisons/NewYearsDayTest.php | 2 +- tests/Switzerland/Grisons/StStephensDayTest.php | 2 +- tests/Switzerland/Jura/AllSaintsDayTest.php | 2 +- tests/Switzerland/Jura/AssumptionOfMaryTest.php | 2 +- tests/Switzerland/Jura/ChristmasDayTest.php | 2 +- tests/Switzerland/Jura/NewYearsDayTest.php | 2 +- tests/Switzerland/Lucerne/AllSaintsDayTest.php | 2 +- tests/Switzerland/Lucerne/AssumptionOfMaryTest.php | 2 +- tests/Switzerland/Lucerne/ChristmasDayTest.php | 2 +- .../Lucerne/ImmaculateConceptionTest.php | 2 +- tests/Switzerland/Lucerne/NewYearsDayTest.php | 2 +- tests/Switzerland/Lucerne/StStephensDayTest.php | 2 +- tests/Switzerland/Neuchatel/ChristmasDayTest.php | 2 +- tests/Switzerland/Neuchatel/NewYearsDayTest.php | 2 +- tests/Switzerland/Nidwalden/AllSaintsDayTest.php | 2 +- .../Switzerland/Nidwalden/AssumptionOfMaryTest.php | 2 +- tests/Switzerland/Nidwalden/ChristmasDayTest.php | 2 +- .../Nidwalden/ImmaculateConceptionTest.php | 2 +- tests/Switzerland/Nidwalden/NewYearsDayTest.php | 2 +- tests/Switzerland/Nidwalden/StJosephDayTest.php | 2 +- tests/Switzerland/Nidwalden/StStephensDayTest.php | 2 +- tests/Switzerland/Obwalden/AllSaintsDayTest.php | 2 +- .../Switzerland/Obwalden/AssumptionOfMaryTest.php | 2 +- tests/Switzerland/Obwalden/ChristmasDayTest.php | 2 +- .../Obwalden/ImmaculateConceptionTest.php | 2 +- tests/Switzerland/Obwalden/NewYearsDayTest.php | 2 +- tests/Switzerland/Obwalden/StStephensDayTest.php | 2 +- .../Switzerland/Schaffhausen/ChristmasDayTest.php | 2 +- tests/Switzerland/Schaffhausen/NewYearsDayTest.php | 2 +- .../Switzerland/Schaffhausen/StStephensDayTest.php | 2 +- tests/Switzerland/Schwyz/AllSaintsDayTest.php | 2 +- tests/Switzerland/Schwyz/AssumptionOfMaryTest.php | 2 +- tests/Switzerland/Schwyz/ChristmasDayTest.php | 2 +- tests/Switzerland/Schwyz/EpiphanyTest.php | 2 +- .../Schwyz/ImmaculateConceptionTest.php | 2 +- tests/Switzerland/Schwyz/NewYearsDayTest.php | 2 +- tests/Switzerland/Schwyz/StJosephDayTest.php | 2 +- tests/Switzerland/Schwyz/StStephensDayTest.php | 2 +- tests/Switzerland/Solothurn/ChristmasDayTest.php | 2 +- tests/Switzerland/Solothurn/NewYearsDayTest.php | 2 +- tests/Switzerland/StGallen/AllSaintsDayTest.php | 2 +- tests/Switzerland/StGallen/ChristmasDayTest.php | 2 +- tests/Switzerland/StGallen/NewYearsDayTest.php | 2 +- tests/Switzerland/StGallen/StStephensDayTest.php | 2 +- tests/Switzerland/Thurgau/ChristmasDayTest.php | 2 +- tests/Switzerland/Thurgau/NewYearsDayTest.php | 2 +- tests/Switzerland/Thurgau/StStephensDayTest.php | 2 +- tests/Switzerland/Ticino/AllSaintsDayTest.php | 2 +- tests/Switzerland/Ticino/AssumptionOfMaryTest.php | 2 +- tests/Switzerland/Ticino/ChristmasDayTest.php | 2 +- tests/Switzerland/Ticino/EpiphanyTest.php | 2 +- .../Ticino/ImmaculateConceptionTest.php | 2 +- tests/Switzerland/Ticino/NewYearsDayTest.php | 2 +- tests/Switzerland/Ticino/StJosephDayTest.php | 2 +- tests/Switzerland/Ticino/StPeterPaulTest.php | 2 +- tests/Switzerland/Ticino/StStephensDayTest.php | 2 +- tests/Switzerland/Uri/AllSaintsDayTest.php | 2 +- tests/Switzerland/Uri/AssumptionOfMaryTest.php | 2 +- tests/Switzerland/Uri/ChristmasDayTest.php | 2 +- tests/Switzerland/Uri/EpiphanyTest.php | 2 +- tests/Switzerland/Uri/ImmaculateConceptionTest.php | 2 +- tests/Switzerland/Uri/NewYearsDayTest.php | 2 +- tests/Switzerland/Uri/StJosephDayTest.php | 2 +- tests/Switzerland/Uri/StStephensDayTest.php | 2 +- tests/Switzerland/Valais/AllSaintsDayTest.php | 2 +- tests/Switzerland/Valais/AssumptionOfMaryTest.php | 2 +- tests/Switzerland/Valais/ChristmasDayTest.php | 2 +- .../Valais/ImmaculateConceptionTest.php | 2 +- tests/Switzerland/Valais/NewYearsDayTest.php | 2 +- tests/Switzerland/Valais/StJosephDayTest.php | 2 +- tests/Switzerland/Vaud/ChristmasDayTest.php | 2 +- tests/Switzerland/Vaud/NewYearsDayTest.php | 2 +- tests/Switzerland/Zug/AllSaintsDayTest.php | 2 +- tests/Switzerland/Zug/AssumptionOfMaryTest.php | 2 +- tests/Switzerland/Zug/ChristmasDayTest.php | 2 +- tests/Switzerland/Zug/ImmaculateConceptionTest.php | 2 +- tests/Switzerland/Zug/NewYearsDayTest.php | 2 +- tests/Switzerland/Zug/StStephensDayTest.php | 2 +- tests/Switzerland/Zurich/ChristmasDayTest.php | 2 +- tests/Switzerland/Zurich/NewYearsDayTest.php | 2 +- tests/Switzerland/Zurich/StStephensDayTest.php | 2 +- tests/Turkey/LabourDayTest.php | 2 +- tests/Turkey/NewYearsDayTest.php | 2 +- tests/Ukraine/CatholicChristmasDayTest.php | 2 +- tests/Ukraine/ChristmasDayTest.php | 2 +- tests/Ukraine/InternationalWomensDayTest.php | 3 +-- tests/Ukraine/InternationalWorkersDayTest.php | 2 +- tests/Ukraine/NewYearsDayTest.php | 2 +- .../Ukraine/SecondInternationalWorkersDayTest.php | 2 +- tests/Ukraine/SubstitutedHolidayTest.php | 14 +++++++------- tests/Ukraine/VictoryDayTest.php | 3 +-- tests/YasumiBase.php | 8 ++++---- 345 files changed, 354 insertions(+), 400 deletions(-) diff --git a/tests/Australia/AustraliaDayTest.php b/tests/Australia/AustraliaDayTest.php index 16bbbf238..e07497ee0 100644 --- a/tests/Australia/AustraliaDayTest.php +++ b/tests/Australia/AustraliaDayTest.php @@ -38,7 +38,7 @@ class AustraliaDayTest extends AustraliaBaseTestCase implements HolidayTestCase * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date */ - public function testHoliday(int $year, DateTime $expected): void + public function testHoliday(int $year, \DateTimeInterface $expected): void { $this->assertHoliday($this->region, self::HOLIDAY, $year, $expected); } diff --git a/tests/Austria/AllSaintsDayTest.php b/tests/Austria/AllSaintsDayTest.php index 3a21f53e1..959a41a60 100644 --- a/tests/Austria/AllSaintsDayTest.php +++ b/tests/Austria/AllSaintsDayTest.php @@ -37,7 +37,7 @@ class AllSaintsDayTest extends AustriaBaseTestCase implements HolidayTestCase * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date */ - public function testHoliday(int $year, DateTime $expected): void + public function testHoliday(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Austria/AssumptionOfMaryTest.php b/tests/Austria/AssumptionOfMaryTest.php index 79b48b6a6..f74fcdd31 100644 --- a/tests/Austria/AssumptionOfMaryTest.php +++ b/tests/Austria/AssumptionOfMaryTest.php @@ -37,7 +37,7 @@ class AssumptionOfMaryTest extends AustriaBaseTestCase implements HolidayTestCas * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date */ - public function testHoliday(int $year, DateTime $expected): void + public function testHoliday(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Austria/Burgenland/stMartinsDayTest.php b/tests/Austria/Burgenland/stMartinsDayTest.php index 1600e642e..1f311c859 100644 --- a/tests/Austria/Burgenland/stMartinsDayTest.php +++ b/tests/Austria/Burgenland/stMartinsDayTest.php @@ -37,7 +37,7 @@ class stMartinsDayTest extends BurgenlandBaseTestCase implements HolidayTestCase * @param int $year the year for which Saint Martins Day needs to be tested * @param DateTime $expected the expected date */ - public function teststMartinsDay(int $year, DateTime $expected): void + public function teststMartinsDay(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Austria/Carinthia/PlebisciteDayTest.php b/tests/Austria/Carinthia/PlebisciteDayTest.php index 7fcf95fcd..0ac7d171e 100644 --- a/tests/Austria/Carinthia/PlebisciteDayTest.php +++ b/tests/Austria/Carinthia/PlebisciteDayTest.php @@ -43,7 +43,7 @@ class PlebisciteDayTest extends CarinthiaBaseTestCase implements HolidayTestCase * @param int $year the year for which Plebiscite Day needs to be tested * @param DateTime $expected the expected date */ - public function testPlebisciteDay(int $year, DateTime $expected): void + public function testPlebisciteDay(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Austria/Carinthia/StJosephsDayTest.php b/tests/Austria/Carinthia/StJosephsDayTest.php index be01f9ff7..10ccad1d6 100644 --- a/tests/Austria/Carinthia/StJosephsDayTest.php +++ b/tests/Austria/Carinthia/StJosephsDayTest.php @@ -37,7 +37,7 @@ class StJosephsDayTest extends CarinthiaBaseTestCase implements HolidayTestCase * @param int $year the year for which St. Joseph's Day needs to be tested. * @param DateTime $expected the expected date */ - public function testStJosephsDay(int $year, DateTime $expected): void + public function testStJosephsDay(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Austria/ChristmasTest.php b/tests/Austria/ChristmasTest.php index 4373654bf..6a5922f59 100644 --- a/tests/Austria/ChristmasTest.php +++ b/tests/Austria/ChristmasTest.php @@ -37,7 +37,7 @@ class ChristmasTest extends AustriaBaseTestCase implements HolidayTestCase * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date */ - public function testHoliday(int $year, DateTime $expected): void + public function testHoliday(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Austria/EpiphanyTest.php b/tests/Austria/EpiphanyTest.php index 1373e4d8c..1b63331d2 100644 --- a/tests/Austria/EpiphanyTest.php +++ b/tests/Austria/EpiphanyTest.php @@ -37,7 +37,7 @@ class EpiphanyTest extends AustriaBaseTestCase implements HolidayTestCase * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date */ - public function testHoliday(int $year, DateTime $expected): void + public function testHoliday(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Austria/ImmaculateConceptionTest.php b/tests/Austria/ImmaculateConceptionTest.php index 0499dd59a..d298ab70e 100644 --- a/tests/Austria/ImmaculateConceptionTest.php +++ b/tests/Austria/ImmaculateConceptionTest.php @@ -37,7 +37,7 @@ class ImmaculateConceptionTest extends AustriaBaseTestCase implements HolidayTes * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date */ - public function testHoliday(int $year, DateTime $expected): void + public function testHoliday(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Austria/InternationalWorkersDayTest.php b/tests/Austria/InternationalWorkersDayTest.php index 652f25fdf..5770f53f3 100644 --- a/tests/Austria/InternationalWorkersDayTest.php +++ b/tests/Austria/InternationalWorkersDayTest.php @@ -37,7 +37,7 @@ class InternationalWorkersDayTest extends AustriaBaseTestCase implements Holiday * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date */ - public function testHoliday(int $year, DateTime $expected): void + public function testHoliday(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Austria/LowerAustria/StLeopoldsDayTest.php b/tests/Austria/LowerAustria/StLeopoldsDayTest.php index d14f2ba22..ab2b194c6 100644 --- a/tests/Austria/LowerAustria/StLeopoldsDayTest.php +++ b/tests/Austria/LowerAustria/StLeopoldsDayTest.php @@ -43,7 +43,7 @@ class StLeopoldsDayTest extends LowerAustriaBaseTestCase implements HolidayTestC * @param int $year the year for which Saint Leopold's Day needs to be tested * @param DateTime $expected the expected date */ - public function testStLeopoldsDay(int $year, DateTime $expected): void + public function testStLeopoldsDay(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Austria/NewYearsDayTest.php b/tests/Austria/NewYearsDayTest.php index 73d5588a0..5f913882a 100644 --- a/tests/Austria/NewYearsDayTest.php +++ b/tests/Austria/NewYearsDayTest.php @@ -37,7 +37,7 @@ class NewYearsDayTest extends AustriaBaseTestCase implements HolidayTestCase * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date */ - public function testHoliday(int $year, DateTime $expected): void + public function testHoliday(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Austria/Salzburg/StRupertsDayTest.php b/tests/Austria/Salzburg/StRupertsDayTest.php index 880385ea2..c199bee71 100644 --- a/tests/Austria/Salzburg/StRupertsDayTest.php +++ b/tests/Austria/Salzburg/StRupertsDayTest.php @@ -37,7 +37,7 @@ class StRupertsDayTest extends SalzburgBaseTestCase implements HolidayTestCase * @param int $year the year for which Saint Rupert's Day needs to be tested * @param DateTime $expected the expected date */ - public function testStRupertsDay(int $year, DateTime $expected): void + public function testStRupertsDay(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Austria/SecondChristmasDayTest.php b/tests/Austria/SecondChristmasDayTest.php index 4d0a82886..bb5376350 100644 --- a/tests/Austria/SecondChristmasDayTest.php +++ b/tests/Austria/SecondChristmasDayTest.php @@ -37,7 +37,7 @@ class SecondChristmasDayTest extends AustriaBaseTestCase implements HolidayTestC * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date */ - public function testHoliday(int $year, DateTime $expected): void + public function testHoliday(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Austria/Styria/StJosephsDayTest.php b/tests/Austria/Styria/StJosephsDayTest.php index c3d55e3bd..e298986f1 100644 --- a/tests/Austria/Styria/StJosephsDayTest.php +++ b/tests/Austria/Styria/StJosephsDayTest.php @@ -37,7 +37,7 @@ class StJosephsDayTest extends StyriaBaseTestCase implements HolidayTestCase * @param int $year the year for which St. Joseph's Day needs to be tested. * @param DateTime $expected the expected date */ - public function testStJosephsDay(int $year, DateTime $expected): void + public function testStJosephsDay(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Austria/Tyrol/StJosephsDayTest.php b/tests/Austria/Tyrol/StJosephsDayTest.php index 6894d92e5..66fffedc7 100644 --- a/tests/Austria/Tyrol/StJosephsDayTest.php +++ b/tests/Austria/Tyrol/StJosephsDayTest.php @@ -37,7 +37,7 @@ class StJosephsDayTest extends TyrolBaseTestCase implements HolidayTestCase * @param int $year the year for which St. Joseph's Day needs to be tested. * @param DateTime $expected the expected date */ - public function testStJosephsDay(int $year, DateTime $expected): void + public function testStJosephsDay(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Austria/UpperAustria/StFloriansDayTest.php b/tests/Austria/UpperAustria/StFloriansDayTest.php index 5bdd1d540..2183a031b 100644 --- a/tests/Austria/UpperAustria/StFloriansDayTest.php +++ b/tests/Austria/UpperAustria/StFloriansDayTest.php @@ -37,7 +37,7 @@ class StFloriansDayTest extends UpperAustriaBaseTestCase implements HolidayTestC * @param int $year the year for which Saint Florian's Day needs to be tested * @param DateTime $expected the expected date */ - public function testStFloriansDay(int $year, DateTime $expected): void + public function testStFloriansDay(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Austria/Vienna/StLeopoldsDayTest.php b/tests/Austria/Vienna/StLeopoldsDayTest.php index ca1dbd237..d045331ee 100644 --- a/tests/Austria/Vienna/StLeopoldsDayTest.php +++ b/tests/Austria/Vienna/StLeopoldsDayTest.php @@ -43,7 +43,7 @@ class StLeopoldsDayTest extends ViennaBaseTestCase implements HolidayTestCase * @param int $year the year for which Saint Leopold's Day needs to be tested * @param DateTime $expected the expected date */ - public function testStLeopoldsDay(int $year, DateTime $expected): void + public function testStLeopoldsDay(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Austria/Vorarlberg/StJosephsDayTest.php b/tests/Austria/Vorarlberg/StJosephsDayTest.php index 12b6ae4e0..83c7d622a 100644 --- a/tests/Austria/Vorarlberg/StJosephsDayTest.php +++ b/tests/Austria/Vorarlberg/StJosephsDayTest.php @@ -37,7 +37,7 @@ class StJosephsDayTest extends VorarlbergBaseTestCase implements HolidayTestCase * @param int $year the year for which St. Joseph's Day needs to be tested. * @param DateTime $expected the expected date */ - public function testStJosephsDay(int $year, DateTime $expected): void + public function testStJosephsDay(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Belgium/AllSaintsDayTest.php b/tests/Belgium/AllSaintsDayTest.php index d45c5292e..84170fec1 100644 --- a/tests/Belgium/AllSaintsDayTest.php +++ b/tests/Belgium/AllSaintsDayTest.php @@ -37,7 +37,7 @@ class AllSaintsDayTest extends BelgiumBaseTestCase implements HolidayTestCase * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date */ - public function testHoliday(int $year, DateTime $expected): void + public function testHoliday(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Belgium/ArmisticeDayTest.php b/tests/Belgium/ArmisticeDayTest.php index 0906630fd..7293e01a6 100644 --- a/tests/Belgium/ArmisticeDayTest.php +++ b/tests/Belgium/ArmisticeDayTest.php @@ -37,7 +37,7 @@ class ArmisticeDayTest extends BelgiumBaseTestCase implements HolidayTestCase * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date */ - public function testHoliday(int $year, DateTime $expected): void + public function testHoliday(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Belgium/AssumptionOfMaryTest.php b/tests/Belgium/AssumptionOfMaryTest.php index 4461dfd4b..c76bc9b5c 100644 --- a/tests/Belgium/AssumptionOfMaryTest.php +++ b/tests/Belgium/AssumptionOfMaryTest.php @@ -37,7 +37,7 @@ class AssumptionOfMaryTest extends BelgiumBaseTestCase implements HolidayTestCas * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date */ - public function testHoliday(int $year, DateTime $expected): void + public function testHoliday(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Belgium/ChristmasTest.php b/tests/Belgium/ChristmasTest.php index 1b0186712..525096eda 100644 --- a/tests/Belgium/ChristmasTest.php +++ b/tests/Belgium/ChristmasTest.php @@ -37,7 +37,7 @@ class ChristmasTest extends BelgiumBaseTestCase implements HolidayTestCase * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date */ - public function testHoliday(int $year, DateTime $expected): void + public function testHoliday(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Belgium/InternationalWorkersDayTest.php b/tests/Belgium/InternationalWorkersDayTest.php index 2fd13c167..da29b5ba5 100644 --- a/tests/Belgium/InternationalWorkersDayTest.php +++ b/tests/Belgium/InternationalWorkersDayTest.php @@ -37,7 +37,7 @@ class InternationalWorkersDayTest extends BelgiumBaseTestCase implements Holiday * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date */ - public function testHoliday(int $year, DateTime $expected): void + public function testHoliday(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Belgium/NationalDayTest.php b/tests/Belgium/NationalDayTest.php index 43e4e2419..5021959b0 100644 --- a/tests/Belgium/NationalDayTest.php +++ b/tests/Belgium/NationalDayTest.php @@ -37,7 +37,7 @@ class NationalDayTest extends BelgiumBaseTestCase implements HolidayTestCase * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date */ - public function testHoliday(int $year, DateTime $expected): void + public function testHoliday(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Belgium/NewYearsDayTest.php b/tests/Belgium/NewYearsDayTest.php index 6a671f436..926e7b4f2 100644 --- a/tests/Belgium/NewYearsDayTest.php +++ b/tests/Belgium/NewYearsDayTest.php @@ -37,7 +37,7 @@ class NewYearsDayTest extends BelgiumBaseTestCase implements HolidayTestCase * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date */ - public function testHoliday(int $year, DateTime $expected): void + public function testHoliday(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Bosnia/ChristmasDayTest.php b/tests/Bosnia/ChristmasDayTest.php index 2216185fa..e3cd0b347 100644 --- a/tests/Bosnia/ChristmasDayTest.php +++ b/tests/Bosnia/ChristmasDayTest.php @@ -37,7 +37,7 @@ class ChristmasDayTest extends BosniaBaseTestCase implements HolidayTestCase * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date */ - public function testHoliday(int $year, DateTime $expected): void + public function testHoliday(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Bosnia/DayAfterNewYearsDay.php b/tests/Bosnia/DayAfterNewYearsDay.php index 8551a4cd7..061987323 100644 --- a/tests/Bosnia/DayAfterNewYearsDay.php +++ b/tests/Bosnia/DayAfterNewYearsDay.php @@ -37,7 +37,7 @@ class DayAfterNewYearsDay extends BosniaBaseTestCase implements HolidayTestCase * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date */ - public function testHoliday(int $year, DateTime $expected): void + public function testHoliday(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Bosnia/InternationalWorkersDayTest.php b/tests/Bosnia/InternationalWorkersDayTest.php index d0867d17c..84a25f8be 100644 --- a/tests/Bosnia/InternationalWorkersDayTest.php +++ b/tests/Bosnia/InternationalWorkersDayTest.php @@ -37,7 +37,7 @@ class InternationalWorkersDayTest extends BosniaBaseTestCase implements HolidayT * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date */ - public function testHoliday(int $year, DateTime $expected): void + public function testHoliday(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Bosnia/NewYearsDayTest.php b/tests/Bosnia/NewYearsDayTest.php index 8928675cb..5dc429897 100644 --- a/tests/Bosnia/NewYearsDayTest.php +++ b/tests/Bosnia/NewYearsDayTest.php @@ -37,7 +37,7 @@ class NewYearsDayTest extends BosniaBaseTestCase implements HolidayTestCase * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date */ - public function testHoliday(int $year, DateTime $expected): void + public function testHoliday(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Bosnia/OrthodoxChristmasDay.php b/tests/Bosnia/OrthodoxChristmasDay.php index 90e7fdc93..d94e12391 100644 --- a/tests/Bosnia/OrthodoxChristmasDay.php +++ b/tests/Bosnia/OrthodoxChristmasDay.php @@ -14,7 +14,6 @@ namespace Yasumi\tests\Bosnia; -use DateTime; use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -42,7 +41,7 @@ public function holidayDataProvider(): array /** * @dataProvider holidayDataProvider */ - public function testHoliday(int $year, DateTime $expected): void + public function testHoliday(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Bosnia/SecondLabourDay.php b/tests/Bosnia/SecondLabourDay.php index 3848a82c8..52bb1968d 100644 --- a/tests/Bosnia/SecondLabourDay.php +++ b/tests/Bosnia/SecondLabourDay.php @@ -37,7 +37,7 @@ class SecondLabourDay extends BosniaBaseTestCase implements HolidayTestCase * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date */ - public function testHoliday(int $year, DateTime $expected): void + public function testHoliday(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Croatia/AllSaintsDayTest.php b/tests/Croatia/AllSaintsDayTest.php index f642f0fae..5c5f61e89 100644 --- a/tests/Croatia/AllSaintsDayTest.php +++ b/tests/Croatia/AllSaintsDayTest.php @@ -37,7 +37,7 @@ class AllSaintsDayTest extends CroatiaBaseTestCase implements HolidayTestCase * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date */ - public function testHoliday(int $year, DateTime $expected): void + public function testHoliday(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Croatia/AssumptionOfMaryTest.php b/tests/Croatia/AssumptionOfMaryTest.php index 384bc7308..c3ffcd3d1 100644 --- a/tests/Croatia/AssumptionOfMaryTest.php +++ b/tests/Croatia/AssumptionOfMaryTest.php @@ -37,7 +37,7 @@ class AssumptionOfMaryTest extends CroatiaBaseTestCase implements HolidayTestCas * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date */ - public function testHoliday(int $year, DateTime $expected): void + public function testHoliday(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Croatia/ChristmasDayTest.php b/tests/Croatia/ChristmasDayTest.php index 759351789..a70edc9f1 100644 --- a/tests/Croatia/ChristmasDayTest.php +++ b/tests/Croatia/ChristmasDayTest.php @@ -37,7 +37,7 @@ class ChristmasDayTest extends CroatiaBaseTestCase implements HolidayTestCase * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date */ - public function testHoliday(int $year, DateTime $expected): void + public function testHoliday(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Croatia/EpiphanyTest.php b/tests/Croatia/EpiphanyTest.php index c3c7f3dff..90db244f4 100644 --- a/tests/Croatia/EpiphanyTest.php +++ b/tests/Croatia/EpiphanyTest.php @@ -37,7 +37,7 @@ class EpiphanyTest extends CroatiaBaseTestCase implements HolidayTestCase * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date */ - public function testHoliday(int $year, DateTime $expected): void + public function testHoliday(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Croatia/InternationalWorkersDayTest.php b/tests/Croatia/InternationalWorkersDayTest.php index bacd804c2..565b3ef37 100644 --- a/tests/Croatia/InternationalWorkersDayTest.php +++ b/tests/Croatia/InternationalWorkersDayTest.php @@ -37,7 +37,7 @@ class InternationalWorkersDayTest extends CroatiaBaseTestCase implements Holiday * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date */ - public function testHoliday(int $year, DateTime $expected): void + public function testHoliday(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Croatia/NewYearsDayTest.php b/tests/Croatia/NewYearsDayTest.php index fe136f74e..077ab71e2 100644 --- a/tests/Croatia/NewYearsDayTest.php +++ b/tests/Croatia/NewYearsDayTest.php @@ -37,7 +37,7 @@ class NewYearsDayTest extends CroatiaBaseTestCase implements HolidayTestCase * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date */ - public function testHoliday(int $year, DateTime $expected): void + public function testHoliday(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Croatia/StStephensDayTest.php b/tests/Croatia/StStephensDayTest.php index fe27bb07b..93df24861 100644 --- a/tests/Croatia/StStephensDayTest.php +++ b/tests/Croatia/StStephensDayTest.php @@ -37,7 +37,7 @@ class StStephensDayTest extends CroatiaBaseTestCase implements HolidayTestCase * @param int $year the year for which St. Stephen's Day needs to be tested * @param DateTime $expected the expected date */ - public function teststStephensDay(int $year, DateTime $expected): void + public function teststStephensDay(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/CzechRepublic/ChristmasDayTest.php b/tests/CzechRepublic/ChristmasDayTest.php index fa1ef6b41..968017c27 100644 --- a/tests/CzechRepublic/ChristmasDayTest.php +++ b/tests/CzechRepublic/ChristmasDayTest.php @@ -41,7 +41,7 @@ class ChristmasDayTest extends CzechRepublicBaseTestCase implements HolidayTestC * @param int $year the year for which Christmas Day needs to be tested * @param DateTime $expected the expected date */ - public function testChristmasDay(int $year, DateTime $expected): void + public function testChristmasDay(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/CzechRepublic/ChristmasEveTest.php b/tests/CzechRepublic/ChristmasEveTest.php index d3c0096b1..130317e36 100644 --- a/tests/CzechRepublic/ChristmasEveTest.php +++ b/tests/CzechRepublic/ChristmasEveTest.php @@ -41,7 +41,7 @@ class ChristmasEveTest extends CzechRepublicBaseTestCase implements HolidayTestC * @param int $year the year for which Christmas Eve needs to be tested * @param DateTime $expected the expected date */ - public function testChristmasDay(int $year, DateTime $expected): void + public function testChristmasDay(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/CzechRepublic/CzechStateHoodDayTest.php b/tests/CzechRepublic/CzechStateHoodDayTest.php index 3cdff1952..1e5430395 100644 --- a/tests/CzechRepublic/CzechStateHoodDayTest.php +++ b/tests/CzechRepublic/CzechStateHoodDayTest.php @@ -41,7 +41,7 @@ class CzechStateHoodDayTest extends CzechRepublicBaseTestCase implements Holiday * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date */ - public function testHoliday(int $year, DateTime $expected): void + public function testHoliday(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/CzechRepublic/IndependentCzechoslovakStateDayTest.php b/tests/CzechRepublic/IndependentCzechoslovakStateDayTest.php index baaf565b7..a38e8a6cf 100644 --- a/tests/CzechRepublic/IndependentCzechoslovakStateDayTest.php +++ b/tests/CzechRepublic/IndependentCzechoslovakStateDayTest.php @@ -37,7 +37,7 @@ class IndependentCzechoslovakStateDayTest extends CzechRepublicBaseTestCase impl * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date */ - public function testHoliday(int $year, DateTime $expected): void + public function testHoliday(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/CzechRepublic/InternationalWorkersDayTest.php b/tests/CzechRepublic/InternationalWorkersDayTest.php index 5fe46f617..e6dc56f3f 100644 --- a/tests/CzechRepublic/InternationalWorkersDayTest.php +++ b/tests/CzechRepublic/InternationalWorkersDayTest.php @@ -41,7 +41,7 @@ class InternationalWorkersDayTest extends CzechRepublicBaseTestCase implements H * @param int $year the year for which International Workers' Day needs to be tested * @param DateTime $expected the expected date */ - public function testHoliday(int $year, DateTime $expected): void + public function testHoliday(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/CzechRepublic/JanHusDayTest.php b/tests/CzechRepublic/JanHusDayTest.php index 82958228a..a3c0ede63 100644 --- a/tests/CzechRepublic/JanHusDayTest.php +++ b/tests/CzechRepublic/JanHusDayTest.php @@ -37,7 +37,7 @@ class JanHusDayTest extends CzechRepublicBaseTestCase implements HolidayTestCase * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date */ - public function testHoliday(int $year, DateTime $expected): void + public function testHoliday(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/CzechRepublic/NewYearsDayTest.php b/tests/CzechRepublic/NewYearsDayTest.php index 47f9b5529..0b47a9b48 100644 --- a/tests/CzechRepublic/NewYearsDayTest.php +++ b/tests/CzechRepublic/NewYearsDayTest.php @@ -41,7 +41,7 @@ class NewYearsDayTest extends CzechRepublicBaseTestCase implements HolidayTestCa * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date */ - public function testHoliday(int $year, DateTime $expected): void + public function testHoliday(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/CzechRepublic/RenewalOfIndependentCzechStateDayTest.php b/tests/CzechRepublic/RenewalOfIndependentCzechStateDayTest.php index 4036ffbc0..30bbddfdc 100644 --- a/tests/CzechRepublic/RenewalOfIndependentCzechStateDayTest.php +++ b/tests/CzechRepublic/RenewalOfIndependentCzechStateDayTest.php @@ -40,7 +40,7 @@ class RenewalOfIndependentCzechStateDayTest extends CzechRepublicBaseTestCase im * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date */ - public function testHoliday(int $year, DateTime $expected): void + public function testHoliday(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/CzechRepublic/SaintsCyrilAndMethodiusDayTest.php b/tests/CzechRepublic/SaintsCyrilAndMethodiusDayTest.php index 63d3df693..1452b5e51 100644 --- a/tests/CzechRepublic/SaintsCyrilAndMethodiusDayTest.php +++ b/tests/CzechRepublic/SaintsCyrilAndMethodiusDayTest.php @@ -41,7 +41,7 @@ class SaintsCyrilAndMethodiusDayTest extends CzechRepublicBaseTestCase implement * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date */ - public function testHoliday(int $year, DateTime $expected): void + public function testHoliday(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/CzechRepublic/SecondChristmasDayTest.php b/tests/CzechRepublic/SecondChristmasDayTest.php index 72ba345a8..31af974a9 100644 --- a/tests/CzechRepublic/SecondChristmasDayTest.php +++ b/tests/CzechRepublic/SecondChristmasDayTest.php @@ -41,7 +41,7 @@ class SecondChristmasDayTest extends CzechRepublicBaseTestCase implements Holida * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date */ - public function testHoliday(int $year, DateTime $expected): void + public function testHoliday(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/CzechRepublic/StruggleForFreedomAndDemocracyDayTest.php b/tests/CzechRepublic/StruggleForFreedomAndDemocracyDayTest.php index ef7a19c45..fa0976c6e 100644 --- a/tests/CzechRepublic/StruggleForFreedomAndDemocracyDayTest.php +++ b/tests/CzechRepublic/StruggleForFreedomAndDemocracyDayTest.php @@ -37,7 +37,7 @@ class StruggleForFreedomAndDemocracyDayTest extends CzechRepublicBaseTestCase im * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date */ - public function testHoliday(int $year, DateTime $expected): void + public function testHoliday(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/CzechRepublic/VictoryInEuropeDayTest.php b/tests/CzechRepublic/VictoryInEuropeDayTest.php index 8cb5f7041..6ace79694 100644 --- a/tests/CzechRepublic/VictoryInEuropeDayTest.php +++ b/tests/CzechRepublic/VictoryInEuropeDayTest.php @@ -41,7 +41,7 @@ class VictoryInEuropeDayTest extends CzechRepublicBaseTestCase implements Holida * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date */ - public function testHoliday(int $year, DateTime $expected): void + public function testHoliday(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Denmark/ChristmasDayTest.php b/tests/Denmark/ChristmasDayTest.php index 1894672fd..3bc60f908 100644 --- a/tests/Denmark/ChristmasDayTest.php +++ b/tests/Denmark/ChristmasDayTest.php @@ -37,7 +37,7 @@ class ChristmasDayTest extends DenmarkBaseTestCase implements HolidayTestCase * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date */ - public function testHoliday(int $year, DateTime $expected): void + public function testHoliday(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Denmark/ChristmasEveTest.php b/tests/Denmark/ChristmasEveTest.php index 144678d9e..87ada4ad5 100644 --- a/tests/Denmark/ChristmasEveTest.php +++ b/tests/Denmark/ChristmasEveTest.php @@ -37,7 +37,7 @@ class ChristmasEveTest extends DenmarkBaseTestCase implements HolidayTestCase * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date */ - public function testHoliday(int $year, DateTime $expected): void + public function testHoliday(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Denmark/InternationalWorkersDayTest.php b/tests/Denmark/InternationalWorkersDayTest.php index c7cf4f642..217ec8f07 100644 --- a/tests/Denmark/InternationalWorkersDayTest.php +++ b/tests/Denmark/InternationalWorkersDayTest.php @@ -37,7 +37,7 @@ class InternationalWorkersDayTest extends DenmarkBaseTestCase implements Holiday * @param int $year the year for which International Workers' Day needs to be tested * @param DateTime $expected the expected date */ - public function testInternationalWorkersDay(int $year, DateTime $expected): void + public function testInternationalWorkersDay(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Denmark/NewYearsDayTest.php b/tests/Denmark/NewYearsDayTest.php index c9ddc59c3..fdb9555f8 100644 --- a/tests/Denmark/NewYearsDayTest.php +++ b/tests/Denmark/NewYearsDayTest.php @@ -37,7 +37,7 @@ class NewYearsDayTest extends DenmarkBaseTestCase implements HolidayTestCase * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date */ - public function testHoliday(int $year, DateTime $expected): void + public function testHoliday(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Denmark/NewYearsEveTest.php b/tests/Denmark/NewYearsEveTest.php index c281ad1a1..55508ce67 100644 --- a/tests/Denmark/NewYearsEveTest.php +++ b/tests/Denmark/NewYearsEveTest.php @@ -37,7 +37,7 @@ class NewYearsEveTest extends DenmarkBaseTestCase implements HolidayTestCase * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date */ - public function testHoliday(int $year, DateTime $expected): void + public function testHoliday(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Denmark/SecondChristmasDayTest.php b/tests/Denmark/SecondChristmasDayTest.php index e7de79ba1..f6e5b4773 100644 --- a/tests/Denmark/SecondChristmasDayTest.php +++ b/tests/Denmark/SecondChristmasDayTest.php @@ -37,7 +37,7 @@ class SecondChristmasDayTest extends DenmarkBaseTestCase implements HolidayTestC * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date */ - public function testHoliday(int $year, DateTime $expected): void + public function testHoliday(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Estonia/ChristmasDayTest.php b/tests/Estonia/ChristmasDayTest.php index 0f99ddc6a..a55638381 100644 --- a/tests/Estonia/ChristmasDayTest.php +++ b/tests/Estonia/ChristmasDayTest.php @@ -15,7 +15,6 @@ namespace Yasumi\tests\Estonia; -use DateTime; use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -45,7 +44,7 @@ public function holidayDataProvider(): array /** * @dataProvider holidayDataProvider */ - public function testHoliday(int $year, DateTime $expected): void + public function testHoliday(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Estonia/ChristmasEveDayTest.php b/tests/Estonia/ChristmasEveDayTest.php index c093d8dfb..3b6fd804e 100644 --- a/tests/Estonia/ChristmasEveDayTest.php +++ b/tests/Estonia/ChristmasEveDayTest.php @@ -15,7 +15,6 @@ namespace Yasumi\tests\Estonia; -use DateTime; use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -45,7 +44,7 @@ public function holidayDataProvider(): array /** * @dataProvider holidayDataProvider */ - public function testHoliday(int $year, DateTime $expected): void + public function testHoliday(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Estonia/InternationalWorkersDayTest.php b/tests/Estonia/InternationalWorkersDayTest.php index 01eb7a3c3..a55bfc4fc 100644 --- a/tests/Estonia/InternationalWorkersDayTest.php +++ b/tests/Estonia/InternationalWorkersDayTest.php @@ -15,7 +15,6 @@ namespace Yasumi\tests\Estonia; -use DateTime; use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -45,7 +44,7 @@ public function holidayDataProvider(): array /** * @dataProvider holidayDataProvider */ - public function testHoliday(int $year, DateTime $expected): void + public function testHoliday(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Estonia/NewYearsDayTest.php b/tests/Estonia/NewYearsDayTest.php index e33ef6753..fc8222463 100644 --- a/tests/Estonia/NewYearsDayTest.php +++ b/tests/Estonia/NewYearsDayTest.php @@ -15,7 +15,6 @@ namespace Yasumi\tests\Estonia; -use DateTime; use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -45,7 +44,7 @@ public function holidayDataProvider(): array /** * @dataProvider holidayDataProvider */ - public function testHoliday(int $year, DateTime $expected): void + public function testHoliday(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Estonia/SecondChristmasDayTest.php b/tests/Estonia/SecondChristmasDayTest.php index 4846a9054..46d134394 100644 --- a/tests/Estonia/SecondChristmasDayTest.php +++ b/tests/Estonia/SecondChristmasDayTest.php @@ -15,7 +15,6 @@ namespace Yasumi\tests\Estonia; -use DateTime; use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -45,7 +44,7 @@ public function holidayDataProvider(): array /** * @dataProvider holidayDataProvider */ - public function testHoliday(int $year, DateTime $expected): void + public function testHoliday(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Estonia/StJohnsDayTest.php b/tests/Estonia/StJohnsDayTest.php index e6cfe998d..f1bd2207d 100644 --- a/tests/Estonia/StJohnsDayTest.php +++ b/tests/Estonia/StJohnsDayTest.php @@ -15,7 +15,6 @@ namespace Yasumi\tests\Estonia; -use DateTime; use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -45,7 +44,7 @@ public function holidayDataProvider(): array /** * @dataProvider holidayDataProvider */ - public function testHoliday(int $year, DateTime $expected): void + public function testHoliday(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Finland/AllSaintsDayTest.php b/tests/Finland/AllSaintsDayTest.php index 22de63d6f..3deefeaa3 100644 --- a/tests/Finland/AllSaintsDayTest.php +++ b/tests/Finland/AllSaintsDayTest.php @@ -39,7 +39,7 @@ class AllSaintsDayTest extends FinlandBaseTestCase implements HolidayTestCase * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date */ - public function testHoliday(int $year, DateTime $expected): void + public function testHoliday(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Finland/ChristmasDayTest.php b/tests/Finland/ChristmasDayTest.php index 0c1ef4281..d5142fee6 100644 --- a/tests/Finland/ChristmasDayTest.php +++ b/tests/Finland/ChristmasDayTest.php @@ -37,7 +37,7 @@ class ChristmasDayTest extends FinlandBaseTestCase implements HolidayTestCase * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date */ - public function testHoliday(int $year, DateTime $expected): void + public function testHoliday(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Finland/EpiphanyTest.php b/tests/Finland/EpiphanyTest.php index 3b00cc05b..ede0e1bc8 100644 --- a/tests/Finland/EpiphanyTest.php +++ b/tests/Finland/EpiphanyTest.php @@ -37,7 +37,7 @@ class EpiphanyTest extends FinlandBaseTestCase implements HolidayTestCase * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date */ - public function testHoliday(int $year, DateTime $expected): void + public function testHoliday(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Finland/InternationalWorkersDayTest.php b/tests/Finland/InternationalWorkersDayTest.php index 787c37829..eca26f759 100644 --- a/tests/Finland/InternationalWorkersDayTest.php +++ b/tests/Finland/InternationalWorkersDayTest.php @@ -37,7 +37,7 @@ class InternationalWorkersDayTest extends FinlandBaseTestCase implements Holiday * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date */ - public function testHoliday(int $year, DateTime $expected): void + public function testHoliday(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Finland/NewYearsDayTest.php b/tests/Finland/NewYearsDayTest.php index f39819e55..7d5da8c16 100644 --- a/tests/Finland/NewYearsDayTest.php +++ b/tests/Finland/NewYearsDayTest.php @@ -37,7 +37,7 @@ class NewYearsDayTest extends FinlandBaseTestCase implements HolidayTestCase * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date */ - public function testHoliday(int $year, DateTime $expected): void + public function testHoliday(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Finland/SecondChristmasDayTest.php b/tests/Finland/SecondChristmasDayTest.php index 34e0b5c71..f5910b22d 100644 --- a/tests/Finland/SecondChristmasDayTest.php +++ b/tests/Finland/SecondChristmasDayTest.php @@ -37,7 +37,7 @@ class SecondChristmasDayTest extends FinlandBaseTestCase implements HolidayTestC * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date */ - public function testHoliday(int $year, DateTime $expected): void + public function testHoliday(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/France/AllSaintsDayTest.php b/tests/France/AllSaintsDayTest.php index 5ed7e9df7..4801936cb 100644 --- a/tests/France/AllSaintsDayTest.php +++ b/tests/France/AllSaintsDayTest.php @@ -37,7 +37,7 @@ class AllSaintsDayTest extends FranceBaseTestCase implements HolidayTestCase * @param int $year the year for which All Saints' Day needs to be tested * @param DateTime $expected the expected date */ - public function testAllSaintsDay(int $year, DateTime $expected): void + public function testAllSaintsDay(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/France/AssumptionOfMaryTest.php b/tests/France/AssumptionOfMaryTest.php index b24757763..64bdcfcb5 100644 --- a/tests/France/AssumptionOfMaryTest.php +++ b/tests/France/AssumptionOfMaryTest.php @@ -37,7 +37,7 @@ class AssumptionOfMaryTest extends FranceBaseTestCase implements HolidayTestCase * @param int $year the year for which the day of the Assumption of Mary needs to be tested * @param DateTime $expected the expected date */ - public function testAssumptionOfMary(int $year, DateTime $expected): void + public function testAssumptionOfMary(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/France/BasRhin/stStephensDayTest.php b/tests/France/BasRhin/stStephensDayTest.php index ea894a4dc..ae97de54a 100644 --- a/tests/France/BasRhin/stStephensDayTest.php +++ b/tests/France/BasRhin/stStephensDayTest.php @@ -37,7 +37,7 @@ class stStephensDayTest extends BasRhinBaseTestCase implements HolidayTestCase * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date */ - public function testHoliday(int $year, DateTime $expected): void + public function testHoliday(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/France/ChristmasDayTest.php b/tests/France/ChristmasDayTest.php index 073605881..b23b24a16 100644 --- a/tests/France/ChristmasDayTest.php +++ b/tests/France/ChristmasDayTest.php @@ -37,7 +37,7 @@ class ChristmasDayTest extends FranceBaseTestCase implements HolidayTestCase * @param int $year the year for which Christmas Day needs to be tested * @param DateTime $expected the expected date */ - public function testChristmasDay(int $year, DateTime $expected): void + public function testChristmasDay(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/France/HautRhin/stStephensDayTest.php b/tests/France/HautRhin/stStephensDayTest.php index ea428f6f9..523cc1b04 100644 --- a/tests/France/HautRhin/stStephensDayTest.php +++ b/tests/France/HautRhin/stStephensDayTest.php @@ -37,7 +37,7 @@ class stStephensDayTest extends HautRhinBaseTestCase implements HolidayTestCase * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date */ - public function testHoliday(int $year, DateTime $expected): void + public function testHoliday(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/France/InternationalWorkersDayTest.php b/tests/France/InternationalWorkersDayTest.php index d04950b96..3d8dbb63f 100644 --- a/tests/France/InternationalWorkersDayTest.php +++ b/tests/France/InternationalWorkersDayTest.php @@ -37,7 +37,7 @@ class InternationalWorkersDayTest extends FranceBaseTestCase implements HolidayT * @param int $year the year for which International Workers' Day needs to be tested * @param DateTime $expected the expected date */ - public function testInternationalWorkersDay(int $year, DateTime $expected): void + public function testInternationalWorkersDay(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/France/Moselle/stStephensDayTest.php b/tests/France/Moselle/stStephensDayTest.php index 0ee3ec544..894b40288 100644 --- a/tests/France/Moselle/stStephensDayTest.php +++ b/tests/France/Moselle/stStephensDayTest.php @@ -37,7 +37,7 @@ class stStephensDayTest extends MoselleBaseTestCase implements HolidayTestCase * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date */ - public function testHoliday(int $year, DateTime $expected): void + public function testHoliday(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/France/NewYearsDayTest.php b/tests/France/NewYearsDayTest.php index e4fa8176f..86ebe9251 100644 --- a/tests/France/NewYearsDayTest.php +++ b/tests/France/NewYearsDayTest.php @@ -37,7 +37,7 @@ class NewYearsDayTest extends FranceBaseTestCase implements HolidayTestCase * @param int $year the year for which New Years Day needs to be tested * @param DateTime $expected the expected date */ - public function testNewYearsDay(int $year, DateTime $expected): void + public function testNewYearsDay(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Georgia/InternationalWomensDayTest.php b/tests/Georgia/InternationalWomensDayTest.php index c1a8eca7c..83d9ddf47 100644 --- a/tests/Georgia/InternationalWomensDayTest.php +++ b/tests/Georgia/InternationalWomensDayTest.php @@ -15,7 +15,6 @@ namespace Yasumi\tests\Georgia; -use DateTime; use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -30,7 +29,7 @@ class InternationalWomensDayTest extends GeorgiaBaseTestCase implements HolidayT /** * @dataProvider HolidayDataProvider */ - public function testHoliday(int $year, DateTime $expected): void + public function testHoliday(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Georgia/MtskhetobaDayTest.php b/tests/Georgia/MtskhetobaDayTest.php index a1be83ad6..80724e2d5 100644 --- a/tests/Georgia/MtskhetobaDayTest.php +++ b/tests/Georgia/MtskhetobaDayTest.php @@ -15,7 +15,6 @@ namespace Yasumi\tests\Georgia; -use DateTime; use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -30,7 +29,7 @@ class MtskhetobaDayTest extends GeorgiaBaseTestCase implements HolidayTestCase /** * @dataProvider HolidayDataProvider */ - public function testHoliday(int $year, DateTime $expected): void + public function testHoliday(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Georgia/NewYearsDayTest.php b/tests/Georgia/NewYearsDayTest.php index f76898cec..03de05be4 100644 --- a/tests/Georgia/NewYearsDayTest.php +++ b/tests/Georgia/NewYearsDayTest.php @@ -15,7 +15,6 @@ namespace Yasumi\tests\Georgia; -use DateTime; use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -30,7 +29,7 @@ class NewYearsDayTest extends GeorgiaBaseTestCase implements HolidayTestCase /** * @dataProvider HolidayDataProvider */ - public function testHoliday(int $year, DateTime $expected): void + public function testHoliday(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Georgia/OrthodoxChristmasDayTest.php b/tests/Georgia/OrthodoxChristmasDayTest.php index e6356a5bb..298514f29 100644 --- a/tests/Georgia/OrthodoxChristmasDayTest.php +++ b/tests/Georgia/OrthodoxChristmasDayTest.php @@ -15,7 +15,6 @@ namespace Yasumi\tests\Georgia; -use DateTime; use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -30,7 +29,7 @@ class OrthodoxChristmasDayTest extends GeorgiaBaseTestCase implements HolidayTes /** * @dataProvider HolidayDataProvider */ - public function testHoliday(int $year, DateTime $expected): void + public function testHoliday(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Georgia/OrthodoxEpiphanyDayTest.php b/tests/Georgia/OrthodoxEpiphanyDayTest.php index aae496458..a16b21afb 100644 --- a/tests/Georgia/OrthodoxEpiphanyDayTest.php +++ b/tests/Georgia/OrthodoxEpiphanyDayTest.php @@ -15,7 +15,6 @@ namespace Yasumi\tests\Georgia; -use DateTime; use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -30,7 +29,7 @@ class OrthodoxEpiphanyDayTest extends GeorgiaBaseTestCase implements HolidayTest /** * @dataProvider HolidayDataProvider */ - public function testHoliday(int $year, DateTime $expected): void + public function testHoliday(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Georgia/SecondNewYearDayTest.php b/tests/Georgia/SecondNewYearDayTest.php index 0c3a34100..778a41967 100644 --- a/tests/Georgia/SecondNewYearDayTest.php +++ b/tests/Georgia/SecondNewYearDayTest.php @@ -15,7 +15,6 @@ namespace Yasumi\tests\Georgia; -use DateTime; use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -30,7 +29,7 @@ class SecondNewYearDayTest extends GeorgiaBaseTestCase implements HolidayTestCas /** * @dataProvider HolidayDataProvider */ - public function testHoliday(int $year, DateTime $expected): void + public function testHoliday(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Georgia/StAndrewsDayTest.php b/tests/Georgia/StAndrewsDayTest.php index 0e6d3c404..6e4fe4fb8 100644 --- a/tests/Georgia/StAndrewsDayTest.php +++ b/tests/Georgia/StAndrewsDayTest.php @@ -15,7 +15,6 @@ namespace Yasumi\tests\Georgia; -use DateTime; use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -30,7 +29,7 @@ class StAndrewsDayTest extends GeorgiaBaseTestCase implements HolidayTestCase /** * @dataProvider HolidayDataProvider */ - public function testHoliday(int $year, DateTime $expected): void + public function testHoliday(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Georgia/StGeorgesDayTest.php b/tests/Georgia/StGeorgesDayTest.php index be8f8b8ed..5a38a1a6b 100644 --- a/tests/Georgia/StGeorgesDayTest.php +++ b/tests/Georgia/StGeorgesDayTest.php @@ -15,7 +15,6 @@ namespace Yasumi\tests\Georgia; -use DateTime; use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -30,7 +29,7 @@ class StGeorgesDayTest extends GeorgiaBaseTestCase implements HolidayTestCase /** * @dataProvider HolidayDataProvider */ - public function testHoliday(int $year, DateTime $expected): void + public function testHoliday(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Georgia/StMarysDayTest.php b/tests/Georgia/StMarysDayTest.php index 78a4b9d40..a8789ef16 100644 --- a/tests/Georgia/StMarysDayTest.php +++ b/tests/Georgia/StMarysDayTest.php @@ -15,7 +15,6 @@ namespace Yasumi\tests\Georgia; -use DateTime; use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -30,7 +29,7 @@ class StMarysDayTest extends GeorgiaBaseTestCase implements HolidayTestCase /** * @dataProvider HolidayDataProvider */ - public function testHoliday(int $year, DateTime $expected): void + public function testHoliday(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Georgia/VictoryDayTest.php b/tests/Georgia/VictoryDayTest.php index 700a8872c..58ace6026 100644 --- a/tests/Georgia/VictoryDayTest.php +++ b/tests/Georgia/VictoryDayTest.php @@ -15,7 +15,6 @@ namespace Yasumi\tests\Georgia; -use DateTime; use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -30,7 +29,7 @@ class VictoryDayTest extends GeorgiaBaseTestCase implements HolidayTestCase /** * @dataProvider HolidayDataProvider */ - public function testHoliday(int $year, DateTime $expected): void + public function testHoliday(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Germany/BadenWurttemberg/AllSaintsDayTest.php b/tests/Germany/BadenWurttemberg/AllSaintsDayTest.php index a1d7cf32b..7f5226326 100644 --- a/tests/Germany/BadenWurttemberg/AllSaintsDayTest.php +++ b/tests/Germany/BadenWurttemberg/AllSaintsDayTest.php @@ -37,7 +37,7 @@ class AllSaintsDayTest extends BadenWurttembergBaseTestCase implements HolidayTe * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date */ - public function testHoliday(int $year, DateTime $expected): void + public function testHoliday(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Germany/BadenWurttemberg/EpiphanyTest.php b/tests/Germany/BadenWurttemberg/EpiphanyTest.php index 9d0e5eaba..f91873b30 100644 --- a/tests/Germany/BadenWurttemberg/EpiphanyTest.php +++ b/tests/Germany/BadenWurttemberg/EpiphanyTest.php @@ -37,7 +37,7 @@ class EpiphanyTest extends BadenWurttembergBaseTestCase implements HolidayTestCa * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date */ - public function testHoliday(int $year, DateTime $expected): void + public function testHoliday(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Germany/Bavaria/AllSaintsDayTest.php b/tests/Germany/Bavaria/AllSaintsDayTest.php index 7bb9bef2e..9134ce1be 100644 --- a/tests/Germany/Bavaria/AllSaintsDayTest.php +++ b/tests/Germany/Bavaria/AllSaintsDayTest.php @@ -37,7 +37,7 @@ class AllSaintsDayTest extends BavariaBaseTestCase implements HolidayTestCase * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date */ - public function testHoliday(int $year, DateTime $expected): void + public function testHoliday(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Germany/Bavaria/EpiphanyTest.php b/tests/Germany/Bavaria/EpiphanyTest.php index 99d5c8a22..bdbecab0a 100644 --- a/tests/Germany/Bavaria/EpiphanyTest.php +++ b/tests/Germany/Bavaria/EpiphanyTest.php @@ -37,7 +37,7 @@ class EpiphanyTest extends BavariaBaseTestCase implements HolidayTestCase * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date */ - public function testHoliday(int $year, DateTime $expected): void + public function testHoliday(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Germany/Brandenburg/ReformationDayTest.php b/tests/Germany/Brandenburg/ReformationDayTest.php index e9f6072a2..e1458c633 100644 --- a/tests/Germany/Brandenburg/ReformationDayTest.php +++ b/tests/Germany/Brandenburg/ReformationDayTest.php @@ -43,7 +43,7 @@ class ReformationDayTest extends BrandenburgBaseTestCase implements HolidayTestC * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date */ - public function testHoliday(int $year, DateTime $expected): void + public function testHoliday(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Germany/Bremen/ReformationDayTest.php b/tests/Germany/Bremen/ReformationDayTest.php index 6ab7107cf..5a3168940 100644 --- a/tests/Germany/Bremen/ReformationDayTest.php +++ b/tests/Germany/Bremen/ReformationDayTest.php @@ -43,7 +43,7 @@ class ReformationDayTest extends BremenBaseTestCase implements HolidayTestCase * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date */ - public function testHoliday(int $year, DateTime $expected): void + public function testHoliday(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Germany/ChristmasTest.php b/tests/Germany/ChristmasTest.php index 157327f86..6ffcb2651 100644 --- a/tests/Germany/ChristmasTest.php +++ b/tests/Germany/ChristmasTest.php @@ -37,7 +37,7 @@ class ChristmasTest extends GermanyBaseTestCase implements HolidayTestCase * @param int $year the year for which Christmas Day needs to be tested * @param DateTime $expected the expected date */ - public function testChristmasDay(int $year, DateTime $expected): void + public function testChristmasDay(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Germany/Hamburg/DayOfReformationTest.php b/tests/Germany/Hamburg/DayOfReformationTest.php index 1fc660422..0dc54bd27 100644 --- a/tests/Germany/Hamburg/DayOfReformationTest.php +++ b/tests/Germany/Hamburg/DayOfReformationTest.php @@ -43,7 +43,7 @@ class DayOfReformationTest extends HamburgBaseTestCase implements HolidayTestCas * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date */ - public function testHoliday(int $year, DateTime $expected): void + public function testHoliday(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Germany/InternationalWorkersDayTest.php b/tests/Germany/InternationalWorkersDayTest.php index 02d2d9453..40523162c 100644 --- a/tests/Germany/InternationalWorkersDayTest.php +++ b/tests/Germany/InternationalWorkersDayTest.php @@ -37,7 +37,7 @@ class InternationalWorkersDayTest extends GermanyBaseTestCase implements Holiday * @param int $year the year for which International Workers' Day needs to be tested * @param DateTime $expected the expected date */ - public function testHoliday(int $year, DateTime $expected): void + public function testHoliday(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Germany/LowerSaxony/ReformationDayTest.php b/tests/Germany/LowerSaxony/ReformationDayTest.php index 9060aa3c1..9d10fffbc 100644 --- a/tests/Germany/LowerSaxony/ReformationDayTest.php +++ b/tests/Germany/LowerSaxony/ReformationDayTest.php @@ -43,7 +43,7 @@ class ReformationDayTest extends LowerSaxonyBaseTestCase implements HolidayTestC * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date */ - public function testHoliday(int $year, DateTime $expected): void + public function testHoliday(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Germany/NewYearsDayTest.php b/tests/Germany/NewYearsDayTest.php index 344af79e2..ba88d480a 100644 --- a/tests/Germany/NewYearsDayTest.php +++ b/tests/Germany/NewYearsDayTest.php @@ -37,7 +37,7 @@ class NewYearsDayTest extends GermanyBaseTestCase implements HolidayTestCase * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date */ - public function testHoliday(int $year, DateTime $expected): void + public function testHoliday(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Germany/NewYearsEveTest.php b/tests/Germany/NewYearsEveTest.php index 9ece28007..3e49390b3 100644 --- a/tests/Germany/NewYearsEveTest.php +++ b/tests/Germany/NewYearsEveTest.php @@ -37,7 +37,7 @@ class NewYearsEveTest extends GermanyBaseTestCase implements HolidayTestCase * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date */ - public function testHoliday(int $year, DateTime $expected): void + public function testHoliday(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Germany/NorthRhineWestphalia/AllSaintsDayTest.php b/tests/Germany/NorthRhineWestphalia/AllSaintsDayTest.php index 1a1b9e504..0e3f54dd1 100644 --- a/tests/Germany/NorthRhineWestphalia/AllSaintsDayTest.php +++ b/tests/Germany/NorthRhineWestphalia/AllSaintsDayTest.php @@ -37,7 +37,7 @@ class AllSaintsDayTest extends NorthRhineWestphaliaBaseTestCase implements Holid * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date */ - public function testHoliday(int $year, DateTime $expected): void + public function testHoliday(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Germany/RhinelandPalatinate/AllSaintsDayTest.php b/tests/Germany/RhinelandPalatinate/AllSaintsDayTest.php index 629da43ab..a0ced8577 100644 --- a/tests/Germany/RhinelandPalatinate/AllSaintsDayTest.php +++ b/tests/Germany/RhinelandPalatinate/AllSaintsDayTest.php @@ -37,7 +37,7 @@ class AllSaintsDayTest extends RhinelandPalatinateBaseTestCase implements Holida * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date */ - public function testHoliday(int $year, DateTime $expected): void + public function testHoliday(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Germany/Saarland/AllSaintsDayTest.php b/tests/Germany/Saarland/AllSaintsDayTest.php index b0eff6eb5..5f2d8af18 100644 --- a/tests/Germany/Saarland/AllSaintsDayTest.php +++ b/tests/Germany/Saarland/AllSaintsDayTest.php @@ -37,7 +37,7 @@ class AllSaintsDayTest extends SaarlandBaseTestCase implements HolidayTestCase * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date */ - public function testHoliday(int $year, DateTime $expected): void + public function testHoliday(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Germany/Saarland/AssumptionOfMaryTest.php b/tests/Germany/Saarland/AssumptionOfMaryTest.php index 94ff9966b..572051290 100644 --- a/tests/Germany/Saarland/AssumptionOfMaryTest.php +++ b/tests/Germany/Saarland/AssumptionOfMaryTest.php @@ -37,7 +37,7 @@ class AssumptionOfMaryTest extends SaarlandBaseTestCase implements HolidayTestCa * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date */ - public function testHoliday(int $year, DateTime $expected): void + public function testHoliday(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Germany/Saxony/ReformationDayTest.php b/tests/Germany/Saxony/ReformationDayTest.php index 34f05982d..c137d5a49 100644 --- a/tests/Germany/Saxony/ReformationDayTest.php +++ b/tests/Germany/Saxony/ReformationDayTest.php @@ -43,7 +43,7 @@ class ReformationDayTest extends SaxonyBaseTestCase implements HolidayTestCase * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date */ - public function testHoliday(int $year, DateTime $expected): void + public function testHoliday(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Germany/SaxonyAnhalt/EpiphanyTest.php b/tests/Germany/SaxonyAnhalt/EpiphanyTest.php index e6ffc3272..adab06704 100644 --- a/tests/Germany/SaxonyAnhalt/EpiphanyTest.php +++ b/tests/Germany/SaxonyAnhalt/EpiphanyTest.php @@ -37,7 +37,7 @@ class EpiphanyTest extends SaxonyAnhaltBaseTestCase implements HolidayTestCase * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date */ - public function testHoliday(int $year, DateTime $expected): void + public function testHoliday(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Germany/SaxonyAnhalt/ReformationDayTest.php b/tests/Germany/SaxonyAnhalt/ReformationDayTest.php index 0b07bfef7..f06249426 100644 --- a/tests/Germany/SaxonyAnhalt/ReformationDayTest.php +++ b/tests/Germany/SaxonyAnhalt/ReformationDayTest.php @@ -43,7 +43,7 @@ class ReformationDayTest extends SaxonyAnhaltBaseTestCase implements HolidayTest * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date */ - public function testHoliday(int $year, DateTime $expected): void + public function testHoliday(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Germany/SchleswigHolstein/ReformationDayTest.php b/tests/Germany/SchleswigHolstein/ReformationDayTest.php index b5e2cd06d..16de48d67 100644 --- a/tests/Germany/SchleswigHolstein/ReformationDayTest.php +++ b/tests/Germany/SchleswigHolstein/ReformationDayTest.php @@ -43,7 +43,7 @@ class ReformationDayTest extends SchleswigHolsteinBaseTestCase implements Holida * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date */ - public function testHoliday(int $year, DateTime $expected): void + public function testHoliday(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Germany/SecondChristmasDayTest.php b/tests/Germany/SecondChristmasDayTest.php index 4caf6f494..a7cacc5f6 100644 --- a/tests/Germany/SecondChristmasDayTest.php +++ b/tests/Germany/SecondChristmasDayTest.php @@ -37,7 +37,7 @@ class SecondChristmasDayTest extends GermanyBaseTestCase implements HolidayTestC * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date */ - public function testHoliday(int $year, DateTime $expected): void + public function testHoliday(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Germany/Thuringia/ReformationDayTest.php b/tests/Germany/Thuringia/ReformationDayTest.php index 5fb7bea47..80e017d60 100644 --- a/tests/Germany/Thuringia/ReformationDayTest.php +++ b/tests/Germany/Thuringia/ReformationDayTest.php @@ -43,7 +43,7 @@ class ReformationDayTest extends ThuringiaBaseTestCase implements HolidayTestCas * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date */ - public function testHoliday(int $year, DateTime $expected): void + public function testHoliday(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Germany/Thuringia/WorldChildrensDayTest.php b/tests/Germany/Thuringia/WorldChildrensDayTest.php index 1a835680c..d8b76dee9 100644 --- a/tests/Germany/Thuringia/WorldChildrensDayTest.php +++ b/tests/Germany/Thuringia/WorldChildrensDayTest.php @@ -43,7 +43,7 @@ class WorldChildrensDayTest extends ThuringiaBaseTestCase implements HolidayTest * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date */ - public function testHoliday(int $year, DateTime $expected): void + public function testHoliday(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Greece/AnnunciationTest.php b/tests/Greece/AnnunciationTest.php index 201e53173..cd28e0cb3 100644 --- a/tests/Greece/AnnunciationTest.php +++ b/tests/Greece/AnnunciationTest.php @@ -37,7 +37,7 @@ class AnnunciationTest extends GreeceBaseTestCase implements HolidayTestCase * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date */ - public function testHoliday(int $year, DateTime $expected): void + public function testHoliday(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Greece/AssumptionOfMaryTest.php b/tests/Greece/AssumptionOfMaryTest.php index 1ac912272..e4cf358d7 100644 --- a/tests/Greece/AssumptionOfMaryTest.php +++ b/tests/Greece/AssumptionOfMaryTest.php @@ -37,7 +37,7 @@ class AssumptionOfMaryTest extends GreeceBaseTestCase implements HolidayTestCase * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date */ - public function testHoliday(int $year, DateTime $expected): void + public function testHoliday(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Greece/ChristmasDayTest.php b/tests/Greece/ChristmasDayTest.php index 8bb6ddec5..612a2e0cc 100644 --- a/tests/Greece/ChristmasDayTest.php +++ b/tests/Greece/ChristmasDayTest.php @@ -37,7 +37,7 @@ class ChristmasDayTest extends GreeceBaseTestCase implements HolidayTestCase * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date */ - public function testHoliday(int $year, DateTime $expected): void + public function testHoliday(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Greece/EpiphanyTest.php b/tests/Greece/EpiphanyTest.php index 54b27544f..517888148 100644 --- a/tests/Greece/EpiphanyTest.php +++ b/tests/Greece/EpiphanyTest.php @@ -37,7 +37,7 @@ class EpiphanyTest extends GreeceBaseTestCase implements HolidayTestCase * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date */ - public function testHoliday(int $year, DateTime $expected): void + public function testHoliday(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Greece/InternationalWorkersDayTest.php b/tests/Greece/InternationalWorkersDayTest.php index 5544f9d54..d461dfb65 100644 --- a/tests/Greece/InternationalWorkersDayTest.php +++ b/tests/Greece/InternationalWorkersDayTest.php @@ -37,7 +37,7 @@ class InternationalWorkersDayTest extends GreeceBaseTestCase implements HolidayT * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date */ - public function testHoliday(int $year, DateTime $expected): void + public function testHoliday(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Greece/NewYearsDayTest.php b/tests/Greece/NewYearsDayTest.php index 209b69bb9..bb3a76cce 100644 --- a/tests/Greece/NewYearsDayTest.php +++ b/tests/Greece/NewYearsDayTest.php @@ -37,7 +37,7 @@ class NewYearsDayTest extends GreeceBaseTestCase implements HolidayTestCase * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date */ - public function testHoliday(int $year, DateTime $expected): void + public function testHoliday(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Greece/ThreeHolyHierarchsTest.php b/tests/Greece/ThreeHolyHierarchsTest.php index e119737a8..1174055c1 100644 --- a/tests/Greece/ThreeHolyHierarchsTest.php +++ b/tests/Greece/ThreeHolyHierarchsTest.php @@ -37,7 +37,7 @@ class ThreeHolyHierarchsTest extends GreeceBaseTestCase implements HolidayTestCa * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date */ - public function testHoliday(int $year, DateTime $expected): void + public function testHoliday(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Hungary/AllSaintsDayTest.php b/tests/Hungary/AllSaintsDayTest.php index 7fb1bce58..4093e11c8 100644 --- a/tests/Hungary/AllSaintsDayTest.php +++ b/tests/Hungary/AllSaintsDayTest.php @@ -37,7 +37,7 @@ class AllSaintsDayTest extends HungaryBaseTestCase implements HolidayTestCase * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date */ - public function testHoliday(int $year, DateTime $expected): void + public function testHoliday(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Hungary/ChristmasTest.php b/tests/Hungary/ChristmasTest.php index 0b05b7de6..8e399c930 100644 --- a/tests/Hungary/ChristmasTest.php +++ b/tests/Hungary/ChristmasTest.php @@ -37,7 +37,7 @@ class ChristmasTest extends HungaryBaseTestCase implements HolidayTestCase * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date */ - public function testHoliday(int $year, DateTime $expected): void + public function testHoliday(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Hungary/InternationalWorkersDayTest.php b/tests/Hungary/InternationalWorkersDayTest.php index dd168dff3..436868a31 100644 --- a/tests/Hungary/InternationalWorkersDayTest.php +++ b/tests/Hungary/InternationalWorkersDayTest.php @@ -37,7 +37,7 @@ class InternationalWorkersDayTest extends HungaryBaseTestCase implements Holiday * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date */ - public function testHoliday(int $year, DateTime $expected): void + public function testHoliday(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Hungary/NewYearsDayTest.php b/tests/Hungary/NewYearsDayTest.php index 4e569703c..055a14d47 100644 --- a/tests/Hungary/NewYearsDayTest.php +++ b/tests/Hungary/NewYearsDayTest.php @@ -37,7 +37,7 @@ class NewYearsDayTest extends HungaryBaseTestCase implements HolidayTestCase * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date */ - public function testHoliday(int $year, DateTime $expected): void + public function testHoliday(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Hungary/SecondChristmasDayTest.php b/tests/Hungary/SecondChristmasDayTest.php index ac2c11c22..ac0cd37ca 100644 --- a/tests/Hungary/SecondChristmasDayTest.php +++ b/tests/Hungary/SecondChristmasDayTest.php @@ -37,7 +37,7 @@ class SecondChristmasDayTest extends HungaryBaseTestCase implements HolidayTestC * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date */ - public function testHoliday(int $year, DateTime $expected): void + public function testHoliday(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Italy/AllSaintsDayTest.php b/tests/Italy/AllSaintsDayTest.php index 4442a07e2..73ae8a0c7 100644 --- a/tests/Italy/AllSaintsDayTest.php +++ b/tests/Italy/AllSaintsDayTest.php @@ -37,7 +37,7 @@ class AllSaintsDayTest extends ItalyBaseTestCase implements HolidayTestCase * @param int $year the year for which All Saints' Day needs to be tested * @param DateTime $expected the expected date */ - public function testAssumptionOfMary(int $year, DateTime $expected): void + public function testAssumptionOfMary(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Italy/AssumptionOfMaryTest.php b/tests/Italy/AssumptionOfMaryTest.php index e2143675d..a8c0fd748 100644 --- a/tests/Italy/AssumptionOfMaryTest.php +++ b/tests/Italy/AssumptionOfMaryTest.php @@ -37,7 +37,7 @@ class AssumptionOfMaryTest extends ItalyBaseTestCase implements HolidayTestCase * @param int $year the year for which the day of the Assumption of Mary needs to be tested * @param DateTime $expected the expected date */ - public function testAssumptionOfMary(int $year, DateTime $expected): void + public function testAssumptionOfMary(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Italy/ChristmasTest.php b/tests/Italy/ChristmasTest.php index 3c52d4f41..343c4de23 100644 --- a/tests/Italy/ChristmasTest.php +++ b/tests/Italy/ChristmasTest.php @@ -37,7 +37,7 @@ class ChristmasTest extends ItalyBaseTestCase implements HolidayTestCase * @param int $year the year for which Christmas Day needs to be tested * @param DateTime $expected the expected date */ - public function testChristmasDay(int $year, DateTime $expected): void + public function testChristmasDay(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Italy/EpiphanyTest.php b/tests/Italy/EpiphanyTest.php index 1810d0382..a11c21734 100644 --- a/tests/Italy/EpiphanyTest.php +++ b/tests/Italy/EpiphanyTest.php @@ -37,7 +37,7 @@ class EpiphanyTest extends ItalyBaseTestCase implements HolidayTestCase * @param int $year the year for which Epiphany needs to be tested * @param DateTime $expected the expected date */ - public function testEpiphany(int $year, DateTime $expected): void + public function testEpiphany(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Italy/ImmaculateConceptionTest.php b/tests/Italy/ImmaculateConceptionTest.php index 8f6a68e51..cc3507025 100644 --- a/tests/Italy/ImmaculateConceptionTest.php +++ b/tests/Italy/ImmaculateConceptionTest.php @@ -37,7 +37,7 @@ class ImmaculateConceptionTest extends ItalyBaseTestCase implements HolidayTestC * @param int $year the year for which the day of Immaculate Conception needs to be tested * @param DateTime $expected the expected date */ - public function testImmaculateConception(int $year, DateTime $expected): void + public function testImmaculateConception(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Italy/InternationalWorkersDayTest.php b/tests/Italy/InternationalWorkersDayTest.php index 87ccf3a45..55fbe57f0 100644 --- a/tests/Italy/InternationalWorkersDayTest.php +++ b/tests/Italy/InternationalWorkersDayTest.php @@ -37,7 +37,7 @@ class InternationalWorkersDayTest extends ItalyBaseTestCase implements HolidayTe * @param int $year the year for which International Workers' Day needs to be tested * @param DateTime $expected the expected date */ - public function testInternationalWorkersDay(int $year, DateTime $expected): void + public function testInternationalWorkersDay(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Italy/NewYearsDayTest.php b/tests/Italy/NewYearsDayTest.php index 19d15c69e..e8e3d2bf5 100644 --- a/tests/Italy/NewYearsDayTest.php +++ b/tests/Italy/NewYearsDayTest.php @@ -37,7 +37,7 @@ class NewYearsDayTest extends ItalyBaseTestCase implements HolidayTestCase * @param int $year the year for which New Years Day needs to be tested * @param DateTime $expected the expected date */ - public function testNewYearsDay(int $year, DateTime $expected): void + public function testNewYearsDay(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Italy/stStephensDayTest.php b/tests/Italy/stStephensDayTest.php index 8e5e62a23..217782c29 100644 --- a/tests/Italy/stStephensDayTest.php +++ b/tests/Italy/stStephensDayTest.php @@ -37,7 +37,7 @@ class stStephensDayTest extends ItalyBaseTestCase implements HolidayTestCase * @param int $year the year for which St. Stephen's Day needs to be tested * @param DateTime $expected the expected date */ - public function teststStephensDay(int $year, DateTime $expected): void + public function teststStephensDay(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Latvia/ChristmasDayTest.php b/tests/Latvia/ChristmasDayTest.php index b62ca87a3..3aa83584e 100644 --- a/tests/Latvia/ChristmasDayTest.php +++ b/tests/Latvia/ChristmasDayTest.php @@ -15,7 +15,6 @@ namespace Yasumi\tests\Latvia; -use DateTime; use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -45,7 +44,7 @@ public function holidayDataProvider(): array /** * @dataProvider holidayDataProvider */ - public function testHoliday(int $year, DateTime $expected): void + public function testHoliday(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Latvia/ChristmasEveDayTest.php b/tests/Latvia/ChristmasEveDayTest.php index 2c68a36e8..68778223c 100644 --- a/tests/Latvia/ChristmasEveDayTest.php +++ b/tests/Latvia/ChristmasEveDayTest.php @@ -15,7 +15,6 @@ namespace Yasumi\tests\Latvia; -use DateTime; use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -45,7 +44,7 @@ public function holidayDataProvider(): array /** * @dataProvider holidayDataProvider */ - public function testHoliday(int $year, DateTime $expected): void + public function testHoliday(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Latvia/InternationalWorkersDayTest.php b/tests/Latvia/InternationalWorkersDayTest.php index fe3d76a44..86841f009 100644 --- a/tests/Latvia/InternationalWorkersDayTest.php +++ b/tests/Latvia/InternationalWorkersDayTest.php @@ -15,7 +15,6 @@ namespace Yasumi\tests\Latvia; -use DateTime; use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -45,7 +44,7 @@ public function holidayDataProvider(): array /** * @dataProvider holidayDataProvider */ - public function testHoliday(int $year, DateTime $expected): void + public function testHoliday(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Latvia/MidsummerEveDayTest.php b/tests/Latvia/MidsummerEveDayTest.php index 8c626949d..127fac9f2 100644 --- a/tests/Latvia/MidsummerEveDayTest.php +++ b/tests/Latvia/MidsummerEveDayTest.php @@ -15,7 +15,6 @@ namespace Yasumi\tests\Latvia; -use DateTime; use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -45,7 +44,7 @@ public function holidayDataProvider(): array /** * @dataProvider holidayDataProvider */ - public function testHoliday(int $year, DateTime $expected): void + public function testHoliday(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Latvia/NewYearsDayTest.php b/tests/Latvia/NewYearsDayTest.php index 9459b8ddf..a035e2d8c 100644 --- a/tests/Latvia/NewYearsDayTest.php +++ b/tests/Latvia/NewYearsDayTest.php @@ -15,7 +15,6 @@ namespace Yasumi\tests\Latvia; -use DateTime; use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -45,7 +44,7 @@ public function holidayDataProvider(): array /** * @dataProvider holidayDataProvider */ - public function testHoliday(int $year, DateTime $expected): void + public function testHoliday(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Latvia/NewYearsEveDayTest.php b/tests/Latvia/NewYearsEveDayTest.php index eb9aa2155..855de4afd 100644 --- a/tests/Latvia/NewYearsEveDayTest.php +++ b/tests/Latvia/NewYearsEveDayTest.php @@ -15,7 +15,6 @@ namespace Yasumi\tests\Latvia; -use DateTime; use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -45,7 +44,7 @@ public function holidayDataProvider(): array /** * @dataProvider holidayDataProvider */ - public function testHoliday(int $year, DateTime $expected): void + public function testHoliday(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Latvia/SecondChristmasDayTest.php b/tests/Latvia/SecondChristmasDayTest.php index faab1bc69..cffb75249 100644 --- a/tests/Latvia/SecondChristmasDayTest.php +++ b/tests/Latvia/SecondChristmasDayTest.php @@ -15,7 +15,6 @@ namespace Yasumi\tests\Latvia; -use DateTime; use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -45,7 +44,7 @@ public function holidayDataProvider(): array /** * @dataProvider holidayDataProvider */ - public function testHoliday(int $year, DateTime $expected): void + public function testHoliday(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Latvia/StJohnsDayTest.php b/tests/Latvia/StJohnsDayTest.php index ff3772828..367145fa4 100644 --- a/tests/Latvia/StJohnsDayTest.php +++ b/tests/Latvia/StJohnsDayTest.php @@ -15,7 +15,6 @@ namespace Yasumi\tests\Latvia; -use DateTime; use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -45,7 +44,7 @@ public function holidayDataProvider(): array /** * @dataProvider holidayDataProvider */ - public function testHoliday(int $year, DateTime $expected): void + public function testHoliday(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Lithuania/AllSaintsDayTest.php b/tests/Lithuania/AllSaintsDayTest.php index bcb82da10..116f72c3f 100644 --- a/tests/Lithuania/AllSaintsDayTest.php +++ b/tests/Lithuania/AllSaintsDayTest.php @@ -15,7 +15,6 @@ namespace Yasumi\tests\Lithuania; -use DateTime; use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -45,7 +44,7 @@ public function holidayDataProvider(): array /** * @dataProvider holidayDataProvider */ - public function testHoliday(int $year, DateTime $expected): void + public function testHoliday(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Lithuania/AssumptionOfMaryDayTest.php b/tests/Lithuania/AssumptionOfMaryDayTest.php index f86e221d2..e97513224 100644 --- a/tests/Lithuania/AssumptionOfMaryDayTest.php +++ b/tests/Lithuania/AssumptionOfMaryDayTest.php @@ -15,7 +15,6 @@ namespace Yasumi\tests\Lithuania; -use DateTime; use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -45,7 +44,7 @@ public function holidayDataProvider(): array /** * @dataProvider holidayDataProvider */ - public function testHoliday(int $year, DateTime $expected): void + public function testHoliday(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Lithuania/ChristmasDayTest.php b/tests/Lithuania/ChristmasDayTest.php index 0fac9cb87..d2d5cee36 100644 --- a/tests/Lithuania/ChristmasDayTest.php +++ b/tests/Lithuania/ChristmasDayTest.php @@ -15,7 +15,6 @@ namespace Yasumi\tests\Lithuania; -use DateTime; use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -45,7 +44,7 @@ public function holidayDataProvider(): array /** * @dataProvider holidayDataProvider */ - public function testHoliday(int $year, DateTime $expected): void + public function testHoliday(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Lithuania/ChristmasEveDayTest.php b/tests/Lithuania/ChristmasEveDayTest.php index 9609ef309..48f88b828 100644 --- a/tests/Lithuania/ChristmasEveDayTest.php +++ b/tests/Lithuania/ChristmasEveDayTest.php @@ -15,7 +15,6 @@ namespace Yasumi\tests\Lithuania; -use DateTime; use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -45,7 +44,7 @@ public function holidayDataProvider(): array /** * @dataProvider holidayDataProvider */ - public function testHoliday(int $year, DateTime $expected): void + public function testHoliday(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Lithuania/InternationalWorkersDayTest.php b/tests/Lithuania/InternationalWorkersDayTest.php index c4886a033..6ce049ce7 100644 --- a/tests/Lithuania/InternationalWorkersDayTest.php +++ b/tests/Lithuania/InternationalWorkersDayTest.php @@ -15,7 +15,6 @@ namespace Yasumi\tests\Lithuania; -use DateTime; use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -45,7 +44,7 @@ public function holidayDataProvider(): array /** * @dataProvider holidayDataProvider */ - public function testHoliday(int $year, DateTime $expected): void + public function testHoliday(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Lithuania/NewYearsDayTest.php b/tests/Lithuania/NewYearsDayTest.php index d845ce473..e3163cffa 100644 --- a/tests/Lithuania/NewYearsDayTest.php +++ b/tests/Lithuania/NewYearsDayTest.php @@ -15,7 +15,6 @@ namespace Yasumi\tests\Lithuania; -use DateTime; use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -45,7 +44,7 @@ public function holidayDataProvider(): array /** * @dataProvider holidayDataProvider */ - public function testHoliday(int $year, DateTime $expected): void + public function testHoliday(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Lithuania/SecondChristmasDayTest.php b/tests/Lithuania/SecondChristmasDayTest.php index 74594d52c..6973f03de 100644 --- a/tests/Lithuania/SecondChristmasDayTest.php +++ b/tests/Lithuania/SecondChristmasDayTest.php @@ -15,7 +15,6 @@ namespace Yasumi\tests\Lithuania; -use DateTime; use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -45,7 +44,7 @@ public function holidayDataProvider(): array /** * @dataProvider holidayDataProvider */ - public function testHoliday(int $year, DateTime $expected): void + public function testHoliday(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Lithuania/StJohnsDayTest.php b/tests/Lithuania/StJohnsDayTest.php index 36dfa04df..898d65379 100644 --- a/tests/Lithuania/StJohnsDayTest.php +++ b/tests/Lithuania/StJohnsDayTest.php @@ -15,7 +15,6 @@ namespace Yasumi\tests\Lithuania; -use DateTime; use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -45,7 +44,7 @@ public function holidayDataProvider(): array /** * @dataProvider holidayDataProvider */ - public function testHoliday(int $year, DateTime $expected): void + public function testHoliday(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Luxembourg/AllSaintsDayTest.php b/tests/Luxembourg/AllSaintsDayTest.php index efa0f17fd..2183d6c44 100644 --- a/tests/Luxembourg/AllSaintsDayTest.php +++ b/tests/Luxembourg/AllSaintsDayTest.php @@ -37,7 +37,7 @@ class AllSaintsDayTest extends LuxembourgBaseTestCase implements HolidayTestCase * @param int $year the year for which All Saints' Day needs to be tested * @param DateTime $expected the expected date */ - public function testAllSaintsDay(int $year, DateTime $expected): void + public function testAllSaintsDay(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Luxembourg/AssumptionOfMaryTest.php b/tests/Luxembourg/AssumptionOfMaryTest.php index a24070707..03498d83e 100644 --- a/tests/Luxembourg/AssumptionOfMaryTest.php +++ b/tests/Luxembourg/AssumptionOfMaryTest.php @@ -37,7 +37,7 @@ class AssumptionOfMaryTest extends LuxembourgBaseTestCase implements HolidayTest * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date */ - public function testHoliday(int $year, DateTime $expected): void + public function testHoliday(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Luxembourg/ChristmasDayTest.php b/tests/Luxembourg/ChristmasDayTest.php index 7eed1a545..2c186e27c 100644 --- a/tests/Luxembourg/ChristmasDayTest.php +++ b/tests/Luxembourg/ChristmasDayTest.php @@ -37,7 +37,7 @@ class ChristmasDayTest extends LuxembourgBaseTestCase implements HolidayTestCase * @param int $year the year for which Christmas Day needs to be tested * @param DateTime $expected the expected date */ - public function testChristmasDay(int $year, DateTime $expected): void + public function testChristmasDay(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Luxembourg/InternationalWorkersDayTest.php b/tests/Luxembourg/InternationalWorkersDayTest.php index cb3cf6b6d..aafa0bcc5 100644 --- a/tests/Luxembourg/InternationalWorkersDayTest.php +++ b/tests/Luxembourg/InternationalWorkersDayTest.php @@ -37,7 +37,7 @@ class InternationalWorkersDayTest extends LuxembourgBaseTestCase implements Holi * @param int $year the year for which International Workers' Day needs to be tested * @param DateTime $expected the expected date */ - public function testInternationalWorkersDay(int $year, DateTime $expected): void + public function testInternationalWorkersDay(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Luxembourg/NationalDayTest.php b/tests/Luxembourg/NationalDayTest.php index 811514fe4..8c0261140 100644 --- a/tests/Luxembourg/NationalDayTest.php +++ b/tests/Luxembourg/NationalDayTest.php @@ -37,7 +37,7 @@ class NationalDayTest extends LuxembourgBaseTestCase implements HolidayTestCase * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date */ - public function testHoliday(int $year, DateTime $expected): void + public function testHoliday(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Luxembourg/NewYearsDayTest.php b/tests/Luxembourg/NewYearsDayTest.php index 0243ce68a..1e9f2a3ac 100644 --- a/tests/Luxembourg/NewYearsDayTest.php +++ b/tests/Luxembourg/NewYearsDayTest.php @@ -37,7 +37,7 @@ class NewYearsDayTest extends LuxembourgBaseTestCase implements HolidayTestCase * @param int $year the year for which New Years Day needs to be tested * @param DateTime $expected the expected date */ - public function testNewYearsDay(int $year, DateTime $expected): void + public function testNewYearsDay(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Luxembourg/SecondChristmasDayTest.php b/tests/Luxembourg/SecondChristmasDayTest.php index 0584b7586..a64dfb3f8 100644 --- a/tests/Luxembourg/SecondChristmasDayTest.php +++ b/tests/Luxembourg/SecondChristmasDayTest.php @@ -37,7 +37,7 @@ class SecondChristmasDayTest extends LuxembourgBaseTestCase implements HolidayTe * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date */ - public function testHoliday(int $year, DateTime $expected): void + public function testHoliday(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Norway/ChristmasDayTest.php b/tests/Norway/ChristmasDayTest.php index 0abbdfe3e..a9d7daf00 100644 --- a/tests/Norway/ChristmasDayTest.php +++ b/tests/Norway/ChristmasDayTest.php @@ -37,7 +37,7 @@ class ChristmasDayTest extends NorwayBaseTestCase implements HolidayTestCase * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date */ - public function testHoliday(int $year, DateTime $expected): void + public function testHoliday(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Norway/InternationalWorkersDayTest.php b/tests/Norway/InternationalWorkersDayTest.php index 9e00706b1..b79334b04 100644 --- a/tests/Norway/InternationalWorkersDayTest.php +++ b/tests/Norway/InternationalWorkersDayTest.php @@ -37,7 +37,7 @@ class InternationalWorkersDayTest extends NorwayBaseTestCase implements HolidayT * @param int $year the year for which International Workers' Day needs to be tested * @param DateTime $expected the expected date */ - public function testInternationalWorkersDay(int $year, DateTime $expected): void + public function testInternationalWorkersDay(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Norway/NewYearsDayTest.php b/tests/Norway/NewYearsDayTest.php index 6cefaa2c0..451096fd2 100644 --- a/tests/Norway/NewYearsDayTest.php +++ b/tests/Norway/NewYearsDayTest.php @@ -37,7 +37,7 @@ class NewYearsDayTest extends NorwayBaseTestCase implements HolidayTestCase * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date */ - public function testHoliday(int $year, DateTime $expected): void + public function testHoliday(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Norway/SecondChristmasDayTest.php b/tests/Norway/SecondChristmasDayTest.php index 64689767a..d068e09b6 100644 --- a/tests/Norway/SecondChristmasDayTest.php +++ b/tests/Norway/SecondChristmasDayTest.php @@ -37,7 +37,7 @@ class SecondChristmasDayTest extends NorwayBaseTestCase implements HolidayTestCa * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date */ - public function testHoliday(int $year, DateTime $expected): void + public function testHoliday(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Poland/AllSaintsDayTest.php b/tests/Poland/AllSaintsDayTest.php index 31e1996fe..a04330ad6 100644 --- a/tests/Poland/AllSaintsDayTest.php +++ b/tests/Poland/AllSaintsDayTest.php @@ -37,7 +37,7 @@ class AllSaintsDayTest extends PolandBaseTestCase implements HolidayTestCase * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date */ - public function testHoliday(int $year, DateTime $expected): void + public function testHoliday(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Poland/AssumptionOfMaryTest.php b/tests/Poland/AssumptionOfMaryTest.php index 2802444c1..0f42bb4c0 100644 --- a/tests/Poland/AssumptionOfMaryTest.php +++ b/tests/Poland/AssumptionOfMaryTest.php @@ -37,7 +37,7 @@ class AssumptionOfMaryTest extends PolandBaseTestCase implements HolidayTestCase * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date */ - public function testHoliday(int $year, DateTime $expected): void + public function testHoliday(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Poland/ChristmasTest.php b/tests/Poland/ChristmasTest.php index f0b72abf1..90945d0d7 100644 --- a/tests/Poland/ChristmasTest.php +++ b/tests/Poland/ChristmasTest.php @@ -37,7 +37,7 @@ class ChristmasTest extends PolandBaseTestCase implements HolidayTestCase * @param int $year the year for which Christmas Day needs to be tested * @param DateTime $expected the expected date */ - public function testChristmasDay(int $year, DateTime $expected): void + public function testChristmasDay(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Poland/EpiphanyTest.php b/tests/Poland/EpiphanyTest.php index 9c8ed6cc5..abc4c72c1 100644 --- a/tests/Poland/EpiphanyTest.php +++ b/tests/Poland/EpiphanyTest.php @@ -37,7 +37,7 @@ class EpiphanyTest extends PolandBaseTestCase implements HolidayTestCase * @param int $year the year for which Epiphany needs to be tested * @param DateTime $expected the expected date */ - public function testEpiphany(int $year, DateTime $expected): void + public function testEpiphany(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Poland/InternationalWorkersDayTest.php b/tests/Poland/InternationalWorkersDayTest.php index b0574a4a9..ba0c0c14e 100644 --- a/tests/Poland/InternationalWorkersDayTest.php +++ b/tests/Poland/InternationalWorkersDayTest.php @@ -37,7 +37,7 @@ class InternationalWorkersDayTest extends PolandBaseTestCase implements HolidayT * @param int $year the year for which International Workers' Day needs to be tested * @param DateTime $expected the expected date */ - public function testInternationalWorkersDay(int $year, DateTime $expected): void + public function testInternationalWorkersDay(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Poland/NewYearsDayTest.php b/tests/Poland/NewYearsDayTest.php index 1062802ef..d0b28620a 100644 --- a/tests/Poland/NewYearsDayTest.php +++ b/tests/Poland/NewYearsDayTest.php @@ -37,7 +37,7 @@ class NewYearsDayTest extends PolandBaseTestCase implements HolidayTestCase * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date */ - public function testHoliday(int $year, DateTime $expected): void + public function testHoliday(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Poland/SecondChristmasDayTest.php b/tests/Poland/SecondChristmasDayTest.php index 2b5d9f935..83dfcf003 100644 --- a/tests/Poland/SecondChristmasDayTest.php +++ b/tests/Poland/SecondChristmasDayTest.php @@ -37,7 +37,7 @@ class SecondChristmasDayTest extends PolandBaseTestCase implements HolidayTestCa * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date */ - public function testHoliday(int $year, DateTime $expected): void + public function testHoliday(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Portugal/AssumptionOfMaryTest.php b/tests/Portugal/AssumptionOfMaryTest.php index 667aadd4d..f51f2fe57 100644 --- a/tests/Portugal/AssumptionOfMaryTest.php +++ b/tests/Portugal/AssumptionOfMaryTest.php @@ -37,7 +37,7 @@ class AssumptionOfMaryTest extends PortugalBaseTestCase implements HolidayTestCa * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date */ - public function testHoliday(int $year, DateTime $expected): void + public function testHoliday(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Portugal/ChristmasTest.php b/tests/Portugal/ChristmasTest.php index 8545ea1c8..f6a837e51 100644 --- a/tests/Portugal/ChristmasTest.php +++ b/tests/Portugal/ChristmasTest.php @@ -37,7 +37,7 @@ class ChristmasTest extends PortugalBaseTestCase implements HolidayTestCase * @param int $year the year for which Christmas Day needs to be tested * @param DateTime $expected the expected date */ - public function testChristmasDay(int $year, DateTime $expected): void + public function testChristmasDay(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Portugal/ImmaculateConceptionTest.php b/tests/Portugal/ImmaculateConceptionTest.php index dff7a043f..a169721de 100644 --- a/tests/Portugal/ImmaculateConceptionTest.php +++ b/tests/Portugal/ImmaculateConceptionTest.php @@ -37,7 +37,7 @@ class ImmaculateConceptionTest extends PortugalBaseTestCase implements HolidayTe * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date */ - public function testHoliday(int $year, DateTime $expected): void + public function testHoliday(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Portugal/InternationalWorkersDayTest.php b/tests/Portugal/InternationalWorkersDayTest.php index 34ce61ac8..3a2c4fd75 100644 --- a/tests/Portugal/InternationalWorkersDayTest.php +++ b/tests/Portugal/InternationalWorkersDayTest.php @@ -37,7 +37,7 @@ class InternationalWorkersDayTest extends PortugalBaseTestCase implements Holida * @param int $year the year for which International Workers' Day needs to be tested * @param DateTime $expected the expected date */ - public function testInternationalWorkersDay(int $year, DateTime $expected): void + public function testInternationalWorkersDay(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Portugal/NewYearsDayTest.php b/tests/Portugal/NewYearsDayTest.php index 83219907f..9c64ede83 100644 --- a/tests/Portugal/NewYearsDayTest.php +++ b/tests/Portugal/NewYearsDayTest.php @@ -37,7 +37,7 @@ class NewYearsDayTest extends PortugalBaseTestCase implements HolidayTestCase * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date */ - public function testHoliday(int $year, DateTime $expected): void + public function testHoliday(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Romania/ChristmasDayTest.php b/tests/Romania/ChristmasDayTest.php index 884446359..ca6dea968 100644 --- a/tests/Romania/ChristmasDayTest.php +++ b/tests/Romania/ChristmasDayTest.php @@ -37,7 +37,7 @@ class ChristmasDayTest extends RomaniaBaseTestCase implements HolidayTestCase * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date */ - public function testHoliday(int $year, DateTime $expected): void + public function testHoliday(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Romania/DayAfterNewYearsDayTest.php b/tests/Romania/DayAfterNewYearsDayTest.php index d4137c9fa..85e4c14e4 100644 --- a/tests/Romania/DayAfterNewYearsDayTest.php +++ b/tests/Romania/DayAfterNewYearsDayTest.php @@ -37,7 +37,7 @@ class DayAfterNewYearsDayTest extends RomaniaBaseTestCase implements HolidayTest * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date */ - public function testHoliday(int $year, DateTime $expected): void + public function testHoliday(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Romania/InternationalWorkersDayTest.php b/tests/Romania/InternationalWorkersDayTest.php index 5f9e5f672..6db5dc108 100644 --- a/tests/Romania/InternationalWorkersDayTest.php +++ b/tests/Romania/InternationalWorkersDayTest.php @@ -37,7 +37,7 @@ class InternationalWorkersDayTest extends RomaniaBaseTestCase implements Holiday * @param int $year the year for which International Workers' Day needs to be tested * @param DateTime $expected the expected date */ - public function testInternationalWorkersDay(int $year, DateTime $expected): void + public function testInternationalWorkersDay(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Romania/NewYearsDayTest.php b/tests/Romania/NewYearsDayTest.php index 0057acbc7..7d7723dd7 100644 --- a/tests/Romania/NewYearsDayTest.php +++ b/tests/Romania/NewYearsDayTest.php @@ -37,7 +37,7 @@ class NewYearsDayTest extends RomaniaBaseTestCase implements HolidayTestCase * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date */ - public function testHoliday(int $year, DateTime $expected): void + public function testHoliday(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Romania/SecondChristmasDayTest.php b/tests/Romania/SecondChristmasDayTest.php index f7f8229fa..7f89cc0ef 100644 --- a/tests/Romania/SecondChristmasDayTest.php +++ b/tests/Romania/SecondChristmasDayTest.php @@ -37,7 +37,7 @@ class SecondChristmasDayTest extends RomaniaBaseTestCase implements HolidayTestC * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date */ - public function testHoliday(int $year, DateTime $expected): void + public function testHoliday(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Russia/InternationalWomensDayTest.php b/tests/Russia/InternationalWomensDayTest.php index 90e9554b7..6450afd76 100644 --- a/tests/Russia/InternationalWomensDayTest.php +++ b/tests/Russia/InternationalWomensDayTest.php @@ -15,7 +15,6 @@ namespace Yasumi\tests\Russia; -use DateTime; use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -45,7 +44,7 @@ public function holidayDataProvider(): array /** * @dataProvider holidayDataProvider */ - public function testHoliday(int $year, DateTime $expected): void + public function testHoliday(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Russia/NewYearHolidaysDay2Test.php b/tests/Russia/NewYearHolidaysDay2Test.php index 09e4de01b..94b2a94b0 100644 --- a/tests/Russia/NewYearHolidaysDay2Test.php +++ b/tests/Russia/NewYearHolidaysDay2Test.php @@ -15,7 +15,6 @@ namespace Yasumi\tests\Russia; -use DateTime; use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -45,7 +44,7 @@ public function holidayDataProvider(): array /** * @dataProvider holidayDataProvider */ - public function testHoliday(int $year, DateTime $expected): void + public function testHoliday(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Russia/NewYearHolidaysDay3Test.php b/tests/Russia/NewYearHolidaysDay3Test.php index cc43b19dd..40e414232 100644 --- a/tests/Russia/NewYearHolidaysDay3Test.php +++ b/tests/Russia/NewYearHolidaysDay3Test.php @@ -15,7 +15,6 @@ namespace Yasumi\tests\Russia; -use DateTime; use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -45,7 +44,7 @@ public function holidayDataProvider(): array /** * @dataProvider holidayDataProvider */ - public function testHoliday(int $year, DateTime $expected): void + public function testHoliday(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Russia/NewYearHolidaysDay4Test.php b/tests/Russia/NewYearHolidaysDay4Test.php index a8b8f3fc6..d8ed91802 100644 --- a/tests/Russia/NewYearHolidaysDay4Test.php +++ b/tests/Russia/NewYearHolidaysDay4Test.php @@ -14,7 +14,6 @@ namespace Yasumi\tests\Russia; -use DateTime; use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -44,7 +43,7 @@ public function holidayDataProvider(): array /** * @dataProvider holidayDataProvider */ - public function testHoliday(int $year, DateTime $expected): void + public function testHoliday(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Russia/NewYearHolidaysDay5Test.php b/tests/Russia/NewYearHolidaysDay5Test.php index d58e6494a..331b28071 100644 --- a/tests/Russia/NewYearHolidaysDay5Test.php +++ b/tests/Russia/NewYearHolidaysDay5Test.php @@ -15,7 +15,6 @@ namespace Yasumi\tests\Russia; -use DateTime; use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -45,7 +44,7 @@ public function holidayDataProvider(): array /** * @dataProvider holidayDataProvider */ - public function testHoliday(int $year, DateTime $expected): void + public function testHoliday(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Russia/NewYearHolidaysDay6Test.php b/tests/Russia/NewYearHolidaysDay6Test.php index 064b3fe0f..4eab9c016 100644 --- a/tests/Russia/NewYearHolidaysDay6Test.php +++ b/tests/Russia/NewYearHolidaysDay6Test.php @@ -15,7 +15,6 @@ namespace Yasumi\tests\Russia; -use DateTime; use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -45,7 +44,7 @@ public function holidayDataProvider(): array /** * @dataProvider holidayDataProvider */ - public function testHoliday(int $year, DateTime $expected): void + public function testHoliday(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Russia/NewYearHolidaysDay8Test.php b/tests/Russia/NewYearHolidaysDay8Test.php index 4d16962af..d5073cbbb 100644 --- a/tests/Russia/NewYearHolidaysDay8Test.php +++ b/tests/Russia/NewYearHolidaysDay8Test.php @@ -14,7 +14,6 @@ namespace Yasumi\tests\Russia; -use DateTime; use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -44,7 +43,7 @@ public function holidayDataProvider(): array /** * @dataProvider holidayDataProvider */ - public function testHoliday(int $year, DateTime $expected): void + public function testHoliday(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Russia/NewYearsDayTest.php b/tests/Russia/NewYearsDayTest.php index 2d987158b..d69155c9a 100644 --- a/tests/Russia/NewYearsDayTest.php +++ b/tests/Russia/NewYearsDayTest.php @@ -15,7 +15,6 @@ namespace Yasumi\tests\Russia; -use DateTime; use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -45,7 +44,7 @@ public function holidayDataProvider(): array /** * @dataProvider holidayDataProvider */ - public function testHoliday(int $year, DateTime $expected): void + public function testHoliday(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Russia/OrthodoxChristmasDayTest.php b/tests/Russia/OrthodoxChristmasDayTest.php index a6d71f1ca..81d1a5d8e 100644 --- a/tests/Russia/OrthodoxChristmasDayTest.php +++ b/tests/Russia/OrthodoxChristmasDayTest.php @@ -15,7 +15,6 @@ namespace Yasumi\tests\Russia; -use DateTime; use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -45,7 +44,7 @@ public function holidayDataProvider(): array /** * @dataProvider holidayDataProvider */ - public function testHoliday(int $year, DateTime $expected): void + public function testHoliday(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Russia/SpringAndLabourDayTest.php b/tests/Russia/SpringAndLabourDayTest.php index 3801c7393..99f330001 100644 --- a/tests/Russia/SpringAndLabourDayTest.php +++ b/tests/Russia/SpringAndLabourDayTest.php @@ -15,7 +15,6 @@ namespace Yasumi\tests\Russia; -use DateTime; use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -45,7 +44,7 @@ public function holidayDataProvider(): array /** * @dataProvider holidayDataProvider */ - public function testHoliday(int $year, DateTime $expected): void + public function testHoliday(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Russia/VictoryDayTest.php b/tests/Russia/VictoryDayTest.php index db7980ac9..4dea7d929 100644 --- a/tests/Russia/VictoryDayTest.php +++ b/tests/Russia/VictoryDayTest.php @@ -15,7 +15,6 @@ namespace Yasumi\tests\Russia; -use DateTime; use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -45,7 +44,7 @@ public function holidayDataProvider(): array /** * @dataProvider holidayDataProvider */ - public function testHoliday(int $year, DateTime $expected): void + public function testHoliday(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Slovakia/AllSaintsDayTest.php b/tests/Slovakia/AllSaintsDayTest.php index 1183fa017..26a546d3c 100644 --- a/tests/Slovakia/AllSaintsDayTest.php +++ b/tests/Slovakia/AllSaintsDayTest.php @@ -40,7 +40,7 @@ class AllSaintsDayTest extends SlovakiaBaseTestCase implements HolidayTestCase * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date */ - public function testHoliday(int $year, DateTime $expected): void + public function testHoliday(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Slovakia/ChristmasDayTest.php b/tests/Slovakia/ChristmasDayTest.php index a36d375e5..a7a04a7f8 100644 --- a/tests/Slovakia/ChristmasDayTest.php +++ b/tests/Slovakia/ChristmasDayTest.php @@ -40,7 +40,7 @@ class ChristmasDayTest extends SlovakiaBaseTestCase implements HolidayTestCase * @param int $year the year for which Christmas Day needs to be tested * @param DateTime $expected the expected date */ - public function testChristmasDay(int $year, DateTime $expected): void + public function testChristmasDay(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Slovakia/ChristmasEveTest.php b/tests/Slovakia/ChristmasEveTest.php index 94a6b9945..9ef38715f 100644 --- a/tests/Slovakia/ChristmasEveTest.php +++ b/tests/Slovakia/ChristmasEveTest.php @@ -40,7 +40,7 @@ class ChristmasEveTest extends SlovakiaBaseTestCase implements HolidayTestCase * @param int $year the year for which Christmas Day needs to be tested * @param DateTime $expected the expected date */ - public function testChristmasEve(int $year, DateTime $expected): void + public function testChristmasEve(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Slovakia/EasterMondayTest.php b/tests/Slovakia/EasterMondayTest.php index 385a52674..c615c18e0 100644 --- a/tests/Slovakia/EasterMondayTest.php +++ b/tests/Slovakia/EasterMondayTest.php @@ -41,7 +41,7 @@ class EasterMondayTest extends SlovakiaBaseTestCase implements HolidayTestCase * @param int $year the year for which Christmas Day needs to be tested * @param DateTime $expected the expected date */ - public function testHoliday(int $year, DateTime $expected): void + public function testHoliday(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Slovakia/EpiphanyTest.php b/tests/Slovakia/EpiphanyTest.php index 438759f41..024857486 100644 --- a/tests/Slovakia/EpiphanyTest.php +++ b/tests/Slovakia/EpiphanyTest.php @@ -40,7 +40,7 @@ class EpiphanyTest extends SlovakiaBaseTestCase implements HolidayTestCase * @param int $year the year for which Christmas Day needs to be tested * @param DateTime $expected the expected date */ - public function testHoliday(int $year, DateTime $expected): void + public function testHoliday(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Slovakia/GoodFridayTest.php b/tests/Slovakia/GoodFridayTest.php index 3bf9ce0f2..19b22433c 100644 --- a/tests/Slovakia/GoodFridayTest.php +++ b/tests/Slovakia/GoodFridayTest.php @@ -41,7 +41,7 @@ class GoodFridayTest extends SlovakiaBaseTestCase implements HolidayTestCase * @param int $year the year for which Christmas Day needs to be tested * @param DateTime $expected the expected date */ - public function testHoliday(int $year, DateTime $expected): void + public function testHoliday(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Slovakia/InternationalWorkersDayTest.php b/tests/Slovakia/InternationalWorkersDayTest.php index a82d1dfa6..1bdf0c46f 100644 --- a/tests/Slovakia/InternationalWorkersDayTest.php +++ b/tests/Slovakia/InternationalWorkersDayTest.php @@ -40,7 +40,7 @@ class InternationalWorkersDayTest extends SlovakiaBaseTestCase implements Holida * @param int $year the year for which Christmas Day needs to be tested * @param DateTime $expected the expected date */ - public function testHoliday(int $year, DateTime $expected): void + public function testHoliday(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Slovakia/OurLadyOfSorrowsDayTest.php b/tests/Slovakia/OurLadyOfSorrowsDayTest.php index be773eec0..fe1ad0554 100644 --- a/tests/Slovakia/OurLadyOfSorrowsDayTest.php +++ b/tests/Slovakia/OurLadyOfSorrowsDayTest.php @@ -40,7 +40,7 @@ class OurLadyOfSorrowsDayTest extends SlovakiaBaseTestCase implements HolidayTes * @param int $year the year for which Christmas Day needs to be tested * @param DateTime $expected the expected date */ - public function testHoliday(int $year, DateTime $expected): void + public function testHoliday(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Slovakia/SaintsCyrilAndMethodiusDayTest.php b/tests/Slovakia/SaintsCyrilAndMethodiusDayTest.php index fc88c8d4e..d5fd7b164 100644 --- a/tests/Slovakia/SaintsCyrilAndMethodiusDayTest.php +++ b/tests/Slovakia/SaintsCyrilAndMethodiusDayTest.php @@ -40,7 +40,7 @@ class SaintsCyrilAndMethodiusDayTest extends SlovakiaBaseTestCase implements Hol * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date */ - public function testHoliday(int $year, DateTime $expected): void + public function testHoliday(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Slovakia/SecondChristmasDayTest.php b/tests/Slovakia/SecondChristmasDayTest.php index 1abc8bce3..f758ad64c 100644 --- a/tests/Slovakia/SecondChristmasDayTest.php +++ b/tests/Slovakia/SecondChristmasDayTest.php @@ -40,7 +40,7 @@ class SecondChristmasDayTest extends SlovakiaBaseTestCase implements HolidayTest * @param int $year the year for which Christmas Day needs to be tested * @param DateTime $expected the expected date */ - public function testHoliday(int $year, DateTime $expected): void + public function testHoliday(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Slovakia/SlovakConstitutionDayTest.php b/tests/Slovakia/SlovakConstitutionDayTest.php index 08bc7c15c..b991ef989 100644 --- a/tests/Slovakia/SlovakConstitutionDayTest.php +++ b/tests/Slovakia/SlovakConstitutionDayTest.php @@ -40,7 +40,7 @@ class SlovakConstitutionDayTest extends SlovakiaBaseTestCase implements HolidayT * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date */ - public function testHoliday(int $year, DateTime $expected): void + public function testHoliday(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Slovakia/SlovakIndependeceDayTest.php b/tests/Slovakia/SlovakIndependeceDayTest.php index a81ba13ec..6a91fbddd 100644 --- a/tests/Slovakia/SlovakIndependeceDayTest.php +++ b/tests/Slovakia/SlovakIndependeceDayTest.php @@ -41,7 +41,7 @@ class SlovakIndependeceDayTest extends SlovakiaBaseTestCase implements HolidayTe * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date */ - public function testHoliday(int $year, DateTime $expected): void + public function testHoliday(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Slovakia/SlovakNationalUprisingDayTest.php b/tests/Slovakia/SlovakNationalUprisingDayTest.php index 2cef159b6..dc9e872b7 100644 --- a/tests/Slovakia/SlovakNationalUprisingDayTest.php +++ b/tests/Slovakia/SlovakNationalUprisingDayTest.php @@ -40,7 +40,7 @@ class SlovakNationalUprisingDayTest extends SlovakiaBaseTestCase implements Holi * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date */ - public function testHoliday(int $year, DateTime $expected): void + public function testHoliday(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Slovakia/StruggleForFreedomAndDemocracyDayTest.php b/tests/Slovakia/StruggleForFreedomAndDemocracyDayTest.php index 162ac5a68..f264fa3d9 100644 --- a/tests/Slovakia/StruggleForFreedomAndDemocracyDayTest.php +++ b/tests/Slovakia/StruggleForFreedomAndDemocracyDayTest.php @@ -40,7 +40,7 @@ class StruggleForFreedomAndDemocracyDayTest extends SlovakiaBaseTestCase impleme * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date */ - public function testHoliday(int $year, DateTime $expected): void + public function testHoliday(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Slovakia/VictoryInEuropeDayTest.php b/tests/Slovakia/VictoryInEuropeDayTest.php index f8947bb31..8c84b564a 100644 --- a/tests/Slovakia/VictoryInEuropeDayTest.php +++ b/tests/Slovakia/VictoryInEuropeDayTest.php @@ -40,7 +40,7 @@ class VictoryInEuropeDayTest extends SlovakiaBaseTestCase implements HolidayTest * @param int $year the year for which Christmas Day needs to be tested * @param DateTime $expected the expected date */ - public function testHoliday(int $year, DateTime $expected): void + public function testHoliday(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Spain/AllSaintsDayTest.php b/tests/Spain/AllSaintsDayTest.php index 1987ae311..7751c91f5 100644 --- a/tests/Spain/AllSaintsDayTest.php +++ b/tests/Spain/AllSaintsDayTest.php @@ -37,7 +37,7 @@ class AllSaintsDayTest extends SpainBaseTestCase implements HolidayTestCase * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date */ - public function testHoliday(int $year, DateTime $expected): void + public function testHoliday(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Spain/AssumptionOfMaryTest.php b/tests/Spain/AssumptionOfMaryTest.php index 7aca19680..cd67bf140 100644 --- a/tests/Spain/AssumptionOfMaryTest.php +++ b/tests/Spain/AssumptionOfMaryTest.php @@ -37,7 +37,7 @@ class AssumptionOfMaryTest extends SpainBaseTestCase implements HolidayTestCase * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date */ - public function testHoliday(int $year, DateTime $expected): void + public function testHoliday(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Spain/Catalonia/stJohnsDayTest.php b/tests/Spain/Catalonia/stJohnsDayTest.php index 2a37fc6b5..26109d08d 100644 --- a/tests/Spain/Catalonia/stJohnsDayTest.php +++ b/tests/Spain/Catalonia/stJohnsDayTest.php @@ -37,7 +37,7 @@ class stJohnsDayTest extends CataloniaBaseTestCase implements HolidayTestCase * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date */ - public function testHoliday(int $year, DateTime $expected): void + public function testHoliday(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Spain/ChristmasTest.php b/tests/Spain/ChristmasTest.php index 66a835b97..49f0bd685 100644 --- a/tests/Spain/ChristmasTest.php +++ b/tests/Spain/ChristmasTest.php @@ -37,7 +37,7 @@ class ChristmasTest extends SpainBaseTestCase implements HolidayTestCase * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date */ - public function testHoliday(int $year, DateTime $expected): void + public function testHoliday(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Spain/EpiphanyTest.php b/tests/Spain/EpiphanyTest.php index 35daabb4e..6598de1fb 100644 --- a/tests/Spain/EpiphanyTest.php +++ b/tests/Spain/EpiphanyTest.php @@ -37,7 +37,7 @@ class EpiphanyTest extends SpainBaseTestCase implements HolidayTestCase * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date */ - public function testHoliday(int $year, DateTime $expected): void + public function testHoliday(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Spain/ImmaculateConceptionTest.php b/tests/Spain/ImmaculateConceptionTest.php index 566157422..5c0d81a12 100644 --- a/tests/Spain/ImmaculateConceptionTest.php +++ b/tests/Spain/ImmaculateConceptionTest.php @@ -37,7 +37,7 @@ class ImmaculateConceptionTest extends SpainBaseTestCase implements HolidayTestC * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date */ - public function testHoliday(int $year, DateTime $expected): void + public function testHoliday(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Spain/InternationalWorkersDayTest.php b/tests/Spain/InternationalWorkersDayTest.php index 579992e57..4c7085a18 100644 --- a/tests/Spain/InternationalWorkersDayTest.php +++ b/tests/Spain/InternationalWorkersDayTest.php @@ -37,7 +37,7 @@ class InternationalWorkersDayTest extends SpainBaseTestCase implements HolidayTe * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date */ - public function testHoliday(int $year, DateTime $expected): void + public function testHoliday(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Spain/NewYearsDayTest.php b/tests/Spain/NewYearsDayTest.php index e56b2c2a0..8cd03eca2 100644 --- a/tests/Spain/NewYearsDayTest.php +++ b/tests/Spain/NewYearsDayTest.php @@ -37,7 +37,7 @@ class NewYearsDayTest extends SpainBaseTestCase implements HolidayTestCase * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date */ - public function testHoliday(int $year, DateTime $expected): void + public function testHoliday(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Spain/ValentinesDayTest.php b/tests/Spain/ValentinesDayTest.php index 1ad39240f..4f70db12d 100644 --- a/tests/Spain/ValentinesDayTest.php +++ b/tests/Spain/ValentinesDayTest.php @@ -37,7 +37,7 @@ class ValentinesDayTest extends SpainBaseTestCase implements HolidayTestCase * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date */ - public function testHoliday(int $year, DateTime $expected): void + public function testHoliday(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Spain/stJosephsDayTest.php b/tests/Spain/stJosephsDayTest.php index de1c563df..dba1418ac 100644 --- a/tests/Spain/stJosephsDayTest.php +++ b/tests/Spain/stJosephsDayTest.php @@ -43,7 +43,7 @@ class stJosephsDayTest extends SpainBaseTestCase implements HolidayTestCase * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date */ - public function testHoliday(int $year, DateTime $expected): void + public function testHoliday(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Sweden/AllSaintsDayTest.php b/tests/Sweden/AllSaintsDayTest.php index 29dd0866e..6ade5fa87 100644 --- a/tests/Sweden/AllSaintsDayTest.php +++ b/tests/Sweden/AllSaintsDayTest.php @@ -39,7 +39,7 @@ class AllSaintsDayTest extends SwedenBaseTestCase implements HolidayTestCase * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date */ - public function testHoliday(int $year, DateTime $expected): void + public function testHoliday(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Sweden/AllSaintsEveTest.php b/tests/Sweden/AllSaintsEveTest.php index a78d0ab93..706451d14 100644 --- a/tests/Sweden/AllSaintsEveTest.php +++ b/tests/Sweden/AllSaintsEveTest.php @@ -39,7 +39,7 @@ class AllSaintsEveTest extends SwedenBaseTestCase implements HolidayTestCase * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date */ - public function testHoliday(int $year, DateTime $expected): void + public function testHoliday(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Sweden/ChristmasDayTest.php b/tests/Sweden/ChristmasDayTest.php index 26ba55640..6e809a349 100644 --- a/tests/Sweden/ChristmasDayTest.php +++ b/tests/Sweden/ChristmasDayTest.php @@ -37,7 +37,7 @@ class ChristmasDayTest extends SwedenBaseTestCase implements HolidayTestCase * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date */ - public function testHoliday(int $year, DateTime $expected): void + public function testHoliday(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Sweden/ChristmasEveTest.php b/tests/Sweden/ChristmasEveTest.php index 45574c0df..bda99a473 100644 --- a/tests/Sweden/ChristmasEveTest.php +++ b/tests/Sweden/ChristmasEveTest.php @@ -37,7 +37,7 @@ class ChristmasEveTest extends SwedenBaseTestCase implements HolidayTestCase * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date */ - public function testHoliday(int $year, DateTime $expected): void + public function testHoliday(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Sweden/EpiphanyEveTest.php b/tests/Sweden/EpiphanyEveTest.php index 8d2ecb0b9..b5b10fdd6 100644 --- a/tests/Sweden/EpiphanyEveTest.php +++ b/tests/Sweden/EpiphanyEveTest.php @@ -37,7 +37,7 @@ class EpiphanyEveTest extends SwedenBaseTestCase implements HolidayTestCase * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date */ - public function testHoliday(int $year, DateTime $expected): void + public function testHoliday(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Sweden/EpiphanyTest.php b/tests/Sweden/EpiphanyTest.php index 6084bf01d..4432af1ad 100644 --- a/tests/Sweden/EpiphanyTest.php +++ b/tests/Sweden/EpiphanyTest.php @@ -37,7 +37,7 @@ class EpiphanyTest extends SwedenBaseTestCase implements HolidayTestCase * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date */ - public function testHoliday(int $year, DateTime $expected): void + public function testHoliday(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Sweden/InternationalWorkersDayTest.php b/tests/Sweden/InternationalWorkersDayTest.php index 0aa5eab57..f890e6e20 100644 --- a/tests/Sweden/InternationalWorkersDayTest.php +++ b/tests/Sweden/InternationalWorkersDayTest.php @@ -37,7 +37,7 @@ class InternationalWorkersDayTest extends SwedenBaseTestCase implements HolidayT * @param int $year the year for which International Workers' Day needs to be tested * @param DateTime $expected the expected date */ - public function testInternationalWorkersDay(int $year, DateTime $expected): void + public function testInternationalWorkersDay(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Sweden/NewYearsDayTest.php b/tests/Sweden/NewYearsDayTest.php index bb291757d..adec93cfa 100644 --- a/tests/Sweden/NewYearsDayTest.php +++ b/tests/Sweden/NewYearsDayTest.php @@ -37,7 +37,7 @@ class NewYearsDayTest extends SwedenBaseTestCase implements HolidayTestCase * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date */ - public function testHoliday(int $year, DateTime $expected): void + public function testHoliday(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Sweden/NewYearsEveTest.php b/tests/Sweden/NewYearsEveTest.php index 8e12c7b07..aad3ab15d 100644 --- a/tests/Sweden/NewYearsEveTest.php +++ b/tests/Sweden/NewYearsEveTest.php @@ -37,7 +37,7 @@ class NewYearsEveTest extends SwedenBaseTestCase implements HolidayTestCase * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date */ - public function testHoliday(int $year, DateTime $expected): void + public function testHoliday(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Sweden/SecondChristmasDayTest.php b/tests/Sweden/SecondChristmasDayTest.php index e66f9a523..18560239c 100644 --- a/tests/Sweden/SecondChristmasDayTest.php +++ b/tests/Sweden/SecondChristmasDayTest.php @@ -37,7 +37,7 @@ class SecondChristmasDayTest extends SwedenBaseTestCase implements HolidayTestCa * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date */ - public function testHoliday(int $year, DateTime $expected): void + public function testHoliday(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Sweden/WalpurgisEveTest.php b/tests/Sweden/WalpurgisEveTest.php index 542cab9f0..b29b4ec80 100644 --- a/tests/Sweden/WalpurgisEveTest.php +++ b/tests/Sweden/WalpurgisEveTest.php @@ -37,7 +37,7 @@ class WalpurgisEveTest extends SwedenBaseTestCase implements HolidayTestCase * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date */ - public function testHoliday(int $year, DateTime $expected): void + public function testHoliday(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Switzerland/Aargau/ChristmasDayTest.php b/tests/Switzerland/Aargau/ChristmasDayTest.php index 1536b1889..b985c8642 100644 --- a/tests/Switzerland/Aargau/ChristmasDayTest.php +++ b/tests/Switzerland/Aargau/ChristmasDayTest.php @@ -37,7 +37,7 @@ class ChristmasDayTest extends AargauBaseTestCase implements HolidayTestCase * @param int $year the year for which Christmas Day needs to be tested * @param DateTime $expected the expected date */ - public function testChristmasDay(int $year, DateTime $expected): void + public function testChristmasDay(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Switzerland/Aargau/NewYearsDayTest.php b/tests/Switzerland/Aargau/NewYearsDayTest.php index 6594e5a8f..3cb73a780 100644 --- a/tests/Switzerland/Aargau/NewYearsDayTest.php +++ b/tests/Switzerland/Aargau/NewYearsDayTest.php @@ -37,7 +37,7 @@ class NewYearsDayTest extends AargauBaseTestCase implements HolidayTestCase * @param int $year the year for which New Years Day needs to be tested * @param DateTime $expected the expected date */ - public function testNewYearsDay(int $year, DateTime $expected): void + public function testNewYearsDay(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Switzerland/AppenzellAusserrhoden/ChristmasDayTest.php b/tests/Switzerland/AppenzellAusserrhoden/ChristmasDayTest.php index 333ec69dd..d9eae80a0 100644 --- a/tests/Switzerland/AppenzellAusserrhoden/ChristmasDayTest.php +++ b/tests/Switzerland/AppenzellAusserrhoden/ChristmasDayTest.php @@ -37,7 +37,7 @@ class ChristmasDayTest extends AppenzellAusserrhodenBaseTestCase implements Holi * @param int $year the year for which Christmas Day needs to be tested * @param DateTime $expected the expected date */ - public function testChristmasDay(int $year, DateTime $expected): void + public function testChristmasDay(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Switzerland/AppenzellAusserrhoden/NewYearsDayTest.php b/tests/Switzerland/AppenzellAusserrhoden/NewYearsDayTest.php index a00afc38f..0b522d6f0 100644 --- a/tests/Switzerland/AppenzellAusserrhoden/NewYearsDayTest.php +++ b/tests/Switzerland/AppenzellAusserrhoden/NewYearsDayTest.php @@ -37,7 +37,7 @@ class NewYearsDayTest extends AppenzellAusserrhodenBaseTestCase implements Holid * @param int $year the year for which New Years Day needs to be tested * @param DateTime $expected the expected date */ - public function testNewYearsDay(int $year, DateTime $expected): void + public function testNewYearsDay(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Switzerland/AppenzellAusserrhoden/StStephensDayTest.php b/tests/Switzerland/AppenzellAusserrhoden/StStephensDayTest.php index 58ea4a56d..2e71b6fc9 100644 --- a/tests/Switzerland/AppenzellAusserrhoden/StStephensDayTest.php +++ b/tests/Switzerland/AppenzellAusserrhoden/StStephensDayTest.php @@ -37,7 +37,7 @@ class StStephensDayTest extends AppenzellAusserrhodenBaseTestCase implements Hol * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date */ - public function testHoliday(int $year, DateTime $expected): void + public function testHoliday(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Switzerland/AppenzellInnerrhoden/AllSaintsDayTest.php b/tests/Switzerland/AppenzellInnerrhoden/AllSaintsDayTest.php index 6eb3c8e56..e32fa7979 100644 --- a/tests/Switzerland/AppenzellInnerrhoden/AllSaintsDayTest.php +++ b/tests/Switzerland/AppenzellInnerrhoden/AllSaintsDayTest.php @@ -37,7 +37,7 @@ class AllSaintsDayTest extends AppenzellInnerrhodenBaseTestCase implements Holid * @param int $year the year for which All Saints' Day needs to be tested * @param DateTime $expected the expected date */ - public function testAllSaintsDay(int $year, DateTime $expected): void + public function testAllSaintsDay(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Switzerland/AppenzellInnerrhoden/AssumptionOfMaryTest.php b/tests/Switzerland/AppenzellInnerrhoden/AssumptionOfMaryTest.php index a2a954a58..681b213da 100644 --- a/tests/Switzerland/AppenzellInnerrhoden/AssumptionOfMaryTest.php +++ b/tests/Switzerland/AppenzellInnerrhoden/AssumptionOfMaryTest.php @@ -37,7 +37,7 @@ class AssumptionOfMaryTest extends AppenzellInnerrhodenBaseTestCase implements H * @param int $year the year for which the day of the Assumption of Mary needs to be tested * @param DateTime $expected the expected date */ - public function testAssumptionOfMary(int $year, DateTime $expected): void + public function testAssumptionOfMary(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Switzerland/AppenzellInnerrhoden/ChristmasDayTest.php b/tests/Switzerland/AppenzellInnerrhoden/ChristmasDayTest.php index b41d31d81..913bed476 100644 --- a/tests/Switzerland/AppenzellInnerrhoden/ChristmasDayTest.php +++ b/tests/Switzerland/AppenzellInnerrhoden/ChristmasDayTest.php @@ -37,7 +37,7 @@ class ChristmasDayTest extends AppenzellInnerrhodenBaseTestCase implements Holid * @param int $year the year for which Christmas Day needs to be tested * @param DateTime $expected the expected date */ - public function testChristmasDay(int $year, DateTime $expected): void + public function testChristmasDay(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Switzerland/AppenzellInnerrhoden/ImmaculateConceptionTest.php b/tests/Switzerland/AppenzellInnerrhoden/ImmaculateConceptionTest.php index 07f83542a..44e9d09f7 100644 --- a/tests/Switzerland/AppenzellInnerrhoden/ImmaculateConceptionTest.php +++ b/tests/Switzerland/AppenzellInnerrhoden/ImmaculateConceptionTest.php @@ -37,7 +37,7 @@ class ImmaculateConceptionTest extends AppenzellInnerrhodenBaseTestCase implemen * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date */ - public function testHoliday(int $year, DateTime $expected): void + public function testHoliday(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Switzerland/AppenzellInnerrhoden/NewYearsDayTest.php b/tests/Switzerland/AppenzellInnerrhoden/NewYearsDayTest.php index 32f9ad85a..41de674bc 100644 --- a/tests/Switzerland/AppenzellInnerrhoden/NewYearsDayTest.php +++ b/tests/Switzerland/AppenzellInnerrhoden/NewYearsDayTest.php @@ -37,7 +37,7 @@ class NewYearsDayTest extends AppenzellInnerrhodenBaseTestCase implements Holida * @param int $year the year for which New Years Day needs to be tested * @param DateTime $expected the expected date */ - public function testNewYearsDay(int $year, DateTime $expected): void + public function testNewYearsDay(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Switzerland/AppenzellInnerrhoden/StStephensDayTest.php b/tests/Switzerland/AppenzellInnerrhoden/StStephensDayTest.php index 3a804ec7d..1607571e1 100644 --- a/tests/Switzerland/AppenzellInnerrhoden/StStephensDayTest.php +++ b/tests/Switzerland/AppenzellInnerrhoden/StStephensDayTest.php @@ -37,7 +37,7 @@ class StStephensDayTest extends AppenzellInnerrhodenBaseTestCase implements Holi * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date */ - public function testHoliday(int $year, DateTime $expected): void + public function testHoliday(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Switzerland/BaselLandschaft/ChristmasDayTest.php b/tests/Switzerland/BaselLandschaft/ChristmasDayTest.php index d12d55c88..786a92ec1 100644 --- a/tests/Switzerland/BaselLandschaft/ChristmasDayTest.php +++ b/tests/Switzerland/BaselLandschaft/ChristmasDayTest.php @@ -37,7 +37,7 @@ class ChristmasDayTest extends BaselLandschaftBaseTestCase implements HolidayTes * @param int $year the year for which Christmas Day needs to be tested * @param DateTime $expected the expected date */ - public function testChristmasDay(int $year, DateTime $expected): void + public function testChristmasDay(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Switzerland/BaselLandschaft/NewYearsDayTest.php b/tests/Switzerland/BaselLandschaft/NewYearsDayTest.php index e8654a7a8..65f689433 100644 --- a/tests/Switzerland/BaselLandschaft/NewYearsDayTest.php +++ b/tests/Switzerland/BaselLandschaft/NewYearsDayTest.php @@ -37,7 +37,7 @@ class NewYearsDayTest extends BaselLandschaftBaseTestCase implements HolidayTest * @param int $year the year for which New Years Day needs to be tested * @param DateTime $expected the expected date */ - public function testNewYearsDay(int $year, DateTime $expected): void + public function testNewYearsDay(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Switzerland/BaselLandschaft/StStephensDayTest.php b/tests/Switzerland/BaselLandschaft/StStephensDayTest.php index b8c101bee..945fc24e7 100644 --- a/tests/Switzerland/BaselLandschaft/StStephensDayTest.php +++ b/tests/Switzerland/BaselLandschaft/StStephensDayTest.php @@ -37,7 +37,7 @@ class StStephensDayTest extends BaselLandschaftBaseTestCase implements HolidayTe * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date */ - public function testHoliday(int $year, DateTime $expected): void + public function testHoliday(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Switzerland/BaselStadt/ChristmasDayTest.php b/tests/Switzerland/BaselStadt/ChristmasDayTest.php index d85d0b6c0..f455d94f5 100644 --- a/tests/Switzerland/BaselStadt/ChristmasDayTest.php +++ b/tests/Switzerland/BaselStadt/ChristmasDayTest.php @@ -37,7 +37,7 @@ class ChristmasDayTest extends BaselStadtBaseTestCase implements HolidayTestCase * @param int $year the year for which Christmas Day needs to be tested * @param DateTime $expected the expected date */ - public function testChristmasDay(int $year, DateTime $expected): void + public function testChristmasDay(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Switzerland/BaselStadt/NewYearsDayTest.php b/tests/Switzerland/BaselStadt/NewYearsDayTest.php index d0c0b84a2..a658b1fdc 100644 --- a/tests/Switzerland/BaselStadt/NewYearsDayTest.php +++ b/tests/Switzerland/BaselStadt/NewYearsDayTest.php @@ -37,7 +37,7 @@ class NewYearsDayTest extends BaselStadtBaseTestCase implements HolidayTestCase * @param int $year the year for which New Years Day needs to be tested * @param DateTime $expected the expected date */ - public function testNewYearsDay(int $year, DateTime $expected): void + public function testNewYearsDay(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Switzerland/BaselStadt/StStephensDayTest.php b/tests/Switzerland/BaselStadt/StStephensDayTest.php index 535038947..8ea498c17 100644 --- a/tests/Switzerland/BaselStadt/StStephensDayTest.php +++ b/tests/Switzerland/BaselStadt/StStephensDayTest.php @@ -37,7 +37,7 @@ class StStephensDayTest extends BaselStadtBaseTestCase implements HolidayTestCas * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date */ - public function testHoliday(int $year, DateTime $expected): void + public function testHoliday(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Switzerland/Bern/ChristmasDayTest.php b/tests/Switzerland/Bern/ChristmasDayTest.php index 2e35a2770..ba5d92019 100644 --- a/tests/Switzerland/Bern/ChristmasDayTest.php +++ b/tests/Switzerland/Bern/ChristmasDayTest.php @@ -37,7 +37,7 @@ class ChristmasDayTest extends BernBaseTestCase implements HolidayTestCase * @param int $year the year for which Christmas Day needs to be tested * @param DateTime $expected the expected date */ - public function testChristmasDay(int $year, DateTime $expected): void + public function testChristmasDay(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Switzerland/Bern/NewYearsDayTest.php b/tests/Switzerland/Bern/NewYearsDayTest.php index 002a0222d..59afad745 100644 --- a/tests/Switzerland/Bern/NewYearsDayTest.php +++ b/tests/Switzerland/Bern/NewYearsDayTest.php @@ -37,7 +37,7 @@ class NewYearsDayTest extends BernBaseTestCase implements HolidayTestCase * @param int $year the year for which New Years Day needs to be tested * @param DateTime $expected the expected date */ - public function testNewYearsDay(int $year, DateTime $expected): void + public function testNewYearsDay(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Switzerland/Bern/StStephensDayTest.php b/tests/Switzerland/Bern/StStephensDayTest.php index 2df96af62..f6260d5e8 100644 --- a/tests/Switzerland/Bern/StStephensDayTest.php +++ b/tests/Switzerland/Bern/StStephensDayTest.php @@ -37,7 +37,7 @@ class StStephensDayTest extends BernBaseTestCase implements HolidayTestCase * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date */ - public function testHoliday(int $year, DateTime $expected): void + public function testHoliday(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Switzerland/Fribourg/AllSaintsDayTest.php b/tests/Switzerland/Fribourg/AllSaintsDayTest.php index f5e419d4c..9afeff288 100644 --- a/tests/Switzerland/Fribourg/AllSaintsDayTest.php +++ b/tests/Switzerland/Fribourg/AllSaintsDayTest.php @@ -37,7 +37,7 @@ class AllSaintsDayTest extends FribourgBaseTestCase implements HolidayTestCase * @param int $year the year for which All Saints' Day needs to be tested * @param DateTime $expected the expected date */ - public function testAllSaintsDay(int $year, DateTime $expected): void + public function testAllSaintsDay(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Switzerland/Fribourg/AssumptionOfMaryTest.php b/tests/Switzerland/Fribourg/AssumptionOfMaryTest.php index 53b2e23f0..315c6c5dd 100644 --- a/tests/Switzerland/Fribourg/AssumptionOfMaryTest.php +++ b/tests/Switzerland/Fribourg/AssumptionOfMaryTest.php @@ -37,7 +37,7 @@ class AssumptionOfMaryTest extends FribourgBaseTestCase implements HolidayTestCa * @param int $year the year for which the day of the Assumption of Mary needs to be tested * @param DateTime $expected the expected date */ - public function testAssumptionOfMary(int $year, DateTime $expected): void + public function testAssumptionOfMary(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Switzerland/Fribourg/ChristmasDayTest.php b/tests/Switzerland/Fribourg/ChristmasDayTest.php index 74204244d..691634ffd 100644 --- a/tests/Switzerland/Fribourg/ChristmasDayTest.php +++ b/tests/Switzerland/Fribourg/ChristmasDayTest.php @@ -37,7 +37,7 @@ class ChristmasDayTest extends FribourgBaseTestCase implements HolidayTestCase * @param int $year the year for which Christmas Day needs to be tested * @param DateTime $expected the expected date */ - public function testChristmasDay(int $year, DateTime $expected): void + public function testChristmasDay(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Switzerland/Fribourg/ImmaculateConceptionTest.php b/tests/Switzerland/Fribourg/ImmaculateConceptionTest.php index 912fcd005..174ef6b9c 100644 --- a/tests/Switzerland/Fribourg/ImmaculateConceptionTest.php +++ b/tests/Switzerland/Fribourg/ImmaculateConceptionTest.php @@ -37,7 +37,7 @@ class ImmaculateConceptionTest extends FribourgBaseTestCase implements HolidayTe * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date */ - public function testHoliday(int $year, DateTime $expected): void + public function testHoliday(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Switzerland/Fribourg/NewYearsDayTest.php b/tests/Switzerland/Fribourg/NewYearsDayTest.php index 22689c564..1c6bf751e 100644 --- a/tests/Switzerland/Fribourg/NewYearsDayTest.php +++ b/tests/Switzerland/Fribourg/NewYearsDayTest.php @@ -37,7 +37,7 @@ class NewYearsDayTest extends FribourgBaseTestCase implements HolidayTestCase * @param int $year the year for which New Years Day needs to be tested * @param DateTime $expected the expected date */ - public function testNewYearsDay(int $year, DateTime $expected): void + public function testNewYearsDay(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Switzerland/Geneva/ChristmasDayTest.php b/tests/Switzerland/Geneva/ChristmasDayTest.php index 07196b248..6e077687f 100644 --- a/tests/Switzerland/Geneva/ChristmasDayTest.php +++ b/tests/Switzerland/Geneva/ChristmasDayTest.php @@ -37,7 +37,7 @@ class ChristmasDayTest extends GenevaBaseTestCase implements HolidayTestCase * @param int $year the year for which Christmas Day needs to be tested * @param DateTime $expected the expected date */ - public function testChristmasDay(int $year, DateTime $expected): void + public function testChristmasDay(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Switzerland/Geneva/NewYearsDayTest.php b/tests/Switzerland/Geneva/NewYearsDayTest.php index 3dbca00d9..e484d6dc9 100644 --- a/tests/Switzerland/Geneva/NewYearsDayTest.php +++ b/tests/Switzerland/Geneva/NewYearsDayTest.php @@ -37,7 +37,7 @@ class NewYearsDayTest extends GenevaBaseTestCase implements HolidayTestCase * @param int $year the year for which New Years Day needs to be tested * @param DateTime $expected the expected date */ - public function testNewYearsDay(int $year, DateTime $expected): void + public function testNewYearsDay(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Switzerland/Glarus/AllSaintsDayTest.php b/tests/Switzerland/Glarus/AllSaintsDayTest.php index 44366b1f0..6055f2dca 100644 --- a/tests/Switzerland/Glarus/AllSaintsDayTest.php +++ b/tests/Switzerland/Glarus/AllSaintsDayTest.php @@ -37,7 +37,7 @@ class AllSaintsDayTest extends GlarusBaseTestCase implements HolidayTestCase * @param int $year the year for which All Saints' Day needs to be tested * @param DateTime $expected the expected date */ - public function testAllSaintsDay(int $year, DateTime $expected): void + public function testAllSaintsDay(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Switzerland/Glarus/ChristmasDayTest.php b/tests/Switzerland/Glarus/ChristmasDayTest.php index 5a50ca300..a44c1c8bd 100644 --- a/tests/Switzerland/Glarus/ChristmasDayTest.php +++ b/tests/Switzerland/Glarus/ChristmasDayTest.php @@ -37,7 +37,7 @@ class ChristmasDayTest extends GlarusBaseTestCase implements HolidayTestCase * @param int $year the year for which Christmas Day needs to be tested * @param DateTime $expected the expected date */ - public function testChristmasDay(int $year, DateTime $expected): void + public function testChristmasDay(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Switzerland/Glarus/NewYearsDayTest.php b/tests/Switzerland/Glarus/NewYearsDayTest.php index de3a2bcae..6de323d91 100644 --- a/tests/Switzerland/Glarus/NewYearsDayTest.php +++ b/tests/Switzerland/Glarus/NewYearsDayTest.php @@ -37,7 +37,7 @@ class NewYearsDayTest extends GlarusBaseTestCase implements HolidayTestCase * @param int $year the year for which New Years Day needs to be tested * @param DateTime $expected the expected date */ - public function testNewYearsDay(int $year, DateTime $expected): void + public function testNewYearsDay(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Switzerland/Glarus/StStephensDayTest.php b/tests/Switzerland/Glarus/StStephensDayTest.php index 4a3d77caa..413349877 100644 --- a/tests/Switzerland/Glarus/StStephensDayTest.php +++ b/tests/Switzerland/Glarus/StStephensDayTest.php @@ -37,7 +37,7 @@ class StStephensDayTest extends GlarusBaseTestCase implements HolidayTestCase * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date */ - public function testHoliday(int $year, DateTime $expected): void + public function testHoliday(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Switzerland/Grisons/ChristmasDayTest.php b/tests/Switzerland/Grisons/ChristmasDayTest.php index a929b45b2..2f03b5894 100644 --- a/tests/Switzerland/Grisons/ChristmasDayTest.php +++ b/tests/Switzerland/Grisons/ChristmasDayTest.php @@ -37,7 +37,7 @@ class ChristmasDayTest extends GrisonsBaseTestCase implements HolidayTestCase * @param int $year the year for which Christmas Day needs to be tested * @param DateTime $expected the expected date */ - public function testChristmasDay(int $year, DateTime $expected): void + public function testChristmasDay(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Switzerland/Grisons/NewYearsDayTest.php b/tests/Switzerland/Grisons/NewYearsDayTest.php index 3019b3eca..eecb9310b 100644 --- a/tests/Switzerland/Grisons/NewYearsDayTest.php +++ b/tests/Switzerland/Grisons/NewYearsDayTest.php @@ -37,7 +37,7 @@ class NewYearsDayTest extends GrisonsBaseTestCase implements HolidayTestCase * @param int $year the year for which New Years Day needs to be tested * @param DateTime $expected the expected date */ - public function testNewYearsDay(int $year, DateTime $expected): void + public function testNewYearsDay(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Switzerland/Grisons/StStephensDayTest.php b/tests/Switzerland/Grisons/StStephensDayTest.php index d9fde825f..e2dddfaf8 100644 --- a/tests/Switzerland/Grisons/StStephensDayTest.php +++ b/tests/Switzerland/Grisons/StStephensDayTest.php @@ -37,7 +37,7 @@ class StStephensDayTest extends GrisonsBaseTestCase implements HolidayTestCase * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date */ - public function testHoliday(int $year, DateTime $expected): void + public function testHoliday(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Switzerland/Jura/AllSaintsDayTest.php b/tests/Switzerland/Jura/AllSaintsDayTest.php index 68a19acae..8c678ff60 100644 --- a/tests/Switzerland/Jura/AllSaintsDayTest.php +++ b/tests/Switzerland/Jura/AllSaintsDayTest.php @@ -37,7 +37,7 @@ class AllSaintsDayTest extends JuraBaseTestCase implements HolidayTestCase * @param int $year the year for which All Saints' Day needs to be tested * @param DateTime $expected the expected date */ - public function testAllSaintsDay(int $year, DateTime $expected): void + public function testAllSaintsDay(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Switzerland/Jura/AssumptionOfMaryTest.php b/tests/Switzerland/Jura/AssumptionOfMaryTest.php index f5edcb659..efe5931e2 100644 --- a/tests/Switzerland/Jura/AssumptionOfMaryTest.php +++ b/tests/Switzerland/Jura/AssumptionOfMaryTest.php @@ -37,7 +37,7 @@ class AssumptionOfMaryTest extends JuraBaseTestCase implements HolidayTestCase * @param int $year the year for which the day of the Assumption of Mary needs to be tested * @param DateTime $expected the expected date */ - public function testAssumptionOfMary(int $year, DateTime $expected): void + public function testAssumptionOfMary(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Switzerland/Jura/ChristmasDayTest.php b/tests/Switzerland/Jura/ChristmasDayTest.php index 4e98c93f9..f81de2386 100644 --- a/tests/Switzerland/Jura/ChristmasDayTest.php +++ b/tests/Switzerland/Jura/ChristmasDayTest.php @@ -37,7 +37,7 @@ class ChristmasDayTest extends JuraBaseTestCase implements HolidayTestCase * @param int $year the year for which Christmas Day needs to be tested * @param DateTime $expected the expected date */ - public function testChristmasDay(int $year, DateTime $expected): void + public function testChristmasDay(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Switzerland/Jura/NewYearsDayTest.php b/tests/Switzerland/Jura/NewYearsDayTest.php index 3f55f1f12..3d22a0acb 100644 --- a/tests/Switzerland/Jura/NewYearsDayTest.php +++ b/tests/Switzerland/Jura/NewYearsDayTest.php @@ -37,7 +37,7 @@ class NewYearsDayTest extends JuraBaseTestCase implements HolidayTestCase * @param int $year the year for which New Years Day needs to be tested * @param DateTime $expected the expected date */ - public function testNewYearsDay(int $year, DateTime $expected): void + public function testNewYearsDay(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Switzerland/Lucerne/AllSaintsDayTest.php b/tests/Switzerland/Lucerne/AllSaintsDayTest.php index f01b394c1..d3f23ade5 100644 --- a/tests/Switzerland/Lucerne/AllSaintsDayTest.php +++ b/tests/Switzerland/Lucerne/AllSaintsDayTest.php @@ -37,7 +37,7 @@ class AllSaintsDayTest extends LucerneBaseTestCase implements HolidayTestCase * @param int $year the year for which All Saints' Day needs to be tested * @param DateTime $expected the expected date */ - public function testAllSaintsDay(int $year, DateTime $expected): void + public function testAllSaintsDay(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Switzerland/Lucerne/AssumptionOfMaryTest.php b/tests/Switzerland/Lucerne/AssumptionOfMaryTest.php index 8aca43508..b94a4ed2f 100644 --- a/tests/Switzerland/Lucerne/AssumptionOfMaryTest.php +++ b/tests/Switzerland/Lucerne/AssumptionOfMaryTest.php @@ -37,7 +37,7 @@ class AssumptionOfMaryTest extends LucerneBaseTestCase implements HolidayTestCas * @param int $year the year for which the day of the Assumption of Mary needs to be tested * @param DateTime $expected the expected date */ - public function testAssumptionOfMary(int $year, DateTime $expected): void + public function testAssumptionOfMary(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Switzerland/Lucerne/ChristmasDayTest.php b/tests/Switzerland/Lucerne/ChristmasDayTest.php index df4857e02..8bef33955 100644 --- a/tests/Switzerland/Lucerne/ChristmasDayTest.php +++ b/tests/Switzerland/Lucerne/ChristmasDayTest.php @@ -37,7 +37,7 @@ class ChristmasDayTest extends LucerneBaseTestCase implements HolidayTestCase * @param int $year the year for which Christmas Day needs to be tested * @param DateTime $expected the expected date */ - public function testChristmasDay(int $year, DateTime $expected): void + public function testChristmasDay(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Switzerland/Lucerne/ImmaculateConceptionTest.php b/tests/Switzerland/Lucerne/ImmaculateConceptionTest.php index f8cde7ea2..6f17a77e8 100644 --- a/tests/Switzerland/Lucerne/ImmaculateConceptionTest.php +++ b/tests/Switzerland/Lucerne/ImmaculateConceptionTest.php @@ -37,7 +37,7 @@ class ImmaculateConceptionTest extends LucerneBaseTestCase implements HolidayTes * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date */ - public function testHoliday(int $year, DateTime $expected): void + public function testHoliday(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Switzerland/Lucerne/NewYearsDayTest.php b/tests/Switzerland/Lucerne/NewYearsDayTest.php index be40eac19..55e8fd612 100644 --- a/tests/Switzerland/Lucerne/NewYearsDayTest.php +++ b/tests/Switzerland/Lucerne/NewYearsDayTest.php @@ -37,7 +37,7 @@ class NewYearsDayTest extends LucerneBaseTestCase implements HolidayTestCase * @param int $year the year for which New Years Day needs to be tested * @param DateTime $expected the expected date */ - public function testNewYearsDay(int $year, DateTime $expected): void + public function testNewYearsDay(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Switzerland/Lucerne/StStephensDayTest.php b/tests/Switzerland/Lucerne/StStephensDayTest.php index 25dc1a879..a331953a0 100644 --- a/tests/Switzerland/Lucerne/StStephensDayTest.php +++ b/tests/Switzerland/Lucerne/StStephensDayTest.php @@ -37,7 +37,7 @@ class StStephensDayTest extends LucerneBaseTestCase implements HolidayTestCase * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date */ - public function testHoliday(int $year, DateTime $expected): void + public function testHoliday(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Switzerland/Neuchatel/ChristmasDayTest.php b/tests/Switzerland/Neuchatel/ChristmasDayTest.php index 758fe9a3e..8af9393d3 100644 --- a/tests/Switzerland/Neuchatel/ChristmasDayTest.php +++ b/tests/Switzerland/Neuchatel/ChristmasDayTest.php @@ -37,7 +37,7 @@ class ChristmasDayTest extends NeuchatelBaseTestCase implements HolidayTestCase * @param int $year the year for which Christmas Day needs to be tested * @param DateTime $expected the expected date */ - public function testChristmasDay(int $year, DateTime $expected): void + public function testChristmasDay(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Switzerland/Neuchatel/NewYearsDayTest.php b/tests/Switzerland/Neuchatel/NewYearsDayTest.php index c67696996..c68dc509d 100644 --- a/tests/Switzerland/Neuchatel/NewYearsDayTest.php +++ b/tests/Switzerland/Neuchatel/NewYearsDayTest.php @@ -37,7 +37,7 @@ class NewYearsDayTest extends NeuchatelBaseTestCase implements HolidayTestCase * @param int $year the year for which New Years Day needs to be tested * @param DateTime $expected the expected date */ - public function testNewYearsDay(int $year, DateTime $expected): void + public function testNewYearsDay(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Switzerland/Nidwalden/AllSaintsDayTest.php b/tests/Switzerland/Nidwalden/AllSaintsDayTest.php index cee7976bc..edc49a934 100644 --- a/tests/Switzerland/Nidwalden/AllSaintsDayTest.php +++ b/tests/Switzerland/Nidwalden/AllSaintsDayTest.php @@ -37,7 +37,7 @@ class AllSaintsDayTest extends NidwaldenBaseTestCase implements HolidayTestCase * @param int $year the year for which All Saints' Day needs to be tested * @param DateTime $expected the expected date */ - public function testAllSaintsDay(int $year, DateTime $expected): void + public function testAllSaintsDay(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Switzerland/Nidwalden/AssumptionOfMaryTest.php b/tests/Switzerland/Nidwalden/AssumptionOfMaryTest.php index dc3994b96..ec3950fb7 100644 --- a/tests/Switzerland/Nidwalden/AssumptionOfMaryTest.php +++ b/tests/Switzerland/Nidwalden/AssumptionOfMaryTest.php @@ -37,7 +37,7 @@ class AssumptionOfMaryTest extends NidwaldenBaseTestCase implements HolidayTestC * @param int $year the year for which the day of the Assumption of Mary needs to be tested * @param DateTime $expected the expected date */ - public function testAssumptionOfMary(int $year, DateTime $expected): void + public function testAssumptionOfMary(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Switzerland/Nidwalden/ChristmasDayTest.php b/tests/Switzerland/Nidwalden/ChristmasDayTest.php index 22a844dfd..af9b9cca8 100644 --- a/tests/Switzerland/Nidwalden/ChristmasDayTest.php +++ b/tests/Switzerland/Nidwalden/ChristmasDayTest.php @@ -37,7 +37,7 @@ class ChristmasDayTest extends NidwaldenBaseTestCase implements HolidayTestCase * @param int $year the year for which Christmas Day needs to be tested * @param DateTime $expected the expected date */ - public function testChristmasDay(int $year, DateTime $expected): void + public function testChristmasDay(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Switzerland/Nidwalden/ImmaculateConceptionTest.php b/tests/Switzerland/Nidwalden/ImmaculateConceptionTest.php index 330107f09..7fe1ca63c 100644 --- a/tests/Switzerland/Nidwalden/ImmaculateConceptionTest.php +++ b/tests/Switzerland/Nidwalden/ImmaculateConceptionTest.php @@ -37,7 +37,7 @@ class ImmaculateConceptionTest extends NidwaldenBaseTestCase implements HolidayT * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date */ - public function testHoliday(int $year, DateTime $expected): void + public function testHoliday(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Switzerland/Nidwalden/NewYearsDayTest.php b/tests/Switzerland/Nidwalden/NewYearsDayTest.php index 36ac14093..4eab06436 100644 --- a/tests/Switzerland/Nidwalden/NewYearsDayTest.php +++ b/tests/Switzerland/Nidwalden/NewYearsDayTest.php @@ -37,7 +37,7 @@ class NewYearsDayTest extends NidwaldenBaseTestCase implements HolidayTestCase * @param int $year the year for which New Years Day needs to be tested * @param DateTime $expected the expected date */ - public function testNewYearsDay(int $year, DateTime $expected): void + public function testNewYearsDay(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Switzerland/Nidwalden/StJosephDayTest.php b/tests/Switzerland/Nidwalden/StJosephDayTest.php index 369b1d107..5eebb4a9f 100644 --- a/tests/Switzerland/Nidwalden/StJosephDayTest.php +++ b/tests/Switzerland/Nidwalden/StJosephDayTest.php @@ -40,7 +40,7 @@ class StJosephDayTest extends NidwaldenBaseTestCase implements HolidayTestCase * @param int $year the year for which St. Joseph's Day needs to be tested * @param DateTime $expected the expected date */ - public function testStJosephDay(int $year, DateTime $expected): void + public function testStJosephDay(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Switzerland/Nidwalden/StStephensDayTest.php b/tests/Switzerland/Nidwalden/StStephensDayTest.php index baba85bd9..1aef71904 100644 --- a/tests/Switzerland/Nidwalden/StStephensDayTest.php +++ b/tests/Switzerland/Nidwalden/StStephensDayTest.php @@ -37,7 +37,7 @@ class StStephensDayTest extends NidwaldenBaseTestCase implements HolidayTestCase * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date */ - public function testHoliday(int $year, DateTime $expected): void + public function testHoliday(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Switzerland/Obwalden/AllSaintsDayTest.php b/tests/Switzerland/Obwalden/AllSaintsDayTest.php index e18040ef1..63cb9a530 100644 --- a/tests/Switzerland/Obwalden/AllSaintsDayTest.php +++ b/tests/Switzerland/Obwalden/AllSaintsDayTest.php @@ -37,7 +37,7 @@ class AllSaintsDayTest extends ObwaldenBaseTestCase implements HolidayTestCase * @param int $year the year for which All Saints' Day needs to be tested * @param DateTime $expected the expected date */ - public function testAllSaintsDay(int $year, DateTime $expected): void + public function testAllSaintsDay(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Switzerland/Obwalden/AssumptionOfMaryTest.php b/tests/Switzerland/Obwalden/AssumptionOfMaryTest.php index 960714b49..149a8e4f2 100644 --- a/tests/Switzerland/Obwalden/AssumptionOfMaryTest.php +++ b/tests/Switzerland/Obwalden/AssumptionOfMaryTest.php @@ -37,7 +37,7 @@ class AssumptionOfMaryTest extends ObwaldenBaseTestCase implements HolidayTestCa * @param int $year the year for which the day of the Assumption of Mary needs to be tested * @param DateTime $expected the expected date */ - public function testAssumptionOfMary(int $year, DateTime $expected): void + public function testAssumptionOfMary(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Switzerland/Obwalden/ChristmasDayTest.php b/tests/Switzerland/Obwalden/ChristmasDayTest.php index 9099e56a9..55dacca6d 100644 --- a/tests/Switzerland/Obwalden/ChristmasDayTest.php +++ b/tests/Switzerland/Obwalden/ChristmasDayTest.php @@ -37,7 +37,7 @@ class ChristmasDayTest extends ObwaldenBaseTestCase implements HolidayTestCase * @param int $year the year for which Christmas Day needs to be tested * @param DateTime $expected the expected date */ - public function testChristmasDay(int $year, DateTime $expected): void + public function testChristmasDay(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Switzerland/Obwalden/ImmaculateConceptionTest.php b/tests/Switzerland/Obwalden/ImmaculateConceptionTest.php index 5873e0341..64e551ada 100644 --- a/tests/Switzerland/Obwalden/ImmaculateConceptionTest.php +++ b/tests/Switzerland/Obwalden/ImmaculateConceptionTest.php @@ -37,7 +37,7 @@ class ImmaculateConceptionTest extends ObwaldenBaseTestCase implements HolidayTe * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date */ - public function testHoliday(int $year, DateTime $expected): void + public function testHoliday(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Switzerland/Obwalden/NewYearsDayTest.php b/tests/Switzerland/Obwalden/NewYearsDayTest.php index 8fa8b48d5..940d834db 100644 --- a/tests/Switzerland/Obwalden/NewYearsDayTest.php +++ b/tests/Switzerland/Obwalden/NewYearsDayTest.php @@ -37,7 +37,7 @@ class NewYearsDayTest extends ObwaldenBaseTestCase implements HolidayTestCase * @param int $year the year for which New Years Day needs to be tested * @param DateTime $expected the expected date */ - public function testNewYearsDay(int $year, DateTime $expected): void + public function testNewYearsDay(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Switzerland/Obwalden/StStephensDayTest.php b/tests/Switzerland/Obwalden/StStephensDayTest.php index 8b84213aa..3f8259ed2 100644 --- a/tests/Switzerland/Obwalden/StStephensDayTest.php +++ b/tests/Switzerland/Obwalden/StStephensDayTest.php @@ -37,7 +37,7 @@ class StStephensDayTest extends ObwaldenBaseTestCase implements HolidayTestCase * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date */ - public function testHoliday(int $year, DateTime $expected): void + public function testHoliday(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Switzerland/Schaffhausen/ChristmasDayTest.php b/tests/Switzerland/Schaffhausen/ChristmasDayTest.php index a91ffb037..39e6cb156 100644 --- a/tests/Switzerland/Schaffhausen/ChristmasDayTest.php +++ b/tests/Switzerland/Schaffhausen/ChristmasDayTest.php @@ -37,7 +37,7 @@ class ChristmasDayTest extends SchaffhausenBaseTestCase implements HolidayTestCa * @param int $year the year for which Christmas Day needs to be tested * @param DateTime $expected the expected date */ - public function testChristmasDay(int $year, DateTime $expected): void + public function testChristmasDay(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Switzerland/Schaffhausen/NewYearsDayTest.php b/tests/Switzerland/Schaffhausen/NewYearsDayTest.php index ac2828ae5..a252328ce 100644 --- a/tests/Switzerland/Schaffhausen/NewYearsDayTest.php +++ b/tests/Switzerland/Schaffhausen/NewYearsDayTest.php @@ -37,7 +37,7 @@ class NewYearsDayTest extends SchaffhausenBaseTestCase implements HolidayTestCas * @param int $year the year for which New Years Day needs to be tested * @param DateTime $expected the expected date */ - public function testNewYearsDay(int $year, DateTime $expected): void + public function testNewYearsDay(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Switzerland/Schaffhausen/StStephensDayTest.php b/tests/Switzerland/Schaffhausen/StStephensDayTest.php index 85564d411..bc6130368 100644 --- a/tests/Switzerland/Schaffhausen/StStephensDayTest.php +++ b/tests/Switzerland/Schaffhausen/StStephensDayTest.php @@ -37,7 +37,7 @@ class StStephensDayTest extends SchaffhausenBaseTestCase implements HolidayTestC * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date */ - public function testHoliday(int $year, DateTime $expected): void + public function testHoliday(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Switzerland/Schwyz/AllSaintsDayTest.php b/tests/Switzerland/Schwyz/AllSaintsDayTest.php index b2fb1177d..a6b4225f4 100644 --- a/tests/Switzerland/Schwyz/AllSaintsDayTest.php +++ b/tests/Switzerland/Schwyz/AllSaintsDayTest.php @@ -37,7 +37,7 @@ class AllSaintsDayTest extends SchwyzBaseTestCase implements HolidayTestCase * @param int $year the year for which All Saints' Day needs to be tested * @param DateTime $expected the expected date */ - public function testAllSaintsDay(int $year, DateTime $expected): void + public function testAllSaintsDay(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Switzerland/Schwyz/AssumptionOfMaryTest.php b/tests/Switzerland/Schwyz/AssumptionOfMaryTest.php index 1d232dfd5..9e54a3d39 100644 --- a/tests/Switzerland/Schwyz/AssumptionOfMaryTest.php +++ b/tests/Switzerland/Schwyz/AssumptionOfMaryTest.php @@ -37,7 +37,7 @@ class AssumptionOfMaryTest extends SchwyzBaseTestCase implements HolidayTestCase * @param int $year the year for which the day of the Assumption of Mary needs to be tested * @param DateTime $expected the expected date */ - public function testAssumptionOfMary(int $year, DateTime $expected): void + public function testAssumptionOfMary(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Switzerland/Schwyz/ChristmasDayTest.php b/tests/Switzerland/Schwyz/ChristmasDayTest.php index 340e73c47..fd3e33d95 100644 --- a/tests/Switzerland/Schwyz/ChristmasDayTest.php +++ b/tests/Switzerland/Schwyz/ChristmasDayTest.php @@ -37,7 +37,7 @@ class ChristmasDayTest extends SchwyzBaseTestCase implements HolidayTestCase * @param int $year the year for which Christmas Day needs to be tested * @param DateTime $expected the expected date */ - public function testChristmasDay(int $year, DateTime $expected): void + public function testChristmasDay(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Switzerland/Schwyz/EpiphanyTest.php b/tests/Switzerland/Schwyz/EpiphanyTest.php index 811415bd0..c47c66b30 100644 --- a/tests/Switzerland/Schwyz/EpiphanyTest.php +++ b/tests/Switzerland/Schwyz/EpiphanyTest.php @@ -37,7 +37,7 @@ class EpiphanyTest extends SchwyzBaseTestCase implements HolidayTestCase * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date */ - public function testHoliday(int $year, DateTime $expected): void + public function testHoliday(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Switzerland/Schwyz/ImmaculateConceptionTest.php b/tests/Switzerland/Schwyz/ImmaculateConceptionTest.php index 2f273071d..9c040d94b 100644 --- a/tests/Switzerland/Schwyz/ImmaculateConceptionTest.php +++ b/tests/Switzerland/Schwyz/ImmaculateConceptionTest.php @@ -37,7 +37,7 @@ class ImmaculateConceptionTest extends SchwyzBaseTestCase implements HolidayTest * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date */ - public function testHoliday(int $year, DateTime $expected): void + public function testHoliday(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Switzerland/Schwyz/NewYearsDayTest.php b/tests/Switzerland/Schwyz/NewYearsDayTest.php index dbd6b5495..471689821 100644 --- a/tests/Switzerland/Schwyz/NewYearsDayTest.php +++ b/tests/Switzerland/Schwyz/NewYearsDayTest.php @@ -37,7 +37,7 @@ class NewYearsDayTest extends SchwyzBaseTestCase implements HolidayTestCase * @param int $year the year for which New Years Day needs to be tested * @param DateTime $expected the expected date */ - public function testNewYearsDay(int $year, DateTime $expected): void + public function testNewYearsDay(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Switzerland/Schwyz/StJosephDayTest.php b/tests/Switzerland/Schwyz/StJosephDayTest.php index 785686258..81227c2fa 100644 --- a/tests/Switzerland/Schwyz/StJosephDayTest.php +++ b/tests/Switzerland/Schwyz/StJosephDayTest.php @@ -40,7 +40,7 @@ class StJosephDayTest extends SchwyzBaseTestCase implements HolidayTestCase * @param int $year the year for which St. Joseph's Day needs to be tested * @param DateTime $expected the expected date */ - public function testStJosephDay(int $year, DateTime $expected): void + public function testStJosephDay(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Switzerland/Schwyz/StStephensDayTest.php b/tests/Switzerland/Schwyz/StStephensDayTest.php index 8408f56a1..a84c13c76 100644 --- a/tests/Switzerland/Schwyz/StStephensDayTest.php +++ b/tests/Switzerland/Schwyz/StStephensDayTest.php @@ -37,7 +37,7 @@ class StStephensDayTest extends SchwyzBaseTestCase implements HolidayTestCase * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date */ - public function testHoliday(int $year, DateTime $expected): void + public function testHoliday(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Switzerland/Solothurn/ChristmasDayTest.php b/tests/Switzerland/Solothurn/ChristmasDayTest.php index b0b2b00da..4918274fe 100644 --- a/tests/Switzerland/Solothurn/ChristmasDayTest.php +++ b/tests/Switzerland/Solothurn/ChristmasDayTest.php @@ -37,7 +37,7 @@ class ChristmasDayTest extends SolothurnBaseTestCase implements HolidayTestCase * @param int $year the year for which Christmas Day needs to be tested * @param DateTime $expected the expected date */ - public function testChristmasDay(int $year, DateTime $expected): void + public function testChristmasDay(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Switzerland/Solothurn/NewYearsDayTest.php b/tests/Switzerland/Solothurn/NewYearsDayTest.php index 35541d83f..3989e7799 100644 --- a/tests/Switzerland/Solothurn/NewYearsDayTest.php +++ b/tests/Switzerland/Solothurn/NewYearsDayTest.php @@ -37,7 +37,7 @@ class NewYearsDayTest extends SolothurnBaseTestCase implements HolidayTestCase * @param int $year the year for which New Years Day needs to be tested * @param DateTime $expected the expected date */ - public function testNewYearsDay(int $year, DateTime $expected): void + public function testNewYearsDay(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Switzerland/StGallen/AllSaintsDayTest.php b/tests/Switzerland/StGallen/AllSaintsDayTest.php index 60989720d..2c6f3a22b 100644 --- a/tests/Switzerland/StGallen/AllSaintsDayTest.php +++ b/tests/Switzerland/StGallen/AllSaintsDayTest.php @@ -37,7 +37,7 @@ class AllSaintsDayTest extends StGallenBaseTestCase implements HolidayTestCase * @param int $year the year for which All Saints' Day needs to be tested * @param DateTime $expected the expected date */ - public function testAllSaintsDay(int $year, DateTime $expected): void + public function testAllSaintsDay(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Switzerland/StGallen/ChristmasDayTest.php b/tests/Switzerland/StGallen/ChristmasDayTest.php index 3bd4e13ef..30f10cdb9 100644 --- a/tests/Switzerland/StGallen/ChristmasDayTest.php +++ b/tests/Switzerland/StGallen/ChristmasDayTest.php @@ -37,7 +37,7 @@ class ChristmasDayTest extends StGallenBaseTestCase implements HolidayTestCase * @param int $year the year for which Christmas Day needs to be tested * @param DateTime $expected the expected date */ - public function testChristmasDay(int $year, DateTime $expected): void + public function testChristmasDay(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Switzerland/StGallen/NewYearsDayTest.php b/tests/Switzerland/StGallen/NewYearsDayTest.php index bae4e38f5..4f204d789 100644 --- a/tests/Switzerland/StGallen/NewYearsDayTest.php +++ b/tests/Switzerland/StGallen/NewYearsDayTest.php @@ -37,7 +37,7 @@ class NewYearsDayTest extends StGallenBaseTestCase implements HolidayTestCase * @param int $year the year for which New Years Day needs to be tested * @param DateTime $expected the expected date */ - public function testNewYearsDay(int $year, DateTime $expected): void + public function testNewYearsDay(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Switzerland/StGallen/StStephensDayTest.php b/tests/Switzerland/StGallen/StStephensDayTest.php index 89c3cced1..e8486d5aa 100644 --- a/tests/Switzerland/StGallen/StStephensDayTest.php +++ b/tests/Switzerland/StGallen/StStephensDayTest.php @@ -37,7 +37,7 @@ class StStephensDayTest extends StGallenBaseTestCase implements HolidayTestCase * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date */ - public function testHoliday(int $year, DateTime $expected): void + public function testHoliday(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Switzerland/Thurgau/ChristmasDayTest.php b/tests/Switzerland/Thurgau/ChristmasDayTest.php index e30bb9d22..b8cab2e5a 100644 --- a/tests/Switzerland/Thurgau/ChristmasDayTest.php +++ b/tests/Switzerland/Thurgau/ChristmasDayTest.php @@ -37,7 +37,7 @@ class ChristmasDayTest extends ThurgauBaseTestCase implements HolidayTestCase * @param int $year the year for which Christmas Day needs to be tested * @param DateTime $expected the expected date */ - public function testChristmasDay(int $year, DateTime $expected): void + public function testChristmasDay(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Switzerland/Thurgau/NewYearsDayTest.php b/tests/Switzerland/Thurgau/NewYearsDayTest.php index 7aaf432ed..bf9879738 100644 --- a/tests/Switzerland/Thurgau/NewYearsDayTest.php +++ b/tests/Switzerland/Thurgau/NewYearsDayTest.php @@ -37,7 +37,7 @@ class NewYearsDayTest extends ThurgauBaseTestCase implements HolidayTestCase * @param int $year the year for which New Years Day needs to be tested * @param DateTime $expected the expected date */ - public function testNewYearsDay(int $year, DateTime $expected): void + public function testNewYearsDay(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Switzerland/Thurgau/StStephensDayTest.php b/tests/Switzerland/Thurgau/StStephensDayTest.php index 8b8a72fc9..287baed36 100644 --- a/tests/Switzerland/Thurgau/StStephensDayTest.php +++ b/tests/Switzerland/Thurgau/StStephensDayTest.php @@ -37,7 +37,7 @@ class StStephensDayTest extends ThurgauBaseTestCase implements HolidayTestCase * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date */ - public function testHoliday(int $year, DateTime $expected): void + public function testHoliday(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Switzerland/Ticino/AllSaintsDayTest.php b/tests/Switzerland/Ticino/AllSaintsDayTest.php index 91a7196c1..87977ce56 100644 --- a/tests/Switzerland/Ticino/AllSaintsDayTest.php +++ b/tests/Switzerland/Ticino/AllSaintsDayTest.php @@ -37,7 +37,7 @@ class AllSaintsDayTest extends TicinoBaseTestCase implements HolidayTestCase * @param int $year the year for which All Saints' Day needs to be tested * @param DateTime $expected the expected date */ - public function testAllSaintsDay(int $year, DateTime $expected): void + public function testAllSaintsDay(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Switzerland/Ticino/AssumptionOfMaryTest.php b/tests/Switzerland/Ticino/AssumptionOfMaryTest.php index eedf1144c..81dacfa4e 100644 --- a/tests/Switzerland/Ticino/AssumptionOfMaryTest.php +++ b/tests/Switzerland/Ticino/AssumptionOfMaryTest.php @@ -37,7 +37,7 @@ class AssumptionOfMaryTest extends TicinoBaseTestCase implements HolidayTestCase * @param int $year the year for which the day of the Assumption of Mary needs to be tested * @param DateTime $expected the expected date */ - public function testAssumptionOfMary(int $year, DateTime $expected): void + public function testAssumptionOfMary(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Switzerland/Ticino/ChristmasDayTest.php b/tests/Switzerland/Ticino/ChristmasDayTest.php index 2e7fb5ed2..ef945d09f 100644 --- a/tests/Switzerland/Ticino/ChristmasDayTest.php +++ b/tests/Switzerland/Ticino/ChristmasDayTest.php @@ -37,7 +37,7 @@ class ChristmasDayTest extends TicinoBaseTestCase implements HolidayTestCase * @param int $year the year for which Christmas Day needs to be tested * @param DateTime $expected the expected date */ - public function testChristmasDay(int $year, DateTime $expected): void + public function testChristmasDay(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Switzerland/Ticino/EpiphanyTest.php b/tests/Switzerland/Ticino/EpiphanyTest.php index 9b5e69922..3dcd58409 100644 --- a/tests/Switzerland/Ticino/EpiphanyTest.php +++ b/tests/Switzerland/Ticino/EpiphanyTest.php @@ -37,7 +37,7 @@ class EpiphanyTest extends TicinoBaseTestCase implements HolidayTestCase * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date */ - public function testHoliday(int $year, DateTime $expected): void + public function testHoliday(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Switzerland/Ticino/ImmaculateConceptionTest.php b/tests/Switzerland/Ticino/ImmaculateConceptionTest.php index d707c44cb..ad2cf3483 100644 --- a/tests/Switzerland/Ticino/ImmaculateConceptionTest.php +++ b/tests/Switzerland/Ticino/ImmaculateConceptionTest.php @@ -37,7 +37,7 @@ class ImmaculateConceptionTest extends TicinoBaseTestCase implements HolidayTest * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date */ - public function testHoliday(int $year, DateTime $expected): void + public function testHoliday(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Switzerland/Ticino/NewYearsDayTest.php b/tests/Switzerland/Ticino/NewYearsDayTest.php index 345238ce4..427b76e03 100644 --- a/tests/Switzerland/Ticino/NewYearsDayTest.php +++ b/tests/Switzerland/Ticino/NewYearsDayTest.php @@ -37,7 +37,7 @@ class NewYearsDayTest extends TicinoBaseTestCase implements HolidayTestCase * @param int $year the year for which New Years Day needs to be tested * @param DateTime $expected the expected date */ - public function testNewYearsDay(int $year, DateTime $expected): void + public function testNewYearsDay(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Switzerland/Ticino/StJosephDayTest.php b/tests/Switzerland/Ticino/StJosephDayTest.php index 0ec537701..437637c4f 100644 --- a/tests/Switzerland/Ticino/StJosephDayTest.php +++ b/tests/Switzerland/Ticino/StJosephDayTest.php @@ -40,7 +40,7 @@ class StJosephDayTest extends TicinoBaseTestCase implements HolidayTestCase * @param int $year the year for which St. Joseph's Day needs to be tested * @param DateTime $expected the expected date */ - public function testStJosephDay(int $year, DateTime $expected): void + public function testStJosephDay(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Switzerland/Ticino/StPeterPaulTest.php b/tests/Switzerland/Ticino/StPeterPaulTest.php index df595e7b1..3bbf91e79 100644 --- a/tests/Switzerland/Ticino/StPeterPaulTest.php +++ b/tests/Switzerland/Ticino/StPeterPaulTest.php @@ -37,7 +37,7 @@ class StPeterPaulTest extends TicinoBaseTestCase implements HolidayTestCase * @param int $year the year for which Feast of Saints Peter and Paul needs to be tested * @param DateTime $expected the expected date */ - public function testStPeterPaul(int $year, DateTime $expected): void + public function testStPeterPaul(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Switzerland/Ticino/StStephensDayTest.php b/tests/Switzerland/Ticino/StStephensDayTest.php index 532286355..cf0a1208e 100644 --- a/tests/Switzerland/Ticino/StStephensDayTest.php +++ b/tests/Switzerland/Ticino/StStephensDayTest.php @@ -37,7 +37,7 @@ class StStephensDayTest extends TicinoBaseTestCase implements HolidayTestCase * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date */ - public function testHoliday(int $year, DateTime $expected): void + public function testHoliday(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Switzerland/Uri/AllSaintsDayTest.php b/tests/Switzerland/Uri/AllSaintsDayTest.php index a8372cad6..d16b2f67a 100644 --- a/tests/Switzerland/Uri/AllSaintsDayTest.php +++ b/tests/Switzerland/Uri/AllSaintsDayTest.php @@ -37,7 +37,7 @@ class AllSaintsDayTest extends UriBaseTestCase implements HolidayTestCase * @param int $year the year for which All Saints' Day needs to be tested * @param DateTime $expected the expected date */ - public function testAllSaintsDay(int $year, DateTime $expected): void + public function testAllSaintsDay(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Switzerland/Uri/AssumptionOfMaryTest.php b/tests/Switzerland/Uri/AssumptionOfMaryTest.php index 9db214b1b..48c6c6d1d 100644 --- a/tests/Switzerland/Uri/AssumptionOfMaryTest.php +++ b/tests/Switzerland/Uri/AssumptionOfMaryTest.php @@ -37,7 +37,7 @@ class AssumptionOfMaryTest extends UriBaseTestCase implements HolidayTestCase * @param int $year the year for which the day of the Assumption of Mary needs to be tested * @param DateTime $expected the expected date */ - public function testAssumptionOfMary(int $year, DateTime $expected): void + public function testAssumptionOfMary(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Switzerland/Uri/ChristmasDayTest.php b/tests/Switzerland/Uri/ChristmasDayTest.php index c90737c2a..8620d24c6 100644 --- a/tests/Switzerland/Uri/ChristmasDayTest.php +++ b/tests/Switzerland/Uri/ChristmasDayTest.php @@ -37,7 +37,7 @@ class ChristmasDayTest extends UriBaseTestCase implements HolidayTestCase * @param int $year the year for which Christmas Day needs to be tested * @param DateTime $expected the expected date */ - public function testChristmasDay(int $year, DateTime $expected): void + public function testChristmasDay(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Switzerland/Uri/EpiphanyTest.php b/tests/Switzerland/Uri/EpiphanyTest.php index 88e3d3d24..281897933 100644 --- a/tests/Switzerland/Uri/EpiphanyTest.php +++ b/tests/Switzerland/Uri/EpiphanyTest.php @@ -37,7 +37,7 @@ class EpiphanyTest extends UriBaseTestCase implements HolidayTestCase * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date */ - public function testHoliday(int $year, DateTime $expected): void + public function testHoliday(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Switzerland/Uri/ImmaculateConceptionTest.php b/tests/Switzerland/Uri/ImmaculateConceptionTest.php index 1a1ce7351..8f4a6997a 100644 --- a/tests/Switzerland/Uri/ImmaculateConceptionTest.php +++ b/tests/Switzerland/Uri/ImmaculateConceptionTest.php @@ -37,7 +37,7 @@ class ImmaculateConceptionTest extends UriBaseTestCase implements HolidayTestCas * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date */ - public function testHoliday(int $year, DateTime $expected): void + public function testHoliday(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Switzerland/Uri/NewYearsDayTest.php b/tests/Switzerland/Uri/NewYearsDayTest.php index 1d241eeee..c4025783a 100644 --- a/tests/Switzerland/Uri/NewYearsDayTest.php +++ b/tests/Switzerland/Uri/NewYearsDayTest.php @@ -37,7 +37,7 @@ class NewYearsDayTest extends UriBaseTestCase implements HolidayTestCase * @param int $year the year for which New Years Day needs to be tested * @param DateTime $expected the expected date */ - public function testNewYearsDay(int $year, DateTime $expected): void + public function testNewYearsDay(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Switzerland/Uri/StJosephDayTest.php b/tests/Switzerland/Uri/StJosephDayTest.php index ef1247487..9709013ee 100644 --- a/tests/Switzerland/Uri/StJosephDayTest.php +++ b/tests/Switzerland/Uri/StJosephDayTest.php @@ -40,7 +40,7 @@ class StJosephDayTest extends UriBaseTestCase implements HolidayTestCase * @param int $year the year for which St. Joseph's Day needs to be tested * @param DateTime $expected the expected date */ - public function testStJosephDay(int $year, DateTime $expected): void + public function testStJosephDay(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Switzerland/Uri/StStephensDayTest.php b/tests/Switzerland/Uri/StStephensDayTest.php index 4e52a9858..5383310c3 100644 --- a/tests/Switzerland/Uri/StStephensDayTest.php +++ b/tests/Switzerland/Uri/StStephensDayTest.php @@ -37,7 +37,7 @@ class StStephensDayTest extends UriBaseTestCase implements HolidayTestCase * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date */ - public function testHoliday(int $year, DateTime $expected): void + public function testHoliday(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Switzerland/Valais/AllSaintsDayTest.php b/tests/Switzerland/Valais/AllSaintsDayTest.php index 8e65a2e6a..ff38ba76c 100644 --- a/tests/Switzerland/Valais/AllSaintsDayTest.php +++ b/tests/Switzerland/Valais/AllSaintsDayTest.php @@ -37,7 +37,7 @@ class AllSaintsDayTest extends ValaisBaseTestCase implements HolidayTestCase * @param int $year the year for which All Saints' Day needs to be tested * @param DateTime $expected the expected date */ - public function testAllSaintsDay(int $year, DateTime $expected): void + public function testAllSaintsDay(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Switzerland/Valais/AssumptionOfMaryTest.php b/tests/Switzerland/Valais/AssumptionOfMaryTest.php index 80331eac5..b576c673d 100644 --- a/tests/Switzerland/Valais/AssumptionOfMaryTest.php +++ b/tests/Switzerland/Valais/AssumptionOfMaryTest.php @@ -37,7 +37,7 @@ class AssumptionOfMaryTest extends ValaisBaseTestCase implements HolidayTestCase * @param int $year the year for which the day of the Assumption of Mary needs to be tested * @param DateTime $expected the expected date */ - public function testAssumptionOfMary(int $year, DateTime $expected): void + public function testAssumptionOfMary(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Switzerland/Valais/ChristmasDayTest.php b/tests/Switzerland/Valais/ChristmasDayTest.php index 42683bc37..7311165e0 100644 --- a/tests/Switzerland/Valais/ChristmasDayTest.php +++ b/tests/Switzerland/Valais/ChristmasDayTest.php @@ -37,7 +37,7 @@ class ChristmasDayTest extends ValaisBaseTestCase implements HolidayTestCase * @param int $year the year for which Christmas Day needs to be tested * @param DateTime $expected the expected date */ - public function testChristmasDay(int $year, DateTime $expected): void + public function testChristmasDay(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Switzerland/Valais/ImmaculateConceptionTest.php b/tests/Switzerland/Valais/ImmaculateConceptionTest.php index 2e6167448..e89881d83 100644 --- a/tests/Switzerland/Valais/ImmaculateConceptionTest.php +++ b/tests/Switzerland/Valais/ImmaculateConceptionTest.php @@ -37,7 +37,7 @@ class ImmaculateConceptionTest extends ValaisBaseTestCase implements HolidayTest * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date */ - public function testHoliday(int $year, DateTime $expected): void + public function testHoliday(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Switzerland/Valais/NewYearsDayTest.php b/tests/Switzerland/Valais/NewYearsDayTest.php index 2209567b2..4f79ba136 100644 --- a/tests/Switzerland/Valais/NewYearsDayTest.php +++ b/tests/Switzerland/Valais/NewYearsDayTest.php @@ -37,7 +37,7 @@ class NewYearsDayTest extends ValaisBaseTestCase implements HolidayTestCase * @param int $year the year for which New Years Day needs to be tested * @param DateTime $expected the expected date */ - public function testNewYearsDay(int $year, DateTime $expected): void + public function testNewYearsDay(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Switzerland/Valais/StJosephDayTest.php b/tests/Switzerland/Valais/StJosephDayTest.php index c385e900a..e995d181e 100644 --- a/tests/Switzerland/Valais/StJosephDayTest.php +++ b/tests/Switzerland/Valais/StJosephDayTest.php @@ -40,7 +40,7 @@ class StJosephDayTest extends ValaisBaseTestCase implements HolidayTestCase * @param int $year the year for which St. Joseph's Day needs to be tested * @param DateTime $expected the expected date */ - public function testStJosephDay(int $year, DateTime $expected): void + public function testStJosephDay(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Switzerland/Vaud/ChristmasDayTest.php b/tests/Switzerland/Vaud/ChristmasDayTest.php index b4cbad386..60ab6252e 100644 --- a/tests/Switzerland/Vaud/ChristmasDayTest.php +++ b/tests/Switzerland/Vaud/ChristmasDayTest.php @@ -37,7 +37,7 @@ class ChristmasDayTest extends VaudBaseTestCase implements HolidayTestCase * @param int $year the year for which Christmas Day needs to be tested * @param DateTime $expected the expected date */ - public function testChristmasDay(int $year, DateTime $expected): void + public function testChristmasDay(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Switzerland/Vaud/NewYearsDayTest.php b/tests/Switzerland/Vaud/NewYearsDayTest.php index 36f21f89c..36bed24a8 100644 --- a/tests/Switzerland/Vaud/NewYearsDayTest.php +++ b/tests/Switzerland/Vaud/NewYearsDayTest.php @@ -37,7 +37,7 @@ class NewYearsDayTest extends VaudBaseTestCase implements HolidayTestCase * @param int $year the year for which New Years Day needs to be tested * @param DateTime $expected the expected date */ - public function testNewYearsDay(int $year, DateTime $expected): void + public function testNewYearsDay(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Switzerland/Zug/AllSaintsDayTest.php b/tests/Switzerland/Zug/AllSaintsDayTest.php index 08de7d99d..aa45782a0 100644 --- a/tests/Switzerland/Zug/AllSaintsDayTest.php +++ b/tests/Switzerland/Zug/AllSaintsDayTest.php @@ -37,7 +37,7 @@ class AllSaintsDayTest extends ZugBaseTestCase implements HolidayTestCase * @param int $year the year for which All Saints' Day needs to be tested * @param DateTime $expected the expected date */ - public function testAllSaintsDay(int $year, DateTime $expected): void + public function testAllSaintsDay(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Switzerland/Zug/AssumptionOfMaryTest.php b/tests/Switzerland/Zug/AssumptionOfMaryTest.php index 5c44ef067..43607bdab 100644 --- a/tests/Switzerland/Zug/AssumptionOfMaryTest.php +++ b/tests/Switzerland/Zug/AssumptionOfMaryTest.php @@ -37,7 +37,7 @@ class AssumptionOfMaryTest extends ZugBaseTestCase implements HolidayTestCase * @param int $year the year for which the day of the Assumption of Mary needs to be tested * @param DateTime $expected the expected date */ - public function testAssumptionOfMary(int $year, DateTime $expected): void + public function testAssumptionOfMary(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Switzerland/Zug/ChristmasDayTest.php b/tests/Switzerland/Zug/ChristmasDayTest.php index a4db02be6..cea2de8e5 100644 --- a/tests/Switzerland/Zug/ChristmasDayTest.php +++ b/tests/Switzerland/Zug/ChristmasDayTest.php @@ -37,7 +37,7 @@ class ChristmasDayTest extends ZugBaseTestCase implements HolidayTestCase * @param int $year the year for which Christmas Day needs to be tested * @param DateTime $expected the expected date */ - public function testChristmasDay(int $year, DateTime $expected): void + public function testChristmasDay(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Switzerland/Zug/ImmaculateConceptionTest.php b/tests/Switzerland/Zug/ImmaculateConceptionTest.php index 0247e06ca..2002c2ce4 100644 --- a/tests/Switzerland/Zug/ImmaculateConceptionTest.php +++ b/tests/Switzerland/Zug/ImmaculateConceptionTest.php @@ -37,7 +37,7 @@ class ImmaculateConceptionTest extends ZugBaseTestCase implements HolidayTestCas * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date */ - public function testHoliday(int $year, DateTime $expected): void + public function testHoliday(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Switzerland/Zug/NewYearsDayTest.php b/tests/Switzerland/Zug/NewYearsDayTest.php index 0b254e59b..93d535b59 100644 --- a/tests/Switzerland/Zug/NewYearsDayTest.php +++ b/tests/Switzerland/Zug/NewYearsDayTest.php @@ -37,7 +37,7 @@ class NewYearsDayTest extends ZugBaseTestCase implements HolidayTestCase * @param int $year the year for which New Years Day needs to be tested * @param DateTime $expected the expected date */ - public function testNewYearsDay(int $year, DateTime $expected): void + public function testNewYearsDay(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Switzerland/Zug/StStephensDayTest.php b/tests/Switzerland/Zug/StStephensDayTest.php index 6f7bbbe3a..6764c861d 100644 --- a/tests/Switzerland/Zug/StStephensDayTest.php +++ b/tests/Switzerland/Zug/StStephensDayTest.php @@ -37,7 +37,7 @@ class StStephensDayTest extends ZugBaseTestCase implements HolidayTestCase * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date */ - public function testHoliday(int $year, DateTime $expected): void + public function testHoliday(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Switzerland/Zurich/ChristmasDayTest.php b/tests/Switzerland/Zurich/ChristmasDayTest.php index 9866f263a..32959b252 100644 --- a/tests/Switzerland/Zurich/ChristmasDayTest.php +++ b/tests/Switzerland/Zurich/ChristmasDayTest.php @@ -37,7 +37,7 @@ class ChristmasDayTest extends ZurichBaseTestCase implements HolidayTestCase * @param int $year the year for which Christmas Day needs to be tested * @param DateTime $expected the expected date */ - public function testChristmasDay(int $year, DateTime $expected): void + public function testChristmasDay(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Switzerland/Zurich/NewYearsDayTest.php b/tests/Switzerland/Zurich/NewYearsDayTest.php index d3603237c..326b88c49 100644 --- a/tests/Switzerland/Zurich/NewYearsDayTest.php +++ b/tests/Switzerland/Zurich/NewYearsDayTest.php @@ -37,7 +37,7 @@ class NewYearsDayTest extends ZurichBaseTestCase implements HolidayTestCase * @param int $year the year for which New Years Day needs to be tested * @param DateTime $expected the expected date */ - public function testNewYearsDay(int $year, DateTime $expected): void + public function testNewYearsDay(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Switzerland/Zurich/StStephensDayTest.php b/tests/Switzerland/Zurich/StStephensDayTest.php index 23748f3a6..f4182f665 100644 --- a/tests/Switzerland/Zurich/StStephensDayTest.php +++ b/tests/Switzerland/Zurich/StStephensDayTest.php @@ -37,7 +37,7 @@ class StStephensDayTest extends ZurichBaseTestCase implements HolidayTestCase * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date */ - public function testHoliday(int $year, DateTime $expected): void + public function testHoliday(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Turkey/LabourDayTest.php b/tests/Turkey/LabourDayTest.php index af84b7786..10ec0fe34 100644 --- a/tests/Turkey/LabourDayTest.php +++ b/tests/Turkey/LabourDayTest.php @@ -29,7 +29,7 @@ class LabourDayTest extends TurkeyBaseTestCase implements HolidayTestCase * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date */ - public function testHoliday(int $year, DateTime $expected): void + public function testHoliday(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Turkey/NewYearsDayTest.php b/tests/Turkey/NewYearsDayTest.php index 0d3c3da0e..48424d29b 100644 --- a/tests/Turkey/NewYearsDayTest.php +++ b/tests/Turkey/NewYearsDayTest.php @@ -29,7 +29,7 @@ class NewYearsDayTest extends TurkeyBaseTestCase implements HolidayTestCase * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date */ - public function testHoliday(int $year, DateTime $expected): void + public function testHoliday(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Ukraine/CatholicChristmasDayTest.php b/tests/Ukraine/CatholicChristmasDayTest.php index 6118e7b57..b507a7b6f 100644 --- a/tests/Ukraine/CatholicChristmasDayTest.php +++ b/tests/Ukraine/CatholicChristmasDayTest.php @@ -39,7 +39,7 @@ class CatholicChristmasDayTest extends UkraineBaseTestCase implements HolidayTes * @param int $year the year for which International Workers' Day needs to be tested * @param DateTime $expected the expected date */ - public function testCatholicChristmasDay(int $year, DateTime $expected): void + public function testCatholicChristmasDay(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Ukraine/ChristmasDayTest.php b/tests/Ukraine/ChristmasDayTest.php index 0eddc717a..6dcc53276 100644 --- a/tests/Ukraine/ChristmasDayTest.php +++ b/tests/Ukraine/ChristmasDayTest.php @@ -37,7 +37,7 @@ class ChristmasDayTest extends UkraineBaseTestCase implements HolidayTestCase * @param int $year the year for which Christmas Day needs to be tested * @param DateTime $expected the expected date */ - public function testChristmasDay(int $year, DateTime $expected): void + public function testChristmasDay(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Ukraine/InternationalWomensDayTest.php b/tests/Ukraine/InternationalWomensDayTest.php index 09e4aaf0b..fbca0d04d 100644 --- a/tests/Ukraine/InternationalWomensDayTest.php +++ b/tests/Ukraine/InternationalWomensDayTest.php @@ -14,7 +14,6 @@ namespace Yasumi\tests\Ukraine; -use DateTime; use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -32,7 +31,7 @@ class InternationalWomensDayTest extends UkraineBaseTestCase implements HolidayT /** * @dataProvider HolidayDataProvider */ - public function testHoliday(int $year, DateTime $expected): void + public function testHoliday(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Ukraine/InternationalWorkersDayTest.php b/tests/Ukraine/InternationalWorkersDayTest.php index 231a36c1a..4ba8bfe19 100644 --- a/tests/Ukraine/InternationalWorkersDayTest.php +++ b/tests/Ukraine/InternationalWorkersDayTest.php @@ -37,7 +37,7 @@ class InternationalWorkersDayTest extends UkraineBaseTestCase implements Holiday * @param int $year the year for which International Workers' Day needs to be tested * @param DateTime $expected the expected date */ - public function testInternationalWorkersDay(int $year, DateTime $expected): void + public function testInternationalWorkersDay(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Ukraine/NewYearsDayTest.php b/tests/Ukraine/NewYearsDayTest.php index 017418786..20fb1b25c 100644 --- a/tests/Ukraine/NewYearsDayTest.php +++ b/tests/Ukraine/NewYearsDayTest.php @@ -37,7 +37,7 @@ class NewYearsDayTest extends UkraineBaseTestCase implements HolidayTestCase * @param int $year the year for which the holiday defined in this test needs to be tested * @param DateTime $expected the expected date */ - public function testHoliday(int $year, DateTime $expected): void + public function testHoliday(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Ukraine/SecondInternationalWorkersDayTest.php b/tests/Ukraine/SecondInternationalWorkersDayTest.php index 63b01456e..1cc683821 100644 --- a/tests/Ukraine/SecondInternationalWorkersDayTest.php +++ b/tests/Ukraine/SecondInternationalWorkersDayTest.php @@ -38,7 +38,7 @@ class SecondInternationalWorkersDayTest extends UkraineBaseTestCase implements H * @param int $year the year for which International Workers' Day needs to be tested * @param DateTime $expected the expected date */ - public function testSecondInternationalWorkersDay(int $year, DateTime $expected): void + public function testSecondInternationalWorkersDay(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/Ukraine/SubstitutedHolidayTest.php b/tests/Ukraine/SubstitutedHolidayTest.php index a409f6104..eb2ae3c57 100644 --- a/tests/Ukraine/SubstitutedHolidayTest.php +++ b/tests/Ukraine/SubstitutedHolidayTest.php @@ -55,18 +55,18 @@ public function testSaturdaySubstitution(): void /** * Asserts that the expected date is indeed a holiday for that given year and name. * - * @param string $provider the holiday provider (i.e. country/state) for which the holiday need to be tested - * @param string $key string the key of the holiday to be checked against - * @param int $year holiday calendar year - * @param DateTime $expectedOfficial the official date to be checked against - * @param DateTime|null $expectedSubstitution the substituted date to be checked against + * @param string $provider the holiday provider (i.e. country/state) for which the holiday need to be tested + * @param string $key string the key of the holiday to be checked against + * @param int $year holiday calendar year + * @param \DateTimeInterface $expectedOfficial the official date to be checked against + * @param \DateTimeImmutable $expectedSubstitution the substituted date to be checked against */ public function assertHolidayWithSubstitution( string $provider, string $key, int $year, - DateTime $expectedOfficial, - DateTime $expectedSubstitution = null + \DateTimeInterface $expectedOfficial, + \DateTimeInterface $expectedSubstitution = null ): void { $holidays = Yasumi::create($provider, $year); diff --git a/tests/Ukraine/VictoryDayTest.php b/tests/Ukraine/VictoryDayTest.php index 4d686b93b..942530533 100644 --- a/tests/Ukraine/VictoryDayTest.php +++ b/tests/Ukraine/VictoryDayTest.php @@ -14,7 +14,6 @@ namespace Yasumi\tests\Ukraine; -use DateTime; use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -32,7 +31,7 @@ class VictoryDayTest extends UkraineBaseTestCase implements HolidayTestCase /** * @dataProvider HolidayDataProvider */ - public function testHoliday(int $year, DateTime $expected): void + public function testHoliday(int $year, \DateTimeInterface $expected): void { $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } diff --git a/tests/YasumiBase.php b/tests/YasumiBase.php index b391c7cda..70fd925c0 100644 --- a/tests/YasumiBase.php +++ b/tests/YasumiBase.php @@ -106,7 +106,7 @@ public function assertHoliday( string $provider, string $key, int $year, - DateTime $expected + DateTimeInterface $expected ): void { $holidays = Yasumi::create($provider, $year); $holiday = $holidays->getHoliday($key); @@ -134,7 +134,7 @@ public function assertSubstituteHoliday( string $provider, string $key, int $year, - DateTime $expected + DateTimeInterface $expected ): void { $holidays = Yasumi::create($provider, $year); $holiday = $holidays->getHoliday('substituteHoliday:'.$key); @@ -596,7 +596,7 @@ public static function numberBetween(int $int1 = 0, int $int2 = 2147483647): int * * @example DateTime('1999-02-02 11:42:52') */ - public static function dateTimeBetween($startDate = '-30 years', $endDate = 'now', $timezone = null): DateTime + public static function dateTimeBetween($startDate = '-30 years', $endDate = 'now', $timezone = null): DateTimeInterface { $startTimestamp = $startDate instanceof \DateTime ? $startDate->getTimestamp() : strtotime($startDate); @@ -722,7 +722,7 @@ protected static function getMaxTimestamp($max = 'now') /** * Internal method to set the time zone on a DateTime. */ - private static function setTimezone(DateTime $dt, ?string $timezone): DateTime + private static function setTimezone(DateTimeInterface $dt, ?string $timezone): DateTimeInterface { return $dt->setTimezone(new \DateTimeZone(static::resolveTimezone($timezone))); } From 19ca165a6eedfa70f9b9d328ec2f25bfb30e05ed Mon Sep 17 00:00:00 2001 From: Sacha Telgenhof Date: Thu, 11 Aug 2022 20:14:10 +0900 Subject: [PATCH 036/142] Included unit tests to be checked by rector. Signed-off-by: Sacha Telgenhof --- rector.php | 1 + 1 file changed, 1 insertion(+) diff --git a/rector.php b/rector.php index d9bd2f07f..b445a189c 100644 --- a/rector.php +++ b/rector.php @@ -9,6 +9,7 @@ return static function (RectorConfig $rectorConfig): void { $rectorConfig->paths([ __DIR__.'/src', + __DIR__.'/tests', ]); // single rules From 97eecb85a6c32cb2444523284da116ce6e3cc1e4 Mon Sep 17 00:00:00 2001 From: Sacha Telgenhof Date: Thu, 11 Aug 2022 20:32:43 +0900 Subject: [PATCH 037/142] Removed unused import statements. Signed-off-by: Sacha Telgenhof --- src/Yasumi/Filters/BetweenFilter.php | 1 - src/Yasumi/Filters/OnFilter.php | 1 - 2 files changed, 2 deletions(-) diff --git a/src/Yasumi/Filters/BetweenFilter.php b/src/Yasumi/Filters/BetweenFilter.php index 5f3096811..b3fcd122c 100644 --- a/src/Yasumi/Filters/BetweenFilter.php +++ b/src/Yasumi/Filters/BetweenFilter.php @@ -16,7 +16,6 @@ namespace Yasumi\Filters; use Iterator; -use Yasumi\Provider\AbstractProvider; use Yasumi\ProviderInterface; /** diff --git a/src/Yasumi/Filters/OnFilter.php b/src/Yasumi/Filters/OnFilter.php index ccf4f8565..22431c644 100644 --- a/src/Yasumi/Filters/OnFilter.php +++ b/src/Yasumi/Filters/OnFilter.php @@ -16,7 +16,6 @@ namespace Yasumi\Filters; use Iterator; -use Yasumi\Provider\AbstractProvider; use Yasumi\ProviderInterface; /** From a49cd0ec5fe11b72c2aaa3105fb24764ed22b184 Mon Sep 17 00:00:00 2001 From: Sacha Telgenhof Date: Tue, 30 Aug 2022 22:22:37 +0900 Subject: [PATCH 038/142] Use return type with closures. Signed-off-by: Sacha Telgenhof --- tests/YasumiBase.php | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/tests/YasumiBase.php b/tests/YasumiBase.php index 70fd925c0..7c0c1c3ec 100644 --- a/tests/YasumiBase.php +++ b/tests/YasumiBase.php @@ -387,7 +387,7 @@ public function generateRandomEasterMondayDates( ): array { $range ??= 1000; - return $this->generateRandomModifiedEasterDates(static function (DateTime $date) { + return $this->generateRandomModifiedEasterDates(static function (DateTime $date): void { $date->add(new DateInterval('P1D')); }, $timezone ?? 'UTC', $iterations ?? 10, $range); } @@ -442,7 +442,7 @@ public function generateRandomGoodFridayDates( ): array { $range ??= 1000; - return $this->generateRandomModifiedEasterDates(static function (DateTime $date) { + return $this->generateRandomModifiedEasterDates(static function (DateTime $date): void { $date->sub(new DateInterval('P2D')); }, $timezone ?? 'UTC', $iterations ?? 10, $range); } @@ -465,7 +465,7 @@ public function generateRandomPentecostDates( ): array { $range ??= 1000; - return $this->generateRandomModifiedEasterDates(static function (DateTime $date) { + return $this->generateRandomModifiedEasterDates(static function (DateTime $date): void { $date->add(new DateInterval('P49D')); }, $timezone ?? 'UTC', $iterations ?? 10, $range); } @@ -491,7 +491,7 @@ public function generateRandomDatesWithHolidayMovedToMonday( int $iterations = null, int $range = null ): array { - return $this->generateRandomDatesWithModifier($month, $day, function ($range, DateTime $date) { + return $this->generateRandomDatesWithModifier($month, $day, function ($range, DateTime $date): void { if ($this->isWeekend($date)) { $date->modify('next monday'); } From 288ea2f71a39f6802739a8ead37813e663a69e93 Mon Sep 17 00:00:00 2001 From: Sacha Telgenhof Date: Tue, 30 Aug 2022 23:44:23 +0900 Subject: [PATCH 039/142] Bumped levels as no other statistic analysis errors have been discovered. Signed-off-by: Sacha Telgenhof --- phpstan.neon.dist | 2 +- psalm.xml.dist | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/phpstan.neon.dist b/phpstan.neon.dist index 2faf82185..3973e7452 100644 --- a/phpstan.neon.dist +++ b/phpstan.neon.dist @@ -1,5 +1,5 @@ parameters: - level: 6 + level: 7 paths: - src ignoreErrors: diff --git a/psalm.xml.dist b/psalm.xml.dist index afd0d2d07..856ff93dc 100644 --- a/psalm.xml.dist +++ b/psalm.xml.dist @@ -11,7 +11,7 @@ --> Date: Tue, 30 Aug 2022 23:46:43 +0900 Subject: [PATCH 040/142] Made calculation for summer/winter time a bit more defensive by adding a check the timestamps are created successfully. Signed-off-by: Sacha Telgenhof --- src/Yasumi/Provider/CommonHolidays.php | 12 +++++++++++- 1 file changed, 11 insertions(+), 1 deletion(-) diff --git a/src/Yasumi/Provider/CommonHolidays.php b/src/Yasumi/Provider/CommonHolidays.php index 23eb17759..5f2648fe3 100644 --- a/src/Yasumi/Provider/CommonHolidays.php +++ b/src/Yasumi/Provider/CommonHolidays.php @@ -510,7 +510,17 @@ private function calculateSummerWinterTime( ): ?\DateTimeImmutable { $zone = DateTimeZoneFactory::getDateTimeZone($timezone); - $transitions = $zone->getTransitions(mktime(0, 0, 0, 1, 1, $year), mktime(23, 59, 59, 12, 31, $year)); + $tsBegin = mktime(0, 0, 0, 1, 1, $year); + if (!$tsBegin) { + throw new \RuntimeException('unable to create a beginning timestamp'); + } + + $tsEnd = mktime(23, 59, 59, 12, 31, $year); + if (!$tsEnd) { + throw new \RuntimeException('unable to create an ending timestamp'); + } + + $transitions = $zone->getTransitions($tsBegin, $tsEnd); $transition = array_shift($transitions); $dst = $transition['isdst']; From cbf72461e0473089e52a95db2fa817bfc20088f5 Mon Sep 17 00:00:00 2001 From: Sacha Telgenhof Date: Sun, 4 Sep 2022 09:39:15 +0900 Subject: [PATCH 041/142] Reordered entries. Signed-off-by: Sacha Telgenhof --- .gitignore | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/.gitignore b/.gitignore index b71a1e059..00cc7cd98 100644 --- a/.gitignore +++ b/.gitignore @@ -1,9 +1,9 @@ .DS_Store .idea/ -vendor -composer.lock .php-cs-fixer.cache .php_cs.cache -bin/_* .phpunit.result.cache +bin/_* +composer.lock var +vendor From c96180e0c2fa921e580458823eb1d8363181f5ab Mon Sep 17 00:00:00 2001 From: Sacha Telgenhof Date: Sun, 4 Sep 2022 09:39:47 +0900 Subject: [PATCH 042/142] Upgraded PHP CS Fixer. Signed-off-by: Sacha Telgenhof --- composer.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/composer.json b/composer.json index 718d7f715..21b99f450 100644 --- a/composer.json +++ b/composer.json @@ -40,7 +40,7 @@ "ext-json": "*" }, "require-dev": { - "friendsofphp/php-cs-fixer": "v2.19 | v3.8", + "friendsofphp/php-cs-fixer": "v2.19 | v3.11", "infection/infection": "^0.17 | ^0.26", "mikey179/vfsstream": "^1.6", "phan/phan": "^5.2", From 3a2158e54998646021cccf682dee00f4ce48bbfa Mon Sep 17 00:00:00 2001 From: Sacha Telgenhof Date: Sun, 4 Sep 2022 09:41:34 +0900 Subject: [PATCH 043/142] Code style formatting. Signed-off-by: Sacha Telgenhof --- src/Yasumi/Provider/Argentina.php | 172 +++++++++--------- src/Yasumi/Provider/Georgia.php | 4 +- src/Yasumi/Provider/Greece.php | 4 +- src/Yasumi/Provider/Romania.php | 4 +- src/Yasumi/Provider/Ukraine.php | 4 +- src/Yasumi/Yasumi.php | 8 +- tests/Argentina/FlagDayTest.php | 16 +- .../Argentina/GeneralJoseSanMartinDayTest.php | 20 +- .../GeneralMartinMigueldeGuemesDayTest.php | 16 +- .../Argentina/ImmaculateConceptionDayTest.php | 16 +- tests/Argentina/IndependenceDayTest.php | 16 +- tests/Argentina/MayRevolutionTest.php | 16 +- .../Argentina/NationalSovereigntyDayTest.php | 16 +- tests/Argentina/RaceDayTest.php | 16 +- tests/Base/YasumiTest.php | 2 +- 15 files changed, 165 insertions(+), 165 deletions(-) diff --git a/src/Yasumi/Provider/Argentina.php b/src/Yasumi/Provider/Argentina.php index 42870d937..cf4a0d27c 100644 --- a/src/Yasumi/Provider/Argentina.php +++ b/src/Yasumi/Provider/Argentina.php @@ -101,14 +101,14 @@ private function addCarnvalHolidays(): void $carnavalMondayDate = $carnavalMonday->sub(new DateInterval('P48D')); if (false !== $carnavalMondayDate) { $this->addHoliday(new Holiday( - 'carnavalMonday', - [ - 'en' => 'Carnival Monday', - 'es' => 'Lunes de Carnaval', - ], - $carnavalMondayDate, - $this->locale, - Holiday::TYPE_OBSERVANCE + 'carnavalMonday', + [ + 'en' => 'Carnival Monday', + 'es' => 'Lunes de Carnaval', + ], + $carnavalMondayDate, + $this->locale, + Holiday::TYPE_OBSERVANCE )); } @@ -116,14 +116,14 @@ private function addCarnvalHolidays(): void $carnavalTuesdayDate = $carnavalTuesday->sub(new DateInterval('P47D')); if (false !== $carnavalTuesdayDate) { $this->addHoliday(new Holiday( - 'carnavalTuesday', - [ - 'en' => 'Carnival Tuesday', - 'es' => 'Martes de Carnaval', - ], - $carnavalTuesdayDate, - $this->locale, - Holiday::TYPE_OBSERVANCE + 'carnavalTuesday', + [ + 'en' => 'Carnival Tuesday', + 'es' => 'Martes de Carnaval', + ], + $carnavalTuesdayDate, + $this->locale, + Holiday::TYPE_OBSERVANCE )); } } @@ -144,13 +144,13 @@ private function addRemembranceDay(): void { if ($this->year >= 2006) { $this->addHoliday(new Holiday( - 'remembranceDay', - [ - 'en' => 'Day of Remembrance for Truth and Justice', - 'es' => 'Día Nacional de la Memoria por la Verdad y la Justicia', - ], - new DateTime("$this->year-03-24", DateTimeZoneFactory::getDateTimeZone($this->timezone)), - $this->locale + 'remembranceDay', + [ + 'en' => 'Day of Remembrance for Truth and Justice', + 'es' => 'Día Nacional de la Memoria por la Verdad y la Justicia', + ], + new DateTime("$this->year-03-24", DateTimeZoneFactory::getDateTimeZone($this->timezone)), + $this->locale )); } } @@ -170,13 +170,13 @@ private function addMalvinasDay(): void { if ($this->year >= 1982) { $this->addHoliday(new Holiday( - 'malvinasDay', - [ - 'en' => 'Malvinas Day', - 'es' => 'Día del Veterano y de los Caídos en la Guerra de Malvinas', - ], - new DateTime("$this->year-04-02", DateTimeZoneFactory::getDateTimeZone($this->timezone)), - $this->locale + 'malvinasDay', + [ + 'en' => 'Malvinas Day', + 'es' => 'Día del Veterano y de los Caídos en la Guerra de Malvinas', + ], + new DateTime("$this->year-04-02", DateTimeZoneFactory::getDateTimeZone($this->timezone)), + $this->locale )); } } @@ -198,13 +198,13 @@ private function addMayRevolution(): void { if ($this->year >= 1810) { $this->addHoliday(new Holiday( - 'mayRevolution', - [ - 'en' => 'May Revolution', - 'es' => 'Día de la Revolución de Mayo', - ], - new DateTime("$this->year-05-25", DateTimeZoneFactory::getDateTimeZone($this->timezone)), - $this->locale + 'mayRevolution', + [ + 'en' => 'May Revolution', + 'es' => 'Día de la Revolución de Mayo', + ], + new DateTime("$this->year-05-25", DateTimeZoneFactory::getDateTimeZone($this->timezone)), + $this->locale )); } } @@ -219,13 +219,13 @@ private function addGeneralMartinMigueldeGuemesDay(): void { if ($this->year >= 1821) { $this->addHoliday(new Holiday( - 'generalMartinMigueldeGuemesDay', - [ - 'en' => 'Anniversary of the Passing of General Martín Miguel de Güemes', - 'es' => 'Paso a la Inmortalidad del General Martín Miguel de Güemes', - ], - new DateTime("$this->year-06-17", DateTimeZoneFactory::getDateTimeZone($this->timezone)), - $this->locale + 'generalMartinMigueldeGuemesDay', + [ + 'en' => 'Anniversary of the Passing of General Martín Miguel de Güemes', + 'es' => 'Paso a la Inmortalidad del General Martín Miguel de Güemes', + ], + new DateTime("$this->year-06-17", DateTimeZoneFactory::getDateTimeZone($this->timezone)), + $this->locale )); } } @@ -242,13 +242,13 @@ private function addFlagDay(): void { if ($this->year >= 1938) { $this->addHoliday(new Holiday( - 'flagDay', - [ - 'en' => 'General Manuel Belgrano Memorial Day', - 'es' => 'Paso a la Inmortalidad del General Manuel Belgrano', - ], - new DateTime("$this->year-06-20", DateTimeZoneFactory::getDateTimeZone($this->timezone)), - $this->locale + 'flagDay', + [ + 'en' => 'General Manuel Belgrano Memorial Day', + 'es' => 'Paso a la Inmortalidad del General Manuel Belgrano', + ], + new DateTime("$this->year-06-20", DateTimeZoneFactory::getDateTimeZone($this->timezone)), + $this->locale )); } } @@ -264,13 +264,13 @@ private function addIndependenceDay(): void { if ($this->year >= self::PROCLAMATION_OF_INDEPENDENCE_YEAR) { $this->addHoliday(new Holiday( - 'independenceDay', - [ - 'en' => 'Independence Day', - 'es' => 'Día de la Independencia', - ], - new DateTime("$this->year-07-09", DateTimeZoneFactory::getDateTimeZone($this->timezone)), - $this->locale + 'independenceDay', + [ + 'en' => 'Independence Day', + 'es' => 'Día de la Independencia', + ], + new DateTime("$this->year-07-09", DateTimeZoneFactory::getDateTimeZone($this->timezone)), + $this->locale )); } } @@ -285,13 +285,13 @@ private function addGeneralJoseSanMartinDay(): void { if ($this->year >= 1850) { $this->addHoliday(new Holiday( - 'generalJoseSanMartinDay', - [ - 'en' => 'General José de San Martín Memorial Day', - 'es' => 'Paso a la Inmortalidad del General José de San Martín', - ], - new DateTime("$this->year-08-17", DateTimeZoneFactory::getDateTimeZone($this->timezone)), - $this->locale + 'generalJoseSanMartinDay', + [ + 'en' => 'General José de San Martín Memorial Day', + 'es' => 'Paso a la Inmortalidad del General José de San Martín', + ], + new DateTime("$this->year-08-17", DateTimeZoneFactory::getDateTimeZone($this->timezone)), + $this->locale )); } } @@ -308,13 +308,13 @@ private function addRaceDay(): void { if ($this->year >= 1492) { $this->addHoliday(new Holiday( - 'raceDay', - [ - 'en' => 'Day of Respect for Cultural Diversity', - 'es' => 'Día del Respeto a la Diversidad Cultural', - ], - new DateTime("$this->year-10-12", DateTimeZoneFactory::getDateTimeZone($this->timezone)), - $this->locale + 'raceDay', + [ + 'en' => 'Day of Respect for Cultural Diversity', + 'es' => 'Día del Respeto a la Diversidad Cultural', + ], + new DateTime("$this->year-10-12", DateTimeZoneFactory::getDateTimeZone($this->timezone)), + $this->locale )); } } @@ -331,13 +331,13 @@ private function addNationalSovereigntyDay(): void { if ($this->year >= 2010) { $this->addHoliday(new Holiday( - 'nationalSovereigntyDay', - [ - 'en' => 'National Sovereignty Day', - 'es' => 'Día de la Soberanía Nacional', - ], - new DateTime("$this->year-11-20", DateTimeZoneFactory::getDateTimeZone($this->timezone)), - $this->locale + 'nationalSovereigntyDay', + [ + 'en' => 'National Sovereignty Day', + 'es' => 'Día de la Soberanía Nacional', + ], + new DateTime("$this->year-11-20", DateTimeZoneFactory::getDateTimeZone($this->timezone)), + $this->locale )); } } @@ -354,13 +354,13 @@ private function addImmaculateConceptionDay(): void { if ($this->year >= 1900) { $this->addHoliday(new Holiday( - 'immaculateConceptionDay', - [ - 'en' => 'Immaculate Conception Day', - 'es' => 'Día de la Inmaculada Concepción de María', - ], - new DateTime("$this->year-12-08", DateTimeZoneFactory::getDateTimeZone($this->timezone)), - $this->locale + 'immaculateConceptionDay', + [ + 'en' => 'Immaculate Conception Day', + 'es' => 'Día de la Inmaculada Concepción de María', + ], + new DateTime("$this->year-12-08", DateTimeZoneFactory::getDateTimeZone($this->timezone)), + $this->locale )); } } diff --git a/src/Yasumi/Provider/Georgia.php b/src/Yasumi/Provider/Georgia.php index 8822ee289..ee3ca6eb2 100644 --- a/src/Yasumi/Provider/Georgia.php +++ b/src/Yasumi/Provider/Georgia.php @@ -73,9 +73,9 @@ public function getSources(): array } /** - * @throws \Exception - * * @return \DateTime|\DateTimeImmutable + * + * @throws \Exception */ protected function calculateEaster(int $year, string $timezone): \DateTimeInterface { diff --git a/src/Yasumi/Provider/Greece.php b/src/Yasumi/Provider/Greece.php index f6c0635f3..7cbdfe886 100644 --- a/src/Yasumi/Provider/Greece.php +++ b/src/Yasumi/Provider/Greece.php @@ -129,9 +129,9 @@ private function calculateCleanMonday(): void /** * Orthodox Easter. * - * @throws \Exception - * * @return \DateTime|\DateTimeImmutable + * + * @throws \Exception */ private function calculateEaster(int $year, string $timezone): \DateTimeInterface { diff --git a/src/Yasumi/Provider/Romania.php b/src/Yasumi/Provider/Romania.php index 13042e1f5..9f4ebb2f4 100644 --- a/src/Yasumi/Provider/Romania.php +++ b/src/Yasumi/Provider/Romania.php @@ -85,9 +85,9 @@ public function getSources(): array } /** - * @throws \Exception - * * @return \DateTime|\DateTimeImmutable + * + * @throws \Exception */ protected function calculateEaster(int $year, string $timezone): \DateTimeInterface { diff --git a/src/Yasumi/Provider/Ukraine.php b/src/Yasumi/Provider/Ukraine.php index 1ab5a440a..039286d3d 100644 --- a/src/Yasumi/Provider/Ukraine.php +++ b/src/Yasumi/Provider/Ukraine.php @@ -114,9 +114,9 @@ public function addHoliday(Holiday $holiday, bool $substitutable = true): void } /** - * @throws \Exception - * * @return \DateTime|\DateTimeImmutable + * + * @throws \Exception */ protected function calculateEaster(int $year, string $timezone): \DateTimeInterface { diff --git a/src/Yasumi/Yasumi.php b/src/Yasumi/Yasumi.php index edc389a5b..858038442 100644 --- a/src/Yasumi/Yasumi.php +++ b/src/Yasumi/Yasumi.php @@ -225,10 +225,10 @@ public static function getProviders(): array foreach ($filesIterator as $file) { if ($file->isDir() || 'php' !== $file->getExtension() || \in_array( - $file->getBasename('.php'), - self::$ignoredProvider, - true - )) { + $file->getBasename('.php'), + self::$ignoredProvider, + true + )) { continue; } diff --git a/tests/Argentina/FlagDayTest.php b/tests/Argentina/FlagDayTest.php index fbe826af2..861654587 100644 --- a/tests/Argentina/FlagDayTest.php +++ b/tests/Argentina/FlagDayTest.php @@ -44,10 +44,10 @@ public function testHoliday(): void { $year = self::ESTABLISHMENT_YEAR; $this->assertHoliday( - self::REGION, - self::HOLIDAY, - $year, - new DateTime("$year-06-20", new DateTimeZone(self::TIMEZONE)) + self::REGION, + self::HOLIDAY, + $year, + new DateTime("$year-06-20", new DateTimeZone(self::TIMEZONE)) ); } @@ -67,10 +67,10 @@ public function testNotHoliday(): void public function testTranslation(): void { $this->assertTranslatedHolidayName( - self::REGION, - self::HOLIDAY, - $this->generateRandomYear(self::ESTABLISHMENT_YEAR), - [self::LOCALE => 'Paso a la Inmortalidad del General Manuel Belgrano'] + self::REGION, + self::HOLIDAY, + $this->generateRandomYear(self::ESTABLISHMENT_YEAR), + [self::LOCALE => 'Paso a la Inmortalidad del General Manuel Belgrano'] ); } diff --git a/tests/Argentina/GeneralJoseSanMartinDayTest.php b/tests/Argentina/GeneralJoseSanMartinDayTest.php index 66d4c3fe2..d36dfb288 100644 --- a/tests/Argentina/GeneralJoseSanMartinDayTest.php +++ b/tests/Argentina/GeneralJoseSanMartinDayTest.php @@ -44,11 +44,11 @@ public function testHoliday(): void { $year = self::ESTABLISHMENT_YEAR; $this->assertHoliday( - self::REGION, - self::HOLIDAY, - $year, - new DateTime("$year-08-17", new DateTimeZone(self::TIMEZONE)) - ); + self::REGION, + self::HOLIDAY, + $year, + new DateTime("$year-08-17", new DateTimeZone(self::TIMEZONE)) + ); } /** @@ -67,11 +67,11 @@ public function testNotHoliday(): void public function testTranslation(): void { $this->assertTranslatedHolidayName( - self::REGION, - self::HOLIDAY, - $this->generateRandomYear(self::ESTABLISHMENT_YEAR), - [self::LOCALE => 'Paso a la Inmortalidad del General José de San Martín'] - ); + self::REGION, + self::HOLIDAY, + $this->generateRandomYear(self::ESTABLISHMENT_YEAR), + [self::LOCALE => 'Paso a la Inmortalidad del General José de San Martín'] + ); } /** diff --git a/tests/Argentina/GeneralMartinMigueldeGuemesDayTest.php b/tests/Argentina/GeneralMartinMigueldeGuemesDayTest.php index 119c45c1c..3202d4e65 100644 --- a/tests/Argentina/GeneralMartinMigueldeGuemesDayTest.php +++ b/tests/Argentina/GeneralMartinMigueldeGuemesDayTest.php @@ -44,10 +44,10 @@ public function testHoliday(): void { $year = self::ESTABLISHMENT_YEAR; $this->assertHoliday( - self::REGION, - self::HOLIDAY, - $year, - new DateTime("$year-06-17", new DateTimeZone(self::TIMEZONE)) + self::REGION, + self::HOLIDAY, + $year, + new DateTime("$year-06-17", new DateTimeZone(self::TIMEZONE)) ); } @@ -67,10 +67,10 @@ public function testNotHoliday(): void public function testTranslation(): void { $this->assertTranslatedHolidayName( - self::REGION, - self::HOLIDAY, - $this->generateRandomYear(self::ESTABLISHMENT_YEAR), - [self::LOCALE => 'Paso a la Inmortalidad del General Martín Miguel de Güemes'] + self::REGION, + self::HOLIDAY, + $this->generateRandomYear(self::ESTABLISHMENT_YEAR), + [self::LOCALE => 'Paso a la Inmortalidad del General Martín Miguel de Güemes'] ); } diff --git a/tests/Argentina/ImmaculateConceptionDayTest.php b/tests/Argentina/ImmaculateConceptionDayTest.php index 94142b054..b2693e0b3 100644 --- a/tests/Argentina/ImmaculateConceptionDayTest.php +++ b/tests/Argentina/ImmaculateConceptionDayTest.php @@ -44,10 +44,10 @@ public function testHoliday(): void { $year = self::ESTABLISHMENT_YEAR; $this->assertHoliday( - self::REGION, - self::HOLIDAY, - $year, - new DateTime("$year-12-08", new DateTimeZone(self::TIMEZONE)) + self::REGION, + self::HOLIDAY, + $year, + new DateTime("$year-12-08", new DateTimeZone(self::TIMEZONE)) ); } @@ -67,10 +67,10 @@ public function testNotHoliday(): void public function testTranslation(): void { $this->assertTranslatedHolidayName( - self::REGION, - self::HOLIDAY, - $this->generateRandomYear(self::ESTABLISHMENT_YEAR), - [self::LOCALE => 'Día de la Inmaculada Concepción de María'] + self::REGION, + self::HOLIDAY, + $this->generateRandomYear(self::ESTABLISHMENT_YEAR), + [self::LOCALE => 'Día de la Inmaculada Concepción de María'] ); } diff --git a/tests/Argentina/IndependenceDayTest.php b/tests/Argentina/IndependenceDayTest.php index c187f2f61..499f58689 100644 --- a/tests/Argentina/IndependenceDayTest.php +++ b/tests/Argentina/IndependenceDayTest.php @@ -44,10 +44,10 @@ public function testHoliday(): void { $year = self::ESTABLISHMENT_YEAR; $this->assertHoliday( - self::REGION, - self::HOLIDAY, - $year, - new DateTime("$year-07-09", new DateTimeZone(self::TIMEZONE)) + self::REGION, + self::HOLIDAY, + $year, + new DateTime("$year-07-09", new DateTimeZone(self::TIMEZONE)) ); } @@ -67,10 +67,10 @@ public function testNotHoliday(): void public function testTranslation(): void { $this->assertTranslatedHolidayName( - self::REGION, - self::HOLIDAY, - $this->generateRandomYear(self::ESTABLISHMENT_YEAR), - [self::LOCALE => 'Día de la Independencia'] + self::REGION, + self::HOLIDAY, + $this->generateRandomYear(self::ESTABLISHMENT_YEAR), + [self::LOCALE => 'Día de la Independencia'] ); } diff --git a/tests/Argentina/MayRevolutionTest.php b/tests/Argentina/MayRevolutionTest.php index 95a7a75f9..5e36faad1 100644 --- a/tests/Argentina/MayRevolutionTest.php +++ b/tests/Argentina/MayRevolutionTest.php @@ -44,10 +44,10 @@ public function testHoliday(): void { $year = self::ESTABLISHMENT_YEAR; $this->assertHoliday( - self::REGION, - self::HOLIDAY, - $year, - new DateTime("$year-05-25", new DateTimeZone(self::TIMEZONE)) + self::REGION, + self::HOLIDAY, + $year, + new DateTime("$year-05-25", new DateTimeZone(self::TIMEZONE)) ); } @@ -67,10 +67,10 @@ public function testNotHoliday(): void public function testTranslation(): void { $this->assertTranslatedHolidayName( - self::REGION, - self::HOLIDAY, - $this->generateRandomYear(self::ESTABLISHMENT_YEAR), - [self::LOCALE => 'Día de la Revolución de Mayo'] + self::REGION, + self::HOLIDAY, + $this->generateRandomYear(self::ESTABLISHMENT_YEAR), + [self::LOCALE => 'Día de la Revolución de Mayo'] ); } diff --git a/tests/Argentina/NationalSovereigntyDayTest.php b/tests/Argentina/NationalSovereigntyDayTest.php index 7defe3529..f82a04f92 100644 --- a/tests/Argentina/NationalSovereigntyDayTest.php +++ b/tests/Argentina/NationalSovereigntyDayTest.php @@ -44,10 +44,10 @@ public function testHoliday(): void { $year = self::ESTABLISHMENT_YEAR; $this->assertHoliday( - self::REGION, - self::HOLIDAY, - $year, - new DateTime("$year-11-20", new DateTimeZone(self::TIMEZONE)) + self::REGION, + self::HOLIDAY, + $year, + new DateTime("$year-11-20", new DateTimeZone(self::TIMEZONE)) ); } @@ -67,10 +67,10 @@ public function testNotHoliday(): void public function testTranslation(): void { $this->assertTranslatedHolidayName( - self::REGION, - self::HOLIDAY, - $this->generateRandomYear(self::ESTABLISHMENT_YEAR), - [self::LOCALE => 'Día de la Soberanía Nacional'] + self::REGION, + self::HOLIDAY, + $this->generateRandomYear(self::ESTABLISHMENT_YEAR), + [self::LOCALE => 'Día de la Soberanía Nacional'] ); } diff --git a/tests/Argentina/RaceDayTest.php b/tests/Argentina/RaceDayTest.php index 46abbe4ed..be28f4d75 100644 --- a/tests/Argentina/RaceDayTest.php +++ b/tests/Argentina/RaceDayTest.php @@ -44,10 +44,10 @@ public function testHoliday(): void { $year = self::ESTABLISHMENT_YEAR; $this->assertHoliday( - self::REGION, - self::HOLIDAY, - $year, - new DateTime("$year-10-12", new DateTimeZone(self::TIMEZONE)) + self::REGION, + self::HOLIDAY, + $year, + new DateTime("$year-10-12", new DateTimeZone(self::TIMEZONE)) ); } @@ -67,10 +67,10 @@ public function testNotHoliday(): void public function testTranslation(): void { $this->assertTranslatedHolidayName( - self::REGION, - self::HOLIDAY, - $this->generateRandomYear(self::ESTABLISHMENT_YEAR), - [self::LOCALE => 'Día del Respeto a la Diversidad Cultural'] + self::REGION, + self::HOLIDAY, + $this->generateRandomYear(self::ESTABLISHMENT_YEAR), + [self::LOCALE => 'Día del Respeto a la Diversidad Cultural'] ); } diff --git a/tests/Base/YasumiTest.php b/tests/Base/YasumiTest.php index 9e164abc6..5bf8d1cd7 100644 --- a/tests/Base/YasumiTest.php +++ b/tests/Base/YasumiTest.php @@ -155,7 +155,7 @@ public function testPrevious(): void $this->assertHoliday( $country, $name, - (($year > $year_lower_limit) ? $year - 1 : $year_lower_limit), + ($year > $year_lower_limit) ? $year - 1 : $year_lower_limit, $holidays->previous($name) ); } From 08db3fb33bdcd2134ef4ed0cdfbed6d19a46acec Mon Sep 17 00:00:00 2001 From: Sacha Telgenhof Date: Sun, 4 Sep 2022 11:35:21 +0900 Subject: [PATCH 044/142] Corrected return types. Add check in case strtok function returns false. Signed-off-by: Sacha Telgenhof --- src/Yasumi/Exception/MissingTranslationException.php | 4 ++-- src/Yasumi/Holiday.php | 6 +++++- 2 files changed, 7 insertions(+), 3 deletions(-) diff --git a/src/Yasumi/Exception/MissingTranslationException.php b/src/Yasumi/Exception/MissingTranslationException.php index 7aa69c82c..accfdd16d 100644 --- a/src/Yasumi/Exception/MissingTranslationException.php +++ b/src/Yasumi/Exception/MissingTranslationException.php @@ -24,8 +24,8 @@ class MissingTranslationException extends BaseException implements Exception /** * Initializes the Exception instance. * - * @param string $key The holiday key - * @param array $locales The locales that was searched + * @param string $key The holiday key + * @param array $locales The locales that was searched */ public function __construct(string $key, array $locales) { diff --git a/src/Yasumi/Holiday.php b/src/Yasumi/Holiday.php index 8b0c52c13..9dc4b5305 100644 --- a/src/Yasumi/Holiday.php +++ b/src/Yasumi/Holiday.php @@ -229,7 +229,7 @@ public function mergeGlobalTranslations(TranslationsInterface $globalTranslation * * @param array|null $locales Array of locales, or null if the display locale should be used * - * @return array an array of locales to check for translations + * @return array an array of locales to check for translations * * @see Holiday::DEFAULT_LOCALE * @see Holiday::LOCALE_KEY @@ -247,6 +247,10 @@ protected function getLocales(?array $locales): array // Expand e.g. ['de_DE', 'en_GB'] into ['de_DE', 'de', 'en_GB', 'en']. foreach (array_reverse($locales) as $locale) { $parent = strtok($locale, '_'); + if (!$parent) { + continue; + } + while ($child = strtok('_')) { $expanded[] = $parent; $parent .= '_'.$child; From 04940c56917d3d6a0104ea3eab17b800d3595a53 Mon Sep 17 00:00:00 2001 From: Sacha Telgenhof Date: Sun, 4 Sep 2022 11:50:43 +0900 Subject: [PATCH 045/142] Used literal separator for large numbers. Removed redundant check for empty array. Signed-off-by: Sacha Telgenhof --- tests/YasumiBase.php | 32 +++++++++++++++----------------- 1 file changed, 15 insertions(+), 17 deletions(-) diff --git a/tests/YasumiBase.php b/tests/YasumiBase.php index 7c0c1c3ec..f186459b4 100644 --- a/tests/YasumiBase.php +++ b/tests/YasumiBase.php @@ -218,25 +218,23 @@ public function assertTranslatedHolidayName( self::assertInstanceOf(Holiday::class, $holiday); self::assertTrue($holidays->isHoliday($holiday)); - if (!empty($translations)) { - foreach ($translations as $locale => $name) { - $locales = [$locale]; - $parts = explode('_', $locale); - while (array_pop($parts) && $parts) { - $locales[] = implode('_', $parts); - } + foreach ($translations as $locale => $name) { + $locales = [$locale]; + $parts = explode('_', $locale); + while (array_pop($parts) && $parts) { + $locales[] = implode('_', $parts); + } - $translation = null; - foreach ($locales as $l) { - if (isset($holiday->translations[$l])) { - $translation = $holiday->translations[$l]; - break; - } + $translation = null; + foreach ($locales as $l) { + if (isset($holiday->translations[$l])) { + $translation = $holiday->translations[$l]; + break; } - - self::assertTrue(isset($translation)); - self::assertEquals($name, $translation); } + + self::assertTrue(isset($translation)); + self::assertEquals($name, $translation); } } @@ -573,7 +571,7 @@ public function isWeekend( * * @example 79907610 */ - public static function numberBetween(int $int1 = 0, int $int2 = 2147483647): int + public static function numberBetween(int $int1 = 0, int $int2 = 2_147_483_647): int { $min = $int1 < $int2 ? $int1 : $int2; $max = $int1 < $int2 ? $int2 : $int1; From 40cd66ede69d21c2b5b8c964737bf57f3e623b83 Mon Sep 17 00:00:00 2001 From: Sacha Telgenhof Date: Sun, 4 Sep 2022 12:13:23 +0900 Subject: [PATCH 046/142] Reverting phpstan level as some errors require some effort refactoring. Signed-off-by: Sacha Telgenhof --- phpstan.neon.dist | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/phpstan.neon.dist b/phpstan.neon.dist index 3973e7452..2faf82185 100644 --- a/phpstan.neon.dist +++ b/phpstan.neon.dist @@ -1,5 +1,5 @@ parameters: - level: 7 + level: 6 paths: - src ignoreErrors: From acf84578ac13155a3e38f6eb63ced3448ea0d58f Mon Sep 17 00:00:00 2001 From: Sacha Telgenhof Date: Sun, 4 Sep 2022 12:16:28 +0900 Subject: [PATCH 047/142] Use preferred/idiomatic way of getting an immutable date from an mutable one. Added extra checks if modifying date methods are not succesful. Signed-off-by: Sacha Telgenhof --- src/Yasumi/Yasumi.php | 14 ++++++++++---- tests/Base/YasumiWorkdayTest.php | 4 ++-- 2 files changed, 12 insertions(+), 6 deletions(-) diff --git a/src/Yasumi/Yasumi.php b/src/Yasumi/Yasumi.php index 858038442..b876c8855 100644 --- a/src/Yasumi/Yasumi.php +++ b/src/Yasumi/Yasumi.php @@ -80,13 +80,16 @@ public static function nextWorkingDay( \DateTimeInterface $startDate, int $workingDays = 1 ): \DateTimeInterface { - // Setup start date, if it's an instance of \DateTime, clone to prevent modification to original - $date = $startDate instanceof \DateTime ? clone $startDate : $startDate; + // convert to immutable date to prevent modification of the original + $date = $startDate instanceof \DateTime ? \DateTimeImmutable::createFromMutable($startDate) : $startDate; $provider = null; while ($workingDays > 0) { $date = $date->add(new \DateInterval('P1D')); + if (!$date instanceof \DateTimeInterface) { + throw new \RuntimeException('unable to perform addition'); + } if (!$provider instanceof ProviderInterface) { $provider = self::create($class, (int) $date->format('Y')); @@ -270,13 +273,16 @@ public static function prevWorkingDay( \DateTimeInterface $startDate, int $workingDays = 1 ): \DateTimeInterface { - // Setup start date, if it's an instance of \DateTime, clone to prevent modification to original - $date = $startDate instanceof \DateTime ? clone $startDate : $startDate; + // convert to immutable date to prevent modification of the original + $date = $startDate instanceof \DateTime ? \DateTimeImmutable::createFromMutable($startDate) : $startDate; $provider = null; while ($workingDays > 0) { $date = $date->sub(new \DateInterval('P1D')); + if (!$date instanceof \DateTimeInterface) { + throw new \RuntimeException('unable to perform subtraction'); + } if (!$provider instanceof ProviderInterface) { $provider = self::create($class, (int) $date->format('Y')); diff --git a/tests/Base/YasumiWorkdayTest.php b/tests/Base/YasumiWorkdayTest.php index 0a794f1b3..c4736e236 100644 --- a/tests/Base/YasumiWorkdayTest.php +++ b/tests/Base/YasumiWorkdayTest.php @@ -42,7 +42,7 @@ public function testNextWorkingDay(): void $startDate = new DateTime($date, new DateTimeZone($timezone)); $nextWorkingDay = Yasumi::nextWorkingDay($provider, $startDate); - self::assertInstanceOf(DateTime::class, $nextWorkingDay); + self::assertInstanceOf(DateTimeImmutable::class, $nextWorkingDay); self::assertEquals($expectedDate, $nextWorkingDay->format(self::FORMAT_DATE)); // Assertion using a DateTimeImmutable instance @@ -70,7 +70,7 @@ public function testPreviousWorkingDay(): void $startDate = new DateTime($date, new DateTimeZone($timezone)); $previousWorkingDay = Yasumi::prevWorkingDay($provider, $startDate); - self::assertInstanceOf(DateTime::class, $previousWorkingDay); + self::assertInstanceOf(DateTimeImmutable::class, $previousWorkingDay); self::assertEquals($expectedDate, $previousWorkingDay->format(self::FORMAT_DATE)); // Assertion using a DateTimeImmutable instance From 8fc03c4599e188ff5897ed18bb10e41b0e1f57f5 Mon Sep 17 00:00:00 2001 From: Sacha Telgenhof Date: Sun, 4 Sep 2022 14:09:14 +0900 Subject: [PATCH 048/142] Changed to use the 'strtotime' function as 'mktime' does not generate timestamps before 1970-01-01 (negative values), which is needed to determine winter/summer time before that. Signed-off-by: Sacha Telgenhof --- src/Yasumi/Provider/CommonHolidays.php | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/src/Yasumi/Provider/CommonHolidays.php b/src/Yasumi/Provider/CommonHolidays.php index 5f2648fe3..329c5435b 100644 --- a/src/Yasumi/Provider/CommonHolidays.php +++ b/src/Yasumi/Provider/CommonHolidays.php @@ -510,14 +510,14 @@ private function calculateSummerWinterTime( ): ?\DateTimeImmutable { $zone = DateTimeZoneFactory::getDateTimeZone($timezone); - $tsBegin = mktime(0, 0, 0, 1, 1, $year); - if (!$tsBegin) { - throw new \RuntimeException('unable to create a beginning timestamp'); + $tsBegin = strtotime(sprintf('%u-01-01 00:00:00', $year)); + if (false === $tsBegin) { + throw new \RuntimeException(sprintf('unable to create a beginning timestamp for the year `%u`', $year)); } - $tsEnd = mktime(23, 59, 59, 12, 31, $year); - if (!$tsEnd) { - throw new \RuntimeException('unable to create an ending timestamp'); + $tsEnd = strtotime(sprintf('%u-12-31 23:59:59', $year)); + if (false === $tsEnd) { + throw new \RuntimeException(sprintf('unable to create an ending timestamp for the year `%u`', $year)); } $transitions = $zone->getTransitions($tsBegin, $tsEnd); From bb9c8d2b865e95a03b1e7afb26225ec390a47bab Mon Sep 17 00:00:00 2001 From: Sacha Telgenhof Date: Sun, 4 Sep 2022 14:11:54 +0900 Subject: [PATCH 049/142] Included an .editorconfig file to maintain a consistent style. Signed-off-by: Sacha Telgenhof --- .editorconfig | 18 ++++++++++++++++++ 1 file changed, 18 insertions(+) create mode 100644 .editorconfig diff --git a/.editorconfig b/.editorconfig new file mode 100644 index 000000000..d3ff85a66 --- /dev/null +++ b/.editorconfig @@ -0,0 +1,18 @@ +root = true + +[*] +charset = utf-8 +end_of_line = lf +indent_style = space +insert_final_newline = true +trim_trailing_whitespace = true + +[*.php] +indent_size = 4 + +[*.json] +indent_size = 2 + +[*.{yml,yaml}] +indent_size = 2 + From 5a18b38dafd0a506366a537a2532e68090a63982 Mon Sep 17 00:00:00 2001 From: Sacha Telgenhof Date: Wed, 7 Sep 2022 00:30:00 +0900 Subject: [PATCH 050/142] Added all examples as shown on the documentation website as a convenience for developers who like to have all information in a single place. Signed-off-by: Sacha Telgenhof --- .phan/config.php | 3 ++- examples/basic.php | 47 ++++++++++++++++++++++++++++++++++++ examples/between_filter.php | 27 +++++++++++++++++++++ examples/custom_provider.php | 43 +++++++++++++++++++++++++++++++++ examples/filters.php | 20 +++++++++++++++ phpstan.neon.dist | 1 + 6 files changed, 140 insertions(+), 1 deletion(-) create mode 100644 examples/basic.php create mode 100644 examples/between_filter.php create mode 100644 examples/custom_provider.php create mode 100644 examples/filters.php diff --git a/.phan/config.php b/.phan/config.php index 5ec6e6b5f..dceda84d5 100644 --- a/.phan/config.php +++ b/.phan/config.php @@ -349,7 +349,8 @@ // Thus, both first-party and third-party code being used by // your application should be included in this list. 'directory_list' => [ - 'src' + 'src', + 'examples' ], // A list of individual files to include in analysis diff --git a/examples/basic.php b/examples/basic.php new file mode 100644 index 000000000..4407f7351 --- /dev/null +++ b/examples/basic.php @@ -0,0 +1,47 @@ +count().PHP_EOL; +echo PHP_EOL; + +// Display a list all of the holiday names (short names) +echo 'List of all the holiday names: '.PHP_EOL; +foreach ($holidays->getHolidayNames() as $name) { + echo $name.PHP_EOL; +} +echo PHP_EOL; + +// Display a list all of the holiday dates +echo 'List of all the holiday dates:'.PHP_EOL; +foreach ($holidays->getHolidayDates() as $date) { + echo $date.PHP_EOL; +} +echo PHP_EOL; + +// Get a holiday instance for Independence Day +$independenceDay = $holidays->getHoliday('independenceDay'); + +// Show the localized name +echo 'Name of the holiday : '.$independenceDay->getName().PHP_EOL; + +// Show the date +echo 'Date of the holiday : '.$independenceDay.PHP_EOL; + +// Show the type of holiday +echo 'Type of holiday : '.$independenceDay->getType().PHP_EOL; +echo PHP_EOL; + +// Dump the holiday as a JSON object +echo 'Holiday as a JSON object:'.PHP_EOL; +echo json_encode($independenceDay, JSON_PRETTY_PRINT); + +echo PHP_EOL; diff --git a/examples/between_filter.php b/examples/between_filter.php new file mode 100644 index 000000000..4b1358c9a --- /dev/null +++ b/examples/between_filter.php @@ -0,0 +1,27 @@ +between( + new DateTime('12/01/'.$year), + new DateTime('12/31/'.$year) +); + +// Show all holidays in Italy for December +echo 'List of all the holidays in December: '.PHP_EOL; +foreach ($holidaysInDecember as $holiday) { + echo $holiday.' - '.$holiday->getName().PHP_EOL; +} +echo PHP_EOL; + +// Show the number of filtered holidays +echo 'Number of filtered holidays: '.$holidaysInDecember->count().PHP_EOL; diff --git a/examples/custom_provider.php b/examples/custom_provider.php new file mode 100644 index 000000000..1f893f474 --- /dev/null +++ b/examples/custom_provider.php @@ -0,0 +1,43 @@ +addHoliday($this->goodFriday($this->year, $this->timezone, $this->locale)); + + // Remove Columbus Day and Veterans Day + $this->removeHoliday('columbusDay'); + $this->removeHoliday('veteransDay'); + } +} + +// Use the factory method to create a new holiday provider instance +$NYSEHolidays = Yasumi\Yasumi::create(NYSE::class, (int) date('Y')); + +// We then can retrieve the NYSE observed holidays in 2022 in the usual manner: +echo 'List of all the holiday names: '.PHP_EOL; +foreach ($NYSEHolidays->getHolidayNames() as $day) { + echo $day.PHP_EOL; +} +echo PHP_EOL; + +// Use the count() method to show how many holidays are returned +echo 'Number of defined holidays: '.$NYSEHolidays->count().PHP_EOL; diff --git a/examples/filters.php b/examples/filters.php new file mode 100644 index 000000000..3a82af460 --- /dev/null +++ b/examples/filters.php @@ -0,0 +1,20 @@ +getIterator()); + +echo 'List of all official holidays: '.PHP_EOL; +foreach ($official as $day) { + echo $day->getName().PHP_EOL; +} diff --git a/phpstan.neon.dist b/phpstan.neon.dist index 2faf82185..fad49a494 100644 --- a/phpstan.neon.dist +++ b/phpstan.neon.dist @@ -2,6 +2,7 @@ parameters: level: 6 paths: - src + - examples ignoreErrors: - message: '#Comparison operation "<=" between [0-9]+ and int<[0-9]+, max> is always true.#' From 8e5666354982dcb564c0992f6ada2834eb5d06c3 Mon Sep 17 00:00:00 2001 From: Sacha Telgenhof Date: Wed, 7 Sep 2022 08:31:12 +0900 Subject: [PATCH 051/142] Updated changelog noting the added examples. Signed-off-by: Sacha Telgenhof --- CHANGELOG.md | 3 +++ 1 file changed, 3 insertions(+) diff --git a/CHANGELOG.md b/CHANGELOG.md index 695f3ed1f..f3913001d 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -9,6 +9,9 @@ to [Semantic Versioning](https://semver.org). ### Added +- Added all examples as shown on the documentation site as a convenience to developers who like to have all + information in a single place. + ### Changed - Included the unit tests directory for checking by PHPStan. From 156f0dc8cfc6fedff83ff314d5710ee40cfedaa8 Mon Sep 17 00:00:00 2001 From: Freshleaf Media <10062339+freshleafmedia@users.noreply.github.com> Date: Mon, 19 Sep 2022 10:11:42 +0100 Subject: [PATCH 052/142] =?UTF-8?q?Adds=20UK=20bank=20holiday=20for=20Quee?= =?UTF-8?q?n=20Elizabeth=20II=E2=80=99s=20funeral=20(#287)?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Adds bank holiday for Queen Elizabeth II’s funeral --- CHANGELOG.md | 1 + src/Yasumi/Provider/UnitedKingdom.php | 28 +++++ .../QueenElizabethFuneralBankHolidayTest.php | 111 ++++++++++++++++++ 3 files changed, 140 insertions(+) create mode 100644 tests/UnitedKingdom/QueenElizabethFuneralBankHolidayTest.php diff --git a/CHANGELOG.md b/CHANGELOG.md index 3ecfeb5b6..a2de483a8 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -11,6 +11,7 @@ to [Semantic Versioning](https://semver.org). - Added all examples as shown on the documentation site as a convenience to developers who like to have all information in a single place. +- Added bank holiday for Queen Elizabeth II’s State Funeral on 19 September 2022 to United Kingdom ### Changed diff --git a/src/Yasumi/Provider/UnitedKingdom.php b/src/Yasumi/Provider/UnitedKingdom.php index 9d58ffc73..c5be0ac8b 100644 --- a/src/Yasumi/Provider/UnitedKingdom.php +++ b/src/Yasumi/Provider/UnitedKingdom.php @@ -62,6 +62,7 @@ public function initialize(): void // Add any other holidays $this->calculatePlatinumJubileeBankHoliday(); $this->calculateMotheringSunday(); + $this->calculateQueenElizabethFuneralBankHoliday(); } public function getSources(): array @@ -203,6 +204,33 @@ protected function calculatePlatinumJubileeBankHoliday(): void )); } + /** + * Queen Elizabeth II’s funeral is an extra bank holiday added on 10 September 2022 + * to mark the last day of the period of national mourning. + * + * @see https://www.timeanddate.com/holidays/uk/queen-elizabeth-funeral + * @see https://www.gov.uk/government/news/bank-holiday-announced-for-her-majesty-queen-elizabeth-iis-state-funeral-on-monday-19-september + * + * @throws InvalidDateException + * @throws \InvalidArgumentException + * @throws UnknownLocaleException + * @throws \Exception + */ + protected function calculateQueenElizabethFuneralBankHoliday(): void + { + if (2022 !== $this->year) { + return; + } + + $this->addHoliday(new Holiday( + 'queenElizabethFuneralBankHoliday', + ['en' => 'Queen Elizabeth II’s State Funeral Bank Holiday'], + new DateTime("$this->year-9-19", DateTimeZoneFactory::getDateTimeZone($this->timezone)), + $this->locale, + Holiday::TYPE_BANK + )); + } + /** * Christmas Day is celebrated in the United Kingdom on December 25. It traditionally celebrates Jesus Christ's * birth but many aspects of this holiday have pagan origins. Christmas is a time for many people to give and diff --git a/tests/UnitedKingdom/QueenElizabethFuneralBankHolidayTest.php b/tests/UnitedKingdom/QueenElizabethFuneralBankHolidayTest.php new file mode 100644 index 000000000..7feb30bad --- /dev/null +++ b/tests/UnitedKingdom/QueenElizabethFuneralBankHolidayTest.php @@ -0,0 +1,111 @@ + + */ + +namespace Yasumi\tests\UnitedKingdom; + +use DateTime; +use DateTimeZone; +use Exception; +use Yasumi\Holiday; +use Yasumi\tests\HolidayTestCase; + +/** + * Class for testing the Queen Elizabeth's Funeral Bank Holiday in the United Kingdom. + */ +class QueenElizabethFuneralBankHolidayTest extends UnitedKingdomBaseTestCase implements HolidayTestCase +{ + /** + * The name of the holiday. + */ + public const HOLIDAY = 'queenElizabethFuneralBankHoliday'; + + /** + * The year in which the holiday occurred. + */ + public const ACTIVE_YEAR = 2022; + + /** + * The date on which the holiday occurred. + */ + public const ACTIVE_DATE = '2022-9-19'; + + /** + * Tests the holiday defined in this test. + * + * @throws Exception + */ + public function testHoliday(): void + { + $this->assertHoliday( + self::REGION, + self::HOLIDAY, + self::ACTIVE_YEAR, + new DateTime(self::ACTIVE_DATE, new DateTimeZone(self::TIMEZONE)) + ); + } + + /** + * Tests the holiday defined in this test before the year in which it occurred. + * + * @throws Exception + */ + public function testHolidayBeforeActive(): void + { + $this->assertNotHoliday( + self::REGION, + self::HOLIDAY, + $this->generateRandomYear(1000, self::ACTIVE_YEAR - 1) + ); + } + + /** + * Tests the holiday defined in this test after the year in which it occurred. + * + * @throws Exception + */ + public function testHolidayAfterActive(): void + { + $this->assertNotHoliday( + self::REGION, + self::HOLIDAY, + $this->generateRandomYear(self::ACTIVE_YEAR + 1) + ); + } + + /** + * Tests the translated name of the holiday defined in this test. + */ + public function testTranslation(): void + { + $this->assertTranslatedHolidayName( + self::REGION, + self::HOLIDAY, + self::ACTIVE_YEAR, + [self::LOCALE => 'Queen Elizabeth II’s State Funeral Bank Holiday'] + ); + } + + /** + * Tests type of the holiday defined in this test. + */ + public function testHolidayType(): void + { + $this->assertHolidayType( + self::REGION, + self::HOLIDAY, + self::ACTIVE_YEAR, + Holiday::TYPE_BANK + ); + } +} From dbe90efe04e503636b9da5eceb56da1a6605aa65 Mon Sep 17 00:00:00 2001 From: Sacha Telgenhof Date: Tue, 20 Sep 2022 00:34:25 +0900 Subject: [PATCH 053/142] Have the United Kingdom and its related countries also assert that Queen Elizabeth II funeral is bank holiday. Signed-off-by: Sacha Telgenhof --- tests/UnitedKingdom/England/EnglandTest.php | 12 ++++++++++-- .../NorthernIreland/NorthernIrelandTest.php | 12 ++++++++++-- tests/UnitedKingdom/Scotland/ScotlandTest.php | 12 ++++++++++-- tests/UnitedKingdom/UnitedKingdomTest.php | 12 ++++++++++-- tests/UnitedKingdom/Wales/WalesTest.php | 12 ++++++++++-- 5 files changed, 50 insertions(+), 10 deletions(-) diff --git a/tests/UnitedKingdom/England/EnglandTest.php b/tests/UnitedKingdom/England/EnglandTest.php index 8ee8ca65a..f20eadf28 100644 --- a/tests/UnitedKingdom/England/EnglandTest.php +++ b/tests/UnitedKingdom/England/EnglandTest.php @@ -70,13 +70,21 @@ public function testSeasonalHolidays(): void */ public function testBankHolidays(): void { - $this->assertDefinedHolidays([ + $holidays = [ 'newYearsDay', 'easterMonday', 'mayDayBankHoliday', 'springBankHoliday', 'secondChristmasDay', - ], self::REGION, $this->year, Holiday::TYPE_BANK); + ]; + + $year = $this->generateRandomYear(); + + if (2022 === $year) { + $holidays[] = 'queenElizabethFuneralBankHoliday'; + } + + $this->assertDefinedHolidays($holidays, self::REGION, $year, Holiday::TYPE_BANK); } /** diff --git a/tests/UnitedKingdom/NorthernIreland/NorthernIrelandTest.php b/tests/UnitedKingdom/NorthernIreland/NorthernIrelandTest.php index 025f804a8..d2ac3d724 100644 --- a/tests/UnitedKingdom/NorthernIreland/NorthernIrelandTest.php +++ b/tests/UnitedKingdom/NorthernIreland/NorthernIrelandTest.php @@ -70,14 +70,22 @@ public function testSeasonalHolidays(): void */ public function testBankHolidays(): void { - $this->assertDefinedHolidays([ + $holidays = [ 'newYearsDay', 'easterMonday', 'mayDayBankHoliday', 'springBankHoliday', 'battleOfTheBoyne', 'secondChristmasDay', - ], self::REGION, $this->year, Holiday::TYPE_BANK); + ]; + + $year = $this->generateRandomYear(); + + if (2022 === $year) { + $holidays[] = 'queenElizabethFuneralBankHoliday'; + } + + $this->assertDefinedHolidays($holidays, self::REGION, $year, Holiday::TYPE_BANK); } /** diff --git a/tests/UnitedKingdom/Scotland/ScotlandTest.php b/tests/UnitedKingdom/Scotland/ScotlandTest.php index 49d78a0c1..6eced9236 100644 --- a/tests/UnitedKingdom/Scotland/ScotlandTest.php +++ b/tests/UnitedKingdom/Scotland/ScotlandTest.php @@ -68,14 +68,22 @@ public function testSeasonalHolidays(): void */ public function testBankHolidays(): void { - $this->assertDefinedHolidays([ + $holidays = [ 'goodFriday', 'mayDayBankHoliday', 'springBankHoliday', 'christmasDay', 'secondChristmasDay', 'newYearsDay', - ], self::REGION, $this->year, Holiday::TYPE_BANK); + ]; + + $year = $this->generateRandomYear(); + + if (2022 === $year) { + $holidays[] = 'queenElizabethFuneralBankHoliday'; + } + + $this->assertDefinedHolidays($holidays, self::REGION, $year, Holiday::TYPE_BANK); } /** diff --git a/tests/UnitedKingdom/UnitedKingdomTest.php b/tests/UnitedKingdom/UnitedKingdomTest.php index 4a4a049f3..01fab9e4c 100644 --- a/tests/UnitedKingdom/UnitedKingdomTest.php +++ b/tests/UnitedKingdom/UnitedKingdomTest.php @@ -70,13 +70,21 @@ public function testSeasonalHolidays(): void */ public function testBankHolidays(): void { - $this->assertDefinedHolidays([ + $holidays = [ 'newYearsDay', 'easterMonday', 'mayDayBankHoliday', 'springBankHoliday', 'secondChristmasDay', - ], self::REGION, $this->year, Holiday::TYPE_BANK); + ]; + + $year = $this->generateRandomYear(); + + if (2022 === $year) { + $holidays[] = 'queenElizabethFuneralBankHoliday'; + } + + $this->assertDefinedHolidays($holidays, self::REGION, $year, Holiday::TYPE_BANK); } /** diff --git a/tests/UnitedKingdom/Wales/WalesTest.php b/tests/UnitedKingdom/Wales/WalesTest.php index 3d7b0835e..f25f24872 100644 --- a/tests/UnitedKingdom/Wales/WalesTest.php +++ b/tests/UnitedKingdom/Wales/WalesTest.php @@ -70,13 +70,21 @@ public function testSeasonalHolidays(): void */ public function testBankHolidays(): void { - $this->assertDefinedHolidays([ + $holidays = [ 'newYearsDay', 'easterMonday', 'mayDayBankHoliday', 'springBankHoliday', 'secondChristmasDay', - ], self::REGION, $this->year, Holiday::TYPE_BANK); + ]; + + $year = $this->generateRandomYear(); + + if (2022 === $year) { + $holidays[] = 'queenElizabethFuneralBankHoliday'; + } + + $this->assertDefinedHolidays($holidays, self::REGION, $year, Holiday::TYPE_BANK); } /** From 8ead422eacbd72adf80b5894b1d4f73104d77ee4 Mon Sep 17 00:00:00 2001 From: Sacha Telgenhof Date: Fri, 23 Sep 2022 11:34:10 +0900 Subject: [PATCH 054/142] Fixed tests for New Years Day, Spring Bank Holiday, and May Day Holiday in the United Kingdom (England, Wales, Northern Ireland, and Scotland), as well as Battle of the Boyne in Northern Ireland as these are celebrated only since a particular calendar year. Signed-off-by: Sacha Telgenhof --- CHANGELOG.md | 1 + tests/UnitedKingdom/England/EnglandTest.php | 15 +++++++++++--- .../NorthernIreland/NorthernIrelandTest.php | 20 +++++++++++++++---- tests/UnitedKingdom/Scotland/ScotlandTest.php | 17 ++++++++++++---- tests/UnitedKingdom/UnitedKingdomTest.php | 15 +++++++++++--- tests/UnitedKingdom/Wales/WalesTest.php | 15 +++++++++++--- 6 files changed, 66 insertions(+), 17 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index a2de483a8..5b32297a8 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -19,6 +19,7 @@ to [Semantic Versioning](https://semver.org). ### Fixed +- Tests for New Years Day, Spring Bank Holiday, and May Day Holiday in the United Kingdom (England, Wales, Northern Ireland, and Scotland), as well as Battle of the Boyne in Northern Ireland were considered for any calendar year; however, these are celebrated only since a particular calendar year. - Pentecost Monday in France was only until 2004 recognized as an official holiday. Since 2004 it is considered a special holiday, a so called 'working holiday'. Hence, it is therefore classified as an observed holiday in Yasumi from 2004 and forward. [\#281](https://github.com/azuyalabs/yasumi/issues/281). diff --git a/tests/UnitedKingdom/England/EnglandTest.php b/tests/UnitedKingdom/England/EnglandTest.php index f20eadf28..4c6a5794e 100644 --- a/tests/UnitedKingdom/England/EnglandTest.php +++ b/tests/UnitedKingdom/England/EnglandTest.php @@ -71,15 +71,24 @@ public function testSeasonalHolidays(): void public function testBankHolidays(): void { $holidays = [ - 'newYearsDay', 'easterMonday', - 'mayDayBankHoliday', - 'springBankHoliday', 'secondChristmasDay', ]; $year = $this->generateRandomYear(); + if (1965 >= $this->year) { + $holidays[] = 'springBankHoliday'; + } + + if (1974 > $this->year) { + $holidays[] = 'newYearsDay'; + } + + if (1978 >= $this->year) { + $holidays[] = 'mayDayBankHoliday'; + } + if (2022 === $year) { $holidays[] = 'queenElizabethFuneralBankHoliday'; } diff --git a/tests/UnitedKingdom/NorthernIreland/NorthernIrelandTest.php b/tests/UnitedKingdom/NorthernIreland/NorthernIrelandTest.php index d2ac3d724..44bb4fd1a 100644 --- a/tests/UnitedKingdom/NorthernIreland/NorthernIrelandTest.php +++ b/tests/UnitedKingdom/NorthernIreland/NorthernIrelandTest.php @@ -71,16 +71,28 @@ public function testSeasonalHolidays(): void public function testBankHolidays(): void { $holidays = [ - 'newYearsDay', 'easterMonday', - 'mayDayBankHoliday', - 'springBankHoliday', - 'battleOfTheBoyne', 'secondChristmasDay', ]; $year = $this->generateRandomYear(); + if (1926 >= $this->year) { + $holidays[] = 'battleOfTheBoyne'; + } + + if (1965 >= $this->year) { + $holidays[] = 'springBankHoliday'; + } + + if (1974 > $this->year) { + $holidays[] = 'newYearsDay'; + } + + if (1978 >= $this->year) { + $holidays[] = 'mayDayBankHoliday'; + } + if (2022 === $year) { $holidays[] = 'queenElizabethFuneralBankHoliday'; } diff --git a/tests/UnitedKingdom/Scotland/ScotlandTest.php b/tests/UnitedKingdom/Scotland/ScotlandTest.php index 6eced9236..388c99661 100644 --- a/tests/UnitedKingdom/Scotland/ScotlandTest.php +++ b/tests/UnitedKingdom/Scotland/ScotlandTest.php @@ -69,16 +69,25 @@ public function testSeasonalHolidays(): void public function testBankHolidays(): void { $holidays = [ - 'goodFriday', - 'mayDayBankHoliday', - 'springBankHoliday', 'christmasDay', + 'goodFriday', 'secondChristmasDay', - 'newYearsDay', ]; $year = $this->generateRandomYear(); + if (1965 >= $this->year) { + $holidays[] = 'springBankHoliday'; + } + + if (1974 > $this->year) { + $holidays[] = 'newYearsDay'; + } + + if (1978 >= $this->year) { + $holidays[] = 'mayDayBankHoliday'; + } + if (2022 === $year) { $holidays[] = 'queenElizabethFuneralBankHoliday'; } diff --git a/tests/UnitedKingdom/UnitedKingdomTest.php b/tests/UnitedKingdom/UnitedKingdomTest.php index 01fab9e4c..5fcd2168b 100644 --- a/tests/UnitedKingdom/UnitedKingdomTest.php +++ b/tests/UnitedKingdom/UnitedKingdomTest.php @@ -71,15 +71,24 @@ public function testSeasonalHolidays(): void public function testBankHolidays(): void { $holidays = [ - 'newYearsDay', 'easterMonday', - 'mayDayBankHoliday', - 'springBankHoliday', 'secondChristmasDay', ]; $year = $this->generateRandomYear(); + if (1965 >= $this->year) { + $holidays[] = 'springBankHoliday'; + } + + if (1974 > $this->year) { + $holidays[] = 'newYearsDay'; + } + + if (1978 >= $this->year) { + $holidays[] = 'mayDayBankHoliday'; + } + if (2022 === $year) { $holidays[] = 'queenElizabethFuneralBankHoliday'; } diff --git a/tests/UnitedKingdom/Wales/WalesTest.php b/tests/UnitedKingdom/Wales/WalesTest.php index f25f24872..8f76e419b 100644 --- a/tests/UnitedKingdom/Wales/WalesTest.php +++ b/tests/UnitedKingdom/Wales/WalesTest.php @@ -71,15 +71,24 @@ public function testSeasonalHolidays(): void public function testBankHolidays(): void { $holidays = [ - 'newYearsDay', 'easterMonday', - 'mayDayBankHoliday', - 'springBankHoliday', 'secondChristmasDay', ]; $year = $this->generateRandomYear(); + if (1965 >= $this->year) { + $holidays[] = 'springBankHoliday'; + } + + if (1974 > $this->year) { + $holidays[] = 'newYearsDay'; + } + + if (1978 >= $this->year) { + $holidays[] = 'mayDayBankHoliday'; + } + if (2022 === $year) { $holidays[] = 'queenElizabethFuneralBankHoliday'; } From a03db2e8d36df4578aa0e25307b7afaf5e568fe5 Mon Sep 17 00:00:00 2001 From: Sacha Telgenhof Date: Sat, 24 Sep 2022 21:34:10 +0900 Subject: [PATCH 055/142] Split functions that generate random dates/years into its own trait to slim down the overgrown base trait. Updated inline documentation (syntax, making sentences more succinct). Signed-off-by: Sacha Telgenhof --- tests/Randomizer.php | 459 ++++++++++++++++++++++++++++++++++++++ tests/YasumiBase.php | 509 ++++--------------------------------------- 2 files changed, 500 insertions(+), 468 deletions(-) create mode 100644 tests/Randomizer.php diff --git a/tests/Randomizer.php b/tests/Randomizer.php new file mode 100644 index 000000000..2e58dbf9e --- /dev/null +++ b/tests/Randomizer.php @@ -0,0 +1,459 @@ + + */ + +namespace Yasumi\tests; + +use DateInterval; +use DateTime; +use DateTimeInterface; +use DateTimeZone; +use Exception; +use Yasumi\Holiday; + +/** + * Trait containing useful functions that generate random dates/years. + */ +trait Randomizer +{ + protected static string $defaultTimezone; + + /** + * Returns a list of random test dates used for assertion of holidays. + * + * @param int $month month (number) for which the test date needs to be generated + * @param int $day day (number) for which the test date needs to be generated + * @param string|null $timezone name of the timezone for which the dates need to be generated + * @param int|null $iterations number of iterations (i.e., samples) that need to be generated (default: 10). + * @param int|null $range year range from which dates will be generated (default: 1000) + * + * @return array list of random test dates used for assertion of holidays + * + * @throws Exception + */ + public function generateRandomDates( + int $month, + int $day, + string $timezone = null, + int $iterations = null, + int $range = null + ): array { + $data = []; + $range ??= 1000; + for ($y = 1; $y <= ($iterations ?? 10); ++$y) { + $year = (int) self::dateTimeBetween("-$range years", "+$range years")->format('Y'); + $data[] = [$year, new DateTime("$year-$month-$day", new DateTimeZone($timezone ?? 'UTC'))]; + } + + return $data; + } + + /** + * Returns a list of random easter test dates used for assertion of holidays. + * + * @param string|null $timezone name of the timezone for which the dates need to be generated + * @param int|null $iterations number of iterations (i.e., samples) that need to be generated (default: 10). + * @param int|null $range year range from which dates will be generated (default: 1000) + * + * @return array list of random easter test dates used for assertion of holidays + * + * @throws Exception + */ + public function generateRandomEasterDates( + string $timezone = null, + int $iterations = null, + int $range = null + ): array { + $data = []; + $range ??= 1000; + + for ($i = 1; $i <= ($iterations ?? 10); ++$i) { + $year = (int) self::dateTimeBetween("-$range years", "+$range years")->format('Y'); + $date = $this->calculateEaster($year, $timezone ?? 'UTC'); + + $data[] = [$year, $date->format('Y-m-d')]; + } + + return $data; + } + + /** + * Returns a list of random Easter Monday test dates used for assertion of holidays. + * + * @param string|null $timezone name of the timezone for which the dates need to be generated + * @param int|null $iterations number of iterations (i.e., samples) that need to be generated (default: 10). + * @param int|null $range year range from which dates will be generated (default: 1000) + * + * @return array list of random Easter Monday test dates used for assertion of holidays + * + * @throws Exception + */ + public function generateRandomEasterMondayDates( + string $timezone = null, + int $iterations = null, + int $range = null + ): array { + $range ??= 1000; + + return $this->generateRandomModifiedEasterDates(static function (DateTime $date): void { + $date->add(new DateInterval('P1D')); + }, $timezone ?? 'UTC', $iterations ?? 10, $range); + } + + /** + * Returns a list of random modified Easter day test dates for assertion of holidays. + * + * @param callable $cb callback(DateTime $date) to modify $date by custom rules + * @param string|null $timezone name of the timezone for which the dates need to be generated + * @param int|null $iterations number of iterations (i.e., samples) that need to be generated (default: 10). + * @param int|null $range year range from which dates will be generated (default: 1000) + * + * @return array list of random modified Easter day test dates for assertion of holidays + * + * @throws Exception + */ + public function generateRandomModifiedEasterDates( + callable $cb, + string $timezone = null, + int $iterations = null, + int $range = null + ): array { + $data = []; + $range ??= 1000; + for ($i = 1; $i <= ($iterations ?? 10); ++$i) { + $year = (int) self::dateTimeBetween("-$range years", "+$range years")->format('Y'); + $date = $this->calculateEaster($year, $timezone ?? 'UTC'); + + $cb($date); + + $data[] = [$year, $date->format('Y-m-d')]; + } + + return $data; + } + + /** + * Returns a list of random Good Friday test dates used for assertion of holidays. + * + * @param string|null $timezone name of the timezone for which the dates need to be generated + * @param int|null $iterations number of iterations (i.e., samples) that need to be generated (default: 10). + * @param int|null $range year range from which dates will be generated (default: 1000) + * + * @return array list of random Good Friday test dates used for assertion of holidays + * + * @throws Exception + */ + public function generateRandomGoodFridayDates( + string $timezone = null, + int $iterations = null, + int $range = null + ): array { + $range ??= 1000; + + return $this->generateRandomModifiedEasterDates(static function (DateTime $date): void { + $date->sub(new DateInterval('P2D')); + }, $timezone ?? 'UTC', $iterations ?? 10, $range); + } + + /** + * Returns a list of random Pentecost test dates used for assertion of holidays. + * + * @param string|null $timezone name of the timezone for which the dates need to be generated + * @param int|null $iterations number of iterations (i.e., samples) that need to be generated (default: 10). + * @param int|null $range year range from which dates will be generated (default: 1000) + * + * @return array list of random Pentecost test dates used for assertion of holidays + * + * @throws Exception + */ + public function generateRandomPentecostDates( + string $timezone = null, + int $iterations = null, + int $range = null + ): array { + $range ??= 1000; + + return $this->generateRandomModifiedEasterDates(static function (DateTime $date): void { + $date->add(new DateInterval('P49D')); + }, $timezone ?? 'UTC', $iterations ?? 10, $range); + } + + /** + * Returns a list of random test dates used for assertion of holidays. If the date falls in a weekend, the random + * holiday day moves to Monday. + * + * @param int $month month (number) for which the test date needs to be generated + * @param int $day day (number) for which the test date needs to be generated + * @param string|null $timezone name of the timezone for which the dates need to be generated + * @param int|null $iterations number of iterations (i.e., samples) that need to be generated (default: 10). + * @param int|null $range year range from which dates will be generated (default: 1000) + * + * @return array list of random test dates used for assertion of holidays + * + * @throws Exception + */ + public function generateRandomDatesWithHolidayMovedToMonday( + int $month, + int $day, + string $timezone = null, + int $iterations = null, + int $range = null + ): array { + return $this->generateRandomDatesWithModifier($month, $day, function ($range, DateTime $date): void { + if ($this->isWeekend($date)) { + $date->modify('next monday'); + } + }, $iterations ?? 10, $range, $timezone ?? 'UTC'); + } + + /** + * Returns a list of random test dates used for assertion of holidays with an applied callback. + * + * @param int $month month (number) for which the test date needs to be generated + * @param int $day day (number) for which the test date needs to be generated + * @param callable $callback callback(int $year, \DateTime $dateTime) to modify $dateTime by custom rules + * @param int $iterations number of iterations (i.e., samples) that need to be generated (default: 10). + * @param int $range year range from which dates will be generated (default: 1000) + * @param string|null $timezone name of the timezone for which the dates need to be generated + * + * @return array list of random test dates used for assertion of holidays with an applied callback + * + * @throws Exception + */ + public function generateRandomDatesWithModifier( + int $month, + int $day, + callable $callback, + int $iterations, + int $range, + string $timezone = null + ): array { + $data = []; + + for ($i = 1; $i <= $iterations; ++$i) { + $year = $this->generateRandomYear($range); + $date = new DateTime("$year-$month-$day", new DateTimeZone($timezone ?? 'UTC')); + + $callback($year, $date); + + $data[] = [$year, $date->format('Y-m-d')]; + } + + return $data; + } + + /** + * Generates a random year (number). + * + * @param int|null $lowerLimit lower limit for generating a year number (default: 1000) + * @param int|null $upperLimit upper limit for generating a year number (default: 9999) + * + * @return int a year number + * + * @throws Exception + */ + public function generateRandomYear( + int $lowerLimit = null, + int $upperLimit = null + ): int { + return self::numberBetween($lowerLimit ?? 1000, $upperLimit ?? 9999); + } + + /** + * Checks if given $dateTime is a weekend. + * + * @param DateTimeInterface $dateTime date for which weekend will be checked + * @param array $weekendDays weekend days. Saturday and Sunday are used by default. + * + * @return bool true if $dateTime is a weekend, false otherwise + */ + public function isWeekend( + DateTimeInterface $dateTime, + array $weekendDays = [0, 6] + ): bool { + return \in_array((int) $dateTime->format('w'), $weekendDays, true); + } + + /** + * Returns a random number between $int1 and $int2 (any order). + * + * @throws Exception + * + * @example 79907610 + */ + public static function numberBetween(int $int1 = 0, int $int2 = 2_147_483_647): int + { + $min = min($int1, $int2); + $max = max($int1, $int2); + + return random_int($min, $max); + } + + /** + * Get a DateTime object based on a random date between two given dates. + * Accepts date strings that can be recognized by `strtotime`. + * + * @param \DateTime|string $startDate Defaults to 30 years ago + * @param \DateTime|string $endDate Defaults to "now" + * @param string|null $timezone time zone in which the date time should be set, default to DateTime::$defaultTimezone, if set, otherwise the result of `date_default_timezone_get` + * + * @throws Exception + * + * @see http://php.net/manual/en/timezones.php + * @see http://php.net/manual/en/function.date-default-timezone-get.php + * + * @example DateTime('1999-02-02 11:42:52') + */ + public static function dateTimeBetween($startDate = '-30 years', $endDate = 'now', $timezone = null): DateTimeInterface + { + $startTimestamp = $startDate instanceof \DateTime ? $startDate->getTimestamp() : strtotime($startDate); + + if (!$startTimestamp) { + throw new \RuntimeException('unable to get timestamp for the start date'); + } + + $endTimestamp = static::getMaxTimestamp($endDate); + + if (!$endTimestamp) { + throw new \RuntimeException('unable to get timestamp for the end date'); + } + + if ($startTimestamp > $endTimestamp) { + throw new \InvalidArgumentException('Start date must be anterior to end date.'); + } + + $timestamp = random_int($startTimestamp, $endTimestamp); + + return static::setTimezone( + new \DateTime('@'.$timestamp), + $timezone + ); + } + + public function randomYearFromArray(array $years): int + { + if ([] === $years) { + throw new \InvalidArgumentException(' years array must not be empty'); + } + + return $years[(int) array_rand($years)]; + } + + /** + * Calculates the date for Easter. + * + * Easter is a festival and holiday celebrating the resurrection of Jesus Christ from the dead. Easter is celebrated + * on a date based on a certain number of days after March 21st. + * + * This function uses the standard PHP 'easter_days' function if the calendar extension is enabled. In case the + * calendar function is not enabled, a fallback calculation has been implemented that is based on the same + * 'easter_days' c function. + * + * Note: In calendrical calculations, frequently operations called integer division are used. + * + * @param int $year year for which Easter needs to be calculated + * @param string $timezone timezone in which Easter is celebrated + * + * @return DateTime date of Easter + * + * @throws Exception + * + * @see easter_days + * @see https://github.com/php/php-src/blob/c8aa6f3a9a3d2c114d0c5e0c9fdd0a465dbb54a5/ext/calendar/easter.c + * @see http://www.gmarts.org/index.php?go=415#EasterMallen + * @see http://www.tondering.dk/claus/cal/easter.php + */ + protected function calculateEaster(int $year, string $timezone): DateTimeInterface + { + if (\extension_loaded('calendar')) { + $easter_days = easter_days($year); + } else { + $golden = (($year % 19) + 1); // The Golden Number + + // The Julian calendar applies to the original method from 326AD. The Gregorian calendar was first + // introduced in October 1582 in Italy. Easter algorithms using the Gregorian calendar apply to years + // 1583 AD to 4099 (A day adjustment is required in or shortly after 4100 AD). + // After 1752, most western churches have adopted the current algorithm. + if ($year <= 1752) { + $dom = ($year + (int) ($year / 4) + 5) % 7; // The 'Dominical number' - finding a Sunday + if ($dom < 0) { + $dom += 7; + } + + $pfm = (3 - (11 * $golden) - 7) % 30; // Uncorrected date of the Paschal full moon + if ($pfm < 0) { + $pfm += 30; + } + } else { + $dom = ($year + (int) ($year / 4) - (int) ($year / 100) + (int) ($year / 400)) % 7; // The 'Dominical number' - finding a Sunday + if ($dom < 0) { + $dom += 7; + } + + $solar = (int) (($year - 1600) / 100) - (int) (($year - 1600) / 400); // The solar correction + $lunar = (int) (((int) (($year - 1400) / 100) * 8) / 25); // The lunar correction + + $pfm = (3 - (11 * $golden) + $solar - $lunar) % 30; // Uncorrected date of the Paschal full moon + if ($pfm < 0) { + $pfm += 30; + } + } + + // Corrected date of the Paschal full moon, - days after 21st March + if ((29 === $pfm) || (28 === $pfm && $golden > 11)) { + --$pfm; + } + + $tmp = (4 - $pfm - $dom) % 7; + if ($tmp < 0) { + $tmp += 7; + } + + $easter_days = ($pfm + $tmp + 1); // Easter as the number of days after 21st March + } + + $easter = new DateTime("$year-3-21", new DateTimeZone($timezone)); + $easter->add(new DateInterval('P'.$easter_days.'D')); + + return $easter; + } + + /** + * @param \DateTime|string|float|int $max + * + * @return int|false + */ + protected static function getMaxTimestamp($max = 'now') + { + if (is_numeric($max)) { + $ts = (int) $max; + } elseif ($max instanceof \DateTime) { + $ts = $max->getTimestamp(); + } else { + $ts = strtotime(empty($max) ? 'now' : $max); + } + + return $ts; + } + + private static function setTimezone(DateTimeInterface $dt, ?string $timezone): DateTimeInterface + { + return $dt->setTimezone(new \DateTimeZone(static::resolveTimezone($timezone))); + } + + private static function resolveTimezone(?string $timezone): string + { + return $timezone ?? (static::$defaultTimezone ?? date_default_timezone_get()); + } +} diff --git a/tests/YasumiBase.php b/tests/YasumiBase.php index f186459b4..c1cac43fd 100644 --- a/tests/YasumiBase.php +++ b/tests/YasumiBase.php @@ -1,6 +1,7 @@ $expectedHolidays list of all known holidays of the given provider - * @param string $provider the holiday provider (i.e. country/state) for which the holidays need to be - * tested + * @param string $provider holiday provider (i.e. country/state) for which the holidays need to be + * tested. * @param int $year holiday calendar year - * @param string $type The type of holiday. Use the following constants: TYPE_OFFICIAL, + * @param string $type type of holiday. Use the following constants: TYPE_OFFICIAL, * TYPE_OBSERVANCE, TYPE_SEASON, TYPE_BANK or TYPE_OTHER. * * @throws InvalidArgumentException @@ -82,19 +79,19 @@ public function assertDefinedHolidays( break; } - // Loop through all known holidays and assert they are defined by the provider class + // Loop through all known holidays and assert they are defined by the provider class. foreach ($expectedHolidays as $holiday) { self::assertArrayHasKey($holiday, iterator_to_array($holidays)); } } /** - * Asserts that the expected date is indeed a holiday for that given year and name. + * Asserts expected date is a holiday for the given year and name. * - * @param string $provider the holiday provider (i.e. country/state) for which the holiday need to be tested - * @param string $key string the key of the holiday to be checked against + * @param string $provider holiday provider (i.e. country/state) for which the holiday need to be tested. + * @param string $key key of the holiday to be checked against * @param int $year holiday calendar year - * @param DateTime $expected the date to be checked against + * @param DateTime $expected date to be checked against * * @throws UnknownLocaleException * @throws InvalidDateException @@ -117,12 +114,12 @@ public function assertHoliday( } /** - * Asserts that the expected date is indeed a substitute holiday for that given year and name. + * Asserts the expected date is a substitute holiday for that given year and name. * - * @param string $provider the holiday provider (i.e. country/state) for which the holiday need to be tested - * @param string $key string the key of the substituted holiday to be checked against + * @param string $provider the holiday provider (i.e. country/state) for which the holiday need to be tested. + * @param string $key key of the substituted holiday to be checked against * @param int $year holiday calendar year - * @param DateTime $expected the date to be checked against + * @param DateTime $expected date to be checked against * * @throws UnknownLocaleException * @throws InvalidDateException @@ -145,10 +142,10 @@ public function assertSubstituteHoliday( } /** - * Asserts that the given substitute holiday for that given year does not exist. + * Asserts the given substitute holiday for a given year does not exist. * - * @param string $provider the holiday provider (i.e. country/state) for which the holiday need to be tested - * @param string $key the key of the substituted holiday to be checked against + * @param string $provider holiday provider (i.e. country/state) for which the holiday need to be tested. + * @param string $key key of the substituted holiday to be checked against * @param int $year holiday calendar year * * @throws InvalidArgumentException @@ -170,10 +167,10 @@ public function assertNotSubstituteHoliday( } /** - * Asserts that the given holiday for that given year does not exist. + * Asserts the given holiday for a given year does not exist. * - * @param string $provider the holiday provider (i.e. country/state) for which the holiday need to be tested - * @param string $key the key of the holiday to be checked against + * @param string $provider holiday provider (i.e. country/state) for which the holiday need to be tested. + * @param string $key key of the holiday to be checked against * @param int $year holiday calendar year * * @throws InvalidArgumentException @@ -194,12 +191,12 @@ public function assertNotHoliday( } /** - * Asserts that the expected name is indeed provided as a translated holiday name for that given year and name. + * Asserts the expected name is provided as a translated holiday name for that given year and name. * - * @param string $provider the holiday provider (i.e. country/state) for which the holiday need to be tested - * @param string $key string the key of the holiday to be checked against + * @param string $provider holiday provider (i.e. country/state) for which the holiday need to be tested. + * @param string $key key of the holiday to be checked against * @param int $year holiday calendar year - * @param array $translations the translations to be checked against + * @param array $translations translations to be checked against * * @throws InvalidArgumentException * @throws RuntimeException @@ -215,8 +212,8 @@ public function assertTranslatedHolidayName( $holidays = Yasumi::create($provider, $year); $holiday = $holidays->getHoliday($key); - self::assertInstanceOf(Holiday::class, $holiday); - self::assertTrue($holidays->isHoliday($holiday)); + self::assertInstanceOf(Holiday::class, $holiday, sprintf('No instance for the year `%u`', $year)); + self::assertTrue($holidays->isHoliday($holiday), sprintf('Holiday `%s` not defined for the year `%u`', $key, $year)); foreach ($translations as $locale => $name) { $locales = [$locale]; @@ -239,12 +236,12 @@ public function assertTranslatedHolidayName( } /** - * Asserts that the expected type is indeed the associated type of the given holiday. + * Asserts the expected type is the associated type for the given holiday. * - * @param string $provider the holiday provider (i.e. country/region) for which the holiday need to be tested - * @param string $key string the key of the holiday to be checked against + * @param string $provider holiday provider (i.e. country/region) for which the holiday need to be tested. + * @param string $key the key of the holiday to be checked against * @param int $year holiday calendar year - * @param string $type the type to be checked against + * @param string $type type to be checked against * * @throws InvalidArgumentException * @throws RuntimeException @@ -260,18 +257,17 @@ public function assertHolidayType( $holidays = Yasumi::create($provider, $year); $holiday = $holidays->getHoliday($key); - self::assertInstanceOf(Holiday::class, $holiday); - self::assertEquals($type, $holiday->getType()); + self::assertInstanceOf(Holiday::class, $holiday, sprintf('No instance for the year `%u`', $year)); + self::assertEquals($type, $holiday->getType(), sprintf('Expected type `%s`, got `%s` for the year `%u`', $type, $holiday->getType(), $year)); } /** - * Asserts that the expected week day is indeed the week day for the given holiday and year. + * Asserts the expected week day is the week day for the given holiday and year. * - * @param string $provider the holiday provider (i.e. country/state) for which the holiday need to be - * tested - * @param string $key string the key of the holiday to be checked against + * @param string $provider holiday provider (i.e. country/state) for which the holiday need to be tested. + * @param string $key key of the holiday to be checked against * @param int $year holiday calendar year - * @param string $expectedDayOfWeek the expected week day (i.e. "Saturday", "Sunday", etc.) + * @param string $expectedDayOfWeek expected week day (i.e. "Saturday", "Sunday", etc.). * * @throws AssertionFailedError * @throws InvalidArgumentException @@ -293,11 +289,10 @@ public function assertDayOfWeek( } /** - * Asserts that the holiday provider has the number of expected sources defined. + * Asserts the holiday provider has the expected sources number. * - * @param string $provider the holiday provider (i.e. country/state) for which the holiday need to be - * tested - * @param int $expectedSourceCount the expected number of sources + * @param string $provider holiday provider (i.e. country/state) for which the holiday need to be tested. + * @param int $expectedSourceCount expected sources number * * @throws Exception */ @@ -307,426 +302,4 @@ public function assertSources(string $provider, int $expectedSourceCount): void self::assertCount($expectedSourceCount, $holidayProvider->getSources()); } - - /** - * Returns a list of random test dates used for assertion of holidays. - * - * @param int $month month (number) for which the test date needs to be generated - * @param int $day day (number) for which the test date needs to be generated - * @param string|null $timezone name of the timezone for which the dates need to be generated - * @param int|null $iterations number of iterations (i.e. samples) that need to be generated (default: 10) - * @param int|null $range year range from which dates will be generated (default: 1000) - * - * @return array list of random test dates used for assertion of holidays - * - * @throws Exception - */ - public function generateRandomDates( - int $month, - int $day, - string $timezone = null, - int $iterations = null, - int $range = null - ): array { - $data = []; - $range ??= 1000; - for ($y = 1; $y <= ($iterations ?? 10); ++$y) { - $year = (int) self::dateTimeBetween("-$range years", "+$range years")->format('Y'); - $data[] = [$year, new DateTime("$year-$month-$day", new DateTimeZone($timezone ?? 'UTC'))]; - } - - return $data; - } - - /** - * Returns a list of random easter test dates used for assertion of holidays. - * - * @param string|null $timezone name of the timezone for which the dates need to be generated - * @param int|null $iterations number of iterations (i.e. samples) that need to be generated (default: 10) - * @param int|null $range year range from which dates will be generated (default: 1000) - * - * @return array list of random easter test dates used for assertion of holidays - * - * @throws Exception - */ - public function generateRandomEasterDates( - string $timezone = null, - int $iterations = null, - int $range = null - ): array { - $data = []; - $range ??= 1000; - - for ($i = 1; $i <= ($iterations ?? 10); ++$i) { - $year = (int) self::dateTimeBetween("-$range years", "+$range years")->format('Y'); - $date = $this->calculateEaster($year, $timezone ?? 'UTC'); - - $data[] = [$year, $date->format('Y-m-d')]; - } - - return $data; - } - - /** - * Returns a list of random Easter Monday test dates used for assertion of holidays. - * - * @param string|null $timezone name of the timezone for which the dates need to be generated - * @param int|null $iterations number of iterations (i.e. samples) that need to be generated (default: 10) - * @param int|null $range year range from which dates will be generated (default: 1000) - * - * @return array list of random Easter Monday test dates used for assertion of holidays - * - * @throws Exception - */ - public function generateRandomEasterMondayDates( - string $timezone = null, - int $iterations = null, - int $range = null - ): array { - $range ??= 1000; - - return $this->generateRandomModifiedEasterDates(static function (DateTime $date): void { - $date->add(new DateInterval('P1D')); - }, $timezone ?? 'UTC', $iterations ?? 10, $range); - } - - /** - * Returns a list of random modified Easter day test dates for assertion of holidays. - * - * @param callable $cb callback(DateTime $date) to modify $date by custom rules - * @param string|null $timezone name of the timezone for which the dates need to be generated - * @param int|null $iterations number of iterations (i.e. samples) that need to be generated (default: 10) - * @param int|null $range year range from which dates will be generated (default: 1000) - * - * @return array list of random modified Easter day test dates for assertion of holidays - * - * @throws Exception - */ - public function generateRandomModifiedEasterDates( - callable $cb, - string $timezone = null, - int $iterations = null, - int $range = null - ): array { - $data = []; - $range ??= 1000; - for ($i = 1; $i <= ($iterations ?? 10); ++$i) { - $year = (int) self::dateTimeBetween("-$range years", "+$range years")->format('Y'); - $date = $this->calculateEaster($year, $timezone ?? 'UTC'); - - $cb($date); - - $data[] = [$year, $date->format('Y-m-d')]; - } - - return $data; - } - - /** - * Returns a list of random Good Friday test dates used for assertion of holidays. - * - * @param string|null $timezone name of the timezone for which the dates need to be generated - * @param int|null $iterations number of iterations (i.e. samples) that need to be generated (default: 10) - * @param int|null $range year range from which dates will be generated (default: 1000) - * - * @return array list of random Good Friday test dates used for assertion of holidays - * - * @throws Exception - */ - public function generateRandomGoodFridayDates( - string $timezone = null, - int $iterations = null, - int $range = null - ): array { - $range ??= 1000; - - return $this->generateRandomModifiedEasterDates(static function (DateTime $date): void { - $date->sub(new DateInterval('P2D')); - }, $timezone ?? 'UTC', $iterations ?? 10, $range); - } - - /** - * Returns a list of random Pentecost test dates used for assertion of holidays. - * - * @param string|null $timezone name of the timezone for which the dates need to be generated - * @param int|null $iterations number of iterations (i.e. samples) that need to be generated (default: 10) - * @param int|null $range year range from which dates will be generated (default: 1000) - * - * @return array list of random Pentecost test dates used for assertion of holidays - * - * @throws Exception - */ - public function generateRandomPentecostDates( - string $timezone = null, - int $iterations = null, - int $range = null - ): array { - $range ??= 1000; - - return $this->generateRandomModifiedEasterDates(static function (DateTime $date): void { - $date->add(new DateInterval('P49D')); - }, $timezone ?? 'UTC', $iterations ?? 10, $range); - } - - /** - * Returns a list of random test dates used for assertion of holidays. If the date falls in a weekend, random - * holiday day is moved to to Monday. - * - * @param int $month month (number) for which the test date needs to be generated - * @param int $day day (number) for which the test date needs to be generated - * @param string|null $timezone name of the timezone for which the dates need to be generated - * @param int|null $iterations number of iterations (i.e. samples) that need to be generated (default: 10) - * @param int|null $range year range from which dates will be generated (default: 1000) - * - * @return array list of random test dates used for assertion of holidays - * - * @throws Exception - */ - public function generateRandomDatesWithHolidayMovedToMonday( - int $month, - int $day, - string $timezone = null, - int $iterations = null, - int $range = null - ): array { - return $this->generateRandomDatesWithModifier($month, $day, function ($range, DateTime $date): void { - if ($this->isWeekend($date)) { - $date->modify('next monday'); - } - }, $iterations ?? 10, $range, $timezone ?? 'UTC'); - } - - /** - * Returns a list of random test dates used for assertion of holidays with applied callback. - * - * @param int $month month (number) for which the test date needs to be generated - * @param int $day day (number) for which the test date needs to be generated - * @param callable $callback callback(int $year, \DateTime $dateTime) to modify $dateTime by custom rules - * @param int $iterations number of iterations (i.e. samples) that need to be generated (default: 10) - * @param int $range year range from which dates will be generated (default: 1000) - * @param string|null $timezone name of the timezone for which the dates need to be generated - * - * @return array list of random test dates used for assertion of holidays with applied callback - * - * @throws Exception - */ - public function generateRandomDatesWithModifier( - int $month, - int $day, - callable $callback, - int $iterations, - int $range, - string $timezone = null - ): array { - $data = []; - - for ($i = 1; $i <= $iterations; ++$i) { - $year = $this->generateRandomYear($range); - $date = new DateTime("$year-$month-$day", new DateTimeZone($timezone ?? 'UTC')); - - $callback($year, $date); - - $data[] = [$year, $date->format('Y-m-d')]; - } - - return $data; - } - - /** - * Generates a random year (number). - * - * @param int|null $lowerLimit the lower limit for generating a year number (default: 1000) - * @param int|null $upperLimit the upper limit for generating a year number (default: 9999) - * - * @return int a year number - * - * @throws Exception - */ - public function generateRandomYear( - int $lowerLimit = null, - int $upperLimit = null - ): int { - return self::numberBetween($lowerLimit ?? 1000, $upperLimit ?? 9999); - } - - /** - * Checks if given $dateTime is a weekend. - * - * @param DateTimeInterface $dateTime date for which weekend will be checked - * @param array $weekendDays weekend days. Saturday and Sunday are used by default. - * - * @return bool true if $dateTime is a weekend, false otherwise - */ - public function isWeekend( - DateTimeInterface $dateTime, - array $weekendDays = [0, 6] - ): bool { - return \in_array((int) $dateTime->format('w'), $weekendDays, true); - } - - /** - * Returns a random number between $int1 and $int2 (any order). - * - * @throws Exception - * - * @example 79907610 - */ - public static function numberBetween(int $int1 = 0, int $int2 = 2_147_483_647): int - { - $min = $int1 < $int2 ? $int1 : $int2; - $max = $int1 < $int2 ? $int2 : $int1; - - return random_int($min, $max); - } - - /** - * Get a DateTime object based on a random date between two given dates. - * Accepts date strings that can be recognized by strtotime(). - * - * @param \DateTime|string $startDate Defaults to 30 years ago - * @param \DateTime|string $endDate Defaults to "now" - * @param string|null $timezone time zone in which the date time should be set, default to DateTime::$defaultTimezone, if set, otherwise the result of `date_default_timezone_get` - * - * @throws Exception - * - * @see http://php.net/manual/en/timezones.php - * @see http://php.net/manual/en/function.date-default-timezone-get.php - * - * @example DateTime('1999-02-02 11:42:52') - */ - public static function dateTimeBetween($startDate = '-30 years', $endDate = 'now', $timezone = null): DateTimeInterface - { - $startTimestamp = $startDate instanceof \DateTime ? $startDate->getTimestamp() : strtotime($startDate); - - if (!$startTimestamp) { - throw new \RuntimeException('unable to get timestamp for the start date'); - } - - $endTimestamp = static::getMaxTimestamp($endDate); - - if (!$endTimestamp) { - throw new \RuntimeException('unable to get timestamp for the end date'); - } - - if ($startTimestamp > $endTimestamp) { - throw new \InvalidArgumentException('Start date must be anterior to end date.'); - } - - $timestamp = random_int($startTimestamp, $endTimestamp); - - return static::setTimezone( - new \DateTime('@'.$timestamp), - $timezone - ); - } - - /** - * Calculates the date for Easter. - * - * Easter is a festival and holiday celebrating the resurrection of Jesus Christ from the dead. Easter is celebrated - * on a date based on a certain number of days after March 21st. - * - * This function uses the standard PHP 'easter_days' function if the calendar extension is enabled. In case the - * calendar function is not enabled, a fallback calculation has been implemented that is based on the same - * 'easter_days' c function. - * - * Note: In calendrical calculations, frequently operations called integer division are used. - * - * @param int $year the year for which Easter needs to be calculated - * @param string $timezone the timezone in which Easter is celebrated - * - * @return DateTime date of Easter - * - * @throws Exception - * - * @see easter_days - * @see https://github.com/php/php-src/blob/c8aa6f3a9a3d2c114d0c5e0c9fdd0a465dbb54a5/ext/calendar/easter.c - * @see http://www.gmarts.org/index.php?go=415#EasterMallen - * @see http://www.tondering.dk/claus/cal/easter.php - */ - protected function calculateEaster(int $year, string $timezone): DateTimeInterface - { - if (\extension_loaded('calendar')) { - $easter_days = easter_days($year); - } else { - $golden = (($year % 19) + 1); // The Golden Number - - // The Julian calendar applies to the original method from 326AD. The Gregorian calendar was first - // introduced in October 1582 in Italy. Easter algorithms using the Gregorian calendar apply to years - // 1583 AD to 4099 (A day adjustment is required in or shortly after 4100 AD). - // After 1752, most western churches have adopted the current algorithm. - if ($year <= 1752) { - $dom = ($year + (int) ($year / 4) + 5) % 7; // The 'Dominical number' - finding a Sunday - if ($dom < 0) { - $dom += 7; - } - - $pfm = (3 - (11 * $golden) - 7) % 30; // Uncorrected date of the Paschal full moon - if ($pfm < 0) { - $pfm += 30; - } - } else { - $dom = ($year + (int) ($year / 4) - (int) ($year / 100) + (int) ($year / 400)) % 7; // The 'Dominical number' - finding a Sunday - if ($dom < 0) { - $dom += 7; - } - - $solar = (int) (($year - 1600) / 100) - (int) (($year - 1600) / 400); // The solar correction - $lunar = (int) (((int) (($year - 1400) / 100) * 8) / 25); // The lunar correction - - $pfm = (3 - (11 * $golden) + $solar - $lunar) % 30; // Uncorrected date of the Paschal full moon - if ($pfm < 0) { - $pfm += 30; - } - } - - // Corrected date of the Paschal full moon, - days after 21st March - if ((29 === $pfm) || (28 === $pfm && $golden > 11)) { - --$pfm; - } - - $tmp = (4 - $pfm - $dom) % 7; - if ($tmp < 0) { - $tmp += 7; - } - - $easter_days = ($pfm + $tmp + 1); // Easter as the number of days after 21st March - } - - $easter = new DateTime("$year-3-21", new DateTimeZone($timezone)); - $easter->add(new DateInterval('P'.$easter_days.'D')); - - return $easter; - } - - /** - * @param \DateTime|string|float|int $max - * - * @return int|false - */ - protected static function getMaxTimestamp($max = 'now') - { - if (is_numeric($max)) { - $ts = (int) $max; - } elseif ($max instanceof \DateTime) { - $ts = $max->getTimestamp(); - } else { - $ts = strtotime(empty($max) ? 'now' : $max); - } - - return $ts; - } - - /** - * Internal method to set the time zone on a DateTime. - */ - private static function setTimezone(DateTimeInterface $dt, ?string $timezone): DateTimeInterface - { - return $dt->setTimezone(new \DateTimeZone(static::resolveTimezone($timezone))); - } - - private static function resolveTimezone(?string $timezone): string - { - return $timezone ?? (static::$defaultTimezone ?? date_default_timezone_get()); - } } From 2f750162c6a210a9b77d68d0d3e981afa9ca5713 Mon Sep 17 00:00:00 2001 From: Sacha Telgenhof Date: Sat, 24 Sep 2022 23:47:52 +0900 Subject: [PATCH 056/142] Refactored summer and winter time tests for Denmark and The Netherlands by introducing a base class holding the domain logic. Signed-off-by: Sacha Telgenhof --- tests/Denmark/DaylightSavingTime.php | 39 ++++++++++++++++++++ tests/Denmark/SummerTimeTest.php | 47 +++++++++++++++++++----- tests/Denmark/WinterTimeTest.php | 30 +++++++++++---- tests/Netherlands/DaylightSavingTime.php | 39 ++++++++++++++++++++ tests/Netherlands/SummertimeTest.php | 31 +++++++++++----- tests/Netherlands/WintertimeTest.php | 28 ++++++++++---- 6 files changed, 180 insertions(+), 34 deletions(-) create mode 100644 tests/Denmark/DaylightSavingTime.php create mode 100644 tests/Netherlands/DaylightSavingTime.php diff --git a/tests/Denmark/DaylightSavingTime.php b/tests/Denmark/DaylightSavingTime.php new file mode 100644 index 000000000..af2317281 --- /dev/null +++ b/tests/Denmark/DaylightSavingTime.php @@ -0,0 +1,39 @@ + + */ + +namespace Yasumi\tests\Denmark; + +use Yasumi\tests\HolidayTestCase; + +abstract class DaylightSavingTime extends DenmarkBaseTestCase implements HolidayTestCase +{ + /** @var int[] */ + public array $observedYears; + + /** @var int[] */ + public array $unobservedYears; + + public function __construct() + { + $observedYears = [1916, 1940]; + $observedYears = array_merge($observedYears, range(1942, 1948)); + $observedYears = array_merge($observedYears, range(1980, 2037)); // PHP caps future DST transitions + + $this->observedYears = $observedYears; + $this->unobservedYears = array_diff(range(reset($observedYears), end($observedYears)), $observedYears); + + parent::__construct(); + } +} diff --git a/tests/Denmark/SummerTimeTest.php b/tests/Denmark/SummerTimeTest.php index dbdb66c95..e15cd9ae5 100644 --- a/tests/Denmark/SummerTimeTest.php +++ b/tests/Denmark/SummerTimeTest.php @@ -1,6 +1,7 @@ '1916-05-14', + 1940 => '1940-05-14', + 1943 => '1943-03-29', + 1944 => '1944-04-03', + 1945 => '1945-04-02', + 1946 => '1946-05-01', + 1947 => '1947-05-04', + 1948 => '1948-05-09', + ]; + + public function __construct() + { + parent::__construct(); + + // no summertime defined for 1942 + if (false !== ($key = array_search(1942, $this->observedYears, true))) { + unset($this->observedYears[(int) $key]); + } + } + /** * Tests the holiday defined in this test. * @@ -37,11 +58,15 @@ class SummerTimeTest extends DenmarkBaseTestCase implements HolidayTestCase */ public function testSummerTime(): void { - $this->assertNotHoliday(self::REGION, self::HOLIDAY, $this->generateRandomYear(1949, 1979)); + $this->assertNotHoliday(self::REGION, self::HOLIDAY, $this->randomYearFromArray($this->unobservedYears)); - $year = $this->generateRandomYear(1980, 2036); + $year = $this->randomYearFromArray($this->observedYears); $expectedDate = new DateTime("last sunday of march $year", new DateTimeZone(self::TIMEZONE)); + if (array_key_exists($year, $this->deviantTransitions)) { + $expectedDate = new DateTime($this->deviantTransitions[$year], new DateTimeZone(self::TIMEZONE)); + } + // Since 1980 Summertime in Denmark starts on the last day of March. In 1980 itself however, it started on April, 6th. if (1980 === $year) { $expectedDate = new DateTime('1980-04-06', new DateTimeZone(self::TIMEZONE)); @@ -65,7 +90,7 @@ public function testTranslation(): void $this->assertTranslatedHolidayName( self::REGION, self::HOLIDAY, - $this->generateRandomYear(1980, 2037), + $this->randomYearFromArray($this->observedYears), [self::LOCALE => 'sommertid starter'] ); } @@ -77,6 +102,10 @@ public function testTranslation(): void */ public function testHolidayType(): void { - $this->assertHolidayType(self::REGION, self::HOLIDAY, $this->generateRandomYear(1980, 2037), Holiday::TYPE_SEASON); + $this->assertHolidayType( + self::REGION, self::HOLIDAY, + $this->randomYearFromArray($this->observedYears), + Holiday::TYPE_SEASON + ); } } diff --git a/tests/Denmark/WinterTimeTest.php b/tests/Denmark/WinterTimeTest.php index 01fe35ad1..872efcf81 100644 --- a/tests/Denmark/WinterTimeTest.php +++ b/tests/Denmark/WinterTimeTest.php @@ -1,6 +1,7 @@ observedYears, true))) { + unset($this->observedYears[(int) $key]); + } + } + /** * Tests the holiday defined in this test. * @@ -37,7 +47,7 @@ class WinterTimeTest extends DenmarkBaseTestCase implements HolidayTestCase */ public function testWinterTime(): void { - $this->assertNotHoliday(self::REGION, self::HOLIDAY, $this->generateRandomYear(1949, 1979)); + $this->assertNotHoliday(self::REGION, self::HOLIDAY, $this->randomYearFromArray($this->unobservedYears)); $year = $this->generateRandomYear(1980, 1995); $this->assertHoliday( @@ -66,7 +76,7 @@ public function testTranslation(): void $this->assertTranslatedHolidayName( self::REGION, self::HOLIDAY, - $this->generateRandomYear(1980, 2037), + $this->randomYearFromArray($this->observedYears), [self::LOCALE => 'sommertid slutter'] ); } @@ -78,6 +88,10 @@ public function testTranslation(): void */ public function testHolidayType(): void { - $this->assertHolidayType(self::REGION, self::HOLIDAY, $this->generateRandomYear(1980, 2037), Holiday::TYPE_SEASON); + $this->assertHolidayType( + self::REGION, self::HOLIDAY, + $this->randomYearFromArray($this->observedYears), + Holiday::TYPE_SEASON + ); } } diff --git a/tests/Netherlands/DaylightSavingTime.php b/tests/Netherlands/DaylightSavingTime.php new file mode 100644 index 000000000..a9f552509 --- /dev/null +++ b/tests/Netherlands/DaylightSavingTime.php @@ -0,0 +1,39 @@ + + */ + +namespace Yasumi\tests\Netherlands; + +use Yasumi\tests\HolidayTestCase; + +abstract class DaylightSavingTime extends NetherlandsBaseTestCase implements HolidayTestCase +{ + /** @var int[] */ + public array $observedYears; + + /** @var int[] */ + public array $unobservedYears; + + public function __construct() + { + $observedYears = range(1916, 1940); + $observedYears = array_merge($observedYears, range(1942, 1945)); + $observedYears = array_merge($observedYears, range(1977, 2037)); // PHP caps future DST transitions + + $this->observedYears = $observedYears; + $this->unobservedYears = array_diff(range(reset($observedYears), end($observedYears)), $observedYears); + + parent::__construct(); + } +} diff --git a/tests/Netherlands/SummertimeTest.php b/tests/Netherlands/SummertimeTest.php index e5707f104..4727ef608 100644 --- a/tests/Netherlands/SummertimeTest.php +++ b/tests/Netherlands/SummertimeTest.php @@ -1,6 +1,7 @@ observedYears, true))) { + unset($this->observedYears[(int) $key]); + } + } + /** * Tests Summertime. * @@ -37,7 +45,7 @@ class SummertimeTest extends NetherlandsBaseTestCase implements HolidayTestCase */ public function testSummertime(): void { - $this->assertNotHoliday(self::REGION, self::HOLIDAY, $this->generateRandomYear(1946, 1976)); + $this->assertNotHoliday(self::REGION, self::HOLIDAY, $this->randomYearFromArray($this->unobservedYears)); $year = $this->generateRandomYear(1977, 1980); $this->assertHoliday( @@ -47,7 +55,7 @@ public function testSummertime(): void new DateTime("first sunday of april $year", new DateTimeZone(self::TIMEZONE)) ); - $year = $this->generateRandomYear(1981, 2036); + $year = $this->generateRandomYear(1981, 2037); $this->assertHoliday( self::REGION, self::HOLIDAY, @@ -66,7 +74,7 @@ public function testTranslation(): void $this->assertTranslatedHolidayName( self::REGION, self::HOLIDAY, - $this->generateRandomYear(1978, 2037), + $this->randomYearFromArray($this->observedYears), [self::LOCALE => 'zomertijd'] ); } @@ -78,6 +86,11 @@ public function testTranslation(): void */ public function testHolidayType(): void { - $this->assertHolidayType(self::REGION, self::HOLIDAY, $this->generateRandomYear(1978, 2037), Holiday::TYPE_SEASON); + $this->assertHolidayType( + self::REGION, + self::HOLIDAY, + $this->randomYearFromArray($this->observedYears), + Holiday::TYPE_SEASON + ); } } diff --git a/tests/Netherlands/WintertimeTest.php b/tests/Netherlands/WintertimeTest.php index d496ec237..6b29b5cbe 100644 --- a/tests/Netherlands/WintertimeTest.php +++ b/tests/Netherlands/WintertimeTest.php @@ -18,18 +18,25 @@ use DateTimeZone; use Exception; use Yasumi\Holiday; -use Yasumi\tests\HolidayTestCase; /** * Class for testing Wintertime in the Netherlands. */ -class WintertimeTest extends NetherlandsBaseTestCase implements HolidayTestCase +final class WintertimeTest extends DaylightSavingTime { - /** - * The name of the holiday. - */ + /** The name of the holiday */ public const HOLIDAY = 'winterTime'; + public function __construct() + { + parent::__construct(); + + // no wintertime defined for 1940 + if (false !== ($key = array_search(1940, $this->observedYears, true))) { + unset($this->observedYears[(int) $key]); + } + } + /** * Tests Wintertime. * @@ -37,7 +44,7 @@ class WintertimeTest extends NetherlandsBaseTestCase implements HolidayTestCase */ public function testWintertime(): void { - $this->assertNotHoliday(self::REGION, self::HOLIDAY, $this->generateRandomYear(1946, 1976)); + $this->assertNotHoliday(self::REGION, self::HOLIDAY, $this->randomYearFromArray($this->unobservedYears)); $year = $this->generateRandomYear(1979, 1995); $this->assertHoliday( @@ -66,7 +73,7 @@ public function testTranslation(): void $this->assertTranslatedHolidayName( self::REGION, self::HOLIDAY, - $this->generateRandomYear(1978, 2037), + $this->randomYearFromArray($this->observedYears), [self::LOCALE => 'wintertijd'] ); } @@ -78,6 +85,11 @@ public function testTranslation(): void */ public function testHolidayType(): void { - $this->assertHolidayType(self::REGION, self::HOLIDAY, $this->generateRandomYear(1978, 2037), Holiday::TYPE_SEASON); + $this->assertHolidayType( + self::REGION, + self::HOLIDAY, + $this->randomYearFromArray($this->observedYears), + Holiday::TYPE_SEASON + ); } } From a9f0d375055f75e689e1605b9a2837f5e7b02734 Mon Sep 17 00:00:00 2001 From: Sacha Telgenhof Date: Mon, 26 Sep 2022 23:53:39 +0900 Subject: [PATCH 057/142] Re-added 8.1 version as the timezone issues have been addressed. Signed-off-by: Sacha Telgenhof --- .github/workflows/coding-standard.yml | 2 +- .github/workflows/static-analysis.yml | 2 +- .github/workflows/testing.yml | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/.github/workflows/coding-standard.yml b/.github/workflows/coding-standard.yml index bb06be3b9..a05470b63 100644 --- a/.github/workflows/coding-standard.yml +++ b/.github/workflows/coding-standard.yml @@ -12,7 +12,7 @@ jobs: fail-fast: false matrix: operating-system: [ ubuntu-latest, windows-latest, macOS-latest ] - php-versions: [ '7.4', '8.0' ] + php-versions: [ '7.4', '8.0', '8.1' ] steps: - name: Set git to use LF diff --git a/.github/workflows/static-analysis.yml b/.github/workflows/static-analysis.yml index 4f157e7ac..7f611f124 100644 --- a/.github/workflows/static-analysis.yml +++ b/.github/workflows/static-analysis.yml @@ -12,7 +12,7 @@ jobs: fail-fast: false matrix: operating-system: [ ubuntu-latest, windows-latest, macOS-latest ] - php-versions: [ '7.4', '8.0' ] + php-versions: [ '7.4', '8.0', '8.1' ] steps: - name: Set git to use LF diff --git a/.github/workflows/testing.yml b/.github/workflows/testing.yml index 945e33fff..a5b18897d 100644 --- a/.github/workflows/testing.yml +++ b/.github/workflows/testing.yml @@ -12,7 +12,7 @@ jobs: fail-fast: false matrix: operating-system: [ ubuntu-latest, windows-latest, macOS-latest ] - php-versions: [ '7.4', '8.0' ] + php-versions: [ '7.4', '8.0', '8.1' ] steps: - name: Set git to use LF From 3214f01bf6bad7a70ce4a39c0a7b2331fb88fd2c Mon Sep 17 00:00:00 2001 From: Sacha Telgenhof Date: Tue, 27 Sep 2022 00:45:46 +0900 Subject: [PATCH 058/142] Removed the mutation testing as currently the outcome is not actively used. Running mutations tests locally should be sufficient. Signed-off-by: Sacha Telgenhof --- .github/workflows/mutation-tests.yml | 52 ---------------------------- 1 file changed, 52 deletions(-) delete mode 100644 .github/workflows/mutation-tests.yml diff --git a/.github/workflows/mutation-tests.yml b/.github/workflows/mutation-tests.yml deleted file mode 100644 index 65b72feaa..000000000 --- a/.github/workflows/mutation-tests.yml +++ /dev/null @@ -1,52 +0,0 @@ -name: "Mutations testing" - -on: - - push - - pull_request - -jobs: - run: - name: "CI" - runs-on: ${{ matrix.operating-system }} - strategy: - fail-fast: false - matrix: - operating-system: [ ubuntu-latest ] - php-versions: [ '7.4', '8.0' ] - - steps: - - name: Set git to use LF - run: | - git config --global core.autocrlf false - git config --global core.eol lf - - - name: Checkout - uses: actions/checkout@v2.3.4 - with: - fetch-depth: 1 - - - name: Install PHP - uses: shivammathur/setup-php@v2 - with: - php-version: ${{ matrix.php-versions }} - coverage: pcov - - - name: Get Composer Cache Directory - id: composer-cache - run: echo "::set-output name=dir::$(composer config cache-files-dir)" - - - name: Cache Composer dependencies - uses: actions/cache@v2 - with: - path: ${{ steps.composer-cache.outputs.dir }} - key: ${{ runner.os }}-composer-${{ hashFiles('**/composer.json') }} - restore-keys: ${{ runner.os }}-composer- - - - name: Check Composer configuration - run: composer validate --strict - - - name: Install dependencies - run: composer install --no-progress --prefer-dist --optimize-autoloader - - - name: Run Mutation tests - run: vendor/bin/infection run -j 2 From 89587fb3fe985c323a1e5187871cabbbafa300ff Mon Sep 17 00:00:00 2001 From: Jozef Grencik <20k121@gmail.com> Date: Thu, 22 Dec 2022 13:09:18 +0100 Subject: [PATCH 059/142] Add Slovak translations for a couple of popular holidays (#298) --- src/Yasumi/data/translations/ascensionDay.php | 1 + src/Yasumi/data/translations/ashWednesday.php | 1 + src/Yasumi/data/translations/corpusChristi.php | 1 + src/Yasumi/data/translations/immaculateConception.php | 1 + 4 files changed, 4 insertions(+) diff --git a/src/Yasumi/data/translations/ascensionDay.php b/src/Yasumi/data/translations/ascensionDay.php index 9d6413228..67ad29dfa 100644 --- a/src/Yasumi/data/translations/ascensionDay.php +++ b/src/Yasumi/data/translations/ascensionDay.php @@ -25,5 +25,6 @@ 'it' => 'Ascensione', 'nb' => 'Kristi himmelfartsdag', 'nl' => 'Hemelvaart', + 'sk' => 'Nanebovstúpenie Pána', 'sv' => 'Kristi himmelsfärdsdag', ]; diff --git a/src/Yasumi/data/translations/ashWednesday.php b/src/Yasumi/data/translations/ashWednesday.php index d145ae215..ea4c2173f 100644 --- a/src/Yasumi/data/translations/ashWednesday.php +++ b/src/Yasumi/data/translations/ashWednesday.php @@ -22,4 +22,5 @@ 'it' => 'Mercoledi delle Ceneri', 'nl' => 'Aswoensdag', 'pt' => 'Quarta-feira de Cinzas', + 'sk' => 'Popolcová streda', ]; diff --git a/src/Yasumi/data/translations/corpusChristi.php b/src/Yasumi/data/translations/corpusChristi.php index f46c60cb0..f27df151e 100644 --- a/src/Yasumi/data/translations/corpusChristi.php +++ b/src/Yasumi/data/translations/corpusChristi.php @@ -23,4 +23,5 @@ 'pl' => 'Boże Ciało', 'pt' => 'Corpus Christi', 'pt_PT' => 'Corpo de Deus', + 'sk' => 'Božie Telo', ]; diff --git a/src/Yasumi/data/translations/immaculateConception.php b/src/Yasumi/data/translations/immaculateConception.php index 0d75bdf66..2fcf9e966 100644 --- a/src/Yasumi/data/translations/immaculateConception.php +++ b/src/Yasumi/data/translations/immaculateConception.php @@ -23,4 +23,5 @@ 'fr' => 'Immaculée Conception', 'it' => 'Immacolata Concezione', 'pt' => 'Dia da Imaculada Conceição', + 'sk' => 'Nepoškvrnené počatie Panny Márie', ]; From 0dc9552bafe6e5201e5bccac97550cb57fb6eead Mon Sep 17 00:00:00 2001 From: Sacha Telgenhof Date: Fri, 23 Dec 2022 21:32:06 +0900 Subject: [PATCH 060/142] Reordered translations alphabetically. Signed-off-by: Sacha Telgenhof --- src/Yasumi/data/translations/allSaintsDay.php | 2 +- src/Yasumi/data/translations/easterMonday.php | 2 +- src/Yasumi/data/translations/epiphany.php | 2 +- src/Yasumi/data/translations/labourDay.php | 2 +- src/Yasumi/data/translations/newYearsDay.php | 2 +- src/Yasumi/data/translations/plebisciteDay.php | 2 +- src/Yasumi/data/translations/queensBirthday.php | 2 +- src/Yasumi/data/translations/stFloriansDay.php | 2 +- src/Yasumi/data/translations/stLeopoldsDay.php | 2 +- src/Yasumi/data/translations/stMartinsDay.php | 2 +- src/Yasumi/data/translations/stRupertsDay.php | 2 +- src/Yasumi/data/translations/substituteHoliday.php | 2 +- 12 files changed, 12 insertions(+), 12 deletions(-) diff --git a/src/Yasumi/data/translations/allSaintsDay.php b/src/Yasumi/data/translations/allSaintsDay.php index 924da6dfb..d96022d8e 100644 --- a/src/Yasumi/data/translations/allSaintsDay.php +++ b/src/Yasumi/data/translations/allSaintsDay.php @@ -21,8 +21,8 @@ 'en' => 'All Saints’ Day', 'es' => 'Día de todos los Santos', 'fi' => 'Pyhäinpäivä', - 'fr_BE' => 'La Toussaint', 'fr' => 'Toussaint', + 'fr_BE' => 'La Toussaint', 'hr' => 'Dan svih svetih', 'hu' => 'Mindenszentek', 'it' => 'Festa di Tutti i Santi', diff --git a/src/Yasumi/data/translations/easterMonday.php b/src/Yasumi/data/translations/easterMonday.php index 868b05ef1..facf6c7e6 100644 --- a/src/Yasumi/data/translations/easterMonday.php +++ b/src/Yasumi/data/translations/easterMonday.php @@ -33,8 +33,8 @@ 'lt' => 'Antroji Velykų diena', 'lv' => 'Otrās Lieldienas', 'nb' => 'andre påskedag', - 'nl_BE' => 'paasmaandag', 'nl' => 'tweede paasdag', + 'nl_BE' => 'paasmaandag', 'pl' => 'Poniedziałek Wielkanocny', 'ro' => 'A doua zi de Paște', 'sk' => 'Veľkonočný pondelok', diff --git a/src/Yasumi/data/translations/epiphany.php b/src/Yasumi/data/translations/epiphany.php index c615e01ba..76e4b20f9 100644 --- a/src/Yasumi/data/translations/epiphany.php +++ b/src/Yasumi/data/translations/epiphany.php @@ -16,9 +16,9 @@ // Translations for Epiphany return [ 'ca' => 'Epifania', + 'de' => 'Heilige 3 Könige', 'de_AT' => 'Heilige Drei Könige', 'de_CH' => 'Heilige Drei Könige', - 'de' => 'Heilige 3 Könige', 'el' => 'Θεοφάνεια', 'en' => 'Epiphany', 'es' => 'Día de Reyes', diff --git a/src/Yasumi/data/translations/labourDay.php b/src/Yasumi/data/translations/labourDay.php index 463d1d724..14b8a6077 100644 --- a/src/Yasumi/data/translations/labourDay.php +++ b/src/Yasumi/data/translations/labourDay.php @@ -17,10 +17,10 @@ return [ 'en' => 'Labour Day', 'en_US' => 'Labor Day', + 'fr' => 'Fête du travail', 'ja' => '労働の日', 'ko' => '노동절', 'nl' => 'Dag van de arbeid', 'sk' => 'Sviatok práce', - 'fr' => 'Fête du travail', 'tr' => 'Emek ve Dayanışma Günü', ]; diff --git a/src/Yasumi/data/translations/newYearsDay.php b/src/Yasumi/data/translations/newYearsDay.php index 06b8b01d1..4d2df4d4f 100644 --- a/src/Yasumi/data/translations/newYearsDay.php +++ b/src/Yasumi/data/translations/newYearsDay.php @@ -26,9 +26,9 @@ 'es' => 'Año Nuevo', 'et' => 'Uusaasta', 'fi' => 'Uudenvuodenpäivä', + 'fr' => 'Jour de l’An', 'fr_BE' => 'Nouvel An', 'fr_CH' => 'Nouvel An', - 'fr' => 'Jour de l’An', 'ga' => 'Lá Caille', 'hr' => 'Nova godina', 'hu' => 'Újév', diff --git a/src/Yasumi/data/translations/plebisciteDay.php b/src/Yasumi/data/translations/plebisciteDay.php index d68854288..8589c1aa9 100644 --- a/src/Yasumi/data/translations/plebisciteDay.php +++ b/src/Yasumi/data/translations/plebisciteDay.php @@ -15,6 +15,6 @@ // Translations for Plebiscite Day. return [ - 'en' => 'Plebiscite Day', 'de_AT' => 'Tag der Volksabstimmung', + 'en' => 'Plebiscite Day', ]; diff --git a/src/Yasumi/data/translations/queensBirthday.php b/src/Yasumi/data/translations/queensBirthday.php index 6ebfea29e..8ae44d5da 100644 --- a/src/Yasumi/data/translations/queensBirthday.php +++ b/src/Yasumi/data/translations/queensBirthday.php @@ -17,7 +17,7 @@ return [ 'da' => 'Dronningens fødselsdag', 'en' => 'Queen’s Birthday', - 'pt' => 'Aniversário da Rainha', 'fr' => 'Anniversaire officiel de la reine', + 'pt' => 'Aniversário da Rainha', 'ru' => 'Официальный день рождения королевы', ]; diff --git a/src/Yasumi/data/translations/stFloriansDay.php b/src/Yasumi/data/translations/stFloriansDay.php index f9894e014..c0cad1376 100644 --- a/src/Yasumi/data/translations/stFloriansDay.php +++ b/src/Yasumi/data/translations/stFloriansDay.php @@ -15,6 +15,6 @@ // Translations for Saint Florian's Day. return [ - 'en' => 'Saint Florian’s Day', 'de_AT' => 'Florian', + 'en' => 'Saint Florian’s Day', ]; diff --git a/src/Yasumi/data/translations/stLeopoldsDay.php b/src/Yasumi/data/translations/stLeopoldsDay.php index aa7cfc990..cc05cf95f 100644 --- a/src/Yasumi/data/translations/stLeopoldsDay.php +++ b/src/Yasumi/data/translations/stLeopoldsDay.php @@ -15,6 +15,6 @@ // Translations for Saint Leopold's Day. return [ - 'en' => 'Saint Leopold’s Day', 'de_AT' => 'Leopold', + 'en' => 'Saint Leopold’s Day', ]; diff --git a/src/Yasumi/data/translations/stMartinsDay.php b/src/Yasumi/data/translations/stMartinsDay.php index 3113bf9ec..d0768d2b5 100644 --- a/src/Yasumi/data/translations/stMartinsDay.php +++ b/src/Yasumi/data/translations/stMartinsDay.php @@ -15,7 +15,7 @@ // Translations for St. Martin's Day return [ + 'de_AT' => 'Martin', 'en' => 'St. Martin’s Day', 'nl' => 'Sint Maarten', - 'de_AT' => 'Martin', ]; diff --git a/src/Yasumi/data/translations/stRupertsDay.php b/src/Yasumi/data/translations/stRupertsDay.php index 35ad9d318..dad66d815 100644 --- a/src/Yasumi/data/translations/stRupertsDay.php +++ b/src/Yasumi/data/translations/stRupertsDay.php @@ -15,6 +15,6 @@ // Translations for Saint Rupert's Day. return [ - 'en' => 'Saint Rupert’s Day', 'de_AT' => 'Rupert', + 'en' => 'Saint Rupert’s Day', ]; diff --git a/src/Yasumi/data/translations/substituteHoliday.php b/src/Yasumi/data/translations/substituteHoliday.php index 38a59906e..eece0501a 100644 --- a/src/Yasumi/data/translations/substituteHoliday.php +++ b/src/Yasumi/data/translations/substituteHoliday.php @@ -17,8 +17,8 @@ return [ 'da' => '{0} (erstatning)', 'en' => '{0} (substitute day)', - 'en_US' => '{0} observed', 'en_CA' => '{0} observed', + 'en_US' => '{0} observed', 'ja' => '振替休日 ({0})', 'ko' => '대체공휴일', ]; From 9d5cdb44e65a02769d263b3e28adf14ba7d62864 Mon Sep 17 00:00:00 2001 From: Sacha Telgenhof Date: Sun, 25 Dec 2022 21:37:01 +0900 Subject: [PATCH 061/142] In version 2022f of the tz db, a correction for 1947 was made for the summertiime transition to april the 6th. Signed-off-by: Sacha Telgenhof --- tests/Denmark/SummerTimeTest.php | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/tests/Denmark/SummerTimeTest.php b/tests/Denmark/SummerTimeTest.php index e15cd9ae5..626d009f0 100644 --- a/tests/Denmark/SummerTimeTest.php +++ b/tests/Denmark/SummerTimeTest.php @@ -45,10 +45,17 @@ public function __construct() { parent::__construct(); - // no summertime defined for 1942 + // no summertime defined prior to 1942 if (false !== ($key = array_search(1942, $this->observedYears, true))) { unset($this->observedYears[(int) $key]); } + + // In version 2022f of th tz db, a correction for 1947 was made for the summertiime + // transition to april the 6th. + // See: https://github.com/eggert/tz/blob/2022f/europe + if (1 === strcmp(intltz_get_tz_data_version(), '2022f')) { + $this->deviantTransitions[1947] = '1947-04-06'; + } } /** From ea9bd33e91459ae94d0d4ef022058b2084313744 Mon Sep 17 00:00:00 2001 From: Sacha Telgenhof Date: Sun, 25 Dec 2022 21:44:39 +0900 Subject: [PATCH 062/142] Namespace correction. Function belongs to the global namespace. Signed-off-by: Sacha Telgenhof --- tests/Denmark/SummerTimeTest.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/tests/Denmark/SummerTimeTest.php b/tests/Denmark/SummerTimeTest.php index 626d009f0..fa4b3b457 100644 --- a/tests/Denmark/SummerTimeTest.php +++ b/tests/Denmark/SummerTimeTest.php @@ -50,10 +50,10 @@ public function __construct() unset($this->observedYears[(int) $key]); } - // In version 2022f of th tz db, a correction for 1947 was made for the summertiime + // In version 2022f of the tz db, a correction for 1947 was made for the summertiime // transition to april the 6th. // See: https://github.com/eggert/tz/blob/2022f/europe - if (1 === strcmp(intltz_get_tz_data_version(), '2022f')) { + if (1 === strcmp(\intltz_get_tz_data_version(), '2022f')) { $this->deviantTransitions[1947] = '1947-04-06'; } } From c123e91f08d8696132e12d32b4ba6493b853ff91 Mon Sep 17 00:00:00 2001 From: Sacha Telgenhof Date: Sun, 25 Dec 2022 23:06:59 +0900 Subject: [PATCH 063/142] Added intl and calendar extension for testing purposes. Signed-off-by: Sacha Telgenhof --- .github/workflows/testing.yml | 1 + 1 file changed, 1 insertion(+) diff --git a/.github/workflows/testing.yml b/.github/workflows/testing.yml index a5b18897d..462424a64 100644 --- a/.github/workflows/testing.yml +++ b/.github/workflows/testing.yml @@ -30,6 +30,7 @@ jobs: with: php-version: ${{ matrix.php-versions }} coverage: pcov + extensions: intl-72.1, calendar - name: Get Composer Cache Directory id: composer-cache From b2c2cbb851cb9e5e6cef5f562c9f51a2e8733533 Mon Sep 17 00:00:00 2001 From: Sacha Telgenhof Date: Sun, 25 Dec 2022 23:18:37 +0900 Subject: [PATCH 064/142] Removed ICU version for the intl extension. Signed-off-by: Sacha Telgenhof --- .github/workflows/testing.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/testing.yml b/.github/workflows/testing.yml index 462424a64..723287daa 100644 --- a/.github/workflows/testing.yml +++ b/.github/workflows/testing.yml @@ -30,7 +30,7 @@ jobs: with: php-version: ${{ matrix.php-versions }} coverage: pcov - extensions: intl-72.1, calendar + extensions: intl, calendar - name: Get Composer Cache Directory id: composer-cache From d94fdf8fd595f471208fde868e7e635d09879aec Mon Sep 17 00:00:00 2001 From: Sacha Telgenhof Date: Sun, 25 Dec 2022 23:25:06 +0900 Subject: [PATCH 065/142] Require intl extension for development as some tests make use of this extension. Signed-off-by: Sacha Telgenhof --- composer.json | 1 + 1 file changed, 1 insertion(+) diff --git a/composer.json b/composer.json index 21b99f450..f7b2b71e8 100644 --- a/composer.json +++ b/composer.json @@ -40,6 +40,7 @@ "ext-json": "*" }, "require-dev": { + "ext-intl": "*", "friendsofphp/php-cs-fixer": "v2.19 | v3.11", "infection/infection": "^0.17 | ^0.26", "mikey179/vfsstream": "^1.6", From ff2d683ec2480f304b55f0ba9556c544926bf69d Mon Sep 17 00:00:00 2001 From: Sacha Telgenhof Date: Sun, 25 Dec 2022 23:42:10 +0900 Subject: [PATCH 066/142] Fixed check for dates before the establishment of Republic Day. Erroneously the year before establishment may be calculated as a holiday. Signed-off-by: Sacha Telgenhof --- src/Yasumi/Provider/Turkey.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/Yasumi/Provider/Turkey.php b/src/Yasumi/Provider/Turkey.php index 19494bc19..a2886c581 100644 --- a/src/Yasumi/Provider/Turkey.php +++ b/src/Yasumi/Provider/Turkey.php @@ -176,7 +176,7 @@ private function addVictoryDay(): void */ private function addRepublicDay(): void { - if (1923 > $this->year) { + if (1924 > $this->year) { return; } From 5cec9083de19764aa1fc382d59d159e074c896d2 Mon Sep 17 00:00:00 2001 From: Sacha Telgenhof Date: Mon, 26 Dec 2022 00:15:45 +0900 Subject: [PATCH 067/142] Remove again required intl extension. Signed-off-by: Sacha Telgenhof --- composer.json | 1 - 1 file changed, 1 deletion(-) diff --git a/composer.json b/composer.json index f7b2b71e8..21b99f450 100644 --- a/composer.json +++ b/composer.json @@ -40,7 +40,6 @@ "ext-json": "*" }, "require-dev": { - "ext-intl": "*", "friendsofphp/php-cs-fixer": "v2.19 | v3.11", "infection/infection": "^0.17 | ^0.26", "mikey179/vfsstream": "^1.6", From 5b06149ee3465eb7182ee7aa3328a4bed482193f Mon Sep 17 00:00:00 2001 From: Sacha Telgenhof Date: Mon, 26 Dec 2022 00:28:50 +0900 Subject: [PATCH 068/142] Added type. Signed-off-by: Sacha Telgenhof --- tests/Japan/PublicBridgeDayTest.php | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/tests/Japan/PublicBridgeDayTest.php b/tests/Japan/PublicBridgeDayTest.php index 261481d7a..c99e49c7b 100644 --- a/tests/Japan/PublicBridgeDayTest.php +++ b/tests/Japan/PublicBridgeDayTest.php @@ -29,10 +29,11 @@ class PublicBridgeDayTest extends JapanBaseTestCase implements HolidayTestCase * The name of the holiday. */ public const HOLIDAY = 'bridgeDay'; + /** * @var number representing the calendar year to be tested against */ - private $year; + private int $year; /** * Initial setup of this Test Case. From 4687d76f9efa39652abc5cf748034a1b5c71f6b3 Mon Sep 17 00:00:00 2001 From: Sacha Telgenhof Date: Mon, 26 Dec 2022 00:29:22 +0900 Subject: [PATCH 069/142] Removed unnecessary check. --- src/Yasumi/Provider/Argentina.php | 44 ++++++++++++++----------------- 1 file changed, 20 insertions(+), 24 deletions(-) diff --git a/src/Yasumi/Provider/Argentina.php b/src/Yasumi/Provider/Argentina.php index cf4a0d27c..9f8a70e09 100644 --- a/src/Yasumi/Provider/Argentina.php +++ b/src/Yasumi/Provider/Argentina.php @@ -99,33 +99,29 @@ private function addCarnvalHolidays(): void $carnavalMonday = clone $easter; $carnavalMondayDate = $carnavalMonday->sub(new DateInterval('P48D')); - if (false !== $carnavalMondayDate) { - $this->addHoliday(new Holiday( - 'carnavalMonday', - [ - 'en' => 'Carnival Monday', - 'es' => 'Lunes de Carnaval', - ], - $carnavalMondayDate, - $this->locale, - Holiday::TYPE_OBSERVANCE - )); - } + $this->addHoliday(new Holiday( + 'carnavalMonday', + [ + 'en' => 'Carnival Monday', + 'es' => 'Lunes de Carnaval', + ], + $carnavalMondayDate, + $this->locale, + Holiday::TYPE_OBSERVANCE + )); $carnavalTuesday = clone $easter; $carnavalTuesdayDate = $carnavalTuesday->sub(new DateInterval('P47D')); - if (false !== $carnavalTuesdayDate) { - $this->addHoliday(new Holiday( - 'carnavalTuesday', - [ - 'en' => 'Carnival Tuesday', - 'es' => 'Martes de Carnaval', - ], - $carnavalTuesdayDate, - $this->locale, - Holiday::TYPE_OBSERVANCE - )); - } + $this->addHoliday(new Holiday( + 'carnavalTuesday', + [ + 'en' => 'Carnival Tuesday', + 'es' => 'Martes de Carnaval', + ], + $carnavalTuesdayDate, + $this->locale, + Holiday::TYPE_OBSERVANCE + )); } } From 3d888ab62421042d6dcd9936dc61d6c483ad3feb Mon Sep 17 00:00:00 2001 From: Sacha Telgenhof Date: Mon, 26 Dec 2022 21:20:22 +0900 Subject: [PATCH 070/142] Added additional years that have the transition changed in tz version 2022f. Signed-off-by: Sacha Telgenhof --- tests/Denmark/SummerTimeTest.php | 10 +++++++--- 1 file changed, 7 insertions(+), 3 deletions(-) diff --git a/tests/Denmark/SummerTimeTest.php b/tests/Denmark/SummerTimeTest.php index fa4b3b457..fe05f2752 100644 --- a/tests/Denmark/SummerTimeTest.php +++ b/tests/Denmark/SummerTimeTest.php @@ -45,16 +45,20 @@ public function __construct() { parent::__construct(); - // no summertime defined prior to 1942 + // no summertime defined in 1942 if (false !== ($key = array_search(1942, $this->observedYears, true))) { unset($this->observedYears[(int) $key]); } - // In version 2022f of the tz db, a correction for 1947 was made for the summertiime - // transition to april the 6th. + // In version 2022f of the tz db, a correction for some years weere made for the summertime + // transitions. // See: https://github.com/eggert/tz/blob/2022f/europe if (1 === strcmp(\intltz_get_tz_data_version(), '2022f')) { + $this->deviantTransitions[1916] = '1916-04-30'; + $this->deviantTransitions[1940] = '1940-04-01'; + $this->deviantTransitions[1946] = '1946-04-14'; $this->deviantTransitions[1947] = '1947-04-06'; + $this->deviantTransitions[1948] = '1948-04-18'; } } From 73971681f09a9e4e349a9613b61d16397bc10a1a Mon Sep 17 00:00:00 2001 From: Sacha Telgenhof Date: Tue, 27 Dec 2022 11:57:07 +0900 Subject: [PATCH 071/142] In version 2022f of the tz db, corrections for some years weere made for the wintertime transitions. Signed-off-by: Sacha Telgenhof --- tests/Denmark/WinterTimeTest.php | 59 +++++++++++++++++++++++++++----- 1 file changed, 50 insertions(+), 9 deletions(-) diff --git a/tests/Denmark/WinterTimeTest.php b/tests/Denmark/WinterTimeTest.php index 872efcf81..cd8bbb33a 100644 --- a/tests/Denmark/WinterTimeTest.php +++ b/tests/Denmark/WinterTimeTest.php @@ -30,6 +30,20 @@ final class WinterTimeTest extends DaylightSavingTime /** The name of the holiday */ public const HOLIDAY = 'winterTime'; + /* List of transition dates that deviate from the known/defined rules. + * PHP derives the transition dates from the tz database which appear to + * be different for some dates */ + private array $deviantTransitions = [ + 1916 => '1916-09-30', + 1942 => '1942-11-02', + 1943 => '1943-10-04', + 1944 => '1944-10-02', + 1945 => '1945-08-15', + 1946 => '1946-09-01', + 1947 => '1947-08-10', + 1948 => '1948-08-08', + ]; + public function __construct() { parent::__construct(); @@ -38,6 +52,20 @@ public function __construct() if (false !== ($key = array_search(1940, $this->observedYears, true))) { unset($this->observedYears[(int) $key]); } + + // In version 2022f of the tz db, a correction for some years weere made for the wintertime + // transitions. See: https://github.com/eggert/tz/blob/2022f/europe + if (1 === strcmp(\intltz_get_tz_data_version(), '2022f')) { + $this->swapObservation([1918, 1917, 1945, 1946, 1948, 1949]); + + $this->deviantTransitions[1917] = '1917-09-17'; + $this->deviantTransitions[1918] = '1918-09-16'; + $this->deviantTransitions[1945] = '1945-11-18'; + $this->deviantTransitions[1946] = '1946-10-07'; + $this->deviantTransitions[1947] = '1947-10-05'; + $this->deviantTransitions[1948] = '1948-10-03'; + $this->deviantTransitions[1949] = '1949-10-02'; + } } /** @@ -49,20 +77,22 @@ public function testWinterTime(): void { $this->assertNotHoliday(self::REGION, self::HOLIDAY, $this->randomYearFromArray($this->unobservedYears)); - $year = $this->generateRandomYear(1980, 1995); - $this->assertHoliday( - self::REGION, - self::HOLIDAY, - $year, - new DateTime("last sunday of september $year", new DateTimeZone(self::TIMEZONE)) - ); + $year = $this->randomYearFromArray($this->observedYears); + $expectedDate = new DateTime("last sunday of september $year", new DateTimeZone(self::TIMEZONE)); + + if ($year >= 1996) { + $expectedDate = new DateTime("last sunday of october $year", new DateTimeZone(self::TIMEZONE)); + } + + if (array_key_exists($year, $this->deviantTransitions)) { + $expectedDate = new DateTime($this->deviantTransitions[$year], new DateTimeZone(self::TIMEZONE)); + } - $year = $this->generateRandomYear(1996, 2036); $this->assertHoliday( self::REGION, self::HOLIDAY, $year, - new DateTime("last sunday of october $year", new DateTimeZone(self::TIMEZONE)) + $expectedDate ); } @@ -94,4 +124,15 @@ public function testHolidayType(): void Holiday::TYPE_SEASON ); } + + /* Swaps the observation from observed to unobserved for the given years */ + private function swapObservation(array $years): void + { + foreach ($years as $y) { + $this->observedYears[] = $y; + if (false !== ($key = array_search($y, $this->unobservedYears, true))) { + unset($this->unobservedYears[(int) $key]); + } + } + } } From c8fc46e5349d98f43864f361e067403e43d3ba63 Mon Sep 17 00:00:00 2001 From: Sacha Telgenhof Date: Tue, 27 Dec 2022 11:59:06 +0900 Subject: [PATCH 072/142] Added note regarding the deviated transition. Signed-off-by: Sacha Telgenhof --- tests/Denmark/SummerTimeTest.php | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/tests/Denmark/SummerTimeTest.php b/tests/Denmark/SummerTimeTest.php index fe05f2752..087a99535 100644 --- a/tests/Denmark/SummerTimeTest.php +++ b/tests/Denmark/SummerTimeTest.php @@ -30,6 +30,9 @@ final class SummerTimeTest extends DaylightSavingTime /** The name of the holiday */ public const HOLIDAY = 'summerTime'; + /* List of transition dates that deviate from the known/defined rules. + * PHP derives the transition dates from the tz database which appear to + * be different for some dates */ private array $deviantTransitions = [ 1916 => '1916-05-14', 1940 => '1940-05-14', @@ -51,8 +54,7 @@ public function __construct() } // In version 2022f of the tz db, a correction for some years weere made for the summertime - // transitions. - // See: https://github.com/eggert/tz/blob/2022f/europe + // transitions. See: https://github.com/eggert/tz/blob/2022f/europe if (1 === strcmp(\intltz_get_tz_data_version(), '2022f')) { $this->deviantTransitions[1916] = '1916-04-30'; $this->deviantTransitions[1940] = '1940-04-01'; From b772b89c345fd15d71d4c2cd8c5efbe69dd658c8 Mon Sep 17 00:00:00 2001 From: Sacha Telgenhof Date: Tue, 27 Dec 2022 13:04:33 +0900 Subject: [PATCH 073/142] Updated actions/checkout to latest v2 version. Signed-off-by: Sacha Telgenhof --- .github/workflows/coding-standard.yml | 2 +- .github/workflows/static-analysis.yml | 2 +- .github/workflows/testing.yml | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/.github/workflows/coding-standard.yml b/.github/workflows/coding-standard.yml index a05470b63..0e4667e28 100644 --- a/.github/workflows/coding-standard.yml +++ b/.github/workflows/coding-standard.yml @@ -21,7 +21,7 @@ jobs: git config --global core.eol lf - name: Checkout - uses: actions/checkout@v2.3.4 + uses: actions/checkout@v2.6.0 with: fetch-depth: 1 diff --git a/.github/workflows/static-analysis.yml b/.github/workflows/static-analysis.yml index 7f611f124..324c24c73 100644 --- a/.github/workflows/static-analysis.yml +++ b/.github/workflows/static-analysis.yml @@ -21,7 +21,7 @@ jobs: git config --global core.eol lf - name: Checkout - uses: actions/checkout@v2.3.4 + uses: actions/checkout@v2.6.0 with: fetch-depth: 1 diff --git a/.github/workflows/testing.yml b/.github/workflows/testing.yml index 723287daa..23f97c63d 100644 --- a/.github/workflows/testing.yml +++ b/.github/workflows/testing.yml @@ -21,7 +21,7 @@ jobs: git config --global core.eol lf - name: Checkout - uses: actions/checkout@v2.3.4 + uses: actions/checkout@v2.6.0 with: fetch-depth: 1 From 8b374dbdfd01b3626ed45ffe7ae812af5793b90e Mon Sep 17 00:00:00 2001 From: Sacha Telgenhof Date: Tue, 27 Dec 2022 13:25:06 +0900 Subject: [PATCH 074/142] Updated actions/checkout to latest v3 version. Signed-off-by: Sacha Telgenhof --- .github/workflows/coding-standard.yml | 2 +- .github/workflows/static-analysis.yml | 2 +- .github/workflows/testing.yml | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/.github/workflows/coding-standard.yml b/.github/workflows/coding-standard.yml index 0e4667e28..0c074d404 100644 --- a/.github/workflows/coding-standard.yml +++ b/.github/workflows/coding-standard.yml @@ -21,7 +21,7 @@ jobs: git config --global core.eol lf - name: Checkout - uses: actions/checkout@v2.6.0 + uses: actions/checkout@v3.2.0 with: fetch-depth: 1 diff --git a/.github/workflows/static-analysis.yml b/.github/workflows/static-analysis.yml index 324c24c73..89a47c80d 100644 --- a/.github/workflows/static-analysis.yml +++ b/.github/workflows/static-analysis.yml @@ -21,7 +21,7 @@ jobs: git config --global core.eol lf - name: Checkout - uses: actions/checkout@v2.6.0 + uses: actions/checkout@v3.2.0 with: fetch-depth: 1 diff --git a/.github/workflows/testing.yml b/.github/workflows/testing.yml index 23f97c63d..204dec4d6 100644 --- a/.github/workflows/testing.yml +++ b/.github/workflows/testing.yml @@ -21,7 +21,7 @@ jobs: git config --global core.eol lf - name: Checkout - uses: actions/checkout@v2.6.0 + uses: actions/checkout@v3.2.0 with: fetch-depth: 1 From 72462dd0d24f678aedecdc66cdd041915837b661 Mon Sep 17 00:00:00 2001 From: Sacha Telgenhof Date: Tue, 27 Dec 2022 14:38:29 +0900 Subject: [PATCH 075/142] Updated actions/cache to v3. Reformatted action steps. Signed-off-by: Sacha Telgenhof --- .github/workflows/coding-standard.yml | 14 +++++++++----- .github/workflows/static-analysis.yml | 14 +++++++++----- .github/workflows/testing.yml | 14 +++++++++----- 3 files changed, 27 insertions(+), 15 deletions(-) diff --git a/.github/workflows/coding-standard.yml b/.github/workflows/coding-standard.yml index 0c074d404..0b2163ea2 100644 --- a/.github/workflows/coding-standard.yml +++ b/.github/workflows/coding-standard.yml @@ -33,14 +33,18 @@ jobs: - name: Get Composer Cache Directory id: composer-cache - run: echo "::set-output name=dir::$(composer config cache-files-dir)" + run: | + echo "::set-output name=dir::$(composer config cache-files-dir)" - - name: Cache Composer dependencies - uses: actions/cache@v2 + - name: Get Composer Cache Directory + id: composer-cache + run: echo "::set-output name=dir::$(composer config cache-files-dir)" + - uses: actions/cache@v3 with: path: ${{ steps.composer-cache.outputs.dir }} - key: ${{ runner.os }}-composer-${{ hashFiles('**/composer.json') }} - restore-keys: ${{ runner.os }}-composer- + key: ${{ runner.os }}-composer-${{ hashFiles('**/composer.lock') }} + restore-keys: | + ${{ runner.os }}-composer- - name: Check Composer configuration run: composer validate --strict diff --git a/.github/workflows/static-analysis.yml b/.github/workflows/static-analysis.yml index 89a47c80d..7fa372f16 100644 --- a/.github/workflows/static-analysis.yml +++ b/.github/workflows/static-analysis.yml @@ -33,14 +33,18 @@ jobs: - name: Get Composer Cache Directory id: composer-cache - run: echo "::set-output name=dir::$(composer config cache-files-dir)" + run: | + echo "::set-output name=dir::$(composer config cache-files-dir)" - - name: Cache Composer dependencies - uses: actions/cache@v2 + - name: Get Composer Cache Directory + id: composer-cache + run: echo "::set-output name=dir::$(composer config cache-files-dir)" + - uses: actions/cache@v3 with: path: ${{ steps.composer-cache.outputs.dir }} - key: ${{ runner.os }}-composer-${{ hashFiles('**/composer.json') }} - restore-keys: ${{ runner.os }}-composer- + key: ${{ runner.os }}-composer-${{ hashFiles('**/composer.lock') }} + restore-keys: | + ${{ runner.os }}-composer- - name: Check Composer configuration run: composer validate --strict diff --git a/.github/workflows/testing.yml b/.github/workflows/testing.yml index 204dec4d6..7ed63773b 100644 --- a/.github/workflows/testing.yml +++ b/.github/workflows/testing.yml @@ -34,14 +34,18 @@ jobs: - name: Get Composer Cache Directory id: composer-cache - run: echo "::set-output name=dir::$(composer config cache-files-dir)" + run: | + echo "::set-output name=dir::$(composer config cache-files-dir)" - - name: Cache Composer dependencies - uses: actions/cache@v2 + - name: Get Composer Cache Directory + id: composer-cache + run: echo "::set-output name=dir::$(composer config cache-files-dir)" + - uses: actions/cache@v3 with: path: ${{ steps.composer-cache.outputs.dir }} - key: ${{ runner.os }}-composer-${{ hashFiles('**/composer.json') }} - restore-keys: ${{ runner.os }}-composer- + key: ${{ runner.os }}-composer-${{ hashFiles('**/composer.lock') }} + restore-keys: | + ${{ runner.os }}-composer- - name: Check Composer configuration run: composer validate --strict From fc51d382a7e66518eb832ce437f17c00ba62481e Mon Sep 17 00:00:00 2001 From: Sacha Telgenhof Date: Tue, 27 Dec 2022 14:40:24 +0900 Subject: [PATCH 076/142] Removed duplicate steps. Signed-off-by: Sacha Telgenhof --- .github/workflows/coding-standard.yml | 5 ----- .github/workflows/static-analysis.yml | 5 ----- .github/workflows/testing.yml | 5 ----- 3 files changed, 15 deletions(-) diff --git a/.github/workflows/coding-standard.yml b/.github/workflows/coding-standard.yml index 0b2163ea2..eff66be54 100644 --- a/.github/workflows/coding-standard.yml +++ b/.github/workflows/coding-standard.yml @@ -31,11 +31,6 @@ jobs: php-version: ${{ matrix.php-versions }} coverage: pcov - - name: Get Composer Cache Directory - id: composer-cache - run: | - echo "::set-output name=dir::$(composer config cache-files-dir)" - - name: Get Composer Cache Directory id: composer-cache run: echo "::set-output name=dir::$(composer config cache-files-dir)" diff --git a/.github/workflows/static-analysis.yml b/.github/workflows/static-analysis.yml index 7fa372f16..73e2eb10c 100644 --- a/.github/workflows/static-analysis.yml +++ b/.github/workflows/static-analysis.yml @@ -31,11 +31,6 @@ jobs: php-version: ${{ matrix.php-versions }} coverage: pcov - - name: Get Composer Cache Directory - id: composer-cache - run: | - echo "::set-output name=dir::$(composer config cache-files-dir)" - - name: Get Composer Cache Directory id: composer-cache run: echo "::set-output name=dir::$(composer config cache-files-dir)" diff --git a/.github/workflows/testing.yml b/.github/workflows/testing.yml index 7ed63773b..714ce1dc5 100644 --- a/.github/workflows/testing.yml +++ b/.github/workflows/testing.yml @@ -32,11 +32,6 @@ jobs: coverage: pcov extensions: intl, calendar - - name: Get Composer Cache Directory - id: composer-cache - run: | - echo "::set-output name=dir::$(composer config cache-files-dir)" - - name: Get Composer Cache Directory id: composer-cache run: echo "::set-output name=dir::$(composer config cache-files-dir)" From 775fc7a4b4bda76d09049f21ffa5cd1d6252e15a Mon Sep 17 00:00:00 2001 From: Sacha Telgenhof Date: Tue, 27 Dec 2022 15:05:25 +0900 Subject: [PATCH 077/142] Updated PHPCS Fixer to v3.13. This version includes the global namspace import ruleset which does not import functions and classes in the global namespace by default. Signed-off-by: Sacha Telgenhof --- composer.json | 2 +- src/Yasumi/Exception/InvalidDateException.php | 4 +- src/Yasumi/Exception/InvalidYearException.php | 4 +- .../Exception/ProviderNotFoundException.php | 4 +- .../Exception/UnknownLocaleException.php | 4 +- src/Yasumi/Filters/AbstractFilter.php | 4 +- src/Yasumi/Filters/BetweenFilter.php | 12 +-- src/Yasumi/Filters/OnFilter.php | 6 +- src/Yasumi/Holiday.php | 9 +-- src/Yasumi/Provider/AbstractProvider.php | 19 ++--- src/Yasumi/Provider/Argentina.php | 26 +++---- src/Yasumi/Provider/Australia.php | 30 ++++---- .../Australia/AustralianCapitalTerritory.php | 14 ++-- .../Provider/Australia/NewSouthWales.php | 10 +-- .../Provider/Australia/NorthernTerritory.php | 10 +-- src/Yasumi/Provider/Australia/Queensland.php | 7 +- .../Australia/Queensland/Brisbane.php | 8 +- .../Provider/Australia/SouthAustralia.php | 24 +++--- src/Yasumi/Provider/Australia/Tasmania.php | 7 +- .../Australia/Tasmania/CentralNorth.php | 3 +- .../Australia/Tasmania/FlindersIsland.php | 6 +- .../Australia/Tasmania/KingIsland.php | 3 +- .../Provider/Australia/Tasmania/Northeast.php | 6 +- .../Provider/Australia/Tasmania/Northwest.php | 6 +- .../Tasmania/Northwest/CircularHead.php | 6 +- .../Provider/Australia/Tasmania/South.php | 6 +- .../Australia/Tasmania/South/Southeast.php | 3 +- src/Yasumi/Provider/Australia/Victoria.php | 12 ++- .../Provider/Australia/WesternAustralia.php | 7 +- src/Yasumi/Provider/Austria.php | 5 +- src/Yasumi/Provider/Austria/Carinthia.php | 3 +- src/Yasumi/Provider/Austria/Salzburg.php | 3 +- src/Yasumi/Provider/Austria/UpperAustria.php | 3 +- src/Yasumi/Provider/Belgium.php | 3 +- src/Yasumi/Provider/Bosnia.php | 11 ++- src/Yasumi/Provider/Brazil.php | 16 ++-- src/Yasumi/Provider/Canada.php | 21 +++-- src/Yasumi/Provider/Canada/Alberta.php | 3 +- src/Yasumi/Provider/Canada/Manitoba.php | 5 +- .../Canada/NewfoundlandAndLabrador.php | 5 +- src/Yasumi/Provider/Canada/NovaScotia.php | 5 +- .../Provider/Canada/PrinceEdwardIsland.php | 5 +- src/Yasumi/Provider/Canada/Quebec.php | 5 +- src/Yasumi/Provider/Canada/Saskatchewan.php | 3 +- src/Yasumi/Provider/Canada/Yukon.php | 5 +- src/Yasumi/Provider/ChristianHolidays.php | 50 ++++++------ src/Yasumi/Provider/CommonHolidays.php | 22 +++--- src/Yasumi/Provider/Croatia.php | 13 ++-- src/Yasumi/Provider/CzechRepublic.php | 13 ++-- src/Yasumi/Provider/Denmark.php | 5 +- src/Yasumi/Provider/Finland.php | 7 +- src/Yasumi/Provider/France.php | 3 +- src/Yasumi/Provider/Germany.php | 3 +- src/Yasumi/Provider/Germany/Berlin.php | 3 +- src/Yasumi/Provider/Germany/Saxony.php | 3 +- src/Yasumi/Provider/Greece.php | 12 ++- src/Yasumi/Provider/Hungary.php | 7 +- src/Yasumi/Provider/Ireland.php | 15 ++-- src/Yasumi/Provider/Italy.php | 5 +- src/Yasumi/Provider/Japan.php | 75 +++++++++--------- src/Yasumi/Provider/Luxembourg.php | 5 +- src/Yasumi/Provider/Netherlands.php | 28 ++++--- src/Yasumi/Provider/NewZealand.php | 36 ++++----- src/Yasumi/Provider/Norway.php | 3 +- src/Yasumi/Provider/Poland.php | 5 +- src/Yasumi/Provider/Portugal.php | 9 +-- src/Yasumi/Provider/Romania.php | 15 ++-- src/Yasumi/Provider/Slovakia.php | 13 ++-- src/Yasumi/Provider/SouthAfrica.php | 22 +++--- src/Yasumi/Provider/SouthKorea.php | 48 ++++++------ src/Yasumi/Provider/Spain.php | 5 +- src/Yasumi/Provider/Spain/Andalusia.php | 3 +- src/Yasumi/Provider/Spain/Asturias.php | 3 +- src/Yasumi/Provider/Spain/BalearicIslands.php | 3 +- src/Yasumi/Provider/Spain/BasqueCountry.php | 3 +- src/Yasumi/Provider/Spain/CanaryIslands.php | 3 +- src/Yasumi/Provider/Spain/Cantabria.php | 3 +- src/Yasumi/Provider/Spain/CastileAndLeon.php | 3 +- .../Provider/Spain/CastillaLaMancha.php | 3 +- src/Yasumi/Provider/Spain/Catalonia.php | 3 +- src/Yasumi/Provider/Spain/Ceuta.php | 3 +- .../Provider/Spain/CommunityOfMadrid.php | 3 +- src/Yasumi/Provider/Spain/Extremadura.php | 3 +- src/Yasumi/Provider/Spain/Galicia.php | 5 +- src/Yasumi/Provider/Spain/LaRioja.php | 3 +- src/Yasumi/Provider/Spain/RegionOfMurcia.php | 3 +- .../Provider/Spain/ValencianCommunity.php | 3 +- src/Yasumi/Provider/Sweden.php | 16 ++-- src/Yasumi/Provider/Switzerland.php | 12 ++- src/Yasumi/Provider/Switzerland/Fribourg.php | 3 +- src/Yasumi/Provider/Switzerland/Geneva.php | 8 +- src/Yasumi/Provider/Switzerland/Glarus.php | 3 +- src/Yasumi/Provider/Switzerland/Jura.php | 3 +- src/Yasumi/Provider/Switzerland/Neuchatel.php | 7 +- src/Yasumi/Provider/Switzerland/Obwalden.php | 5 +- src/Yasumi/Provider/Switzerland/Ticino.php | 3 +- src/Yasumi/Provider/USA.php | 30 ++++---- src/Yasumi/Provider/UnitedKingdom.php | 30 ++++---- .../UnitedKingdom/NorthernIreland.php | 5 +- .../Provider/UnitedKingdom/Scotland.php | 12 ++- src/Yasumi/ProviderInterface.php | 5 +- src/Yasumi/Translations.php | 8 +- src/Yasumi/Yasumi.php | 30 +++----- tests/Argentina/CarnavalMondayTest.php | 12 ++- tests/Argentina/CarnavalTuesdayTest.php | 12 ++- tests/Argentina/ChristmasDayTest.php | 11 +-- tests/Argentina/EasterTest.php | 7 +- tests/Argentina/FlagDayTest.php | 11 +-- .../Argentina/GeneralJoseSanMartinDayTest.php | 11 +-- .../GeneralMartinMigueldeGuemesDayTest.php | 11 +-- tests/Argentina/GoodFridayTest.php | 10 +-- .../Argentina/ImmaculateConceptionDayTest.php | 11 +-- tests/Argentina/IndependenceDayTest.php | 11 +-- .../Argentina/InternationalWorkersDayTest.php | 11 +-- tests/Argentina/MalvinasDayTest.php | 11 +-- tests/Argentina/MayRevolutionTest.php | 11 +-- .../Argentina/NationalSovereigntyDayTest.php | 11 +-- tests/Argentina/NewYearsDayTest.php | 11 +-- tests/Argentina/RaceDayTest.php | 11 +-- tests/Argentina/RemembranceDayTest.php | 13 ++-- tests/Australia/AnzacDayTest.php | 11 +-- tests/Australia/AustraliaDayTest.php | 17 ++-- tests/Australia/AustraliaTest.php | 3 +- .../AustralianCapitalTerritoryTest.php | 3 +- .../CanberraDayTest.php | 11 +-- .../EasterSaturdayTest.php | 16 ++-- .../EasterSundayTest.php | 13 ++-- .../LabourDayTest.php | 11 +-- .../QueensBirthdayTest.php | 11 +-- .../ReconciliationDayTest.php | 11 +-- tests/Australia/BoxingDayTest.php | 13 ++-- tests/Australia/ChristmasDayTest.php | 13 ++-- tests/Australia/EasterMondayTest.php | 20 ++--- tests/Australia/GoodFridayTest.php | 16 ++-- .../NewSouthWales/BankHolidayTest.php | 11 +-- .../NewSouthWales/EasterSaturdayTest.php | 16 ++-- .../NewSouthWales/EasterSundayTest.php | 13 ++-- .../Australia/NewSouthWales/LabourDayTest.php | 11 +-- .../NewSouthWales/NewSouthWalesTest.php | 3 +- .../NewSouthWales/QueensBirthdayTest.php | 11 +-- tests/Australia/NewYearsDayTest.php | 13 ++-- .../NorthernTerritory/EasterSaturdayTest.php | 16 ++-- .../NorthernTerritory/MayDayTest.php | 11 +-- .../NorthernTerritoryTest.php | 3 +- .../NorthernTerritory/PicnicDayTest.php | 11 +-- .../NorthernTerritory/QueensBirthdayTest.php | 11 +-- .../Queensland/Brisbane/BrisbaneTest.php | 3 +- .../Queensland/Brisbane/PeoplesDayTest.php | 11 +-- tests/Australia/Queensland/LabourDayTest.php | 11 +-- .../Queensland/QueensBirthdayTest.php | 11 +-- tests/Australia/Queensland/QueenslandTest.php | 3 +- .../SouthAustralia/AdelaideCupDayTest.php | 11 +-- .../SouthAustralia/ChristmasDayTest.php | 13 ++-- .../SouthAustralia/EasterSaturdayTest.php | 16 ++-- .../SouthAustralia/LabourDayTest.php | 11 +-- .../SouthAustralia/ProclamationDayTest.php | 11 +-- .../SouthAustralia/QueensBirthdayTest.php | 11 +-- .../SouthAustralia/SouthAustraliaTest.php | 3 +- .../CentralNorth/CentralNorthTest.php | 3 +- .../CentralNorth/DevonportShowTest.php | 11 +-- tests/Australia/Tasmania/EightHourDayTest.php | 11 +-- .../FlindersIsland/FlindersIslandShowTest.php | 11 +-- .../FlindersIsland/FlindersIslandTest.php | 3 +- .../KingIsland/KingIslandShowTest.php | 11 +-- .../Tasmania/KingIsland/KingIslandTest.php | 3 +- .../Tasmania/Northeast/LauncestonShowTest.php | 11 +-- .../Tasmania/Northeast/NortheastTest.php | 3 +- .../Tasmania/Northwest/BurnieShowTest.php | 11 +-- .../Northwest/CircularHead/AGFESTTest.php | 11 +-- .../Tasmania/Northwest/NorthwestTest.php | 3 +- .../Australia/Tasmania/QueensBirthdayTest.php | 11 +-- .../Australia/Tasmania/RecreationDayTest.php | 11 +-- .../Tasmania/South/HobartShowTest.php | 11 +-- tests/Australia/Tasmania/South/SouthTest.php | 3 +- .../South/Southeast/HobartRegattaTest.php | 11 +-- tests/Australia/Tasmania/TasmaniaTest.php | 3 +- .../Victoria/AFLGrandFinalFridayTest.php | 11 +-- .../Australia/Victoria/EasterSaturdayTest.php | 16 ++-- tests/Australia/Victoria/EasterSundayTest.php | 13 ++-- tests/Australia/Victoria/LabourDayTest.php | 11 +-- .../Victoria/MelbourneCupDayTest.php | 11 +-- .../Australia/Victoria/QueensBirthdayTest.php | 11 +-- tests/Australia/Victoria/VictoriaTest.php | 3 +- .../WesternAustralia/LabourDayTest.php | 11 +-- .../WesternAustralia/QueensBirthdayTest.php | 11 +-- .../WesternAustraliaDayTest.php | 11 +-- .../WesternAustralia/WesternAustraliaTest.php | 3 +- tests/Austria/AllSaintsDayTest.php | 12 ++- tests/Austria/AscensionDayTest.php | 11 +-- tests/Austria/AssumptionOfMaryTest.php | 12 ++- tests/Austria/AustriaTest.php | 3 +- tests/Austria/Burgenland/BurgenlandTest.php | 3 +- tests/Austria/Burgenland/stMartinsDayTest.php | 12 ++- tests/Austria/Carinthia/CarinthiaTest.php | 3 +- tests/Austria/Carinthia/PlebisciteDayTest.php | 17 ++-- tests/Austria/Carinthia/StJosephsDayTest.php | 12 ++- tests/Austria/ChristmasTest.php | 12 ++- tests/Austria/CorpusChristiTest.php | 10 +-- tests/Austria/EasterMondayTest.php | 11 +-- tests/Austria/EasterTest.php | 11 +-- tests/Austria/EpiphanyTest.php | 12 ++- tests/Austria/ImmaculateConceptionTest.php | 12 ++- tests/Austria/InternationalWorkersDayTest.php | 12 ++- .../Austria/LowerAustria/LowerAustriaTest.php | 3 +- .../LowerAustria/StLeopoldsDayTest.php | 17 ++-- tests/Austria/NationalDayTest.php | 13 ++-- tests/Austria/NewYearsDayTest.php | 12 ++- tests/Austria/PentecostMondayTest.php | 11 +-- tests/Austria/PentecostTest.php | 11 +-- tests/Austria/Salzburg/SalzburgTest.php | 3 +- tests/Austria/Salzburg/StRupertsDayTest.php | 12 ++- tests/Austria/SecondChristmasDayTest.php | 12 ++- tests/Austria/Styria/StJosephsDayTest.php | 12 ++- tests/Austria/Styria/StyriaTest.php | 3 +- tests/Austria/Tyrol/StJosephsDayTest.php | 12 ++- tests/Austria/Tyrol/TyrolTest.php | 3 +- .../UpperAustria/StFloriansDayTest.php | 12 ++- .../Austria/UpperAustria/UpperAustriaTest.php | 3 +- tests/Austria/Vienna/StLeopoldsDayTest.php | 17 ++-- tests/Austria/Vienna/ViennaTest.php | 3 +- tests/Austria/Vorarlberg/StJosephsDayTest.php | 12 ++- tests/Austria/Vorarlberg/VorarlbergTest.php | 3 +- tests/Base/HolidayBetweenFilterTest.php | 77 +++++++++---------- tests/Base/HolidayOnFilterTest.php | 27 +++---- tests/Base/HolidayTest.php | 66 ++++++++-------- tests/Base/SubstituteHolidayTest.php | 44 +++++------ tests/Base/TranslationsTest.php | 3 +- tests/Base/YasumiTest.php | 59 +++++++------- tests/Base/YasumiWorkdayTest.php | 40 +++++----- tests/Belgium/AllSaintsDayTest.php | 12 ++- tests/Belgium/ArmisticeDayTest.php | 12 ++- tests/Belgium/AscensionDayTest.php | 11 +-- tests/Belgium/AssumptionOfMaryTest.php | 12 ++- tests/Belgium/BelgiumTest.php | 3 +- tests/Belgium/ChristmasTest.php | 12 ++- tests/Belgium/EasterMondayTest.php | 11 +-- tests/Belgium/EasterTest.php | 11 +-- tests/Belgium/InternationalWorkersDayTest.php | 12 ++- tests/Belgium/NationalDayTest.php | 12 ++- tests/Belgium/NewYearsDayTest.php | 12 ++- tests/Belgium/PentecostTest.php | 11 +-- tests/Belgium/pentecostMondayTest.php | 11 +-- tests/Bosnia/BosniaTest.php | 3 +- tests/Bosnia/ChristmasDayTest.php | 12 ++- tests/Bosnia/DayAfterNewYearsDay.php | 12 ++- tests/Bosnia/EasterTest.php | 11 +-- tests/Bosnia/IndependenceDayTest.php | 13 ++-- tests/Bosnia/InternationalWorkersDayTest.php | 12 ++- tests/Bosnia/NewYearsDayTest.php | 12 ++- tests/Bosnia/OrthodoxChristmasDay.php | 7 +- tests/Bosnia/SecondLabourDay.php | 12 ++- tests/Bosnia/StatehoodDayTest.php | 13 ++-- tests/Brazil/AllSoulsDayTest.php | 13 ++-- tests/Brazil/AshWednesdayTest.php | 11 +-- tests/Brazil/BrazilTest.php | 3 +- tests/Brazil/CarnavalMondayTest.php | 12 ++- tests/Brazil/CarnavalTuesdayTest.php | 12 ++- tests/Brazil/ChristmasDayTest.php | 11 +-- tests/Brazil/CorpusChristiTest.php | 10 +-- tests/Brazil/EasterTest.php | 7 +- tests/Brazil/GoodFridayTest.php | 10 +-- tests/Brazil/IndependenceDayTest.php | 13 ++-- tests/Brazil/InternationalWorkersDayTest.php | 11 +-- tests/Brazil/NewYearsDayTest.php | 11 +-- tests/Brazil/OurLadyOfAparecidaDayTest.php | 13 ++-- .../Brazil/ProclamationOfRepublicDayTest.php | 13 ++-- tests/Brazil/TiradentesDayTest.php | 13 ++-- tests/Canada/Alberta/AlbertaTest.php | 3 +- .../BritishColumbia/BritishColumbiaTest.php | 3 +- tests/Canada/CanadaDayTest.php | 15 ++-- tests/Canada/CanadaTest.php | 3 +- tests/Canada/ChristmasDayTest.php | 11 +-- tests/Canada/LabourDayTest.php | 13 ++-- tests/Canada/Manitoba/ManitobaTest.php | 3 +- .../Canada/NewBrunswick/NewBrunswickTest.php | 3 +- tests/Canada/NewYearsDayTest.php | 11 +-- .../NewfoundlandAndLabradorTest.php | 3 +- .../NorthwestTerritoriesTest.php | 3 +- tests/Canada/NovaScotia/NovaScotiaTest.php | 3 +- tests/Canada/Nunavut/NunavutTest.php | 3 +- tests/Canada/Ontario/OntarioTest.php | 3 +- .../PrinceEdwardIslandTest.php | 3 +- tests/Canada/Quebec/QuebecTest.php | 3 +- tests/Canada/RemembranceDayTest.php | 13 ++-- .../Canada/Saskatchewan/SaskatchewanTest.php | 3 +- tests/Canada/ThanksgivingDayTest.php | 13 ++-- .../Canada/TruthAndReconciliationDayTest.php | 13 ++-- tests/Canada/Yukon/YukonTest.php | 3 +- tests/Croatia/AllSaintsDayTest.php | 12 ++- tests/Croatia/AntifascistStruggleDayTest.php | 13 ++-- tests/Croatia/AssumptionOfMaryTest.php | 12 ++- tests/Croatia/ChristmasDayTest.php | 12 ++- tests/Croatia/CorpusChristiTest.php | 10 +-- tests/Croatia/CroatiaTest.php | 3 +- tests/Croatia/EasterMondayTest.php | 11 +-- tests/Croatia/EasterTest.php | 11 +-- tests/Croatia/EpiphanyTest.php | 12 ++- tests/Croatia/HomelandThanksgivingDayTest.php | 13 ++-- tests/Croatia/IndependenceDayTest.php | 15 ++-- tests/Croatia/InternationalWorkersDayTest.php | 12 ++- tests/Croatia/NewYearsDayTest.php | 12 ++- tests/Croatia/RemembranceDayTest.php | 13 ++-- tests/Croatia/StStephensDayTest.php | 12 ++- tests/Croatia/StatehoodDayTest.php | 15 ++-- tests/CzechRepublic/ChristmasDayTest.php | 12 ++- tests/CzechRepublic/ChristmasEveTest.php | 12 ++- tests/CzechRepublic/CzechRepublicTest.php | 3 +- tests/CzechRepublic/CzechStateHoodDayTest.php | 12 ++- tests/CzechRepublic/EasterMondayTest.php | 11 +-- tests/CzechRepublic/GoodFridayTest.php | 11 +-- .../IndependentCzechoslovakStateDayTest.php | 12 ++- .../InternationalWorkersDayTest.php | 12 ++- tests/CzechRepublic/JanHusDayTest.php | 12 ++- tests/CzechRepublic/NewYearsDayTest.php | 12 ++- .../RenewalOfIndependentCzechStateDayTest.php | 12 ++- .../SaintsCyrilAndMethodiusDayTest.php | 12 ++- .../CzechRepublic/SecondChristmasDayTest.php | 12 ++- .../StruggleForFreedomAndDemocracyDayTest.php | 12 ++- .../CzechRepublic/VictoryInEuropeDayTest.php | 12 ++- tests/Denmark/AscensionDayTest.php | 11 +-- tests/Denmark/ChristmasDayTest.php | 12 ++- tests/Denmark/ChristmasEveTest.php | 12 ++- tests/Denmark/ConstitutionDayTest.php | 13 ++-- tests/Denmark/DenmarkTest.php | 3 +- tests/Denmark/EasterMondayTest.php | 11 +-- tests/Denmark/EasterTest.php | 11 +-- tests/Denmark/GoodFridayTest.php | 11 +-- tests/Denmark/GreatPrayerDayTest.php | 13 ++-- tests/Denmark/InternationalWorkersDayTest.php | 12 ++- tests/Denmark/MaundyThursdayTest.php | 11 +-- tests/Denmark/NewYearsDayTest.php | 12 ++- tests/Denmark/NewYearsEveTest.php | 12 ++- tests/Denmark/PentecostMondayTest.php | 11 +-- tests/Denmark/PentecostTest.php | 11 +-- tests/Denmark/SecondChristmasDayTest.php | 12 ++- tests/Denmark/SummerTimeTest.php | 15 ++-- tests/Denmark/WinterTimeTest.php | 15 ++-- tests/Estonia/ChristmasDayTest.php | 7 +- tests/Estonia/ChristmasEveDayTest.php | 7 +- tests/Estonia/EasterDayTest.php | 13 ++-- tests/Estonia/EstoniaTest.php | 3 +- tests/Estonia/GoodFridayDayTest.php | 13 ++-- tests/Estonia/IndependenceDayTest.php | 13 ++-- tests/Estonia/InternationalWorkersDayTest.php | 7 +- tests/Estonia/NewYearsDayTest.php | 7 +- tests/Estonia/PentecostTest.php | 13 ++-- .../RestorationOfIndependenceDayTest.php | 13 ++-- tests/Estonia/SecondChristmasDayTest.php | 7 +- tests/Estonia/StJohnsDayTest.php | 7 +- tests/Estonia/VictoryDayTest.php | 13 ++-- tests/Finland/AllSaintsDayTest.php | 18 ++--- tests/Finland/AscensionDayTest.php | 11 +-- tests/Finland/ChristmasDayTest.php | 12 ++- tests/Finland/EasterMondayTest.php | 11 +-- tests/Finland/EasterTest.php | 11 +-- tests/Finland/EpiphanyTest.php | 12 ++- tests/Finland/FinlandTest.php | 3 +- tests/Finland/GoodFridayTest.php | 11 +-- tests/Finland/IndependenceDayTest.php | 13 ++-- tests/Finland/InternationalWorkersDayTest.php | 12 ++- tests/Finland/NewYearsDayTest.php | 12 ++- tests/Finland/PentecostTest.php | 11 +-- tests/Finland/SecondChristmasDayTest.php | 12 ++- tests/Finland/stJohnsDayTest.php | 13 ++-- tests/France/AllSaintsDayTest.php | 12 ++- tests/France/ArmisticeDayTest.php | 13 ++-- tests/France/AscensionDayTest.php | 11 +-- tests/France/AssumptionOfMaryTest.php | 12 ++- tests/France/BasRhin/BasRhinTest.php | 3 +- tests/France/BasRhin/GoodFridayTest.php | 11 +-- tests/France/BasRhin/stStephensDayTest.php | 12 ++- tests/France/BastilleDayTest.php | 13 ++-- tests/France/ChristmasDayTest.php | 12 ++- tests/France/EasterMondayTest.php | 11 +-- tests/France/FranceTest.php | 3 +- tests/France/HautRhin/GoodFridayTest.php | 11 +-- tests/France/HautRhin/HautRhinTest.php | 3 +- tests/France/HautRhin/stStephensDayTest.php | 12 ++- tests/France/InternationalWorkersDayTest.php | 12 ++- tests/France/Moselle/GoodFridayTest.php | 11 +-- tests/France/Moselle/MoselleTest.php | 3 +- tests/France/Moselle/stStephensDayTest.php | 12 ++- tests/France/NewYearsDayTest.php | 12 ++- tests/France/PentecostMondayTest.php | 11 +-- tests/France/VictoryInEuropeDayTest.php | 13 ++-- tests/Georgia/EasterTest.php | 11 +-- tests/Georgia/GeorgiaTest.php | 3 +- tests/Georgia/IndependenceDayTest.php | 7 +- tests/Georgia/InternationalWomensDayTest.php | 7 +- tests/Georgia/MtskhetobaDayTest.php | 7 +- tests/Georgia/NewYearsDayTest.php | 7 +- tests/Georgia/OrthodoxChristmasDayTest.php | 7 +- tests/Georgia/OrthodoxEpiphanyDayTest.php | 7 +- tests/Georgia/SecondNewYearDayTest.php | 7 +- tests/Georgia/StAndrewsDayTest.php | 7 +- tests/Georgia/StGeorgesDayTest.php | 7 +- tests/Georgia/StMarysDayTest.php | 7 +- tests/Georgia/UnityDayTest.php | 7 +- tests/Georgia/VictoryDayTest.php | 7 +- tests/Germany/AscensionDayTest.php | 11 +-- .../BadenWurttemberg/AllSaintsDayTest.php | 12 ++- .../BadenWurttemberg/BadenWurttembergTest.php | 3 +- .../BadenWurttemberg/CorpusChristiTest.php | 7 +- .../Germany/BadenWurttemberg/EpiphanyTest.php | 12 ++- tests/Germany/Bavaria/AllSaintsDayTest.php | 12 ++- tests/Germany/Bavaria/BavariaTest.php | 3 +- tests/Germany/Bavaria/CorpusChristiTest.php | 7 +- tests/Germany/Bavaria/EpiphanyTest.php | 12 ++- tests/Germany/Berlin/BerlinTest.php | 3 +- .../Berlin/DayOfLiberation2020Test.php | 11 +-- .../Berlin/InternationalWomensDay2019Test.php | 15 ++-- tests/Germany/Brandenburg/BrandenburgTest.php | 3 +- .../Brandenburg/ReformationDayTest.php | 17 ++-- tests/Germany/Bremen/BremenTest.php | 3 +- tests/Germany/Bremen/ReformationDayTest.php | 17 ++-- tests/Germany/ChristmasTest.php | 12 ++- tests/Germany/EasterMondayTest.php | 11 +-- tests/Germany/GermanUnityDayTest.php | 13 ++-- tests/Germany/GermanyTest.php | 3 +- tests/Germany/GoodFridayTest.php | 11 +-- .../Germany/Hamburg/DayOfReformationTest.php | 17 ++-- tests/Germany/Hamburg/HamburgTest.php | 3 +- tests/Germany/Hesse/CorpusChristiTest.php | 7 +- tests/Germany/Hesse/HesseTest.php | 3 +- tests/Germany/InternationalWorkersDayTest.php | 12 ++- tests/Germany/LowerSaxony/LowerSaxonyTest.php | 3 +- .../LowerSaxony/ReformationDayTest.php | 17 ++-- .../MecklenburgWesternPomeraniaTest.php | 3 +- .../ReformationDayTest.php | 13 ++-- tests/Germany/NewYearsDayTest.php | 12 ++- tests/Germany/NewYearsEveTest.php | 12 ++- .../NorthRhineWestphalia/AllSaintsDayTest.php | 12 ++- .../CorpusChristiTest.php | 7 +- .../NorthRhineWestphaliaTest.php | 3 +- tests/Germany/PentecostMondayTest.php | 11 +-- tests/Germany/PentecostTest.php | 11 +-- tests/Germany/ReformationDay2017Test.php | 15 ++-- .../RhinelandPalatinate/AllSaintsDayTest.php | 12 ++- .../RhinelandPalatinate/CorpusChristiTest.php | 7 +- .../RhinelandPalatinateTest.php | 3 +- tests/Germany/Saarland/AllSaintsDayTest.php | 12 ++- .../Germany/Saarland/AssumptionOfMaryTest.php | 12 ++- tests/Germany/Saarland/CorpusChristiTest.php | 7 +- tests/Germany/Saarland/SaarlandTest.php | 3 +- tests/Germany/Saxony/ReformationDayTest.php | 17 ++-- .../Saxony/RepentanceAndPrayerDayTest.php | 13 ++-- tests/Germany/Saxony/SaxonyTest.php | 3 +- tests/Germany/SaxonyAnhalt/EpiphanyTest.php | 12 ++- .../SaxonyAnhalt/ReformationDayTest.php | 17 ++-- .../Germany/SaxonyAnhalt/SaxonyAnhaltTest.php | 3 +- .../SchleswigHolstein/ReformationDayTest.php | 17 ++-- .../SchleswigHolsteinTest.php | 3 +- tests/Germany/SecondChristmasDayTest.php | 12 ++- .../Germany/Thuringia/ReformationDayTest.php | 17 ++-- tests/Germany/Thuringia/ThuringiaTest.php | 3 +- .../Thuringia/WorldChildrensDayTest.php | 17 ++-- tests/Greece/AnnunciationTest.php | 12 ++- tests/Greece/AscensionDayTest.php | 11 +-- tests/Greece/AssumptionOfMaryTest.php | 12 ++- tests/Greece/ChristmasDayTest.php | 12 ++- tests/Greece/CleanMondayTest.php | 11 +-- tests/Greece/EasterMondayTest.php | 11 +-- tests/Greece/EasterTest.php | 11 +-- tests/Greece/EpiphanyTest.php | 12 ++- tests/Greece/GreeceTest.php | 3 +- tests/Greece/IndepencenceDayTest.php | 13 ++-- tests/Greece/InternationalWorkersDayTest.php | 12 ++- tests/Greece/NewYearsDayTest.php | 12 ++- tests/Greece/OhiDayTest.php | 13 ++-- tests/Greece/PentecostMondayTest.php | 11 +-- tests/Greece/PentecostTest.php | 11 +-- tests/Greece/PolytechnioTest.php | 13 ++-- tests/Greece/ThreeHolyHierarchsTest.php | 12 ++- tests/Greece/goodFridayTest.php | 11 +-- tests/Hungary/AllSaintsDayTest.php | 12 ++- tests/Hungary/ChristmasTest.php | 12 ++- tests/Hungary/EasterMondayTest.php | 11 +-- tests/Hungary/EasterTest.php | 11 +-- tests/Hungary/HungaryTest.php | 3 +- tests/Hungary/InternationalWorkersDayTest.php | 12 ++- tests/Hungary/MemorialDay1848Test.php | 13 ++-- tests/Hungary/MemorialDay1956Test.php | 13 ++-- tests/Hungary/NewYearsDayTest.php | 12 ++- tests/Hungary/PentecostMondayTest.php | 11 +-- tests/Hungary/PentecostTest.php | 11 +-- tests/Hungary/SecondChristmasDayTest.php | 12 ++- tests/Hungary/StateFoundationDayTest.php | 13 ++-- tests/Ireland/AugustHolidayTest.php | 15 ++-- tests/Ireland/ChristmasDayTest.php | 15 ++-- tests/Ireland/EasterMondayTest.php | 16 ++-- tests/Ireland/EasterTest.php | 13 ++-- tests/Ireland/GoodFridayTest.php | 16 ++-- tests/Ireland/IrelandTest.php | 3 +- tests/Ireland/JuneHolidayTest.php | 17 ++-- tests/Ireland/MayDayTest.php | 17 ++-- tests/Ireland/NewYearsDayTest.php | 17 ++-- tests/Ireland/OctoberHolidayTest.php | 17 ++-- tests/Ireland/PentecostTest.php | 16 ++-- tests/Ireland/StPatricksDayTest.php | 17 ++-- tests/Ireland/StStephensDayTest.php | 15 ++-- tests/Ireland/pentecostMondayTest.php | 18 ++--- tests/Italy/AllSaintsDayTest.php | 12 ++- tests/Italy/AssumptionOfMaryTest.php | 12 ++- tests/Italy/ChristmasTest.php | 12 ++- tests/Italy/EasterMondayTest.php | 11 +-- tests/Italy/EasterTest.php | 11 +-- tests/Italy/EpiphanyTest.php | 12 ++- tests/Italy/ImmaculateConceptionTest.php | 12 ++- tests/Italy/InternationalWorkersDayTest.php | 12 ++- tests/Italy/ItalyTest.php | 3 +- tests/Italy/LiberationDayTest.php | 13 ++-- tests/Italy/NewYearsDayTest.php | 12 ++- tests/Italy/RepublicDayTest.php | 13 ++-- tests/Italy/stStephensDayTest.php | 12 ++- tests/Japan/AutumnalEquinoxDayTest.php | 15 ++-- tests/Japan/ChildrensDayTest.php | 17 ++-- tests/Japan/ComingOfAgeDayTest.php | 17 ++-- tests/Japan/ConstitutionMemorialDayTest.php | 17 ++-- tests/Japan/CoronationDayTest.php | 11 +-- tests/Japan/CultureDayTest.php | 17 ++-- tests/Japan/EmperorsBirthdayTest.php | 25 +++--- .../EnthronementProclamationCeremonyTest.php | 11 +-- tests/Japan/GreeneryDayTest.php | 25 +++--- tests/Japan/JapanTest.php | 3 +- tests/Japan/LabourThanksgivingDayTest.php | 17 ++-- tests/Japan/MarineDayTest.php | 25 +++--- tests/Japan/MountainDayTest.php | 25 +++--- tests/Japan/NationalFoundationDayTest.php | 17 ++-- tests/Japan/NewYearsDayTest.php | 17 ++-- tests/Japan/PublicBridgeDayTest.php | 9 +-- tests/Japan/RespectForTheAgedDayTest.php | 21 +++-- tests/Japan/ShowaDayTest.php | 17 ++-- tests/Japan/SportsDayTest.php | 31 ++++---- tests/Japan/VernalEquinoxDayTest.php | 15 ++-- tests/Latvia/ChristmasDayTest.php | 7 +- tests/Latvia/ChristmasEveDayTest.php | 7 +- tests/Latvia/EasterDayTest.php | 13 ++-- tests/Latvia/EasterMondayDayTest.php | 13 ++-- tests/Latvia/GoodFridayDayTest.php | 13 ++-- tests/Latvia/InternationalWorkersDayTest.php | 7 +- tests/Latvia/LatviaTest.php | 3 +- tests/Latvia/MidsummerEveDayTest.php | 7 +- tests/Latvia/NewYearsDayTest.php | 7 +- tests/Latvia/NewYearsEveDayTest.php | 7 +- ...oclamationOfTheRepublicOfLatviaDayTest.php | 15 ++-- .../RestorationOfIndependenceDayTest.php | 15 ++-- tests/Latvia/SecondChristmasDayTest.php | 7 +- tests/Latvia/StJohnsDayTest.php | 7 +- tests/Lithuania/AllSaintsDayTest.php | 7 +- tests/Lithuania/AllSoulsDayTest.php | 13 ++-- tests/Lithuania/AssumptionOfMaryDayTest.php | 7 +- tests/Lithuania/ChristmasDayTest.php | 7 +- tests/Lithuania/ChristmasEveDayTest.php | 7 +- tests/Lithuania/EasterDayTest.php | 13 ++-- tests/Lithuania/EasterMondayDayTest.php | 13 ++-- .../Lithuania/InternationalWorkersDayTest.php | 7 +- tests/Lithuania/LithuaniaTest.php | 3 +- tests/Lithuania/NewYearsDayTest.php | 7 +- ...rationOfIndependenceOfLithuaniaDayTest.php | 13 ++-- ...estorationOfTheStateOfLithuaniaDayTest.php | 13 ++-- tests/Lithuania/SecondChristmasDayTest.php | 7 +- tests/Lithuania/StJohnsDayTest.php | 7 +- tests/Lithuania/StatehoodDayTest.php | 13 ++-- tests/Luxembourg/AllSaintsDayTest.php | 12 ++- tests/Luxembourg/AscensionDayTest.php | 11 +-- tests/Luxembourg/AssumptionOfMaryTest.php | 12 ++- tests/Luxembourg/ChristmasDayTest.php | 12 ++- tests/Luxembourg/EasterMondayTest.php | 11 +-- tests/Luxembourg/EuropeDayTest.php | 13 ++-- .../InternationalWorkersDayTest.php | 12 ++- tests/Luxembourg/LuxembourgTest.php | 3 +- tests/Luxembourg/NationalDayTest.php | 12 ++- tests/Luxembourg/NewYearsDayTest.php | 12 ++- tests/Luxembourg/PentecostMondayTest.php | 11 +-- tests/Luxembourg/SecondChristmasDayTest.php | 12 ++- tests/Netherlands/AscensionDayTest.php | 11 +-- tests/Netherlands/AshWednesdayTest.php | 11 +-- tests/Netherlands/ChristmasDayTest.php | 12 ++- tests/Netherlands/CommemorationDayTest.php | 13 ++-- tests/Netherlands/EasterMondayTest.php | 11 +-- tests/Netherlands/EasterTest.php | 11 +-- tests/Netherlands/EpiphanyTest.php | 12 ++- tests/Netherlands/FathersDayTest.php | 11 +-- tests/Netherlands/GoodFridayTest.php | 11 +-- tests/Netherlands/HalloweenTest.php | 12 ++- .../InternationalWorkersDayTest.php | 12 ++- tests/Netherlands/KingsDayTest.php | 17 ++-- tests/Netherlands/LiberationDayTest.php | 13 ++-- tests/Netherlands/MothersDayTest.php | 11 +-- tests/Netherlands/NetherlandsTest.php | 3 +- tests/Netherlands/NewYearsDayTest.php | 12 ++- tests/Netherlands/PentecostTest.php | 11 +-- tests/Netherlands/QueensDayTest.php | 31 ++++---- tests/Netherlands/SummertimeTest.php | 13 ++-- tests/Netherlands/ValentinesDayTest.php | 12 ++- tests/Netherlands/WintertimeTest.php | 13 ++-- tests/Netherlands/WorldAnimalDayTest.php | 13 ++-- tests/Netherlands/carnivalDayTest.php | 11 +-- tests/Netherlands/pentecostMondayTest.php | 11 +-- tests/Netherlands/princesDayTest.php | 11 +-- tests/Netherlands/secondCarnivalDay.php | 25 +++--- tests/Netherlands/secondChristmasdayTest.php | 12 ++- tests/Netherlands/stMartinsDayTest.php | 12 ++- tests/Netherlands/stNicholasDayTest.php | 12 ++- tests/Netherlands/thirdCarnivalDay.php | 25 +++--- tests/NewZealand/AnzacDayTest.php | 15 ++-- tests/NewZealand/BoxingDayTest.php | 18 ++--- tests/NewZealand/ChristmasDayTest.php | 18 ++--- tests/NewZealand/DayAfterNewYearsDayTest.php | 20 ++--- tests/NewZealand/EasterMondayTest.php | 16 ++-- tests/NewZealand/GoodFridayTest.php | 16 ++-- tests/NewZealand/LabourDayTest.php | 17 ++-- tests/NewZealand/NewYearsDayTest.php | 20 ++--- tests/NewZealand/NewZealandTest.php | 3 +- tests/NewZealand/QueensBirthdayTest.php | 15 ++-- tests/NewZealand/WaitangiDayTest.php | 15 ++-- tests/Norway/AscensionDayTest.php | 11 +-- tests/Norway/ChristmasDayTest.php | 12 ++- tests/Norway/ConstitutionDayTest.php | 13 ++-- tests/Norway/EasterMondayTest.php | 11 +-- tests/Norway/EasterTest.php | 11 +-- tests/Norway/GoodFridayTest.php | 11 +-- tests/Norway/InternationalWorkersDayTest.php | 12 ++- tests/Norway/MaundyThursdayTest.php | 11 +-- tests/Norway/NewYearsDayTest.php | 12 ++- tests/Norway/NorwayTest.php | 3 +- tests/Norway/PentecostMondayTest.php | 11 +-- tests/Norway/PentecostTest.php | 11 +-- tests/Norway/SecondChristmasDayTest.php | 12 ++- tests/Poland/AllSaintsDayTest.php | 12 ++- tests/Poland/AssumptionOfMaryTest.php | 12 ++- tests/Poland/ChristmasTest.php | 12 ++- tests/Poland/ConstitutionDayTest.php | 13 ++-- tests/Poland/CorpusChristiTest.php | 11 +-- tests/Poland/EasterMondayTest.php | 11 +-- tests/Poland/EasterTest.php | 11 +-- tests/Poland/EpiphanyTest.php | 12 ++- tests/Poland/IndependenceDayTest.php | 13 ++-- tests/Poland/InternationalWorkersDayTest.php | 12 ++- tests/Poland/NewYearsDayTest.php | 12 ++- tests/Poland/PentecostTest.php | 11 +-- tests/Poland/PolandTest.php | 3 +- tests/Poland/SecondChristmasDayTest.php | 12 ++- tests/Portugal/AllSaintsDayTest.php | 15 ++-- tests/Portugal/AssumptionOfMaryTest.php | 12 ++- tests/Portugal/CarnationRevolutionDayTest.php | 13 ++-- tests/Portugal/ChristmasTest.php | 12 ++- tests/Portugal/CorpusChristiTest.php | 13 ++-- tests/Portugal/EasterTest.php | 11 +-- tests/Portugal/GoodFridayTest.php | 11 +-- tests/Portugal/ImmaculateConceptionTest.php | 12 ++- .../Portugal/InternationalWorkersDayTest.php | 12 ++- tests/Portugal/NewYearsDayTest.php | 12 ++- tests/Portugal/PortugalDayTest.php | 17 ++-- tests/Portugal/PortugalTest.php | 3 +- tests/Portugal/PortugueseRepublicDayTest.php | 27 +++---- .../RestorationOfIndependenceTest.php | 25 +++--- tests/Randomizer.php | 64 ++++++++------- tests/Romania/AssumptionOfMaryTest.php | 13 ++-- tests/Romania/ChildrensDayTest.php | 13 ++-- tests/Romania/ChristmasDayTest.php | 12 ++- tests/Romania/ConstantinBrancusiDayTest.php | 13 ++-- tests/Romania/DayAfterNewYearsDayTest.php | 12 ++- tests/Romania/EasterMondayTest.php | 11 +-- tests/Romania/EasterTest.php | 11 +-- tests/Romania/InternationalWorkersDayTest.php | 12 ++- tests/Romania/NationalDayTest.php | 21 +++-- tests/Romania/NewYearsDayTest.php | 12 ++- tests/Romania/PentecostMondayTest.php | 13 ++-- tests/Romania/PentecostTest.php | 13 ++-- tests/Romania/RomaniaTest.php | 3 +- tests/Romania/SecondChristmasDayTest.php | 12 ++- tests/Romania/StAndrewsDayTest.php | 13 ++-- tests/Romania/UnitedPrincipalitiesDayTest.php | 13 ++-- .../Russia/DefenceOfTheFatherlandDayTest.php | 13 ++-- tests/Russia/InternationalWomensDayTest.php | 7 +- tests/Russia/NewYearHolidaysDay2Test.php | 7 +- tests/Russia/NewYearHolidaysDay3Test.php | 7 +- tests/Russia/NewYearHolidaysDay4Test.php | 7 +- tests/Russia/NewYearHolidaysDay5Test.php | 7 +- tests/Russia/NewYearHolidaysDay6Test.php | 7 +- tests/Russia/NewYearHolidaysDay8Test.php | 7 +- tests/Russia/NewYearsDayTest.php | 7 +- tests/Russia/OrthodoxChristmasDayTest.php | 7 +- tests/Russia/RussiaDayTest.php | 13 ++-- tests/Russia/RussiaTest.php | 3 +- tests/Russia/SpringAndLabourDayTest.php | 7 +- tests/Russia/UnityDayTest.php | 13 ++-- tests/Russia/VictoryDayTest.php | 7 +- tests/Slovakia/AllSaintsDayTest.php | 12 ++- tests/Slovakia/ChristmasDayTest.php | 12 ++- tests/Slovakia/ChristmasEveTest.php | 12 ++- tests/Slovakia/EasterMondayTest.php | 29 ++++--- tests/Slovakia/EpiphanyTest.php | 12 ++- tests/Slovakia/GoodFridayTest.php | 29 ++++--- .../Slovakia/InternationalWorkersDayTest.php | 12 ++- tests/Slovakia/OurLadyOfSorrowsDayTest.php | 12 ++- .../SaintsCyrilAndMethodiusDayTest.php | 12 ++- tests/Slovakia/SecondChristmasDayTest.php | 12 ++- tests/Slovakia/SlovakConstitutionDayTest.php | 12 ++- tests/Slovakia/SlovakIndependeceDayTest.php | 12 ++- .../SlovakNationalUprisingDayTest.php | 12 ++- tests/Slovakia/SlovakiaTest.php | 3 +- .../StruggleForFreedomAndDemocracyDayTest.php | 12 ++- tests/Slovakia/VictoryInEuropeDayTest.php | 12 ++- tests/SouthAfrica/ChristmasDayTest.php | 20 ++--- tests/SouthAfrica/FamilyDayTest.php | 18 ++--- tests/SouthAfrica/FreedomDayTest.php | 20 ++--- tests/SouthAfrica/GoodFridayTest.php | 18 ++--- tests/SouthAfrica/HeritageDayTest.php | 20 ++--- tests/SouthAfrica/HumanRightsDayTest.php | 20 ++--- .../MunicipalElections2016DayTest.php | 15 ++-- tests/SouthAfrica/NationalWomensDayTest.php | 20 ++--- tests/SouthAfrica/NewYearsDayTest.php | 20 ++--- tests/SouthAfrica/ReconciliationDayTest.php | 20 ++--- tests/SouthAfrica/SecondChristmasDayTest.php | 20 ++--- tests/SouthAfrica/SouthAfricaTest.php | 3 +- .../SubstituteDayOfGoodwillTest.php | 15 ++-- tests/SouthAfrica/WorkersDayTest.php | 20 ++--- tests/SouthAfrica/YouthDayTest.php | 20 ++--- tests/SouthKorea/ArborDayTest.php | 15 ++-- tests/SouthKorea/ArmedForcesDayTest.php | 15 ++-- tests/SouthKorea/BuddhasBirthdayTest.php | 13 ++-- tests/SouthKorea/ChildrensDayTest.php | 31 ++++---- tests/SouthKorea/ChristmasDayTest.php | 13 ++-- tests/SouthKorea/ChuseokTest.php | 44 +++++------ tests/SouthKorea/ConstitutionDayTest.php | 15 ++-- tests/SouthKorea/GaecheonjeolTest.php | 31 ++++---- tests/SouthKorea/HangulDayTest.php | 23 +++--- .../IndependenceMovementDayTest.php | 25 +++--- tests/SouthKorea/LiberationDayTest.php | 23 +++--- tests/SouthKorea/MemorialDayTest.php | 13 ++-- tests/SouthKorea/NewYearsDayTest.php | 20 ++--- tests/SouthKorea/SeollalTest.php | 30 ++++---- tests/SouthKorea/SouthKoreaTest.php | 3 +- tests/Spain/AllSaintsDayTest.php | 12 ++- tests/Spain/Andalusia/AndalusiaDayTest.php | 13 ++-- tests/Spain/Andalusia/AndalusiaTest.php | 3 +- tests/Spain/Aragon/AragonTest.php | 3 +- tests/Spain/Aragon/StGeorgesDayTest.php | 11 +-- tests/Spain/AssumptionOfMaryTest.php | 12 ++- tests/Spain/Asturias/AsturiasDayTest.php | 13 ++-- tests/Spain/Asturias/AsturiasTest.php | 3 +- .../BalearicIslandsDayTest.php | 13 ++-- .../BalearicIslands/BalearicIslandsTest.php | 3 +- .../BasqueCountry/BasqueCountryDayTest.php | 15 ++-- .../Spain/BasqueCountry/BasqueCountryTest.php | 3 +- .../CanaryIslands/CanaryIslandsDayTest.php | 13 ++-- .../Spain/CanaryIslands/CanaryIslandsTest.php | 3 +- tests/Spain/Cantabria/CantabriaDayTest.php | 13 ++-- tests/Spain/Cantabria/CantabriaTest.php | 3 +- .../CastileAndLeon/CastileAndLeonDayTest.php | 13 ++-- .../CastileAndLeon/CastileAndLeonTest.php | 3 +- .../CastillaLaManchaDayTest.php | 13 ++-- .../CastillaLaMancha/CastillaLaManchaTest.php | 3 +- tests/Spain/Catalonia/CataloniaTest.php | 3 +- .../Catalonia/nationalCataloniaDayTest.php | 13 ++-- tests/Spain/Catalonia/stJohnsDayTest.php | 12 ++- tests/Spain/Ceuta/CeutaTest.php | 3 +- tests/Spain/Ceuta/ceutaDayTest.php | 13 ++-- tests/Spain/ChristmasTest.php | 12 ++- .../CommunityOfMadridTest.php | 3 +- .../DosdeMayoUprisingDayTest.php | 11 +-- tests/Spain/ConstitutionDayTest.php | 13 ++-- tests/Spain/EasterMondayTest.php | 11 +-- tests/Spain/EpiphanyTest.php | 12 ++- .../Spain/Extremadura/ExtremaduraDayTest.php | 13 ++-- tests/Spain/Extremadura/ExtremaduraTest.php | 3 +- tests/Spain/Galicia/GaliciaTest.php | 3 +- .../Galicia/GalicianLiteratureDayTest.php | 13 ++-- tests/Spain/Galicia/stJamesDayTest.php | 13 ++-- tests/Spain/GoodFridayTest.php | 11 +-- tests/Spain/ImmaculateConceptionTest.php | 12 ++- tests/Spain/InternationalWorkersDayTest.php | 12 ++- tests/Spain/LaRioja/LaRiojaDayTest.php | 13 ++-- tests/Spain/LaRioja/LaRiojaTest.php | 3 +- tests/Spain/MaundyThursdayTest.php | 11 +-- tests/Spain/Melilla/MelillaTest.php | 3 +- tests/Spain/NationalDayTest.php | 13 ++-- tests/Spain/Navarre/NavarreTest.php | 3 +- tests/Spain/NewYearsDayTest.php | 12 ++- .../RegionOfMurcia/RegionOfMurciaDayTest.php | 13 ++-- .../RegionOfMurcia/RegionOfMurciaTest.php | 3 +- tests/Spain/SpainTest.php | 3 +- .../ValencianCommunityDayTest.php | 13 ++-- .../ValencianCommunityTest.php | 3 +- tests/Spain/ValentinesDayTest.php | 12 ++- tests/Spain/stJosephsDayTest.php | 12 ++- tests/Sweden/AllSaintsDayTest.php | 18 ++--- tests/Sweden/AllSaintsEveTest.php | 18 ++--- tests/Sweden/AscensionDayTest.php | 11 +-- tests/Sweden/ChristmasDayTest.php | 12 ++- tests/Sweden/ChristmasEveTest.php | 12 ++- tests/Sweden/EasterMondayTest.php | 11 +-- tests/Sweden/EasterTest.php | 11 +-- tests/Sweden/EpiphanyEveTest.php | 12 ++- tests/Sweden/EpiphanyTest.php | 12 ++- tests/Sweden/GoodFridayTest.php | 11 +-- tests/Sweden/InternationalWorkersDayTest.php | 12 ++- tests/Sweden/NationalDayTest.php | 15 ++-- tests/Sweden/NewYearsDayTest.php | 12 ++- tests/Sweden/NewYearsEveTest.php | 12 ++- tests/Sweden/PentecostTest.php | 11 +-- tests/Sweden/SecondChristmasDayTest.php | 12 ++- tests/Sweden/SwedenTest.php | 3 +- tests/Sweden/WalpurgisEveTest.php | 12 ++- tests/Switzerland/Aargau/AargauTest.php | 3 +- tests/Switzerland/Aargau/AscensionDayTest.php | 11 +-- tests/Switzerland/Aargau/ChristmasDayTest.php | 12 ++- tests/Switzerland/Aargau/GoodFridayTest.php | 11 +-- tests/Switzerland/Aargau/NewYearsDayTest.php | 12 ++- .../AppenzellAusserrhodenTest.php | 3 +- .../AscensionDayTest.php | 11 +-- .../ChristmasDayTest.php | 12 ++- .../EasterMondayTest.php | 11 +-- .../AppenzellAusserrhoden/GoodFridayTest.php | 11 +-- .../AppenzellAusserrhoden/NewYearsDayTest.php | 12 ++- .../PentecostMondayTest.php | 11 +-- .../StStephensDayTest.php | 12 ++- .../AppenzellInnerrhoden/AllSaintsDayTest.php | 12 ++- .../AppenzellInnerrhodenTest.php | 3 +- .../AppenzellInnerrhoden/AscensionDayTest.php | 11 +-- .../AssumptionOfMaryTest.php | 12 ++- .../AppenzellInnerrhoden/ChristmasDayTest.php | 12 ++- .../CorpusChristiTest.php | 10 +-- .../AppenzellInnerrhoden/EasterMondayTest.php | 11 +-- .../AppenzellInnerrhoden/GoodFridayTest.php | 11 +-- .../ImmaculateConceptionTest.php | 12 ++- .../AppenzellInnerrhoden/NewYearsDayTest.php | 12 ++- .../PentecostMondayTest.php | 11 +-- .../StStephensDayTest.php | 12 ++- .../BaselLandschaft/AscensionDayTest.php | 11 +-- .../BaselLandschaft/BaselLandschaftTest.php | 3 +- .../BaselLandschaft/ChristmasDayTest.php | 12 ++- .../BaselLandschaft/EasterMondayTest.php | 11 +-- .../BaselLandschaft/GoodFridayTest.php | 11 +-- .../BaselLandschaft/NewYearsDayTest.php | 12 ++- .../BaselLandschaft/PentecostMondayTest.php | 11 +-- .../BaselLandschaft/StStephensDayTest.php | 12 ++- .../BaselLandschaft/WorkersDayTest.php | 15 ++-- .../BaselStadt/AscensionDayTest.php | 11 +-- .../Switzerland/BaselStadt/BaselStadtTest.php | 3 +- .../BaselStadt/ChristmasDayTest.php | 12 ++- .../BaselStadt/EasterMondayTest.php | 11 +-- .../Switzerland/BaselStadt/GoodFridayTest.php | 11 +-- .../BaselStadt/NewYearsDayTest.php | 12 ++- .../BaselStadt/PentecostMondayTest.php | 11 +-- .../BaselStadt/StStephensDayTest.php | 12 ++- .../Switzerland/BaselStadt/WorkersDayTest.php | 15 ++-- tests/Switzerland/Bern/AscensionDayTest.php | 11 +-- tests/Switzerland/Bern/BerchtoldsTagTest.php | 11 +-- tests/Switzerland/Bern/BernTest.php | 3 +- tests/Switzerland/Bern/ChristmasDayTest.php | 12 ++- tests/Switzerland/Bern/EasterMondayTest.php | 11 +-- tests/Switzerland/Bern/GoodFridayTest.php | 11 +-- tests/Switzerland/Bern/NewYearsDayTest.php | 12 ++- .../Switzerland/Bern/PentecostMondayTest.php | 11 +-- tests/Switzerland/Bern/StStephensDayTest.php | 12 ++- .../Switzerland/Fribourg/AllSaintsDayTest.php | 12 ++- .../Switzerland/Fribourg/AscensionDayTest.php | 11 +-- .../Fribourg/AssumptionOfMaryTest.php | 12 ++- .../Fribourg/BerchtoldsTagTest.php | 11 +-- .../Switzerland/Fribourg/ChristmasDayTest.php | 12 ++- .../Fribourg/CorpusChristiTest.php | 10 +-- .../Switzerland/Fribourg/December26thTest.php | 11 +-- .../Switzerland/Fribourg/EasterMondayTest.php | 11 +-- tests/Switzerland/Fribourg/FribourgTest.php | 3 +- tests/Switzerland/Fribourg/GoodFridayTest.php | 11 +-- .../Fribourg/ImmaculateConceptionTest.php | 12 ++- .../Switzerland/Fribourg/NewYearsDayTest.php | 12 ++- .../Fribourg/PentecostMondayTest.php | 11 +-- tests/Switzerland/Geneva/AscensionDayTest.php | 11 +-- tests/Switzerland/Geneva/ChristmasDayTest.php | 12 ++- tests/Switzerland/Geneva/EasterMondayTest.php | 11 +-- tests/Switzerland/Geneva/GenevaTest.php | 3 +- tests/Switzerland/Geneva/GoodFridayTest.php | 11 +-- .../Switzerland/Geneva/JeuneGenevoisTest.php | 22 +++--- tests/Switzerland/Geneva/NewYearsDayTest.php | 12 ++- .../Geneva/PentecostMondayTest.php | 11 +-- .../Geneva/RestaurationGenevoiseTest.php | 11 +-- tests/Switzerland/Glarus/AllSaintsDayTest.php | 12 ++- tests/Switzerland/Glarus/AscensionDayTest.php | 11 +-- .../Switzerland/Glarus/BerchtoldsTagTest.php | 11 +-- tests/Switzerland/Glarus/ChristmasDayTest.php | 12 ++- tests/Switzerland/Glarus/EasterMondayTest.php | 11 +-- tests/Switzerland/Glarus/GlarusTest.php | 3 +- tests/Switzerland/Glarus/GoodFridayTest.php | 11 +-- .../Switzerland/Glarus/NafelserFahrtTest.php | 13 ++-- tests/Switzerland/Glarus/NewYearsDayTest.php | 12 ++- .../Glarus/PentecostMondayTest.php | 11 +-- .../Switzerland/Glarus/StStephensDayTest.php | 12 ++- .../Switzerland/Grisons/AscensionDayTest.php | 11 +-- .../Switzerland/Grisons/ChristmasDayTest.php | 12 ++- .../Switzerland/Grisons/EasterMondayTest.php | 11 +-- tests/Switzerland/Grisons/GoodFridayTest.php | 11 +-- tests/Switzerland/Grisons/GrisonsTest.php | 3 +- tests/Switzerland/Grisons/NewYearsDayTest.php | 12 ++- .../Grisons/PentecostMondayTest.php | 11 +-- .../Switzerland/Grisons/StStephensDayTest.php | 12 ++- tests/Switzerland/Jura/AllSaintsDayTest.php | 12 ++- tests/Switzerland/Jura/AscensionDayTest.php | 11 +-- .../Switzerland/Jura/AssumptionOfMaryTest.php | 12 ++- tests/Switzerland/Jura/BerchtoldsTagTest.php | 11 +-- tests/Switzerland/Jura/BettagsMontagTest.php | 16 ++-- tests/Switzerland/Jura/ChristmasDayTest.php | 12 ++- tests/Switzerland/Jura/CorpusChristiTest.php | 10 +-- tests/Switzerland/Jura/EasterMondayTest.php | 11 +-- tests/Switzerland/Jura/EasterTest.php | 11 +-- tests/Switzerland/Jura/GoodFridayTest.php | 11 +-- tests/Switzerland/Jura/JuraTest.php | 3 +- tests/Switzerland/Jura/NewYearsDayTest.php | 12 ++- .../Switzerland/Jura/PentecostMondayTest.php | 11 +-- tests/Switzerland/Jura/PentecostTest.php | 11 +-- .../Jura/PlebisciteJurassienTest.php | 13 ++-- tests/Switzerland/Jura/WorkersDayTest.php | 15 ++-- .../Switzerland/Lucerne/AllSaintsDayTest.php | 12 ++- .../Switzerland/Lucerne/AscensionDayTest.php | 11 +-- .../Lucerne/AssumptionOfMaryTest.php | 12 ++- .../Switzerland/Lucerne/BerchtoldsTagTest.php | 11 +-- .../Switzerland/Lucerne/ChristmasDayTest.php | 12 ++- .../Switzerland/Lucerne/CorpusChristiTest.php | 10 +-- .../Switzerland/Lucerne/EasterMondayTest.php | 11 +-- tests/Switzerland/Lucerne/GoodFridayTest.php | 11 +-- .../Lucerne/ImmaculateConceptionTest.php | 12 ++- tests/Switzerland/Lucerne/LucerneTest.php | 3 +- tests/Switzerland/Lucerne/NewYearsDayTest.php | 12 ++- .../Lucerne/PentecostMondayTest.php | 11 +-- .../Switzerland/Lucerne/StStephensDayTest.php | 12 ++- .../Neuchatel/AscensionDayTest.php | 11 +-- .../Neuchatel/BettagsMontagTest.php | 16 ++-- .../Neuchatel/ChristmasDayTest.php | 12 ++- .../Neuchatel/December26thTest.php | 7 +- .../Neuchatel/EasterMondayTest.php | 11 +-- .../Switzerland/Neuchatel/GoodFridayTest.php | 11 +-- .../Neuchatel/InstaurationRepubliqueTest.php | 13 ++-- .../Switzerland/Neuchatel/January2ndTest.php | 7 +- tests/Switzerland/Neuchatel/NeuchatelTest.php | 3 +- .../Switzerland/Neuchatel/NewYearsDayTest.php | 12 ++- .../Neuchatel/PentecostMondayTest.php | 11 +-- .../Switzerland/Neuchatel/WorkersDayTest.php | 15 ++-- .../Nidwalden/AllSaintsDayTest.php | 12 ++- .../Nidwalden/AscensionDayTest.php | 11 +-- .../Nidwalden/AssumptionOfMaryTest.php | 12 ++- .../Nidwalden/ChristmasDayTest.php | 12 ++- .../Nidwalden/CorpusChristiTest.php | 10 +-- .../Nidwalden/EasterMondayTest.php | 11 +-- .../Switzerland/Nidwalden/GoodFridayTest.php | 11 +-- .../Nidwalden/ImmaculateConceptionTest.php | 12 ++- .../Switzerland/Nidwalden/NewYearsDayTest.php | 12 ++- tests/Switzerland/Nidwalden/NidwaldenTest.php | 3 +- .../Nidwalden/PentecostMondayTest.php | 11 +-- .../Switzerland/Nidwalden/StJosephDayTest.php | 12 ++- .../Nidwalden/StStephensDayTest.php | 12 ++- .../Switzerland/Obwalden/AllSaintsDayTest.php | 12 ++- .../Switzerland/Obwalden/AscensionDayTest.php | 11 +-- .../Obwalden/AssumptionOfMaryTest.php | 12 ++- .../Obwalden/BerchtoldsTagTest.php | 11 +-- .../Obwalden/BruderKlausenFestTest.php | 17 ++-- .../Switzerland/Obwalden/ChristmasDayTest.php | 12 ++- .../Obwalden/CorpusChristiTest.php | 10 +-- .../Switzerland/Obwalden/EasterMondayTest.php | 11 +-- tests/Switzerland/Obwalden/GoodFridayTest.php | 11 +-- .../Obwalden/ImmaculateConceptionTest.php | 12 ++- .../Switzerland/Obwalden/NewYearsDayTest.php | 12 ++- tests/Switzerland/Obwalden/ObwaldenTest.php | 3 +- .../Obwalden/PentecostMondayTest.php | 11 +-- .../Obwalden/StStephensDayTest.php | 12 ++- .../Schaffhausen/AscensionDayTest.php | 11 +-- .../Schaffhausen/BerchtoldsTagTest.php | 11 +-- .../Schaffhausen/ChristmasDayTest.php | 12 ++- .../Schaffhausen/EasterMondayTest.php | 11 +-- .../Schaffhausen/GoodFridayTest.php | 11 +-- .../Schaffhausen/NewYearsDayTest.php | 12 ++- .../Schaffhausen/PentecostMondayTest.php | 11 +-- .../Schaffhausen/SchaffhausenTest.php | 3 +- .../Schaffhausen/StStephensDayTest.php | 12 ++- .../Schaffhausen/WorkersDayTest.php | 15 ++-- tests/Switzerland/Schwyz/AllSaintsDayTest.php | 12 ++- tests/Switzerland/Schwyz/AscensionDayTest.php | 11 +-- .../Schwyz/AssumptionOfMaryTest.php | 12 ++- tests/Switzerland/Schwyz/ChristmasDayTest.php | 12 ++- .../Switzerland/Schwyz/CorpusChristiTest.php | 10 +-- tests/Switzerland/Schwyz/EasterMondayTest.php | 11 +-- tests/Switzerland/Schwyz/EpiphanyTest.php | 12 ++- tests/Switzerland/Schwyz/GoodFridayTest.php | 11 +-- .../Schwyz/ImmaculateConceptionTest.php | 12 ++- tests/Switzerland/Schwyz/NewYearsDayTest.php | 12 ++- .../Schwyz/PentecostMondayTest.php | 11 +-- tests/Switzerland/Schwyz/SchwyzTest.php | 3 +- tests/Switzerland/Schwyz/StJosephDayTest.php | 12 ++- .../Switzerland/Schwyz/StStephensDayTest.php | 12 ++- .../Solothurn/AscensionDayTest.php | 11 +-- .../Solothurn/BerchtoldsTagTest.php | 11 +-- .../Solothurn/ChristmasDayTest.php | 12 ++- .../Switzerland/Solothurn/GoodFridayTest.php | 11 +-- .../Switzerland/Solothurn/NewYearsDayTest.php | 12 ++- tests/Switzerland/Solothurn/SolothurnTest.php | 3 +- .../Switzerland/StGallen/AllSaintsDayTest.php | 12 ++- .../Switzerland/StGallen/AscensionDayTest.php | 11 +-- .../Switzerland/StGallen/ChristmasDayTest.php | 12 ++- .../Switzerland/StGallen/EasterMondayTest.php | 11 +-- tests/Switzerland/StGallen/GoodFridayTest.php | 11 +-- .../Switzerland/StGallen/NewYearsDayTest.php | 12 ++- .../StGallen/PentecostMondayTest.php | 11 +-- tests/Switzerland/StGallen/StGallenTest.php | 3 +- .../StGallen/StStephensDayTest.php | 12 ++- tests/Switzerland/SwissNationalDayTest.php | 23 +++--- tests/Switzerland/SwitzerlandTest.php | 3 +- .../Switzerland/Thurgau/AscensionDayTest.php | 11 +-- .../Switzerland/Thurgau/BerchtoldsTagTest.php | 11 +-- .../Switzerland/Thurgau/ChristmasDayTest.php | 12 ++- .../Switzerland/Thurgau/EasterMondayTest.php | 11 +-- tests/Switzerland/Thurgau/GoodFridayTest.php | 11 +-- tests/Switzerland/Thurgau/NewYearsDayTest.php | 12 ++- .../Thurgau/PentecostMondayTest.php | 11 +-- .../Switzerland/Thurgau/StStephensDayTest.php | 12 ++- tests/Switzerland/Thurgau/ThurgauTest.php | 3 +- tests/Switzerland/Thurgau/WorkersDayTest.php | 15 ++-- tests/Switzerland/Ticino/AllSaintsDayTest.php | 12 ++- tests/Switzerland/Ticino/AscensionDayTest.php | 11 +-- .../Ticino/AssumptionOfMaryTest.php | 12 ++- tests/Switzerland/Ticino/ChristmasDayTest.php | 12 ++- .../Switzerland/Ticino/CorpusChristiTest.php | 10 +-- tests/Switzerland/Ticino/EasterMondayTest.php | 11 +-- tests/Switzerland/Ticino/EpiphanyTest.php | 12 ++- .../Ticino/ImmaculateConceptionTest.php | 12 ++- tests/Switzerland/Ticino/NewYearsDayTest.php | 12 ++- .../Ticino/PentecostMondayTest.php | 11 +-- tests/Switzerland/Ticino/StJosephDayTest.php | 12 ++- tests/Switzerland/Ticino/StPeterPaulTest.php | 12 ++- .../Switzerland/Ticino/StStephensDayTest.php | 12 ++- tests/Switzerland/Ticino/TicinoTest.php | 3 +- tests/Switzerland/Ticino/WorkersDayTest.php | 15 ++-- tests/Switzerland/Uri/AllSaintsDayTest.php | 12 ++- tests/Switzerland/Uri/AscensionDayTest.php | 11 +-- .../Switzerland/Uri/AssumptionOfMaryTest.php | 12 ++- tests/Switzerland/Uri/ChristmasDayTest.php | 12 ++- tests/Switzerland/Uri/CorpusChristiTest.php | 10 +-- tests/Switzerland/Uri/EasterMondayTest.php | 11 +-- tests/Switzerland/Uri/EpiphanyTest.php | 12 ++- tests/Switzerland/Uri/GoodFridayTest.php | 11 +-- .../Uri/ImmaculateConceptionTest.php | 12 ++- tests/Switzerland/Uri/NewYearsDayTest.php | 12 ++- tests/Switzerland/Uri/PentecostMondayTest.php | 11 +-- tests/Switzerland/Uri/StJosephDayTest.php | 12 ++- tests/Switzerland/Uri/StStephensDayTest.php | 12 ++- tests/Switzerland/Uri/UriTest.php | 3 +- tests/Switzerland/Valais/AllSaintsDayTest.php | 12 ++- tests/Switzerland/Valais/AscensionDayTest.php | 11 +-- .../Valais/AssumptionOfMaryTest.php | 12 ++- tests/Switzerland/Valais/ChristmasDayTest.php | 12 ++- .../Switzerland/Valais/CorpusChristiTest.php | 10 +-- .../Valais/ImmaculateConceptionTest.php | 12 ++- tests/Switzerland/Valais/NewYearsDayTest.php | 12 ++- tests/Switzerland/Valais/StJosephDayTest.php | 12 ++- tests/Switzerland/Valais/ValaisTest.php | 3 +- tests/Switzerland/Vaud/AscensionDayTest.php | 11 +-- tests/Switzerland/Vaud/BerchtoldsTagTest.php | 11 +-- tests/Switzerland/Vaud/BettagsMontagTest.php | 16 ++-- tests/Switzerland/Vaud/ChristmasDayTest.php | 12 ++- tests/Switzerland/Vaud/EasterMondayTest.php | 11 +-- tests/Switzerland/Vaud/GoodFridayTest.php | 11 +-- tests/Switzerland/Vaud/NewYearsDayTest.php | 12 ++- .../Switzerland/Vaud/PentecostMondayTest.php | 11 +-- tests/Switzerland/Vaud/VaudTest.php | 3 +- tests/Switzerland/Zug/AllSaintsDayTest.php | 12 ++- tests/Switzerland/Zug/AscensionDayTest.php | 11 +-- .../Switzerland/Zug/AssumptionOfMaryTest.php | 12 ++- tests/Switzerland/Zug/BerchtoldsTagTest.php | 11 +-- tests/Switzerland/Zug/ChristmasDayTest.php | 12 ++- tests/Switzerland/Zug/CorpusChristiTest.php | 10 +-- tests/Switzerland/Zug/EasterMondayTest.php | 11 +-- tests/Switzerland/Zug/GoodFridayTest.php | 11 +-- .../Zug/ImmaculateConceptionTest.php | 12 ++- tests/Switzerland/Zug/NewYearsDayTest.php | 12 ++- tests/Switzerland/Zug/PentecostMondayTest.php | 11 +-- tests/Switzerland/Zug/StStephensDayTest.php | 12 ++- tests/Switzerland/Zug/ZugTest.php | 3 +- tests/Switzerland/Zurich/AscensionDayTest.php | 11 +-- tests/Switzerland/Zurich/ChristmasDayTest.php | 12 ++- tests/Switzerland/Zurich/EasterMondayTest.php | 11 +-- tests/Switzerland/Zurich/GoodFridayTest.php | 11 +-- tests/Switzerland/Zurich/NewYearsDayTest.php | 12 ++- .../Zurich/PentecostMondayTest.php | 11 +-- .../Switzerland/Zurich/StStephensDayTest.php | 12 ++- tests/Switzerland/Zurich/WorkersDayTest.php | 15 ++-- tests/Switzerland/Zurich/ZurichTest.php | 3 +- tests/Turkey/LabourDayTest.php | 12 ++- tests/Turkey/NewYearsDayTest.php | 12 ++- tests/Turkey/TurkeyTest.php | 3 +- tests/USA/ChristmasDayTest.php | 19 ++--- tests/USA/ColumbusDayTest.php | 17 ++-- tests/USA/IndependenceDayTest.php | 21 +++-- tests/USA/JuneteenthTest.php | 21 +++-- tests/USA/LabourDayTest.php | 13 ++-- tests/USA/MartinLutherKingDayTest.php | 13 ++-- tests/USA/MemorialDayTest.php | 17 ++-- tests/USA/NewYearsDayTest.php | 19 ++--- tests/USA/ThanksgivingDayTest.php | 13 ++-- tests/USA/USATest.php | 3 +- tests/USA/VeteransDayTest.php | 25 +++--- tests/USA/WashingtonsBirthdayTest.php | 17 ++-- tests/Ukraine/CatholicChristmasDayTest.php | 14 ++-- tests/Ukraine/ChristmasDayTest.php | 12 ++- tests/Ukraine/ConstitutionDayTest.php | 7 +- tests/Ukraine/DefenderOfUkraineDayTest.php | 7 +- tests/Ukraine/EasterTest.php | 11 +-- tests/Ukraine/IndependenceDayTest.php | 7 +- tests/Ukraine/InternationalWomensDayTest.php | 7 +- tests/Ukraine/InternationalWorkersDayTest.php | 12 ++- tests/Ukraine/NewYearsDayTest.php | 12 ++- tests/Ukraine/PentecostTest.php | 11 +-- .../SecondInternationalWorkersDayTest.php | 5 +- tests/Ukraine/SubstitutedHolidayTest.php | 32 ++++---- tests/Ukraine/UkraineTest.php | 3 +- tests/Ukraine/VictoryDayTest.php | 7 +- tests/UnitedKingdom/BoxingDayTest.php | 18 ++--- tests/UnitedKingdom/ChristmasDayTest.php | 18 ++--- tests/UnitedKingdom/EasterMondayTest.php | 16 ++-- tests/UnitedKingdom/England/BoxingDayTest.php | 18 ++--- .../England/ChristmasDayTest.php | 18 ++--- .../England/EasterMondayTest.php | 16 ++-- tests/UnitedKingdom/England/EnglandTest.php | 3 +- .../UnitedKingdom/England/GoodFridayTest.php | 11 +-- .../England/MayDayBankHolidayTest.php | 18 ++--- .../UnitedKingdom/England/NewYearsDayTest.php | 17 ++-- .../England/SpringBankHolidayTest.php | 19 ++--- .../England/SummerBankHolidayTest.php | 18 ++--- tests/UnitedKingdom/GoodFridayTest.php | 11 +-- tests/UnitedKingdom/MayDayBankHolidayTest.php | 18 ++--- tests/UnitedKingdom/MotheringSundayTest.php | 16 ++-- tests/UnitedKingdom/NewYearsDayTest.php | 17 ++-- .../NorthernIreland/BattleOfTheBoyneTest.php | 17 ++-- .../NorthernIreland/BoxingDayTest.php | 18 ++--- .../NorthernIreland/ChristmasDayTest.php | 18 ++--- .../NorthernIreland/EasterMondayTest.php | 16 ++-- .../NorthernIreland/GoodFridayTest.php | 11 +-- .../NorthernIreland/MayDayBankHolidayTest.php | 18 ++--- .../NorthernIreland/NewYearsDayTest.php | 17 ++-- .../NorthernIreland/NorthernIrelandTest.php | 3 +- .../NorthernIreland/SpringBankHolidayTest.php | 13 ++-- .../NorthernIreland/StPatricksDayTest.php | 17 ++-- .../NorthernIreland/SummerBankHolidayTest.php | 32 ++++---- .../PlatinumJubileeBankHolidayTest.php | 11 +-- .../QueenElizabethFuneralBankHolidayTest.php | 11 +-- .../UnitedKingdom/Scotland/BoxingDayTest.php | 18 ++--- .../Scotland/ChristmasDayTest.php | 18 ++--- .../UnitedKingdom/Scotland/GoodFridayTest.php | 11 +-- .../Scotland/MayDayBankHolidayTest.php | 18 ++--- .../Scotland/NewYearsDayTest.php | 22 +++--- tests/UnitedKingdom/Scotland/ScotlandTest.php | 3 +- .../Scotland/SecondNewYearsDayTest.php | 22 +++--- .../Scotland/SpringBankHolidayTest.php | 13 ++-- .../Scotland/StAndrewsDayTest.php | 15 ++-- .../Scotland/SummerBankHolidayTest.php | 13 ++-- tests/UnitedKingdom/SpringBankHolidayTest.php | 21 +++-- tests/UnitedKingdom/SummerBankHolidayTest.php | 32 ++++---- tests/UnitedKingdom/UnitedKingdomTest.php | 3 +- tests/UnitedKingdom/Wales/BoxingDayTest.php | 18 ++--- .../UnitedKingdom/Wales/ChristmasDayTest.php | 18 ++--- .../UnitedKingdom/Wales/EasterMondayTest.php | 16 ++-- tests/UnitedKingdom/Wales/GoodFridayTest.php | 11 +-- .../Wales/MayDayBankHolidayTest.php | 18 ++--- tests/UnitedKingdom/Wales/NewYearsDayTest.php | 17 ++-- .../Wales/SpringBankHolidayTest.php | 19 ++--- .../Wales/SummerBankHolidayTest.php | 32 ++++---- tests/UnitedKingdom/Wales/WalesTest.php | 3 +- tests/YasumiBase.php | 59 +++++++------- 1168 files changed, 5391 insertions(+), 8073 deletions(-) diff --git a/composer.json b/composer.json index 21b99f450..a312116c8 100644 --- a/composer.json +++ b/composer.json @@ -40,7 +40,7 @@ "ext-json": "*" }, "require-dev": { - "friendsofphp/php-cs-fixer": "v2.19 | v3.11", + "friendsofphp/php-cs-fixer": "v2.19 | v3.13", "infection/infection": "^0.17 | ^0.26", "mikey179/vfsstream": "^1.6", "phan/phan": "^5.2", diff --git a/src/Yasumi/Exception/InvalidDateException.php b/src/Yasumi/Exception/InvalidDateException.php index ef0697d39..14931b576 100644 --- a/src/Yasumi/Exception/InvalidDateException.php +++ b/src/Yasumi/Exception/InvalidDateException.php @@ -14,12 +14,10 @@ namespace Yasumi\Exception; -use InvalidArgumentException; - /** * Class InvalidDateException. */ -class InvalidDateException extends InvalidArgumentException implements Exception +class InvalidDateException extends \InvalidArgumentException implements Exception { /** * Initializes the Exception instance. diff --git a/src/Yasumi/Exception/InvalidYearException.php b/src/Yasumi/Exception/InvalidYearException.php index a66ac1203..fcd01d0b5 100644 --- a/src/Yasumi/Exception/InvalidYearException.php +++ b/src/Yasumi/Exception/InvalidYearException.php @@ -15,13 +15,11 @@ namespace Yasumi\Exception; -use InvalidArgumentException; - /** * Class InvalidYearException. * * @author Quentin Neyrat */ -class InvalidYearException extends InvalidArgumentException implements Exception +class InvalidYearException extends \InvalidArgumentException implements Exception { } diff --git a/src/Yasumi/Exception/ProviderNotFoundException.php b/src/Yasumi/Exception/ProviderNotFoundException.php index 9eccf62f1..9ab0732aa 100644 --- a/src/Yasumi/Exception/ProviderNotFoundException.php +++ b/src/Yasumi/Exception/ProviderNotFoundException.php @@ -14,13 +14,11 @@ namespace Yasumi\Exception; -use InvalidArgumentException; - /** * Class ProviderNotFoundException. * * @author Quentin Neyrat */ -class ProviderNotFoundException extends InvalidArgumentException implements Exception +class ProviderNotFoundException extends \InvalidArgumentException implements Exception { } diff --git a/src/Yasumi/Exception/UnknownLocaleException.php b/src/Yasumi/Exception/UnknownLocaleException.php index 8cfa97f71..dfe95f345 100644 --- a/src/Yasumi/Exception/UnknownLocaleException.php +++ b/src/Yasumi/Exception/UnknownLocaleException.php @@ -14,11 +14,9 @@ namespace Yasumi\Exception; -use InvalidArgumentException; - /** * Class UnknownLocaleException. */ -class UnknownLocaleException extends InvalidArgumentException implements Exception +class UnknownLocaleException extends \InvalidArgumentException implements Exception { } diff --git a/src/Yasumi/Filters/AbstractFilter.php b/src/Yasumi/Filters/AbstractFilter.php index 170749008..5f9f65c8b 100644 --- a/src/Yasumi/Filters/AbstractFilter.php +++ b/src/Yasumi/Filters/AbstractFilter.php @@ -15,14 +15,12 @@ namespace Yasumi\Filters; -use Countable; -use FilterIterator; use Yasumi\SubstituteHoliday; /** * AbstractFilter. */ -abstract class AbstractFilter extends FilterIterator implements Countable +abstract class AbstractFilter extends \FilterIterator implements \Countable { /** * Returns the number of holidays returned by this iterator. diff --git a/src/Yasumi/Filters/BetweenFilter.php b/src/Yasumi/Filters/BetweenFilter.php index b3fcd122c..d122d3c1f 100644 --- a/src/Yasumi/Filters/BetweenFilter.php +++ b/src/Yasumi/Filters/BetweenFilter.php @@ -40,14 +40,14 @@ class BetweenFilter extends AbstractFilter /** * Construct the Between FilterIterator Object. * - * @param Iterator $iterator Iterator object of the Holidays Provider - * @param \DateTimeInterface $startDate Start date of the time frame to check against - * @param \DateTimeInterface $endDate End date of the time frame to check against - * @param bool $equal Indicate whether the start and end dates should be included in the - * comparison + * @param \Iterator $iterator Iterator object of the Holidays Provider + * @param \DateTimeInterface $startDate Start date of the time frame to check against + * @param \DateTimeInterface $endDate End date of the time frame to check against + * @param bool $equal Indicate whether the start and end dates should be included in the + * comparison */ public function __construct( - Iterator $iterator, + \Iterator $iterator, \DateTimeInterface $startDate, \DateTimeInterface $endDate, bool $equal = true diff --git a/src/Yasumi/Filters/OnFilter.php b/src/Yasumi/Filters/OnFilter.php index 22431c644..e83ce8633 100644 --- a/src/Yasumi/Filters/OnFilter.php +++ b/src/Yasumi/Filters/OnFilter.php @@ -33,11 +33,11 @@ class OnFilter extends AbstractFilter /** * Construct the On FilterIterator Object. * - * @param Iterator $iterator Iterator object of the Holidays Provider - * @param \DateTimeInterface $date Start date of the time frame to check against + * @param \Iterator $iterator Iterator object of the Holidays Provider + * @param \DateTimeInterface $date Start date of the time frame to check against */ public function __construct( - Iterator $iterator, + \Iterator $iterator, \DateTimeInterface $date ) { parent::__construct($iterator); diff --git a/src/Yasumi/Holiday.php b/src/Yasumi/Holiday.php index 9dc4b5305..f65e705f9 100644 --- a/src/Yasumi/Holiday.php +++ b/src/Yasumi/Holiday.php @@ -15,9 +15,6 @@ namespace Yasumi; -use DateTime; -use InvalidArgumentException; -use JsonSerializable; use Yasumi\Exception\InvalidDateException; use Yasumi\Exception\MissingTranslationException; use Yasumi\Exception\UnknownLocaleException; @@ -25,7 +22,7 @@ /** * Class Holiday. */ -class Holiday extends DateTime implements JsonSerializable +class Holiday extends \DateTime implements \JsonSerializable { /** * Type definition for Official (i.e. National/Federal) holidays. @@ -102,7 +99,7 @@ class Holiday extends DateTime implements JsonSerializable * * @throws InvalidDateException * @throws UnknownLocaleException - * @throws InvalidArgumentException + * @throws \InvalidArgumentException * @throws \Exception */ public function __construct( @@ -114,7 +111,7 @@ public function __construct( ) { // Validate if key is not empty if (empty($key)) { - throw new InvalidArgumentException('Holiday name can not be blank.'); + throw new \InvalidArgumentException('Holiday name can not be blank.'); } // Load internal locales variable diff --git a/src/Yasumi/Provider/AbstractProvider.php b/src/Yasumi/Provider/AbstractProvider.php index 82115ab11..538059e34 100644 --- a/src/Yasumi/Provider/AbstractProvider.php +++ b/src/Yasumi/Provider/AbstractProvider.php @@ -14,10 +14,7 @@ namespace Yasumi\Provider; -use ArrayIterator; -use Countable; use InvalidArgumentException; -use IteratorAggregate; use Yasumi\Exception\UnknownLocaleException; use Yasumi\Filters\BetweenFilter; use Yasumi\Filters\OnFilter; @@ -30,7 +27,7 @@ /** * Class AbstractProvider. */ -abstract class AbstractProvider implements Countable, ProviderInterface, IteratorAggregate +abstract class AbstractProvider implements \Countable, ProviderInterface, \IteratorAggregate { /** * Code to identify the Holiday Provider. Typically, this is the ISO3166 code corresponding to the respective @@ -235,16 +232,16 @@ public function between( ?bool $equals = null ): BetweenFilter { if ($startDate > $endDate) { - throw new InvalidArgumentException('Start date must be a date before the end date.'); + throw new \InvalidArgumentException('Start date must be a date before the end date.'); } return new BetweenFilter($this->getIterator(), $startDate, $endDate, $equals ?? true); } /** {@inheritdoc} */ - public function getIterator(): ArrayIterator + public function getIterator(): \ArrayIterator { - return new ArrayIterator($this->getHolidays()); + return new \ArrayIterator($this->getHolidays()); } /** {@inheritdoc} */ @@ -266,7 +263,7 @@ public function getHolidayDates(): array * * @return true upon success, otherwise an InvalidArgumentException is thrown * - * @throws InvalidArgumentException an InvalidArgumentException is thrown if the given holiday parameter is empty + * @throws \InvalidArgumentException an InvalidArgumentException is thrown if the given holiday parameter is empty * * @deprecated deprecated in favor of isHolidayKeyNotEmpty() * @deprecated see isHolidayKeyNotEmpty() @@ -291,12 +288,12 @@ private function clearHolidays(): void * * @return true upon success, otherwise an InvalidArgumentException is thrown * - * @throws InvalidArgumentException an InvalidArgumentException is thrown if the given holiday parameter is empty + * @throws \InvalidArgumentException an InvalidArgumentException is thrown if the given holiday parameter is empty */ private function isHolidayKeyNotEmpty(string $key): bool { if (empty($key)) { - throw new InvalidArgumentException('Holiday key can not be blank.'); + throw new \InvalidArgumentException('Holiday key can not be blank.'); } return true; @@ -324,7 +321,7 @@ private static function compareDates(\DateTimeInterface $dateA, \DateTimeInterfa * * @return Holiday|null a Holiday instance for the given holiday and year * - * @throws InvalidArgumentException when the given name is blank or empty + * @throws \InvalidArgumentException when the given name is blank or empty * @throws UnknownLocaleException * @throws \RuntimeException */ diff --git a/src/Yasumi/Provider/Argentina.php b/src/Yasumi/Provider/Argentina.php index 9f8a70e09..c55e81b3c 100644 --- a/src/Yasumi/Provider/Argentina.php +++ b/src/Yasumi/Provider/Argentina.php @@ -14,8 +14,6 @@ namespace Yasumi\Provider; -use DateInterval; -use DateTime; use Yasumi\Exception\InvalidDateException; use Yasumi\Exception\UnknownLocaleException; use Yasumi\Holiday; @@ -98,7 +96,7 @@ private function addCarnvalHolidays(): void $easter = $this->calculateEaster($this->year, $this->timezone); $carnavalMonday = clone $easter; - $carnavalMondayDate = $carnavalMonday->sub(new DateInterval('P48D')); + $carnavalMondayDate = $carnavalMonday->sub(new \DateInterval('P48D')); $this->addHoliday(new Holiday( 'carnavalMonday', [ @@ -111,7 +109,7 @@ private function addCarnvalHolidays(): void )); $carnavalTuesday = clone $easter; - $carnavalTuesdayDate = $carnavalTuesday->sub(new DateInterval('P47D')); + $carnavalTuesdayDate = $carnavalTuesday->sub(new \DateInterval('P47D')); $this->addHoliday(new Holiday( 'carnavalTuesday', [ @@ -145,7 +143,7 @@ private function addRemembranceDay(): void 'en' => 'Day of Remembrance for Truth and Justice', 'es' => 'Día Nacional de la Memoria por la Verdad y la Justicia', ], - new DateTime("$this->year-03-24", DateTimeZoneFactory::getDateTimeZone($this->timezone)), + new \DateTime("$this->year-03-24", DateTimeZoneFactory::getDateTimeZone($this->timezone)), $this->locale )); } @@ -171,7 +169,7 @@ private function addMalvinasDay(): void 'en' => 'Malvinas Day', 'es' => 'Día del Veterano y de los Caídos en la Guerra de Malvinas', ], - new DateTime("$this->year-04-02", DateTimeZoneFactory::getDateTimeZone($this->timezone)), + new \DateTime("$this->year-04-02", DateTimeZoneFactory::getDateTimeZone($this->timezone)), $this->locale )); } @@ -199,7 +197,7 @@ private function addMayRevolution(): void 'en' => 'May Revolution', 'es' => 'Día de la Revolución de Mayo', ], - new DateTime("$this->year-05-25", DateTimeZoneFactory::getDateTimeZone($this->timezone)), + new \DateTime("$this->year-05-25", DateTimeZoneFactory::getDateTimeZone($this->timezone)), $this->locale )); } @@ -220,7 +218,7 @@ private function addGeneralMartinMigueldeGuemesDay(): void 'en' => 'Anniversary of the Passing of General Martín Miguel de Güemes', 'es' => 'Paso a la Inmortalidad del General Martín Miguel de Güemes', ], - new DateTime("$this->year-06-17", DateTimeZoneFactory::getDateTimeZone($this->timezone)), + new \DateTime("$this->year-06-17", DateTimeZoneFactory::getDateTimeZone($this->timezone)), $this->locale )); } @@ -243,7 +241,7 @@ private function addFlagDay(): void 'en' => 'General Manuel Belgrano Memorial Day', 'es' => 'Paso a la Inmortalidad del General Manuel Belgrano', ], - new DateTime("$this->year-06-20", DateTimeZoneFactory::getDateTimeZone($this->timezone)), + new \DateTime("$this->year-06-20", DateTimeZoneFactory::getDateTimeZone($this->timezone)), $this->locale )); } @@ -265,7 +263,7 @@ private function addIndependenceDay(): void 'en' => 'Independence Day', 'es' => 'Día de la Independencia', ], - new DateTime("$this->year-07-09", DateTimeZoneFactory::getDateTimeZone($this->timezone)), + new \DateTime("$this->year-07-09", DateTimeZoneFactory::getDateTimeZone($this->timezone)), $this->locale )); } @@ -286,7 +284,7 @@ private function addGeneralJoseSanMartinDay(): void 'en' => 'General José de San Martín Memorial Day', 'es' => 'Paso a la Inmortalidad del General José de San Martín', ], - new DateTime("$this->year-08-17", DateTimeZoneFactory::getDateTimeZone($this->timezone)), + new \DateTime("$this->year-08-17", DateTimeZoneFactory::getDateTimeZone($this->timezone)), $this->locale )); } @@ -309,7 +307,7 @@ private function addRaceDay(): void 'en' => 'Day of Respect for Cultural Diversity', 'es' => 'Día del Respeto a la Diversidad Cultural', ], - new DateTime("$this->year-10-12", DateTimeZoneFactory::getDateTimeZone($this->timezone)), + new \DateTime("$this->year-10-12", DateTimeZoneFactory::getDateTimeZone($this->timezone)), $this->locale )); } @@ -332,7 +330,7 @@ private function addNationalSovereigntyDay(): void 'en' => 'National Sovereignty Day', 'es' => 'Día de la Soberanía Nacional', ], - new DateTime("$this->year-11-20", DateTimeZoneFactory::getDateTimeZone($this->timezone)), + new \DateTime("$this->year-11-20", DateTimeZoneFactory::getDateTimeZone($this->timezone)), $this->locale )); } @@ -355,7 +353,7 @@ private function addImmaculateConceptionDay(): void 'en' => 'Immaculate Conception Day', 'es' => 'Día de la Inmaculada Concepción de María', ], - new DateTime("$this->year-12-08", DateTimeZoneFactory::getDateTimeZone($this->timezone)), + new \DateTime("$this->year-12-08", DateTimeZoneFactory::getDateTimeZone($this->timezone)), $this->locale )); } diff --git a/src/Yasumi/Provider/Australia.php b/src/Yasumi/Provider/Australia.php index d8cf32855..4494ae9ad 100644 --- a/src/Yasumi/Provider/Australia.php +++ b/src/Yasumi/Provider/Australia.php @@ -14,8 +14,6 @@ namespace Yasumi\Provider; -use DateInterval; -use DateTime; use Yasumi\Exception\UnknownLocaleException; use Yasumi\Holiday; use Yasumi\SubstituteHoliday; @@ -79,7 +77,7 @@ public function getSources(): array */ private function calculateNewYearHolidays(): void { - $newYearsDay = new DateTime("$this->year-01-01", DateTimeZoneFactory::getDateTimeZone($this->timezone)); + $newYearsDay = new \DateTime("$this->year-01-01", DateTimeZoneFactory::getDateTimeZone($this->timezone)); $this->addHoliday(new Holiday( 'newYearsDay', [], @@ -89,7 +87,7 @@ private function calculateNewYearHolidays(): void )); switch ($newYearsDay->format('w')) { case 0: // sunday - $newYearsDay->add(new DateInterval('P1D')); + $newYearsDay->add(new \DateInterval('P1D')); $this->addHoliday(new Holiday( 'newYearsHoliday', ['en' => 'New Year’s Holiday'], @@ -99,7 +97,7 @@ private function calculateNewYearHolidays(): void )); break; case 6: // saturday - $newYearsDay->add(new DateInterval('P2D')); + $newYearsDay->add(new \DateInterval('P2D')); $this->addHoliday(new Holiday( 'newYearsHoliday', ['en' => 'New Year’s Holiday'], @@ -131,7 +129,7 @@ private function calculateNewYearHolidays(): void */ private function calculateAustraliaDay(): void { - $date = new DateTime("$this->year-01-26", DateTimeZoneFactory::getDateTimeZone($this->timezone)); + $date = new \DateTime("$this->year-01-26", DateTimeZoneFactory::getDateTimeZone($this->timezone)); $holiday = new Holiday( 'australiaDay', @@ -144,7 +142,7 @@ private function calculateAustraliaDay(): void $day = (int) $date->format('w'); if (0 === $day || 6 === $day) { - $date = $date->add(0 === $day ? new DateInterval('P1D') : new DateInterval('P2D')); + $date = $date->add(0 === $day ? new \DateInterval('P1D') : new \DateInterval('P2D')); $this->addHoliday(new SubstituteHoliday( $holiday, @@ -178,7 +176,7 @@ private function calculateAnzacDay(): void return; } - $date = new DateTime("$this->year-04-25", DateTimeZoneFactory::getDateTimeZone($this->timezone)); + $date = new \DateTime("$this->year-04-25", DateTimeZoneFactory::getDateTimeZone($this->timezone)); $this->addHoliday(new Holiday( 'anzacDay', [], @@ -189,11 +187,11 @@ private function calculateAnzacDay(): void $easter = $this->calculateEaster($this->year, $this->timezone); $easterMonday = $this->calculateEaster($this->year, $this->timezone); - $easterMonday->add(new DateInterval('P1D')); + $easterMonday->add(new \DateInterval('P1D')); $fDate = $date->format('Y-m-d'); if ($fDate === $easter->format('Y-m-d') || $fDate === $easterMonday->format('Y-m-d')) { - $easterMonday->add(new DateInterval('P1D')); + $easterMonday->add(new \DateInterval('P1D')); $this->addHoliday(new Holiday( 'easterTuesday', ['en' => 'Easter Tuesday'], @@ -218,8 +216,8 @@ private function calculateAnzacDay(): void */ private function calculateChristmasDay(): void { - $christmasDay = new DateTime("$this->year-12-25", DateTimeZoneFactory::getDateTimeZone($this->timezone)); - $boxingDay = new DateTime("$this->year-12-26", DateTimeZoneFactory::getDateTimeZone($this->timezone)); + $christmasDay = new \DateTime("$this->year-12-25", DateTimeZoneFactory::getDateTimeZone($this->timezone)); + $boxingDay = new \DateTime("$this->year-12-26", DateTimeZoneFactory::getDateTimeZone($this->timezone)); $this->addHoliday(new Holiday( 'christmasDay', [], @@ -237,7 +235,7 @@ private function calculateChristmasDay(): void switch ($christmasDay->format('w')) { case 0: // sunday - $christmasDay->add(new DateInterval('P2D')); + $christmasDay->add(new \DateInterval('P2D')); $this->addHoliday(new Holiday( 'christmasHoliday', ['en' => 'Christmas Holiday'], @@ -247,7 +245,7 @@ private function calculateChristmasDay(): void )); break; case 5: // friday - $boxingDay->add(new DateInterval('P2D')); + $boxingDay->add(new \DateInterval('P2D')); $this->addHoliday(new Holiday( 'secondChristmasHoliday', ['en' => 'Boxing Day Holiday'], @@ -257,8 +255,8 @@ private function calculateChristmasDay(): void )); break; case 6: // saturday - $christmasDay->add(new DateInterval('P2D')); - $boxingDay->add(new DateInterval('P2D')); + $christmasDay->add(new \DateInterval('P2D')); + $boxingDay->add(new \DateInterval('P2D')); $this->addHoliday(new Holiday( 'christmasHoliday', ['en' => 'Christmas Holiday'], diff --git a/src/Yasumi/Provider/Australia/AustralianCapitalTerritory.php b/src/Yasumi/Provider/Australia/AustralianCapitalTerritory.php index 5936ccc50..a1eda4980 100644 --- a/src/Yasumi/Provider/Australia/AustralianCapitalTerritory.php +++ b/src/Yasumi/Provider/Australia/AustralianCapitalTerritory.php @@ -14,8 +14,6 @@ namespace Yasumi\Provider\Australia; -use DateInterval; -use DateTime; use Yasumi\Exception\UnknownLocaleException; use Yasumi\Holiday; use Yasumi\Provider\Australia; @@ -111,7 +109,7 @@ private function easterSaturday( return new Holiday( 'easterSaturday', ['en' => 'Easter Saturday'], - $this->calculateEaster($year, $timezone)->sub(new DateInterval('P1D')), + $this->calculateEaster($year, $timezone)->sub(new \DateInterval('P1D')), $locale, $type ?? Holiday::TYPE_OFFICIAL ); @@ -137,7 +135,7 @@ private function calculateQueensBirthday(): void $this->addHoliday(new Holiday( 'queensBirthday', [], - new DateTime('second monday of june '.$this->year, DateTimeZoneFactory::getDateTimeZone($this->timezone)), + new \DateTime('second monday of june '.$this->year, DateTimeZoneFactory::getDateTimeZone($this->timezone)), $this->locale, Holiday::TYPE_OFFICIAL )); @@ -150,7 +148,7 @@ private function calculateQueensBirthday(): void */ private function calculateLabourDay(): void { - $date = new DateTime("first monday of october $this->year", DateTimeZoneFactory::getDateTimeZone($this->timezone)); + $date = new \DateTime("first monday of october $this->year", DateTimeZoneFactory::getDateTimeZone($this->timezone)); $this->addHoliday(new Holiday('labourDay', [], $date, $this->locale)); } @@ -168,7 +166,7 @@ private function calculateCanberraDay(): void new Holiday( 'canberraDay', ['en' => 'Canberra Day'], - new DateTime($datePattern, DateTimeZoneFactory::getDateTimeZone($this->timezone)), + new \DateTime($datePattern, DateTimeZoneFactory::getDateTimeZone($this->timezone)), $this->locale ) ); @@ -185,10 +183,10 @@ private function calculateReconciliationDay(): void return; } - $date = new DateTime($this->year.'-05-27', DateTimeZoneFactory::getDateTimeZone($this->timezone)); + $date = new \DateTime($this->year.'-05-27', DateTimeZoneFactory::getDateTimeZone($this->timezone)); $day = (int) $date->format('w'); if (1 !== $day) { - $date = $date->add(0 === $day ? new DateInterval('P1D') : new DateInterval('P'.(8 - $day).'D')); + $date = $date->add(0 === $day ? new \DateInterval('P1D') : new \DateInterval('P'.(8 - $day).'D')); } $this->addHoliday(new Holiday('reconciliationDay', ['en' => 'Reconciliation Day'], $date, $this->locale)); } diff --git a/src/Yasumi/Provider/Australia/NewSouthWales.php b/src/Yasumi/Provider/Australia/NewSouthWales.php index 87031bfea..c5fa16b6f 100644 --- a/src/Yasumi/Provider/Australia/NewSouthWales.php +++ b/src/Yasumi/Provider/Australia/NewSouthWales.php @@ -14,8 +14,6 @@ namespace Yasumi\Provider\Australia; -use DateInterval; -use DateTime; use Yasumi\Exception\UnknownLocaleException; use Yasumi\Holiday; use Yasumi\Provider\Australia; @@ -78,7 +76,7 @@ private function easterSaturday( return new Holiday( 'easterSaturday', ['en' => 'Easter Saturday'], - $this->calculateEaster($year, $timezone)->sub(new DateInterval('P1D')), + $this->calculateEaster($year, $timezone)->sub(new \DateInterval('P1D')), $locale, $type ?? Holiday::TYPE_OFFICIAL ); @@ -104,7 +102,7 @@ private function calculateQueensBirthday(): void $this->addHoliday(new Holiday( 'queensBirthday', [], - new DateTime('second monday of june '.$this->year, DateTimeZoneFactory::getDateTimeZone($this->timezone)), + new \DateTime('second monday of june '.$this->year, DateTimeZoneFactory::getDateTimeZone($this->timezone)), $this->locale, Holiday::TYPE_OFFICIAL )); @@ -117,7 +115,7 @@ private function calculateQueensBirthday(): void */ private function calculateLabourDay(): void { - $date = new DateTime("first monday of october $this->year", DateTimeZoneFactory::getDateTimeZone($this->timezone)); + $date = new \DateTime("first monday of october $this->year", DateTimeZoneFactory::getDateTimeZone($this->timezone)); $this->addHoliday(new Holiday('labourDay', [], $date, $this->locale)); } @@ -133,7 +131,7 @@ private function calculateBankHoliday(): void $this->addHoliday(new Holiday( 'bankHoliday', ['en' => 'Bank Holiday'], - new DateTime('first monday of august '.$this->year, DateTimeZoneFactory::getDateTimeZone($this->timezone)), + new \DateTime('first monday of august '.$this->year, DateTimeZoneFactory::getDateTimeZone($this->timezone)), $this->locale, Holiday::TYPE_BANK )); diff --git a/src/Yasumi/Provider/Australia/NorthernTerritory.php b/src/Yasumi/Provider/Australia/NorthernTerritory.php index 324b52711..950def16e 100644 --- a/src/Yasumi/Provider/Australia/NorthernTerritory.php +++ b/src/Yasumi/Provider/Australia/NorthernTerritory.php @@ -14,8 +14,6 @@ namespace Yasumi\Provider\Australia; -use DateInterval; -use DateTime; use Yasumi\Exception\UnknownLocaleException; use Yasumi\Holiday; use Yasumi\Provider\Australia; @@ -77,7 +75,7 @@ private function easterSaturday( return new Holiday( 'easterSaturday', ['en' => 'Easter Saturday'], - $this->calculateEaster($year, $timezone)->sub(new DateInterval('P1D')), + $this->calculateEaster($year, $timezone)->sub(new \DateInterval('P1D')), $locale, $type ?? Holiday::TYPE_OFFICIAL ); @@ -103,7 +101,7 @@ private function calculateQueensBirthday(): void $this->addHoliday(new Holiday( 'queensBirthday', [], - new DateTime('second monday of june '.$this->year, DateTimeZoneFactory::getDateTimeZone($this->timezone)), + new \DateTime('second monday of june '.$this->year, DateTimeZoneFactory::getDateTimeZone($this->timezone)), $this->locale, Holiday::TYPE_OFFICIAL )); @@ -116,7 +114,7 @@ private function calculateQueensBirthday(): void */ private function calculateMayDay(): void { - $date = new DateTime("first monday of may $this->year", DateTimeZoneFactory::getDateTimeZone($this->timezone)); + $date = new \DateTime("first monday of may $this->year", DateTimeZoneFactory::getDateTimeZone($this->timezone)); $this->addHoliday(new Holiday('mayDay', ['en' => 'May Day'], $date, $this->locale)); } @@ -134,7 +132,7 @@ private function calculatePicnicDay(): void $this->addHoliday(new Holiday( 'picnicDay', ['en' => 'Picnic Day'], - new DateTime('first monday of august '.$this->year, DateTimeZoneFactory::getDateTimeZone($this->timezone)), + new \DateTime('first monday of august '.$this->year, DateTimeZoneFactory::getDateTimeZone($this->timezone)), $this->locale, Holiday::TYPE_OFFICIAL )); diff --git a/src/Yasumi/Provider/Australia/Queensland.php b/src/Yasumi/Provider/Australia/Queensland.php index cf451af89..9f2bd3946 100644 --- a/src/Yasumi/Provider/Australia/Queensland.php +++ b/src/Yasumi/Provider/Australia/Queensland.php @@ -14,7 +14,6 @@ namespace Yasumi\Provider\Australia; -use DateTime; use Yasumi\Exception\UnknownLocaleException; use Yasumi\Holiday; use Yasumi\Provider\Australia; @@ -74,7 +73,7 @@ private function calculateQueensBirthday(): void $this->addHoliday(new Holiday( 'queensBirthday', [], - new DateTime($birthDay, DateTimeZoneFactory::getDateTimeZone($this->timezone)), + new \DateTime($birthDay, DateTimeZoneFactory::getDateTimeZone($this->timezone)), $this->locale, Holiday::TYPE_OFFICIAL )); @@ -87,9 +86,9 @@ private function calculateQueensBirthday(): void */ private function calculateLabourDay(): void { - $date = new DateTime("first monday of may $this->year", DateTimeZoneFactory::getDateTimeZone($this->timezone)); + $date = new \DateTime("first monday of may $this->year", DateTimeZoneFactory::getDateTimeZone($this->timezone)); if (2013 === $this->year || 2014 === $this->year || 2015 === $this->year) { - $date = new DateTime("first monday of october $this->year", DateTimeZoneFactory::getDateTimeZone($this->timezone)); + $date = new \DateTime("first monday of october $this->year", DateTimeZoneFactory::getDateTimeZone($this->timezone)); } $this->addHoliday(new Holiday('labourDay', [], $date, $this->locale)); diff --git a/src/Yasumi/Provider/Australia/Queensland/Brisbane.php b/src/Yasumi/Provider/Australia/Queensland/Brisbane.php index 3255f2fe7..e4ca04e9c 100644 --- a/src/Yasumi/Provider/Australia/Queensland/Brisbane.php +++ b/src/Yasumi/Provider/Australia/Queensland/Brisbane.php @@ -14,8 +14,6 @@ namespace Yasumi\Provider\Australia\Queensland; -use DateInterval; -use DateTime; use Yasumi\Exception\UnknownLocaleException; use Yasumi\Holiday; use Yasumi\Provider\Australia\Queensland; @@ -68,11 +66,11 @@ public function initialize(): void */ private function calculatePeoplesDay(): void { - $date = new DateTime('first friday of august '.$this->year, DateTimeZoneFactory::getDateTimeZone($this->timezone)); + $date = new \DateTime('first friday of august '.$this->year, DateTimeZoneFactory::getDateTimeZone($this->timezone)); if ($date->format('d') < 5) { - $date = $date->add(new DateInterval('P7D')); + $date = $date->add(new \DateInterval('P7D')); } - $date = $date->add(new DateInterval('P5D')); + $date = $date->add(new \DateInterval('P5D')); $this->addHoliday(new Holiday('peoplesDay', ['en' => 'Ekka People’s Day'], $date, $this->locale)); } } diff --git a/src/Yasumi/Provider/Australia/SouthAustralia.php b/src/Yasumi/Provider/Australia/SouthAustralia.php index 0b5540407..8f2dae735 100644 --- a/src/Yasumi/Provider/Australia/SouthAustralia.php +++ b/src/Yasumi/Provider/Australia/SouthAustralia.php @@ -14,8 +14,6 @@ namespace Yasumi\Provider\Australia; -use DateInterval; -use DateTime; use Yasumi\Exception\UnknownLocaleException; use Yasumi\Holiday; use Yasumi\Provider\Australia; @@ -85,7 +83,7 @@ private function easterSaturday( return new Holiday( 'easterSaturday', ['en' => 'Easter Saturday'], - $this->calculateEaster($year, $timezone)->sub(new DateInterval('P1D')), + $this->calculateEaster($year, $timezone)->sub(new \DateInterval('P1D')), $locale, $type ?? Holiday::TYPE_OFFICIAL ); @@ -111,7 +109,7 @@ private function calculateQueensBirthday(): void $this->addHoliday(new Holiday( 'queensBirthday', [], - new DateTime('second monday of june '.$this->year, DateTimeZoneFactory::getDateTimeZone($this->timezone)), + new \DateTime('second monday of june '.$this->year, DateTimeZoneFactory::getDateTimeZone($this->timezone)), $this->locale, Holiday::TYPE_OFFICIAL )); @@ -124,7 +122,7 @@ private function calculateQueensBirthday(): void */ private function calculateLabourDay(): void { - $date = new DateTime("first monday of october $this->year", DateTimeZoneFactory::getDateTimeZone($this->timezone)); + $date = new \DateTime("first monday of october $this->year", DateTimeZoneFactory::getDateTimeZone($this->timezone)); $this->addHoliday(new Holiday('labourDay', ['en' => 'Labour Day'], $date, $this->locale)); } @@ -149,7 +147,7 @@ private function calculateAdelaideCupDay(): void $this->addHoliday(new Holiday( 'adelaideCup', ['en' => 'Adelaide Cup'], - new DateTime($cupDay, DateTimeZoneFactory::getDateTimeZone($this->timezone)), + new \DateTime($cupDay, DateTimeZoneFactory::getDateTimeZone($this->timezone)), $this->locale, Holiday::TYPE_OFFICIAL )); @@ -163,7 +161,7 @@ private function calculateAdelaideCupDay(): void */ private function calculateProclamationDay(): void { - $christmasDay = new DateTime("$this->year-12-25", DateTimeZoneFactory::getDateTimeZone($this->timezone)); + $christmasDay = new \DateTime("$this->year-12-25", DateTimeZoneFactory::getDateTimeZone($this->timezone)); $this->addHoliday(new Holiday( 'christmasDay', @@ -175,7 +173,7 @@ private function calculateProclamationDay(): void switch ($christmasDay->format('w')) { case 0: // sunday - $christmasDay->add(new DateInterval('P1D')); + $christmasDay->add(new \DateInterval('P1D')); $this->addHoliday(new Holiday( 'christmasHoliday', ['en' => 'Christmas Holiday'], @@ -183,13 +181,13 @@ private function calculateProclamationDay(): void $this->locale, Holiday::TYPE_OFFICIAL )); - $christmasDay->add(new DateInterval('P1D')); + $christmasDay->add(new \DateInterval('P1D')); break; case 5: // friday - $christmasDay->add(new DateInterval('P3D')); + $christmasDay->add(new \DateInterval('P3D')); break; case 6: // saturday - $christmasDay->add(new DateInterval('P2D')); + $christmasDay->add(new \DateInterval('P2D')); $this->addHoliday(new Holiday( 'christmasHoliday', ['en' => 'Christmas Holiday'], @@ -197,10 +195,10 @@ private function calculateProclamationDay(): void $this->locale, Holiday::TYPE_OFFICIAL )); - $christmasDay->add(new DateInterval('P1D')); + $christmasDay->add(new \DateInterval('P1D')); break; default: // monday-thursday - $christmasDay->add(new DateInterval('P1D')); + $christmasDay->add(new \DateInterval('P1D')); break; } diff --git a/src/Yasumi/Provider/Australia/Tasmania.php b/src/Yasumi/Provider/Australia/Tasmania.php index 72ebf4c46..7cdbe4795 100644 --- a/src/Yasumi/Provider/Australia/Tasmania.php +++ b/src/Yasumi/Provider/Australia/Tasmania.php @@ -14,7 +14,6 @@ namespace Yasumi\Provider\Australia; -use DateTime; use Yasumi\Exception\UnknownLocaleException; use Yasumi\Holiday; use Yasumi\Provider\Australia; @@ -56,7 +55,7 @@ public function initialize(): void */ private function calculateEightHoursDay(): void { - $date = new DateTime("second monday of march $this->year", DateTimeZoneFactory::getDateTimeZone($this->timezone)); + $date = new \DateTime("second monday of march $this->year", DateTimeZoneFactory::getDateTimeZone($this->timezone)); $this->addHoliday(new Holiday('eightHourDay', ['en' => 'Eight Hour Day'], $date, $this->locale)); } @@ -81,7 +80,7 @@ private function calculateQueensBirthday(): void $this->addHoliday(new Holiday( 'queensBirthday', [], - new DateTime('second monday of june '.$this->year, DateTimeZoneFactory::getDateTimeZone($this->timezone)), + new \DateTime('second monday of june '.$this->year, DateTimeZoneFactory::getDateTimeZone($this->timezone)), $this->locale, Holiday::TYPE_OFFICIAL )); @@ -100,7 +99,7 @@ private function calculateRecreationDay(): void $this->addHoliday(new Holiday( 'recreationDay', ['en' => 'Recreation Day'], - new DateTime('first monday of november '.$this->year, DateTimeZoneFactory::getDateTimeZone($this->timezone)), + new \DateTime('first monday of november '.$this->year, DateTimeZoneFactory::getDateTimeZone($this->timezone)), $this->locale, Holiday::TYPE_OFFICIAL )); diff --git a/src/Yasumi/Provider/Australia/Tasmania/CentralNorth.php b/src/Yasumi/Provider/Australia/Tasmania/CentralNorth.php index ef276de98..694c8de27 100644 --- a/src/Yasumi/Provider/Australia/Tasmania/CentralNorth.php +++ b/src/Yasumi/Provider/Australia/Tasmania/CentralNorth.php @@ -14,7 +14,6 @@ namespace Yasumi\Provider\Australia\Tasmania; -use DateTime; use Yasumi\Exception\UnknownLocaleException; use Yasumi\Holiday; use Yasumi\Provider\Australia\Tasmania; @@ -53,7 +52,7 @@ public function initialize(): void */ private function calculateDevonportShow(): void { - $date = new DateTime($this->year.'-12-02', DateTimeZoneFactory::getDateTimeZone($this->timezone)); + $date = new \DateTime($this->year.'-12-02', DateTimeZoneFactory::getDateTimeZone($this->timezone)); $date = $date->modify('previous friday'); $this->addHoliday(new Holiday('devonportShow', ['en' => 'Devonport Show'], $date, $this->locale)); diff --git a/src/Yasumi/Provider/Australia/Tasmania/FlindersIsland.php b/src/Yasumi/Provider/Australia/Tasmania/FlindersIsland.php index 42c899567..1a34bde66 100644 --- a/src/Yasumi/Provider/Australia/Tasmania/FlindersIsland.php +++ b/src/Yasumi/Provider/Australia/Tasmania/FlindersIsland.php @@ -14,8 +14,6 @@ namespace Yasumi\Provider\Australia\Tasmania; -use DateInterval; -use DateTime; use Yasumi\Exception\UnknownLocaleException; use Yasumi\Holiday; use Yasumi\Provider\Australia\Tasmania; @@ -54,8 +52,8 @@ public function initialize(): void */ private function calculateFlindersIslandShow(): void { - $date = new DateTime('third saturday of october '.$this->year, DateTimeZoneFactory::getDateTimeZone($this->timezone)); - $date = $date->sub(new DateInterval('P1D')); + $date = new \DateTime('third saturday of october '.$this->year, DateTimeZoneFactory::getDateTimeZone($this->timezone)); + $date = $date->sub(new \DateInterval('P1D')); $this->addHoliday(new Holiday('flindersIslandShow', ['en' => 'Flinders Island Show'], $date, $this->locale)); } } diff --git a/src/Yasumi/Provider/Australia/Tasmania/KingIsland.php b/src/Yasumi/Provider/Australia/Tasmania/KingIsland.php index 70edbbe94..5fcc8414c 100644 --- a/src/Yasumi/Provider/Australia/Tasmania/KingIsland.php +++ b/src/Yasumi/Provider/Australia/Tasmania/KingIsland.php @@ -14,7 +14,6 @@ namespace Yasumi\Provider\Australia\Tasmania; -use DateTime; use Yasumi\Exception\UnknownLocaleException; use Yasumi\Holiday; use Yasumi\Provider\Australia\Tasmania; @@ -56,7 +55,7 @@ private function calculateKingIslandShow(): void $this->addHoliday(new Holiday( 'kingIslandShow', ['en' => 'King Island Show'], - new DateTime('first tuesday of march '.$this->year, DateTimeZoneFactory::getDateTimeZone($this->timezone)), + new \DateTime('first tuesday of march '.$this->year, DateTimeZoneFactory::getDateTimeZone($this->timezone)), $this->locale, Holiday::TYPE_OFFICIAL )); diff --git a/src/Yasumi/Provider/Australia/Tasmania/Northeast.php b/src/Yasumi/Provider/Australia/Tasmania/Northeast.php index 2df8693f2..eaa4e8524 100644 --- a/src/Yasumi/Provider/Australia/Tasmania/Northeast.php +++ b/src/Yasumi/Provider/Australia/Tasmania/Northeast.php @@ -14,8 +14,6 @@ namespace Yasumi\Provider\Australia\Tasmania; -use DateInterval; -use DateTime; use Yasumi\Exception\UnknownLocaleException; use Yasumi\Holiday; use Yasumi\Provider\Australia\Tasmania; @@ -54,8 +52,8 @@ public function initialize(): void */ private function calculateLauncestonShow(): void { - $date = new DateTime('second saturday of october '.$this->year, DateTimeZoneFactory::getDateTimeZone($this->timezone)); - $date = $date->sub(new DateInterval('P2D')); + $date = new \DateTime('second saturday of october '.$this->year, DateTimeZoneFactory::getDateTimeZone($this->timezone)); + $date = $date->sub(new \DateInterval('P2D')); $this->addHoliday(new Holiday('launcestonShow', ['en' => 'Royal Launceston Show'], $date, $this->locale)); } } diff --git a/src/Yasumi/Provider/Australia/Tasmania/Northwest.php b/src/Yasumi/Provider/Australia/Tasmania/Northwest.php index 138b1934f..7f8bcebce 100644 --- a/src/Yasumi/Provider/Australia/Tasmania/Northwest.php +++ b/src/Yasumi/Provider/Australia/Tasmania/Northwest.php @@ -14,8 +14,6 @@ namespace Yasumi\Provider\Australia\Tasmania; -use DateInterval; -use DateTime; use Yasumi\Exception\UnknownLocaleException; use Yasumi\Holiday; use Yasumi\Provider\Australia\Tasmania; @@ -54,8 +52,8 @@ public function initialize(): void */ private function calculateBurnieShow(): void { - $date = new DateTime('first saturday of october '.$this->year, DateTimeZoneFactory::getDateTimeZone($this->timezone)); - $date = $date->sub(new DateInterval('P1D')); + $date = new \DateTime('first saturday of october '.$this->year, DateTimeZoneFactory::getDateTimeZone($this->timezone)); + $date = $date->sub(new \DateInterval('P1D')); $this->addHoliday(new Holiday('burnieShow', ['en' => 'Burnie Show'], $date, $this->locale)); } } diff --git a/src/Yasumi/Provider/Australia/Tasmania/Northwest/CircularHead.php b/src/Yasumi/Provider/Australia/Tasmania/Northwest/CircularHead.php index d947cdba1..5e155514f 100644 --- a/src/Yasumi/Provider/Australia/Tasmania/Northwest/CircularHead.php +++ b/src/Yasumi/Provider/Australia/Tasmania/Northwest/CircularHead.php @@ -14,8 +14,6 @@ namespace Yasumi\Provider\Australia\Tasmania\Northwest; -use DateInterval; -use DateTime; use Yasumi\Exception\UnknownLocaleException; use Yasumi\Holiday; use Yasumi\Provider\Australia\Tasmania\Northwest; @@ -54,8 +52,8 @@ public function initialize(): void */ private function calculateAGFEST(): void { - $date = new DateTime('first thursday of may '.$this->year, DateTimeZoneFactory::getDateTimeZone($this->timezone)); - $date = $date->add(new DateInterval('P1D')); + $date = new \DateTime('first thursday of may '.$this->year, DateTimeZoneFactory::getDateTimeZone($this->timezone)); + $date = $date->add(new \DateInterval('P1D')); $this->addHoliday(new Holiday('agfest', ['en' => 'AGFEST'], $date, $this->locale)); } } diff --git a/src/Yasumi/Provider/Australia/Tasmania/South.php b/src/Yasumi/Provider/Australia/Tasmania/South.php index 891878777..11b805d43 100644 --- a/src/Yasumi/Provider/Australia/Tasmania/South.php +++ b/src/Yasumi/Provider/Australia/Tasmania/South.php @@ -14,8 +14,6 @@ namespace Yasumi\Provider\Australia\Tasmania; -use DateInterval; -use DateTime; use Yasumi\Exception\UnknownLocaleException; use Yasumi\Holiday; use Yasumi\Provider\Australia\Tasmania; @@ -54,8 +52,8 @@ public function initialize(): void */ private function calculateHobartShow(): void { - $date = new DateTime('fourth saturday of october '.$this->year, DateTimeZoneFactory::getDateTimeZone($this->timezone)); - $date = $date->sub(new DateInterval('P2D')); + $date = new \DateTime('fourth saturday of october '.$this->year, DateTimeZoneFactory::getDateTimeZone($this->timezone)); + $date = $date->sub(new \DateInterval('P2D')); $this->addHoliday(new Holiday('hobartShow', ['en' => 'Royal Hobart Show'], $date, $this->locale)); } } diff --git a/src/Yasumi/Provider/Australia/Tasmania/South/Southeast.php b/src/Yasumi/Provider/Australia/Tasmania/South/Southeast.php index 39454d5c7..836c71654 100644 --- a/src/Yasumi/Provider/Australia/Tasmania/South/Southeast.php +++ b/src/Yasumi/Provider/Australia/Tasmania/South/Southeast.php @@ -14,7 +14,6 @@ namespace Yasumi\Provider\Australia\Tasmania\South; -use DateTime; use Yasumi\Exception\UnknownLocaleException; use Yasumi\Holiday; use Yasumi\Provider\Australia\Tasmania\South; @@ -59,7 +58,7 @@ private function calculateHobartRegatta(): void $this->addHoliday(new Holiday( 'hobartRegatta', ['en' => 'Royal Hobart Regatta'], - new DateTime('second monday of february '.$this->year, DateTimeZoneFactory::getDateTimeZone($this->timezone)), + new \DateTime('second monday of february '.$this->year, DateTimeZoneFactory::getDateTimeZone($this->timezone)), $this->locale, Holiday::TYPE_OFFICIAL )); diff --git a/src/Yasumi/Provider/Australia/Victoria.php b/src/Yasumi/Provider/Australia/Victoria.php index 09ec7684a..da0d30dc5 100644 --- a/src/Yasumi/Provider/Australia/Victoria.php +++ b/src/Yasumi/Provider/Australia/Victoria.php @@ -14,8 +14,6 @@ namespace Yasumi\Provider\Australia; -use DateInterval; -use DateTime; use Yasumi\Exception\UnknownLocaleException; use Yasumi\Holiday; use Yasumi\Provider\Australia; @@ -111,7 +109,7 @@ private function easterSaturday( return new Holiday( 'easterSaturday', ['en' => 'Easter Saturday'], - $this->calculateEaster($year, $timezone)->sub(new DateInterval('P1D')), + $this->calculateEaster($year, $timezone)->sub(new \DateInterval('P1D')), $locale, $type ?? Holiday::TYPE_OFFICIAL ); @@ -124,7 +122,7 @@ private function easterSaturday( */ private function calculateLabourDay(): void { - $date = new DateTime("second monday of march $this->year", DateTimeZoneFactory::getDateTimeZone($this->timezone)); + $date = new \DateTime("second monday of march $this->year", DateTimeZoneFactory::getDateTimeZone($this->timezone)); $this->addHoliday(new Holiday('labourDay', [], $date, $this->locale)); } @@ -149,7 +147,7 @@ private function calculateQueensBirthday(): void $this->addHoliday(new Holiday( 'queensBirthday', [], - new DateTime('second monday of june '.$this->year, DateTimeZoneFactory::getDateTimeZone($this->timezone)), + new \DateTime('second monday of june '.$this->year, DateTimeZoneFactory::getDateTimeZone($this->timezone)), $this->locale, Holiday::TYPE_OFFICIAL )); @@ -162,7 +160,7 @@ private function calculateQueensBirthday(): void */ private function calculateMelbourneCupDay(): void { - $date = new DateTime('first Tuesday of November'." $this->year", DateTimeZoneFactory::getDateTimeZone($this->timezone)); + $date = new \DateTime('first Tuesday of November'." $this->year", DateTimeZoneFactory::getDateTimeZone($this->timezone)); $this->addHoliday(new Holiday('melbourneCup', ['en' => 'Melbourne Cup'], $date, $this->locale)); } @@ -197,7 +195,7 @@ private function calculateAFLGrandFinalDay(): void return; } - $date = new DateTime($aflGrandFinalFriday, DateTimeZoneFactory::getDateTimeZone($this->timezone)); + $date = new \DateTime($aflGrandFinalFriday, DateTimeZoneFactory::getDateTimeZone($this->timezone)); $this->addHoliday(new Holiday( 'aflGrandFinalFriday', diff --git a/src/Yasumi/Provider/Australia/WesternAustralia.php b/src/Yasumi/Provider/Australia/WesternAustralia.php index 426531535..cd9ccc10a 100644 --- a/src/Yasumi/Provider/Australia/WesternAustralia.php +++ b/src/Yasumi/Provider/Australia/WesternAustralia.php @@ -14,7 +14,6 @@ namespace Yasumi\Provider\Australia; -use DateTime; use Yasumi\Exception\UnknownLocaleException; use Yasumi\Holiday; use Yasumi\Provider\Australia; @@ -78,7 +77,7 @@ private function calculateQueensBirthday(): void $this->addHoliday(new Holiday( 'queensBirthday', [], - new DateTime($birthDay, DateTimeZoneFactory::getDateTimeZone($this->timezone)), + new \DateTime($birthDay, DateTimeZoneFactory::getDateTimeZone($this->timezone)), $this->locale, Holiday::TYPE_OFFICIAL )); @@ -91,7 +90,7 @@ private function calculateQueensBirthday(): void */ private function calculateLabourDay(): void { - $date = new DateTime("first monday of march $this->year", DateTimeZoneFactory::getDateTimeZone($this->timezone)); + $date = new \DateTime("first monday of march $this->year", DateTimeZoneFactory::getDateTimeZone($this->timezone)); $this->addHoliday(new Holiday('labourDay', [], $date, $this->locale)); } @@ -109,7 +108,7 @@ private function calculateWesternAustraliaDay(): void $this->addHoliday(new Holiday( 'westernAustraliaDay', ['en' => 'Western Australia Day'], - new DateTime('first monday of june '.$this->year, DateTimeZoneFactory::getDateTimeZone($this->timezone)), + new \DateTime('first monday of june '.$this->year, DateTimeZoneFactory::getDateTimeZone($this->timezone)), $this->locale, Holiday::TYPE_OFFICIAL )); diff --git a/src/Yasumi/Provider/Austria.php b/src/Yasumi/Provider/Austria.php index 6a96a7f7f..6485ec7ef 100644 --- a/src/Yasumi/Provider/Austria.php +++ b/src/Yasumi/Provider/Austria.php @@ -15,7 +15,6 @@ namespace Yasumi\Provider; -use DateTime; use Yasumi\Exception\InvalidDateException; use Yasumi\Exception\UnknownLocaleException; use Yasumi\Holiday; @@ -101,7 +100,7 @@ protected function calculateStLeopoldsDay(): void $this->addHoliday(new Holiday( 'stLeopoldsDay', [], - new DateTime($this->year.'-11-15', new \DateTimeZone($this->timezone)), + new \DateTime($this->year.'-11-15', new \DateTimeZone($this->timezone)), $this->locale )); } @@ -130,7 +129,7 @@ private function calculateNationalDay(): void $this->addHoliday(new Holiday( 'nationalDay', ['de' => 'Nationalfeiertag'], - new DateTime($this->year.'-10-26', new \DateTimeZone($this->timezone)), + new \DateTime($this->year.'-10-26', new \DateTimeZone($this->timezone)), $this->locale )); } diff --git a/src/Yasumi/Provider/Austria/Carinthia.php b/src/Yasumi/Provider/Austria/Carinthia.php index 7fb449ed0..9804eaffb 100644 --- a/src/Yasumi/Provider/Austria/Carinthia.php +++ b/src/Yasumi/Provider/Austria/Carinthia.php @@ -14,7 +14,6 @@ namespace Yasumi\Provider\Austria; -use DateTime; use Yasumi\Exception\InvalidDateException; use Yasumi\Exception\UnknownLocaleException; use Yasumi\Holiday; @@ -74,7 +73,7 @@ private function calculatePlebisciteDay(): void $this->addHoliday(new Holiday( 'plebisciteDay', [], - new DateTime($this->year.'-10-10', new \DateTimeZone($this->timezone)), + new \DateTime($this->year.'-10-10', new \DateTimeZone($this->timezone)), $this->locale )); } diff --git a/src/Yasumi/Provider/Austria/Salzburg.php b/src/Yasumi/Provider/Austria/Salzburg.php index b342bb338..d8218e4f6 100644 --- a/src/Yasumi/Provider/Austria/Salzburg.php +++ b/src/Yasumi/Provider/Austria/Salzburg.php @@ -14,7 +14,6 @@ namespace Yasumi\Provider\Austria; -use DateTime; use Yasumi\Exception\InvalidDateException; use Yasumi\Exception\UnknownLocaleException; use Yasumi\Holiday; @@ -75,7 +74,7 @@ private function calculateStRupertsDay(): void $this->addHoliday(new Holiday( 'stRupertsDay', [], - new DateTime($this->year.'-9-24', new \DateTimeZone($this->timezone)), + new \DateTime($this->year.'-9-24', new \DateTimeZone($this->timezone)), $this->locale )); } diff --git a/src/Yasumi/Provider/Austria/UpperAustria.php b/src/Yasumi/Provider/Austria/UpperAustria.php index 63c30ed2f..0849e924c 100644 --- a/src/Yasumi/Provider/Austria/UpperAustria.php +++ b/src/Yasumi/Provider/Austria/UpperAustria.php @@ -14,7 +14,6 @@ namespace Yasumi\Provider\Austria; -use DateTime; use Yasumi\Exception\InvalidDateException; use Yasumi\Exception\UnknownLocaleException; use Yasumi\Holiday; @@ -76,7 +75,7 @@ private function calculateStFloriansDay(): void $this->addHoliday(new Holiday( 'stFloriansDay', [], - new DateTime($this->year.'-5-4', new \DateTimeZone($this->timezone)), + new \DateTime($this->year.'-5-4', new \DateTimeZone($this->timezone)), $this->locale )); } diff --git a/src/Yasumi/Provider/Belgium.php b/src/Yasumi/Provider/Belgium.php index 84f879f50..9f20255db 100644 --- a/src/Yasumi/Provider/Belgium.php +++ b/src/Yasumi/Provider/Belgium.php @@ -14,7 +14,6 @@ namespace Yasumi\Provider; -use DateTime; use Yasumi\Exception\InvalidDateException; use Yasumi\Exception\UnknownLocaleException; use Yasumi\Holiday; @@ -69,7 +68,7 @@ public function initialize(): void 'fr' => 'Fête nationale', 'en' => 'Belgian National Day', 'nl' => 'nationale feestdag', - ], new DateTime("$this->year-7-21", DateTimeZoneFactory::getDateTimeZone($this->timezone)), $this->locale)); + ], new \DateTime("$this->year-7-21", DateTimeZoneFactory::getDateTimeZone($this->timezone)), $this->locale)); } public function getSources(): array diff --git a/src/Yasumi/Provider/Bosnia.php b/src/Yasumi/Provider/Bosnia.php index 326a9c9c3..d3ea63469 100644 --- a/src/Yasumi/Provider/Bosnia.php +++ b/src/Yasumi/Provider/Bosnia.php @@ -14,7 +14,6 @@ namespace Yasumi\Provider; -use DateTime; use Yasumi\Exception\InvalidDateException; use Yasumi\Exception\UnknownLocaleException; use Yasumi\Holiday; @@ -61,7 +60,7 @@ public function initialize(): void $this->addHoliday(new Holiday('orthodoxChristmasDay', [ 'en' => 'Orthodox Christmas Day', 'bs_Latn' => 'Pravoslavni Božić', - ], new DateTime("$this->year-01-07", DateTimeZoneFactory::getDateTimeZone($this->timezone)))); + ], new \DateTime("$this->year-01-07", DateTimeZoneFactory::getDateTimeZone($this->timezone)))); /* * Independence Day @@ -70,7 +69,7 @@ public function initialize(): void $this->addHoliday(new Holiday('independenceDay', [ 'en' => 'Independence Day', 'bs_Latn' => 'Dan Nezavisnosti', - ], new DateTime("$this->year-3-1", DateTimeZoneFactory::getDateTimeZone($this->timezone)), $this->locale)); + ], new \DateTime("$this->year-3-1", DateTimeZoneFactory::getDateTimeZone($this->timezone)), $this->locale)); } /* @@ -80,7 +79,7 @@ public function initialize(): void $this->addHoliday(new Holiday('statehoodDay', [ 'en' => 'Statehood Day', 'bs_Latn' => 'Dan državnosti', - ], new DateTime("$this->year-11-25", DateTimeZoneFactory::getDateTimeZone($this->timezone)), $this->locale)); + ], new \DateTime("$this->year-11-25", DateTimeZoneFactory::getDateTimeZone($this->timezone)), $this->locale)); } /* @@ -89,7 +88,7 @@ public function initialize(): void $this->addHoliday(new Holiday('dayAfterNewYearsDay', [ 'en' => 'Day after New Year’s Day', 'bs_Latn' => 'Nova godina - drugi dan', - ], new DateTime("$this->year-01-02", DateTimeZoneFactory::getDateTimeZone($this->timezone)), $this->locale)); + ], new \DateTime("$this->year-01-02", DateTimeZoneFactory::getDateTimeZone($this->timezone)), $this->locale)); /* * Second Labour day @@ -97,7 +96,7 @@ public function initialize(): void $this->addHoliday(new Holiday('secondLabourDay', [ 'en' => 'Second Labour Day', 'bs_Latn' => 'Praznik rada - drugi dan', - ], new DateTime("$this->year-05-02", DateTimeZoneFactory::getDateTimeZone($this->timezone)), $this->locale)); + ], new \DateTime("$this->year-05-02", DateTimeZoneFactory::getDateTimeZone($this->timezone)), $this->locale)); } public function getSources(): array diff --git a/src/Yasumi/Provider/Brazil.php b/src/Yasumi/Provider/Brazil.php index 7a09d20c1..86ca66b8e 100644 --- a/src/Yasumi/Provider/Brazil.php +++ b/src/Yasumi/Provider/Brazil.php @@ -14,8 +14,6 @@ namespace Yasumi\Provider; -use DateInterval; -use DateTime; use Yasumi\Exception\InvalidDateException; use Yasumi\Exception\UnknownLocaleException; use Yasumi\Holiday; @@ -72,7 +70,7 @@ public function initialize(): void $this->addHoliday(new Holiday( 'carnavalMonday', ['pt' => 'Segunda-feira de Carnaval'], - $carnavalMonday->sub(new DateInterval('P48D')), + $carnavalMonday->sub(new \DateInterval('P48D')), $this->locale, Holiday::TYPE_OBSERVANCE )); @@ -81,7 +79,7 @@ public function initialize(): void $this->addHoliday(new Holiday( 'carnavalTuesday', ['pt' => 'Terça-feira de Carnaval'], - $carnavalTuesday->sub(new DateInterval('P47D')), + $carnavalTuesday->sub(new \DateInterval('P47D')), $this->locale, Holiday::TYPE_OBSERVANCE )); @@ -100,7 +98,7 @@ public function initialize(): void $this->addHoliday(new Holiday( 'tiradentesDay', ['pt' => 'Dia de Tiradentes'], - new DateTime("$this->year-04-21", DateTimeZoneFactory::getDateTimeZone($this->timezone)), + new \DateTime("$this->year-04-21", DateTimeZoneFactory::getDateTimeZone($this->timezone)), $this->locale )); } @@ -117,7 +115,7 @@ public function initialize(): void $this->addHoliday(new Holiday( 'independenceDay', ['pt' => 'Dia da Independência do Brasil'], - new DateTime("$this->year-09-07", DateTimeZoneFactory::getDateTimeZone($this->timezone)), + new \DateTime("$this->year-09-07", DateTimeZoneFactory::getDateTimeZone($this->timezone)), $this->locale )); } @@ -137,7 +135,7 @@ public function initialize(): void $this->addHoliday(new Holiday( 'ourLadyOfAparecidaDay', ['pt' => 'Dia de Nossa Senhora Aparecida'], - new DateTime("$this->year-10-12", DateTimeZoneFactory::getDateTimeZone($this->timezone)), + new \DateTime("$this->year-10-12", DateTimeZoneFactory::getDateTimeZone($this->timezone)), $this->locale )); } @@ -153,7 +151,7 @@ public function initialize(): void $this->addHoliday(new Holiday( 'allSoulsDay', [], - new DateTime("$this->year-11-02", DateTimeZoneFactory::getDateTimeZone($this->timezone)), + new \DateTime("$this->year-11-02", DateTimeZoneFactory::getDateTimeZone($this->timezone)), $this->locale )); } @@ -171,7 +169,7 @@ public function initialize(): void $this->addHoliday(new Holiday( 'proclamationOfRepublicDay', ['pt' => 'Dia da Proclamação da República'], - new DateTime("$this->year-11-15", DateTimeZoneFactory::getDateTimeZone($this->timezone)), + new \DateTime("$this->year-11-15", DateTimeZoneFactory::getDateTimeZone($this->timezone)), $this->locale )); } diff --git a/src/Yasumi/Provider/Canada.php b/src/Yasumi/Provider/Canada.php index 6fc52365e..57efa58f4 100644 --- a/src/Yasumi/Provider/Canada.php +++ b/src/Yasumi/Provider/Canada.php @@ -15,7 +15,6 @@ namespace Yasumi\Provider; -use DateTime; use Yasumi\Exception\InvalidDateException; use Yasumi\Exception\UnknownLocaleException; use Yasumi\Holiday; @@ -89,7 +88,7 @@ protected function calculateFamilyDay(): void $this->addHoliday(new Holiday( 'familyDay', [], - new DateTime("third monday of february $this->year", DateTimeZoneFactory::getDateTimeZone($this->timezone)), + new \DateTime("third monday of february $this->year", DateTimeZoneFactory::getDateTimeZone($this->timezone)), $this->locale )); } @@ -113,7 +112,7 @@ protected function calculateVictoriaDay(): void $this->addHoliday(new Holiday( 'victoriaDay', [], - new DateTime("last monday front of $this->year-05-25", DateTimeZoneFactory::getDateTimeZone($this->timezone)), + new \DateTime("last monday front of $this->year-05-25", DateTimeZoneFactory::getDateTimeZone($this->timezone)), $this->locale )); } @@ -137,7 +136,7 @@ protected function calculateNationalIndigenousPeoplesDay(): void $this->addHoliday(new Holiday( 'nationalIndigenousPeoplesDay', [], - new DateTime("$this->year-06-21", DateTimeZoneFactory::getDateTimeZone($this->timezone)), + new \DateTime("$this->year-06-21", DateTimeZoneFactory::getDateTimeZone($this->timezone)), $this->locale )); } @@ -161,7 +160,7 @@ protected function calculateCivicHoliday(): void $this->addHoliday(new Holiday( 'civicHoliday', [], - new DateTime("first monday of august $this->year", DateTimeZoneFactory::getDateTimeZone($this->timezone)), + new \DateTime("first monday of august $this->year", DateTimeZoneFactory::getDateTimeZone($this->timezone)), $this->locale )); } @@ -185,9 +184,9 @@ private function calculateCanadaDay(): void if ($this->year < 1983) { return; } - $date = new DateTime($this->year.'-07-01', DateTimeZoneFactory::getDateTimeZone($this->timezone)); + $date = new \DateTime($this->year.'-07-01', DateTimeZoneFactory::getDateTimeZone($this->timezone)); if (7 === (int) $date->format('N')) { - $date = new DateTime($this->year.'-07-02', DateTimeZoneFactory::getDateTimeZone($this->timezone)); + $date = new \DateTime($this->year.'-07-02', DateTimeZoneFactory::getDateTimeZone($this->timezone)); } $this->addHoliday(new Holiday( 'canadaDay', @@ -216,7 +215,7 @@ private function calculateThanksgivingDay(): void $this->addHoliday(new Holiday( 'thanksgivingDay', [], - new DateTime("second monday of october $this->year", DateTimeZoneFactory::getDateTimeZone($this->timezone)), + new \DateTime("second monday of october $this->year", DateTimeZoneFactory::getDateTimeZone($this->timezone)), $this->locale )); } @@ -240,7 +239,7 @@ private function calculateRemembranceDay(): void $this->addHoliday(new Holiday( 'remembranceDay', [], - new DateTime("$this->year-11-11", DateTimeZoneFactory::getDateTimeZone($this->timezone)), + new \DateTime("$this->year-11-11", DateTimeZoneFactory::getDateTimeZone($this->timezone)), $this->locale )); } @@ -264,7 +263,7 @@ private function calculateLabourDay(): void $this->addHoliday(new Holiday( 'labourDay', [], - new DateTime("first monday of september $this->year", DateTimeZoneFactory::getDateTimeZone($this->timezone)), + new \DateTime("first monday of september $this->year", DateTimeZoneFactory::getDateTimeZone($this->timezone)), $this->locale )); } @@ -288,7 +287,7 @@ private function calculateNationalDayForTruthAndReconciliation(): void $this->addHoliday(new Holiday( 'truthAndReconciliationDay', [], - new DateTime("last day of september $this->year", DateTimeZoneFactory::getDateTimeZone($this->timezone)), + new \DateTime("last day of september $this->year", DateTimeZoneFactory::getDateTimeZone($this->timezone)), $this->locale )); } diff --git a/src/Yasumi/Provider/Canada/Alberta.php b/src/Yasumi/Provider/Canada/Alberta.php index 21f387e7d..cc8ce0ac4 100644 --- a/src/Yasumi/Provider/Canada/Alberta.php +++ b/src/Yasumi/Provider/Canada/Alberta.php @@ -14,7 +14,6 @@ namespace Yasumi\Provider\Canada; -use DateTime; use Yasumi\Exception\InvalidDateException; use Yasumi\Exception\UnknownLocaleException; use Yasumi\Holiday; @@ -74,7 +73,7 @@ private function calculateHeritageDay(): void $this->addHoliday(new Holiday( 'heritageDay', [], - new DateTime("first monday of august $this->year", DateTimeZoneFactory::getDateTimeZone($this->timezone)), + new \DateTime("first monday of august $this->year", DateTimeZoneFactory::getDateTimeZone($this->timezone)), $this->locale )); } diff --git a/src/Yasumi/Provider/Canada/Manitoba.php b/src/Yasumi/Provider/Canada/Manitoba.php index 4aa9af92f..26a482db2 100644 --- a/src/Yasumi/Provider/Canada/Manitoba.php +++ b/src/Yasumi/Provider/Canada/Manitoba.php @@ -14,7 +14,6 @@ namespace Yasumi\Provider\Canada; -use DateTime; use Yasumi\Exception\InvalidDateException; use Yasumi\Exception\UnknownLocaleException; use Yasumi\Holiday; @@ -74,7 +73,7 @@ protected function calculateCivicHoliday(): void $this->addHoliday(new Holiday( 'terryFoxDay', [], - new DateTime("first monday of august $this->year", DateTimeZoneFactory::getDateTimeZone($this->timezone)), + new \DateTime("first monday of august $this->year", DateTimeZoneFactory::getDateTimeZone($this->timezone)), $this->locale )); } @@ -98,7 +97,7 @@ private function calculateLouisRielDay(): void $this->addHoliday(new Holiday( 'louisRielDay', [], - new DateTime("third monday of february $this->year", DateTimeZoneFactory::getDateTimeZone($this->timezone)), + new \DateTime("third monday of february $this->year", DateTimeZoneFactory::getDateTimeZone($this->timezone)), $this->locale )); } diff --git a/src/Yasumi/Provider/Canada/NewfoundlandAndLabrador.php b/src/Yasumi/Provider/Canada/NewfoundlandAndLabrador.php index ebd4556a1..24f2a3e22 100644 --- a/src/Yasumi/Provider/Canada/NewfoundlandAndLabrador.php +++ b/src/Yasumi/Provider/Canada/NewfoundlandAndLabrador.php @@ -14,7 +14,6 @@ namespace Yasumi\Provider\Canada; -use DateTime; use Yasumi\Exception\InvalidDateException; use Yasumi\Exception\UnknownLocaleException; use Yasumi\Holiday; @@ -82,7 +81,7 @@ private function calculateStPatricksDay(): void $holiday = new Holiday( 'stPatricksDay', ['en' => 'St. Patrick’s Day'], - new DateTime($this->year.'-3-17', DateTimeZoneFactory::getDateTimeZone($this->timezone)), + new \DateTime($this->year.'-3-17', DateTimeZoneFactory::getDateTimeZone($this->timezone)), $this->locale, Holiday::TYPE_BANK ); @@ -128,7 +127,7 @@ private function calculateOrangemensDay(): void $holiday = new Holiday( 'orangemensDay', [], - new DateTime($this->year.'-7-12', DateTimeZoneFactory::getDateTimeZone($this->timezone)), + new \DateTime($this->year.'-7-12', DateTimeZoneFactory::getDateTimeZone($this->timezone)), $this->locale, Holiday::TYPE_BANK ); diff --git a/src/Yasumi/Provider/Canada/NovaScotia.php b/src/Yasumi/Provider/Canada/NovaScotia.php index c4141842e..ecadaca14 100644 --- a/src/Yasumi/Provider/Canada/NovaScotia.php +++ b/src/Yasumi/Provider/Canada/NovaScotia.php @@ -14,7 +14,6 @@ namespace Yasumi\Provider\Canada; -use DateTime; use Yasumi\Exception\InvalidDateException; use Yasumi\Exception\UnknownLocaleException; use Yasumi\Holiday; @@ -74,7 +73,7 @@ protected function calculateCivicHoliday(): void $this->addHoliday(new Holiday( 'natalHoliday', [], - new DateTime("first monday of august $this->year", DateTimeZoneFactory::getDateTimeZone($this->timezone)), + new \DateTime("first monday of august $this->year", DateTimeZoneFactory::getDateTimeZone($this->timezone)), $this->locale )); } @@ -98,7 +97,7 @@ private function calculateHeritageDay(): void $this->addHoliday(new Holiday( 'novaScotiaHeritageDay', [], - new DateTime("third monday of february $this->year", DateTimeZoneFactory::getDateTimeZone($this->timezone)), + new \DateTime("third monday of february $this->year", DateTimeZoneFactory::getDateTimeZone($this->timezone)), $this->locale )); } diff --git a/src/Yasumi/Provider/Canada/PrinceEdwardIsland.php b/src/Yasumi/Provider/Canada/PrinceEdwardIsland.php index 68373252a..660c78549 100644 --- a/src/Yasumi/Provider/Canada/PrinceEdwardIsland.php +++ b/src/Yasumi/Provider/Canada/PrinceEdwardIsland.php @@ -14,7 +14,6 @@ namespace Yasumi\Provider\Canada; -use DateTime; use Yasumi\Exception\InvalidDateException; use Yasumi\Exception\UnknownLocaleException; use Yasumi\Holiday; @@ -74,7 +73,7 @@ private function calculateIslanderDay(): void $this->addHoliday(new Holiday( 'islanderDay', [], - new DateTime("third monday of february $this->year", DateTimeZoneFactory::getDateTimeZone($this->timezone)), + new \DateTime("third monday of february $this->year", DateTimeZoneFactory::getDateTimeZone($this->timezone)), $this->locale )); } @@ -98,7 +97,7 @@ private function calculateGoldCupParadeDay(): void $this->addHoliday(new Holiday( 'goldCupParadeDay', [], - new DateTime("third friday of august $this->year", DateTimeZoneFactory::getDateTimeZone($this->timezone)), + new \DateTime("third friday of august $this->year", DateTimeZoneFactory::getDateTimeZone($this->timezone)), $this->locale )); } diff --git a/src/Yasumi/Provider/Canada/Quebec.php b/src/Yasumi/Provider/Canada/Quebec.php index 2275fc17b..7d79cad75 100644 --- a/src/Yasumi/Provider/Canada/Quebec.php +++ b/src/Yasumi/Provider/Canada/Quebec.php @@ -14,7 +14,6 @@ namespace Yasumi\Provider\Canada; -use DateTime; use Yasumi\Exception\InvalidDateException; use Yasumi\Exception\UnknownLocaleException; use Yasumi\Holiday; @@ -85,7 +84,7 @@ private function saintJeanBaptisteDay( return new Holiday( 'saintJeanBaptisteDay', [], - new DateTime("$year-06-24", DateTimeZoneFactory::getDateTimeZone($timezone)), + new \DateTime("$year-06-24", DateTimeZoneFactory::getDateTimeZone($timezone)), $locale, $type ); @@ -110,7 +109,7 @@ private function calculateNationalPatriotsDay(): void $this->addHoliday(new Holiday( 'nationalPatriotsDay', [], - new DateTime("last monday front of $this->year-05-25", DateTimeZoneFactory::getDateTimeZone($this->timezone)), + new \DateTime("last monday front of $this->year-05-25", DateTimeZoneFactory::getDateTimeZone($this->timezone)), $this->locale )); } diff --git a/src/Yasumi/Provider/Canada/Saskatchewan.php b/src/Yasumi/Provider/Canada/Saskatchewan.php index 666ad56b8..7cce867da 100644 --- a/src/Yasumi/Provider/Canada/Saskatchewan.php +++ b/src/Yasumi/Provider/Canada/Saskatchewan.php @@ -14,7 +14,6 @@ namespace Yasumi\Provider\Canada; -use DateTime; use Yasumi\Exception\InvalidDateException; use Yasumi\Exception\UnknownLocaleException; use Yasumi\Holiday; @@ -74,7 +73,7 @@ private function calculateSaskatchewanDay(): void $this->addHoliday(new Holiday( 'saskatchewanDay', [], - new DateTime("first monday of august $this->year", DateTimeZoneFactory::getDateTimeZone($this->timezone)), + new \DateTime("first monday of august $this->year", DateTimeZoneFactory::getDateTimeZone($this->timezone)), $this->locale )); } diff --git a/src/Yasumi/Provider/Canada/Yukon.php b/src/Yasumi/Provider/Canada/Yukon.php index fdb4d981f..21ac970f2 100644 --- a/src/Yasumi/Provider/Canada/Yukon.php +++ b/src/Yasumi/Provider/Canada/Yukon.php @@ -14,7 +14,6 @@ namespace Yasumi\Provider\Canada; -use DateTime; use Yasumi\Exception\InvalidDateException; use Yasumi\Exception\UnknownLocaleException; use Yasumi\Holiday; @@ -75,7 +74,7 @@ private function calculateDiscoveryDay(): void $this->addHoliday(new Holiday( 'discoveryDay', [], - new DateTime("third monday of august $this->year", DateTimeZoneFactory::getDateTimeZone($this->timezone)), + new \DateTime("third monday of august $this->year", DateTimeZoneFactory::getDateTimeZone($this->timezone)), $this->locale )); } @@ -99,7 +98,7 @@ private function calculateHeritageDay(): void $this->addHoliday(new Holiday( 'yukonHeritageDay', [], - new DateTime("first monday of august $this->year", DateTimeZoneFactory::getDateTimeZone($this->timezone)), + new \DateTime("first monday of august $this->year", DateTimeZoneFactory::getDateTimeZone($this->timezone)), $this->locale )); } diff --git a/src/Yasumi/Provider/ChristianHolidays.php b/src/Yasumi/Provider/ChristianHolidays.php index 614b9fb25..ec4018016 100644 --- a/src/Yasumi/Provider/ChristianHolidays.php +++ b/src/Yasumi/Provider/ChristianHolidays.php @@ -14,8 +14,6 @@ namespace Yasumi\Provider; -use DateInterval; -use DateTime; use Yasumi\Exception\InvalidDateException; use Yasumi\Exception\UnknownLocaleException; use Yasumi\Holiday; @@ -56,7 +54,7 @@ protected function corpusChristi( return new Holiday( 'corpusChristi', [], - $this->calculateEaster($year, $timezone)->add(new DateInterval('P60D')), + $this->calculateEaster($year, $timezone)->add(new \DateInterval('P60D')), $locale, $type ); @@ -89,7 +87,7 @@ protected function allSaintsDay( string $locale, string $type = Holiday::TYPE_OFFICIAL ): Holiday { - return new Holiday('allSaintsDay', [], new DateTime("$year-11-1", DateTimeZoneFactory::getDateTimeZone($timezone)), $locale, $type); + return new Holiday('allSaintsDay', [], new \DateTime("$year-11-1", DateTimeZoneFactory::getDateTimeZone($timezone)), $locale, $type); } /** @@ -121,7 +119,7 @@ protected function assumptionOfMary( return new Holiday( 'assumptionOfMary', [], - new DateTime("$year-8-15", DateTimeZoneFactory::getDateTimeZone($timezone)), + new \DateTime("$year-8-15", DateTimeZoneFactory::getDateTimeZone($timezone)), $locale, $type ); @@ -154,7 +152,7 @@ protected function goodFriday( return new Holiday( 'goodFriday', [], - $this->calculateEaster($year, $timezone)->sub(new DateInterval('P2D')), + $this->calculateEaster($year, $timezone)->sub(new \DateInterval('P2D')), $locale, $type ); @@ -188,7 +186,7 @@ protected function epiphany( string $locale, string $type = Holiday::TYPE_OFFICIAL ): Holiday { - return new Holiday('epiphany', [], new DateTime("$year-1-6", DateTimeZoneFactory::getDateTimeZone($timezone)), $locale, $type); + return new Holiday('epiphany', [], new \DateTime("$year-1-6", DateTimeZoneFactory::getDateTimeZone($timezone)), $locale, $type); } /** @@ -219,7 +217,7 @@ protected function stJosephsDay( string $locale, string $type = Holiday::TYPE_OFFICIAL ): Holiday { - return new Holiday('stJosephsDay', [], new DateTime("$year-3-19", DateTimeZoneFactory::getDateTimeZone($timezone)), $locale, $type); + return new Holiday('stJosephsDay', [], new \DateTime("$year-3-19", DateTimeZoneFactory::getDateTimeZone($timezone)), $locale, $type); } /** @@ -249,7 +247,7 @@ protected function stGeorgesDay( string $locale, string $type = Holiday::TYPE_OFFICIAL ): Holiday { - return new Holiday('stGeorgesDay', [], new DateTime("$year-4-23", DateTimeZoneFactory::getDateTimeZone($timezone)), $locale, $type); + return new Holiday('stGeorgesDay', [], new \DateTime("$year-4-23", DateTimeZoneFactory::getDateTimeZone($timezone)), $locale, $type); } /** @@ -275,7 +273,7 @@ protected function calculateOrthodoxEaster(int $year, string $timezone): \DateTi $month = floor(($d + $e + 114) / 31); $day = (($d + $e + 114) % 31) + 1; - return (new DateTime("$year-$month-$day", DateTimeZoneFactory::getDateTimeZone($timezone)))->add(new DateInterval('P13D')); + return (new \DateTime("$year-$month-$day", DateTimeZoneFactory::getDateTimeZone($timezone)))->add(new \DateInterval('P13D')); } /** @@ -313,7 +311,7 @@ protected function reformationDay( return new Holiday( 'reformationDay', [], - new DateTime("$year-10-31", DateTimeZoneFactory::getDateTimeZone($timezone)), + new \DateTime("$year-10-31", DateTimeZoneFactory::getDateTimeZone($timezone)), $locale, $type ); @@ -390,8 +388,8 @@ protected function calculateEaster(int $year, string $timezone): \DateTimeInterf $easterDays = $pfm + $tmp + 1; // Easter as the number of days after 21st March } - $easter = new DateTime("$year-3-21", DateTimeZoneFactory::getDateTimeZone($timezone)); - $easter->add(new DateInterval('P'.$easterDays.'D')); + $easter = new \DateTime("$year-3-21", DateTimeZoneFactory::getDateTimeZone($timezone)); + $easter->add(new \DateInterval('P'.$easterDays.'D')); return $easter; } @@ -451,7 +449,7 @@ protected function pentecost( return new Holiday( 'pentecost', [], - $this->calculateEaster($year, $timezone)->add(new DateInterval('P49D')), + $this->calculateEaster($year, $timezone)->add(new \DateInterval('P49D')), $locale, $type ); @@ -486,7 +484,7 @@ protected function easterMonday( return new Holiday( 'easterMonday', [], - $this->calculateEaster($year, $timezone)->add(new DateInterval('P1D')), + $this->calculateEaster($year, $timezone)->add(new \DateInterval('P1D')), $locale, $type ); @@ -521,7 +519,7 @@ protected function ascensionDay( return new Holiday( 'ascensionDay', [], - $this->calculateEaster($year, $timezone)->add(new DateInterval('P39D')), + $this->calculateEaster($year, $timezone)->add(new \DateInterval('P39D')), $locale, $type ); @@ -553,7 +551,7 @@ protected function pentecostMonday( return new Holiday( 'pentecostMonday', [], - $this->calculateEaster($year, $timezone)->add(new DateInterval('P50D')), + $this->calculateEaster($year, $timezone)->add(new \DateInterval('P50D')), $locale, $type ); @@ -589,7 +587,7 @@ protected function christmasEve( return new Holiday( 'christmasEve', [], - new DateTime("$year-12-24", DateTimeZoneFactory::getDateTimeZone($timezone)), + new \DateTime("$year-12-24", DateTimeZoneFactory::getDateTimeZone($timezone)), $locale, $type ); @@ -622,7 +620,7 @@ protected function christmasDay( return new Holiday( 'christmasDay', [], - new DateTime("$year-12-25", DateTimeZoneFactory::getDateTimeZone($timezone)), + new \DateTime("$year-12-25", DateTimeZoneFactory::getDateTimeZone($timezone)), $locale, $type ); @@ -655,7 +653,7 @@ protected function secondChristmasDay( return new Holiday( 'secondChristmasDay', [], - new DateTime("$year-12-26", DateTimeZoneFactory::getDateTimeZone($timezone)), + new \DateTime("$year-12-26", DateTimeZoneFactory::getDateTimeZone($timezone)), $locale, $type ); @@ -690,7 +688,7 @@ protected function ashWednesday( return new Holiday( 'ashWednesday', [], - $this->calculateEaster($year, $timezone)->sub(new DateInterval('P46D')), + $this->calculateEaster($year, $timezone)->sub(new \DateInterval('P46D')), $locale, $type ); @@ -726,7 +724,7 @@ protected function immaculateConception( return new Holiday( 'immaculateConception', [], - new DateTime("$year-12-8", DateTimeZoneFactory::getDateTimeZone($timezone)), + new \DateTime("$year-12-8", DateTimeZoneFactory::getDateTimeZone($timezone)), $locale, $type ); @@ -763,7 +761,7 @@ protected function stStephensDay( return new Holiday( 'stStephensDay', [], - new DateTime("$year-12-26", DateTimeZoneFactory::getDateTimeZone($timezone)), + new \DateTime("$year-12-26", DateTimeZoneFactory::getDateTimeZone($timezone)), $locale, $type ); @@ -799,7 +797,7 @@ protected function maundyThursday( return new Holiday( 'maundyThursday', [], - $this->calculateEaster($year, $timezone)->sub(new DateInterval('P3D')), + $this->calculateEaster($year, $timezone)->sub(new \DateInterval('P3D')), $locale, $type ); @@ -833,7 +831,7 @@ protected function stJohnsDay( string $locale, string $type = Holiday::TYPE_OFFICIAL ): Holiday { - return new Holiday('stJohnsDay', [], new DateTime("$year-06-24", DateTimeZoneFactory::getDateTimeZone($timezone)), $locale, $type); + return new Holiday('stJohnsDay', [], new \DateTime("$year-06-24", DateTimeZoneFactory::getDateTimeZone($timezone)), $locale, $type); } /** @@ -867,7 +865,7 @@ protected function annunciation( return new Holiday( 'annunciation', [], - new DateTime("$year-03-25", DateTimeZoneFactory::getDateTimeZone($timezone)), + new \DateTime("$year-03-25", DateTimeZoneFactory::getDateTimeZone($timezone)), $locale, $type ); diff --git a/src/Yasumi/Provider/CommonHolidays.php b/src/Yasumi/Provider/CommonHolidays.php index 329c5435b..49a6fc11f 100644 --- a/src/Yasumi/Provider/CommonHolidays.php +++ b/src/Yasumi/Provider/CommonHolidays.php @@ -55,7 +55,7 @@ protected function newYearsDay( string $locale, string $type = Holiday::TYPE_OFFICIAL ): Holiday { - return new Holiday('newYearsDay', [], new DateTime("$year-1-1", DateTimeZoneFactory::getDateTimeZone($timezone)), $locale, $type); + return new Holiday('newYearsDay', [], new \DateTime("$year-1-1", DateTimeZoneFactory::getDateTimeZone($timezone)), $locale, $type); } /** @@ -89,7 +89,7 @@ protected function internationalWorkersDay( return new Holiday( 'internationalWorkersDay', [], - new DateTime("$year-5-1", DateTimeZoneFactory::getDateTimeZone($timezone)), + new \DateTime("$year-5-1", DateTimeZoneFactory::getDateTimeZone($timezone)), $locale, $type ); @@ -126,7 +126,7 @@ protected function stMartinsDay( return new Holiday( 'stMartinsDay', [], - new DateTime("$year-11-11", DateTimeZoneFactory::getDateTimeZone($timezone)), + new \DateTime("$year-11-11", DateTimeZoneFactory::getDateTimeZone($timezone)), $locale, $type ); @@ -159,7 +159,7 @@ protected function internationalWomensDay( return new Holiday( 'internationalWomensDay', [], - new DateTime("$year-03-08", DateTimeZoneFactory::getDateTimeZone($timezone)), + new \DateTime("$year-03-08", DateTimeZoneFactory::getDateTimeZone($timezone)), $locale, $type ); @@ -192,7 +192,7 @@ protected function newYearsEve( string $locale, string $type = Holiday::TYPE_OFFICIAL ): Holiday { - return new Holiday('newYearsEve', [], new DateTime("$year-12-31", DateTimeZoneFactory::getDateTimeZone($timezone)), $locale, $type); + return new Holiday('newYearsEve', [], new \DateTime("$year-12-31", DateTimeZoneFactory::getDateTimeZone($timezone)), $locale, $type); } /** @@ -226,7 +226,7 @@ protected function valentinesDay( return new Holiday( 'valentinesDay', [], - new DateTime("$year-2-14", DateTimeZoneFactory::getDateTimeZone($timezone)), + new \DateTime("$year-2-14", DateTimeZoneFactory::getDateTimeZone($timezone)), $locale, $type ); @@ -261,7 +261,7 @@ protected function worldAnimalDay( return new Holiday( 'worldAnimalDay', [], - new DateTime("$year-10-4", DateTimeZoneFactory::getDateTimeZone($timezone)), + new \DateTime("$year-10-4", DateTimeZoneFactory::getDateTimeZone($timezone)), $locale, $type ); @@ -297,7 +297,7 @@ protected function fathersDay( return new Holiday( 'fathersDay', [], - new DateTime("third sunday of june $year", DateTimeZoneFactory::getDateTimeZone($timezone)), + new \DateTime("third sunday of june $year", DateTimeZoneFactory::getDateTimeZone($timezone)), $locale, $type ); @@ -333,7 +333,7 @@ protected function mothersDay( return new Holiday( 'mothersDay', [], - new DateTime("second sunday of may $year", DateTimeZoneFactory::getDateTimeZone($timezone)), + new \DateTime("second sunday of may $year", DateTimeZoneFactory::getDateTimeZone($timezone)), $locale, $type ); @@ -369,7 +369,7 @@ protected function victoryInEuropeDay( return new Holiday( 'victoryInEuropeDay', [], - new DateTime("$year-5-8", DateTimeZoneFactory::getDateTimeZone($timezone)), + new \DateTime("$year-5-8", DateTimeZoneFactory::getDateTimeZone($timezone)), $locale, $type ); @@ -407,7 +407,7 @@ protected function armisticeDay( return new Holiday( 'armisticeDay', [], - new DateTime("$year-11-11", DateTimeZoneFactory::getDateTimeZone($timezone)), + new \DateTime("$year-11-11", DateTimeZoneFactory::getDateTimeZone($timezone)), $locale, $type ); diff --git a/src/Yasumi/Provider/Croatia.php b/src/Yasumi/Provider/Croatia.php index e64bf30b6..64465d76b 100644 --- a/src/Yasumi/Provider/Croatia.php +++ b/src/Yasumi/Provider/Croatia.php @@ -14,7 +14,6 @@ namespace Yasumi\Provider; -use DateTime; use Yasumi\Exception\InvalidDateException; use Yasumi\Exception\UnknownLocaleException; use Yasumi\Holiday; @@ -68,7 +67,7 @@ public function initialize(): void $this->addHoliday(new Holiday('antifascistStruggleDay', [ 'en' => 'Day of Antifascist Struggle', 'hr' => 'Dan antifašističke borbe', - ], new DateTime("$this->year-6-22", DateTimeZoneFactory::getDateTimeZone($this->timezone)), $this->locale)); + ], new \DateTime("$this->year-6-22", DateTimeZoneFactory::getDateTimeZone($this->timezone)), $this->locale)); } $this->calculateStatehoodDay(); @@ -97,9 +96,9 @@ private function calculateStatehoodDay(): void $statehoodDayDate = null; if ($this->year >= 1991 && $this->year < 2020) { - $statehoodDayDate = new DateTime("$this->year-6-25", DateTimeZoneFactory::getDateTimeZone($this->timezone)); + $statehoodDayDate = new \DateTime("$this->year-6-25", DateTimeZoneFactory::getDateTimeZone($this->timezone)); } elseif ($this->year >= 2020) { - $statehoodDayDate = new DateTime("$this->year-5-30", DateTimeZoneFactory::getDateTimeZone($this->timezone)); + $statehoodDayDate = new \DateTime("$this->year-5-30", DateTimeZoneFactory::getDateTimeZone($this->timezone)); } if (null !== $statehoodDayDate) { @@ -131,7 +130,7 @@ private function calculateHomelandThanksgivingDay(): void $this->addHoliday(new Holiday( 'homelandThanksgiving', $names, - new DateTime("$this->year-8-5", DateTimeZoneFactory::getDateTimeZone($this->timezone)), + new \DateTime("$this->year-8-5", DateTimeZoneFactory::getDateTimeZone($this->timezone)), $this->locale )); } @@ -150,7 +149,7 @@ private function calculateIndependenceDay(): void $this->addHoliday(new Holiday('independenceDay', [ 'en' => 'Independence Day', 'hr' => 'Dan neovisnosti', - ], new DateTime("$this->year-10-8", DateTimeZoneFactory::getDateTimeZone($this->timezone)), $this->locale)); + ], new \DateTime("$this->year-10-8", DateTimeZoneFactory::getDateTimeZone($this->timezone)), $this->locale)); } } @@ -166,7 +165,7 @@ private function calculateRemembranceDayForHomelandWarVictims(): void $this->addHoliday(new Holiday('remembranceDay', [ 'en' => 'Remembrance Day for Homeland War Victims and Remembrance Day for the Victims of Vukovar and Skabrnja', 'hr' => 'Dan sjećanja na žrtve Domovinskog rata i Dan sjećanja na žrtvu Vukovara i Škabrnje', - ], new DateTime("$this->year-11-18", DateTimeZoneFactory::getDateTimeZone($this->timezone)), $this->locale)); + ], new \DateTime("$this->year-11-18", DateTimeZoneFactory::getDateTimeZone($this->timezone)), $this->locale)); } } } diff --git a/src/Yasumi/Provider/CzechRepublic.php b/src/Yasumi/Provider/CzechRepublic.php index fe7db41e3..e8a593f2d 100644 --- a/src/Yasumi/Provider/CzechRepublic.php +++ b/src/Yasumi/Provider/CzechRepublic.php @@ -14,7 +14,6 @@ namespace Yasumi\Provider; -use DateTime; use Yasumi\Exception\InvalidDateException; use Yasumi\Exception\UnknownLocaleException; use Yasumi\Holiday; @@ -91,7 +90,7 @@ private function calculateRenewalOfCzechIndependenceDay(): void 'cs' => 'Den obnovy samostatného českého státu', 'en' => 'Day of renewal of the independent Czech state', ], - new DateTime($this->year.'-01-01', new \DateTimeZone($this->timezone)), + new \DateTime($this->year.'-01-01', new \DateTimeZone($this->timezone)), $this->locale )); } @@ -125,7 +124,7 @@ private function calculateSaintsCyrilAndMethodiusDay(): void 'cs' => 'Den slovanských věrozvěstů Cyrila a Metoděje', 'en' => 'Saints Cyril and Methodius Day', ], - new DateTime($this->year.'-07-5', new \DateTimeZone($this->timezone)), + new \DateTime($this->year.'-07-5', new \DateTimeZone($this->timezone)), $this->locale )); } @@ -150,7 +149,7 @@ private function calculateJanHusDay(): void $this->addHoliday(new Holiday( 'janHusDay', ['cs' => 'Den upálení mistra Jana Husa', 'en' => 'Jan Hus Day'], - new DateTime($this->year.'-07-6', new \DateTimeZone($this->timezone)), + new \DateTime($this->year.'-07-6', new \DateTimeZone($this->timezone)), $this->locale )); } @@ -181,7 +180,7 @@ private function calculateCzechStatehoodDay(): void 'cs' => 'Den české státnosti', 'en' => 'St. Wenceslas Day (Czech Statehood Day)', ], - new DateTime($this->year.'-09-28', new \DateTimeZone($this->timezone)), + new \DateTime($this->year.'-09-28', new \DateTimeZone($this->timezone)), $this->locale )); } @@ -201,7 +200,7 @@ private function calculateIndependentCzechoslovakStateDay(): void $this->addHoliday(new Holiday('independentCzechoslovakStateDay', [ 'cs' => 'Den vzniku samostatného československého státu', 'en' => 'Independent Czechoslovak State Day', - ], new DateTime($this->year.'-10-28', new \DateTimeZone($this->timezone)), $this->locale)); + ], new \DateTime($this->year.'-10-28', new \DateTimeZone($this->timezone)), $this->locale)); } /** @@ -222,7 +221,7 @@ private function calculateStruggleForFreedomAndDemocracyDay(): void 'cs' => 'Den boje za svobodu a demokracii', 'en' => 'Struggle for Freedom and Democracy Day', ], - new DateTime($this->year.'-11-17', new \DateTimeZone($this->timezone)), + new \DateTime($this->year.'-11-17', new \DateTimeZone($this->timezone)), $this->locale )); } diff --git a/src/Yasumi/Provider/Denmark.php b/src/Yasumi/Provider/Denmark.php index deeef714c..72d54b23b 100644 --- a/src/Yasumi/Provider/Denmark.php +++ b/src/Yasumi/Provider/Denmark.php @@ -15,7 +15,6 @@ namespace Yasumi\Provider; -use DateTime; use Yasumi\Exception\InvalidDateException; use Yasumi\Exception\UnknownLocaleException; use Yasumi\Holiday; @@ -107,7 +106,7 @@ private function calculateGreatPrayerDay(): void $this->addHoliday(new Holiday( 'greatPrayerDay', ['da' => 'store bededag'], - new DateTime("fourth friday $easter", DateTimeZoneFactory::getDateTimeZone($this->timezone)), + new \DateTime("fourth friday $easter", DateTimeZoneFactory::getDateTimeZone($this->timezone)), $this->locale )); } @@ -135,7 +134,7 @@ private function calculateConstitutionDay(): void $this->addHoliday(new Holiday( 'constitutionDay', ['da' => 'grundlovsdag'], - new DateTime("$this->year-6-5", DateTimeZoneFactory::getDateTimeZone($this->timezone)), + new \DateTime("$this->year-6-5", DateTimeZoneFactory::getDateTimeZone($this->timezone)), $this->locale, Holiday::TYPE_OBSERVANCE )); diff --git a/src/Yasumi/Provider/Finland.php b/src/Yasumi/Provider/Finland.php index 8370df710..c6e3170eb 100644 --- a/src/Yasumi/Provider/Finland.php +++ b/src/Yasumi/Provider/Finland.php @@ -14,7 +14,6 @@ namespace Yasumi\Provider; -use DateTime; use Yasumi\Exception\InvalidDateException; use Yasumi\Exception\UnknownLocaleException; use Yasumi\Holiday; @@ -100,7 +99,7 @@ private function calculateStJohnsDay(): void $this->addHoliday(new Holiday( 'stJohnsDay', [], - new DateTime($stJohnsDay, DateTimeZoneFactory::getDateTimeZone($this->timezone)), + new \DateTime($stJohnsDay, DateTimeZoneFactory::getDateTimeZone($this->timezone)), $this->locale )); } @@ -132,7 +131,7 @@ private function calculateAllSaintsDay(): void $this->addHoliday(new Holiday( 'allSaintsDay', [], - new DateTime("$this->year-10-31 this saturday", DateTimeZoneFactory::getDateTimeZone($this->timezone)), + new \DateTime("$this->year-10-31 this saturday", DateTimeZoneFactory::getDateTimeZone($this->timezone)), $this->locale )); } @@ -161,7 +160,7 @@ private function calculateIndependenceDay(): void $this->addHoliday(new Holiday( 'independenceDay', ['fi' => 'Itsenäisyyspäivä'], - new DateTime("$this->year-12-6", DateTimeZoneFactory::getDateTimeZone($this->timezone)), + new \DateTime("$this->year-12-6", DateTimeZoneFactory::getDateTimeZone($this->timezone)), $this->locale )); } diff --git a/src/Yasumi/Provider/France.php b/src/Yasumi/Provider/France.php index 291e70753..110d0a951 100644 --- a/src/Yasumi/Provider/France.php +++ b/src/Yasumi/Provider/France.php @@ -14,7 +14,6 @@ namespace Yasumi\Provider; -use DateTime; use Yasumi\Exception\InvalidDateException; use Yasumi\Exception\UnknownLocaleException; use Yasumi\Holiday; @@ -102,7 +101,7 @@ private function calculateBastilleDay(): void $this->addHoliday(new Holiday('bastilleDay', [ 'en' => 'Bastille Day', 'fr' => 'La Fête nationale', - ], new DateTime("$this->year-7-14", DateTimeZoneFactory::getDateTimeZone($this->timezone)), $this->locale)); + ], new \DateTime("$this->year-7-14", DateTimeZoneFactory::getDateTimeZone($this->timezone)), $this->locale)); } } diff --git a/src/Yasumi/Provider/Germany.php b/src/Yasumi/Provider/Germany.php index 0d49459ef..f5439239a 100644 --- a/src/Yasumi/Provider/Germany.php +++ b/src/Yasumi/Provider/Germany.php @@ -15,7 +15,6 @@ namespace Yasumi\Provider; -use DateTime; use Yasumi\Exception\InvalidDateException; use Yasumi\Exception\UnknownLocaleException; use Yasumi\Holiday; @@ -100,7 +99,7 @@ private function calculateGermanUnityDay(): void $this->addHoliday(new Holiday( 'germanUnityDay', ['de' => 'Tag der Deutschen Einheit'], - new DateTime($this->year.'-10-3', new \DateTimeZone($this->timezone)), + new \DateTime($this->year.'-10-3', new \DateTimeZone($this->timezone)), $this->locale )); } diff --git a/src/Yasumi/Provider/Germany/Berlin.php b/src/Yasumi/Provider/Germany/Berlin.php index 5d77e3420..701d7dc14 100644 --- a/src/Yasumi/Provider/Germany/Berlin.php +++ b/src/Yasumi/Provider/Germany/Berlin.php @@ -14,7 +14,6 @@ namespace Yasumi\Provider\Germany; -use DateTime; use Yasumi\Exception\InvalidDateException; use Yasumi\Exception\UnknownLocaleException; use Yasumi\Holiday; @@ -86,7 +85,7 @@ private function dayOfLiberation( return new Holiday( 'dayOfLiberation', [], - new DateTime('2020-05-08', DateTimeZoneFactory::getDateTimeZone($timezone)), + new \DateTime('2020-05-08', DateTimeZoneFactory::getDateTimeZone($timezone)), $locale, $type ); diff --git a/src/Yasumi/Provider/Germany/Saxony.php b/src/Yasumi/Provider/Germany/Saxony.php index 83b4579cd..7052a7def 100644 --- a/src/Yasumi/Provider/Germany/Saxony.php +++ b/src/Yasumi/Provider/Germany/Saxony.php @@ -14,7 +14,6 @@ namespace Yasumi\Provider\Germany; -use DateTime; use Yasumi\Exception\InvalidDateException; use Yasumi\Exception\UnknownLocaleException; use Yasumi\Holiday; @@ -96,7 +95,7 @@ private function calculateRepentanceAndPrayerDay(): void $this->addHoliday(new Holiday( 'repentanceAndPrayerDay', ['de' => 'Buß- und Bettag'], - new DateTime("next wednesday $this->year-11-15", DateTimeZoneFactory::getDateTimeZone($this->timezone)), + new \DateTime("next wednesday $this->year-11-15", DateTimeZoneFactory::getDateTimeZone($this->timezone)), $this->locale, Holiday::TYPE_OFFICIAL )); diff --git a/src/Yasumi/Provider/Greece.php b/src/Yasumi/Provider/Greece.php index 7cbdfe886..caf39f7fb 100644 --- a/src/Yasumi/Provider/Greece.php +++ b/src/Yasumi/Provider/Greece.php @@ -14,8 +14,6 @@ namespace Yasumi\Provider; -use DateInterval; -use DateTime; use Yasumi\Exception\InvalidDateException; use Yasumi\Exception\UnknownLocaleException; use Yasumi\Holiday; @@ -96,7 +94,7 @@ private function calculateThreeHolyHierarchs(): void $this->addHoliday(new Holiday( 'threeHolyHierarchs', ['el' => 'Τριών Ιεραρχών'], - new DateTime("$this->year-1-30", DateTimeZoneFactory::getDateTimeZone($this->timezone)), + new \DateTime("$this->year-1-30", DateTimeZoneFactory::getDateTimeZone($this->timezone)), $this->locale, Holiday::TYPE_OTHER )); @@ -121,7 +119,7 @@ private function calculateCleanMonday(): void $this->addHoliday(new Holiday( 'cleanMonday', ['el' => 'Καθαρά Δευτέρα'], - $this->calculateEaster($this->year, $this->timezone)->sub(new DateInterval('P48D')), + $this->calculateEaster($this->year, $this->timezone)->sub(new \DateInterval('P48D')), $this->locale )); } @@ -156,7 +154,7 @@ private function calculateIndependenceDay(): void $this->addHoliday(new Holiday( 'independenceDay', ['el' => 'Εικοστή Πέμπτη Μαρτίου'], - new DateTime("$this->year-3-25", DateTimeZoneFactory::getDateTimeZone($this->timezone)), + new \DateTime("$this->year-3-25", DateTimeZoneFactory::getDateTimeZone($this->timezone)), $this->locale )); } @@ -180,7 +178,7 @@ private function calculateOhiDay(): void $this->addHoliday(new Holiday( 'ohiDay', ['el' => 'Επέτειος του Όχι'], - new DateTime("$this->year-10-28", DateTimeZoneFactory::getDateTimeZone($this->timezone)), + new \DateTime("$this->year-10-28", DateTimeZoneFactory::getDateTimeZone($this->timezone)), $this->locale )); } @@ -204,7 +202,7 @@ private function calculatePolytechnio(): void $this->addHoliday(new Holiday( 'polytechnio', ['el' => 'Πολυτεχνείο'], - new DateTime("$this->year-11-17", DateTimeZoneFactory::getDateTimeZone($this->timezone)), + new \DateTime("$this->year-11-17", DateTimeZoneFactory::getDateTimeZone($this->timezone)), $this->locale, Holiday::TYPE_OTHER )); diff --git a/src/Yasumi/Provider/Hungary.php b/src/Yasumi/Provider/Hungary.php index a5f7c7bf5..47da42879 100644 --- a/src/Yasumi/Provider/Hungary.php +++ b/src/Yasumi/Provider/Hungary.php @@ -14,7 +14,6 @@ namespace Yasumi\Provider; -use DateTime; use Yasumi\Exception\InvalidDateException; use Yasumi\Exception\UnknownLocaleException; use Yasumi\Holiday; @@ -70,7 +69,7 @@ public function initialize(): void $this->addHoliday(new Holiday('memorialDay1848', [ 'en' => 'Memorial day of the 1848 Revolution', 'hu' => 'Az 1848-as forradalom ünnepe', - ], new DateTime("$this->year-3-15", DateTimeZoneFactory::getDateTimeZone($this->timezone)), $this->locale)); + ], new \DateTime("$this->year-3-15", DateTimeZoneFactory::getDateTimeZone($this->timezone)), $this->locale)); } /* @@ -80,7 +79,7 @@ public function initialize(): void $this->addHoliday(new Holiday('stateFoundation', [ 'en' => 'State Foundation Day', 'hu' => 'Az államalapítás ünnepe', - ], new DateTime("$this->year-8-20", DateTimeZoneFactory::getDateTimeZone($this->timezone)), $this->locale)); + ], new \DateTime("$this->year-8-20", DateTimeZoneFactory::getDateTimeZone($this->timezone)), $this->locale)); } /* @@ -90,7 +89,7 @@ public function initialize(): void $this->addHoliday(new Holiday('memorialDay1956', [ 'en' => 'Memorial day of the 1956 Revolution', 'hu' => 'Az 1956-os forradalom ünnepe', - ], new DateTime("$this->year-10-23", DateTimeZoneFactory::getDateTimeZone($this->timezone)), $this->locale)); + ], new \DateTime("$this->year-10-23", DateTimeZoneFactory::getDateTimeZone($this->timezone)), $this->locale)); } } diff --git a/src/Yasumi/Provider/Ireland.php b/src/Yasumi/Provider/Ireland.php index 6a6f0e756..6dc2ff61d 100644 --- a/src/Yasumi/Provider/Ireland.php +++ b/src/Yasumi/Provider/Ireland.php @@ -15,7 +15,6 @@ namespace Yasumi\Provider; -use DateTime; use Yasumi\Exception\InvalidDateException; use Yasumi\Exception\UnknownLocaleException; use Yasumi\Holiday; @@ -71,7 +70,7 @@ public function initialize(): void $this->addHoliday(new Holiday( 'augustHoliday', ['en' => 'August Holiday', 'ga' => 'Lá Saoire i mí Lúnasa'], - new DateTime("next monday $this->year-7-31", DateTimeZoneFactory::getDateTimeZone($this->timezone)), + new \DateTime("next monday $this->year-7-31", DateTimeZoneFactory::getDateTimeZone($this->timezone)), $this->locale )); $this->calculateOctoberHoliday(); @@ -167,7 +166,7 @@ private function calculateChristmasDay(): void $holiday = new Holiday( 'christmasDay', ['en' => 'Christmas Day', 'ga' => 'Lá Nollag'], - new DateTime($this->year.'-12-25', DateTimeZoneFactory::getDateTimeZone($this->timezone)), + new \DateTime($this->year.'-12-25', DateTimeZoneFactory::getDateTimeZone($this->timezone)), $this->locale ); @@ -207,7 +206,7 @@ private function calculateStStephensDay(): void $holiday = new Holiday( 'stStephensDay', [], - new DateTime($this->year.'-12-26', DateTimeZoneFactory::getDateTimeZone($this->timezone)), + new \DateTime($this->year.'-12-26', DateTimeZoneFactory::getDateTimeZone($this->timezone)), $this->locale ); @@ -252,7 +251,7 @@ private function calculateStPatricksDay(): void $holiday = new Holiday( 'stPatricksDay', ['en' => 'St. Patrick’s Day', 'ga' => 'Lá Fhéile Pádraig'], - new DateTime($this->year.'-3-17', DateTimeZoneFactory::getDateTimeZone($this->timezone)), + new \DateTime($this->year.'-3-17', DateTimeZoneFactory::getDateTimeZone($this->timezone)), $this->locale ); @@ -298,7 +297,7 @@ private function calculateMayDay(): void $this->addHoliday(new Holiday( 'mayDay', ['en' => 'May Day', 'ga' => 'Lá Bealtaine'], - new DateTime("next monday $this->year-4-30", DateTimeZoneFactory::getDateTimeZone($this->timezone)), + new \DateTime("next monday $this->year-4-30", DateTimeZoneFactory::getDateTimeZone($this->timezone)), $this->locale )); } @@ -326,7 +325,7 @@ private function calculateJuneHoliday(): void $this->addHoliday(new Holiday( 'juneHoliday', ['en' => 'June Holiday', 'ga' => 'Lá Saoire i mí an Mheithimh'], - new DateTime("next monday $this->year-5-31", DateTimeZoneFactory::getDateTimeZone($this->timezone)), + new \DateTime("next monday $this->year-5-31", DateTimeZoneFactory::getDateTimeZone($this->timezone)), $this->locale )); } @@ -353,7 +352,7 @@ private function calculateOctoberHoliday(): void $this->addHoliday(new Holiday( 'octoberHoliday', ['en' => 'October Holiday', 'ga' => 'Lá Saoire i mí Dheireadh Fómhair'], - new DateTime("previous monday $this->year-11-01", DateTimeZoneFactory::getDateTimeZone($this->timezone)), + new \DateTime("previous monday $this->year-11-01", DateTimeZoneFactory::getDateTimeZone($this->timezone)), $this->locale )); } diff --git a/src/Yasumi/Provider/Italy.php b/src/Yasumi/Provider/Italy.php index 1308f959e..879506450 100644 --- a/src/Yasumi/Provider/Italy.php +++ b/src/Yasumi/Provider/Italy.php @@ -14,7 +14,6 @@ namespace Yasumi\Provider; -use DateTime; use Yasumi\Exception\InvalidDateException; use Yasumi\Exception\UnknownLocaleException; use Yasumi\Holiday; @@ -95,7 +94,7 @@ private function calculateLiberationDay(): void $this->addHoliday(new Holiday( 'liberationDay', ['it' => 'Festa della Liberazione'], - new DateTime("$this->year-4-25", DateTimeZoneFactory::getDateTimeZone($this->timezone)), + new \DateTime("$this->year-4-25", DateTimeZoneFactory::getDateTimeZone($this->timezone)), $this->locale )); } @@ -123,7 +122,7 @@ private function calculateRepublicDay(): void $this->addHoliday(new Holiday( 'republicDay', ['it' => 'Festa della Repubblica'], - new DateTime("$this->year-6-2", DateTimeZoneFactory::getDateTimeZone($this->timezone)), + new \DateTime("$this->year-6-2", DateTimeZoneFactory::getDateTimeZone($this->timezone)), $this->locale )); } diff --git a/src/Yasumi/Provider/Japan.php b/src/Yasumi/Provider/Japan.php index 26cbc702d..1261a073f 100644 --- a/src/Yasumi/Provider/Japan.php +++ b/src/Yasumi/Provider/Japan.php @@ -15,9 +15,6 @@ namespace Yasumi\Provider; -use DateInterval; -use DateTime; -use DateTimeInterface; use Yasumi\Exception\InvalidDateException; use Yasumi\Exception\UnknownLocaleException; use Yasumi\Holiday; @@ -132,7 +129,7 @@ private function calculateNationalFoundationDay(): void 'en' => 'National Foundation Day', 'ja' => '建国記念の日', ], - new DateTime("$this->year-2-11", DateTimeZoneFactory::getDateTimeZone($this->timezone)), + new \DateTime("$this->year-2-11", DateTimeZoneFactory::getDateTimeZone($this->timezone)), $this->locale )); } @@ -152,7 +149,7 @@ private function calculateShowaDay(): void 'en' => 'Showa Day', 'ja' => '昭和の日', ], - new DateTime("$this->year-4-29", DateTimeZoneFactory::getDateTimeZone($this->timezone)), + new \DateTime("$this->year-4-29", DateTimeZoneFactory::getDateTimeZone($this->timezone)), $this->locale )); } @@ -172,7 +169,7 @@ private function calculateConstitutionMemorialDay(): void 'en' => 'Constitution Memorial Day', 'ja' => '憲法記念日', ], - new DateTime("$this->year-5-3", DateTimeZoneFactory::getDateTimeZone($this->timezone)), + new \DateTime("$this->year-5-3", DateTimeZoneFactory::getDateTimeZone($this->timezone)), $this->locale )); } @@ -192,7 +189,7 @@ private function calculateChildrensDay(): void 'en' => 'Children’s Day', 'ja' => 'こどもの日', ], - new DateTime("$this->year-5-5", DateTimeZoneFactory::getDateTimeZone($this->timezone)), + new \DateTime("$this->year-5-5", DateTimeZoneFactory::getDateTimeZone($this->timezone)), $this->locale )); } @@ -209,7 +206,7 @@ private function calculateCultureDay(): void $this->addHoliday(new Holiday( 'cultureDay', ['en' => 'Culture Day', 'ja' => '文化の日'], - new DateTime("$this->year-11-3", DateTimeZoneFactory::getDateTimeZone($this->timezone)), + new \DateTime("$this->year-11-3", DateTimeZoneFactory::getDateTimeZone($this->timezone)), $this->locale )); } @@ -226,7 +223,7 @@ private function calculateLaborThanksgivingDay(): void $this->addHoliday(new Holiday( 'laborThanksgivingDay', ['en' => 'Labor Thanksgiving Day', 'ja' => '勤労感謝の日'], - new DateTime("$this->year-11-23", DateTimeZoneFactory::getDateTimeZone($this->timezone)), + new \DateTime("$this->year-11-23", DateTimeZoneFactory::getDateTimeZone($this->timezone)), $this->locale )); } @@ -255,7 +252,7 @@ private function calculateEmperorsBirthday(): void $this->addHoliday(new Holiday( 'emperorsBirthday', ['en' => 'Emperors Birthday', 'ja' => '天皇誕生日'], - new DateTime($emperorsBirthday, DateTimeZoneFactory::getDateTimeZone($this->timezone)), + new \DateTime($emperorsBirthday, DateTimeZoneFactory::getDateTimeZone($this->timezone)), $this->locale )); } @@ -294,7 +291,7 @@ private function calculateVernalEquinoxDay(): void $this->addHoliday(new Holiday( 'vernalEquinoxDay', ['en' => 'Vernal Equinox Day', 'ja' => '春分の日'], - new DateTime("$this->year-3-$day", DateTimeZoneFactory::getDateTimeZone($this->timezone)), + new \DateTime("$this->year-3-$day", DateTimeZoneFactory::getDateTimeZone($this->timezone)), $this->locale )); } @@ -316,12 +313,12 @@ private function calculateComingOfAgeDay(): void { $date = null; if ($this->year >= 2000) { - $date = new DateTime("second monday of january $this->year", DateTimeZoneFactory::getDateTimeZone($this->timezone)); + $date = new \DateTime("second monday of january $this->year", DateTimeZoneFactory::getDateTimeZone($this->timezone)); } elseif ($this->year >= 1948) { - $date = new DateTime("$this->year-1-15", DateTimeZoneFactory::getDateTimeZone($this->timezone)); + $date = new \DateTime("$this->year-1-15", DateTimeZoneFactory::getDateTimeZone($this->timezone)); } - if ($date instanceof DateTimeInterface) { + if ($date instanceof \DateTimeInterface) { $this->addHoliday(new Holiday( 'comingOfAgeDay', ['en' => 'Coming of Age Day', 'ja' => '成人の日'], @@ -346,12 +343,12 @@ private function calculateGreeneryDay(): void { $date = null; if ($this->year >= 2007) { - $date = new DateTime("$this->year-5-4", DateTimeZoneFactory::getDateTimeZone($this->timezone)); + $date = new \DateTime("$this->year-5-4", DateTimeZoneFactory::getDateTimeZone($this->timezone)); } elseif ($this->year >= 1989) { - $date = new DateTime("$this->year-4-29", DateTimeZoneFactory::getDateTimeZone($this->timezone)); + $date = new \DateTime("$this->year-4-29", DateTimeZoneFactory::getDateTimeZone($this->timezone)); } - if ($date instanceof DateTimeInterface) { + if ($date instanceof \DateTimeInterface) { $this->addHoliday(new Holiday( 'greeneryDay', ['en' => 'Greenery Day', 'ja' => 'みどりの日'], @@ -379,14 +376,14 @@ private function calculateMarineDay(): void $date = null; if (2021 === $this->year) { // For Olympic 2021 Tokyo (rescheduled due to the COVID-19 pandemic) - $date = new DateTime("$this->year-7-22", DateTimeZoneFactory::getDateTimeZone($this->timezone)); + $date = new \DateTime("$this->year-7-22", DateTimeZoneFactory::getDateTimeZone($this->timezone)); } elseif ($this->year >= 2003) { - $date = new DateTime("third monday of july $this->year", DateTimeZoneFactory::getDateTimeZone($this->timezone)); + $date = new \DateTime("third monday of july $this->year", DateTimeZoneFactory::getDateTimeZone($this->timezone)); } elseif ($this->year >= 1996) { - $date = new DateTime("$this->year-7-20", DateTimeZoneFactory::getDateTimeZone($this->timezone)); + $date = new \DateTime("$this->year-7-20", DateTimeZoneFactory::getDateTimeZone($this->timezone)); } - if ($date instanceof DateTimeInterface) { + if ($date instanceof \DateTimeInterface) { $this->addHoliday(new Holiday( 'marineDay', ['en' => 'Marine Day', 'ja' => '海の日'], @@ -411,15 +408,15 @@ private function calculateMountainDay(): void $date = null; if (2021 === $this->year) { // For Olympic 2021 Tokyo (after COVID-19) - $date = new DateTime("$this->year-8-8", DateTimeZoneFactory::getDateTimeZone($this->timezone)); + $date = new \DateTime("$this->year-8-8", DateTimeZoneFactory::getDateTimeZone($this->timezone)); } elseif (2020 === $this->year) { // For Olympic 2020 Tokyo - $date = new DateTime("$this->year-8-10", DateTimeZoneFactory::getDateTimeZone($this->timezone)); + $date = new \DateTime("$this->year-8-10", DateTimeZoneFactory::getDateTimeZone($this->timezone)); } elseif ($this->year >= 2016) { - $date = new DateTime("$this->year-8-11", DateTimeZoneFactory::getDateTimeZone($this->timezone)); + $date = new \DateTime("$this->year-8-11", DateTimeZoneFactory::getDateTimeZone($this->timezone)); } - if ($date instanceof DateTimeInterface) { + if ($date instanceof \DateTimeInterface) { $this->addHoliday(new Holiday( 'mountainDay', ['en' => 'Mountain Day', 'ja' => '山の日'], @@ -445,12 +442,12 @@ private function calculateRespectForTheAgeDay(): void { $date = null; if ($this->year >= 2003) { - $date = new DateTime("third monday of september $this->year", DateTimeZoneFactory::getDateTimeZone($this->timezone)); + $date = new \DateTime("third monday of september $this->year", DateTimeZoneFactory::getDateTimeZone($this->timezone)); } elseif ($this->year >= 1996) { - $date = new DateTime("$this->year-9-15", DateTimeZoneFactory::getDateTimeZone($this->timezone)); + $date = new \DateTime("$this->year-9-15", DateTimeZoneFactory::getDateTimeZone($this->timezone)); } - if ($date instanceof DateTimeInterface) { + if ($date instanceof \DateTimeInterface) { $this->addHoliday(new Holiday( 'respectfortheAgedDay', ['en' => 'Respect for the Aged Day', 'ja' => '敬老の日'], @@ -478,14 +475,14 @@ private function calculateSportsDay(): void $date = null; if (2021 === $this->year) { // For Olympic 2021 Tokyo (after COVID-19) - $date = new DateTime("$this->year-7-23", DateTimeZoneFactory::getDateTimeZone($this->timezone)); + $date = new \DateTime("$this->year-7-23", DateTimeZoneFactory::getDateTimeZone($this->timezone)); } elseif (2020 === $this->year) { // For Olympic 2020 Tokyo - $date = new DateTime("$this->year-7-24", DateTimeZoneFactory::getDateTimeZone($this->timezone)); + $date = new \DateTime("$this->year-7-24", DateTimeZoneFactory::getDateTimeZone($this->timezone)); } elseif ($this->year >= 2000) { - $date = new DateTime("second monday of october $this->year", DateTimeZoneFactory::getDateTimeZone($this->timezone)); + $date = new \DateTime("second monday of october $this->year", DateTimeZoneFactory::getDateTimeZone($this->timezone)); } elseif ($this->year >= 1996) { - $date = new DateTime("$this->year-10-10", DateTimeZoneFactory::getDateTimeZone($this->timezone)); + $date = new \DateTime("$this->year-10-10", DateTimeZoneFactory::getDateTimeZone($this->timezone)); } $holidayName = ['en' => 'Health And Sports Day', 'ja' => '体育の日']; @@ -493,7 +490,7 @@ private function calculateSportsDay(): void $holidayName = ['en' => 'Sports Day', 'ja' => 'スポーツの日']; } - if ($date instanceof DateTimeInterface) { + if ($date instanceof \DateTimeInterface) { $this->addHoliday(new Holiday( 'sportsDay', $holidayName, @@ -536,7 +533,7 @@ private function calculateAutumnalEquinoxDay(): void $this->addHoliday(new Holiday( 'autumnalEquinoxDay', ['en' => 'Autumnal Equinox Day', 'ja' => '秋分の日'], - new DateTime("$this->year-9-$day", DateTimeZoneFactory::getDateTimeZone($this->timezone)), + new \DateTime("$this->year-9-$day", DateTimeZoneFactory::getDateTimeZone($this->timezone)), $this->locale )); } @@ -567,10 +564,10 @@ private function calculateSubstituteHolidays(): void if ($this->year >= 2007) { // Find next week day (not being another holiday) while (\in_array($date, $dates, false)) { - $date->add(new DateInterval('P1D')); + $date->add(new \DateInterval('P1D')); } } elseif ($holiday >= '1973-04-12') { - $date->add(new DateInterval('P1D')); + $date->add(new \DateInterval('P1D')); if (\in_array($date, $dates, false)) { continue; // @codeCoverageIgnore } @@ -603,7 +600,7 @@ private function calculateCoronationDay(): void $this->addHoliday(new Holiday( 'coronationDay', ['en' => 'Coronation Day', 'ja' => '即位の日'], - new DateTime("$this->year-5-1", DateTimeZoneFactory::getDateTimeZone($this->timezone)), + new \DateTime("$this->year-5-1", DateTimeZoneFactory::getDateTimeZone($this->timezone)), $this->locale )); } @@ -621,7 +618,7 @@ private function calculateEnthronementProclamationCeremony(): void $this->addHoliday(new Holiday( 'enthronementProclamationCeremony', ['en' => 'Enthronement Proclamation Ceremony', 'ja' => '即位礼正殿の儀'], - new DateTime("$this->year-10-22", DateTimeZoneFactory::getDateTimeZone($this->timezone)), + new \DateTime("$this->year-10-22", DateTimeZoneFactory::getDateTimeZone($this->timezone)), $this->locale )); } @@ -656,7 +653,7 @@ private function calculateBridgeHolidays(): void // Determine if gap between holidays is one day and create bridge holiday if (2 === (int) $previous->diff($datesIterator->current())->format('%a')) { $bridgeDate = clone $previous; - $bridgeDate->add(new DateInterval('P1D')); + $bridgeDate->add(new \DateInterval('P1D')); $this->addHoliday(new Holiday('bridgeDay'.$counter, [ 'en' => 'Bridge Public holiday', diff --git a/src/Yasumi/Provider/Luxembourg.php b/src/Yasumi/Provider/Luxembourg.php index 0783eb388..9b3faaee7 100644 --- a/src/Yasumi/Provider/Luxembourg.php +++ b/src/Yasumi/Provider/Luxembourg.php @@ -14,7 +14,6 @@ namespace Yasumi\Provider; -use DateTime; use Yasumi\Exception\InvalidDateException; use Yasumi\Exception\UnknownLocaleException; use Yasumi\Holiday; @@ -91,7 +90,7 @@ private function calculateEuropeDay(): void $this->addHoliday(new Holiday('europeDay', [ 'en_US' => 'Europe day', 'fr' => 'La Journée de l’Europe', - ], new DateTime("$this->year-5-9", DateTimeZoneFactory::getDateTimeZone($this->timezone)), $this->locale)); + ], new \DateTime("$this->year-5-9", DateTimeZoneFactory::getDateTimeZone($this->timezone)), $this->locale)); } } @@ -116,6 +115,6 @@ private function calculateNationalDay(): void $this->addHoliday(new Holiday('nationalDay', [ 'en_US' => 'National day', 'fr' => 'La Fête nationale', - ], new DateTime("$this->year-6-23", DateTimeZoneFactory::getDateTimeZone($this->timezone)), $this->locale)); + ], new \DateTime("$this->year-6-23", DateTimeZoneFactory::getDateTimeZone($this->timezone)), $this->locale)); } } diff --git a/src/Yasumi/Provider/Netherlands.php b/src/Yasumi/Provider/Netherlands.php index ff95d4796..94026e978 100644 --- a/src/Yasumi/Provider/Netherlands.php +++ b/src/Yasumi/Provider/Netherlands.php @@ -14,8 +14,6 @@ namespace Yasumi\Provider; -use DateInterval; -use DateTime; use Yasumi\Exception\InvalidDateException; use Yasumi\Exception\UnknownLocaleException; use Yasumi\Holiday; @@ -113,7 +111,7 @@ private function calculateCarnival(): void $this->addHoliday(new Holiday( 'carnivalDay', ['en' => 'Carnival', 'nl' => 'Carnaval'], - $carnivalDay1->sub(new DateInterval('P49D')), + $carnivalDay1->sub(new \DateInterval('P49D')), $this->locale, Holiday::TYPE_OBSERVANCE )); @@ -125,7 +123,7 @@ private function calculateCarnival(): void $this->addHoliday(new Holiday( 'secondCarnivalDay', ['en' => 'Carnival', 'nl' => 'Carnaval'], - $carnivalDay2->sub(new DateInterval('P48D')), + $carnivalDay2->sub(new \DateInterval('P48D')), $this->locale, Holiday::TYPE_OBSERVANCE )); @@ -137,7 +135,7 @@ private function calculateCarnival(): void $this->addHoliday(new Holiday( 'thirdCarnivalDay', ['en' => 'Carnival', 'nl' => 'Carnaval'], - $carnivalDay3->sub(new DateInterval('P47D')), + $carnivalDay3->sub(new \DateInterval('P47D')), $this->locale, Holiday::TYPE_OBSERVANCE )); @@ -197,7 +195,7 @@ private function calculateStNicholasDay(): void $this->addHoliday(new Holiday( 'stNicholasDay', ['en' => 'St. Nicholas’ Day', 'nl' => 'Sinterklaas'], - new DateTime("$this->year-12-5", DateTimeZoneFactory::getDateTimeZone($this->timezone)), + new \DateTime("$this->year-12-5", DateTimeZoneFactory::getDateTimeZone($this->timezone)), $this->locale, Holiday::TYPE_OBSERVANCE )); @@ -220,7 +218,7 @@ private function calculateHalloween(): void $this->addHoliday(new Holiday( 'halloween', ['en' => 'Halloween', 'nl' => 'Halloween'], - new DateTime("$this->year-10-31", DateTimeZoneFactory::getDateTimeZone($this->timezone)), + new \DateTime("$this->year-10-31", DateTimeZoneFactory::getDateTimeZone($this->timezone)), $this->locale, Holiday::TYPE_OBSERVANCE )); @@ -239,7 +237,7 @@ private function calculatePrincesDay(): void $this->addHoliday(new Holiday( 'princesDay', ['en' => 'Prince’s Day', 'nl' => 'Prinsjesdag'], - new DateTime("third tuesday of september $this->year", DateTimeZoneFactory::getDateTimeZone($this->timezone)), + new \DateTime("third tuesday of september $this->year", DateTimeZoneFactory::getDateTimeZone($this->timezone)), $this->locale, Holiday::TYPE_OTHER )); @@ -257,14 +255,14 @@ private function calculatePrincesDay(): void private function calculateQueensday(): void { if ($this->year >= 1891 && $this->year <= 2013) { - $date = new DateTime("$this->year-4-30", DateTimeZoneFactory::getDateTimeZone($this->timezone)); + $date = new \DateTime("$this->year-4-30", DateTimeZoneFactory::getDateTimeZone($this->timezone)); if ($this->year <= 1948) { - $date = new DateTime("$this->year-8-31", DateTimeZoneFactory::getDateTimeZone($this->timezone)); + $date = new \DateTime("$this->year-8-31", DateTimeZoneFactory::getDateTimeZone($this->timezone)); } // Determine substitution day if (0 === (int) $date->format('w')) { - $this->year < 1980 ? $date->add(new DateInterval('P1D')) : $date->sub(new DateInterval('P1D')); + $this->year < 1980 ? $date->add(new \DateInterval('P1D')) : $date->sub(new \DateInterval('P1D')); } $this->addHoliday(new Holiday( @@ -287,10 +285,10 @@ private function calculateQueensday(): void private function calculateKingsday(): void { if ($this->year >= 2014) { - $date = new DateTime("$this->year-4-27", DateTimeZoneFactory::getDateTimeZone($this->timezone)); + $date = new \DateTime("$this->year-4-27", DateTimeZoneFactory::getDateTimeZone($this->timezone)); if (0 === (int) $date->format('w')) { - $date->sub(new DateInterval('P1D')); + $date->sub(new \DateInterval('P1D')); } $this->addHoliday(new Holiday( @@ -315,7 +313,7 @@ private function calculateCommemorationLiberationDay(): void $this->addHoliday(new Holiday( 'commemorationDay', ['en' => 'Commemoration Day', 'nl' => 'dodenherdenking'], - new DateTime("$this->year-5-4", DateTimeZoneFactory::getDateTimeZone($this->timezone)), + new \DateTime("$this->year-5-4", DateTimeZoneFactory::getDateTimeZone($this->timezone)), $this->locale, Holiday::TYPE_OBSERVANCE )); @@ -324,7 +322,7 @@ private function calculateCommemorationLiberationDay(): void $this->addHoliday(new Holiday( 'liberationDay', ['en' => 'Liberation Day', 'nl' => 'Bevrijdingsdag'], - new DateTime("$this->year-5-5", DateTimeZoneFactory::getDateTimeZone($this->timezone)), + new \DateTime("$this->year-5-5", DateTimeZoneFactory::getDateTimeZone($this->timezone)), $this->locale, $holidayType )); diff --git a/src/Yasumi/Provider/NewZealand.php b/src/Yasumi/Provider/NewZealand.php index c8be986c8..837f49a98 100644 --- a/src/Yasumi/Provider/NewZealand.php +++ b/src/Yasumi/Provider/NewZealand.php @@ -14,8 +14,6 @@ namespace Yasumi\Provider; -use DateInterval; -use DateTime; use Yasumi\Exception\InvalidDateException; use Yasumi\Exception\UnknownLocaleException; use Yasumi\Holiday; @@ -84,20 +82,20 @@ public function getSources(): array */ private function calculateNewYearHolidays(): void { - $newYearsDay = new DateTime("$this->year-01-01", DateTimeZoneFactory::getDateTimeZone($this->timezone)); - $dayAfterNewYearsDay = new DateTime("$this->year-01-02", DateTimeZoneFactory::getDateTimeZone($this->timezone)); + $newYearsDay = new \DateTime("$this->year-01-01", DateTimeZoneFactory::getDateTimeZone($this->timezone)); + $dayAfterNewYearsDay = new \DateTime("$this->year-01-02", DateTimeZoneFactory::getDateTimeZone($this->timezone)); switch ($newYearsDay->format('w')) { case 0: - $newYearsDay->add(new DateInterval('P1D')); - $dayAfterNewYearsDay->add(new DateInterval('P1D')); + $newYearsDay->add(new \DateInterval('P1D')); + $dayAfterNewYearsDay->add(new \DateInterval('P1D')); break; case 5: - $dayAfterNewYearsDay->add(new DateInterval('P2D')); + $dayAfterNewYearsDay->add(new \DateInterval('P2D')); break; case 6: - $newYearsDay->add(new DateInterval('P2D')); - $dayAfterNewYearsDay->add(new DateInterval('P2D')); + $newYearsDay->add(new \DateInterval('P2D')); + $dayAfterNewYearsDay->add(new \DateInterval('P2D')); break; } @@ -128,7 +126,7 @@ private function calculateWaitangiDay(): void return; } - $date = new DateTime("$this->year-02-6", DateTimeZoneFactory::getDateTimeZone($this->timezone)); + $date = new \DateTime("$this->year-02-6", DateTimeZoneFactory::getDateTimeZone($this->timezone)); if ($this->year >= 2015 && !$this->isWorkingDay($date)) { $date->modify('next monday'); @@ -158,7 +156,7 @@ private function calculateAnzacDay(): void return; } - $date = new DateTime("$this->year-04-25", DateTimeZoneFactory::getDateTimeZone($this->timezone)); + $date = new \DateTime("$this->year-04-25", DateTimeZoneFactory::getDateTimeZone($this->timezone)); if ($this->year >= 2015 && !$this->isWorkingDay($date)) { $date->modify('next monday'); @@ -194,7 +192,7 @@ private function calculateQueensBirthday(): void $this->addHoliday(new Holiday( 'queensBirthday', [], - new DateTime("first monday of june $this->year", DateTimeZoneFactory::getDateTimeZone($this->timezone)), + new \DateTime("first monday of june $this->year", DateTimeZoneFactory::getDateTimeZone($this->timezone)), $this->locale )); } @@ -224,7 +222,7 @@ private function calculateLabourDay(): void return; } - $date = new DateTime( + $date = new \DateTime( ($this->year < 1910 ? 'second wednesday of october' : 'fourth monday of october')." $this->year", DateTimeZoneFactory::getDateTimeZone($this->timezone) ); @@ -249,19 +247,19 @@ private function calculateLabourDay(): void */ private function calculateChristmasHolidays(): void { - $christmasDay = new DateTime("$this->year-12-25", DateTimeZoneFactory::getDateTimeZone($this->timezone)); - $boxingDay = new DateTime("$this->year-12-26", DateTimeZoneFactory::getDateTimeZone($this->timezone)); + $christmasDay = new \DateTime("$this->year-12-25", DateTimeZoneFactory::getDateTimeZone($this->timezone)); + $boxingDay = new \DateTime("$this->year-12-26", DateTimeZoneFactory::getDateTimeZone($this->timezone)); switch ($christmasDay->format('w')) { case 0: - $christmasDay->add(new DateInterval('P2D')); + $christmasDay->add(new \DateInterval('P2D')); break; case 5: - $boxingDay->add(new DateInterval('P2D')); + $boxingDay->add(new \DateInterval('P2D')); break; case 6: - $christmasDay->add(new DateInterval('P2D')); - $boxingDay->add(new DateInterval('P2D')); + $christmasDay->add(new \DateInterval('P2D')); + $boxingDay->add(new \DateInterval('P2D')); break; } diff --git a/src/Yasumi/Provider/Norway.php b/src/Yasumi/Provider/Norway.php index f9c9a1bca..d0adf205e 100644 --- a/src/Yasumi/Provider/Norway.php +++ b/src/Yasumi/Provider/Norway.php @@ -14,7 +14,6 @@ namespace Yasumi\Provider; -use DateTime; use Yasumi\Exception\InvalidDateException; use Yasumi\Exception\UnknownLocaleException; use Yasumi\Holiday; @@ -96,7 +95,7 @@ private function calculateConstitutionDay(): void $this->addHoliday(new Holiday( 'constitutionDay', ['nb' => 'grunnlovsdagen'], - new DateTime("$this->year-5-17", DateTimeZoneFactory::getDateTimeZone($this->timezone)), + new \DateTime("$this->year-5-17", DateTimeZoneFactory::getDateTimeZone($this->timezone)), $this->locale )); } diff --git a/src/Yasumi/Provider/Poland.php b/src/Yasumi/Provider/Poland.php index b0fbdfa9e..d4872f81a 100644 --- a/src/Yasumi/Provider/Poland.php +++ b/src/Yasumi/Provider/Poland.php @@ -14,7 +14,6 @@ namespace Yasumi\Provider; -use DateTime; use Yasumi\Exception\InvalidDateException; use Yasumi\Exception\UnknownLocaleException; use Yasumi\Holiday; @@ -97,7 +96,7 @@ private function calculateIndependenceDay(): void $this->addHoliday(new Holiday('independenceDay', [ 'en' => 'Independence Day', 'pl' => 'Narodowe Święto Niepodległości', - ], new DateTime("$this->year-11-11", DateTimeZoneFactory::getDateTimeZone($this->timezone)), $this->locale)); + ], new \DateTime("$this->year-11-11", DateTimeZoneFactory::getDateTimeZone($this->timezone)), $this->locale)); } /** @@ -124,6 +123,6 @@ private function calculateConstitutionDay(): void $this->addHoliday(new Holiday('constitutionDay', [ 'en' => 'Constitution Day', 'pl' => 'Święto Narodowe Trzeciego Maja', - ], new DateTime("$this->year-5-3", DateTimeZoneFactory::getDateTimeZone($this->timezone)), $this->locale)); + ], new \DateTime("$this->year-5-3", DateTimeZoneFactory::getDateTimeZone($this->timezone)), $this->locale)); } } diff --git a/src/Yasumi/Provider/Portugal.php b/src/Yasumi/Provider/Portugal.php index 41e508e29..acff2e1a7 100644 --- a/src/Yasumi/Provider/Portugal.php +++ b/src/Yasumi/Provider/Portugal.php @@ -14,7 +14,6 @@ namespace Yasumi\Provider; -use DateTime; use Yasumi\Exception\InvalidDateException; use Yasumi\Exception\UnknownLocaleException; use Yasumi\Holiday; @@ -95,7 +94,7 @@ private function calculateCarnationRevolutionDay(): void $this->addHoliday(new Holiday( '25thApril', ['pt' => 'Dia da Liberdade'], - new DateTime("$this->year-04-25", DateTimeZoneFactory::getDateTimeZone($this->timezone)), + new \DateTime("$this->year-04-25", DateTimeZoneFactory::getDateTimeZone($this->timezone)), $this->locale, Holiday::TYPE_OFFICIAL )); @@ -142,7 +141,7 @@ private function calculatePortugalDay(): void $this->addHoliday(new Holiday( 'portugalDay', ['pt' => 'Dia de Portugal'], - new DateTime("$this->year-06-10", DateTimeZoneFactory::getDateTimeZone($this->timezone)), + new \DateTime("$this->year-06-10", DateTimeZoneFactory::getDateTimeZone($this->timezone)), $this->locale )); } @@ -176,7 +175,7 @@ private function calculatePortugueseRepublicDay(): void $this->addHoliday(new Holiday( 'portugueseRepublic', ['pt' => 'Implantação da República Portuguesa'], - new DateTime("$this->year-10-05", DateTimeZoneFactory::getDateTimeZone($this->timezone)), + new \DateTime("$this->year-10-05", DateTimeZoneFactory::getDateTimeZone($this->timezone)), $this->locale )); } @@ -232,7 +231,7 @@ private function calculateRestorationOfIndependenceDay(): void $this->addHoliday(new Holiday( 'restorationOfIndependence', ['pt' => 'Restauração da Independência'], - new DateTime("$this->year-12-01", DateTimeZoneFactory::getDateTimeZone($this->timezone)), + new \DateTime("$this->year-12-01", DateTimeZoneFactory::getDateTimeZone($this->timezone)), $this->locale, Holiday::TYPE_OFFICIAL )); diff --git a/src/Yasumi/Provider/Romania.php b/src/Yasumi/Provider/Romania.php index 9f4ebb2f4..d4e1ef0ac 100644 --- a/src/Yasumi/Provider/Romania.php +++ b/src/Yasumi/Provider/Romania.php @@ -14,7 +14,6 @@ namespace Yasumi\Provider; -use DateTime; use Yasumi\Exception\InvalidDateException; use Yasumi\Exception\UnknownLocaleException; use Yasumi\Holiday; @@ -111,7 +110,7 @@ private function calculateDayAfterNewYearsDay(): void $this->addHoliday(new Holiday( 'dayAfterNewYearsDay', [], - new DateTime("$this->year-01-02", DateTimeZoneFactory::getDateTimeZone($this->timezone)), + new \DateTime("$this->year-01-02", DateTimeZoneFactory::getDateTimeZone($this->timezone)), $this->locale )); } @@ -137,7 +136,7 @@ private function calculateUnitedPrincipalitiesDay(): void $this->addHoliday(new Holiday('unitedPrincipalitiesDay', [ 'en' => 'Union Day / Small Union', 'ro' => 'Unirea Principatelor Române / Mica Unire', - ], new DateTime("$this->year-01-24", DateTimeZoneFactory::getDateTimeZone($this->timezone)), $this->locale)); + ], new \DateTime("$this->year-01-24", DateTimeZoneFactory::getDateTimeZone($this->timezone)), $this->locale)); } } @@ -159,7 +158,7 @@ private function calculateStAndrewDay(): void $this->addHoliday(new Holiday( 'stAndrewsDay', [], - new DateTime($this->year.'-11-30', DateTimeZoneFactory::getDateTimeZone($this->timezone)), + new \DateTime($this->year.'-11-30', DateTimeZoneFactory::getDateTimeZone($this->timezone)), $this->locale )); } @@ -202,7 +201,7 @@ private function calculateNationalDay(): void $this->addHoliday(new Holiday('nationalDay', [ 'en' => 'National Day', 'ro' => 'Ziua Națională', - ], new DateTime($nationalDay, DateTimeZoneFactory::getDateTimeZone($this->timezone)), $this->locale)); + ], new \DateTime($nationalDay, DateTimeZoneFactory::getDateTimeZone($this->timezone)), $this->locale)); } } @@ -227,7 +226,7 @@ private function calculateConstantinBrancusiDay(): void 'en' => 'Constantin Brâncuși day', 'ro' => 'Ziua Constantin Brâncuși', ], - new DateTime("$this->year-02-19", DateTimeZoneFactory::getDateTimeZone($this->timezone)), + new \DateTime("$this->year-02-19", DateTimeZoneFactory::getDateTimeZone($this->timezone)), $this->locale, Holiday::TYPE_OBSERVANCE )); @@ -257,7 +256,7 @@ private function calculateChildrensDay(): void 'en' => 'International Children’s Day', 'ro' => 'Ziua Copilului', ], - new DateTime("$this->year-06-01", DateTimeZoneFactory::getDateTimeZone($this->timezone)), + new \DateTime("$this->year-06-01", DateTimeZoneFactory::getDateTimeZone($this->timezone)), $this->locale, Holiday::TYPE_OBSERVANCE )); @@ -267,7 +266,7 @@ private function calculateChildrensDay(): void $this->addHoliday(new Holiday('childrensDay', [ 'en' => 'International Children’s Day', 'ro' => 'Ziua Copilului', - ], new DateTime("$this->year-06-01", DateTimeZoneFactory::getDateTimeZone($this->timezone)), $this->locale)); + ], new \DateTime("$this->year-06-01", DateTimeZoneFactory::getDateTimeZone($this->timezone)), $this->locale)); } } } diff --git a/src/Yasumi/Provider/Slovakia.php b/src/Yasumi/Provider/Slovakia.php index 2c5bc2f0e..f0f2d58c6 100644 --- a/src/Yasumi/Provider/Slovakia.php +++ b/src/Yasumi/Provider/Slovakia.php @@ -15,7 +15,6 @@ namespace Yasumi\Provider; -use DateTime; use Yasumi\Exception\InvalidDateException; use Yasumi\Exception\UnknownLocaleException; use Yasumi\Holiday; @@ -133,7 +132,7 @@ private function calculateSlovakIndependenceDay(): void 'sk' => 'Deň vzniku Slovenskej republiky', 'en' => 'Day of the Establishment of the Slovak Republic', ], - new DateTime($this->year.'-01-01', DateTimeZoneFactory::getDateTimeZone($this->timezone)), + new \DateTime($this->year.'-01-01', DateTimeZoneFactory::getDateTimeZone($this->timezone)), $this->locale )); } @@ -159,7 +158,7 @@ private function calculateSaintsCyrilAndMethodiusDay(): void 'cs' => 'Den slovanských věrozvěstů Cyrila a Metoděje', 'en' => 'Saints Cyril and Methodius Day', ], - new DateTime($this->year.'-07-05', DateTimeZoneFactory::getDateTimeZone($this->timezone)), + new \DateTime($this->year.'-07-05', DateTimeZoneFactory::getDateTimeZone($this->timezone)), $this->locale, Holiday::TYPE_OFFICIAL )); @@ -183,7 +182,7 @@ private function calculateSlovakNationalUprisingDay(): void 'sk' => 'Výročie Slovenského národného povstania', 'en' => 'Slovak National Uprising Day', ], - new DateTime($this->year.'-08-29', DateTimeZoneFactory::getDateTimeZone($this->timezone)), + new \DateTime($this->year.'-08-29', DateTimeZoneFactory::getDateTimeZone($this->timezone)), $this->locale, Holiday::TYPE_OFFICIAL )); @@ -207,7 +206,7 @@ private function calculateSlovakConstitutionDay(): void 'sk' => 'Deň Ústavy Slovenskej republiky', 'en' => 'Day of the Constitution of the Slovak Republic', ], - new DateTime($this->year.'-09-01', DateTimeZoneFactory::getDateTimeZone($this->timezone)), + new \DateTime($this->year.'-09-01', DateTimeZoneFactory::getDateTimeZone($this->timezone)), $this->locale, Holiday::TYPE_OFFICIAL )); @@ -232,7 +231,7 @@ private function calculateOurLadyOfSorrowsDay(): void $this->addHoliday(new Holiday('ourLadyOfSorrowsDay', [ 'sk' => 'Sviatok Sedembolestnej Panny Márie', 'en' => 'Our Lady of Sorrows Day', - ], new DateTime($this->year.'-09-15', DateTimeZoneFactory::getDateTimeZone($this->timezone)), $this->locale, Holiday::TYPE_BANK)); + ], new \DateTime($this->year.'-09-15', DateTimeZoneFactory::getDateTimeZone($this->timezone)), $this->locale, Holiday::TYPE_BANK)); } /** @@ -254,7 +253,7 @@ private function calculateStruggleForFreedomAndDemocracyDay(): void 'cs' => 'Den boje za svobodu a demokracii', 'en' => 'Struggle for Freedom and Democracy Day', ], - new DateTime($this->year.'-11-17', DateTimeZoneFactory::getDateTimeZone($this->timezone)), + new \DateTime($this->year.'-11-17', DateTimeZoneFactory::getDateTimeZone($this->timezone)), $this->locale, Holiday::TYPE_OFFICIAL )); diff --git a/src/Yasumi/Provider/SouthAfrica.php b/src/Yasumi/Provider/SouthAfrica.php index d22b8ed48..516ba572b 100644 --- a/src/Yasumi/Provider/SouthAfrica.php +++ b/src/Yasumi/Provider/SouthAfrica.php @@ -15,8 +15,6 @@ namespace Yasumi\Provider; -use DateInterval; -use DateTime; use Yasumi\Exception\InvalidDateException; use Yasumi\Exception\UnknownLocaleException; use Yasumi\Holiday; @@ -111,7 +109,7 @@ private function calculateHumanRightsDay(): void $this->addHoliday(new Holiday( 'humanRightsDay', ['en' => 'Human Rights Day'], - new DateTime($this->year.'-3-21', DateTimeZoneFactory::getDateTimeZone($this->timezone)), + new \DateTime($this->year.'-3-21', DateTimeZoneFactory::getDateTimeZone($this->timezone)), $this->locale )); } @@ -133,7 +131,7 @@ private function calculateFamilyDay(): void $this->addHoliday(new Holiday( 'familyDay', ['en' => 'Family Day'], - $this->calculateEaster($this->year, $this->timezone)->add(new DateInterval('P1D')), + $this->calculateEaster($this->year, $this->timezone)->add(new \DateInterval('P1D')), $this->locale )); } @@ -156,7 +154,7 @@ private function calculateFreedomDay(): void $this->addHoliday(new Holiday( 'freedomDay', ['en' => 'Freedom Day'], - new DateTime($this->year.'-4-27', DateTimeZoneFactory::getDateTimeZone($this->timezone)), + new \DateTime($this->year.'-4-27', DateTimeZoneFactory::getDateTimeZone($this->timezone)), $this->locale )); } @@ -183,7 +181,7 @@ private function calculateYouthDay(): void $this->addHoliday(new Holiday( 'youthDay', ['en' => 'Youth Day'], - new DateTime($this->year.'-6-16', DateTimeZoneFactory::getDateTimeZone($this->timezone)), + new \DateTime($this->year.'-6-16', DateTimeZoneFactory::getDateTimeZone($this->timezone)), $this->locale )); } @@ -210,7 +208,7 @@ private function calculate2016MunicipalElectionsDay(): void $this->addHoliday(new Holiday( '2016MunicipalElectionsDay', ['en' => '2016 Municipal Elections Day'], - new DateTime('2016-8-3', DateTimeZoneFactory::getDateTimeZone($this->timezone)), + new \DateTime('2016-8-3', DateTimeZoneFactory::getDateTimeZone($this->timezone)), $this->locale )); } @@ -235,7 +233,7 @@ private function calculateNationalWomensDay(): void $this->addHoliday(new Holiday( 'nationalWomensDay', ['en' => 'National Women’s Day'], - new DateTime($this->year.'-8-9', DateTimeZoneFactory::getDateTimeZone($this->timezone)), + new \DateTime($this->year.'-8-9', DateTimeZoneFactory::getDateTimeZone($this->timezone)), $this->locale )); } @@ -260,7 +258,7 @@ private function calculateHeritageDay(): void $this->addHoliday(new Holiday( 'heritageDay', ['en' => 'Heritage Day'], - new DateTime($this->year.'-9-24', DateTimeZoneFactory::getDateTimeZone($this->timezone)), + new \DateTime($this->year.'-9-24', DateTimeZoneFactory::getDateTimeZone($this->timezone)), $this->locale )); } @@ -287,7 +285,7 @@ private function calculateDayOfReconciliation(): void $this->addHoliday(new Holiday( 'reconciliationDay', ['en' => 'Day of Reconciliation'], - new DateTime($this->year.'-12-16', DateTimeZoneFactory::getDateTimeZone($this->timezone)), + new \DateTime($this->year.'-12-16', DateTimeZoneFactory::getDateTimeZone($this->timezone)), $this->locale )); } @@ -317,7 +315,7 @@ private function calculateSubstituteDayOfGoodwill(): void $this->addHoliday(new Holiday( 'substituteDayOfGoodwill', ['en' => 'Day of Goodwill observed'], - new DateTime('2016-12-27', DateTimeZoneFactory::getDateTimeZone($this->timezone)), + new \DateTime('2016-12-27', DateTimeZoneFactory::getDateTimeZone($this->timezone)), $this->locale )); } @@ -340,7 +338,7 @@ private function calculateSubstituteHolidays(): void // Substitute holiday is on a Monday in case the holiday falls on a Sunday if (0 === (int) $holiday->format('w')) { $date = clone $holiday; - $date->add(new DateInterval('P1D')); + $date->add(new \DateInterval('P1D')); $this->addHoliday(new SubstituteHoliday( $holiday, diff --git a/src/Yasumi/Provider/SouthKorea.php b/src/Yasumi/Provider/SouthKorea.php index 805d2e98e..7f8869763 100644 --- a/src/Yasumi/Provider/SouthKorea.php +++ b/src/Yasumi/Provider/SouthKorea.php @@ -15,8 +15,6 @@ namespace Yasumi\Provider; -use DateInterval; -use DateTime; use Yasumi\Exception\InvalidDateException; use Yasumi\Exception\UnknownLocaleException; use Yasumi\Holiday; @@ -177,7 +175,7 @@ private function calculateNewYearsDay(): void $this->addHoliday(new Holiday( 'dayAfterNewYearsDay', [], - new DateTime("$this->year-1-2", DateTimeZoneFactory::getDateTimeZone($this->timezone)), + new \DateTime("$this->year-1-2", DateTimeZoneFactory::getDateTimeZone($this->timezone)), $this->locale )); } @@ -185,7 +183,7 @@ private function calculateNewYearsDay(): void $this->addHoliday(new Holiday( 'twoDaysLaterNewYearsDay', ['en' => 'Two Days Later New Year’s Day', 'ko' => '새해 연휴'], - new DateTime("$this->year-1-3", DateTimeZoneFactory::getDateTimeZone($this->timezone)), + new \DateTime("$this->year-1-3", DateTimeZoneFactory::getDateTimeZone($this->timezone)), $this->locale )); } @@ -203,7 +201,7 @@ private function calculateNewYearsDay(): void private function calculateSeollal(): void { if ($this->year >= 1985 && isset(self::LUNAR_HOLIDAY['seollal'][$this->year])) { - $seollal = new DateTime(self::LUNAR_HOLIDAY['seollal'][$this->year], DateTimeZoneFactory::getDateTimeZone($this->timezone)); + $seollal = new \DateTime(self::LUNAR_HOLIDAY['seollal'][$this->year], DateTimeZoneFactory::getDateTimeZone($this->timezone)); $this->addHoliday(new Holiday( 'seollal', ['en' => 'Seollal', 'ko' => '설날'], @@ -212,7 +210,7 @@ private function calculateSeollal(): void )); if ($this->year > 1989) { $dayBeforeSeollal = clone $seollal; - $dayBeforeSeollal->sub(new DateInterval('P1D')); + $dayBeforeSeollal->sub(new \DateInterval('P1D')); $this->addHoliday(new Holiday( 'dayBeforeSeollal', ['en' => 'Day before Seollal', 'ko' => '설날 연휴'], @@ -220,7 +218,7 @@ private function calculateSeollal(): void $this->locale )); $dayAfterSeollal = clone $seollal; - $dayAfterSeollal->add(new DateInterval('P1D')); + $dayAfterSeollal->add(new \DateInterval('P1D')); $this->addHoliday(new Holiday( 'dayAfterSeollal', ['en' => 'Day after Seollal', 'ko' => '설날 연휴'], @@ -244,7 +242,7 @@ private function calculateBuddhasBirthday(): void $this->addHoliday(new Holiday( 'buddhasBirthday', ['en' => 'Buddha’s Birthday', 'ko' => '부처님오신날'], - new DateTime(self::LUNAR_HOLIDAY['buddhasBirthday'][$this->year], DateTimeZoneFactory::getDateTimeZone($this->timezone)), + new \DateTime(self::LUNAR_HOLIDAY['buddhasBirthday'][$this->year], DateTimeZoneFactory::getDateTimeZone($this->timezone)), $this->locale )); } @@ -267,7 +265,7 @@ private function calculateChuseok(): void $chuseok = new Holiday( 'chuseok', ['en' => 'Chuseok', 'ko' => '추석'], - new DateTime(self::LUNAR_HOLIDAY['chuseok'][$this->year], DateTimeZoneFactory::getDateTimeZone($this->timezone)), + new \DateTime(self::LUNAR_HOLIDAY['chuseok'][$this->year], DateTimeZoneFactory::getDateTimeZone($this->timezone)), $this->locale ); $this->addHoliday($chuseok); @@ -277,7 +275,7 @@ private function calculateChuseok(): void $this->addHoliday(new Holiday( 'dayAfterChuseok', ['en' => 'Day after Chuseok', 'ko' => '추석 연휴'], - (clone $chuseok)->add(new DateInterval('P1D')), + (clone $chuseok)->add(new \DateInterval('P1D')), $this->locale )); } @@ -287,7 +285,7 @@ private function calculateChuseok(): void $this->addHoliday(new Holiday( 'dayBeforeChuseok', ['en' => 'Day before Chuseok', 'ko' => '추석 연휴'], - (clone $chuseok)->sub(new DateInterval('P1D')), + (clone $chuseok)->sub(new \DateInterval('P1D')), $this->locale )); } @@ -307,7 +305,7 @@ private function calculateIndependenceMovementDay(): void $this->addHoliday(new Holiday( 'independenceMovementDay', ['en' => 'Independence Movement Day', 'ko' => '삼일절'], - new DateTime("$this->year-3-1", DateTimeZoneFactory::getDateTimeZone($this->timezone)), + new \DateTime("$this->year-3-1", DateTimeZoneFactory::getDateTimeZone($this->timezone)), $this->locale )); } @@ -326,7 +324,7 @@ private function calculateArborDay(): void $this->addHoliday(new Holiday( 'arborDay', ['en' => 'Arbor Day', 'ko' => '식목일'], - new DateTime("$this->year-4-5", DateTimeZoneFactory::getDateTimeZone($this->timezone)), + new \DateTime("$this->year-4-5", DateTimeZoneFactory::getDateTimeZone($this->timezone)), $this->locale )); } @@ -345,7 +343,7 @@ private function calculateChildrensDay(): void $this->addHoliday(new Holiday( 'childrensDay', ['en' => 'Children’s Day', 'ko' => '어린이날'], - new DateTime("$this->year-5-5", DateTimeZoneFactory::getDateTimeZone($this->timezone)), + new \DateTime("$this->year-5-5", DateTimeZoneFactory::getDateTimeZone($this->timezone)), $this->locale )); } @@ -364,7 +362,7 @@ private function calculateMemorialDay(): void $this->addHoliday(new Holiday( 'memorialDay', ['en' => 'Memorial Day', 'ko' => '현충일'], - new DateTime("$this->year-6-6", DateTimeZoneFactory::getDateTimeZone($this->timezone)), + new \DateTime("$this->year-6-6", DateTimeZoneFactory::getDateTimeZone($this->timezone)), $this->locale )); } @@ -386,7 +384,7 @@ private function calculateConstitutionDay(): void $this->addHoliday(new Holiday( 'constitutionDay', ['en' => 'Constitution Day', 'ko' => '제헌절'], - new DateTime("$this->year-7-17", DateTimeZoneFactory::getDateTimeZone($this->timezone)), + new \DateTime("$this->year-7-17", DateTimeZoneFactory::getDateTimeZone($this->timezone)), $this->locale )); } @@ -405,7 +403,7 @@ private function calculateLiberationDay(): void $this->addHoliday(new Holiday( 'liberationDay', ['en' => 'Liberation Day', 'ko' => '광복절'], - new DateTime("$this->year-8-15", DateTimeZoneFactory::getDateTimeZone($this->timezone)), + new \DateTime("$this->year-8-15", DateTimeZoneFactory::getDateTimeZone($this->timezone)), $this->locale )); } @@ -424,7 +422,7 @@ private function calculateArmedForcesDay(): void $this->addHoliday(new Holiday( 'armedForcesDay', ['en' => 'Armed Forces Day', 'ko' => '국군의 날'], - new DateTime("$this->year-10-1", DateTimeZoneFactory::getDateTimeZone($this->timezone)), + new \DateTime("$this->year-10-1", DateTimeZoneFactory::getDateTimeZone($this->timezone)), $this->locale )); } @@ -443,7 +441,7 @@ private function calculateNationalFoundationDay(): void $this->addHoliday(new Holiday( 'nationalFoundationDay', ['en' => 'National Foundation Day', 'ko' => '개천절'], - new DateTime("$this->year-10-3", DateTimeZoneFactory::getDateTimeZone($this->timezone)), + new \DateTime("$this->year-10-3", DateTimeZoneFactory::getDateTimeZone($this->timezone)), $this->locale )); } @@ -462,7 +460,7 @@ private function calculateHangulDay(): void $this->addHoliday(new Holiday( 'hangulDay', ['en' => 'Hangul Day', 'ko' => '한글날'], - new DateTime("$this->year-10-9", DateTimeZoneFactory::getDateTimeZone($this->timezone)), + new \DateTime("$this->year-10-9", DateTimeZoneFactory::getDateTimeZone($this->timezone)), $this->locale )); } @@ -586,8 +584,8 @@ private function calculateSubstituteHolidays(): void // And weekends are keyed by string start with 'weekend:'. // For the substitute, we will use first item in queue. $origin = $this->getHoliday($names[0]); - $nextWorkingDay = DateTime::createFromFormat('Y-m-d', $day, $tz); - if ($nextWorkingDay instanceof DateTime) { + $nextWorkingDay = \DateTime::createFromFormat('Y-m-d', $day, $tz); + if ($nextWorkingDay instanceof \DateTime) { $workDay = $this->nextWorkingDay($nextWorkingDay); $this->addSubstituteHoliday($origin, $workDay->format('Y-m-d')); } @@ -597,9 +595,9 @@ private function calculateSubstituteHolidays(): void /** * Helper method to find a first working day after specific date. */ - private function nextWorkingDay(DateTime $date): DateTime + private function nextWorkingDay(\DateTime $date): \DateTime { - $interval = new DateInterval('P1D'); + $interval = new \DateInterval('P1D'); $next = clone $date; do { $next->add($interval); @@ -624,7 +622,7 @@ private function addSubstituteHoliday(?Holiday $origin, string $date_str): void $this->addHoliday(new SubstituteHoliday( $origin, [], - new DateTime($date_str, DateTimeZoneFactory::getDateTimeZone($this->timezone)), + new \DateTime($date_str, DateTimeZoneFactory::getDateTimeZone($this->timezone)), $this->locale )); } diff --git a/src/Yasumi/Provider/Spain.php b/src/Yasumi/Provider/Spain.php index e48845242..bc66b729d 100644 --- a/src/Yasumi/Provider/Spain.php +++ b/src/Yasumi/Provider/Spain.php @@ -14,7 +14,6 @@ namespace Yasumi\Provider; -use DateTime; use Yasumi\Exception\InvalidDateException; use Yasumi\Exception\UnknownLocaleException; use Yasumi\Holiday; @@ -96,7 +95,7 @@ private function calculateNationalDay(): void 'ca' => 'Festa Nacional d’Espanya', 'es' => 'Fiesta Nacional de España', ], - new DateTime("$this->year-10-12", DateTimeZoneFactory::getDateTimeZone($this->timezone)), + new \DateTime("$this->year-10-12", DateTimeZoneFactory::getDateTimeZone($this->timezone)), $this->locale )); } @@ -125,7 +124,7 @@ private function calculateConstitutionDay(): void 'ca' => 'Dia de la Constitució', 'es' => 'Día de la Constitución', ], - new DateTime("$this->year-12-6", DateTimeZoneFactory::getDateTimeZone($this->timezone)), + new \DateTime("$this->year-12-6", DateTimeZoneFactory::getDateTimeZone($this->timezone)), $this->locale )); } diff --git a/src/Yasumi/Provider/Spain/Andalusia.php b/src/Yasumi/Provider/Spain/Andalusia.php index 0fc1361ca..1b6efbcad 100644 --- a/src/Yasumi/Provider/Spain/Andalusia.php +++ b/src/Yasumi/Provider/Spain/Andalusia.php @@ -14,7 +14,6 @@ namespace Yasumi\Provider\Spain; -use DateTime; use Yasumi\Exception\InvalidDateException; use Yasumi\Exception\UnknownLocaleException; use Yasumi\Holiday; @@ -81,7 +80,7 @@ private function calculateAndalusiaDay(): void $this->addHoliday(new Holiday( 'andalusiaDay', ['es' => 'Día de Andalucía'], - new DateTime("$this->year-2-28", DateTimeZoneFactory::getDateTimeZone($this->timezone)), + new \DateTime("$this->year-2-28", DateTimeZoneFactory::getDateTimeZone($this->timezone)), $this->locale )); } diff --git a/src/Yasumi/Provider/Spain/Asturias.php b/src/Yasumi/Provider/Spain/Asturias.php index 85beca4fd..b223f00c1 100644 --- a/src/Yasumi/Provider/Spain/Asturias.php +++ b/src/Yasumi/Provider/Spain/Asturias.php @@ -14,7 +14,6 @@ namespace Yasumi\Provider\Spain; -use DateTime; use Yasumi\Exception\InvalidDateException; use Yasumi\Exception\UnknownLocaleException; use Yasumi\Holiday; @@ -83,7 +82,7 @@ private function calculateAsturiasDay(): void $this->addHoliday(new Holiday( 'asturiasDay', ['es' => 'Día de Asturias'], - new DateTime("$this->year-9-8", DateTimeZoneFactory::getDateTimeZone($this->timezone)), + new \DateTime("$this->year-9-8", DateTimeZoneFactory::getDateTimeZone($this->timezone)), $this->locale )); } diff --git a/src/Yasumi/Provider/Spain/BalearicIslands.php b/src/Yasumi/Provider/Spain/BalearicIslands.php index 1f3cc75d6..5bb74505c 100644 --- a/src/Yasumi/Provider/Spain/BalearicIslands.php +++ b/src/Yasumi/Provider/Spain/BalearicIslands.php @@ -14,7 +14,6 @@ namespace Yasumi\Provider\Spain; -use DateTime; use Yasumi\Exception\InvalidDateException; use Yasumi\Exception\UnknownLocaleException; use Yasumi\Holiday; @@ -86,7 +85,7 @@ private function calculateBalearicIslandsDay(): void 'ca' => 'Diada de les Illes Balears', 'es' => 'Día de les Illes Balears', ], - new DateTime("$this->year-3-1", DateTimeZoneFactory::getDateTimeZone($this->timezone)), + new \DateTime("$this->year-3-1", DateTimeZoneFactory::getDateTimeZone($this->timezone)), $this->locale )); } diff --git a/src/Yasumi/Provider/Spain/BasqueCountry.php b/src/Yasumi/Provider/Spain/BasqueCountry.php index 519b74a3f..955811f7a 100644 --- a/src/Yasumi/Provider/Spain/BasqueCountry.php +++ b/src/Yasumi/Provider/Spain/BasqueCountry.php @@ -14,7 +14,6 @@ namespace Yasumi\Provider\Spain; -use DateTime; use Yasumi\Exception\InvalidDateException; use Yasumi\Exception\UnknownLocaleException; use Yasumi\Holiday; @@ -83,7 +82,7 @@ private function calculateBasqueCountryDay(): void $this->addHoliday(new Holiday( 'basqueCountryDay', ['es' => 'Euskadi Eguna'], - new DateTime("$this->year-10-25", DateTimeZoneFactory::getDateTimeZone($this->timezone)), + new \DateTime("$this->year-10-25", DateTimeZoneFactory::getDateTimeZone($this->timezone)), $this->locale )); } diff --git a/src/Yasumi/Provider/Spain/CanaryIslands.php b/src/Yasumi/Provider/Spain/CanaryIslands.php index ef1c0bd3c..e21609916 100644 --- a/src/Yasumi/Provider/Spain/CanaryIslands.php +++ b/src/Yasumi/Provider/Spain/CanaryIslands.php @@ -14,7 +14,6 @@ namespace Yasumi\Provider\Spain; -use DateTime; use Yasumi\Exception\InvalidDateException; use Yasumi\Exception\UnknownLocaleException; use Yasumi\Holiday; @@ -82,7 +81,7 @@ private function calculateCanaryIslandsDay(): void $this->addHoliday(new Holiday( 'canaryIslandsDay', ['es' => 'Día de las Canarias'], - new DateTime("$this->year-5-30", DateTimeZoneFactory::getDateTimeZone($this->timezone)), + new \DateTime("$this->year-5-30", DateTimeZoneFactory::getDateTimeZone($this->timezone)), $this->locale )); } diff --git a/src/Yasumi/Provider/Spain/Cantabria.php b/src/Yasumi/Provider/Spain/Cantabria.php index 492d9f4c2..c09567736 100644 --- a/src/Yasumi/Provider/Spain/Cantabria.php +++ b/src/Yasumi/Provider/Spain/Cantabria.php @@ -14,7 +14,6 @@ namespace Yasumi\Provider\Spain; -use DateTime; use Yasumi\Exception\InvalidDateException; use Yasumi\Exception\UnknownLocaleException; use Yasumi\Holiday; @@ -86,7 +85,7 @@ private function calculateCantabriaDay(): void $this->addHoliday(new Holiday( 'cantabriaDay', ['es' => 'Día de Cantabria'], - new DateTime("second sunday of august $this->year", DateTimeZoneFactory::getDateTimeZone($this->timezone)), + new \DateTime("second sunday of august $this->year", DateTimeZoneFactory::getDateTimeZone($this->timezone)), $this->locale )); } diff --git a/src/Yasumi/Provider/Spain/CastileAndLeon.php b/src/Yasumi/Provider/Spain/CastileAndLeon.php index 2ee3254ca..9a46064d1 100644 --- a/src/Yasumi/Provider/Spain/CastileAndLeon.php +++ b/src/Yasumi/Provider/Spain/CastileAndLeon.php @@ -15,7 +15,6 @@ namespace Yasumi\Provider\Spain; -use DateTime; use Yasumi\Exception\InvalidDateException; use Yasumi\Exception\UnknownLocaleException; use Yasumi\Holiday; @@ -83,7 +82,7 @@ private function calculateCastileAndLeonDay(): void $this->addHoliday(new Holiday( 'castileAndLeonDay', ['es' => 'Día de Castilla y León'], - new DateTime("$this->year-4-23", DateTimeZoneFactory::getDateTimeZone($this->timezone)), + new \DateTime("$this->year-4-23", DateTimeZoneFactory::getDateTimeZone($this->timezone)), $this->locale )); } diff --git a/src/Yasumi/Provider/Spain/CastillaLaMancha.php b/src/Yasumi/Provider/Spain/CastillaLaMancha.php index 647ad8fd2..d1b71861f 100644 --- a/src/Yasumi/Provider/Spain/CastillaLaMancha.php +++ b/src/Yasumi/Provider/Spain/CastillaLaMancha.php @@ -15,7 +15,6 @@ namespace Yasumi\Provider\Spain; -use DateTime; use Yasumi\Exception\InvalidDateException; use Yasumi\Exception\UnknownLocaleException; use Yasumi\Holiday; @@ -86,7 +85,7 @@ private function calculateCastillaLaManchaDay(): void $this->addHoliday(new Holiday( 'castillaLaManchaDay', ['es' => 'Día de la Región Castilla-La Mancha'], - new DateTime("$this->year-5-31", DateTimeZoneFactory::getDateTimeZone($this->timezone)), + new \DateTime("$this->year-5-31", DateTimeZoneFactory::getDateTimeZone($this->timezone)), $this->locale )); } diff --git a/src/Yasumi/Provider/Spain/Catalonia.php b/src/Yasumi/Provider/Spain/Catalonia.php index 8961f651c..4b76d3ca3 100644 --- a/src/Yasumi/Provider/Spain/Catalonia.php +++ b/src/Yasumi/Provider/Spain/Catalonia.php @@ -14,7 +14,6 @@ namespace Yasumi\Provider\Spain; -use DateTime; use Yasumi\Exception\InvalidDateException; use Yasumi\Exception\UnknownLocaleException; use Yasumi\Holiday; @@ -89,7 +88,7 @@ private function calculateNationalDayOfCatalonia(): void 'ca' => 'Diada Nacional de Catalunya', 'es' => 'Diada Nacional de Cataluña', ], - new DateTime("$this->year-9-11", DateTimeZoneFactory::getDateTimeZone($this->timezone)), + new \DateTime("$this->year-9-11", DateTimeZoneFactory::getDateTimeZone($this->timezone)), $this->locale )); } diff --git a/src/Yasumi/Provider/Spain/Ceuta.php b/src/Yasumi/Provider/Spain/Ceuta.php index 94270a405..9f4e86175 100644 --- a/src/Yasumi/Provider/Spain/Ceuta.php +++ b/src/Yasumi/Provider/Spain/Ceuta.php @@ -14,7 +14,6 @@ namespace Yasumi\Provider\Spain; -use DateTime; use Yasumi\Exception\InvalidDateException; use Yasumi\Exception\UnknownLocaleException; use Yasumi\Holiday; @@ -80,7 +79,7 @@ private function calculateDayOfCeuta(): void $this->addHoliday(new Holiday( 'ceutaDay', ['es' => 'Día de Ceuta'], - new DateTime("$this->year-9-2", DateTimeZoneFactory::getDateTimeZone($this->timezone)), + new \DateTime("$this->year-9-2", DateTimeZoneFactory::getDateTimeZone($this->timezone)), $this->locale )); } diff --git a/src/Yasumi/Provider/Spain/CommunityOfMadrid.php b/src/Yasumi/Provider/Spain/CommunityOfMadrid.php index 2417a8a2f..1b069bc1f 100644 --- a/src/Yasumi/Provider/Spain/CommunityOfMadrid.php +++ b/src/Yasumi/Provider/Spain/CommunityOfMadrid.php @@ -14,7 +14,6 @@ namespace Yasumi\Provider\Spain; -use DateTime; use Yasumi\Exception\InvalidDateException; use Yasumi\Exception\UnknownLocaleException; use Yasumi\Holiday; @@ -86,7 +85,7 @@ private function calculateDosdeMayoUprisingDay(): void $this->addHoliday(new Holiday( 'dosdeMayoUprisingDay', ['es' => 'Fiesta de la Comunidad de Madrid'], - new DateTime("$this->year-5-2", DateTimeZoneFactory::getDateTimeZone($this->timezone)), + new \DateTime("$this->year-5-2", DateTimeZoneFactory::getDateTimeZone($this->timezone)), $this->locale )); } diff --git a/src/Yasumi/Provider/Spain/Extremadura.php b/src/Yasumi/Provider/Spain/Extremadura.php index fed1a1326..7f674f0ae 100644 --- a/src/Yasumi/Provider/Spain/Extremadura.php +++ b/src/Yasumi/Provider/Spain/Extremadura.php @@ -14,7 +14,6 @@ namespace Yasumi\Provider\Spain; -use DateTime; use Yasumi\Exception\InvalidDateException; use Yasumi\Exception\UnknownLocaleException; use Yasumi\Holiday; @@ -83,7 +82,7 @@ private function calculateDayOfExtremadura(): void $this->addHoliday(new Holiday( 'extremaduraDay', ['es' => 'Día de Extremadura'], - new DateTime("$this->year-9-8", DateTimeZoneFactory::getDateTimeZone($this->timezone)), + new \DateTime("$this->year-9-8", DateTimeZoneFactory::getDateTimeZone($this->timezone)), $this->locale )); } diff --git a/src/Yasumi/Provider/Spain/Galicia.php b/src/Yasumi/Provider/Spain/Galicia.php index b2127147e..8556633d3 100644 --- a/src/Yasumi/Provider/Spain/Galicia.php +++ b/src/Yasumi/Provider/Spain/Galicia.php @@ -14,7 +14,6 @@ namespace Yasumi\Provider\Spain; -use DateTime; use Yasumi\Exception\InvalidDateException; use Yasumi\Exception\UnknownLocaleException; use Yasumi\Holiday; @@ -84,7 +83,7 @@ private function calculateGalicianLiteratureDay(): void $this->addHoliday(new Holiday('galicianLiteratureDay', [ 'es' => 'Día de las Letras Gallegas', 'gl' => 'Día das Letras Galegas', - ], new DateTime("$this->year-5-17", DateTimeZoneFactory::getDateTimeZone($this->timezone)), $this->locale)); + ], new \DateTime("$this->year-5-17", DateTimeZoneFactory::getDateTimeZone($this->timezone)), $this->locale)); } } @@ -111,7 +110,7 @@ private function calculateStJamesDay(): void if ($this->year >= 2000) { $this->addHoliday(new Holiday('stJamesDay', [ 'es' => 'Santiago Apostol', - ], new DateTime("$this->year-7-25", DateTimeZoneFactory::getDateTimeZone($this->timezone)), $this->locale)); + ], new \DateTime("$this->year-7-25", DateTimeZoneFactory::getDateTimeZone($this->timezone)), $this->locale)); } } } diff --git a/src/Yasumi/Provider/Spain/LaRioja.php b/src/Yasumi/Provider/Spain/LaRioja.php index d4e9f88ea..95a9571f6 100644 --- a/src/Yasumi/Provider/Spain/LaRioja.php +++ b/src/Yasumi/Provider/Spain/LaRioja.php @@ -14,7 +14,6 @@ namespace Yasumi\Provider\Spain; -use DateTime; use Yasumi\Exception\InvalidDateException; use Yasumi\Exception\UnknownLocaleException; use Yasumi\Holiday; @@ -79,7 +78,7 @@ private function calculateLaRiojaDay(): void if ($this->year >= 1983) { $this->addHoliday(new Holiday('laRiojaDay', [ 'es' => 'Día de La Rioja', - ], new DateTime("$this->year-6-9", DateTimeZoneFactory::getDateTimeZone($this->timezone)), $this->locale)); + ], new \DateTime("$this->year-6-9", DateTimeZoneFactory::getDateTimeZone($this->timezone)), $this->locale)); } } } diff --git a/src/Yasumi/Provider/Spain/RegionOfMurcia.php b/src/Yasumi/Provider/Spain/RegionOfMurcia.php index a9dd42559..8d176b4b8 100644 --- a/src/Yasumi/Provider/Spain/RegionOfMurcia.php +++ b/src/Yasumi/Provider/Spain/RegionOfMurcia.php @@ -14,7 +14,6 @@ namespace Yasumi\Provider\Spain; -use DateTime; use Yasumi\Exception\InvalidDateException; use Yasumi\Exception\UnknownLocaleException; use Yasumi\Holiday; @@ -80,7 +79,7 @@ private function calculateDayOfMurcia(): void if ($this->year >= 1983) { $this->addHoliday(new Holiday('murciaDay', [ 'es' => 'Día de la Región de Murcia', - ], new DateTime("$this->year-6-9", DateTimeZoneFactory::getDateTimeZone($this->timezone)), $this->locale)); + ], new \DateTime("$this->year-6-9", DateTimeZoneFactory::getDateTimeZone($this->timezone)), $this->locale)); } } } diff --git a/src/Yasumi/Provider/Spain/ValencianCommunity.php b/src/Yasumi/Provider/Spain/ValencianCommunity.php index 9981f605e..c4bb590e3 100644 --- a/src/Yasumi/Provider/Spain/ValencianCommunity.php +++ b/src/Yasumi/Provider/Spain/ValencianCommunity.php @@ -14,7 +14,6 @@ namespace Yasumi\Provider\Spain; -use DateTime; use Yasumi\Exception\InvalidDateException; use Yasumi\Exception\UnknownLocaleException; use Yasumi\Holiday; @@ -91,7 +90,7 @@ private function calculateValencianCommunityDay(): void 'ca' => 'Diada Nacional del País Valencià', 'es' => 'Día de la Comunidad Valenciana', ], - new DateTime("$this->year-10-9", DateTimeZoneFactory::getDateTimeZone($this->timezone)), + new \DateTime("$this->year-10-9", DateTimeZoneFactory::getDateTimeZone($this->timezone)), $this->locale )); } diff --git a/src/Yasumi/Provider/Sweden.php b/src/Yasumi/Provider/Sweden.php index 6474af36f..7498c574e 100644 --- a/src/Yasumi/Provider/Sweden.php +++ b/src/Yasumi/Provider/Sweden.php @@ -14,8 +14,6 @@ namespace Yasumi\Provider; -use DateInterval; -use DateTime; use Yasumi\Exception\InvalidDateException; use Yasumi\Exception\UnknownLocaleException; use Yasumi\Holiday; @@ -100,7 +98,7 @@ private function calculateEpiphanyEve(): void $this->addHoliday(new Holiday( 'epiphanyEve', [], - new DateTime("$this->year-1-5", DateTimeZoneFactory::getDateTimeZone($this->timezone)), + new \DateTime("$this->year-1-5", DateTimeZoneFactory::getDateTimeZone($this->timezone)), $this->locale, Holiday::TYPE_OBSERVANCE )); @@ -127,7 +125,7 @@ private function calculateWalpurgisEve(): void $this->addHoliday(new Holiday( 'walpurgisEve', [], - new DateTime("$this->year-4-30", DateTimeZoneFactory::getDateTimeZone($this->timezone)), + new \DateTime("$this->year-4-30", DateTimeZoneFactory::getDateTimeZone($this->timezone)), $this->locale, Holiday::TYPE_OBSERVANCE )); @@ -154,7 +152,7 @@ private function calculateWalpurgisEve(): void */ private function calculateStJohnsHolidays(): void { - $date = new DateTime("$this->year-6-20 this saturday", DateTimeZoneFactory::getDateTimeZone($this->timezone)); + $date = new \DateTime("$this->year-6-20 this saturday", DateTimeZoneFactory::getDateTimeZone($this->timezone)); $this->addHoliday(new Holiday( 'stJohnsDay', [], @@ -162,7 +160,7 @@ private function calculateStJohnsHolidays(): void $this->locale )); - $date->sub(new DateInterval('P1D')); + $date->sub(new \DateInterval('P1D')); $this->addHoliday(new Holiday( 'stJohnsEve', [], @@ -195,7 +193,7 @@ private function calculateStJohnsHolidays(): void */ private function calculateAllSaintsHolidays(): void { - $date = new DateTime("$this->year-10-31 this saturday", DateTimeZoneFactory::getDateTimeZone($this->timezone)); + $date = new \DateTime("$this->year-10-31 this saturday", DateTimeZoneFactory::getDateTimeZone($this->timezone)); $this->addHoliday(new Holiday( 'allSaintsDay', [], @@ -203,7 +201,7 @@ private function calculateAllSaintsHolidays(): void $this->locale )); - $date->sub(new DateInterval('P1D')); + $date->sub(new \DateInterval('P1D')); $this->addHoliday(new Holiday( 'allSaintsEve', [], @@ -243,7 +241,7 @@ private function calculateNationalDay(): void $this->addHoliday(new Holiday( 'nationalDay', ['sv' => $holidayName], - new DateTime("$this->year-6-6", DateTimeZoneFactory::getDateTimeZone($this->timezone)), + new \DateTime("$this->year-6-6", DateTimeZoneFactory::getDateTimeZone($this->timezone)), $this->locale )); } diff --git a/src/Yasumi/Provider/Switzerland.php b/src/Yasumi/Provider/Switzerland.php index 0231035bb..0a1c7c353 100644 --- a/src/Yasumi/Provider/Switzerland.php +++ b/src/Yasumi/Provider/Switzerland.php @@ -14,8 +14,6 @@ namespace Yasumi\Provider; -use DateInterval; -use DateTime; use Yasumi\Exception\InvalidDateException; use Yasumi\Exception\UnknownLocaleException; use Yasumi\Holiday; @@ -81,7 +79,7 @@ protected function calculateBerchtoldsTag(): void 'fr' => 'Jour de la Saint-Berthold', 'en' => 'Berchtoldstag', ], - new DateTime($this->year.'-01-02', DateTimeZoneFactory::getDateTimeZone($this->timezone)), + new \DateTime($this->year.'-01-02', DateTimeZoneFactory::getDateTimeZone($this->timezone)), $this->locale, Holiday::TYPE_OTHER )); @@ -106,9 +104,9 @@ protected function calculateBettagsMontag(): void { if ($this->year >= 1832) { // Find third Sunday of September - $date = new DateTime('Third Sunday of '.$this->year.'-09', DateTimeZoneFactory::getDateTimeZone($this->timezone)); + $date = new \DateTime('Third Sunday of '.$this->year.'-09', DateTimeZoneFactory::getDateTimeZone($this->timezone)); // Go to next Thursday - $date->add(new DateInterval('P1D')); + $date->add(new \DateInterval('P1D')); $this->addHoliday(new Holiday('bettagsMontag', [ 'fr' => 'Jeûne fédéral', @@ -145,7 +143,7 @@ private function calculateNationalDay(): void $this->addHoliday(new Holiday( 'swissNationalDay', $translations, - new DateTime($this->year.'-08-01', DateTimeZoneFactory::getDateTimeZone($this->timezone)), + new \DateTime($this->year.'-08-01', DateTimeZoneFactory::getDateTimeZone($this->timezone)), $this->locale, Holiday::TYPE_OFFICIAL )); @@ -153,7 +151,7 @@ private function calculateNationalDay(): void $this->addHoliday(new Holiday( 'swissNationalDay', $translations, - new DateTime($this->year.'-08-01', DateTimeZoneFactory::getDateTimeZone($this->timezone)), + new \DateTime($this->year.'-08-01', DateTimeZoneFactory::getDateTimeZone($this->timezone)), $this->locale, Holiday::TYPE_OBSERVANCE )); diff --git a/src/Yasumi/Provider/Switzerland/Fribourg.php b/src/Yasumi/Provider/Switzerland/Fribourg.php index 59d04311a..ab8e53c9a 100644 --- a/src/Yasumi/Provider/Switzerland/Fribourg.php +++ b/src/Yasumi/Provider/Switzerland/Fribourg.php @@ -14,7 +14,6 @@ namespace Yasumi\Provider\Switzerland; -use DateTime; use Yasumi\Exception\InvalidDateException; use Yasumi\Exception\UnknownLocaleException; use Yasumi\Holiday; @@ -85,7 +84,7 @@ private function calculateDecember26th(): void 'en' => 'December 26th', 'fr' => '26 décembre', ], - new DateTime($this->year.'-12-26', DateTimeZoneFactory::getDateTimeZone($this->timezone)), + new \DateTime($this->year.'-12-26', DateTimeZoneFactory::getDateTimeZone($this->timezone)), $this->locale, Holiday::TYPE_OTHER )); diff --git a/src/Yasumi/Provider/Switzerland/Geneva.php b/src/Yasumi/Provider/Switzerland/Geneva.php index 970f70167..4abfe171c 100644 --- a/src/Yasumi/Provider/Switzerland/Geneva.php +++ b/src/Yasumi/Provider/Switzerland/Geneva.php @@ -14,8 +14,6 @@ namespace Yasumi\Provider\Switzerland; -use DateInterval; -use DateTime; use Yasumi\Exception\InvalidDateException; use Yasumi\Exception\UnknownLocaleException; use Yasumi\Holiday; @@ -84,9 +82,9 @@ private function calculateJeuneGenevois(): void } // Find first Sunday of September - $date = new DateTime('First Sunday of '.$this->year.'-09', DateTimeZoneFactory::getDateTimeZone($this->timezone)); + $date = new \DateTime('First Sunday of '.$this->year.'-09', DateTimeZoneFactory::getDateTimeZone($this->timezone)); // Go to next Thursday - $date->add(new DateInterval('P4D')); + $date->add(new \DateInterval('P4D')); $type = Holiday::TYPE_OTHER; if ($this->year > 1869 && $this->year < 1966) { @@ -121,7 +119,7 @@ private function calculateRestaurationGenevoise(): void [ 'fr' => 'Restauration de la République', ], - new DateTime($this->year.'-12-31', DateTimeZoneFactory::getDateTimeZone($this->timezone)), + new \DateTime($this->year.'-12-31', DateTimeZoneFactory::getDateTimeZone($this->timezone)), $this->locale, Holiday::TYPE_OTHER )); diff --git a/src/Yasumi/Provider/Switzerland/Glarus.php b/src/Yasumi/Provider/Switzerland/Glarus.php index 16870ca30..a9fb1f4df 100644 --- a/src/Yasumi/Provider/Switzerland/Glarus.php +++ b/src/Yasumi/Provider/Switzerland/Glarus.php @@ -14,7 +14,6 @@ namespace Yasumi\Provider\Switzerland; -use DateTime; use Yasumi\Exception\InvalidDateException; use Yasumi\Exception\UnknownLocaleException; use Yasumi\Holiday; @@ -79,7 +78,7 @@ public function initialize(): void private function calculateNafelserFahrt(): void { if ($this->year >= 1389) { - $date = new DateTime('First Thursday of '.$this->year.'-04', DateTimeZoneFactory::getDateTimeZone($this->timezone)); + $date = new \DateTime('First Thursday of '.$this->year.'-04', DateTimeZoneFactory::getDateTimeZone($this->timezone)); $this->addHoliday(new Holiday('nafelserFahrt', [ 'de' => 'Näfelser Fahrt', ], $date, $this->locale, Holiday::TYPE_OTHER)); diff --git a/src/Yasumi/Provider/Switzerland/Jura.php b/src/Yasumi/Provider/Switzerland/Jura.php index 50842acdb..7e8abb942 100644 --- a/src/Yasumi/Provider/Switzerland/Jura.php +++ b/src/Yasumi/Provider/Switzerland/Jura.php @@ -14,7 +14,6 @@ namespace Yasumi\Provider\Switzerland; -use DateTime; use Yasumi\Exception\InvalidDateException; use Yasumi\Exception\UnknownLocaleException; use Yasumi\Holiday; @@ -91,7 +90,7 @@ private function calculatePlebisciteJurassien(): void [ 'fr' => 'Commémoration du plébiscite jurassien', ], - new DateTime($this->year.'-06-23', DateTimeZoneFactory::getDateTimeZone($this->timezone)), + new \DateTime($this->year.'-06-23', DateTimeZoneFactory::getDateTimeZone($this->timezone)), $this->locale, Holiday::TYPE_OTHER )); diff --git a/src/Yasumi/Provider/Switzerland/Neuchatel.php b/src/Yasumi/Provider/Switzerland/Neuchatel.php index f01e0786d..1e816a095 100644 --- a/src/Yasumi/Provider/Switzerland/Neuchatel.php +++ b/src/Yasumi/Provider/Switzerland/Neuchatel.php @@ -14,7 +14,6 @@ namespace Yasumi\Provider\Switzerland; -use DateTime; use Yasumi\Exception\InvalidDateException; use Yasumi\Exception\UnknownLocaleException; use Yasumi\Holiday; @@ -98,7 +97,7 @@ private function calculateInstaurationRepublique(): void [ 'fr' => 'Instauration de la République', ], - new DateTime($this->year.'-03-01', DateTimeZoneFactory::getDateTimeZone($this->timezone)), + new \DateTime($this->year.'-03-01', DateTimeZoneFactory::getDateTimeZone($this->timezone)), $this->locale, Holiday::TYPE_OTHER )); @@ -121,7 +120,7 @@ private function calculateJanuary2nd(): void 'en' => 'January 2nd', 'fr' => '2 janvier', ], - new DateTime($this->year.'-01-02', DateTimeZoneFactory::getDateTimeZone($this->timezone)), + new \DateTime($this->year.'-01-02', DateTimeZoneFactory::getDateTimeZone($this->timezone)), $this->locale, Holiday::TYPE_OTHER )); @@ -143,7 +142,7 @@ private function calculateDecember26th(): void 'en' => 'December 26th', 'fr' => '26 décembre', ], - new DateTime($this->year.'-12-26', DateTimeZoneFactory::getDateTimeZone($this->timezone)), + new \DateTime($this->year.'-12-26', DateTimeZoneFactory::getDateTimeZone($this->timezone)), $this->locale, Holiday::TYPE_OTHER )); diff --git a/src/Yasumi/Provider/Switzerland/Obwalden.php b/src/Yasumi/Provider/Switzerland/Obwalden.php index a04ec8e97..036e9a6ae 100644 --- a/src/Yasumi/Provider/Switzerland/Obwalden.php +++ b/src/Yasumi/Provider/Switzerland/Obwalden.php @@ -14,7 +14,6 @@ namespace Yasumi\Provider\Switzerland; -use DateTime; use Yasumi\Exception\InvalidDateException; use Yasumi\Exception\UnknownLocaleException; use Yasumi\Holiday; @@ -89,7 +88,7 @@ private function calculateBruderKlausenFest(): void [ 'de' => 'Bruder-Klausen-Fest', ], - new DateTime($this->year.'-09-25', DateTimeZoneFactory::getDateTimeZone($this->timezone)), + new \DateTime($this->year.'-09-25', DateTimeZoneFactory::getDateTimeZone($this->timezone)), $this->locale, Holiday::TYPE_OTHER )); @@ -99,7 +98,7 @@ private function calculateBruderKlausenFest(): void [ 'de' => 'Bruder-Klausen-Fest', ], - new DateTime($this->year.'-09-21', DateTimeZoneFactory::getDateTimeZone($this->timezone)), + new \DateTime($this->year.'-09-21', DateTimeZoneFactory::getDateTimeZone($this->timezone)), $this->locale, Holiday::TYPE_OTHER )); diff --git a/src/Yasumi/Provider/Switzerland/Ticino.php b/src/Yasumi/Provider/Switzerland/Ticino.php index 7a3ae0265..dcc5b8cb1 100644 --- a/src/Yasumi/Provider/Switzerland/Ticino.php +++ b/src/Yasumi/Provider/Switzerland/Ticino.php @@ -14,7 +14,6 @@ namespace Yasumi\Provider\Switzerland; -use DateTime; use Yasumi\Exception\InvalidDateException; use Yasumi\Exception\UnknownLocaleException; use Yasumi\Holiday; @@ -96,7 +95,7 @@ private function calculateStPeterPaul(): void 'fr' => 'Solennité des saints Pierre et Paul', 'de' => 'St. Peter und Paul', ], - new DateTime($this->year.'-06-29', DateTimeZoneFactory::getDateTimeZone($this->timezone)), + new \DateTime($this->year.'-06-29', DateTimeZoneFactory::getDateTimeZone($this->timezone)), $this->locale, Holiday::TYPE_OTHER )); diff --git a/src/Yasumi/Provider/USA.php b/src/Yasumi/Provider/USA.php index 3153f62be..f291630ef 100644 --- a/src/Yasumi/Provider/USA.php +++ b/src/Yasumi/Provider/USA.php @@ -14,8 +14,6 @@ namespace Yasumi\Provider; -use DateInterval; -use DateTime; use Yasumi\Exception\InvalidDateException; use Yasumi\Exception\UnknownLocaleException; use Yasumi\Holiday; @@ -89,7 +87,7 @@ private function calculateMartinLutherKingday(): void if ($this->year >= 1986) { $this->addHoliday(new Holiday('martinLutherKingDay', [ 'en' => 'Dr. Martin Luther King Jr’s Birthday', - ], new DateTime("third monday of january $this->year", DateTimeZoneFactory::getDateTimeZone($this->timezone)), $this->locale)); + ], new \DateTime("third monday of january $this->year", DateTimeZoneFactory::getDateTimeZone($this->timezone)), $this->locale)); } } @@ -111,9 +109,9 @@ private function calculateMartinLutherKingday(): void private function calculateWashingtonsBirthday(): void { if ($this->year >= 1879) { - $date = new DateTime("$this->year-2-22", DateTimeZoneFactory::getDateTimeZone($this->timezone)); + $date = new \DateTime("$this->year-2-22", DateTimeZoneFactory::getDateTimeZone($this->timezone)); if ($this->year >= 1968) { - $date = new DateTime("third monday of february $this->year", DateTimeZoneFactory::getDateTimeZone($this->timezone)); + $date = new \DateTime("third monday of february $this->year", DateTimeZoneFactory::getDateTimeZone($this->timezone)); } $this->addHoliday(new Holiday('washingtonsBirthday', [ 'en' => 'Washington’s Birthday', @@ -136,9 +134,9 @@ private function calculateWashingtonsBirthday(): void private function calculateMemorialDay(): void { if ($this->year >= 1865) { - $date = new DateTime("$this->year-5-30", DateTimeZoneFactory::getDateTimeZone($this->timezone)); + $date = new \DateTime("$this->year-5-30", DateTimeZoneFactory::getDateTimeZone($this->timezone)); if ($this->year >= 1968) { - $date = new DateTime("last monday of may $this->year", DateTimeZoneFactory::getDateTimeZone($this->timezone)); + $date = new \DateTime("last monday of may $this->year", DateTimeZoneFactory::getDateTimeZone($this->timezone)); } $this->addHoliday(new Holiday('memorialDay', [ 'en' => 'Memorial Day', @@ -163,7 +161,7 @@ private function calculateJuneteenth(): void if ($this->year >= 2021) { $this->addHoliday(new Holiday('juneteenth', [ 'en' => 'Juneteenth', - ], new DateTime("$this->year-6-19", DateTimeZoneFactory::getDateTimeZone($this->timezone)), $this->locale)); + ], new \DateTime("$this->year-6-19", DateTimeZoneFactory::getDateTimeZone($this->timezone)), $this->locale)); } } @@ -184,7 +182,7 @@ private function calculateIndependenceDay(): void if ($this->year >= 1776) { $this->addHoliday(new Holiday('independenceDay', [ 'en' => 'Independence Day', - ], new DateTime("$this->year-7-4", DateTimeZoneFactory::getDateTimeZone($this->timezone)), $this->locale)); + ], new \DateTime("$this->year-7-4", DateTimeZoneFactory::getDateTimeZone($this->timezone)), $this->locale)); } } @@ -206,7 +204,7 @@ private function calculateLabourDay(): void [ 'en' => 'Labour Day', ], - new DateTime("first monday of september $this->year", DateTimeZoneFactory::getDateTimeZone($this->timezone)), + new \DateTime("first monday of september $this->year", DateTimeZoneFactory::getDateTimeZone($this->timezone)), $this->locale )); } @@ -228,9 +226,9 @@ private function calculateLabourDay(): void private function calculateColumbusDay(): void { if ($this->year >= 1937) { - $date = new DateTime("$this->year-10-12", DateTimeZoneFactory::getDateTimeZone($this->timezone)); + $date = new \DateTime("$this->year-10-12", DateTimeZoneFactory::getDateTimeZone($this->timezone)); if ($this->year >= 1970) { - $date = new DateTime("second monday of october $this->year", DateTimeZoneFactory::getDateTimeZone($this->timezone)); + $date = new \DateTime("second monday of october $this->year", DateTimeZoneFactory::getDateTimeZone($this->timezone)); } $this->addHoliday(new Holiday('columbusDay', [ 'en' => 'Columbus Day', @@ -256,7 +254,7 @@ private function calculateVeteransDay(): void $this->addHoliday(new Holiday('veteransDay', [ 'en' => $name, - ], new DateTime("$this->year-11-11", DateTimeZoneFactory::getDateTimeZone($this->timezone)), $this->locale)); + ], new \DateTime("$this->year-11-11", DateTimeZoneFactory::getDateTimeZone($this->timezone)), $this->locale)); } } @@ -280,7 +278,7 @@ private function calculateThanksgivingDay(): void [ 'en' => 'Thanksgiving Day', ], - new DateTime("fourth thursday of november $this->year", DateTimeZoneFactory::getDateTimeZone($this->timezone)), + new \DateTime("fourth thursday of november $this->year", DateTimeZoneFactory::getDateTimeZone($this->timezone)), $this->locale )); } @@ -306,13 +304,13 @@ private function calculateSubstituteHolidays(): void // Substitute holiday is on a Monday in case the holiday falls on a Sunday if (0 === (int) $holiday->format('w')) { $date = clone $holiday; - $date->add(new DateInterval('P1D')); + $date->add(new \DateInterval('P1D')); } // Substitute holiday is on a Friday in case the holiday falls on a Saturday if (6 === (int) $holiday->format('w')) { $date = clone $holiday; - $date->sub(new DateInterval('P1D')); + $date->sub(new \DateInterval('P1D')); } // Add substitute holiday diff --git a/src/Yasumi/Provider/UnitedKingdom.php b/src/Yasumi/Provider/UnitedKingdom.php index c5be0ac8b..0e55355d4 100644 --- a/src/Yasumi/Provider/UnitedKingdom.php +++ b/src/Yasumi/Provider/UnitedKingdom.php @@ -14,8 +14,6 @@ namespace Yasumi\Provider; -use DateInterval; -use DateTime; use Yasumi\Exception\InvalidDateException; use Yasumi\Exception\UnknownLocaleException; use Yasumi\Holiday; @@ -101,7 +99,7 @@ protected function calculateMayDayBankHoliday(): void $this->addHoliday(new Holiday( 'mayDayBankHoliday', ['en' => 'May Day Bank Holiday'], - new DateTime("$this->year-5-8", DateTimeZoneFactory::getDateTimeZone($this->timezone)), + new \DateTime("$this->year-5-8", DateTimeZoneFactory::getDateTimeZone($this->timezone)), $this->locale, Holiday::TYPE_BANK )); @@ -112,7 +110,7 @@ protected function calculateMayDayBankHoliday(): void $this->addHoliday(new Holiday( 'mayDayBankHoliday', ['en' => 'May Day Bank Holiday'], - new DateTime("first monday of may $this->year", DateTimeZoneFactory::getDateTimeZone($this->timezone)), + new \DateTime("first monday of may $this->year", DateTimeZoneFactory::getDateTimeZone($this->timezone)), $this->locale, Holiday::TYPE_BANK )); @@ -147,7 +145,7 @@ protected function calculateSpringBankHoliday(): void $this->addHoliday(new Holiday( 'springBankHoliday', ['en' => 'Spring Bank Holiday'], - new DateTime("$this->year-6-4", DateTimeZoneFactory::getDateTimeZone($this->timezone)), + new \DateTime("$this->year-6-4", DateTimeZoneFactory::getDateTimeZone($this->timezone)), $this->locale, Holiday::TYPE_BANK )); @@ -160,7 +158,7 @@ protected function calculateSpringBankHoliday(): void $this->addHoliday(new Holiday( 'springBankHoliday', ['en' => 'Spring Bank Holiday'], - new DateTime("$this->year-6-2", DateTimeZoneFactory::getDateTimeZone($this->timezone)), + new \DateTime("$this->year-6-2", DateTimeZoneFactory::getDateTimeZone($this->timezone)), $this->locale, Holiday::TYPE_BANK )); @@ -171,7 +169,7 @@ protected function calculateSpringBankHoliday(): void $this->addHoliday(new Holiday( 'springBankHoliday', ['en' => 'Spring Bank Holiday'], - new DateTime("last monday of may $this->year", DateTimeZoneFactory::getDateTimeZone($this->timezone)), + new \DateTime("last monday of may $this->year", DateTimeZoneFactory::getDateTimeZone($this->timezone)), $this->locale, Holiday::TYPE_BANK )); @@ -198,7 +196,7 @@ protected function calculatePlatinumJubileeBankHoliday(): void $this->addHoliday(new Holiday( 'platinumJubileeBankHoliday', ['en' => 'Platinum Jubilee Bank Holiday'], - new DateTime("$this->year-6-3", DateTimeZoneFactory::getDateTimeZone($this->timezone)), + new \DateTime("$this->year-6-3", DateTimeZoneFactory::getDateTimeZone($this->timezone)), $this->locale, Holiday::TYPE_BANK )); @@ -225,7 +223,7 @@ protected function calculateQueenElizabethFuneralBankHoliday(): void $this->addHoliday(new Holiday( 'queenElizabethFuneralBankHoliday', ['en' => 'Queen Elizabeth II’s State Funeral Bank Holiday'], - new DateTime("$this->year-9-19", DateTimeZoneFactory::getDateTimeZone($this->timezone)), + new \DateTime("$this->year-9-19", DateTimeZoneFactory::getDateTimeZone($this->timezone)), $this->locale, Holiday::TYPE_BANK )); @@ -262,7 +260,7 @@ protected function calculateChristmasHolidays(?string $type = null): void if (\in_array((int) $christmasDay->format('w'), [0, 6], true)) { $date = clone $christmasDay; - $date->add(new DateInterval('P2D')); + $date->add(new \DateInterval('P2D')); $this->addHoliday(new SubstituteHoliday( $christmasDay, [], @@ -274,7 +272,7 @@ protected function calculateChristmasHolidays(?string $type = null): void if (\in_array((int) $secondChristmasDay->format('w'), [0, 6], true)) { $date = clone $secondChristmasDay; - $date->add(new DateInterval('P2D')); + $date->add(new \DateInterval('P2D')); $this->addHoliday(new SubstituteHoliday( $secondChristmasDay, [], @@ -314,7 +312,7 @@ private function calculateNewYearsDay(): void $type = Holiday::TYPE_OBSERVANCE; } - $newYearsDay = new DateTime("$this->year-01-01", DateTimeZoneFactory::getDateTimeZone($this->timezone)); + $newYearsDay = new \DateTime("$this->year-01-01", DateTimeZoneFactory::getDateTimeZone($this->timezone)); // If New Years Day falls on a Saturday or Sunday, it is observed the next Monday (January 2nd or 3rd) if (\in_array((int) $newYearsDay->format('w'), [0, 6], true)) { @@ -350,7 +348,7 @@ private function calculateSummerBankHoliday(): void $this->addHoliday(new Holiday( 'summerBankHoliday', ['en' => 'August Bank Holiday'], - new DateTime("first monday of august $this->year", DateTimeZoneFactory::getDateTimeZone($this->timezone)), + new \DateTime("first monday of august $this->year", DateTimeZoneFactory::getDateTimeZone($this->timezone)), $this->locale, Holiday::TYPE_BANK )); @@ -365,7 +363,7 @@ private function calculateSummerBankHoliday(): void $this->addHoliday(new Holiday( 'summerBankHoliday', ['en' => 'Summer Bank Holiday'], - new DateTime("first monday of september $this->year", DateTimeZoneFactory::getDateTimeZone($this->timezone)), + new \DateTime("first monday of september $this->year", DateTimeZoneFactory::getDateTimeZone($this->timezone)), $this->locale, Holiday::TYPE_BANK )); @@ -376,7 +374,7 @@ private function calculateSummerBankHoliday(): void $this->addHoliday(new Holiday( 'summerBankHoliday', ['en' => 'Summer Bank Holiday'], - new DateTime("last monday of august $this->year", DateTimeZoneFactory::getDateTimeZone($this->timezone)), + new \DateTime("last monday of august $this->year", DateTimeZoneFactory::getDateTimeZone($this->timezone)), $this->locale, Holiday::TYPE_BANK )); @@ -394,7 +392,7 @@ private function calculateSummerBankHoliday(): void private function calculateMotheringSunday(): void { $date = $this->calculateEaster($this->year, $this->timezone); - $date->sub(new DateInterval('P3W')); + $date->sub(new \DateInterval('P3W')); $this->addHoliday(new Holiday( 'motheringSunday', diff --git a/src/Yasumi/Provider/UnitedKingdom/NorthernIreland.php b/src/Yasumi/Provider/UnitedKingdom/NorthernIreland.php index 93ad7bf95..a9cd6a6aa 100644 --- a/src/Yasumi/Provider/UnitedKingdom/NorthernIreland.php +++ b/src/Yasumi/Provider/UnitedKingdom/NorthernIreland.php @@ -14,7 +14,6 @@ namespace Yasumi\Provider\UnitedKingdom; -use DateTime; use Yasumi\Exception\InvalidDateException; use Yasumi\Exception\UnknownLocaleException; use Yasumi\Holiday; @@ -81,7 +80,7 @@ private function calculateStPatricksDay(): void $holiday = new Holiday( 'stPatricksDay', ['en' => 'St. Patrick’s Day'], - new DateTime($this->year.'-3-17', DateTimeZoneFactory::getDateTimeZone($this->timezone)), + new \DateTime($this->year.'-3-17', DateTimeZoneFactory::getDateTimeZone($this->timezone)), $this->locale, Holiday::TYPE_BANK ); @@ -127,7 +126,7 @@ private function calculateBattleOfTheBoyne(): void $holiday = new Holiday( 'battleOfTheBoyne', ['en' => 'Battle of the Boyne'], - new DateTime($this->year.'-7-12', DateTimeZoneFactory::getDateTimeZone($this->timezone)), + new \DateTime($this->year.'-7-12', DateTimeZoneFactory::getDateTimeZone($this->timezone)), $this->locale, Holiday::TYPE_BANK ); diff --git a/src/Yasumi/Provider/UnitedKingdom/Scotland.php b/src/Yasumi/Provider/UnitedKingdom/Scotland.php index af5ee863d..4ffbc35e0 100644 --- a/src/Yasumi/Provider/UnitedKingdom/Scotland.php +++ b/src/Yasumi/Provider/UnitedKingdom/Scotland.php @@ -14,8 +14,6 @@ namespace Yasumi\Provider\UnitedKingdom; -use DateInterval; -use DateTime; use Yasumi\Exception\InvalidDateException; use Yasumi\Exception\UnknownLocaleException; use Yasumi\Holiday; @@ -94,7 +92,7 @@ private function calculateSummerBankHoliday(): void $this->addHoliday(new Holiday( 'summerBankHoliday', ['en' => 'August Bank Holiday'], - new DateTime("first monday of august $this->year", DateTimeZoneFactory::getDateTimeZone($this->timezone)), + new \DateTime("first monday of august $this->year", DateTimeZoneFactory::getDateTimeZone($this->timezone)), $this->locale, Holiday::TYPE_BANK )); @@ -131,7 +129,7 @@ private function calculateNewYearsHolidays(): void $secondNewYearsDay = new Holiday( 'secondNewYearsDay', [], - new DateTime("$this->year-1-2", DateTimeZoneFactory::getDateTimeZone($this->timezone)), + new \DateTime("$this->year-1-2", DateTimeZoneFactory::getDateTimeZone($this->timezone)), $this->locale, $type ); @@ -141,7 +139,7 @@ private function calculateNewYearsHolidays(): void if (\in_array((int) $newYearsDay->format('w'), [0, 6], true)) { $date = clone $newYearsDay; - $date->add(new DateInterval('P2D')); + $date->add(new \DateInterval('P2D')); $this->addHoliday(new SubstituteHoliday( $newYearsDay, [], @@ -153,7 +151,7 @@ private function calculateNewYearsHolidays(): void if (\in_array((int) $secondNewYearsDay->format('w'), [0, 6], true)) { $date = clone $secondNewYearsDay; - $date->add(new DateInterval('P2D')); + $date->add(new \DateInterval('P2D')); $this->addHoliday(new SubstituteHoliday( $secondNewYearsDay, [], @@ -185,7 +183,7 @@ private function calculateStAndrewsDay(): void $holiday = new Holiday( 'stAndrewsDay', [], - new DateTime($this->year.'-11-30', DateTimeZoneFactory::getDateTimeZone($this->timezone)), + new \DateTime($this->year.'-11-30', DateTimeZoneFactory::getDateTimeZone($this->timezone)), $this->locale, Holiday::TYPE_BANK ); diff --git a/src/Yasumi/ProviderInterface.php b/src/Yasumi/ProviderInterface.php index 430ca4fdc..269dfadae 100644 --- a/src/Yasumi/ProviderInterface.php +++ b/src/Yasumi/ProviderInterface.php @@ -14,7 +14,6 @@ namespace Yasumi; -use ArrayIterator; use Yasumi\Exception\InvalidDateException; use Yasumi\Exception\UnknownLocaleException; use Yasumi\Filters\BetweenFilter; @@ -95,9 +94,9 @@ public function isHoliday(\DateTimeInterface $date): bool; /** * Get an iterator for the holidays. * - * @return ArrayIterator iterator for the holidays of this calendar + * @return \ArrayIterator iterator for the holidays of this calendar */ - public function getIterator(): ArrayIterator; + public function getIterator(): \ArrayIterator; /** * Adds a holiday to the holidays providers (i.e. country/state) list of holidays. diff --git a/src/Yasumi/Translations.php b/src/Yasumi/Translations.php index 5f3990e50..6230f199e 100644 --- a/src/Yasumi/Translations.php +++ b/src/Yasumi/Translations.php @@ -15,8 +15,6 @@ namespace Yasumi; -use DirectoryIterator; -use InvalidArgumentException; use Yasumi\Exception\UnknownLocaleException; /** @@ -50,18 +48,18 @@ public function __construct(array $availableLocales) * @param string $directoryPath directory path for translation files * * @throws UnknownLocaleException - * @throws InvalidArgumentException + * @throws \InvalidArgumentException */ public function loadTranslations(string $directoryPath): void { if (!file_exists($directoryPath)) { - throw new InvalidArgumentException('Directory with translations not found'); + throw new \InvalidArgumentException('Directory with translations not found'); } $directoryPath = rtrim($directoryPath, '/\\').DIRECTORY_SEPARATOR; $extension = 'php'; - foreach (new DirectoryIterator($directoryPath) as $file) { + foreach (new \DirectoryIterator($directoryPath) as $file) { if ($file->isDot() || $file->isDir()) { continue; } diff --git a/src/Yasumi/Yasumi.php b/src/Yasumi/Yasumi.php index b876c8855..a68e30bea 100644 --- a/src/Yasumi/Yasumi.php +++ b/src/Yasumi/Yasumi.php @@ -14,12 +14,6 @@ namespace Yasumi; -use FilesystemIterator; -use InvalidArgumentException; -use RecursiveDirectoryIterator; -use RecursiveIteratorIterator; -use ReflectionClass; -use RuntimeException; use Yasumi\Exception\InvalidDateException; use Yasumi\Exception\InvalidYearException; use Yasumi\Exception\ProviderNotFoundException; @@ -68,8 +62,8 @@ class Yasumi * @param int $workingDays Number of days to look ahead for the (first) next working day * * @throws UnknownLocaleException - * @throws RuntimeException - * @throws InvalidArgumentException + * @throws \RuntimeException + * @throws \InvalidArgumentException * @throws \Exception * @throws InvalidDateException * @@ -119,7 +113,7 @@ public static function nextWorkingDay( * * @return ProviderInterface An instance of class $class is created and returned * - * @throws RuntimeException If no such holiday provider is found + * @throws \RuntimeException If no such holiday provider is found * @throws InvalidYearException if the year parameter is not between the defined lower and upper bounds * @throws UnknownLocaleException if the locale parameter is invalid * @throws ProviderNotFoundException if the holiday provider for the given country does not exist @@ -129,7 +123,7 @@ public static function create(string $class, int $year = self::YEAR_LOWER_BOUND, // Find and return holiday provider instance $providerClass = sprintf('Yasumi\Provider\%s', str_replace('/', '\\', $class)); - if (class_exists($class) && (new ReflectionClass($class))->implementsInterface(ProviderInterface::class)) { + if (class_exists($class) && (new \ReflectionClass($class))->implementsInterface(ProviderInterface::class)) { $providerClass = $class; } @@ -185,8 +179,8 @@ public static function getAvailableLocales(): array * * @return ProviderInterface An instance of class $class is created and returned * - * @throws RuntimeException If no such holiday provider is found - * @throws InvalidArgumentException if the year parameter is not between the defined lower and upper bounds + * @throws \RuntimeException If no such holiday provider is found + * @throws \InvalidArgumentException if the year parameter is not between the defined lower and upper bounds * @throws UnknownLocaleException if the locale parameter is invalid * @throws ProviderNotFoundException if the holiday provider for the given ISO3166-2 code does not exist * @throws \ReflectionException @@ -221,10 +215,10 @@ public static function getProviders(): array } $providers = []; - $filesIterator = new RecursiveIteratorIterator(new RecursiveDirectoryIterator( + $filesIterator = new \RecursiveIteratorIterator(new \RecursiveDirectoryIterator( __DIR__.DIRECTORY_SEPARATOR.'Provider', - FilesystemIterator::SKIP_DOTS - ), RecursiveIteratorIterator::SELF_FIRST); + \FilesystemIterator::SKIP_DOTS + ), \RecursiveIteratorIterator::SELF_FIRST); foreach ($filesIterator as $file) { if ($file->isDir() || 'php' !== $file->getExtension() || \in_array( @@ -238,7 +232,7 @@ public static function getProviders(): array $quotedDs = preg_quote(DIRECTORY_SEPARATOR, ''); $provider = preg_replace("#^.+{$quotedDs}Provider$quotedDs(.+)\\.php$#", '$1', $file->getPathName()); - $class = new ReflectionClass(sprintf('Yasumi\Provider\%s', str_replace('/', '\\', $provider))); + $class = new \ReflectionClass(sprintf('Yasumi\Provider\%s', str_replace('/', '\\', $provider))); $key = 'ID'; if ($class->isSubclassOf(AbstractProvider::class) && $class->hasConstant($key)) { @@ -261,8 +255,8 @@ public static function getProviders(): array * @param int $workingDays Number of days to look back for the (first) previous working day * * @throws UnknownLocaleException - * @throws RuntimeException - * @throws InvalidArgumentException + * @throws \RuntimeException + * @throws \InvalidArgumentException * @throws \Exception * @throws InvalidDateException * diff --git a/tests/Argentina/CarnavalMondayTest.php b/tests/Argentina/CarnavalMondayTest.php index 870ab79be..caa7752a1 100644 --- a/tests/Argentina/CarnavalMondayTest.php +++ b/tests/Argentina/CarnavalMondayTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\Argentina; -use DateInterval; -use Exception; use Yasumi\Holiday; use Yasumi\Provider\ChristianHolidays; use Yasumi\tests\HolidayTestCase; @@ -40,7 +38,7 @@ class CarnavalMondayTest extends ArgentinaBaseTestCase implements HolidayTestCas /** * Tests Carnaval Monday on or after 1700. * - * @throws Exception + * @throws \Exception */ public function testCarnavalMondayAfter1700(): void { @@ -49,14 +47,14 @@ public function testCarnavalMondayAfter1700(): void self::REGION, self::HOLIDAY, $year, - $this->calculateEaster($year, self::TIMEZONE)->sub(new DateInterval('P48D')) + $this->calculateEaster($year, self::TIMEZONE)->sub(new \DateInterval('P48D')) ); } /** * Tests Carnaval Monday on or before 1700. * - * @throws Exception + * @throws \Exception */ public function testCarnavalMondayBefore1700(): void { @@ -67,7 +65,7 @@ public function testCarnavalMondayBefore1700(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -78,7 +76,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Argentina/CarnavalTuesdayTest.php b/tests/Argentina/CarnavalTuesdayTest.php index 25b5b6493..554b34b5f 100644 --- a/tests/Argentina/CarnavalTuesdayTest.php +++ b/tests/Argentina/CarnavalTuesdayTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\Argentina; -use DateInterval; -use Exception; use Yasumi\Holiday; use Yasumi\Provider\ChristianHolidays; use Yasumi\tests\HolidayTestCase; @@ -40,7 +38,7 @@ class CarnavalTuesdayTest extends ArgentinaBaseTestCase implements HolidayTestCa /** * Tests Carnaval Tuesday on or after 1700. * - * @throws Exception + * @throws \Exception */ public function testCarnavalTuesdayAfter1700(): void { @@ -49,14 +47,14 @@ public function testCarnavalTuesdayAfter1700(): void self::REGION, self::HOLIDAY, $year, - $this->calculateEaster($year, self::TIMEZONE)->sub(new DateInterval('P47D')) + $this->calculateEaster($year, self::TIMEZONE)->sub(new \DateInterval('P47D')) ); } /** * Tests Carnaval Tuesday on or before 1700. * - * @throws Exception + * @throws \Exception */ public function testCarnavalTuesdayBefore1700(): void { @@ -67,7 +65,7 @@ public function testCarnavalTuesdayBefore1700(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -78,7 +76,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Argentina/ChristmasDayTest.php b/tests/Argentina/ChristmasDayTest.php index 52070ad1a..be2740f70 100644 --- a/tests/Argentina/ChristmasDayTest.php +++ b/tests/Argentina/ChristmasDayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Argentina; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -33,7 +30,7 @@ class ChristmasDayTest extends ArgentinaBaseTestCase implements HolidayTestCase /** * Tests Christmas Day. * - * @throws Exception + * @throws \Exception */ public function testChristmasDay(): void { @@ -42,14 +39,14 @@ public function testChristmasDay(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-12-25", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-12-25", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -64,7 +61,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Argentina/EasterTest.php b/tests/Argentina/EasterTest.php index e6527630a..c314da7d8 100644 --- a/tests/Argentina/EasterTest.php +++ b/tests/Argentina/EasterTest.php @@ -14,7 +14,6 @@ namespace Yasumi\tests\Argentina; -use Exception; use Yasumi\Holiday; use Yasumi\Provider\ChristianHolidays; use Yasumi\tests\HolidayTestCase; @@ -34,7 +33,7 @@ class EasterTest extends ArgentinaBaseTestCase implements HolidayTestCase /** * Tests Easter. * - * @throws Exception + * @throws \Exception */ public function testEaster(): void { @@ -45,7 +44,7 @@ public function testEaster(): void /** * Tests translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -60,7 +59,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Argentina/FlagDayTest.php b/tests/Argentina/FlagDayTest.php index 861654587..fcb328fa7 100644 --- a/tests/Argentina/FlagDayTest.php +++ b/tests/Argentina/FlagDayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Argentina; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -38,7 +35,7 @@ class FlagDayTest extends ArgentinaBaseTestCase implements HolidayTestCase /** * Tests the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHoliday(): void { @@ -47,7 +44,7 @@ public function testHoliday(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-06-20", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-06-20", new \DateTimeZone(self::TIMEZONE)) ); } @@ -62,7 +59,7 @@ public function testNotHoliday(): void /** * Tests translated name of the holiday. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -77,7 +74,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Argentina/GeneralJoseSanMartinDayTest.php b/tests/Argentina/GeneralJoseSanMartinDayTest.php index d36dfb288..fce46d832 100644 --- a/tests/Argentina/GeneralJoseSanMartinDayTest.php +++ b/tests/Argentina/GeneralJoseSanMartinDayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Argentina; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -38,7 +35,7 @@ class GeneralJoseSanMartinDayTest extends ArgentinaBaseTestCase implements Holid /** * Tests the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHoliday(): void { @@ -47,7 +44,7 @@ public function testHoliday(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-08-17", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-08-17", new \DateTimeZone(self::TIMEZONE)) ); } @@ -62,7 +59,7 @@ public function testNotHoliday(): void /** * Tests translated name of the holiday. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -77,7 +74,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Argentina/GeneralMartinMigueldeGuemesDayTest.php b/tests/Argentina/GeneralMartinMigueldeGuemesDayTest.php index 3202d4e65..bac28e7d8 100644 --- a/tests/Argentina/GeneralMartinMigueldeGuemesDayTest.php +++ b/tests/Argentina/GeneralMartinMigueldeGuemesDayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Argentina; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -38,7 +35,7 @@ class GeneralMartinMigueldeGuemesDayTest extends ArgentinaBaseTestCase implement /** * Tests the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHoliday(): void { @@ -47,7 +44,7 @@ public function testHoliday(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-06-17", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-06-17", new \DateTimeZone(self::TIMEZONE)) ); } @@ -62,7 +59,7 @@ public function testNotHoliday(): void /** * Tests translated name of the holiday. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -77,7 +74,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Argentina/GoodFridayTest.php b/tests/Argentina/GoodFridayTest.php index fbe4b4ea6..e56f86246 100644 --- a/tests/Argentina/GoodFridayTest.php +++ b/tests/Argentina/GoodFridayTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\Argentina; -use DateInterval; -use Exception; use Yasumi\Holiday; use Yasumi\Provider\ChristianHolidays; use Yasumi\tests\HolidayTestCase; @@ -35,7 +33,7 @@ class GoodFridayTest extends ArgentinaBaseTestCase implements HolidayTestCase /** * Tests Good Friday. * - * @throws Exception + * @throws \Exception */ public function testGoodFriday(): void { @@ -44,14 +42,14 @@ public function testGoodFriday(): void self::REGION, self::HOLIDAY, $year, - $this->calculateEaster($year, self::TIMEZONE)->sub(new DateInterval('P2D')) + $this->calculateEaster($year, self::TIMEZONE)->sub(new \DateInterval('P2D')) ); } /** * Tests translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -66,7 +64,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Argentina/ImmaculateConceptionDayTest.php b/tests/Argentina/ImmaculateConceptionDayTest.php index b2693e0b3..dce134fc0 100644 --- a/tests/Argentina/ImmaculateConceptionDayTest.php +++ b/tests/Argentina/ImmaculateConceptionDayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Argentina; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -38,7 +35,7 @@ class ImmaculateConceptionDayTest extends ArgentinaBaseTestCase implements Holid /** * Tests the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHoliday(): void { @@ -47,7 +44,7 @@ public function testHoliday(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-12-08", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-12-08", new \DateTimeZone(self::TIMEZONE)) ); } @@ -62,7 +59,7 @@ public function testNotHoliday(): void /** * Tests translated name of the holiday. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -77,7 +74,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Argentina/IndependenceDayTest.php b/tests/Argentina/IndependenceDayTest.php index 499f58689..da40191ef 100644 --- a/tests/Argentina/IndependenceDayTest.php +++ b/tests/Argentina/IndependenceDayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Argentina; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -38,7 +35,7 @@ class IndependenceDayTest extends ArgentinaBaseTestCase implements HolidayTestCa /** * Tests the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHoliday(): void { @@ -47,7 +44,7 @@ public function testHoliday(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-07-09", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-07-09", new \DateTimeZone(self::TIMEZONE)) ); } @@ -62,7 +59,7 @@ public function testNotHoliday(): void /** * Tests translated name of the holiday. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -77,7 +74,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Argentina/InternationalWorkersDayTest.php b/tests/Argentina/InternationalWorkersDayTest.php index c2e7baf2e..51f2508e1 100644 --- a/tests/Argentina/InternationalWorkersDayTest.php +++ b/tests/Argentina/InternationalWorkersDayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Argentina; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -33,7 +30,7 @@ class InternationalWorkersDayTest extends ArgentinaBaseTestCase implements Holid /** * Tests International Workers' Day. * - * @throws Exception + * @throws \Exception */ public function testInternationalWorkersDay(): void { @@ -42,14 +39,14 @@ public function testInternationalWorkersDay(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-5-1", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-5-1", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -64,7 +61,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Argentina/MalvinasDayTest.php b/tests/Argentina/MalvinasDayTest.php index 14ff33536..7fbb8cdbd 100644 --- a/tests/Argentina/MalvinasDayTest.php +++ b/tests/Argentina/MalvinasDayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Argentina; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -38,7 +35,7 @@ class MalvinasDayTest extends ArgentinaBaseTestCase implements HolidayTestCase /** * Tests the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHoliday(): void { @@ -47,7 +44,7 @@ public function testHoliday(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-04-02", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-04-02", new \DateTimeZone(self::TIMEZONE)) ); } @@ -62,7 +59,7 @@ public function testNotHoliday(): void /** * Tests translated name of Malvinas Day. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -77,7 +74,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Argentina/MayRevolutionTest.php b/tests/Argentina/MayRevolutionTest.php index 5e36faad1..cd6609ce5 100644 --- a/tests/Argentina/MayRevolutionTest.php +++ b/tests/Argentina/MayRevolutionTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Argentina; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -38,7 +35,7 @@ class MayRevolutionTest extends ArgentinaBaseTestCase implements HolidayTestCase /** * Tests the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHoliday(): void { @@ -47,7 +44,7 @@ public function testHoliday(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-05-25", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-05-25", new \DateTimeZone(self::TIMEZONE)) ); } @@ -62,7 +59,7 @@ public function testNotHoliday(): void /** * Tests translated name of First National Government. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -77,7 +74,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Argentina/NationalSovereigntyDayTest.php b/tests/Argentina/NationalSovereigntyDayTest.php index f82a04f92..71fa361ee 100644 --- a/tests/Argentina/NationalSovereigntyDayTest.php +++ b/tests/Argentina/NationalSovereigntyDayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Argentina; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -38,7 +35,7 @@ class NationalSovereigntyDayTest extends ArgentinaBaseTestCase implements Holida /** * Tests the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHoliday(): void { @@ -47,7 +44,7 @@ public function testHoliday(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-11-20", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-11-20", new \DateTimeZone(self::TIMEZONE)) ); } @@ -62,7 +59,7 @@ public function testNotHoliday(): void /** * Tests translated name of the holiday. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -77,7 +74,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Argentina/NewYearsDayTest.php b/tests/Argentina/NewYearsDayTest.php index 0342e37cf..2cf173413 100644 --- a/tests/Argentina/NewYearsDayTest.php +++ b/tests/Argentina/NewYearsDayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Argentina; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -33,7 +30,7 @@ class NewYearsDayTest extends ArgentinaBaseTestCase implements HolidayTestCase /** * Tests New Years Day. * - * @throws Exception + * @throws \Exception */ public function testNewYearsDay(): void { @@ -42,14 +39,14 @@ public function testNewYearsDay(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-1-1", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-1-1", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -64,7 +61,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Argentina/RaceDayTest.php b/tests/Argentina/RaceDayTest.php index be28f4d75..a90775ecd 100644 --- a/tests/Argentina/RaceDayTest.php +++ b/tests/Argentina/RaceDayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Argentina; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -38,7 +35,7 @@ class RaceDayTest extends ArgentinaBaseTestCase implements HolidayTestCase /** * Tests the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHoliday(): void { @@ -47,7 +44,7 @@ public function testHoliday(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-10-12", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-10-12", new \DateTimeZone(self::TIMEZONE)) ); } @@ -62,7 +59,7 @@ public function testNotHoliday(): void /** * Tests translated name of the holiday. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -77,7 +74,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Argentina/RemembranceDayTest.php b/tests/Argentina/RemembranceDayTest.php index e414dfaca..a51be27a6 100644 --- a/tests/Argentina/RemembranceDayTest.php +++ b/tests/Argentina/RemembranceDayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Argentina; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -38,7 +35,7 @@ class RemembranceDayTest extends ArgentinaBaseTestCase implements HolidayTestCas /** * Tests Day of Remembrance for Truth and Justice on or after 2006. * - * @throws Exception + * @throws \Exception */ public function testRemembranceDayAfter2006(): void { @@ -47,14 +44,14 @@ public function testRemembranceDayAfter2006(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-03-24", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-03-24", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests Day of Remembrance for Truth and Justice on or before 2006. * - * @throws Exception + * @throws \Exception */ public function testRemembranceDayBefore2006(): void { @@ -65,7 +62,7 @@ public function testRemembranceDayBefore2006(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -76,7 +73,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Australia/AnzacDayTest.php b/tests/Australia/AnzacDayTest.php index 5df42057b..4aabf25c8 100644 --- a/tests/Australia/AnzacDayTest.php +++ b/tests/Australia/AnzacDayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Australia; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -43,7 +40,7 @@ class AnzacDayTest extends AustraliaBaseTestCase implements HolidayTestCase * @param int $year the year for which the holiday defined in this test needs to be tested * @param string $expected the expected date * - * @throws Exception + * @throws \Exception */ public function testHoliday(int $year, string $expected): void { @@ -51,7 +48,7 @@ public function testHoliday(int $year, string $expected): void $this->region, self::HOLIDAY, $year, - new DateTime($expected, new DateTimeZone($this->timezone)) + new \DateTime($expected, new \DateTimeZone($this->timezone)) ); } @@ -89,7 +86,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -104,7 +101,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Australia/AustraliaDayTest.php b/tests/Australia/AustraliaDayTest.php index e07497ee0..56196bc4f 100644 --- a/tests/Australia/AustraliaDayTest.php +++ b/tests/Australia/AustraliaDayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Australia; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -35,8 +32,8 @@ class AustraliaDayTest extends AustraliaBaseTestCase implements HolidayTestCase * * @dataProvider HolidayDataProvider * - * @param int $year the year for which the holiday defined in this test needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which the holiday defined in this test needs to be tested + * @param \DateTime $expected the expected date */ public function testHoliday(int $year, \DateTimeInterface $expected): void { @@ -51,7 +48,7 @@ public function testHoliday(int $year, \DateTimeInterface $expected): void * @param int $year the year for which the holiday defined in this test needs to be tested * @param ?string $expected the expected date * - * @throws Exception + * @throws \Exception */ public function testSubstituteHoliday(int $year, ?string $expected): void { @@ -60,7 +57,7 @@ public function testSubstituteHoliday(int $year, ?string $expected): void $this->region, self::HOLIDAY, $year, - new DateTime($expected, new DateTimeZone($this->timezone)) + new \DateTime($expected, new \DateTimeZone($this->timezone)) ); } else { $this->assertNotSubstituteHoliday( @@ -74,7 +71,7 @@ public function testSubstituteHoliday(int $year, ?string $expected): void /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -89,7 +86,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { @@ -101,7 +98,7 @@ public function testHolidayType(): void * * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function HolidayDataProvider(): array { diff --git a/tests/Australia/AustraliaTest.php b/tests/Australia/AustraliaTest.php index 18e86b074..6717418ef 100644 --- a/tests/Australia/AustraliaTest.php +++ b/tests/Australia/AustraliaTest.php @@ -14,7 +14,6 @@ namespace Yasumi\tests\Australia; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\ProviderTestCase; @@ -87,7 +86,7 @@ public function testOtherHolidays(): void } /** - * @throws ReflectionException + * @throws \ReflectionException * @throws \Exception */ public function testSources(): void diff --git a/tests/Australia/AustralianCapitalTerritory/AustralianCapitalTerritoryTest.php b/tests/Australia/AustralianCapitalTerritory/AustralianCapitalTerritoryTest.php index 472d01650..f892b3802 100644 --- a/tests/Australia/AustralianCapitalTerritory/AustralianCapitalTerritoryTest.php +++ b/tests/Australia/AustralianCapitalTerritory/AustralianCapitalTerritoryTest.php @@ -14,7 +14,6 @@ namespace Yasumi\tests\Australia\AustralianCapitalTerritory; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\ProviderTestCase; @@ -61,7 +60,7 @@ public function testOfficialHolidays(): void } /** - * @throws ReflectionException + * @throws \ReflectionException * @throws \Exception */ public function testSources(): void diff --git a/tests/Australia/AustralianCapitalTerritory/CanberraDayTest.php b/tests/Australia/AustralianCapitalTerritory/CanberraDayTest.php index 615b8e7e4..ef5e279dc 100644 --- a/tests/Australia/AustralianCapitalTerritory/CanberraDayTest.php +++ b/tests/Australia/AustralianCapitalTerritory/CanberraDayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Australia\AustralianCapitalTerritory; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -43,7 +40,7 @@ class CanberraDayTest extends AustralianCapitalTerritoryBaseTestCase implements * @param int $year the year for which the holiday defined in this test needs to be tested * @param string $expected the expected date * - * @throws Exception + * @throws \Exception */ public function testHoliday(int $year, string $expected): void { @@ -51,7 +48,7 @@ public function testHoliday(int $year, string $expected): void $this->region, self::HOLIDAY, $year, - new DateTime($expected, new DateTimeZone($this->timezone)) + new \DateTime($expected, new \DateTimeZone($this->timezone)) ); } @@ -80,7 +77,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -95,7 +92,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Australia/AustralianCapitalTerritory/EasterSaturdayTest.php b/tests/Australia/AustralianCapitalTerritory/EasterSaturdayTest.php index 27ab89783..3edcf4cf3 100644 --- a/tests/Australia/AustralianCapitalTerritory/EasterSaturdayTest.php +++ b/tests/Australia/AustralianCapitalTerritory/EasterSaturdayTest.php @@ -14,10 +14,6 @@ namespace Yasumi\tests\Australia\AustralianCapitalTerritory; -use DateInterval; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -39,7 +35,7 @@ class EasterSaturdayTest extends AustralianCapitalTerritoryBaseTestCase implemen * @param int $year the year for which the holiday defined in this test needs to be tested * @param string $expected the expected date * - * @throws Exception + * @throws \Exception */ public function testHoliday(int $year, string $expected): void { @@ -47,7 +43,7 @@ public function testHoliday(int $year, string $expected): void $this->region, self::HOLIDAY, $year, - new DateTime($expected, new DateTimeZone($this->timezone)) + new \DateTime($expected, new \DateTimeZone($this->timezone)) ); } @@ -56,7 +52,7 @@ public function testHoliday(int $year, string $expected): void * * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function HolidayDataProvider(): array { @@ -65,7 +61,7 @@ public function HolidayDataProvider(): array for ($y = 0; $y < 50; ++$y) { $year = $this->generateRandomYear(); $date = $this->calculateEaster($year, $this->timezone); - $date->sub(new DateInterval('P1D')); + $date->sub(new \DateInterval('P1D')); $data[] = [$year, $date->format('Y-m-d')]; } @@ -76,7 +72,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -91,7 +87,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Australia/AustralianCapitalTerritory/EasterSundayTest.php b/tests/Australia/AustralianCapitalTerritory/EasterSundayTest.php index 2dd6297a7..fa663bd4d 100644 --- a/tests/Australia/AustralianCapitalTerritory/EasterSundayTest.php +++ b/tests/Australia/AustralianCapitalTerritory/EasterSundayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Australia\AustralianCapitalTerritory; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -38,7 +35,7 @@ class EasterSundayTest extends AustralianCapitalTerritoryBaseTestCase implements * @param int $year the year for which the holiday defined in this test needs to be tested * @param string $expected the expected date * - * @throws Exception + * @throws \Exception */ public function testHoliday(int $year, string $expected): void { @@ -46,7 +43,7 @@ public function testHoliday(int $year, string $expected): void $this->region, self::HOLIDAY, $year, - new DateTime($expected, new DateTimeZone($this->timezone)) + new \DateTime($expected, new \DateTimeZone($this->timezone)) ); } @@ -55,7 +52,7 @@ public function testHoliday(int $year, string $expected): void * * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function HolidayDataProvider(): array { @@ -74,7 +71,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -89,7 +86,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Australia/AustralianCapitalTerritory/LabourDayTest.php b/tests/Australia/AustralianCapitalTerritory/LabourDayTest.php index bc3c02249..73f62a89a 100644 --- a/tests/Australia/AustralianCapitalTerritory/LabourDayTest.php +++ b/tests/Australia/AustralianCapitalTerritory/LabourDayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Australia\AustralianCapitalTerritory; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -38,7 +35,7 @@ class LabourDayTest extends AustralianCapitalTerritoryBaseTestCase implements Ho * @param int $year the year for which the holiday defined in this test needs to be tested * @param string $expected the expected date * - * @throws Exception + * @throws \Exception */ public function testHoliday(int $year, string $expected): void { @@ -46,7 +43,7 @@ public function testHoliday(int $year, string $expected): void $this->region, self::HOLIDAY, $year, - new DateTime($expected, new DateTimeZone($this->timezone)) + new \DateTime($expected, new \DateTimeZone($this->timezone)) ); } @@ -75,7 +72,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -90,7 +87,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Australia/AustralianCapitalTerritory/QueensBirthdayTest.php b/tests/Australia/AustralianCapitalTerritory/QueensBirthdayTest.php index e8606351b..30633a46a 100644 --- a/tests/Australia/AustralianCapitalTerritory/QueensBirthdayTest.php +++ b/tests/Australia/AustralianCapitalTerritory/QueensBirthdayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Australia\AustralianCapitalTerritory; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -43,7 +40,7 @@ class QueensBirthdayTest extends AustralianCapitalTerritoryBaseTestCase implemen * @param int $year the year for which the holiday defined in this test needs to be tested * @param string $expected the expected date * - * @throws Exception + * @throws \Exception */ public function testHoliday(int $year, string $expected): void { @@ -51,7 +48,7 @@ public function testHoliday(int $year, string $expected): void $this->region, self::HOLIDAY, $year, - new DateTime($expected, new DateTimeZone($this->timezone)) + new \DateTime($expected, new \DateTimeZone($this->timezone)) ); } @@ -80,7 +77,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -95,7 +92,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Australia/AustralianCapitalTerritory/ReconciliationDayTest.php b/tests/Australia/AustralianCapitalTerritory/ReconciliationDayTest.php index 01e16ff53..104a46055 100644 --- a/tests/Australia/AustralianCapitalTerritory/ReconciliationDayTest.php +++ b/tests/Australia/AustralianCapitalTerritory/ReconciliationDayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Australia\AustralianCapitalTerritory; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -43,7 +40,7 @@ class ReconciliationDayTest extends AustralianCapitalTerritoryBaseTestCase imple * @param int $year the year for which the holiday defined in this test needs to be tested * @param string $expected the expected date * - * @throws Exception + * @throws \Exception */ public function testHoliday(int $year, string $expected): void { @@ -51,7 +48,7 @@ public function testHoliday(int $year, string $expected): void $this->region, self::HOLIDAY, $year, - new DateTime($expected, new DateTimeZone($this->timezone)) + new \DateTime($expected, new \DateTimeZone($this->timezone)) ); } @@ -82,7 +79,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -97,7 +94,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Australia/BoxingDayTest.php b/tests/Australia/BoxingDayTest.php index 3757db122..04c2e7671 100644 --- a/tests/Australia/BoxingDayTest.php +++ b/tests/Australia/BoxingDayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Australia; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -40,7 +37,7 @@ class BoxingDayTest extends AustraliaBaseTestCase implements HolidayTestCase * @param string $expected the expected date * @param ?string $expectedExtra the expected date for the additional holiday, or null if no additional holiday * - * @throws Exception + * @throws \Exception */ public function testHoliday(int $year, string $expected, ?string $expectedExtra): void { @@ -48,7 +45,7 @@ public function testHoliday(int $year, string $expected, ?string $expectedExtra) $this->region, self::HOLIDAY, $year, - new DateTime($expected, new DateTimeZone($this->timezone)) + new \DateTime($expected, new \DateTimeZone($this->timezone)) ); if (null === $expectedExtra) { $this->assertNotHoliday( @@ -61,7 +58,7 @@ public function testHoliday(int $year, string $expected, ?string $expectedExtra) $this->region, self::HOLIDAY2, $year, - new DateTime($expectedExtra, new DateTimeZone($this->timezone)) + new \DateTime($expectedExtra, new \DateTimeZone($this->timezone)) ); } } @@ -91,7 +88,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -112,7 +109,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Australia/ChristmasDayTest.php b/tests/Australia/ChristmasDayTest.php index 2badfcd37..be22ddfe0 100644 --- a/tests/Australia/ChristmasDayTest.php +++ b/tests/Australia/ChristmasDayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Australia; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -40,7 +37,7 @@ class ChristmasDayTest extends AustraliaBaseTestCase implements HolidayTestCase * @param string $expected the expected date * @param ?string $expectedExtra the expected date for the additional holiday, or null if no additional holiday * - * @throws Exception + * @throws \Exception */ public function testHoliday(int $year, string $expected, ?string $expectedExtra): void { @@ -48,7 +45,7 @@ public function testHoliday(int $year, string $expected, ?string $expectedExtra) $this->region, self::HOLIDAY, $year, - new DateTime($expected, new DateTimeZone($this->timezone)) + new \DateTime($expected, new \DateTimeZone($this->timezone)) ); if (null === $expectedExtra) { $this->assertNotHoliday( @@ -61,7 +58,7 @@ public function testHoliday(int $year, string $expected, ?string $expectedExtra) $this->region, self::HOLIDAY2, $year, - new DateTime($expectedExtra, new DateTimeZone($this->timezone)) + new \DateTime($expectedExtra, new \DateTimeZone($this->timezone)) ); } } @@ -91,7 +88,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -112,7 +109,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Australia/EasterMondayTest.php b/tests/Australia/EasterMondayTest.php index 18088f406..e0e220e47 100644 --- a/tests/Australia/EasterMondayTest.php +++ b/tests/Australia/EasterMondayTest.php @@ -14,10 +14,6 @@ namespace Yasumi\tests\Australia; -use DateInterval; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -40,7 +36,7 @@ class EasterMondayTest extends AustraliaBaseTestCase implements HolidayTestCase * @param int $year the year for which the holiday defined in this test needs to be tested * @param string $expected the expected date * - * @throws Exception + * @throws \Exception */ public function testHoliday(int $year, string $expected): void { @@ -48,7 +44,7 @@ public function testHoliday(int $year, string $expected): void $this->region, self::HOLIDAY, $year, - new DateTime($expected, new DateTimeZone($this->timezone)) + new \DateTime($expected, new \DateTimeZone($this->timezone)) ); } @@ -60,7 +56,7 @@ public function testHoliday(int $year, string $expected): void * @param int $year the year for which the holiday defined in this test needs to be tested * @param string $expected the expected date * - * @throws Exception + * @throws \Exception */ public function testHoliday2(int $year, string $expected): void { @@ -68,7 +64,7 @@ public function testHoliday2(int $year, string $expected): void $this->region, self::HOLIDAY2, $year, - new DateTime($expected, new DateTimeZone($this->timezone)) + new \DateTime($expected, new \DateTimeZone($this->timezone)) ); } @@ -77,7 +73,7 @@ public function testHoliday2(int $year, string $expected): void * * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function HolidayDataProvider(): array { @@ -86,7 +82,7 @@ public function HolidayDataProvider(): array for ($y = 0; $y < 50; ++$y) { $year = $this->generateRandomYear(); $date = $this->calculateEaster($year, $this->timezone); - $date->add(new DateInterval('P1D')); + $date->add(new \DateInterval('P1D')); $data[] = [$year, $date->format('Y-m-d')]; } @@ -112,7 +108,7 @@ public function HolidayDataProvider2(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -133,7 +129,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Australia/GoodFridayTest.php b/tests/Australia/GoodFridayTest.php index f2ad138b6..ca05452b8 100644 --- a/tests/Australia/GoodFridayTest.php +++ b/tests/Australia/GoodFridayTest.php @@ -14,10 +14,6 @@ namespace Yasumi\tests\Australia; -use DateInterval; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -39,7 +35,7 @@ class GoodFridayTest extends AustraliaBaseTestCase implements HolidayTestCase * @param int $year the year for which the holiday defined in this test needs to be tested * @param string $expected the expected date * - * @throws Exception + * @throws \Exception */ public function testHoliday(int $year, string $expected): void { @@ -47,7 +43,7 @@ public function testHoliday(int $year, string $expected): void $this->region, self::HOLIDAY, $year, - new DateTime($expected, new DateTimeZone($this->timezone)) + new \DateTime($expected, new \DateTimeZone($this->timezone)) ); } @@ -56,7 +52,7 @@ public function testHoliday(int $year, string $expected): void * * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function HolidayDataProvider(): array { @@ -65,7 +61,7 @@ public function HolidayDataProvider(): array for ($y = 0; $y < 50; ++$y) { $year = $this->generateRandomYear(); $date = $this->calculateEaster($year, $this->timezone); - $date->sub(new DateInterval('P2D')); + $date->sub(new \DateInterval('P2D')); $data[] = [$year, $date->format('Y-m-d')]; } @@ -75,7 +71,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -90,7 +86,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Australia/NewSouthWales/BankHolidayTest.php b/tests/Australia/NewSouthWales/BankHolidayTest.php index 4fb19326d..e092439da 100644 --- a/tests/Australia/NewSouthWales/BankHolidayTest.php +++ b/tests/Australia/NewSouthWales/BankHolidayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Australia\NewSouthWales; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -38,7 +35,7 @@ class BankHolidayTest extends NewSouthWalesBaseTestCase implements HolidayTestCa * @param int $year the year for which the holiday defined in this test needs to be tested * @param string $expected the expected date * - * @throws Exception + * @throws \Exception */ public function testHoliday(int $year, string $expected): void { @@ -46,7 +43,7 @@ public function testHoliday(int $year, string $expected): void $this->region, self::HOLIDAY, $year, - new DateTime($expected, new DateTimeZone($this->timezone)) + new \DateTime($expected, new \DateTimeZone($this->timezone)) ); } @@ -75,7 +72,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -90,7 +87,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Australia/NewSouthWales/EasterSaturdayTest.php b/tests/Australia/NewSouthWales/EasterSaturdayTest.php index cfb4040e8..ad6a09350 100644 --- a/tests/Australia/NewSouthWales/EasterSaturdayTest.php +++ b/tests/Australia/NewSouthWales/EasterSaturdayTest.php @@ -14,10 +14,6 @@ namespace Yasumi\tests\Australia\NewSouthWales; -use DateInterval; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -39,7 +35,7 @@ class EasterSaturdayTest extends NewSouthWalesBaseTestCase implements HolidayTes * @param int $year the year for which the holiday defined in this test needs to be tested * @param string $expected the expected date * - * @throws Exception + * @throws \Exception */ public function testHoliday(int $year, string $expected): void { @@ -47,7 +43,7 @@ public function testHoliday(int $year, string $expected): void $this->region, self::HOLIDAY, $year, - new DateTime($expected, new DateTimeZone($this->timezone)) + new \DateTime($expected, new \DateTimeZone($this->timezone)) ); } @@ -56,7 +52,7 @@ public function testHoliday(int $year, string $expected): void * * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function HolidayDataProvider(): array { @@ -65,7 +61,7 @@ public function HolidayDataProvider(): array for ($y = 0; $y < 50; ++$y) { $year = $this->generateRandomYear(); $date = $this->calculateEaster($year, $this->timezone); - $date->sub(new DateInterval('P1D')); + $date->sub(new \DateInterval('P1D')); $data[] = [$year, $date->format('Y-m-d')]; } @@ -76,7 +72,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -91,7 +87,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Australia/NewSouthWales/EasterSundayTest.php b/tests/Australia/NewSouthWales/EasterSundayTest.php index 8bbc5d25a..42d2af2a7 100644 --- a/tests/Australia/NewSouthWales/EasterSundayTest.php +++ b/tests/Australia/NewSouthWales/EasterSundayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Australia\NewSouthWales; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -38,7 +35,7 @@ class EasterSundayTest extends NewSouthWalesBaseTestCase implements HolidayTestC * @param int $year the year for which the holiday defined in this test needs to be tested * @param string $expected the expected date * - * @throws Exception + * @throws \Exception */ public function testHoliday(int $year, string $expected): void { @@ -46,7 +43,7 @@ public function testHoliday(int $year, string $expected): void $this->region, self::HOLIDAY, $year, - new DateTime($expected, new DateTimeZone($this->timezone)) + new \DateTime($expected, new \DateTimeZone($this->timezone)) ); } @@ -55,7 +52,7 @@ public function testHoliday(int $year, string $expected): void * * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function HolidayDataProvider(): array { @@ -74,7 +71,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -89,7 +86,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Australia/NewSouthWales/LabourDayTest.php b/tests/Australia/NewSouthWales/LabourDayTest.php index 0a678ee10..eecc817e1 100644 --- a/tests/Australia/NewSouthWales/LabourDayTest.php +++ b/tests/Australia/NewSouthWales/LabourDayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Australia\NewSouthWales; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -38,7 +35,7 @@ class LabourDayTest extends NewSouthWalesBaseTestCase implements HolidayTestCase * @param int $year the year for which the holiday defined in this test needs to be tested * @param string $expected the expected date * - * @throws Exception + * @throws \Exception */ public function testHoliday(int $year, string $expected): void { @@ -46,7 +43,7 @@ public function testHoliday(int $year, string $expected): void $this->region, self::HOLIDAY, $year, - new DateTime($expected, new DateTimeZone($this->timezone)) + new \DateTime($expected, new \DateTimeZone($this->timezone)) ); } @@ -75,7 +72,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -90,7 +87,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Australia/NewSouthWales/NewSouthWalesTest.php b/tests/Australia/NewSouthWales/NewSouthWalesTest.php index 0249ebbf4..85b790a86 100644 --- a/tests/Australia/NewSouthWales/NewSouthWalesTest.php +++ b/tests/Australia/NewSouthWales/NewSouthWalesTest.php @@ -14,7 +14,6 @@ namespace Yasumi\tests\Australia\NewSouthWales; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\ProviderTestCase; @@ -69,7 +68,7 @@ public function testBankHolidays(): void } /** - * @throws ReflectionException + * @throws \ReflectionException * @throws \Exception */ public function testSources(): void diff --git a/tests/Australia/NewSouthWales/QueensBirthdayTest.php b/tests/Australia/NewSouthWales/QueensBirthdayTest.php index 81bee578b..99b01821d 100644 --- a/tests/Australia/NewSouthWales/QueensBirthdayTest.php +++ b/tests/Australia/NewSouthWales/QueensBirthdayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Australia\NewSouthWales; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -43,7 +40,7 @@ class QueensBirthdayTest extends NewSouthWalesBaseTestCase implements HolidayTes * @param int $year the year for which the holiday defined in this test needs to be tested * @param string $expected the expected date * - * @throws Exception + * @throws \Exception */ public function testHoliday(int $year, string $expected): void { @@ -51,7 +48,7 @@ public function testHoliday(int $year, string $expected): void $this->region, self::HOLIDAY, $year, - new DateTime($expected, new DateTimeZone($this->timezone)) + new \DateTime($expected, new \DateTimeZone($this->timezone)) ); } @@ -80,7 +77,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -95,7 +92,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Australia/NewYearsDayTest.php b/tests/Australia/NewYearsDayTest.php index f36800828..e210d9997 100644 --- a/tests/Australia/NewYearsDayTest.php +++ b/tests/Australia/NewYearsDayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Australia; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -40,7 +37,7 @@ class NewYearsDayTest extends AustraliaBaseTestCase implements HolidayTestCase * @param string $expected the expected date * @param ?string $expectedExtra the expected date for the additional holiday, or null if no additional holiday * - * @throws Exception + * @throws \Exception */ public function testHoliday(int $year, string $expected, ?string $expectedExtra): void { @@ -48,7 +45,7 @@ public function testHoliday(int $year, string $expected, ?string $expectedExtra) $this->region, self::HOLIDAY, $year, - new DateTime($expected, new DateTimeZone($this->timezone)) + new \DateTime($expected, new \DateTimeZone($this->timezone)) ); if (null === $expectedExtra) { $this->assertNotHoliday( @@ -61,7 +58,7 @@ public function testHoliday(int $year, string $expected, ?string $expectedExtra) $this->region, self::HOLIDAY2, $year, - new DateTime($expectedExtra, new DateTimeZone($this->timezone)) + new \DateTime($expectedExtra, new \DateTimeZone($this->timezone)) ); } } @@ -91,7 +88,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -112,7 +109,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Australia/NorthernTerritory/EasterSaturdayTest.php b/tests/Australia/NorthernTerritory/EasterSaturdayTest.php index 4c164251d..6aa3670c6 100644 --- a/tests/Australia/NorthernTerritory/EasterSaturdayTest.php +++ b/tests/Australia/NorthernTerritory/EasterSaturdayTest.php @@ -14,10 +14,6 @@ namespace Yasumi\tests\Australia\NorthernTerritory; -use DateInterval; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -39,7 +35,7 @@ class EasterSaturdayTest extends NorthernTerritoryBaseTestCase implements Holida * @param int $year the year for which the holiday defined in this test needs to be tested * @param string $expected the expected date * - * @throws Exception + * @throws \Exception */ public function testHoliday(int $year, string $expected): void { @@ -47,7 +43,7 @@ public function testHoliday(int $year, string $expected): void $this->region, self::HOLIDAY, $year, - new DateTime($expected, new DateTimeZone($this->timezone)) + new \DateTime($expected, new \DateTimeZone($this->timezone)) ); } @@ -56,7 +52,7 @@ public function testHoliday(int $year, string $expected): void * * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function HolidayDataProvider(): array { @@ -65,7 +61,7 @@ public function HolidayDataProvider(): array for ($y = 0; $y < 50; ++$y) { $year = $this->generateRandomYear(); $date = $this->calculateEaster($year, $this->timezone); - $date->sub(new DateInterval('P1D')); + $date->sub(new \DateInterval('P1D')); $data[] = [$year, $date->format('Y-m-d')]; } @@ -76,7 +72,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -91,7 +87,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Australia/NorthernTerritory/MayDayTest.php b/tests/Australia/NorthernTerritory/MayDayTest.php index 8b5675c44..f08334f73 100644 --- a/tests/Australia/NorthernTerritory/MayDayTest.php +++ b/tests/Australia/NorthernTerritory/MayDayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Australia\NorthernTerritory; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -38,7 +35,7 @@ class MayDayTest extends NorthernTerritoryBaseTestCase implements HolidayTestCas * @param int $year the year for which the holiday defined in this test needs to be tested * @param string $expected the expected date * - * @throws Exception + * @throws \Exception */ public function testHoliday(int $year, string $expected): void { @@ -46,7 +43,7 @@ public function testHoliday(int $year, string $expected): void $this->region, self::HOLIDAY, $year, - new DateTime($expected, new DateTimeZone($this->timezone)) + new \DateTime($expected, new \DateTimeZone($this->timezone)) ); } @@ -75,7 +72,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -90,7 +87,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Australia/NorthernTerritory/NorthernTerritoryTest.php b/tests/Australia/NorthernTerritory/NorthernTerritoryTest.php index cbe17acf8..86b91e69c 100644 --- a/tests/Australia/NorthernTerritory/NorthernTerritoryTest.php +++ b/tests/Australia/NorthernTerritory/NorthernTerritoryTest.php @@ -14,7 +14,6 @@ namespace Yasumi\tests\Australia\NorthernTerritory; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\ProviderTestCase; @@ -59,7 +58,7 @@ public function testOfficialHolidays(): void } /** - * @throws ReflectionException + * @throws \ReflectionException * @throws \Exception */ public function testSources(): void diff --git a/tests/Australia/NorthernTerritory/PicnicDayTest.php b/tests/Australia/NorthernTerritory/PicnicDayTest.php index fef8e3bb2..bebd59c26 100644 --- a/tests/Australia/NorthernTerritory/PicnicDayTest.php +++ b/tests/Australia/NorthernTerritory/PicnicDayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Australia\NorthernTerritory; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -38,7 +35,7 @@ class PicnicDayTest extends NorthernTerritoryBaseTestCase implements HolidayTest * @param int $year the year for which the holiday defined in this test needs to be tested * @param string $expected the expected date * - * @throws Exception + * @throws \Exception */ public function testHoliday(int $year, string $expected): void { @@ -46,7 +43,7 @@ public function testHoliday(int $year, string $expected): void $this->region, self::HOLIDAY, $year, - new DateTime($expected, new DateTimeZone($this->timezone)) + new \DateTime($expected, new \DateTimeZone($this->timezone)) ); } @@ -75,7 +72,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -90,7 +87,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Australia/NorthernTerritory/QueensBirthdayTest.php b/tests/Australia/NorthernTerritory/QueensBirthdayTest.php index f31e35f1a..d491d8c11 100644 --- a/tests/Australia/NorthernTerritory/QueensBirthdayTest.php +++ b/tests/Australia/NorthernTerritory/QueensBirthdayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Australia\NorthernTerritory; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -43,7 +40,7 @@ class QueensBirthdayTest extends NorthernTerritoryBaseTestCase implements Holida * @param int $year the year for which the holiday defined in this test needs to be tested * @param string $expected the expected date * - * @throws Exception + * @throws \Exception */ public function testHoliday(int $year, string $expected): void { @@ -51,7 +48,7 @@ public function testHoliday(int $year, string $expected): void $this->region, self::HOLIDAY, $year, - new DateTime($expected, new DateTimeZone($this->timezone)) + new \DateTime($expected, new \DateTimeZone($this->timezone)) ); } @@ -80,7 +77,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -95,7 +92,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Australia/Queensland/Brisbane/BrisbaneTest.php b/tests/Australia/Queensland/Brisbane/BrisbaneTest.php index 1d0c17ad0..dcfc4088d 100644 --- a/tests/Australia/Queensland/Brisbane/BrisbaneTest.php +++ b/tests/Australia/Queensland/Brisbane/BrisbaneTest.php @@ -14,7 +14,6 @@ namespace Yasumi\tests\Australia\Queensland\Brisbane; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\ProviderTestCase; @@ -58,7 +57,7 @@ public function testOfficialHolidays(): void } /** - * @throws ReflectionException + * @throws \ReflectionException * @throws \Exception */ public function testSources(): void diff --git a/tests/Australia/Queensland/Brisbane/PeoplesDayTest.php b/tests/Australia/Queensland/Brisbane/PeoplesDayTest.php index 89af7c121..33cdcac03 100644 --- a/tests/Australia/Queensland/Brisbane/PeoplesDayTest.php +++ b/tests/Australia/Queensland/Brisbane/PeoplesDayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Australia\Queensland\Brisbane; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -38,7 +35,7 @@ class PeoplesDayTest extends BrisbaneBaseTestCase implements HolidayTestCase * @param int $year the year for which the holiday defined in this test needs to be tested * @param string $expected the expected date * - * @throws Exception + * @throws \Exception */ public function testHoliday(int $year, string $expected): void { @@ -46,7 +43,7 @@ public function testHoliday(int $year, string $expected): void $this->region, self::HOLIDAY, $year, - new DateTime($expected, new DateTimeZone($this->timezone)) + new \DateTime($expected, new \DateTimeZone($this->timezone)) ); } @@ -75,7 +72,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -90,7 +87,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Australia/Queensland/LabourDayTest.php b/tests/Australia/Queensland/LabourDayTest.php index a9d0177f9..e26dd3440 100644 --- a/tests/Australia/Queensland/LabourDayTest.php +++ b/tests/Australia/Queensland/LabourDayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Australia\Queensland; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -38,7 +35,7 @@ class LabourDayTest extends QueenslandBaseTestCase implements HolidayTestCase * @param int $year the year for which the holiday defined in this test needs to be tested * @param string $expected the expected date * - * @throws Exception + * @throws \Exception */ public function testHoliday(int $year, string $expected): void { @@ -46,7 +43,7 @@ public function testHoliday(int $year, string $expected): void $this->region, self::HOLIDAY, $year, - new DateTime($expected, new DateTimeZone($this->timezone)) + new \DateTime($expected, new \DateTimeZone($this->timezone)) ); } @@ -75,7 +72,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -90,7 +87,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Australia/Queensland/QueensBirthdayTest.php b/tests/Australia/Queensland/QueensBirthdayTest.php index 15d02035c..bce38d08b 100644 --- a/tests/Australia/Queensland/QueensBirthdayTest.php +++ b/tests/Australia/Queensland/QueensBirthdayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Australia\Queensland; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -43,7 +40,7 @@ class QueensBirthdayTest extends QueenslandBaseTestCase implements HolidayTestCa * @param int $year the year for which the holiday defined in this test needs to be tested * @param string $expected the expected date * - * @throws Exception + * @throws \Exception */ public function testHoliday(int $year, string $expected): void { @@ -51,7 +48,7 @@ public function testHoliday(int $year, string $expected): void $this->region, self::HOLIDAY, $year, - new DateTime($expected, new DateTimeZone($this->timezone)) + new \DateTime($expected, new \DateTimeZone($this->timezone)) ); } @@ -80,7 +77,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -95,7 +92,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Australia/Queensland/QueenslandTest.php b/tests/Australia/Queensland/QueenslandTest.php index 393a32b99..fd5a2a6ab 100644 --- a/tests/Australia/Queensland/QueenslandTest.php +++ b/tests/Australia/Queensland/QueenslandTest.php @@ -14,7 +14,6 @@ namespace Yasumi\tests\Australia\Queensland; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\ProviderTestCase; @@ -57,7 +56,7 @@ public function testOfficialHolidays(): void } /** - * @throws ReflectionException + * @throws \ReflectionException * @throws \Exception */ public function testSources(): void diff --git a/tests/Australia/SouthAustralia/AdelaideCupDayTest.php b/tests/Australia/SouthAustralia/AdelaideCupDayTest.php index 3d4d768bd..98d37038c 100644 --- a/tests/Australia/SouthAustralia/AdelaideCupDayTest.php +++ b/tests/Australia/SouthAustralia/AdelaideCupDayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Australia\SouthAustralia; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -43,7 +40,7 @@ class AdelaideCupDayTest extends SouthAustraliaBaseTestCase implements HolidayTe * @param int $year the year for which the holiday defined in this test needs to be tested * @param string $expected the expected date * - * @throws Exception + * @throws \Exception */ public function testHoliday(int $year, string $expected): void { @@ -51,7 +48,7 @@ public function testHoliday(int $year, string $expected): void $this->region, self::HOLIDAY, $year, - new DateTime($expected, new DateTimeZone($this->timezone)) + new \DateTime($expected, new \DateTimeZone($this->timezone)) ); } @@ -90,7 +87,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -105,7 +102,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Australia/SouthAustralia/ChristmasDayTest.php b/tests/Australia/SouthAustralia/ChristmasDayTest.php index 9514d2089..0d1cdbe70 100644 --- a/tests/Australia/SouthAustralia/ChristmasDayTest.php +++ b/tests/Australia/SouthAustralia/ChristmasDayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Australia\SouthAustralia; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -40,7 +37,7 @@ class ChristmasDayTest extends SouthAustraliaBaseTestCase implements HolidayTest * @param string $expected the expected date * @param ?string $expectedExtra the expected date for the additional holiday, or null if no additional holiday * - * @throws Exception + * @throws \Exception */ public function testHoliday(int $year, string $expected, ?string $expectedExtra): void { @@ -48,7 +45,7 @@ public function testHoliday(int $year, string $expected, ?string $expectedExtra) $this->region, self::HOLIDAY, $year, - new DateTime($expected, new DateTimeZone($this->timezone)) + new \DateTime($expected, new \DateTimeZone($this->timezone)) ); if (null === $expectedExtra) { $this->assertNotHoliday( @@ -61,7 +58,7 @@ public function testHoliday(int $year, string $expected, ?string $expectedExtra) $this->region, self::HOLIDAY2, $year, - new DateTime($expectedExtra, new DateTimeZone($this->timezone)) + new \DateTime($expectedExtra, new \DateTimeZone($this->timezone)) ); } } @@ -91,7 +88,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -112,7 +109,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Australia/SouthAustralia/EasterSaturdayTest.php b/tests/Australia/SouthAustralia/EasterSaturdayTest.php index d19049985..6770adb7e 100644 --- a/tests/Australia/SouthAustralia/EasterSaturdayTest.php +++ b/tests/Australia/SouthAustralia/EasterSaturdayTest.php @@ -14,10 +14,6 @@ namespace Yasumi\tests\Australia\SouthAustralia; -use DateInterval; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -39,7 +35,7 @@ class EasterSaturdayTest extends SouthAustraliaBaseTestCase implements HolidayTe * @param int $year the year for which the holiday defined in this test needs to be tested * @param string $expected the expected date * - * @throws Exception + * @throws \Exception */ public function testHoliday(int $year, string $expected): void { @@ -47,7 +43,7 @@ public function testHoliday(int $year, string $expected): void $this->region, self::HOLIDAY, $year, - new DateTime($expected, new DateTimeZone($this->timezone)) + new \DateTime($expected, new \DateTimeZone($this->timezone)) ); } @@ -56,7 +52,7 @@ public function testHoliday(int $year, string $expected): void * * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function HolidayDataProvider(): array { @@ -65,7 +61,7 @@ public function HolidayDataProvider(): array for ($y = 0; $y < 50; ++$y) { $year = $this->generateRandomYear(); $date = $this->calculateEaster($year, $this->timezone); - $date->sub(new DateInterval('P1D')); + $date->sub(new \DateInterval('P1D')); $data[] = [$year, $date->format('Y-m-d')]; } @@ -76,7 +72,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -91,7 +87,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Australia/SouthAustralia/LabourDayTest.php b/tests/Australia/SouthAustralia/LabourDayTest.php index daf8d88df..1b8fb2047 100644 --- a/tests/Australia/SouthAustralia/LabourDayTest.php +++ b/tests/Australia/SouthAustralia/LabourDayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Australia\SouthAustralia; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -38,7 +35,7 @@ class LabourDayTest extends SouthAustraliaBaseTestCase implements HolidayTestCas * @param int $year the year for which the holiday defined in this test needs to be tested * @param string $expected the expected date * - * @throws Exception + * @throws \Exception */ public function testHoliday(int $year, string $expected): void { @@ -46,7 +43,7 @@ public function testHoliday(int $year, string $expected): void $this->region, self::HOLIDAY, $year, - new DateTime($expected, new DateTimeZone($this->timezone)) + new \DateTime($expected, new \DateTimeZone($this->timezone)) ); } @@ -75,7 +72,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -90,7 +87,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Australia/SouthAustralia/ProclamationDayTest.php b/tests/Australia/SouthAustralia/ProclamationDayTest.php index 6ca469fbd..d5ab00407 100644 --- a/tests/Australia/SouthAustralia/ProclamationDayTest.php +++ b/tests/Australia/SouthAustralia/ProclamationDayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Australia\SouthAustralia; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -38,7 +35,7 @@ class ProclamationDayTest extends SouthAustraliaBaseTestCase implements HolidayT * @param int $year the year for which the holiday defined in this test needs to be tested * @param string $expected the expected date * - * @throws Exception + * @throws \Exception */ public function testHoliday(int $year, string $expected): void { @@ -46,7 +43,7 @@ public function testHoliday(int $year, string $expected): void $this->region, self::HOLIDAY, $year, - new DateTime($expected, new DateTimeZone($this->timezone)) + new \DateTime($expected, new \DateTimeZone($this->timezone)) ); } @@ -75,7 +72,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -90,7 +87,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Australia/SouthAustralia/QueensBirthdayTest.php b/tests/Australia/SouthAustralia/QueensBirthdayTest.php index e5a880014..eabba5f02 100644 --- a/tests/Australia/SouthAustralia/QueensBirthdayTest.php +++ b/tests/Australia/SouthAustralia/QueensBirthdayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Australia\SouthAustralia; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -43,7 +40,7 @@ class QueensBirthdayTest extends SouthAustraliaBaseTestCase implements HolidayTe * @param int $year the year for which the holiday defined in this test needs to be tested * @param string $expected the expected date * - * @throws Exception + * @throws \Exception */ public function testHoliday(int $year, string $expected): void { @@ -51,7 +48,7 @@ public function testHoliday(int $year, string $expected): void $this->region, self::HOLIDAY, $year, - new DateTime($expected, new DateTimeZone($this->timezone)) + new \DateTime($expected, new \DateTimeZone($this->timezone)) ); } @@ -80,7 +77,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -95,7 +92,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Australia/SouthAustralia/SouthAustraliaTest.php b/tests/Australia/SouthAustralia/SouthAustraliaTest.php index d35c0bad6..e42e8b046 100644 --- a/tests/Australia/SouthAustralia/SouthAustraliaTest.php +++ b/tests/Australia/SouthAustralia/SouthAustraliaTest.php @@ -14,7 +14,6 @@ namespace Yasumi\tests\Australia\SouthAustralia; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\ProviderTestCase; @@ -59,7 +58,7 @@ public function testOfficialHolidays(): void } /** - * @throws ReflectionException + * @throws \ReflectionException * @throws \Exception */ public function testSources(): void diff --git a/tests/Australia/Tasmania/CentralNorth/CentralNorthTest.php b/tests/Australia/Tasmania/CentralNorth/CentralNorthTest.php index 4c8a04c1d..533138c9c 100644 --- a/tests/Australia/Tasmania/CentralNorth/CentralNorthTest.php +++ b/tests/Australia/Tasmania/CentralNorth/CentralNorthTest.php @@ -14,7 +14,6 @@ namespace Yasumi\tests\Australia\Tasmania\CentralNorth; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\ProviderTestCase; @@ -59,7 +58,7 @@ public function testOfficialHolidays(): void } /** - * @throws ReflectionException + * @throws \ReflectionException * @throws \Exception */ public function testSources(): void diff --git a/tests/Australia/Tasmania/CentralNorth/DevonportShowTest.php b/tests/Australia/Tasmania/CentralNorth/DevonportShowTest.php index c110d7469..e2ce5bdbd 100644 --- a/tests/Australia/Tasmania/CentralNorth/DevonportShowTest.php +++ b/tests/Australia/Tasmania/CentralNorth/DevonportShowTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Australia\Tasmania\CentralNorth; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -38,7 +35,7 @@ class DevonportShowTest extends CentralNorthBaseTestCase implements HolidayTestC * @param int $year the year for which the holiday defined in this test needs to be tested * @param string $expected the expected date * - * @throws Exception + * @throws \Exception */ public function testHoliday(int $year, string $expected): void { @@ -46,7 +43,7 @@ public function testHoliday(int $year, string $expected): void $this->region, self::HOLIDAY, $year, - new DateTime($expected, new DateTimeZone($this->timezone)) + new \DateTime($expected, new \DateTimeZone($this->timezone)) ); } @@ -75,7 +72,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -90,7 +87,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Australia/Tasmania/EightHourDayTest.php b/tests/Australia/Tasmania/EightHourDayTest.php index bda06f4b9..ea9f52a8e 100644 --- a/tests/Australia/Tasmania/EightHourDayTest.php +++ b/tests/Australia/Tasmania/EightHourDayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Australia\Tasmania; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -38,7 +35,7 @@ class EightHourDayTest extends TasmaniaBaseTestCase implements HolidayTestCase * @param int $year the year for which the holiday defined in this test needs to be tested * @param string $expected the expected date * - * @throws Exception + * @throws \Exception */ public function testHoliday(int $year, string $expected): void { @@ -46,7 +43,7 @@ public function testHoliday(int $year, string $expected): void $this->region, self::HOLIDAY, $year, - new DateTime($expected, new DateTimeZone($this->timezone)) + new \DateTime($expected, new \DateTimeZone($this->timezone)) ); } @@ -75,7 +72,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -90,7 +87,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Australia/Tasmania/FlindersIsland/FlindersIslandShowTest.php b/tests/Australia/Tasmania/FlindersIsland/FlindersIslandShowTest.php index e4f293f71..f95136955 100644 --- a/tests/Australia/Tasmania/FlindersIsland/FlindersIslandShowTest.php +++ b/tests/Australia/Tasmania/FlindersIsland/FlindersIslandShowTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Australia\Tasmania\FlindersIsland; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -38,7 +35,7 @@ class FlindersIslandShowTest extends FlindersIslandBaseTestCase implements Holid * @param int $year the year for which the holiday defined in this test needs to be tested * @param string $expected the expected date * - * @throws Exception + * @throws \Exception */ public function testHoliday(int $year, string $expected): void { @@ -46,7 +43,7 @@ public function testHoliday(int $year, string $expected): void $this->region, self::HOLIDAY, $year, - new DateTime($expected, new DateTimeZone($this->timezone)) + new \DateTime($expected, new \DateTimeZone($this->timezone)) ); } @@ -75,7 +72,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -90,7 +87,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Australia/Tasmania/FlindersIsland/FlindersIslandTest.php b/tests/Australia/Tasmania/FlindersIsland/FlindersIslandTest.php index 76bce01a5..78f438b26 100644 --- a/tests/Australia/Tasmania/FlindersIsland/FlindersIslandTest.php +++ b/tests/Australia/Tasmania/FlindersIsland/FlindersIslandTest.php @@ -14,7 +14,6 @@ namespace Yasumi\tests\Australia\Tasmania\FlindersIsland; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\ProviderTestCase; @@ -59,7 +58,7 @@ public function testOfficialHolidays(): void } /** - * @throws ReflectionException + * @throws \ReflectionException * @throws \Exception */ public function testSources(): void diff --git a/tests/Australia/Tasmania/KingIsland/KingIslandShowTest.php b/tests/Australia/Tasmania/KingIsland/KingIslandShowTest.php index 3dae93000..f137847d8 100644 --- a/tests/Australia/Tasmania/KingIsland/KingIslandShowTest.php +++ b/tests/Australia/Tasmania/KingIsland/KingIslandShowTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Australia\Tasmania\KingIsland; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -38,7 +35,7 @@ class KingIslandShowTest extends KingIslandBaseTestCase implements HolidayTestCa * @param int $year the year for which the holiday defined in this test needs to be tested * @param string $expected the expected date * - * @throws Exception + * @throws \Exception */ public function testHoliday(int $year, string $expected): void { @@ -46,7 +43,7 @@ public function testHoliday(int $year, string $expected): void $this->region, self::HOLIDAY, $year, - new DateTime($expected, new DateTimeZone($this->timezone)) + new \DateTime($expected, new \DateTimeZone($this->timezone)) ); } @@ -75,7 +72,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -90,7 +87,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Australia/Tasmania/KingIsland/KingIslandTest.php b/tests/Australia/Tasmania/KingIsland/KingIslandTest.php index fc5464e25..2e9175a67 100644 --- a/tests/Australia/Tasmania/KingIsland/KingIslandTest.php +++ b/tests/Australia/Tasmania/KingIsland/KingIslandTest.php @@ -14,7 +14,6 @@ namespace Yasumi\tests\Australia\Tasmania\KingIsland; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\ProviderTestCase; @@ -59,7 +58,7 @@ public function testOfficialHolidays(): void } /** - * @throws ReflectionException + * @throws \ReflectionException * @throws \Exception */ public function testSources(): void diff --git a/tests/Australia/Tasmania/Northeast/LauncestonShowTest.php b/tests/Australia/Tasmania/Northeast/LauncestonShowTest.php index 183f07977..523780635 100644 --- a/tests/Australia/Tasmania/Northeast/LauncestonShowTest.php +++ b/tests/Australia/Tasmania/Northeast/LauncestonShowTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Australia\Tasmania\Northeast; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -38,7 +35,7 @@ class LauncestonShowTest extends NortheastBaseTestCase implements HolidayTestCas * @param int $year the year for which the holiday defined in this test needs to be tested * @param string $expected the expected date * - * @throws Exception + * @throws \Exception */ public function testHoliday(int $year, string $expected): void { @@ -46,7 +43,7 @@ public function testHoliday(int $year, string $expected): void $this->region, self::HOLIDAY, $year, - new DateTime($expected, new DateTimeZone($this->timezone)) + new \DateTime($expected, new \DateTimeZone($this->timezone)) ); } @@ -75,7 +72,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -90,7 +87,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Australia/Tasmania/Northeast/NortheastTest.php b/tests/Australia/Tasmania/Northeast/NortheastTest.php index fe9933f9a..50c96a6ca 100644 --- a/tests/Australia/Tasmania/Northeast/NortheastTest.php +++ b/tests/Australia/Tasmania/Northeast/NortheastTest.php @@ -14,7 +14,6 @@ namespace Yasumi\tests\Australia\Tasmania\Northeast; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\ProviderTestCase; @@ -59,7 +58,7 @@ public function testOfficialHolidays(): void } /** - * @throws ReflectionException + * @throws \ReflectionException * @throws \Exception */ public function testSources(): void diff --git a/tests/Australia/Tasmania/Northwest/BurnieShowTest.php b/tests/Australia/Tasmania/Northwest/BurnieShowTest.php index 99d7a2836..b3d699639 100644 --- a/tests/Australia/Tasmania/Northwest/BurnieShowTest.php +++ b/tests/Australia/Tasmania/Northwest/BurnieShowTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Australia\Tasmania\Northwest; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -38,7 +35,7 @@ class BurnieShowTest extends NorthwestBaseTestCase implements HolidayTestCase * @param int $year the year for which the holiday defined in this test needs to be tested * @param string $expected the expected date * - * @throws Exception + * @throws \Exception */ public function testHoliday(int $year, string $expected): void { @@ -46,7 +43,7 @@ public function testHoliday(int $year, string $expected): void $this->region, self::HOLIDAY, $year, - new DateTime($expected, new DateTimeZone($this->timezone)) + new \DateTime($expected, new \DateTimeZone($this->timezone)) ); } @@ -75,7 +72,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -90,7 +87,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Australia/Tasmania/Northwest/CircularHead/AGFESTTest.php b/tests/Australia/Tasmania/Northwest/CircularHead/AGFESTTest.php index 2be1d89e9..5da92d8aa 100644 --- a/tests/Australia/Tasmania/Northwest/CircularHead/AGFESTTest.php +++ b/tests/Australia/Tasmania/Northwest/CircularHead/AGFESTTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Australia\Tasmania\Northwest\CircularHead; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -38,7 +35,7 @@ class AGFESTTest extends CircularHeadBaseTestCase implements HolidayTestCase * @param int $year the year for which the holiday defined in this test needs to be tested * @param string $expected the expected date * - * @throws Exception + * @throws \Exception */ public function testHoliday(int $year, string $expected): void { @@ -46,7 +43,7 @@ public function testHoliday(int $year, string $expected): void $this->region, self::HOLIDAY, $year, - new DateTime($expected, new DateTimeZone($this->timezone)) + new \DateTime($expected, new \DateTimeZone($this->timezone)) ); } @@ -75,7 +72,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -90,7 +87,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Australia/Tasmania/Northwest/NorthwestTest.php b/tests/Australia/Tasmania/Northwest/NorthwestTest.php index aee008564..d23c9e3b2 100644 --- a/tests/Australia/Tasmania/Northwest/NorthwestTest.php +++ b/tests/Australia/Tasmania/Northwest/NorthwestTest.php @@ -14,7 +14,6 @@ namespace Yasumi\tests\Australia\Tasmania\Northwest; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\ProviderTestCase; @@ -59,7 +58,7 @@ public function testOfficialHolidays(): void } /** - * @throws ReflectionException + * @throws \ReflectionException * @throws \Exception */ public function testSources(): void diff --git a/tests/Australia/Tasmania/QueensBirthdayTest.php b/tests/Australia/Tasmania/QueensBirthdayTest.php index 5aa0b7fd3..88c2b1bf6 100644 --- a/tests/Australia/Tasmania/QueensBirthdayTest.php +++ b/tests/Australia/Tasmania/QueensBirthdayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Australia\Tasmania; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -43,7 +40,7 @@ class QueensBirthdayTest extends TasmaniaBaseTestCase implements HolidayTestCase * @param int $year the year for which the holiday defined in this test needs to be tested * @param string $expected the expected date * - * @throws Exception + * @throws \Exception */ public function testHoliday(int $year, string $expected): void { @@ -51,7 +48,7 @@ public function testHoliday(int $year, string $expected): void $this->region, self::HOLIDAY, $year, - new DateTime($expected, new DateTimeZone($this->timezone)) + new \DateTime($expected, new \DateTimeZone($this->timezone)) ); } @@ -80,7 +77,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -95,7 +92,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Australia/Tasmania/RecreationDayTest.php b/tests/Australia/Tasmania/RecreationDayTest.php index 207ee6ba7..e45d3d756 100644 --- a/tests/Australia/Tasmania/RecreationDayTest.php +++ b/tests/Australia/Tasmania/RecreationDayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Australia\Tasmania; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -38,7 +35,7 @@ class RecreationDayTest extends TasmaniaBaseTestCase implements HolidayTestCase * @param int $year the year for which the holiday defined in this test needs to be tested * @param string $expected the expected date * - * @throws Exception + * @throws \Exception */ public function testHoliday(int $year, string $expected): void { @@ -46,7 +43,7 @@ public function testHoliday(int $year, string $expected): void $this->region, self::HOLIDAY, $year, - new DateTime($expected, new DateTimeZone($this->timezone)) + new \DateTime($expected, new \DateTimeZone($this->timezone)) ); } @@ -75,7 +72,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -90,7 +87,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Australia/Tasmania/South/HobartShowTest.php b/tests/Australia/Tasmania/South/HobartShowTest.php index 63f91ab22..137cd0897 100644 --- a/tests/Australia/Tasmania/South/HobartShowTest.php +++ b/tests/Australia/Tasmania/South/HobartShowTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Australia\Tasmania\South; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -38,7 +35,7 @@ class HobartShowTest extends SouthBaseTestCase implements HolidayTestCase * @param int $year the year for which the holiday defined in this test needs to be tested * @param string $expected the expected date * - * @throws Exception + * @throws \Exception */ public function testHoliday(int $year, string $expected): void { @@ -46,7 +43,7 @@ public function testHoliday(int $year, string $expected): void $this->region, self::HOLIDAY, $year, - new DateTime($expected, new DateTimeZone($this->timezone)) + new \DateTime($expected, new \DateTimeZone($this->timezone)) ); } @@ -75,7 +72,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -90,7 +87,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Australia/Tasmania/South/SouthTest.php b/tests/Australia/Tasmania/South/SouthTest.php index 2d65b97dc..a113a66b0 100644 --- a/tests/Australia/Tasmania/South/SouthTest.php +++ b/tests/Australia/Tasmania/South/SouthTest.php @@ -14,7 +14,6 @@ namespace Yasumi\tests\Australia\Tasmania\South; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\ProviderTestCase; @@ -59,7 +58,7 @@ public function testOfficialHolidays(): void } /** - * @throws ReflectionException + * @throws \ReflectionException * @throws \Exception */ public function testSources(): void diff --git a/tests/Australia/Tasmania/South/Southeast/HobartRegattaTest.php b/tests/Australia/Tasmania/South/Southeast/HobartRegattaTest.php index e4e609ab2..c367539f9 100644 --- a/tests/Australia/Tasmania/South/Southeast/HobartRegattaTest.php +++ b/tests/Australia/Tasmania/South/Southeast/HobartRegattaTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Australia\Tasmania\South\Southeast; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -38,7 +35,7 @@ class HobartRegattaTest extends SoutheastBaseTestCase implements HolidayTestCase * @param int $year the year for which the holiday defined in this test needs to be tested * @param string $expected the expected date * - * @throws Exception + * @throws \Exception */ public function testHoliday(int $year, string $expected): void { @@ -46,7 +43,7 @@ public function testHoliday(int $year, string $expected): void $this->region, self::HOLIDAY, $year, - new DateTime($expected, new DateTimeZone($this->timezone)) + new \DateTime($expected, new \DateTimeZone($this->timezone)) ); } @@ -75,7 +72,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -90,7 +87,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Australia/Tasmania/TasmaniaTest.php b/tests/Australia/Tasmania/TasmaniaTest.php index a5157c60c..15eb83217 100644 --- a/tests/Australia/Tasmania/TasmaniaTest.php +++ b/tests/Australia/Tasmania/TasmaniaTest.php @@ -14,7 +14,6 @@ namespace Yasumi\tests\Australia\Tasmania; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\ProviderTestCase; @@ -58,7 +57,7 @@ public function testOfficialHolidays(): void } /** - * @throws ReflectionException + * @throws \ReflectionException * @throws \Exception */ public function testSources(): void diff --git a/tests/Australia/Victoria/AFLGrandFinalFridayTest.php b/tests/Australia/Victoria/AFLGrandFinalFridayTest.php index 114c710e0..0380bf9c2 100644 --- a/tests/Australia/Victoria/AFLGrandFinalFridayTest.php +++ b/tests/Australia/Victoria/AFLGrandFinalFridayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Australia\Victoria; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -41,7 +38,7 @@ class AFLGrandFinalFridayTest extends VictoriaBaseTestCase implements HolidayTes * @param int $year the year for which the holiday defined in this test needs to be tested * @param string $expected the expected date * - * @throws Exception + * @throws \Exception */ public function testHoliday(int $year, string $expected): void { @@ -49,14 +46,14 @@ public function testHoliday(int $year, string $expected): void $this->region, self::HOLIDAY, $year, - new DateTime($expected, new DateTimeZone($this->timezone)) + new \DateTime($expected, new \DateTimeZone($this->timezone)) ); } /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -71,7 +68,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Australia/Victoria/EasterSaturdayTest.php b/tests/Australia/Victoria/EasterSaturdayTest.php index 9799c546e..826985004 100644 --- a/tests/Australia/Victoria/EasterSaturdayTest.php +++ b/tests/Australia/Victoria/EasterSaturdayTest.php @@ -14,10 +14,6 @@ namespace Yasumi\tests\Australia\Victoria; -use DateInterval; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -39,7 +35,7 @@ class EasterSaturdayTest extends VictoriaBaseTestCase implements HolidayTestCase * @param int $year the year for which the holiday defined in this test needs to be tested * @param string $expected the expected date * - * @throws Exception + * @throws \Exception */ public function testHoliday(int $year, string $expected): void { @@ -47,7 +43,7 @@ public function testHoliday(int $year, string $expected): void $this->region, self::HOLIDAY, $year, - new DateTime($expected, new DateTimeZone($this->timezone)) + new \DateTime($expected, new \DateTimeZone($this->timezone)) ); } @@ -56,7 +52,7 @@ public function testHoliday(int $year, string $expected): void * * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function HolidayDataProvider(): array { @@ -65,7 +61,7 @@ public function HolidayDataProvider(): array for ($y = 0; $y < 50; ++$y) { $year = $this->generateRandomYear(); $date = $this->calculateEaster($year, $this->timezone); - $date->sub(new DateInterval('P1D')); + $date->sub(new \DateInterval('P1D')); $data[] = [$year, $date->format('Y-m-d')]; } @@ -76,7 +72,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -91,7 +87,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Australia/Victoria/EasterSundayTest.php b/tests/Australia/Victoria/EasterSundayTest.php index 194f19685..a4067d6e1 100644 --- a/tests/Australia/Victoria/EasterSundayTest.php +++ b/tests/Australia/Victoria/EasterSundayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Australia\Victoria; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -38,7 +35,7 @@ class EasterSundayTest extends VictoriaBaseTestCase implements HolidayTestCase * @param int $year the year for which the holiday defined in this test needs to be tested * @param string $expected the expected date * - * @throws Exception + * @throws \Exception */ public function testHoliday(int $year, string $expected): void { @@ -46,7 +43,7 @@ public function testHoliday(int $year, string $expected): void $this->region, self::HOLIDAY, $year, - new DateTime($expected, new DateTimeZone($this->timezone)) + new \DateTime($expected, new \DateTimeZone($this->timezone)) ); } @@ -55,7 +52,7 @@ public function testHoliday(int $year, string $expected): void * * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function HolidayDataProvider(): array { @@ -74,7 +71,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -89,7 +86,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Australia/Victoria/LabourDayTest.php b/tests/Australia/Victoria/LabourDayTest.php index 602b5728a..958826a2f 100644 --- a/tests/Australia/Victoria/LabourDayTest.php +++ b/tests/Australia/Victoria/LabourDayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Australia\Victoria; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -38,7 +35,7 @@ class LabourDayTest extends VictoriaBaseTestCase implements HolidayTestCase * @param int $year the year for which the holiday defined in this test needs to be tested * @param string $expected the expected date * - * @throws Exception + * @throws \Exception */ public function testHoliday(int $year, string $expected): void { @@ -46,7 +43,7 @@ public function testHoliday(int $year, string $expected): void $this->region, self::HOLIDAY, $year, - new DateTime($expected, new DateTimeZone($this->timezone)) + new \DateTime($expected, new \DateTimeZone($this->timezone)) ); } @@ -75,7 +72,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -90,7 +87,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Australia/Victoria/MelbourneCupDayTest.php b/tests/Australia/Victoria/MelbourneCupDayTest.php index e106247f3..5816b5107 100644 --- a/tests/Australia/Victoria/MelbourneCupDayTest.php +++ b/tests/Australia/Victoria/MelbourneCupDayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Australia\Victoria; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -43,7 +40,7 @@ class MelbourneCupDayTest extends VictoriaBaseTestCase implements HolidayTestCas * @param int $year the year for which the holiday defined in this test needs to be tested * @param string $expected the expected date * - * @throws Exception + * @throws \Exception */ public function testHoliday(int $year, string $expected): void { @@ -51,7 +48,7 @@ public function testHoliday(int $year, string $expected): void $this->region, self::HOLIDAY, $year, - new DateTime($expected, new DateTimeZone($this->timezone)) + new \DateTime($expected, new \DateTimeZone($this->timezone)) ); } @@ -80,7 +77,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -95,7 +92,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Australia/Victoria/QueensBirthdayTest.php b/tests/Australia/Victoria/QueensBirthdayTest.php index d569ee816..4f5cfd549 100644 --- a/tests/Australia/Victoria/QueensBirthdayTest.php +++ b/tests/Australia/Victoria/QueensBirthdayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Australia\Victoria; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -43,7 +40,7 @@ class QueensBirthdayTest extends VictoriaBaseTestCase implements HolidayTestCase * @param int $year the year for which the holiday defined in this test needs to be tested * @param string $expected the expected date * - * @throws Exception + * @throws \Exception */ public function testHoliday(int $year, string $expected): void { @@ -51,7 +48,7 @@ public function testHoliday(int $year, string $expected): void $this->region, self::HOLIDAY, $year, - new DateTime($expected, new DateTimeZone($this->timezone)) + new \DateTime($expected, new \DateTimeZone($this->timezone)) ); } @@ -80,7 +77,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -95,7 +92,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Australia/Victoria/VictoriaTest.php b/tests/Australia/Victoria/VictoriaTest.php index 112827c25..bdc4a752f 100644 --- a/tests/Australia/Victoria/VictoriaTest.php +++ b/tests/Australia/Victoria/VictoriaTest.php @@ -14,7 +14,6 @@ namespace Yasumi\tests\Australia\Victoria; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\ProviderTestCase; @@ -61,7 +60,7 @@ public function testOfficialHolidays(): void } /** - * @throws ReflectionException + * @throws \ReflectionException * @throws \Exception */ public function testSources(): void diff --git a/tests/Australia/WesternAustralia/LabourDayTest.php b/tests/Australia/WesternAustralia/LabourDayTest.php index 583bb8070..16f8bea59 100644 --- a/tests/Australia/WesternAustralia/LabourDayTest.php +++ b/tests/Australia/WesternAustralia/LabourDayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Australia\WesternAustralia; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -38,7 +35,7 @@ class LabourDayTest extends WesternAustraliaBaseTestCase implements HolidayTestC * @param int $year the year for which the holiday defined in this test needs to be tested * @param string $expected the expected date * - * @throws Exception + * @throws \Exception */ public function testHoliday(int $year, string $expected): void { @@ -46,7 +43,7 @@ public function testHoliday(int $year, string $expected): void $this->region, self::HOLIDAY, $year, - new DateTime($expected, new DateTimeZone($this->timezone)) + new \DateTime($expected, new \DateTimeZone($this->timezone)) ); } @@ -75,7 +72,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -90,7 +87,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Australia/WesternAustralia/QueensBirthdayTest.php b/tests/Australia/WesternAustralia/QueensBirthdayTest.php index 23dfedacb..6c3435d02 100644 --- a/tests/Australia/WesternAustralia/QueensBirthdayTest.php +++ b/tests/Australia/WesternAustralia/QueensBirthdayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Australia\WesternAustralia; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -43,7 +40,7 @@ class QueensBirthdayTest extends WesternAustraliaBaseTestCase implements Holiday * @param int $year the year for which the holiday defined in this test needs to be tested * @param string $expected the expected date * - * @throws Exception + * @throws \Exception */ public function testHoliday(int $year, string $expected): void { @@ -51,7 +48,7 @@ public function testHoliday(int $year, string $expected): void $this->region, self::HOLIDAY, $year, - new DateTime($expected, new DateTimeZone($this->timezone)) + new \DateTime($expected, new \DateTimeZone($this->timezone)) ); } @@ -80,7 +77,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -95,7 +92,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Australia/WesternAustralia/WesternAustraliaDayTest.php b/tests/Australia/WesternAustralia/WesternAustraliaDayTest.php index ec55944ce..0edc72fb9 100644 --- a/tests/Australia/WesternAustralia/WesternAustraliaDayTest.php +++ b/tests/Australia/WesternAustralia/WesternAustraliaDayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Australia\WesternAustralia; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -38,7 +35,7 @@ class WesternAustraliaDayTest extends WesternAustraliaBaseTestCase implements Ho * @param int $year the year for which the holiday defined in this test needs to be tested * @param string $expected the expected date * - * @throws Exception + * @throws \Exception */ public function testHoliday(int $year, string $expected): void { @@ -46,7 +43,7 @@ public function testHoliday(int $year, string $expected): void $this->region, self::HOLIDAY, $year, - new DateTime($expected, new DateTimeZone($this->timezone)) + new \DateTime($expected, new \DateTimeZone($this->timezone)) ); } @@ -75,7 +72,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -90,7 +87,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Australia/WesternAustralia/WesternAustraliaTest.php b/tests/Australia/WesternAustralia/WesternAustraliaTest.php index 42e2b05e7..7ccce6489 100644 --- a/tests/Australia/WesternAustralia/WesternAustraliaTest.php +++ b/tests/Australia/WesternAustralia/WesternAustraliaTest.php @@ -14,7 +14,6 @@ namespace Yasumi\tests\Australia\WesternAustralia; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\ProviderTestCase; @@ -58,7 +57,7 @@ public function testOfficialHolidays(): void } /** - * @throws ReflectionException + * @throws \ReflectionException * @throws \Exception */ public function testSources(): void diff --git a/tests/Austria/AllSaintsDayTest.php b/tests/Austria/AllSaintsDayTest.php index 959a41a60..b17c2a48a 100644 --- a/tests/Austria/AllSaintsDayTest.php +++ b/tests/Austria/AllSaintsDayTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\Austria; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,8 +32,8 @@ class AllSaintsDayTest extends AustriaBaseTestCase implements HolidayTestCase * * @dataProvider HolidayDataProvider * - * @param int $year the year for which the holiday defined in this test needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which the holiday defined in this test needs to be tested + * @param \DateTime $expected the expected date */ public function testHoliday(int $year, \DateTimeInterface $expected): void { @@ -47,7 +45,7 @@ public function testHoliday(int $year, \DateTimeInterface $expected): void * * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function HolidayDataProvider(): array { @@ -57,7 +55,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -72,7 +70,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Austria/AscensionDayTest.php b/tests/Austria/AscensionDayTest.php index 2598db313..03694e5f2 100644 --- a/tests/Austria/AscensionDayTest.php +++ b/tests/Austria/AscensionDayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Austria; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -33,7 +30,7 @@ class AscensionDayTest extends AustriaBaseTestCase implements HolidayTestCase /** * Tests the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHoliday(): void { @@ -42,14 +39,14 @@ public function testHoliday(): void self::REGION, 'ascensionDay', $year, - new DateTime("$year-5-23", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-5-23", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -64,7 +61,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Austria/AssumptionOfMaryTest.php b/tests/Austria/AssumptionOfMaryTest.php index f74fcdd31..5dc914040 100644 --- a/tests/Austria/AssumptionOfMaryTest.php +++ b/tests/Austria/AssumptionOfMaryTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\Austria; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,8 +32,8 @@ class AssumptionOfMaryTest extends AustriaBaseTestCase implements HolidayTestCas * * @dataProvider HolidayDataProvider * - * @param int $year the year for which the holiday defined in this test needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which the holiday defined in this test needs to be tested + * @param \DateTime $expected the expected date */ public function testHoliday(int $year, \DateTimeInterface $expected): void { @@ -47,7 +45,7 @@ public function testHoliday(int $year, \DateTimeInterface $expected): void * * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function HolidayDataProvider(): array { @@ -57,7 +55,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -72,7 +70,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Austria/AustriaTest.php b/tests/Austria/AustriaTest.php index 76015bd23..c069994cd 100644 --- a/tests/Austria/AustriaTest.php +++ b/tests/Austria/AustriaTest.php @@ -14,7 +14,6 @@ namespace Yasumi\tests\Austria; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\ProviderTestCase; @@ -93,7 +92,7 @@ public function testOtherHolidays(): void } /** - * @throws ReflectionException + * @throws \ReflectionException * @throws \Exception */ public function testSources(): void diff --git a/tests/Austria/Burgenland/BurgenlandTest.php b/tests/Austria/Burgenland/BurgenlandTest.php index 72c872459..fdadb33a1 100644 --- a/tests/Austria/Burgenland/BurgenlandTest.php +++ b/tests/Austria/Burgenland/BurgenlandTest.php @@ -14,7 +14,6 @@ namespace Yasumi\tests\Austria\Burgenland; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\ProviderTestCase; @@ -99,7 +98,7 @@ public function testOtherHolidays(): void } /** - * @throws ReflectionException + * @throws \ReflectionException * @throws \Exception */ public function testSources(): void diff --git a/tests/Austria/Burgenland/stMartinsDayTest.php b/tests/Austria/Burgenland/stMartinsDayTest.php index 1f311c859..22a07ff19 100644 --- a/tests/Austria/Burgenland/stMartinsDayTest.php +++ b/tests/Austria/Burgenland/stMartinsDayTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\Austria\Burgenland; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,8 +32,8 @@ class stMartinsDayTest extends BurgenlandBaseTestCase implements HolidayTestCase * * @dataProvider stMartinsDayDataProvider * - * @param int $year the year for which Saint Martins Day needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which Saint Martins Day needs to be tested + * @param \DateTime $expected the expected date */ public function teststMartinsDay(int $year, \DateTimeInterface $expected): void { @@ -47,7 +45,7 @@ public function teststMartinsDay(int $year, \DateTimeInterface $expected): void * * @return array list of test dates for Saint Martins Day * - * @throws Exception + * @throws \Exception */ public function stMartinsDayDataProvider(): array { @@ -57,7 +55,7 @@ public function stMartinsDayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -72,7 +70,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Austria/Carinthia/CarinthiaTest.php b/tests/Austria/Carinthia/CarinthiaTest.php index 7b58a548c..8f0295749 100644 --- a/tests/Austria/Carinthia/CarinthiaTest.php +++ b/tests/Austria/Carinthia/CarinthiaTest.php @@ -14,7 +14,6 @@ namespace Yasumi\tests\Austria\Carinthia; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\ProviderTestCase; @@ -103,7 +102,7 @@ public function testOtherHolidays(): void } /** - * @throws ReflectionException + * @throws \ReflectionException * @throws \Exception */ public function testSources(): void diff --git a/tests/Austria/Carinthia/PlebisciteDayTest.php b/tests/Austria/Carinthia/PlebisciteDayTest.php index 0ac7d171e..72ec5dc6f 100644 --- a/tests/Austria/Carinthia/PlebisciteDayTest.php +++ b/tests/Austria/Carinthia/PlebisciteDayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Austria\Carinthia; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -40,8 +37,8 @@ class PlebisciteDayTest extends CarinthiaBaseTestCase implements HolidayTestCase * * @dataProvider PlebisciteDayDataProvider * - * @param int $year the year for which Plebiscite Day needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which Plebiscite Day needs to be tested + * @param \DateTime $expected the expected date */ public function testPlebisciteDay(int $year, \DateTimeInterface $expected): void { @@ -53,7 +50,7 @@ public function testPlebisciteDay(int $year, \DateTimeInterface $expected): void * * @return array list of test dates for Plebiscite Day * - * @throws Exception + * @throws \Exception */ public function PlebisciteDayDataProvider(): array { @@ -61,7 +58,7 @@ public function PlebisciteDayDataProvider(): array for ($y = 0; $y < self::TEST_ITERATIONS; ++$y) { $year = $this->generateRandomYear(self::ESTABLISHMENT_YEAR); - $data[] = [$year, new DateTime("$year-10-10", new DateTimeZone(self::TIMEZONE))]; + $data[] = [$year, new \DateTime("$year-10-10", new \DateTimeZone(self::TIMEZONE))]; } return $data; @@ -70,7 +67,7 @@ public function PlebisciteDayDataProvider(): array /** * Tests the holiday defined in this test before establishment. * - * @throws Exception + * @throws \Exception */ public function testHolidayBeforeEstablishment(): void { @@ -84,7 +81,7 @@ public function testHolidayBeforeEstablishment(): void /** * Tests translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -99,7 +96,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Austria/Carinthia/StJosephsDayTest.php b/tests/Austria/Carinthia/StJosephsDayTest.php index 10ccad1d6..48fef8375 100644 --- a/tests/Austria/Carinthia/StJosephsDayTest.php +++ b/tests/Austria/Carinthia/StJosephsDayTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\Austria\Carinthia; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,8 +32,8 @@ class StJosephsDayTest extends CarinthiaBaseTestCase implements HolidayTestCase * * @dataProvider StJosephsDayDataProvider * - * @param int $year the year for which St. Joseph's Day needs to be tested. - * @param DateTime $expected the expected date + * @param int $year the year for which St. Joseph's Day needs to be tested. + * @param \DateTime $expected the expected date */ public function testStJosephsDay(int $year, \DateTimeInterface $expected): void { @@ -47,7 +45,7 @@ public function testStJosephsDay(int $year, \DateTimeInterface $expected): void * * @return array list of test dates for St. Joseph's Day. * - * @throws Exception + * @throws \Exception */ public function StJosephsDayDataProvider(): array { @@ -57,7 +55,7 @@ public function StJosephsDayDataProvider(): array /** * Tests translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -72,7 +70,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Austria/ChristmasTest.php b/tests/Austria/ChristmasTest.php index 6a5922f59..b3b4bb4c2 100644 --- a/tests/Austria/ChristmasTest.php +++ b/tests/Austria/ChristmasTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\Austria; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,8 +32,8 @@ class ChristmasTest extends AustriaBaseTestCase implements HolidayTestCase * * @dataProvider HolidayDataProvider * - * @param int $year the year for which the holiday defined in this test needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which the holiday defined in this test needs to be tested + * @param \DateTime $expected the expected date */ public function testHoliday(int $year, \DateTimeInterface $expected): void { @@ -47,7 +45,7 @@ public function testHoliday(int $year, \DateTimeInterface $expected): void * * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function HolidayDataProvider(): array { @@ -57,7 +55,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -72,7 +70,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Austria/CorpusChristiTest.php b/tests/Austria/CorpusChristiTest.php index 2eb327f0d..fd9ed3cba 100644 --- a/tests/Austria/CorpusChristiTest.php +++ b/tests/Austria/CorpusChristiTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\Austria; -use DateInterval; -use Exception; use Yasumi\Holiday; use Yasumi\Provider\ChristianHolidays; use Yasumi\tests\HolidayTestCase; @@ -35,7 +33,7 @@ class CorpusChristiTest extends AustriaBaseTestCase implements HolidayTestCase /** * Tests the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHoliday(): void { @@ -44,14 +42,14 @@ public function testHoliday(): void self::REGION, self::HOLIDAY, $year, - $this->calculateEaster($year, self::TIMEZONE)->add(new DateInterval('P60D')) + $this->calculateEaster($year, self::TIMEZONE)->add(new \DateInterval('P60D')) ); } /** * Tests translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -66,7 +64,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Austria/EasterMondayTest.php b/tests/Austria/EasterMondayTest.php index 3ac452316..63570888e 100644 --- a/tests/Austria/EasterMondayTest.php +++ b/tests/Austria/EasterMondayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Austria; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -33,7 +30,7 @@ class EasterMondayTest extends AustriaBaseTestCase implements HolidayTestCase /** * Tests the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHoliday(): void { @@ -42,14 +39,14 @@ public function testHoliday(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-3-28", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-3-28", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -64,7 +61,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Austria/EasterTest.php b/tests/Austria/EasterTest.php index 3228a0365..2ae348904 100644 --- a/tests/Austria/EasterTest.php +++ b/tests/Austria/EasterTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Austria; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -33,7 +30,7 @@ class EasterTest extends AustriaBaseTestCase implements HolidayTestCase /** * Tests the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHoliday(): void { @@ -42,14 +39,14 @@ public function testHoliday(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-4-12", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-4-12", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -64,7 +61,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Austria/EpiphanyTest.php b/tests/Austria/EpiphanyTest.php index 1b63331d2..2bc592148 100644 --- a/tests/Austria/EpiphanyTest.php +++ b/tests/Austria/EpiphanyTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\Austria; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,8 +32,8 @@ class EpiphanyTest extends AustriaBaseTestCase implements HolidayTestCase * * @dataProvider HolidayDataProvider * - * @param int $year the year for which the holiday defined in this test needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which the holiday defined in this test needs to be tested + * @param \DateTime $expected the expected date */ public function testHoliday(int $year, \DateTimeInterface $expected): void { @@ -47,7 +45,7 @@ public function testHoliday(int $year, \DateTimeInterface $expected): void * * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function HolidayDataProvider(): array { @@ -57,7 +55,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -72,7 +70,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Austria/ImmaculateConceptionTest.php b/tests/Austria/ImmaculateConceptionTest.php index d298ab70e..66e505a62 100644 --- a/tests/Austria/ImmaculateConceptionTest.php +++ b/tests/Austria/ImmaculateConceptionTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\Austria; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,8 +32,8 @@ class ImmaculateConceptionTest extends AustriaBaseTestCase implements HolidayTes * * @dataProvider HolidayDataProvider * - * @param int $year the year for which the holiday defined in this test needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which the holiday defined in this test needs to be tested + * @param \DateTime $expected the expected date */ public function testHoliday(int $year, \DateTimeInterface $expected): void { @@ -47,7 +45,7 @@ public function testHoliday(int $year, \DateTimeInterface $expected): void * * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function HolidayDataProvider(): array { @@ -57,7 +55,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -72,7 +70,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Austria/InternationalWorkersDayTest.php b/tests/Austria/InternationalWorkersDayTest.php index 5770f53f3..533fcafcb 100644 --- a/tests/Austria/InternationalWorkersDayTest.php +++ b/tests/Austria/InternationalWorkersDayTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\Austria; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,8 +32,8 @@ class InternationalWorkersDayTest extends AustriaBaseTestCase implements Holiday * * @dataProvider HolidayDataProvider * - * @param int $year the year for which the holiday defined in this test needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which the holiday defined in this test needs to be tested + * @param \DateTime $expected the expected date */ public function testHoliday(int $year, \DateTimeInterface $expected): void { @@ -47,7 +45,7 @@ public function testHoliday(int $year, \DateTimeInterface $expected): void * * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function HolidayDataProvider(): array { @@ -57,7 +55,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -72,7 +70,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Austria/LowerAustria/LowerAustriaTest.php b/tests/Austria/LowerAustria/LowerAustriaTest.php index 7bced1f7f..b49441308 100644 --- a/tests/Austria/LowerAustria/LowerAustriaTest.php +++ b/tests/Austria/LowerAustria/LowerAustriaTest.php @@ -14,7 +14,6 @@ namespace Yasumi\tests\Austria\LowerAustria; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\ProviderTestCase; @@ -102,7 +101,7 @@ public function testOtherHolidays(): void } /** - * @throws ReflectionException + * @throws \ReflectionException * @throws \Exception */ public function testSources(): void diff --git a/tests/Austria/LowerAustria/StLeopoldsDayTest.php b/tests/Austria/LowerAustria/StLeopoldsDayTest.php index ab2b194c6..56acaf17f 100644 --- a/tests/Austria/LowerAustria/StLeopoldsDayTest.php +++ b/tests/Austria/LowerAustria/StLeopoldsDayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Austria\LowerAustria; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -40,8 +37,8 @@ class StLeopoldsDayTest extends LowerAustriaBaseTestCase implements HolidayTestC * * @dataProvider StLeopoldsDayDataProvider * - * @param int $year the year for which Saint Leopold's Day needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which Saint Leopold's Day needs to be tested + * @param \DateTime $expected the expected date */ public function testStLeopoldsDay(int $year, \DateTimeInterface $expected): void { @@ -53,7 +50,7 @@ public function testStLeopoldsDay(int $year, \DateTimeInterface $expected): void * * @return array list of test dates for Saint Leopold's Day * - * @throws Exception + * @throws \Exception */ public function StLeopoldsDayDataProvider(): array { @@ -61,7 +58,7 @@ public function StLeopoldsDayDataProvider(): array for ($y = 0; $y < self::TEST_ITERATIONS; ++$y) { $year = $this->generateRandomYear(self::ESTABLISHMENT_YEAR); - $data[] = [$year, new DateTime("$year-11-15", new DateTimeZone(self::TIMEZONE))]; + $data[] = [$year, new \DateTime("$year-11-15", new \DateTimeZone(self::TIMEZONE))]; } return $data; @@ -70,7 +67,7 @@ public function StLeopoldsDayDataProvider(): array /** * Tests the holiday defined in this test before establishment. * - * @throws Exception + * @throws \Exception */ public function testHolidayBeforeEstablishment(): void { @@ -84,7 +81,7 @@ public function testHolidayBeforeEstablishment(): void /** * Tests translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -99,7 +96,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Austria/NationalDayTest.php b/tests/Austria/NationalDayTest.php index 8cba12015..a8281ecfa 100644 --- a/tests/Austria/NationalDayTest.php +++ b/tests/Austria/NationalDayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Austria; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -38,7 +35,7 @@ class NationalDayTest extends AustriaBaseTestCase implements HolidayTestCase /** * Tests the holiday defined in this test on or after establishment. * - * @throws Exception + * @throws \Exception */ public function testHolidayOnAfterEstablishment(): void { @@ -47,14 +44,14 @@ public function testHolidayOnAfterEstablishment(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-10-26", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-10-26", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests the holiday defined in this test before establishment. * - * @throws Exception + * @throws \Exception */ public function testHolidayBeforeEstablishment(): void { @@ -68,7 +65,7 @@ public function testHolidayBeforeEstablishment(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -83,7 +80,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Austria/NewYearsDayTest.php b/tests/Austria/NewYearsDayTest.php index 5f913882a..3c49ba50b 100644 --- a/tests/Austria/NewYearsDayTest.php +++ b/tests/Austria/NewYearsDayTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\Austria; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,8 +32,8 @@ class NewYearsDayTest extends AustriaBaseTestCase implements HolidayTestCase * * @dataProvider HolidayDataProvider * - * @param int $year the year for which the holiday defined in this test needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which the holiday defined in this test needs to be tested + * @param \DateTime $expected the expected date */ public function testHoliday(int $year, \DateTimeInterface $expected): void { @@ -47,7 +45,7 @@ public function testHoliday(int $year, \DateTimeInterface $expected): void * * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function HolidayDataProvider(): array { @@ -57,7 +55,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -72,7 +70,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Austria/PentecostMondayTest.php b/tests/Austria/PentecostMondayTest.php index 779313ef1..d896a26a7 100644 --- a/tests/Austria/PentecostMondayTest.php +++ b/tests/Austria/PentecostMondayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Austria; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -33,7 +30,7 @@ class PentecostMondayTest extends AustriaBaseTestCase implements HolidayTestCase /** * Tests the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHoliday(): void { @@ -42,14 +39,14 @@ public function testHoliday(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-6-10", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-6-10", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -64,7 +61,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Austria/PentecostTest.php b/tests/Austria/PentecostTest.php index f7099bd0e..cacf284e1 100644 --- a/tests/Austria/PentecostTest.php +++ b/tests/Austria/PentecostTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Austria; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -33,7 +30,7 @@ class PentecostTest extends AustriaBaseTestCase implements HolidayTestCase /** * Tests the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHoliday(): void { @@ -42,14 +39,14 @@ public function testHoliday(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-5-23", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-5-23", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -64,7 +61,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Austria/Salzburg/SalzburgTest.php b/tests/Austria/Salzburg/SalzburgTest.php index 861598bff..097278bc9 100644 --- a/tests/Austria/Salzburg/SalzburgTest.php +++ b/tests/Austria/Salzburg/SalzburgTest.php @@ -14,7 +14,6 @@ namespace Yasumi\tests\Austria\Salzburg; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\ProviderTestCase; @@ -102,7 +101,7 @@ public function testOtherHolidays(): void } /** - * @throws ReflectionException + * @throws \ReflectionException * @throws \Exception */ public function testSources(): void diff --git a/tests/Austria/Salzburg/StRupertsDayTest.php b/tests/Austria/Salzburg/StRupertsDayTest.php index c199bee71..71741eaaa 100644 --- a/tests/Austria/Salzburg/StRupertsDayTest.php +++ b/tests/Austria/Salzburg/StRupertsDayTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\Austria\Salzburg; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,8 +32,8 @@ class StRupertsDayTest extends SalzburgBaseTestCase implements HolidayTestCase * * @dataProvider StRupertsDayDataProvider * - * @param int $year the year for which Saint Rupert's Day needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which Saint Rupert's Day needs to be tested + * @param \DateTime $expected the expected date */ public function testStRupertsDay(int $year, \DateTimeInterface $expected): void { @@ -47,7 +45,7 @@ public function testStRupertsDay(int $year, \DateTimeInterface $expected): void * * @return array list of test dates for Saint Rupert's Day * - * @throws Exception + * @throws \Exception */ public function StRupertsDayDataProvider(): array { @@ -57,7 +55,7 @@ public function StRupertsDayDataProvider(): array /** * Tests translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -72,7 +70,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Austria/SecondChristmasDayTest.php b/tests/Austria/SecondChristmasDayTest.php index bb5376350..b43344930 100644 --- a/tests/Austria/SecondChristmasDayTest.php +++ b/tests/Austria/SecondChristmasDayTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\Austria; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,8 +32,8 @@ class SecondChristmasDayTest extends AustriaBaseTestCase implements HolidayTestC * * @dataProvider HolidayDataProvider * - * @param int $year the year for which the holiday defined in this test needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which the holiday defined in this test needs to be tested + * @param \DateTime $expected the expected date */ public function testHoliday(int $year, \DateTimeInterface $expected): void { @@ -47,7 +45,7 @@ public function testHoliday(int $year, \DateTimeInterface $expected): void * * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function HolidayDataProvider(): array { @@ -57,7 +55,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -72,7 +70,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Austria/Styria/StJosephsDayTest.php b/tests/Austria/Styria/StJosephsDayTest.php index e298986f1..a491c1923 100644 --- a/tests/Austria/Styria/StJosephsDayTest.php +++ b/tests/Austria/Styria/StJosephsDayTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\Austria\Styria; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,8 +32,8 @@ class StJosephsDayTest extends StyriaBaseTestCase implements HolidayTestCase * * @dataProvider StJosephsDayDataProvider * - * @param int $year the year for which St. Joseph's Day needs to be tested. - * @param DateTime $expected the expected date + * @param int $year the year for which St. Joseph's Day needs to be tested. + * @param \DateTime $expected the expected date */ public function testStJosephsDay(int $year, \DateTimeInterface $expected): void { @@ -47,7 +45,7 @@ public function testStJosephsDay(int $year, \DateTimeInterface $expected): void * * @return array list of test dates for St. Joseph's Day. * - * @throws Exception + * @throws \Exception */ public function StJosephsDayDataProvider(): array { @@ -57,7 +55,7 @@ public function StJosephsDayDataProvider(): array /** * Tests translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -72,7 +70,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Austria/Styria/StyriaTest.php b/tests/Austria/Styria/StyriaTest.php index 9e777e8c0..a3fa0188d 100644 --- a/tests/Austria/Styria/StyriaTest.php +++ b/tests/Austria/Styria/StyriaTest.php @@ -14,7 +14,6 @@ namespace Yasumi\tests\Austria\Styria; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\ProviderTestCase; @@ -99,7 +98,7 @@ public function testOtherHolidays(): void } /** - * @throws ReflectionException + * @throws \ReflectionException * @throws \Exception */ public function testSources(): void diff --git a/tests/Austria/Tyrol/StJosephsDayTest.php b/tests/Austria/Tyrol/StJosephsDayTest.php index 66fffedc7..b12977c9a 100644 --- a/tests/Austria/Tyrol/StJosephsDayTest.php +++ b/tests/Austria/Tyrol/StJosephsDayTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\Austria\Tyrol; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,8 +32,8 @@ class StJosephsDayTest extends TyrolBaseTestCase implements HolidayTestCase * * @dataProvider StJosephsDayDataProvider * - * @param int $year the year for which St. Joseph's Day needs to be tested. - * @param DateTime $expected the expected date + * @param int $year the year for which St. Joseph's Day needs to be tested. + * @param \DateTime $expected the expected date */ public function testStJosephsDay(int $year, \DateTimeInterface $expected): void { @@ -47,7 +45,7 @@ public function testStJosephsDay(int $year, \DateTimeInterface $expected): void * * @return array list of test dates for St. Joseph's Day. * - * @throws Exception + * @throws \Exception */ public function StJosephsDayDataProvider(): array { @@ -57,7 +55,7 @@ public function StJosephsDayDataProvider(): array /** * Tests translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -72,7 +70,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Austria/Tyrol/TyrolTest.php b/tests/Austria/Tyrol/TyrolTest.php index 211b0e21e..adcf7a781 100644 --- a/tests/Austria/Tyrol/TyrolTest.php +++ b/tests/Austria/Tyrol/TyrolTest.php @@ -14,7 +14,6 @@ namespace Yasumi\tests\Austria\Tyrol; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\ProviderTestCase; @@ -99,7 +98,7 @@ public function testOtherHolidays(): void } /** - * @throws ReflectionException + * @throws \ReflectionException * @throws \Exception */ public function testSources(): void diff --git a/tests/Austria/UpperAustria/StFloriansDayTest.php b/tests/Austria/UpperAustria/StFloriansDayTest.php index 2183a031b..a2352b152 100644 --- a/tests/Austria/UpperAustria/StFloriansDayTest.php +++ b/tests/Austria/UpperAustria/StFloriansDayTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\Austria\UpperAustria; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,8 +32,8 @@ class StFloriansDayTest extends UpperAustriaBaseTestCase implements HolidayTestC * * @dataProvider StFloriansDayDataProvider * - * @param int $year the year for which Saint Florian's Day needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which Saint Florian's Day needs to be tested + * @param \DateTime $expected the expected date */ public function testStFloriansDay(int $year, \DateTimeInterface $expected): void { @@ -47,7 +45,7 @@ public function testStFloriansDay(int $year, \DateTimeInterface $expected): void * * @return array list of test dates for Saint Florian's Day * - * @throws Exception + * @throws \Exception */ public function StFloriansDayDataProvider(): array { @@ -57,7 +55,7 @@ public function StFloriansDayDataProvider(): array /** * Tests translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -72,7 +70,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Austria/UpperAustria/UpperAustriaTest.php b/tests/Austria/UpperAustria/UpperAustriaTest.php index 36cbce30c..a8901a273 100644 --- a/tests/Austria/UpperAustria/UpperAustriaTest.php +++ b/tests/Austria/UpperAustria/UpperAustriaTest.php @@ -14,7 +14,6 @@ namespace Yasumi\tests\Austria\UpperAustria; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\ProviderTestCase; @@ -102,7 +101,7 @@ public function testOtherHolidays(): void } /** - * @throws ReflectionException + * @throws \ReflectionException * @throws \Exception */ public function testSources(): void diff --git a/tests/Austria/Vienna/StLeopoldsDayTest.php b/tests/Austria/Vienna/StLeopoldsDayTest.php index d045331ee..79efb10d1 100644 --- a/tests/Austria/Vienna/StLeopoldsDayTest.php +++ b/tests/Austria/Vienna/StLeopoldsDayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Austria\Vienna; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -40,8 +37,8 @@ class StLeopoldsDayTest extends ViennaBaseTestCase implements HolidayTestCase * * @dataProvider StLeopoldsDayDataProvider * - * @param int $year the year for which Saint Leopold's Day needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which Saint Leopold's Day needs to be tested + * @param \DateTime $expected the expected date */ public function testStLeopoldsDay(int $year, \DateTimeInterface $expected): void { @@ -53,7 +50,7 @@ public function testStLeopoldsDay(int $year, \DateTimeInterface $expected): void * * @return array list of test dates for Saint Leopold's Day * - * @throws Exception + * @throws \Exception */ public function StLeopoldsDayDataProvider(): array { @@ -61,7 +58,7 @@ public function StLeopoldsDayDataProvider(): array for ($y = 0; $y < self::TEST_ITERATIONS; ++$y) { $year = $this->generateRandomYear(self::ESTABLISHMENT_YEAR); - $data[] = [$year, new DateTime("$year-11-15", new DateTimeZone(self::TIMEZONE))]; + $data[] = [$year, new \DateTime("$year-11-15", new \DateTimeZone(self::TIMEZONE))]; } return $data; @@ -70,7 +67,7 @@ public function StLeopoldsDayDataProvider(): array /** * Tests the holiday defined in this test before establishment. * - * @throws Exception + * @throws \Exception */ public function testHolidayBeforeEstablishment(): void { @@ -84,7 +81,7 @@ public function testHolidayBeforeEstablishment(): void /** * Tests translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -99,7 +96,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Austria/Vienna/ViennaTest.php b/tests/Austria/Vienna/ViennaTest.php index 6b2e56884..7fac55bbc 100644 --- a/tests/Austria/Vienna/ViennaTest.php +++ b/tests/Austria/Vienna/ViennaTest.php @@ -14,7 +14,6 @@ namespace Yasumi\tests\Austria\Vienna; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\ProviderTestCase; @@ -102,7 +101,7 @@ public function testOtherHolidays(): void } /** - * @throws ReflectionException + * @throws \ReflectionException * @throws \Exception */ public function testSources(): void diff --git a/tests/Austria/Vorarlberg/StJosephsDayTest.php b/tests/Austria/Vorarlberg/StJosephsDayTest.php index 83c7d622a..a595f8a58 100644 --- a/tests/Austria/Vorarlberg/StJosephsDayTest.php +++ b/tests/Austria/Vorarlberg/StJosephsDayTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\Austria\Vorarlberg; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,8 +32,8 @@ class StJosephsDayTest extends VorarlbergBaseTestCase implements HolidayTestCase * * @dataProvider StJosephsDayDataProvider * - * @param int $year the year for which St. Joseph's Day needs to be tested. - * @param DateTime $expected the expected date + * @param int $year the year for which St. Joseph's Day needs to be tested. + * @param \DateTime $expected the expected date */ public function testStJosephsDay(int $year, \DateTimeInterface $expected): void { @@ -47,7 +45,7 @@ public function testStJosephsDay(int $year, \DateTimeInterface $expected): void * * @return array list of test dates for St. Joseph's Day. * - * @throws Exception + * @throws \Exception */ public function StJosephsDayDataProvider(): array { @@ -57,7 +55,7 @@ public function StJosephsDayDataProvider(): array /** * Tests translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -72,7 +70,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Austria/Vorarlberg/VorarlbergTest.php b/tests/Austria/Vorarlberg/VorarlbergTest.php index 5d9a1542c..c14cca5cf 100644 --- a/tests/Austria/Vorarlberg/VorarlbergTest.php +++ b/tests/Austria/Vorarlberg/VorarlbergTest.php @@ -14,7 +14,6 @@ namespace Yasumi\tests\Austria\Vorarlberg; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\ProviderTestCase; @@ -99,7 +98,7 @@ public function testOtherHolidays(): void } /** - * @throws ReflectionException + * @throws \ReflectionException * @throws \Exception */ public function testSources(): void diff --git a/tests/Base/HolidayBetweenFilterTest.php b/tests/Base/HolidayBetweenFilterTest.php index e3f0efd8d..7921f19b0 100644 --- a/tests/Base/HolidayBetweenFilterTest.php +++ b/tests/Base/HolidayBetweenFilterTest.php @@ -14,11 +14,6 @@ namespace Yasumi\tests\Base; -use DateTime; -use DateTimeImmutable; -use DateTimeZone; -use Exception; -use InvalidArgumentException; use PHPUnit\Framework\TestCase; use Yasumi\tests\YasumiBase; use Yasumi\Yasumi; @@ -27,15 +22,15 @@ class HolidayBetweenFilterTest extends TestCase { use YasumiBase; - /** @throws Exception */ + /** @throws \Exception */ public function testHolidaysBetweenDateRange(): void { $timezone = 'Europe/Amsterdam'; $holidays = Yasumi::create('Netherlands', 2016); $between = $holidays->between( - new DateTime('03/25/2016', new DateTimeZone($timezone)), - new DateTime('07/25/2016', new DateTimeZone($timezone)) + new \DateTime('03/25/2016', new \DateTimeZone($timezone)), + new \DateTime('07/25/2016', new \DateTimeZone($timezone)) ); $betweenHolidays = iterator_to_array($between); @@ -77,15 +72,15 @@ public function testHolidaysBetweenDateRange(): void self::assertNotEquals(\count($holidays), $between->count()); } - /** @throws Exception */ + /** @throws \Exception */ public function testHolidaysBetweenDateRangeWithDateTimeImmutable(): void { $timezone = 'Europe/Amsterdam'; $holidays = Yasumi::create('Netherlands', 2016); $between = $holidays->between( - new DateTimeImmutable('03/25/2016', new DateTimeZone($timezone)), - new DateTimeImmutable('07/25/2016', new DateTimeZone($timezone)) + new \DateTimeImmutable('03/25/2016', new \DateTimeZone($timezone)), + new \DateTimeImmutable('07/25/2016', new \DateTimeZone($timezone)) ); $betweenHolidays = iterator_to_array($between); @@ -127,7 +122,7 @@ public function testHolidaysBetweenDateRangeWithDateTimeImmutable(): void self::assertNotEquals(\count($holidays), $between->count()); } - /** @throws Exception */ + /** @throws \Exception */ public function testHolidaysBetweenDateRangeDifferentTimezone(): void { $holidays = Yasumi::create('Netherlands', 2016); @@ -136,28 +131,28 @@ public function testHolidaysBetweenDateRangeDifferentTimezone(): void foreach ($timezones as $timezone) { $between = $holidays->between( - new DateTime('01/01/2016', new DateTimeZone($timezone)), - new DateTime('01/01/2016', new DateTimeZone($timezone)) + new \DateTime('01/01/2016', new \DateTimeZone($timezone)), + new \DateTime('01/01/2016', new \DateTimeZone($timezone)) ); self::assertCount(1, $between); $between = $holidays->between( - new DateTime('01/01/2016 23:59:59', new DateTimeZone($timezone)), - new DateTime('01/01/2016 23:59:59', new DateTimeZone($timezone)) + new \DateTime('01/01/2016 23:59:59', new \DateTimeZone($timezone)), + new \DateTime('01/01/2016 23:59:59', new \DateTimeZone($timezone)) ); self::assertCount(1, $between); } } - /** @throws Exception */ + /** @throws \Exception */ public function testHolidaysBetweenDateRangeExclusiveStartEndDate(): void { $timezone = 'Europe/Amsterdam'; $holidays = Yasumi::create('Netherlands', 2016); $between = $holidays->between( - new DateTime('01/01/2016', new DateTimeZone($timezone)), - new DateTime('07/25/2016', new DateTimeZone($timezone)), + new \DateTime('01/01/2016', new \DateTimeZone($timezone)), + new \DateTime('07/25/2016', new \DateTimeZone($timezone)), false ); @@ -200,7 +195,7 @@ public function testHolidaysBetweenDateRangeExclusiveStartEndDate(): void self::assertNotEquals(\count($holidays), $between->count()); } - /** @throws Exception */ + /** @throws \Exception */ public function testHolidaysBetweenDateRangeWithStartBeforeInstanceYear(): void { $year = 2015; @@ -208,8 +203,8 @@ public function testHolidaysBetweenDateRangeWithStartBeforeInstanceYear(): void $holidays = Yasumi::create('Norway', $year); $between = $holidays->between( - new DateTime('03/25/2011', new DateTimeZone($timezone)), - new DateTime('05/17/'.$year, new DateTimeZone($timezone)) + new \DateTime('03/25/2011', new \DateTimeZone($timezone)), + new \DateTime('05/17/'.$year, new \DateTimeZone($timezone)) ); $betweenHolidays = iterator_to_array($between); @@ -235,7 +230,7 @@ public function testHolidaysBetweenDateRangeWithStartBeforeInstanceYear(): void self::assertNotEquals(\count($holidays), $between->count()); } - /** @throws Exception */ + /** @throws \Exception */ public function testHolidaysBetweenDateRangeWithEndAfterInstanceYear(): void { $year = 2000; @@ -243,8 +238,8 @@ public function testHolidaysBetweenDateRangeWithEndAfterInstanceYear(): void $holidays = Yasumi::create('Italy', $year); $between = $holidays->between( - new DateTime('03/25/'.$year, new DateTimeZone($timezone)), - new DateTime('09/21/2021', new DateTimeZone($timezone)) + new \DateTime('03/25/'.$year, new \DateTimeZone($timezone)), + new \DateTime('09/21/2021', new \DateTimeZone($timezone)) ); $betweenHolidays = iterator_to_array($between); @@ -270,18 +265,18 @@ public function testHolidaysBetweenDateRangeWithEndAfterInstanceYear(): void self::assertNotEquals(\count($holidays), $between->count()); } - /** @throws Exception */ + /** @throws \Exception */ public function testWrongDates(): void { - $this->expectException(InvalidArgumentException::class); + $this->expectException(\InvalidArgumentException::class); $year = 2017; $timezone = 'America/New_York'; $holidays = Yasumi::create('USA', $year); $holidays->between( - new DateTime('12/31/'.$year, new DateTimeZone($timezone)), - new DateTime('01/01/'.$year, new DateTimeZone($timezone)) + new \DateTime('12/31/'.$year, new \DateTimeZone($timezone)), + new \DateTime('01/01/'.$year, new \DateTimeZone($timezone)) ); } @@ -290,7 +285,7 @@ public function testWrongDates(): void * * This test covers the scenario that the requested date range covers all know holidays. * - * @throws Exception + * @throws \Exception */ public function testCountBetweenWithSubstitutes(): void { @@ -300,8 +295,8 @@ public function testCountBetweenWithSubstitutes(): void $holidays = Yasumi::create('Ireland', $year); $between = $holidays->between( - new DateTime('01/01/'.$year, new DateTimeZone($timezone)), - new DateTime('12/31/'.$year, new DateTimeZone($timezone)) + new \DateTime('01/01/'.$year, new \DateTimeZone($timezone)), + new \DateTime('12/31/'.$year, new \DateTimeZone($timezone)) ); $betweenHolidays = iterator_to_array($between); @@ -330,7 +325,7 @@ public function testCountBetweenWithSubstitutes(): void * * This test covers the scenario that the requested date range excludes a substituted holiday. * - * @throws Exception + * @throws \Exception */ public function testCountBetweenExcludingSubstituteHoliday(): void { @@ -340,8 +335,8 @@ public function testCountBetweenExcludingSubstituteHoliday(): void $holidays = Yasumi::create('Ireland', $year); $between = $holidays->between( - new DateTime('01/01/'.$year, new DateTimeZone($timezone)), - new DateTime('03/20/'.$year, new DateTimeZone($timezone)) + new \DateTime('01/01/'.$year, new \DateTimeZone($timezone)), + new \DateTime('03/20/'.$year, new \DateTimeZone($timezone)) ); $betweenHolidays = iterator_to_array($between); @@ -374,7 +369,7 @@ public function testCountBetweenExcludingSubstituteHoliday(): void * This test covers the scenario that the requested date range excludes a substituted holiday, but includes * the original substituted holiday. * - * @throws Exception + * @throws \Exception */ public function testCountBetweenExcludingSubstituteHolidayIncludingOriginalHoliday(): void { @@ -384,8 +379,8 @@ public function testCountBetweenExcludingSubstituteHolidayIncludingOriginalHolid $holidays = Yasumi::create('Ireland', $year); $between = $holidays->between( - new DateTime('01/01/'.$year, new DateTimeZone($timezone)), - new DateTime('03/18/'.$year, new DateTimeZone($timezone)) + new \DateTime('01/01/'.$year, new \DateTimeZone($timezone)), + new \DateTime('03/18/'.$year, new \DateTimeZone($timezone)) ); $betweenHolidays = iterator_to_array($between); @@ -419,7 +414,7 @@ public function testCountBetweenExcludingSubstituteHolidayIncludingOriginalHolid * This test covers the scenario that the requested date range excludes a substituted holiday and also * the original substituted holiday. * - * @throws Exception + * @throws \Exception */ public function testCountBetweenExcludingSubstituteHolidayAndOriginalHoliday(): void { @@ -429,8 +424,8 @@ public function testCountBetweenExcludingSubstituteHolidayAndOriginalHoliday(): $holidays = Yasumi::create('Ireland', $year); $between = $holidays->between( - new DateTime('01/01/'.$year, new DateTimeZone($timezone)), - new DateTime('03/16/'.$year, new DateTimeZone($timezone)) + new \DateTime('01/01/'.$year, new \DateTimeZone($timezone)), + new \DateTime('03/16/'.$year, new \DateTimeZone($timezone)) ); $betweenHolidays = iterator_to_array($between); diff --git a/tests/Base/HolidayOnFilterTest.php b/tests/Base/HolidayOnFilterTest.php index 5bdeecbd7..2599202ed 100644 --- a/tests/Base/HolidayOnFilterTest.php +++ b/tests/Base/HolidayOnFilterTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Base; -use DateTime; -use DateTimeZone; -use Exception; use PHPUnit\Framework\TestCase; use Yasumi\tests\YasumiBase; use Yasumi\Yasumi; @@ -25,16 +22,16 @@ class HolidayOnFilterTest extends TestCase { use YasumiBase; - /** @throws Exception */ + /** @throws \Exception */ public function testHolidaysOnDate(): void { $timezone = 'Europe/Amsterdam'; $holidays = Yasumi::create('Netherlands', 2016); $holidayDates = [ - 'goodFriday' => new DateTime('03/25/2016', new DateTimeZone($timezone)), - 'easter' => new DateTime('03/27/2016', new DateTimeZone($timezone)), - 'summerTime' => new DateTime('03/27/2016', new DateTimeZone($timezone)), + 'goodFriday' => new \DateTime('03/25/2016', new \DateTimeZone($timezone)), + 'easter' => new \DateTime('03/27/2016', new \DateTimeZone($timezone)), + 'summerTime' => new \DateTime('03/27/2016', new \DateTimeZone($timezone)), ]; foreach ($holidayDates as $name => $date) { @@ -46,16 +43,16 @@ public function testHolidaysOnDate(): void } } - /** @throws Exception */ + /** @throws \Exception */ public function testHolidaysNotOnDate(): void { $timezone = 'Europe/Amsterdam'; $holidays = Yasumi::create('Netherlands', 2016); $holidayWrongDates = [ - 'goodFriday' => new DateTime('04/25/2016', new DateTimeZone($timezone)), - 'easter' => new DateTime('03/22/2016', new DateTimeZone($timezone)), - 'summerTime' => new DateTime('12/27/2016', new DateTimeZone($timezone)), + 'goodFriday' => new \DateTime('04/25/2016', new \DateTimeZone($timezone)), + 'easter' => new \DateTime('03/22/2016', new \DateTimeZone($timezone)), + 'summerTime' => new \DateTime('12/27/2016', new \DateTimeZone($timezone)), ]; foreach ($holidayWrongDates as $name => $date) { @@ -67,22 +64,22 @@ public function testHolidaysNotOnDate(): void } } - /** @throws Exception */ + /** @throws \Exception */ public function testCorrectNumberOfHolidaysOnDate(): void { $timezone = 'Europe/Amsterdam'; $holidays = Yasumi::create('Netherlands', 2016); // No holidays - $holidaysOnDate = $holidays->on(new DateTime('11/19/2016', new DateTimeZone($timezone))); + $holidaysOnDate = $holidays->on(new \DateTime('11/19/2016', new \DateTimeZone($timezone))); self::assertEquals(0, $holidaysOnDate->count()); // One holiday - $holidaysOnDate = $holidays->on(new DateTime('12/25/2016', new DateTimeZone($timezone))); + $holidaysOnDate = $holidays->on(new \DateTime('12/25/2016', new \DateTimeZone($timezone))); self::assertEquals(1, $holidaysOnDate->count()); // Multiple holidays - $holidaysOnDate = $holidays->on(new DateTime('03/27/2016', new DateTimeZone($timezone))); + $holidaysOnDate = $holidays->on(new \DateTime('03/27/2016', new \DateTimeZone($timezone))); self::assertGreaterThan(1, $holidaysOnDate->count()); } } diff --git a/tests/Base/HolidayTest.php b/tests/Base/HolidayTest.php index eff824902..1ced57880 100644 --- a/tests/Base/HolidayTest.php +++ b/tests/Base/HolidayTest.php @@ -16,8 +16,6 @@ use DateTime; use DateTimeImmutable; -use Exception; -use InvalidArgumentException; use PHPUnit\Framework\TestCase; use Yasumi\Exception\MissingTranslationException; use Yasumi\Exception\UnknownLocaleException; @@ -29,26 +27,26 @@ class HolidayTest extends TestCase { use YasumiBase; - /** @throws Exception */ + /** @throws \Exception */ public function testHolidayBlankKeyInvalidArgumentException(): void { - $this->expectException(InvalidArgumentException::class); + $this->expectException(\InvalidArgumentException::class); - new Holiday('', [], new DateTime()); + new Holiday('', [], new \DateTime()); } - /** @throws Exception */ + /** @throws \Exception */ public function testCreateHolidayUnknownLocaleException(): void { $this->expectException(UnknownLocaleException::class); - new Holiday('testHoliday', [], new DateTime(), 'wx-YZ'); + new Holiday('testHoliday', [], new \DateTime(), 'wx-YZ'); } - /** @throws Exception */ + /** @throws \Exception */ public function testHolidayIsJsonSerializable(): void { - $holiday = new Holiday('testHoliday', [], new DateTime(), 'en_US'); + $holiday = new Holiday('testHoliday', [], new \DateTime(), 'en_US'); $json = json_encode($holiday, JSON_THROW_ON_ERROR); $instance = json_decode($json, true, 512, JSON_THROW_ON_ERROR); @@ -57,24 +55,24 @@ public function testHolidayIsJsonSerializable(): void self::assertArrayHasKey('shortName', $instance); } - /** @throws Exception */ + /** @throws \Exception */ public function testHolidayWithDateTimeInterface(): void { // Assert with DateTime instance - $holiday = new Holiday('testHoliday', [], new DateTime(), 'en_US'); + $holiday = new Holiday('testHoliday', [], new \DateTime(), 'en_US'); self::assertNotNull($holiday); self::assertInstanceOf(Holiday::class, $holiday); // Assert with DateTimeImmutable instance - $holiday = new Holiday('testHoliday', [], new DateTimeImmutable(), 'en_US'); + $holiday = new Holiday('testHoliday', [], new \DateTimeImmutable(), 'en_US'); self::assertNotNull($holiday); self::assertInstanceOf(Holiday::class, $holiday); } - /** @throws Exception */ + /** @throws \Exception */ public function testHolidayGetLocales(): void { - $holiday = new Holiday('testHoliday', [], new DateTime(), 'ca_ES_VALENCIA'); + $holiday = new Holiday('testHoliday', [], new \DateTime(), 'ca_ES_VALENCIA'); $method = new \ReflectionMethod(Holiday::class, 'getLocales'); $method->setAccessible(true); @@ -83,7 +81,7 @@ public function testHolidayGetLocales(): void self::assertEquals(['de_DE', 'de', Holiday::LOCALE_KEY], $method->invoke($holiday, ['de_DE', Holiday::LOCALE_KEY])); } - /** @throws Exception */ + /** @throws \Exception */ public function testHolidayGetNameWithoutArgument(): void { // 'en_US' fallback @@ -94,16 +92,16 @@ public function testHolidayGetNameWithoutArgument(): void 'en_US' => 'Holiday EN-US', ]; - $holiday = new Holiday('testHoliday', $translations, new DateTime(), 'de_AT'); + $holiday = new Holiday('testHoliday', $translations, new \DateTime(), 'de_AT'); self::assertEquals('Holiday DE-AT', $holiday->getName()); - $holiday = new Holiday('testHoliday', $translations, new DateTime(), 'de'); + $holiday = new Holiday('testHoliday', $translations, new \DateTime(), 'de'); self::assertEquals('Holiday DE', $holiday->getName()); - $holiday = new Holiday('testHoliday', $translations, new DateTime(), 'de_DE'); + $holiday = new Holiday('testHoliday', $translations, new \DateTime(), 'de_DE'); self::assertEquals('Holiday DE', $holiday->getName()); - $holiday = new Holiday('testHoliday', $translations, new DateTime(), 'ja'); + $holiday = new Holiday('testHoliday', $translations, new \DateTime(), 'ja'); self::assertEquals('Holiday EN-US', $holiday->getName()); // 'en' fallback @@ -112,10 +110,10 @@ public function testHolidayGetNameWithoutArgument(): void 'en' => 'Holiday EN', ]; - $holiday = new Holiday('testHoliday', $translations, new DateTime(), 'de_DE'); + $holiday = new Holiday('testHoliday', $translations, new \DateTime(), 'de_DE'); self::assertEquals('Holiday DE', $holiday->getName()); - $holiday = new Holiday('testHoliday', $translations, new DateTime(), 'ja'); + $holiday = new Holiday('testHoliday', $translations, new \DateTime(), 'ja'); self::assertEquals('Holiday EN', $holiday->getName()); // No 'en' or 'en_US' fallback @@ -123,14 +121,14 @@ public function testHolidayGetNameWithoutArgument(): void 'de' => 'Holiday DE', ]; - $holiday = new Holiday('testHoliday', $translations, new DateTime(), 'de_DE'); + $holiday = new Holiday('testHoliday', $translations, new \DateTime(), 'de_DE'); self::assertEquals('Holiday DE', $holiday->getName()); - $holiday = new Holiday('testHoliday', $translations, new DateTime(), 'ja'); + $holiday = new Holiday('testHoliday', $translations, new \DateTime(), 'ja'); self::assertEquals('testHoliday', $holiday->getName()); } - /** @throws Exception */ + /** @throws \Exception */ public function testHolidayGetNameWithArgument(): void { $translations = [ @@ -140,7 +138,7 @@ public function testHolidayGetNameWithArgument(): void 'it_IT' => 'Holiday IT-IT', 'en_US' => 'Holiday EN-US', ]; - $holiday = new Holiday('testHoliday', $translations, new DateTime(), 'de_DE'); + $holiday = new Holiday('testHoliday', $translations, new \DateTime(), 'de_DE'); self::assertEquals('Holiday DE', $holiday->getName(['de'])); self::assertEquals('Holiday DE', $holiday->getName(['ja', 'de', 'nl', 'it_IT'])); @@ -155,14 +153,14 @@ public function testHolidayGetNameWithArgument(): void self::assertEquals('Holiday IT-IT', $holiday->getName(['it_IT', Holiday::LOCALE_KEY])); self::assertEquals('testHoliday', $holiday->getName([Holiday::LOCALE_KEY])); - $holiday = new Holiday('testHoliday', $translations, new DateTime(), 'ja'); + $holiday = new Holiday('testHoliday', $translations, new \DateTime(), 'ja'); self::assertEquals('Holiday EN-US', $holiday->getName()); $this->expectException(MissingTranslationException::class); $holiday->getName(['it']); } - /** @throws Exception */ + /** @throws \Exception */ public function testHolidayGetNameWithGlobalTranslations(): void { $translationsStub = $this->getMockBuilder(TranslationsInterface::class)->getMock(); @@ -176,7 +174,7 @@ public function testHolidayGetNameWithGlobalTranslations(): void $locale = 'pl_PL'; - $holiday = new Holiday('newYearsDay', [], new DateTime('2015-01-01'), $locale); + $holiday = new Holiday('newYearsDay', [], new \DateTime('2015-01-01'), $locale); $holiday->mergeGlobalTranslations($translationsStub); self::assertNotNull($holiday->getName()); @@ -184,7 +182,7 @@ public function testHolidayGetNameWithGlobalTranslations(): void self::assertEquals($translations[$locale], $holiday->getName()); } - /** @throws Exception */ + /** @throws \Exception */ public function testHolidayGetNameWithGlobalParentLocaleTranslations(): void { $translationsStub = $this->getMockBuilder(TranslationsInterface::class)->getMock(); @@ -198,7 +196,7 @@ public function testHolidayGetNameWithGlobalParentLocaleTranslations(): void $locale = 'pl_PL'; - $holiday = new Holiday('newYearsDay', [], new DateTime('2015-01-01'), $locale); + $holiday = new Holiday('newYearsDay', [], new \DateTime('2015-01-01'), $locale); $holiday->mergeGlobalTranslations($translationsStub); self::assertNotNull($holiday->getName()); @@ -206,7 +204,7 @@ public function testHolidayGetNameWithGlobalParentLocaleTranslations(): void self::assertEquals($translations['pl'], $holiday->getName()); } - /** @throws Exception */ + /** @throws \Exception */ public function testHolidayGetNameWithGlobalAndCustomTranslations(): void { $translationsStub = $this->getMockBuilder(TranslationsInterface::class)->getMock(); @@ -224,7 +222,7 @@ public function testHolidayGetNameWithGlobalAndCustomTranslations(): void $holiday = new Holiday( 'newYearsDay', [$customLocale => $customTranslation], - new DateTime('2015-01-01'), + new \DateTime('2015-01-01'), $customLocale ); $holiday->mergeGlobalTranslations($translationsStub); @@ -234,7 +232,7 @@ public function testHolidayGetNameWithGlobalAndCustomTranslations(): void self::assertEquals($customTranslation, $holiday->getName()); } - /** @throws Exception */ + /** @throws \Exception */ public function testHolidayGetNameWithOverridenGlobalTranslations(): void { $translationsStub = $this->getMockBuilder(TranslationsInterface::class)->getMock(); @@ -252,7 +250,7 @@ public function testHolidayGetNameWithOverridenGlobalTranslations(): void $holiday = new Holiday( 'newYearsDay', [$customLocale => $customTranslation], - new DateTime('2014-01-01'), + new \DateTime('2014-01-01'), $customLocale ); $holiday->mergeGlobalTranslations($translationsStub); diff --git a/tests/Base/SubstituteHolidayTest.php b/tests/Base/SubstituteHolidayTest.php index a947adb1c..3e30e3af5 100644 --- a/tests/Base/SubstituteHolidayTest.php +++ b/tests/Base/SubstituteHolidayTest.php @@ -30,11 +30,11 @@ class SubstituteHolidayTest extends TestCase /** @throws \Exception */ public function testCreateSubstituteHolidayUnknownLocaleException(): void { - $holiday = new Holiday('testHoliday', [], new DateTime()); + $holiday = new Holiday('testHoliday', [], new \DateTime()); $this->expectException(UnknownLocaleException::class); - new SubstituteHoliday($holiday, [], new DateTime(), 'wx-YZ'); + new SubstituteHoliday($holiday, [], new \DateTime(), 'wx-YZ'); } /** @@ -44,30 +44,30 @@ public function testCreateSubstituteHolidayUnknownLocaleException(): void */ public function testCreateSubstituteHolidaySameDate(): void { - $holiday = new Holiday('testHoliday', [], new DateTime('2019-01-01')); + $holiday = new Holiday('testHoliday', [], new \DateTime('2019-01-01')); - $this->expectException(InvalidArgumentException::class); + $this->expectException(\InvalidArgumentException::class); - new SubstituteHoliday($holiday, [], new DateTime('2019-01-01')); + new SubstituteHoliday($holiday, [], new \DateTime('2019-01-01')); } /** @throws \Exception */ public function testConstructor(): void { - $holiday = new Holiday('testHoliday', [], new DateTime('2019-01-01'), 'en_US', Holiday::TYPE_BANK); - $substitute = new SubstituteHoliday($holiday, [], new DateTime('2019-01-02'), 'en_US', Holiday::TYPE_SEASON); + $holiday = new Holiday('testHoliday', [], new \DateTime('2019-01-01'), 'en_US', Holiday::TYPE_BANK); + $substitute = new SubstituteHoliday($holiday, [], new \DateTime('2019-01-02'), 'en_US', Holiday::TYPE_SEASON); self::assertSame($holiday, $substitute->getSubstitutedHoliday()); self::assertEquals('substituteHoliday:testHoliday', $substitute->getKey()); self::assertEquals(Holiday::TYPE_SEASON, $substitute->getType()); - self::assertEquals(new DateTime('2019-01-02'), $substitute); + self::assertEquals(new \DateTime('2019-01-02'), $substitute); } /** @throws \Exception */ public function testSubstituteHolidayIsJsonSerializable(): void { - $holiday = new Holiday('testHoliday', [], new DateTime('2019-01-01'), 'en_US'); - $substitute = new SubstituteHoliday($holiday, [], new DateTime('2019-01-02'), 'en_US'); + $holiday = new Holiday('testHoliday', [], new \DateTime('2019-01-01'), 'en_US'); + $substitute = new SubstituteHoliday($holiday, [], new \DateTime('2019-01-02'), 'en_US'); $json = json_encode($substitute, JSON_THROW_ON_ERROR); $instance = json_decode($json, true, 512, JSON_THROW_ON_ERROR); @@ -81,8 +81,8 @@ public function testSubstituteHolidayIsJsonSerializable(): void public function testSubstituteHolidayWithDateTimeInterface(): void { // Assert with DateTime instance - $holiday = new Holiday('testHoliday', [], new DateTime('2019-01-01'), 'en_US'); - $substitute = new SubstituteHoliday($holiday, [], new DateTime('2019-01-02'), 'en_US'); + $holiday = new Holiday('testHoliday', [], new \DateTime('2019-01-01'), 'en_US'); + $substitute = new SubstituteHoliday($holiday, [], new \DateTime('2019-01-02'), 'en_US'); self::assertNotNull($holiday); self::assertInstanceOf(SubstituteHoliday::class, $substitute); @@ -96,8 +96,8 @@ public function testSubstituteHolidayWithDateTimeInterface(): void public function testSubstituteHolidayGetNameWithNoTranslations(): void { $name = 'testHoliday'; - $holiday = new Holiday($name, [], new DateTime('2019-01-01')); - $substitute = new SubstituteHoliday($holiday, [], new DateTime('2019-01-02'), 'en_US'); + $holiday = new Holiday($name, [], new \DateTime('2019-01-01')); + $substitute = new SubstituteHoliday($holiday, [], new \DateTime('2019-01-02'), 'en_US'); self::assertIsString($substitute->getName()); self::assertEquals('substituteHoliday:'.$name, $substitute->getName()); @@ -109,8 +109,8 @@ public function testSubstituteHolidayGetNameWithCustomSubstituteTranslation(): v $name = 'testHoliday'; $translation = 'My Holiday'; $locale = 'en_US'; - $holiday = new Holiday($name, [$locale => 'foo'], new DateTime('2019-01-01'), $locale); - $substitute = new SubstituteHoliday($holiday, [$locale => $translation], new DateTime('2019-01-02'), $locale); + $holiday = new Holiday($name, [$locale => 'foo'], new \DateTime('2019-01-01'), $locale); + $substitute = new SubstituteHoliday($holiday, [$locale => $translation], new \DateTime('2019-01-02'), $locale); $translationsStub = $this->getMockBuilder(TranslationsInterface::class)->getMock(); $translationsStub @@ -135,8 +135,8 @@ public function testSubstituteHolidayGetNameWithPatternFallback(): void $name = 'testHoliday'; $translation = 'My Holiday'; $locale = 'en_US'; - $holiday = new Holiday($name, [], new DateTime('2019-01-01'), $locale); - $substitute = new SubstituteHoliday($holiday, [], new DateTime('2019-01-02'), $locale); + $holiday = new Holiday($name, [], new \DateTime('2019-01-01'), $locale); + $substitute = new SubstituteHoliday($holiday, [], new \DateTime('2019-01-02'), $locale); $translationsStub = $this->getMockBuilder(TranslationsInterface::class)->getMock(); $translationsStub @@ -161,8 +161,8 @@ public function testSubstituteHolidayGetNameWithGlobalSubstituteTranslation(): v $name = 'testHoliday'; $translation = 'My Substitute'; $locale = 'en_US'; - $holiday = new Holiday($name, [$locale => 'foo'], new DateTime('2019-01-01'), $locale); - $substitute = new SubstituteHoliday($holiday, [$locale => $translation], new DateTime('2019-01-02'), $locale); + $holiday = new Holiday($name, [$locale => 'foo'], new \DateTime('2019-01-01'), $locale); + $substitute = new SubstituteHoliday($holiday, [$locale => $translation], new \DateTime('2019-01-02'), $locale); $translationsStub = $this->getMockBuilder(TranslationsInterface::class)->getMock(); $translationsStub @@ -187,8 +187,8 @@ public function testSubstituteHolidayGetNameWithSubstitutedTranslation(): void $name = 'testHoliday'; $translation = 'My Holiday'; $locale = 'en_US'; - $holiday = new Holiday($name, [$locale => $translation], new DateTime('2019-01-01'), $locale); - $substitute = new SubstituteHoliday($holiday, [], new DateTime('2019-01-02'), $locale); + $holiday = new Holiday($name, [$locale => $translation], new \DateTime('2019-01-01'), $locale); + $substitute = new SubstituteHoliday($holiday, [], new \DateTime('2019-01-02'), $locale); $translationsStub = $this->getMockBuilder(TranslationsInterface::class)->getMock(); $translationsStub diff --git a/tests/Base/TranslationsTest.php b/tests/Base/TranslationsTest.php index ad4a785ab..bfc6f07c5 100644 --- a/tests/Base/TranslationsTest.php +++ b/tests/Base/TranslationsTest.php @@ -14,7 +14,6 @@ namespace Yasumi\tests\Base; -use InvalidArgumentException; use org\bovigo\vfs\vfsStream; use PHPUnit\Framework\TestCase; use Yasumi\Exception\UnknownLocaleException; @@ -212,7 +211,7 @@ public function testLoadingTranslationsFromDirectoryWithUnknownLocaleException() public function testLoadingTranslationsFromInexistentDirectory(): void { - $this->expectException(InvalidArgumentException::class); + $this->expectException(\InvalidArgumentException::class); vfsStream::setup(); diff --git a/tests/Base/YasumiTest.php b/tests/Base/YasumiTest.php index 5bf8d1cd7..16bb248c1 100644 --- a/tests/Base/YasumiTest.php +++ b/tests/Base/YasumiTest.php @@ -16,10 +16,7 @@ use DateTime; use DateTimeImmutable; -use Exception; -use InvalidArgumentException; use PHPUnit\Framework\TestCase; -use ReflectionException; use Yasumi\Exception\InvalidYearException; use Yasumi\Exception\ProviderNotFoundException; use Yasumi\Exception\UnknownLocaleException; @@ -51,14 +48,14 @@ public function testCreateWithInvalidProvider(): void public function testCreateWithInvalidProviderBecauseItsATrait(): void { - $this->expectException(InvalidArgumentException::class); + $this->expectException(\InvalidArgumentException::class); Yasumi::create('CommonHolidays'); } public function testCreateWithAbstractClassProvider(): void { - $this->expectException(InvalidArgumentException::class); + $this->expectException(\InvalidArgumentException::class); Yasumi::create('AbstractProvider'); } @@ -114,7 +111,7 @@ public function testGetYear(): void /** * Tests that the next function returns the next upcoming date (i.e. next year) for the given holiday. * - * @throws Exception + * @throws \Exception */ public function testNext(): void { @@ -129,7 +126,7 @@ public function testNext(): void public function testNextWithBlankKey(): void { - $this->expectException(InvalidArgumentException::class); + $this->expectException(\InvalidArgumentException::class); $holidays = Yasumi::create( 'Netherlands', @@ -141,7 +138,7 @@ public function testNextWithBlankKey(): void /** * Tests the previous function returns the previous date (i.e. previous year) for the given holiday. * - * @throws Exception + * @throws \Exception */ public function testPrevious(): void { @@ -162,7 +159,7 @@ public function testPrevious(): void public function testPreviousWithBlankKey(): void { - $this->expectException(InvalidArgumentException::class); + $this->expectException(\InvalidArgumentException::class); $holidays = Yasumi::create( 'Netherlands', @@ -193,7 +190,7 @@ public function testWhenIs(): void public function testWhenIsWithBlankKey(): void { - $this->expectException(InvalidArgumentException::class); + $this->expectException(\InvalidArgumentException::class); $holidays = Yasumi::create('Japan', 2010); $holidays->whenIs(''); @@ -201,7 +198,7 @@ public function testWhenIsWithBlankKey(): void public function testGetHolidayWithBlankKey(): void { - $this->expectException(InvalidArgumentException::class); + $this->expectException(\InvalidArgumentException::class); $holidays = Yasumi::create('Netherlands', 1999); $holidays->getHoliday(''); @@ -218,7 +215,7 @@ public function testWhatWeekDayIs(): void public function testWhatWeekDayIsWithBlankKey(): void { - $this->expectException(InvalidArgumentException::class); + $this->expectException(\InvalidArgumentException::class); $holidays = Yasumi::create('Netherlands', 2388); $holidays->whatWeekDayIs(''); @@ -227,7 +224,7 @@ public function testWhatWeekDayIsWithBlankKey(): void /** * Tests that the getProviders function returns an array containing all available holiday providers. * - * @throws ReflectionException + * @throws \ReflectionException */ public function testGetProviders(): void { @@ -243,7 +240,7 @@ public function testGetProviders(): void /** * Tests that the getProviders function (static call) returns the same data when called again. * - * @throws ReflectionException + * @throws \ReflectionException */ public function testGetProvidersStaticCall(): void { @@ -268,7 +265,7 @@ public function testGetProvidersStaticCall(): void * Note that this function does *NOT* determine whether a date is a working or non-working day. It * only asserts that it is a date calculated by the Holiday Provider. * - * @throws Exception + * @throws \Exception */ public function testIsHoliday(): void { @@ -277,12 +274,12 @@ public function testIsHoliday(): void $date = $year.'-08-15'; // Assertion using a DateTime instance - $isHoliday = Yasumi::create($provider, $year)->isHoliday(new DateTime($date)); + $isHoliday = Yasumi::create($provider, $year)->isHoliday(new \DateTime($date)); self::assertIsBool($isHoliday); self::assertTrue($isHoliday); // Assertion using a DateTimeImmutable instance - $isHoliday = Yasumi::create($provider, $year)->isHoliday(new DateTimeImmutable($date)); + $isHoliday = Yasumi::create($provider, $year)->isHoliday(new \DateTimeImmutable($date)); self::assertIsBool($isHoliday); self::assertTrue($isHoliday); @@ -295,7 +292,7 @@ public function testIsHoliday(): void * Note that this function does *NOT* determine whether a date is a working or non-working day. It * only asserts that it is a date calculated by the Holiday Provider. * - * @throws Exception + * @throws \Exception */ public function testIsNotHoliday(): void { @@ -304,12 +301,12 @@ public function testIsNotHoliday(): void $date = $year.'-06-10'; // Assertion using a DateTime instance - $isHoliday = Yasumi::create($provider, $year)->isHoliday(new DateTime($date)); + $isHoliday = Yasumi::create($provider, $year)->isHoliday(new \DateTime($date)); self::assertIsBool($isHoliday); self::assertFalse($isHoliday); // Assertion using a DateTimeImmutable instance - $isHoliday = Yasumi::create($provider, $year)->isHoliday(new DateTimeImmutable($date)); + $isHoliday = Yasumi::create($provider, $year)->isHoliday(new \DateTimeImmutable($date)); self::assertIsBool($isHoliday); self::assertFalse($isHoliday); @@ -322,7 +319,7 @@ public function testIsNotHoliday(): void * * @TODO Add additional unit tests for those holiday providers that differ from the global definition * - * @throws Exception + * @throws \Exception */ public function testIsWorkingDay(): void { @@ -331,12 +328,12 @@ public function testIsWorkingDay(): void $date = $year.'-06-02'; // Assertion using a DateTime instance - $isWorkingDay = Yasumi::create($provider, $year)->isWorkingDay(new DateTime($date)); + $isWorkingDay = Yasumi::create($provider, $year)->isWorkingDay(new \DateTime($date)); self::assertIsBool($isWorkingDay); self::assertTrue($isWorkingDay); // Assertion using a DateTimeImmutable instance - $isWorkingDay = Yasumi::create($provider, $year)->isWorkingDay(new DateTimeImmutable($date)); + $isWorkingDay = Yasumi::create($provider, $year)->isWorkingDay(new \DateTimeImmutable($date)); self::assertIsBool($isWorkingDay); self::assertTrue($isWorkingDay); @@ -349,7 +346,7 @@ public function testIsWorkingDay(): void * * @TODO Add additional unit tests for those holiday providers that differ from the global definition * - * @throws Exception + * @throws \Exception */ public function testIsNotWorkingDay(): void { @@ -358,12 +355,12 @@ public function testIsNotWorkingDay(): void $date = $year.'-01-11'; // Assertion using a DateTime instance - $isNotWorkingDay = Yasumi::create($provider, $year)->isWorkingDay(new DateTime($date)); + $isNotWorkingDay = Yasumi::create($provider, $year)->isWorkingDay(new \DateTime($date)); self::assertIsBool($isNotWorkingDay); self::assertFalse($isNotWorkingDay); // Assertion using a DateTimeImmutable instance - $isNotWorkingDay = Yasumi::create($provider, $year)->isWorkingDay(new DateTimeImmutable($date)); + $isNotWorkingDay = Yasumi::create($provider, $year)->isWorkingDay(new \DateTimeImmutable($date)); self::assertIsBool($isNotWorkingDay); self::assertFalse($isNotWorkingDay); @@ -418,7 +415,7 @@ public function testRemoveHoliday(): void * Tests that a holiday provider instance can be created by using the ISO3166-2 * country/region code. (Using the Yasumi::createByISO3166_2 method). * - * @throws ReflectionException + * @throws \ReflectionException */ public function testCreateByISO31662(): void { @@ -439,7 +436,7 @@ public function testCreateByISO31662(): void * Tests that a ProviderNotFoundException is thrown when providing a invalid * ISO3166-2 code when using the Yasumi::createByISO3166_2 method. * - * @throws ReflectionException + * @throws \ReflectionException */ public function testCreateByISO31662WithInvalidCode(): void { @@ -452,15 +449,15 @@ public function testCreateByISO31662WithInvalidCode(): void * Tests that a holiday can be added to a provider. In addition, it * tests that the same holiday instance isn't added twice. * - * @throws ReflectionException - * @throws Exception + * @throws \ReflectionException + * @throws \Exception */ public function testAddExistingHoliday(): void { $provider = Yasumi::createByISO3166_2('NL', 2019); $holidayName = 'testHoliday'; - $holiday = new Holiday($holidayName, [], new DateTime()); + $holiday = new Holiday($holidayName, [], new \DateTime()); $originalHolidays = $provider->getHolidayNames(); // Add a new holiday diff --git a/tests/Base/YasumiWorkdayTest.php b/tests/Base/YasumiWorkdayTest.php index c4736e236..2dbd04169 100644 --- a/tests/Base/YasumiWorkdayTest.php +++ b/tests/Base/YasumiWorkdayTest.php @@ -16,8 +16,6 @@ use DateTime; use DateTimeImmutable; -use DateTimeZone; -use Exception; use PHPUnit\Framework\TestCase; use Yasumi\Yasumi; @@ -28,7 +26,7 @@ class YasumiWorkdayTest extends TestCase /** * Tests that the nextWorkingDay function returns an object that implements the DateTimeInterface (e.g. DateTime). * - * @throws Exception + * @throws \Exception */ public function testNextWorkingDay(): void { @@ -39,24 +37,24 @@ public function testNextWorkingDay(): void $expectedDate = '2016-07-05'; // Assertion using a DateTime instance - $startDate = new DateTime($date, new DateTimeZone($timezone)); + $startDate = new \DateTime($date, new \DateTimeZone($timezone)); $nextWorkingDay = Yasumi::nextWorkingDay($provider, $startDate); - self::assertInstanceOf(DateTimeImmutable::class, $nextWorkingDay); + self::assertInstanceOf(\DateTimeImmutable::class, $nextWorkingDay); self::assertEquals($expectedDate, $nextWorkingDay->format(self::FORMAT_DATE)); // Assertion using a DateTimeImmutable instance - $startDate = new DateTimeImmutable($date, new DateTimeZone($timezone)); + $startDate = new \DateTimeImmutable($date, new \DateTimeZone($timezone)); $nextWorkingDay = Yasumi::nextWorkingDay($provider, $startDate); - self::assertInstanceOf(DateTimeImmutable::class, $nextWorkingDay); + self::assertInstanceOf(\DateTimeImmutable::class, $nextWorkingDay); self::assertEquals($expectedDate, $nextWorkingDay->format(self::FORMAT_DATE)); } /** * Tests that the prevWorkingDay function returns an object that implements the DateTimeInterface (e.g. DateTime). * - * @throws Exception + * @throws \Exception */ public function testPreviousWorkingDay(): void { @@ -67,17 +65,17 @@ public function testPreviousWorkingDay(): void $expectedDate = '2016-07-01'; // Assertion using a DateTime instance - $startDate = new DateTime($date, new DateTimeZone($timezone)); + $startDate = new \DateTime($date, new \DateTimeZone($timezone)); $previousWorkingDay = Yasumi::prevWorkingDay($provider, $startDate); - self::assertInstanceOf(DateTimeImmutable::class, $previousWorkingDay); + self::assertInstanceOf(\DateTimeImmutable::class, $previousWorkingDay); self::assertEquals($expectedDate, $previousWorkingDay->format(self::FORMAT_DATE)); // Assertion using a DateTimeImmutable instance - $startDate = new DateTimeImmutable($date, new DateTimeZone($timezone)); + $startDate = new \DateTimeImmutable($date, new \DateTimeZone($timezone)); $previousWorkingDay = Yasumi::prevWorkingDay($provider, $startDate); - self::assertInstanceOf(DateTimeImmutable::class, $previousWorkingDay); + self::assertInstanceOf(\DateTimeImmutable::class, $previousWorkingDay); self::assertEquals($expectedDate, $previousWorkingDay->format(self::FORMAT_DATE)); } @@ -85,7 +83,7 @@ public function testPreviousWorkingDay(): void * Tests that the prevWorkingDay and nextWorkingDay functions returns an object that implements the * DateTimeInterface (e.g. DateTime) when an interval is chosen that passes the year boundary (i.e. beyond 12/31). * - * @throws Exception + * @throws \Exception */ public function testYearBoundary(): void { @@ -114,22 +112,22 @@ public function testYearBoundary(): void $expectedPrevious = '2015-12-18'; // Assertion using a DateTime instance - $startDate = new DateTime($start, new DateTimeZone($timezone)); + $startDate = new \DateTime($start, new \DateTimeZone($timezone)); $nextWorkingDay = Yasumi::nextWorkingDay($provider, $startDate, $interval); self::assertEquals($expectedNext, $nextWorkingDay->format(self::FORMAT_DATE)); - $startDate = new DateTime($expectedNext, new DateTimeZone($timezone)); + $startDate = new \DateTime($expectedNext, new \DateTimeZone($timezone)); $previousWorkingDay = Yasumi::prevWorkingDay($provider, $startDate, $interval); self::assertEquals($expectedPrevious, $previousWorkingDay->format(self::FORMAT_DATE)); // Assertion using a DateTimeImmutable instance - $startDate = new DateTimeImmutable($start, new DateTimeZone($timezone)); + $startDate = new \DateTimeImmutable($start, new \DateTimeZone($timezone)); $nextWorkingDay = Yasumi::nextWorkingDay($provider, $startDate, $interval); self::assertEquals($expectedNext, $nextWorkingDay->format(self::FORMAT_DATE)); - $startDate = new DateTimeImmutable($expectedNext, new DateTimeZone($timezone)); + $startDate = new \DateTimeImmutable($expectedNext, new \DateTimeZone($timezone)); $previousWorkingDay = Yasumi::prevWorkingDay($provider, $startDate, $interval); self::assertEquals($expectedPrevious, $previousWorkingDay->format(self::FORMAT_DATE)); } @@ -139,13 +137,13 @@ public function testYearBoundary(): void * * @dataProvider dataProviderWorkDayNextYear * - * @throws Exception + * @throws \Exception */ public function testWorkDayIsNextYear(string $start, int $workdays, string $expectedNext): void { $provider = 'USA'; $timezone = 'America/New_York'; - $startDate = new DateTime($start, new DateTimeZone($timezone)); + $startDate = new \DateTime($start, new \DateTimeZone($timezone)); $nextWorkingDay = Yasumi::nextWorkingDay($provider, $startDate, $workdays); self::assertEquals($expectedNext, $nextWorkingDay->format(self::FORMAT_DATE)); @@ -175,13 +173,13 @@ public function dataProviderWorkDayNextYear(): array * * @dataProvider dataProviderWorkDayPreviousYear * - * @throws Exception + * @throws \Exception */ public function testWorkDayIsPreviousYear(string $start, int $workdays, string $expectedNext): void { $provider = 'USA'; $timezone = 'America/New_York'; - $startDate = new DateTime($start, new DateTimeZone($timezone)); + $startDate = new \DateTime($start, new \DateTimeZone($timezone)); $previousWorkingDay = Yasumi::prevWorkingDay($provider, $startDate, $workdays); self::assertEquals($expectedNext, $previousWorkingDay->format(self::FORMAT_DATE)); diff --git a/tests/Belgium/AllSaintsDayTest.php b/tests/Belgium/AllSaintsDayTest.php index 84170fec1..7b6177c08 100644 --- a/tests/Belgium/AllSaintsDayTest.php +++ b/tests/Belgium/AllSaintsDayTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\Belgium; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,8 +32,8 @@ class AllSaintsDayTest extends BelgiumBaseTestCase implements HolidayTestCase * * @dataProvider HolidayDataProvider * - * @param int $year the year for which the holiday defined in this test needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which the holiday defined in this test needs to be tested + * @param \DateTime $expected the expected date */ public function testHoliday(int $year, \DateTimeInterface $expected): void { @@ -47,7 +45,7 @@ public function testHoliday(int $year, \DateTimeInterface $expected): void * * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function HolidayDataProvider(): array { @@ -57,7 +55,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -72,7 +70,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Belgium/ArmisticeDayTest.php b/tests/Belgium/ArmisticeDayTest.php index 7293e01a6..c2c2291f5 100644 --- a/tests/Belgium/ArmisticeDayTest.php +++ b/tests/Belgium/ArmisticeDayTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\Belgium; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,8 +32,8 @@ class ArmisticeDayTest extends BelgiumBaseTestCase implements HolidayTestCase * * @dataProvider HolidayDataProvider * - * @param int $year the year for which the holiday defined in this test needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which the holiday defined in this test needs to be tested + * @param \DateTime $expected the expected date */ public function testHoliday(int $year, \DateTimeInterface $expected): void { @@ -47,7 +45,7 @@ public function testHoliday(int $year, \DateTimeInterface $expected): void * * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function HolidayDataProvider(): array { @@ -57,7 +55,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -72,7 +70,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Belgium/AscensionDayTest.php b/tests/Belgium/AscensionDayTest.php index 9a7c1c4a8..cbcbdcfa1 100644 --- a/tests/Belgium/AscensionDayTest.php +++ b/tests/Belgium/AscensionDayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Belgium; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -33,7 +30,7 @@ class AscensionDayTest extends BelgiumBaseTestCase implements HolidayTestCase /** * Tests the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHoliday(): void { @@ -42,14 +39,14 @@ public function testHoliday(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-4-30", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-4-30", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -64,7 +61,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Belgium/AssumptionOfMaryTest.php b/tests/Belgium/AssumptionOfMaryTest.php index c76bc9b5c..515f75f08 100644 --- a/tests/Belgium/AssumptionOfMaryTest.php +++ b/tests/Belgium/AssumptionOfMaryTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\Belgium; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,8 +32,8 @@ class AssumptionOfMaryTest extends BelgiumBaseTestCase implements HolidayTestCas * * @dataProvider HolidayDataProvider * - * @param int $year the year for which the holiday defined in this test needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which the holiday defined in this test needs to be tested + * @param \DateTime $expected the expected date */ public function testHoliday(int $year, \DateTimeInterface $expected): void { @@ -47,7 +45,7 @@ public function testHoliday(int $year, \DateTimeInterface $expected): void * * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function HolidayDataProvider(): array { @@ -57,7 +55,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -72,7 +70,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Belgium/BelgiumTest.php b/tests/Belgium/BelgiumTest.php index 1cc601171..f747802d2 100644 --- a/tests/Belgium/BelgiumTest.php +++ b/tests/Belgium/BelgiumTest.php @@ -14,7 +14,6 @@ namespace Yasumi\tests\Belgium; -use ReflectionException; use Yasumi\Holiday; /** @@ -91,7 +90,7 @@ public function testOtherHolidays(): void } /** - * @throws ReflectionException + * @throws \ReflectionException * @throws \Exception */ public function testSources(): void diff --git a/tests/Belgium/ChristmasTest.php b/tests/Belgium/ChristmasTest.php index 525096eda..48badfd79 100644 --- a/tests/Belgium/ChristmasTest.php +++ b/tests/Belgium/ChristmasTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\Belgium; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,8 +32,8 @@ class ChristmasTest extends BelgiumBaseTestCase implements HolidayTestCase * * @dataProvider HolidayDataProvider * - * @param int $year the year for which the holiday defined in this test needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which the holiday defined in this test needs to be tested + * @param \DateTime $expected the expected date */ public function testHoliday(int $year, \DateTimeInterface $expected): void { @@ -47,7 +45,7 @@ public function testHoliday(int $year, \DateTimeInterface $expected): void * * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function HolidayDataProvider(): array { @@ -57,7 +55,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -72,7 +70,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Belgium/EasterMondayTest.php b/tests/Belgium/EasterMondayTest.php index 477d96e22..6f64b0bb2 100644 --- a/tests/Belgium/EasterMondayTest.php +++ b/tests/Belgium/EasterMondayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Belgium; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -33,7 +30,7 @@ class EasterMondayTest extends BelgiumBaseTestCase implements HolidayTestCase /** * Tests the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHoliday(): void { @@ -42,14 +39,14 @@ public function testHoliday(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-3-28", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-3-28", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -64,7 +61,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Belgium/EasterTest.php b/tests/Belgium/EasterTest.php index 1d5161837..6fd474c9c 100644 --- a/tests/Belgium/EasterTest.php +++ b/tests/Belgium/EasterTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Belgium; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -33,7 +30,7 @@ class EasterTest extends BelgiumBaseTestCase implements HolidayTestCase /** * Tests Easter. * - * @throws Exception + * @throws \Exception */ public function testEaster(): void { @@ -42,14 +39,14 @@ public function testEaster(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-4-4", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-4-4", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -64,7 +61,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Belgium/InternationalWorkersDayTest.php b/tests/Belgium/InternationalWorkersDayTest.php index da29b5ba5..4cc6873b9 100644 --- a/tests/Belgium/InternationalWorkersDayTest.php +++ b/tests/Belgium/InternationalWorkersDayTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\Belgium; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,8 +32,8 @@ class InternationalWorkersDayTest extends BelgiumBaseTestCase implements Holiday * * @dataProvider HolidayDataProvider * - * @param int $year the year for which the holiday defined in this test needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which the holiday defined in this test needs to be tested + * @param \DateTime $expected the expected date */ public function testHoliday(int $year, \DateTimeInterface $expected): void { @@ -47,7 +45,7 @@ public function testHoliday(int $year, \DateTimeInterface $expected): void * * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function HolidayDataProvider(): array { @@ -57,7 +55,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -72,7 +70,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Belgium/NationalDayTest.php b/tests/Belgium/NationalDayTest.php index 5021959b0..5f20b324a 100644 --- a/tests/Belgium/NationalDayTest.php +++ b/tests/Belgium/NationalDayTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\Belgium; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,8 +32,8 @@ class NationalDayTest extends BelgiumBaseTestCase implements HolidayTestCase * * @dataProvider HolidayDataProvider * - * @param int $year the year for which the holiday defined in this test needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which the holiday defined in this test needs to be tested + * @param \DateTime $expected the expected date */ public function testHoliday(int $year, \DateTimeInterface $expected): void { @@ -47,7 +45,7 @@ public function testHoliday(int $year, \DateTimeInterface $expected): void * * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function HolidayDataProvider(): array { @@ -57,7 +55,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -72,7 +70,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Belgium/NewYearsDayTest.php b/tests/Belgium/NewYearsDayTest.php index 926e7b4f2..bcac83a8c 100644 --- a/tests/Belgium/NewYearsDayTest.php +++ b/tests/Belgium/NewYearsDayTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\Belgium; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,8 +32,8 @@ class NewYearsDayTest extends BelgiumBaseTestCase implements HolidayTestCase * * @dataProvider HolidayDataProvider * - * @param int $year the year for which the holiday defined in this test needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which the holiday defined in this test needs to be tested + * @param \DateTime $expected the expected date */ public function testHoliday(int $year, \DateTimeInterface $expected): void { @@ -47,7 +45,7 @@ public function testHoliday(int $year, \DateTimeInterface $expected): void * * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function HolidayDataProvider(): array { @@ -57,7 +55,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -72,7 +70,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Belgium/PentecostTest.php b/tests/Belgium/PentecostTest.php index 0703498e5..0453ee6d9 100644 --- a/tests/Belgium/PentecostTest.php +++ b/tests/Belgium/PentecostTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Belgium; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -33,7 +30,7 @@ class PentecostTest extends BelgiumBaseTestCase implements HolidayTestCase /** * Tests Pentecost. * - * @throws Exception + * @throws \Exception */ public function testHoliday(): void { @@ -42,14 +39,14 @@ public function testHoliday(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-6-8", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-6-8", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -64,7 +61,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Belgium/pentecostMondayTest.php b/tests/Belgium/pentecostMondayTest.php index 5cc3b89d4..b142db3ab 100644 --- a/tests/Belgium/pentecostMondayTest.php +++ b/tests/Belgium/pentecostMondayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Belgium; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -33,7 +30,7 @@ class pentecostMondayTest extends BelgiumBaseTestCase implements HolidayTestCase /** * Tests Pentecost Monday. * - * @throws Exception + * @throws \Exception */ public function testHoliday(): void { @@ -42,14 +39,14 @@ public function testHoliday(): void self::REGION, 'pentecostMonday', $year, - new DateTime("$year-6-1", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-6-1", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -64,7 +61,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Bosnia/BosniaTest.php b/tests/Bosnia/BosniaTest.php index 673532c57..d335fd1d2 100644 --- a/tests/Bosnia/BosniaTest.php +++ b/tests/Bosnia/BosniaTest.php @@ -14,7 +14,6 @@ namespace Yasumi\tests\Bosnia; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\ProviderTestCase; @@ -90,7 +89,7 @@ public function testOtherHolidays(): void } /** - * @throws ReflectionException + * @throws \ReflectionException * @throws \Exception */ public function testSources(): void diff --git a/tests/Bosnia/ChristmasDayTest.php b/tests/Bosnia/ChristmasDayTest.php index e3cd0b347..1d2766cae 100644 --- a/tests/Bosnia/ChristmasDayTest.php +++ b/tests/Bosnia/ChristmasDayTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\Bosnia; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,8 +32,8 @@ class ChristmasDayTest extends BosniaBaseTestCase implements HolidayTestCase * * @dataProvider HolidayDataProvider * - * @param int $year the year for which the holiday defined in this test needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which the holiday defined in this test needs to be tested + * @param \DateTime $expected the expected date */ public function testHoliday(int $year, \DateTimeInterface $expected): void { @@ -47,7 +45,7 @@ public function testHoliday(int $year, \DateTimeInterface $expected): void * * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function HolidayDataProvider(): array { @@ -57,7 +55,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -72,7 +70,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Bosnia/DayAfterNewYearsDay.php b/tests/Bosnia/DayAfterNewYearsDay.php index 061987323..67e02462e 100644 --- a/tests/Bosnia/DayAfterNewYearsDay.php +++ b/tests/Bosnia/DayAfterNewYearsDay.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\Bosnia; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,8 +32,8 @@ class DayAfterNewYearsDay extends BosniaBaseTestCase implements HolidayTestCase * * @dataProvider HolidayDataProvider * - * @param int $year the year for which the holiday defined in this test needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which the holiday defined in this test needs to be tested + * @param \DateTime $expected the expected date */ public function testHoliday(int $year, \DateTimeInterface $expected): void { @@ -47,7 +45,7 @@ public function testHoliday(int $year, \DateTimeInterface $expected): void * * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function HolidayDataProvider(): array { @@ -57,7 +55,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -72,7 +70,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Bosnia/EasterTest.php b/tests/Bosnia/EasterTest.php index f81df105c..8a5df60a5 100644 --- a/tests/Bosnia/EasterTest.php +++ b/tests/Bosnia/EasterTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Bosnia; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -33,7 +30,7 @@ class EasterTest extends BosniaBaseTestCase implements HolidayTestCase /** * Tests the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHoliday(): void { @@ -42,14 +39,14 @@ public function testHoliday(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-4-15", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-4-15", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -64,7 +61,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Bosnia/IndependenceDayTest.php b/tests/Bosnia/IndependenceDayTest.php index c3080cdba..aae10f9cc 100644 --- a/tests/Bosnia/IndependenceDayTest.php +++ b/tests/Bosnia/IndependenceDayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Bosnia; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -38,7 +35,7 @@ class IndependenceDayTest extends BosniaBaseTestCase implements HolidayTestCase /** * Tests Independence Day on or after 1992. * - * @throws Exception + * @throws \Exception */ public function testIndependenceDayOnAfter1992(): void { @@ -47,14 +44,14 @@ public function testIndependenceDayOnAfter1992(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-3-1", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-3-1", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests Independence Day before 1992. * - * @throws Exception + * @throws \Exception */ public function testIndependenceDayBefore1992(): void { @@ -68,7 +65,7 @@ public function testIndependenceDayBefore1992(): void /** * Tests translated name of Independence Day. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -83,7 +80,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Bosnia/InternationalWorkersDayTest.php b/tests/Bosnia/InternationalWorkersDayTest.php index 84a25f8be..22e23a584 100644 --- a/tests/Bosnia/InternationalWorkersDayTest.php +++ b/tests/Bosnia/InternationalWorkersDayTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\Bosnia; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,8 +32,8 @@ class InternationalWorkersDayTest extends BosniaBaseTestCase implements HolidayT * * @dataProvider HolidayDataProvider * - * @param int $year the year for which the holiday defined in this test needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which the holiday defined in this test needs to be tested + * @param \DateTime $expected the expected date */ public function testHoliday(int $year, \DateTimeInterface $expected): void { @@ -45,7 +43,7 @@ public function testHoliday(int $year, \DateTimeInterface $expected): void /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -60,7 +58,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { @@ -72,7 +70,7 @@ public function testHolidayType(): void * * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function HolidayDataProvider(): array { diff --git a/tests/Bosnia/NewYearsDayTest.php b/tests/Bosnia/NewYearsDayTest.php index 5dc429897..4ba081733 100644 --- a/tests/Bosnia/NewYearsDayTest.php +++ b/tests/Bosnia/NewYearsDayTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\Bosnia; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,8 +32,8 @@ class NewYearsDayTest extends BosniaBaseTestCase implements HolidayTestCase * * @dataProvider HolidayDataProvider * - * @param int $year the year for which the holiday defined in this test needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which the holiday defined in this test needs to be tested + * @param \DateTime $expected the expected date */ public function testHoliday(int $year, \DateTimeInterface $expected): void { @@ -47,7 +45,7 @@ public function testHoliday(int $year, \DateTimeInterface $expected): void * * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function HolidayDataProvider(): array { @@ -57,7 +55,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -72,7 +70,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Bosnia/OrthodoxChristmasDay.php b/tests/Bosnia/OrthodoxChristmasDay.php index d94e12391..152c3cd6e 100644 --- a/tests/Bosnia/OrthodoxChristmasDay.php +++ b/tests/Bosnia/OrthodoxChristmasDay.php @@ -14,7 +14,6 @@ namespace Yasumi\tests\Bosnia; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -31,7 +30,7 @@ class OrthodoxChristmasDay extends BosniaBaseTestCase implements HolidayTestCase /** * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function holidayDataProvider(): array { @@ -49,7 +48,7 @@ public function testHoliday(int $year, \DateTimeInterface $expected): void /** * {@inheritdoc} * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -64,7 +63,7 @@ public function testTranslation(): void /** * {@inheritdoc} * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Bosnia/SecondLabourDay.php b/tests/Bosnia/SecondLabourDay.php index 52bb1968d..f430cfa61 100644 --- a/tests/Bosnia/SecondLabourDay.php +++ b/tests/Bosnia/SecondLabourDay.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\Bosnia; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,8 +32,8 @@ class SecondLabourDay extends BosniaBaseTestCase implements HolidayTestCase * * @dataProvider HolidayDataProvider * - * @param int $year the year for which the holiday defined in this test needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which the holiday defined in this test needs to be tested + * @param \DateTime $expected the expected date */ public function testHoliday(int $year, \DateTimeInterface $expected): void { @@ -45,7 +43,7 @@ public function testHoliday(int $year, \DateTimeInterface $expected): void /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -60,7 +58,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { @@ -72,7 +70,7 @@ public function testHolidayType(): void * * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function HolidayDataProvider(): array { diff --git a/tests/Bosnia/StatehoodDayTest.php b/tests/Bosnia/StatehoodDayTest.php index 0b2040a33..73385178f 100644 --- a/tests/Bosnia/StatehoodDayTest.php +++ b/tests/Bosnia/StatehoodDayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Bosnia; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -38,7 +35,7 @@ class StatehoodDayTest extends BosniaBaseTestCase implements HolidayTestCase /** * Tests Statehood Day on or after 1943. * - * @throws Exception + * @throws \Exception */ public function testStatehoodDayOnAfter1943(): void { @@ -47,14 +44,14 @@ public function testStatehoodDayOnAfter1943(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-11-25", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-11-25", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests Statehood Day before 1943. * - * @throws Exception + * @throws \Exception */ public function testStatehoodDayBefore1943(): void { @@ -68,7 +65,7 @@ public function testStatehoodDayBefore1943(): void /** * Tests translated name of Statehood Day. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -83,7 +80,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Brazil/AllSoulsDayTest.php b/tests/Brazil/AllSoulsDayTest.php index cc6692835..15aec8f95 100644 --- a/tests/Brazil/AllSoulsDayTest.php +++ b/tests/Brazil/AllSoulsDayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Brazil; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -38,7 +35,7 @@ class AllSoulsDayTest extends BrazilBaseTestCase implements HolidayTestCase /** * Tests Dia dos Finados on or after 1300. * - * @throws Exception + * @throws \Exception */ public function testDiaDosFinadosAfter1300(): void { @@ -47,14 +44,14 @@ public function testDiaDosFinadosAfter1300(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-11-02", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-11-02", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests Dia dos Finados on or before 1300. * - * @throws Exception + * @throws \Exception */ public function testDiaDosFinadosBefore1300(): void { @@ -65,7 +62,7 @@ public function testDiaDosFinadosBefore1300(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -76,7 +73,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Brazil/AshWednesdayTest.php b/tests/Brazil/AshWednesdayTest.php index 2342686b1..5490d7f5e 100644 --- a/tests/Brazil/AshWednesdayTest.php +++ b/tests/Brazil/AshWednesdayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Brazil; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -33,7 +30,7 @@ class AshWednesdayTest extends BrazilBaseTestCase implements HolidayTestCase /** * Tests the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHoliday(): void { @@ -42,14 +39,14 @@ public function testHoliday(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-2-17", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-2-17", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests translated name of Ash Wednesday. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -64,7 +61,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Brazil/BrazilTest.php b/tests/Brazil/BrazilTest.php index 01396d761..4ec2ce750 100644 --- a/tests/Brazil/BrazilTest.php +++ b/tests/Brazil/BrazilTest.php @@ -14,7 +14,6 @@ namespace Yasumi\tests\Brazil; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\ProviderTestCase; @@ -95,7 +94,7 @@ public function testOtherHolidays(): void } /** - * @throws ReflectionException + * @throws \ReflectionException * @throws \Exception */ public function testSources(): void diff --git a/tests/Brazil/CarnavalMondayTest.php b/tests/Brazil/CarnavalMondayTest.php index e4fad2483..ba98ac50b 100644 --- a/tests/Brazil/CarnavalMondayTest.php +++ b/tests/Brazil/CarnavalMondayTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\Brazil; -use DateInterval; -use Exception; use Yasumi\Holiday; use Yasumi\Provider\ChristianHolidays; use Yasumi\tests\HolidayTestCase; @@ -40,7 +38,7 @@ class CarnavalMondayTest extends BrazilBaseTestCase implements HolidayTestCase /** * Tests Carnaval Monday on or after 1700. * - * @throws Exception + * @throws \Exception */ public function testCarnavalMondayAfter1700(): void { @@ -49,14 +47,14 @@ public function testCarnavalMondayAfter1700(): void self::REGION, self::HOLIDAY, $year, - $this->calculateEaster($year, self::TIMEZONE)->sub(new DateInterval('P48D')) + $this->calculateEaster($year, self::TIMEZONE)->sub(new \DateInterval('P48D')) ); } /** * Tests Carnaval Monday on or before 1700. * - * @throws Exception + * @throws \Exception */ public function testCarnavalMondayBefore1700(): void { @@ -67,7 +65,7 @@ public function testCarnavalMondayBefore1700(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -78,7 +76,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Brazil/CarnavalTuesdayTest.php b/tests/Brazil/CarnavalTuesdayTest.php index d39111db3..5157961e4 100644 --- a/tests/Brazil/CarnavalTuesdayTest.php +++ b/tests/Brazil/CarnavalTuesdayTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\Brazil; -use DateInterval; -use Exception; use Yasumi\Holiday; use Yasumi\Provider\ChristianHolidays; use Yasumi\tests\HolidayTestCase; @@ -40,7 +38,7 @@ class CarnavalTuesdayTest extends BrazilBaseTestCase implements HolidayTestCase /** * Tests Carnaval Tuesday on or after 1700. * - * @throws Exception + * @throws \Exception */ public function testCarnavalTuesdayAfter1700(): void { @@ -49,14 +47,14 @@ public function testCarnavalTuesdayAfter1700(): void self::REGION, self::HOLIDAY, $year, - $this->calculateEaster($year, self::TIMEZONE)->sub(new DateInterval('P47D')) + $this->calculateEaster($year, self::TIMEZONE)->sub(new \DateInterval('P47D')) ); } /** * Tests Carnaval Tuesday on or before 1700. * - * @throws Exception + * @throws \Exception */ public function testCarnavalTuesdayBefore1700(): void { @@ -67,7 +65,7 @@ public function testCarnavalTuesdayBefore1700(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -78,7 +76,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Brazil/ChristmasDayTest.php b/tests/Brazil/ChristmasDayTest.php index bc3217a38..d3aafd116 100644 --- a/tests/Brazil/ChristmasDayTest.php +++ b/tests/Brazil/ChristmasDayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Brazil; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -33,7 +30,7 @@ class ChristmasDayTest extends BrazilBaseTestCase implements HolidayTestCase /** * Tests Christmas Day. * - * @throws Exception + * @throws \Exception */ public function testChristmasDay(): void { @@ -42,14 +39,14 @@ public function testChristmasDay(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-12-25", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-12-25", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -64,7 +61,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Brazil/CorpusChristiTest.php b/tests/Brazil/CorpusChristiTest.php index 0d61b003e..7be8d2ced 100644 --- a/tests/Brazil/CorpusChristiTest.php +++ b/tests/Brazil/CorpusChristiTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\Brazil; -use DateInterval; -use Exception; use Yasumi\Holiday; use Yasumi\Provider\ChristianHolidays; use Yasumi\tests\HolidayTestCase; @@ -35,7 +33,7 @@ class CorpusChristiTest extends BrazilBaseTestCase implements HolidayTestCase /** * Tests Corpus Christi. * - * @throws Exception + * @throws \Exception */ public function testCorpusChristi(): void { @@ -44,14 +42,14 @@ public function testCorpusChristi(): void self::REGION, self::HOLIDAY, $year, - $this->calculateEaster($year, self::TIMEZONE)->add(new DateInterval('P60D')) + $this->calculateEaster($year, self::TIMEZONE)->add(new \DateInterval('P60D')) ); } /** * Tests translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -66,7 +64,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Brazil/EasterTest.php b/tests/Brazil/EasterTest.php index 765480f37..7eb523ac1 100644 --- a/tests/Brazil/EasterTest.php +++ b/tests/Brazil/EasterTest.php @@ -14,7 +14,6 @@ namespace Yasumi\tests\Brazil; -use Exception; use Yasumi\Holiday; use Yasumi\Provider\ChristianHolidays; use Yasumi\tests\HolidayTestCase; @@ -34,7 +33,7 @@ class EasterTest extends BrazilBaseTestCase implements HolidayTestCase /** * Tests Easter. * - * @throws Exception + * @throws \Exception */ public function testEaster(): void { @@ -45,7 +44,7 @@ public function testEaster(): void /** * Tests translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -60,7 +59,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Brazil/GoodFridayTest.php b/tests/Brazil/GoodFridayTest.php index 866574985..5109a0579 100644 --- a/tests/Brazil/GoodFridayTest.php +++ b/tests/Brazil/GoodFridayTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\Brazil; -use DateInterval; -use Exception; use Yasumi\Holiday; use Yasumi\Provider\ChristianHolidays; use Yasumi\tests\HolidayTestCase; @@ -35,7 +33,7 @@ class GoodFridayTest extends BrazilBaseTestCase implements HolidayTestCase /** * Tests Good Friday. * - * @throws Exception + * @throws \Exception */ public function testGoodFriday(): void { @@ -44,14 +42,14 @@ public function testGoodFriday(): void self::REGION, self::HOLIDAY, $year, - $this->calculateEaster($year, self::TIMEZONE)->sub(new DateInterval('P2D')) + $this->calculateEaster($year, self::TIMEZONE)->sub(new \DateInterval('P2D')) ); } /** * Tests translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -66,7 +64,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Brazil/IndependenceDayTest.php b/tests/Brazil/IndependenceDayTest.php index 393e327ae..4f75f7d3e 100644 --- a/tests/Brazil/IndependenceDayTest.php +++ b/tests/Brazil/IndependenceDayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Brazil; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -38,7 +35,7 @@ class IndependenceDayTest extends BrazilBaseTestCase implements HolidayTestCase /** * Tests Dia da independência do Brasil on or after 1822. * - * @throws Exception + * @throws \Exception */ public function testDiaDaIndependenciaDoBrasilAfter1822(): void { @@ -47,14 +44,14 @@ public function testDiaDaIndependenciaDoBrasilAfter1822(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-09-07", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-09-07", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests Dia da independência do Brasil on or before 1822. * - * @throws Exception + * @throws \Exception */ public function testDiaDaIndependenciaDoBrasilBefore1822(): void { @@ -65,7 +62,7 @@ public function testDiaDaIndependenciaDoBrasilBefore1822(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -81,7 +78,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Brazil/InternationalWorkersDayTest.php b/tests/Brazil/InternationalWorkersDayTest.php index 06138c9b0..b9f44abf5 100644 --- a/tests/Brazil/InternationalWorkersDayTest.php +++ b/tests/Brazil/InternationalWorkersDayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Brazil; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -33,7 +30,7 @@ class InternationalWorkersDayTest extends BrazilBaseTestCase implements HolidayT /** * Tests International Workers' Day. * - * @throws Exception + * @throws \Exception */ public function testInternationalWorkersDay(): void { @@ -42,14 +39,14 @@ public function testInternationalWorkersDay(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-5-1", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-5-1", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -64,7 +61,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Brazil/NewYearsDayTest.php b/tests/Brazil/NewYearsDayTest.php index 221a30422..b1c3495a2 100644 --- a/tests/Brazil/NewYearsDayTest.php +++ b/tests/Brazil/NewYearsDayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Brazil; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -33,7 +30,7 @@ class NewYearsDayTest extends BrazilBaseTestCase implements HolidayTestCase /** * Tests New Years Day. * - * @throws Exception + * @throws \Exception */ public function testNewYearsDay(): void { @@ -42,14 +39,14 @@ public function testNewYearsDay(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-1-1", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-1-1", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -64,7 +61,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Brazil/OurLadyOfAparecidaDayTest.php b/tests/Brazil/OurLadyOfAparecidaDayTest.php index 65b270fbe..a16da5a3d 100644 --- a/tests/Brazil/OurLadyOfAparecidaDayTest.php +++ b/tests/Brazil/OurLadyOfAparecidaDayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Brazil; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -38,7 +35,7 @@ class OurLadyOfAparecidaDayTest extends BrazilBaseTestCase implements HolidayTes /** * Tests Nossa Senhora Aparecida on or after 1980. * - * @throws Exception + * @throws \Exception */ public function testNossaSenhoraAparecidaAfter1980(): void { @@ -47,14 +44,14 @@ public function testNossaSenhoraAparecidaAfter1980(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-10-12", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-10-12", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests Nossa Senhora Aparecida on or before 1980. * - * @throws Exception + * @throws \Exception */ public function testNossaSenhoraAparecidaBefore1980(): void { @@ -65,7 +62,7 @@ public function testNossaSenhoraAparecidaBefore1980(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -81,7 +78,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Brazil/ProclamationOfRepublicDayTest.php b/tests/Brazil/ProclamationOfRepublicDayTest.php index 6b7393eb6..f5fe4fbdf 100644 --- a/tests/Brazil/ProclamationOfRepublicDayTest.php +++ b/tests/Brazil/ProclamationOfRepublicDayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Brazil; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -38,7 +35,7 @@ class ProclamationOfRepublicDayTest extends BrazilBaseTestCase implements Holida /** * Tests Proclamação da República on or after 1889. * - * @throws Exception + * @throws \Exception */ public function testProclamacaoDaRepublicaAfter1889(): void { @@ -47,14 +44,14 @@ public function testProclamacaoDaRepublicaAfter1889(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-11-15", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-11-15", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests Proclamação da República on or before 1889. * - * @throws Exception + * @throws \Exception */ public function testProclamacaoDaRepublicaBefore1889(): void { @@ -65,7 +62,7 @@ public function testProclamacaoDaRepublicaBefore1889(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -81,7 +78,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Brazil/TiradentesDayTest.php b/tests/Brazil/TiradentesDayTest.php index f80d9f07a..760ba52f2 100644 --- a/tests/Brazil/TiradentesDayTest.php +++ b/tests/Brazil/TiradentesDayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Brazil; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -38,7 +35,7 @@ class TiradentesDayTest extends BrazilBaseTestCase implements HolidayTestCase /** * Tests Dia de Tiradentes on or after 1792. * - * @throws Exception + * @throws \Exception */ public function testDiaDeTiradentesAfter1792(): void { @@ -47,14 +44,14 @@ public function testDiaDeTiradentesAfter1792(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-04-21", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-04-21", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests Dia de Tiradentes on or before 1792. * - * @throws Exception + * @throws \Exception */ public function testDiaDeTiradentesBefore1792(): void { @@ -65,7 +62,7 @@ public function testDiaDeTiradentesBefore1792(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -76,7 +73,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Canada/Alberta/AlbertaTest.php b/tests/Canada/Alberta/AlbertaTest.php index 921d74da0..c9bf62bd5 100644 --- a/tests/Canada/Alberta/AlbertaTest.php +++ b/tests/Canada/Alberta/AlbertaTest.php @@ -14,7 +14,6 @@ namespace Yasumi\tests\Canada\Alberta; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\ProviderTestCase; @@ -90,7 +89,7 @@ public function testOtherHolidays(): void } /** - * @throws ReflectionException + * @throws \ReflectionException * @throws \Exception */ public function testSources(): void diff --git a/tests/Canada/BritishColumbia/BritishColumbiaTest.php b/tests/Canada/BritishColumbia/BritishColumbiaTest.php index 7eee55af8..c71ac9472 100644 --- a/tests/Canada/BritishColumbia/BritishColumbiaTest.php +++ b/tests/Canada/BritishColumbia/BritishColumbiaTest.php @@ -14,7 +14,6 @@ namespace Yasumi\tests\Canada\BritishColumbia; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\ProviderTestCase; @@ -90,7 +89,7 @@ public function testOtherHolidays(): void } /** - * @throws ReflectionException + * @throws \ReflectionException * @throws \Exception */ public function testSources(): void diff --git a/tests/Canada/CanadaDayTest.php b/tests/Canada/CanadaDayTest.php index 3a1b10c38..a0e2ecbab 100644 --- a/tests/Canada/CanadaDayTest.php +++ b/tests/Canada/CanadaDayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Canada; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -38,7 +35,7 @@ class CanadaDayTest extends CanadaBaseTestCase implements HolidayTestCase /** * Tests Canada Day on or after 1983. Canada Day was established in 1983 on July 1st. * - * @throws Exception + * @throws \Exception */ public function testCanadaDayOnAfter1983(): void { @@ -47,21 +44,21 @@ public function testCanadaDayOnAfter1983(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-07-01", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-07-01", new \DateTimeZone(self::TIMEZONE)) ); $year = 2018; // July 1 is Sunday $this->assertHoliday( self::REGION, self::HOLIDAY, $year, - new DateTime("$year-07-02", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-07-02", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests Canada Day before 1879. Canada Day was established as Dominion Day in 1879 on July 1st. * - * @throws Exception + * @throws \Exception */ public function testCanadaDayBefore1879(): void { @@ -75,7 +72,7 @@ public function testCanadaDayBefore1879(): void /** * Tests translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -90,7 +87,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Canada/CanadaTest.php b/tests/Canada/CanadaTest.php index 93c454dd6..5aefffc13 100644 --- a/tests/Canada/CanadaTest.php +++ b/tests/Canada/CanadaTest.php @@ -14,7 +14,6 @@ namespace Yasumi\tests\Canada; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\ProviderTestCase; @@ -89,7 +88,7 @@ public function testOtherHolidays(): void } /** - * @throws ReflectionException + * @throws \ReflectionException * @throws \Exception */ public function testSources(): void diff --git a/tests/Canada/ChristmasDayTest.php b/tests/Canada/ChristmasDayTest.php index c5be59386..f658ed64f 100644 --- a/tests/Canada/ChristmasDayTest.php +++ b/tests/Canada/ChristmasDayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Canada; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -33,7 +30,7 @@ class ChristmasDayTest extends CanadaBaseTestCase implements HolidayTestCase /** * Tests Christmas Day. Christmas Day is celebrated on December 25th. * - * @throws Exception + * @throws \Exception */ public function testChristmasDay(): void { @@ -42,14 +39,14 @@ public function testChristmasDay(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-12-25", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-12-25", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -64,7 +61,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Canada/LabourDayTest.php b/tests/Canada/LabourDayTest.php index d73c4851b..c474157cf 100644 --- a/tests/Canada/LabourDayTest.php +++ b/tests/Canada/LabourDayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Canada; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -38,7 +35,7 @@ class LabourDayTest extends CanadaBaseTestCase implements HolidayTestCase /** * Tests Labour Day on or after 1894. Labour Day was established since 1894 on the first Monday of September. * - * @throws Exception + * @throws \Exception */ public function testLabourDayOnAfter1894(): void { @@ -47,14 +44,14 @@ public function testLabourDayOnAfter1894(): void self::REGION, self::HOLIDAY, $year, - new DateTime("first monday of september $year", new DateTimeZone(self::TIMEZONE)) + new \DateTime("first monday of september $year", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests Labour Day before 1894. Labour Day was established since 1894 on the first Monday of September. * - * @throws Exception + * @throws \Exception */ public function testLabourDayBefore1894(): void { @@ -68,7 +65,7 @@ public function testLabourDayBefore1894(): void /** * Tests translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -83,7 +80,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Canada/Manitoba/ManitobaTest.php b/tests/Canada/Manitoba/ManitobaTest.php index d7569c982..eeaa0eef8 100644 --- a/tests/Canada/Manitoba/ManitobaTest.php +++ b/tests/Canada/Manitoba/ManitobaTest.php @@ -14,7 +14,6 @@ namespace Yasumi\tests\Canada\Manitoba; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\ProviderTestCase; @@ -90,7 +89,7 @@ public function testOtherHolidays(): void } /** - * @throws ReflectionException + * @throws \ReflectionException * @throws \Exception */ public function testSources(): void diff --git a/tests/Canada/NewBrunswick/NewBrunswickTest.php b/tests/Canada/NewBrunswick/NewBrunswickTest.php index 4e3b05eb0..28f7459c3 100644 --- a/tests/Canada/NewBrunswick/NewBrunswickTest.php +++ b/tests/Canada/NewBrunswick/NewBrunswickTest.php @@ -14,7 +14,6 @@ namespace Yasumi\tests\Canada\NewBrunswick; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\ProviderTestCase; @@ -90,7 +89,7 @@ public function testOtherHolidays(): void } /** - * @throws ReflectionException + * @throws \ReflectionException * @throws \Exception */ public function testSources(): void diff --git a/tests/Canada/NewYearsDayTest.php b/tests/Canada/NewYearsDayTest.php index 2413282e9..d273af6d1 100644 --- a/tests/Canada/NewYearsDayTest.php +++ b/tests/Canada/NewYearsDayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Canada; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -33,7 +30,7 @@ class NewYearsDayTest extends CanadaBaseTestCase implements HolidayTestCase /** * Tests New Years Day. * - * @throws Exception + * @throws \Exception */ public function testNewYearsDay(): void { @@ -42,14 +39,14 @@ public function testNewYearsDay(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-1-1", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-1-1", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -64,7 +61,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Canada/NewfoundlandAndLabrador/NewfoundlandAndLabradorTest.php b/tests/Canada/NewfoundlandAndLabrador/NewfoundlandAndLabradorTest.php index cb6353994..3a1a1dc54 100644 --- a/tests/Canada/NewfoundlandAndLabrador/NewfoundlandAndLabradorTest.php +++ b/tests/Canada/NewfoundlandAndLabrador/NewfoundlandAndLabradorTest.php @@ -14,7 +14,6 @@ namespace Yasumi\tests\Canada\NewfoundlandAndLabrador; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\ProviderTestCase; @@ -86,7 +85,7 @@ public function testOtherHolidays(): void } /** - * @throws ReflectionException + * @throws \ReflectionException * @throws \Exception */ public function testSources(): void diff --git a/tests/Canada/NorthwestTerritories/NorthwestTerritoriesTest.php b/tests/Canada/NorthwestTerritories/NorthwestTerritoriesTest.php index 3885e7bb6..10fcb72cc 100644 --- a/tests/Canada/NorthwestTerritories/NorthwestTerritoriesTest.php +++ b/tests/Canada/NorthwestTerritories/NorthwestTerritoriesTest.php @@ -14,7 +14,6 @@ namespace Yasumi\tests\Canada\NorthwestTerritories; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\ProviderTestCase; @@ -90,7 +89,7 @@ public function testOtherHolidays(): void } /** - * @throws ReflectionException + * @throws \ReflectionException * @throws \Exception */ public function testSources(): void diff --git a/tests/Canada/NovaScotia/NovaScotiaTest.php b/tests/Canada/NovaScotia/NovaScotiaTest.php index f8ffcddd5..995fa18e9 100644 --- a/tests/Canada/NovaScotia/NovaScotiaTest.php +++ b/tests/Canada/NovaScotia/NovaScotiaTest.php @@ -14,7 +14,6 @@ namespace Yasumi\tests\Canada\NovaScotia; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\ProviderTestCase; @@ -90,7 +89,7 @@ public function testOtherHolidays(): void } /** - * @throws ReflectionException + * @throws \ReflectionException * @throws \Exception */ public function testSources(): void diff --git a/tests/Canada/Nunavut/NunavutTest.php b/tests/Canada/Nunavut/NunavutTest.php index 27913c836..2d22c23b1 100644 --- a/tests/Canada/Nunavut/NunavutTest.php +++ b/tests/Canada/Nunavut/NunavutTest.php @@ -14,7 +14,6 @@ namespace Yasumi\tests\Canada\Nunavut; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\ProviderTestCase; @@ -84,7 +83,7 @@ public function testOtherHolidays(): void } /** - * @throws ReflectionException + * @throws \ReflectionException * @throws \Exception */ public function testSources(): void diff --git a/tests/Canada/Ontario/OntarioTest.php b/tests/Canada/Ontario/OntarioTest.php index d6746141a..acc23f841 100644 --- a/tests/Canada/Ontario/OntarioTest.php +++ b/tests/Canada/Ontario/OntarioTest.php @@ -14,7 +14,6 @@ namespace Yasumi\tests\Canada\Ontario; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\ProviderTestCase; @@ -90,7 +89,7 @@ public function testOtherHolidays(): void } /** - * @throws ReflectionException + * @throws \ReflectionException * @throws \Exception */ public function testSources(): void diff --git a/tests/Canada/PrinceEdwardIsland/PrinceEdwardIslandTest.php b/tests/Canada/PrinceEdwardIsland/PrinceEdwardIslandTest.php index 4624b6251..6b4a7163f 100644 --- a/tests/Canada/PrinceEdwardIsland/PrinceEdwardIslandTest.php +++ b/tests/Canada/PrinceEdwardIsland/PrinceEdwardIslandTest.php @@ -14,7 +14,6 @@ namespace Yasumi\tests\Canada\PrinceEdwardIsland; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\ProviderTestCase; @@ -90,7 +89,7 @@ public function testOtherHolidays(): void } /** - * @throws ReflectionException + * @throws \ReflectionException * @throws \Exception */ public function testSources(): void diff --git a/tests/Canada/Quebec/QuebecTest.php b/tests/Canada/Quebec/QuebecTest.php index 254dcb8bf..3dc6e3049 100644 --- a/tests/Canada/Quebec/QuebecTest.php +++ b/tests/Canada/Quebec/QuebecTest.php @@ -14,7 +14,6 @@ namespace Yasumi\tests\Canada\Quebec; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\ProviderTestCase; @@ -89,7 +88,7 @@ public function testOtherHolidays(): void } /** - * @throws ReflectionException + * @throws \ReflectionException * @throws \Exception */ public function testSources(): void diff --git a/tests/Canada/RemembranceDayTest.php b/tests/Canada/RemembranceDayTest.php index 6d14b88e3..2cbfc0625 100644 --- a/tests/Canada/RemembranceDayTest.php +++ b/tests/Canada/RemembranceDayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Canada; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -38,7 +35,7 @@ class RemembranceDayTest extends CanadaBaseTestCase implements HolidayTestCase /** * Tests Remembrance Day on or after 1919. Remembrance Day was established in 1919 on November 11. * - * @throws Exception + * @throws \Exception */ public function testRemembranceDayOnAfter1919(): void { @@ -47,14 +44,14 @@ public function testRemembranceDayOnAfter1919(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-11-11", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-11-11", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests Remembrance Day before 1919. Remembrance Day was established in 1919 on November 11. * - * @throws Exception + * @throws \Exception */ public function testVeteransDayBefore1919(): void { @@ -68,7 +65,7 @@ public function testVeteransDayBefore1919(): void /** * Tests translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -83,7 +80,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Canada/Saskatchewan/SaskatchewanTest.php b/tests/Canada/Saskatchewan/SaskatchewanTest.php index 811750143..6b3da1351 100644 --- a/tests/Canada/Saskatchewan/SaskatchewanTest.php +++ b/tests/Canada/Saskatchewan/SaskatchewanTest.php @@ -14,7 +14,6 @@ namespace Yasumi\tests\Canada\Saskatchewan; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\ProviderTestCase; @@ -90,7 +89,7 @@ public function testOtherHolidays(): void } /** - * @throws ReflectionException + * @throws \ReflectionException * @throws \Exception */ public function testSources(): void diff --git a/tests/Canada/ThanksgivingDayTest.php b/tests/Canada/ThanksgivingDayTest.php index d57b1a54d..b6ee6a3ab 100644 --- a/tests/Canada/ThanksgivingDayTest.php +++ b/tests/Canada/ThanksgivingDayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Canada; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -39,7 +36,7 @@ class ThanksgivingDayTest extends CanadaBaseTestCase implements HolidayTestCase * Tests Thanksgiving Day on or after 1879. Thanksgiving Day is celebrated since 1879 on the second Monday * of October. * - * @throws Exception + * @throws \Exception */ public function testThanksgivingDayOnAfter1879(): void { @@ -48,7 +45,7 @@ public function testThanksgivingDayOnAfter1879(): void self::REGION, self::HOLIDAY, $year, - new DateTime("second monday of october $year", new DateTimeZone(self::TIMEZONE)) + new \DateTime("second monday of october $year", new \DateTimeZone(self::TIMEZONE)) ); } @@ -56,7 +53,7 @@ public function testThanksgivingDayOnAfter1879(): void * Tests Thanksgiving Day before 1879. ThanksgivingDay Day is celebrated since 1879 on the second Monday * of October. * - * @throws Exception + * @throws \Exception */ public function testThanksgivingDayBefore1879(): void { @@ -70,7 +67,7 @@ public function testThanksgivingDayBefore1879(): void /** * Tests translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -85,7 +82,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Canada/TruthAndReconciliationDayTest.php b/tests/Canada/TruthAndReconciliationDayTest.php index 648e539b3..edd5fb68f 100644 --- a/tests/Canada/TruthAndReconciliationDayTest.php +++ b/tests/Canada/TruthAndReconciliationDayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Canada; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -39,7 +36,7 @@ class TruthAndReconciliationDayTest extends CanadaBaseTestCase implements Holida * Tests TruthAndReconciliationDay on or after 2021. Thanksgiving Day is celebrated since 2021 on the last day * of September. * - * @throws Exception + * @throws \Exception */ public function testTruthAndReconciliationDayOnAfter2021(): void { @@ -48,7 +45,7 @@ public function testTruthAndReconciliationDayOnAfter2021(): void self::REGION, self::HOLIDAY, $year, - new DateTime("last day of september $year", new DateTimeZone(self::TIMEZONE)) + new \DateTime("last day of september $year", new \DateTimeZone(self::TIMEZONE)) ); } @@ -56,7 +53,7 @@ public function testTruthAndReconciliationDayOnAfter2021(): void * Tests TruthAndReconciliationDay before 2021. TruthAndReconciliationDay is celebrated since 2021 on the last day * of September. * - * @throws Exception + * @throws \Exception */ public function testTruthAndReconciliationDayBefore2021(): void { @@ -70,7 +67,7 @@ public function testTruthAndReconciliationDayBefore2021(): void /** * Tests translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -85,7 +82,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Canada/Yukon/YukonTest.php b/tests/Canada/Yukon/YukonTest.php index 3f34cfe4a..a43247915 100644 --- a/tests/Canada/Yukon/YukonTest.php +++ b/tests/Canada/Yukon/YukonTest.php @@ -14,7 +14,6 @@ namespace Yasumi\tests\Canada\Yukon; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\ProviderTestCase; @@ -100,7 +99,7 @@ public function testOtherHolidays(): void } /** - * @throws ReflectionException + * @throws \ReflectionException * @throws \Exception */ public function testSources(): void diff --git a/tests/Croatia/AllSaintsDayTest.php b/tests/Croatia/AllSaintsDayTest.php index 5c5f61e89..5e3a4aebe 100644 --- a/tests/Croatia/AllSaintsDayTest.php +++ b/tests/Croatia/AllSaintsDayTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\Croatia; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,8 +32,8 @@ class AllSaintsDayTest extends CroatiaBaseTestCase implements HolidayTestCase * * @dataProvider HolidayDataProvider * - * @param int $year the year for which the holiday defined in this test needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which the holiday defined in this test needs to be tested + * @param \DateTime $expected the expected date */ public function testHoliday(int $year, \DateTimeInterface $expected): void { @@ -47,7 +45,7 @@ public function testHoliday(int $year, \DateTimeInterface $expected): void * * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function HolidayDataProvider(): array { @@ -57,7 +55,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -72,7 +70,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Croatia/AntifascistStruggleDayTest.php b/tests/Croatia/AntifascistStruggleDayTest.php index dd392b339..e06473f23 100644 --- a/tests/Croatia/AntifascistStruggleDayTest.php +++ b/tests/Croatia/AntifascistStruggleDayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Croatia; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -38,7 +35,7 @@ class AntifascistStruggleDayTest extends CroatiaBaseTestCase implements HolidayT /** * Tests Day of Antifascist Struggle on or after 1941. * - * @throws Exception + * @throws \Exception */ public function testAntifascistStruggleDayOnAfter1941(): void { @@ -47,14 +44,14 @@ public function testAntifascistStruggleDayOnAfter1941(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-6-22", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-6-22", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests Day of Antifascist Struggle before 1941. * - * @throws Exception + * @throws \Exception */ public function testAntifascistStruggleDayBefore1941(): void { @@ -68,7 +65,7 @@ public function testAntifascistStruggleDayBefore1941(): void /** * Tests translated name of Day of Antifascist Struggle. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -83,7 +80,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Croatia/AssumptionOfMaryTest.php b/tests/Croatia/AssumptionOfMaryTest.php index c3ffcd3d1..2e771060b 100644 --- a/tests/Croatia/AssumptionOfMaryTest.php +++ b/tests/Croatia/AssumptionOfMaryTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\Croatia; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,8 +32,8 @@ class AssumptionOfMaryTest extends CroatiaBaseTestCase implements HolidayTestCas * * @dataProvider HolidayDataProvider * - * @param int $year the year for which the holiday defined in this test needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which the holiday defined in this test needs to be tested + * @param \DateTime $expected the expected date */ public function testHoliday(int $year, \DateTimeInterface $expected): void { @@ -47,7 +45,7 @@ public function testHoliday(int $year, \DateTimeInterface $expected): void * * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function HolidayDataProvider(): array { @@ -57,7 +55,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -72,7 +70,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Croatia/ChristmasDayTest.php b/tests/Croatia/ChristmasDayTest.php index a70edc9f1..c1732630f 100644 --- a/tests/Croatia/ChristmasDayTest.php +++ b/tests/Croatia/ChristmasDayTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\Croatia; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,8 +32,8 @@ class ChristmasDayTest extends CroatiaBaseTestCase implements HolidayTestCase * * @dataProvider HolidayDataProvider * - * @param int $year the year for which the holiday defined in this test needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which the holiday defined in this test needs to be tested + * @param \DateTime $expected the expected date */ public function testHoliday(int $year, \DateTimeInterface $expected): void { @@ -47,7 +45,7 @@ public function testHoliday(int $year, \DateTimeInterface $expected): void * * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function HolidayDataProvider(): array { @@ -57,7 +55,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -72,7 +70,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Croatia/CorpusChristiTest.php b/tests/Croatia/CorpusChristiTest.php index ff9bf6847..982761c0c 100644 --- a/tests/Croatia/CorpusChristiTest.php +++ b/tests/Croatia/CorpusChristiTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\Croatia; -use DateInterval; -use Exception; use Yasumi\Holiday; use Yasumi\Provider\ChristianHolidays; use Yasumi\tests\HolidayTestCase; @@ -35,7 +33,7 @@ class CorpusChristiTest extends CroatiaBaseTestCase implements HolidayTestCase /** * Tests Corpus Christi. * - * @throws Exception + * @throws \Exception */ public function testCorpusChristi(): void { @@ -44,14 +42,14 @@ public function testCorpusChristi(): void self::REGION, self::HOLIDAY, $year, - $this->calculateEaster($year, self::TIMEZONE)->add(new DateInterval('P60D')) + $this->calculateEaster($year, self::TIMEZONE)->add(new \DateInterval('P60D')) ); } /** * Tests translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -66,7 +64,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Croatia/CroatiaTest.php b/tests/Croatia/CroatiaTest.php index 50420f792..640287e95 100644 --- a/tests/Croatia/CroatiaTest.php +++ b/tests/Croatia/CroatiaTest.php @@ -14,7 +14,6 @@ namespace Yasumi\tests\Croatia; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\ProviderTestCase; @@ -112,7 +111,7 @@ public function testOtherHolidays(): void } /** - * @throws ReflectionException + * @throws \ReflectionException * @throws \Exception */ public function testSources(): void diff --git a/tests/Croatia/EasterMondayTest.php b/tests/Croatia/EasterMondayTest.php index 4336eeec5..ef806e4d3 100644 --- a/tests/Croatia/EasterMondayTest.php +++ b/tests/Croatia/EasterMondayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Croatia; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -33,7 +30,7 @@ class EasterMondayTest extends CroatiaBaseTestCase implements HolidayTestCase /** * Tests the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHoliday(): void { @@ -42,14 +39,14 @@ public function testHoliday(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-4-16", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-4-16", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -64,7 +61,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Croatia/EasterTest.php b/tests/Croatia/EasterTest.php index e75ae4918..21a35259c 100644 --- a/tests/Croatia/EasterTest.php +++ b/tests/Croatia/EasterTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Croatia; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -33,7 +30,7 @@ class EasterTest extends CroatiaBaseTestCase implements HolidayTestCase /** * Tests the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHoliday(): void { @@ -42,14 +39,14 @@ public function testHoliday(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-4-15", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-4-15", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -64,7 +61,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Croatia/EpiphanyTest.php b/tests/Croatia/EpiphanyTest.php index 90db244f4..2d5ced71b 100644 --- a/tests/Croatia/EpiphanyTest.php +++ b/tests/Croatia/EpiphanyTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\Croatia; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,8 +32,8 @@ class EpiphanyTest extends CroatiaBaseTestCase implements HolidayTestCase * * @dataProvider HolidayDataProvider * - * @param int $year the year for which the holiday defined in this test needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which the holiday defined in this test needs to be tested + * @param \DateTime $expected the expected date */ public function testHoliday(int $year, \DateTimeInterface $expected): void { @@ -47,7 +45,7 @@ public function testHoliday(int $year, \DateTimeInterface $expected): void * * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function HolidayDataProvider(): array { @@ -57,7 +55,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -72,7 +70,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Croatia/HomelandThanksgivingDayTest.php b/tests/Croatia/HomelandThanksgivingDayTest.php index 91fe5721a..0f0f97509 100644 --- a/tests/Croatia/HomelandThanksgivingDayTest.php +++ b/tests/Croatia/HomelandThanksgivingDayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Croatia; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -43,7 +40,7 @@ class HomelandThanksgivingDayTest extends CroatiaBaseTestCase implements Holiday /** * Tests Homeland Thanksgiving Day on or after 1995. * - * @throws Exception + * @throws \Exception */ public function testHomelandThanksgivingDayOnAfter1995(): void { @@ -52,14 +49,14 @@ public function testHomelandThanksgivingDayOnAfter1995(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-8-5", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-8-5", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests Homeland Thanksgiving Day before 1995. * - * @throws Exception + * @throws \Exception */ public function testHomelandThanksgivingDayBefore1995(): void { @@ -73,7 +70,7 @@ public function testHomelandThanksgivingDayBefore1995(): void /** * Tests translated name of Homeland Thanksgiving Day. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -99,7 +96,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Croatia/IndependenceDayTest.php b/tests/Croatia/IndependenceDayTest.php index 63abb5f1b..18a5b738b 100644 --- a/tests/Croatia/IndependenceDayTest.php +++ b/tests/Croatia/IndependenceDayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Croatia; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -43,7 +40,7 @@ class IndependenceDayTest extends CroatiaBaseTestCase implements HolidayTestCase /** * Tests Independence Day on or after 1991. * - * @throws Exception + * @throws \Exception */ public function testIndependenceDayOnAfter1991(): void { @@ -52,14 +49,14 @@ public function testIndependenceDayOnAfter1991(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-10-8", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-10-8", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests Independence Day before 1991. * - * @throws Exception + * @throws \Exception */ public function testIndependenceDayBefore1991(): void { @@ -73,7 +70,7 @@ public function testIndependenceDayBefore1991(): void /** * Tests Independence Day before 1991. * - * @throws Exception + * @throws \Exception */ public function testIndependenceDayAfterDisbandment(): void { @@ -87,7 +84,7 @@ public function testIndependenceDayAfterDisbandment(): void /** * Tests translated name of Independence Day. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -102,7 +99,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Croatia/InternationalWorkersDayTest.php b/tests/Croatia/InternationalWorkersDayTest.php index 565b3ef37..f83ff0803 100644 --- a/tests/Croatia/InternationalWorkersDayTest.php +++ b/tests/Croatia/InternationalWorkersDayTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\Croatia; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,8 +32,8 @@ class InternationalWorkersDayTest extends CroatiaBaseTestCase implements Holiday * * @dataProvider HolidayDataProvider * - * @param int $year the year for which the holiday defined in this test needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which the holiday defined in this test needs to be tested + * @param \DateTime $expected the expected date */ public function testHoliday(int $year, \DateTimeInterface $expected): void { @@ -45,7 +43,7 @@ public function testHoliday(int $year, \DateTimeInterface $expected): void /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -60,7 +58,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { @@ -72,7 +70,7 @@ public function testHolidayType(): void * * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function HolidayDataProvider(): array { diff --git a/tests/Croatia/NewYearsDayTest.php b/tests/Croatia/NewYearsDayTest.php index 077ab71e2..e3e3dd5dd 100644 --- a/tests/Croatia/NewYearsDayTest.php +++ b/tests/Croatia/NewYearsDayTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\Croatia; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,8 +32,8 @@ class NewYearsDayTest extends CroatiaBaseTestCase implements HolidayTestCase * * @dataProvider HolidayDataProvider * - * @param int $year the year for which the holiday defined in this test needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which the holiday defined in this test needs to be tested + * @param \DateTime $expected the expected date */ public function testHoliday(int $year, \DateTimeInterface $expected): void { @@ -47,7 +45,7 @@ public function testHoliday(int $year, \DateTimeInterface $expected): void * * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function HolidayDataProvider(): array { @@ -57,7 +55,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -72,7 +70,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Croatia/RemembranceDayTest.php b/tests/Croatia/RemembranceDayTest.php index 376354dc9..1199e87f6 100644 --- a/tests/Croatia/RemembranceDayTest.php +++ b/tests/Croatia/RemembranceDayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Croatia; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -38,7 +35,7 @@ class RemembranceDayTest extends CroatiaBaseTestCase implements HolidayTestCase /** * Tests Remembrance Day. * - * @throws Exception + * @throws \Exception */ public function testRemembranceDayAfterItWasEstablished(): void { @@ -47,14 +44,14 @@ public function testRemembranceDayAfterItWasEstablished(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-11-18", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-11-18", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests Remembrance Day. * - * @throws Exception + * @throws \Exception */ public function testRemembranceDayBeforeItWasEstablished(): void { @@ -68,7 +65,7 @@ public function testRemembranceDayBeforeItWasEstablished(): void /** * Tests translated name of Remembrance Day. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -83,7 +80,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Croatia/StStephensDayTest.php b/tests/Croatia/StStephensDayTest.php index 93df24861..91e7b3304 100644 --- a/tests/Croatia/StStephensDayTest.php +++ b/tests/Croatia/StStephensDayTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\Croatia; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,8 +32,8 @@ class StStephensDayTest extends CroatiaBaseTestCase implements HolidayTestCase * * @dataProvider stStephensDayDataProvider * - * @param int $year the year for which St. Stephen's Day needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which St. Stephen's Day needs to be tested + * @param \DateTime $expected the expected date */ public function teststStephensDay(int $year, \DateTimeInterface $expected): void { @@ -47,7 +45,7 @@ public function teststStephensDay(int $year, \DateTimeInterface $expected): void * * @return array list of test dates for St. Stephen's Day * - * @throws Exception + * @throws \Exception */ public function stStephensDayDataProvider(): array { @@ -57,7 +55,7 @@ public function stStephensDayDataProvider(): array /** * Tests translated name of St. Stephen's Day. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -72,7 +70,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Croatia/StatehoodDayTest.php b/tests/Croatia/StatehoodDayTest.php index 9b98d48c4..706b5d946 100644 --- a/tests/Croatia/StatehoodDayTest.php +++ b/tests/Croatia/StatehoodDayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Croatia; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -43,7 +40,7 @@ class StatehoodDayTest extends CroatiaBaseTestCase implements HolidayTestCase /** * Tests Statehood Day. * - * @throws Exception + * @throws \Exception */ public function testStatehoodDay(): void { @@ -53,7 +50,7 @@ public function testStatehoodDay(): void self::REGION, self::HOLIDAY, $year, - new DateTime($expectedDate, new DateTimeZone(self::TIMEZONE)) + new \DateTime($expectedDate, new \DateTimeZone(self::TIMEZONE)) ); $year = $this->generateRandomYear(self::DATE_CHANGE_YEAR); @@ -62,14 +59,14 @@ public function testStatehoodDay(): void self::REGION, self::HOLIDAY, $year, - new DateTime($expectedDate, new DateTimeZone(self::TIMEZONE)) + new \DateTime($expectedDate, new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests Statehood Day before 1991. * - * @throws Exception + * @throws \Exception */ public function testStatehoodDayBefore1991(): void { @@ -83,7 +80,7 @@ public function testStatehoodDayBefore1991(): void /** * Tests translated name of Statehood Day. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -98,7 +95,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/CzechRepublic/ChristmasDayTest.php b/tests/CzechRepublic/ChristmasDayTest.php index 968017c27..695e09bc0 100644 --- a/tests/CzechRepublic/ChristmasDayTest.php +++ b/tests/CzechRepublic/ChristmasDayTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\CzechRepublic; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -38,8 +36,8 @@ class ChristmasDayTest extends CzechRepublicBaseTestCase implements HolidayTestC * * @dataProvider HolidayDataProvider * - * @param int $year the year for which Christmas Day needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which Christmas Day needs to be tested + * @param \DateTime $expected the expected date */ public function testChristmasDay(int $year, \DateTimeInterface $expected): void { @@ -51,7 +49,7 @@ public function testChristmasDay(int $year, \DateTimeInterface $expected): void * * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function HolidayDataProvider(): array { @@ -61,7 +59,7 @@ public function HolidayDataProvider(): array /** * Tests translated name of Christmas Day. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -76,7 +74,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/CzechRepublic/ChristmasEveTest.php b/tests/CzechRepublic/ChristmasEveTest.php index 130317e36..6912c220b 100644 --- a/tests/CzechRepublic/ChristmasEveTest.php +++ b/tests/CzechRepublic/ChristmasEveTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\CzechRepublic; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -38,8 +36,8 @@ class ChristmasEveTest extends CzechRepublicBaseTestCase implements HolidayTestC * * @dataProvider HolidayDataProvider * - * @param int $year the year for which Christmas Eve needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which Christmas Eve needs to be tested + * @param \DateTime $expected the expected date */ public function testChristmasDay(int $year, \DateTimeInterface $expected): void { @@ -51,7 +49,7 @@ public function testChristmasDay(int $year, \DateTimeInterface $expected): void * * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function HolidayDataProvider(): array { @@ -61,7 +59,7 @@ public function HolidayDataProvider(): array /** * Tests translated name of Christmas Day. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -76,7 +74,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/CzechRepublic/CzechRepublicTest.php b/tests/CzechRepublic/CzechRepublicTest.php index f6170ed92..feec67d63 100644 --- a/tests/CzechRepublic/CzechRepublicTest.php +++ b/tests/CzechRepublic/CzechRepublicTest.php @@ -14,7 +14,6 @@ namespace Yasumi\tests\CzechRepublic; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\ProviderTestCase; @@ -97,7 +96,7 @@ public function testOtherHolidays(): void } /** - * @throws ReflectionException + * @throws \ReflectionException * @throws \Exception */ public function testSources(): void diff --git a/tests/CzechRepublic/CzechStateHoodDayTest.php b/tests/CzechRepublic/CzechStateHoodDayTest.php index 1e5430395..306592c5b 100644 --- a/tests/CzechRepublic/CzechStateHoodDayTest.php +++ b/tests/CzechRepublic/CzechStateHoodDayTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\CzechRepublic; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -38,8 +36,8 @@ class CzechStateHoodDayTest extends CzechRepublicBaseTestCase implements Holiday * * @dataProvider HolidayDataProvider * - * @param int $year the year for which the holiday defined in this test needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which the holiday defined in this test needs to be tested + * @param \DateTime $expected the expected date */ public function testHoliday(int $year, \DateTimeInterface $expected): void { @@ -51,7 +49,7 @@ public function testHoliday(int $year, \DateTimeInterface $expected): void * * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function HolidayDataProvider(): array { @@ -61,7 +59,7 @@ public function HolidayDataProvider(): array /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -76,7 +74,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/CzechRepublic/EasterMondayTest.php b/tests/CzechRepublic/EasterMondayTest.php index c0c190fc2..4df298b0b 100644 --- a/tests/CzechRepublic/EasterMondayTest.php +++ b/tests/CzechRepublic/EasterMondayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\CzechRepublic; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -37,7 +34,7 @@ class EasterMondayTest extends CzechRepublicBaseTestCase implements HolidayTestC /** * Tests the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHoliday(): void { @@ -46,14 +43,14 @@ public function testHoliday(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-4-24", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-4-24", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -68,7 +65,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/CzechRepublic/GoodFridayTest.php b/tests/CzechRepublic/GoodFridayTest.php index 40500243e..07382e95c 100644 --- a/tests/CzechRepublic/GoodFridayTest.php +++ b/tests/CzechRepublic/GoodFridayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\CzechRepublic; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -37,7 +34,7 @@ class GoodFridayTest extends CzechRepublicBaseTestCase implements HolidayTestCas /** * Tests Good Friday. * - * @throws Exception + * @throws \Exception */ public function testGoodFriday(): void { @@ -46,14 +43,14 @@ public function testGoodFriday(): void self::REGION, 'goodFriday', $year, - new DateTime("$year-4-14", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-4-14", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -68,7 +65,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/CzechRepublic/IndependentCzechoslovakStateDayTest.php b/tests/CzechRepublic/IndependentCzechoslovakStateDayTest.php index a38e8a6cf..756962297 100644 --- a/tests/CzechRepublic/IndependentCzechoslovakStateDayTest.php +++ b/tests/CzechRepublic/IndependentCzechoslovakStateDayTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\CzechRepublic; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,8 +32,8 @@ class IndependentCzechoslovakStateDayTest extends CzechRepublicBaseTestCase impl * * @dataProvider HolidayDataProvider * - * @param int $year the year for which the holiday defined in this test needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which the holiday defined in this test needs to be tested + * @param \DateTime $expected the expected date */ public function testHoliday(int $year, \DateTimeInterface $expected): void { @@ -47,7 +45,7 @@ public function testHoliday(int $year, \DateTimeInterface $expected): void * * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function HolidayDataProvider(): array { @@ -57,7 +55,7 @@ public function HolidayDataProvider(): array /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -72,7 +70,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/CzechRepublic/InternationalWorkersDayTest.php b/tests/CzechRepublic/InternationalWorkersDayTest.php index e6dc56f3f..fdf38bfd1 100644 --- a/tests/CzechRepublic/InternationalWorkersDayTest.php +++ b/tests/CzechRepublic/InternationalWorkersDayTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\CzechRepublic; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -38,8 +36,8 @@ class InternationalWorkersDayTest extends CzechRepublicBaseTestCase implements H * * @dataProvider HolidayDataProvider * - * @param int $year the year for which International Workers' Day needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which International Workers' Day needs to be tested + * @param \DateTime $expected the expected date */ public function testHoliday(int $year, \DateTimeInterface $expected): void { @@ -49,7 +47,7 @@ public function testHoliday(int $year, \DateTimeInterface $expected): void /** * Tests translated name of International Workers' Day. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -64,7 +62,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { @@ -76,7 +74,7 @@ public function testHolidayType(): void * * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function HolidayDataProvider(): array { diff --git a/tests/CzechRepublic/JanHusDayTest.php b/tests/CzechRepublic/JanHusDayTest.php index a3c0ede63..560f77854 100644 --- a/tests/CzechRepublic/JanHusDayTest.php +++ b/tests/CzechRepublic/JanHusDayTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\CzechRepublic; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,8 +32,8 @@ class JanHusDayTest extends CzechRepublicBaseTestCase implements HolidayTestCase * * @dataProvider HolidayDataProvider * - * @param int $year the year for which the holiday defined in this test needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which the holiday defined in this test needs to be tested + * @param \DateTime $expected the expected date */ public function testHoliday(int $year, \DateTimeInterface $expected): void { @@ -47,7 +45,7 @@ public function testHoliday(int $year, \DateTimeInterface $expected): void * * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function HolidayDataProvider(): array { @@ -57,7 +55,7 @@ public function HolidayDataProvider(): array /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -72,7 +70,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/CzechRepublic/NewYearsDayTest.php b/tests/CzechRepublic/NewYearsDayTest.php index 0b47a9b48..2ee7d00f8 100644 --- a/tests/CzechRepublic/NewYearsDayTest.php +++ b/tests/CzechRepublic/NewYearsDayTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\CzechRepublic; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -38,8 +36,8 @@ class NewYearsDayTest extends CzechRepublicBaseTestCase implements HolidayTestCa * * @dataProvider HolidayDataProvider * - * @param int $year the year for which the holiday defined in this test needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which the holiday defined in this test needs to be tested + * @param \DateTime $expected the expected date */ public function testHoliday(int $year, \DateTimeInterface $expected): void { @@ -51,7 +49,7 @@ public function testHoliday(int $year, \DateTimeInterface $expected): void * * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function HolidayDataProvider(): array { @@ -61,7 +59,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -76,7 +74,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/CzechRepublic/RenewalOfIndependentCzechStateDayTest.php b/tests/CzechRepublic/RenewalOfIndependentCzechStateDayTest.php index 30bbddfdc..7e08a0a57 100644 --- a/tests/CzechRepublic/RenewalOfIndependentCzechStateDayTest.php +++ b/tests/CzechRepublic/RenewalOfIndependentCzechStateDayTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\CzechRepublic; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -37,8 +35,8 @@ class RenewalOfIndependentCzechStateDayTest extends CzechRepublicBaseTestCase im * * @dataProvider HolidayDataProvider * - * @param int $year the year for which the holiday defined in this test needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which the holiday defined in this test needs to be tested + * @param \DateTime $expected the expected date */ public function testHoliday(int $year, \DateTimeInterface $expected): void { @@ -50,7 +48,7 @@ public function testHoliday(int $year, \DateTimeInterface $expected): void * * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function HolidayDataProvider(): array { @@ -60,7 +58,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -75,7 +73,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/CzechRepublic/SaintsCyrilAndMethodiusDayTest.php b/tests/CzechRepublic/SaintsCyrilAndMethodiusDayTest.php index 1452b5e51..75e4aa7b4 100644 --- a/tests/CzechRepublic/SaintsCyrilAndMethodiusDayTest.php +++ b/tests/CzechRepublic/SaintsCyrilAndMethodiusDayTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\CzechRepublic; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -38,8 +36,8 @@ class SaintsCyrilAndMethodiusDayTest extends CzechRepublicBaseTestCase implement * * @dataProvider HolidayDataProvider * - * @param int $year the year for which the holiday defined in this test needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which the holiday defined in this test needs to be tested + * @param \DateTime $expected the expected date */ public function testHoliday(int $year, \DateTimeInterface $expected): void { @@ -51,7 +49,7 @@ public function testHoliday(int $year, \DateTimeInterface $expected): void * * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function HolidayDataProvider(): array { @@ -61,7 +59,7 @@ public function HolidayDataProvider(): array /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -76,7 +74,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/CzechRepublic/SecondChristmasDayTest.php b/tests/CzechRepublic/SecondChristmasDayTest.php index 31af974a9..13652b7dd 100644 --- a/tests/CzechRepublic/SecondChristmasDayTest.php +++ b/tests/CzechRepublic/SecondChristmasDayTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\CzechRepublic; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -38,8 +36,8 @@ class SecondChristmasDayTest extends CzechRepublicBaseTestCase implements Holida * * @dataProvider HolidayDataProvider * - * @param int $year the year for which the holiday defined in this test needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which the holiday defined in this test needs to be tested + * @param \DateTime $expected the expected date */ public function testHoliday(int $year, \DateTimeInterface $expected): void { @@ -51,7 +49,7 @@ public function testHoliday(int $year, \DateTimeInterface $expected): void * * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function HolidayDataProvider(): array { @@ -61,7 +59,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -76,7 +74,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/CzechRepublic/StruggleForFreedomAndDemocracyDayTest.php b/tests/CzechRepublic/StruggleForFreedomAndDemocracyDayTest.php index fa0976c6e..c495da56e 100644 --- a/tests/CzechRepublic/StruggleForFreedomAndDemocracyDayTest.php +++ b/tests/CzechRepublic/StruggleForFreedomAndDemocracyDayTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\CzechRepublic; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,8 +32,8 @@ class StruggleForFreedomAndDemocracyDayTest extends CzechRepublicBaseTestCase im * * @dataProvider HolidayDataProvider * - * @param int $year the year for which the holiday defined in this test needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which the holiday defined in this test needs to be tested + * @param \DateTime $expected the expected date */ public function testHoliday(int $year, \DateTimeInterface $expected): void { @@ -47,7 +45,7 @@ public function testHoliday(int $year, \DateTimeInterface $expected): void * * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function HolidayDataProvider(): array { @@ -57,7 +55,7 @@ public function HolidayDataProvider(): array /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -72,7 +70,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/CzechRepublic/VictoryInEuropeDayTest.php b/tests/CzechRepublic/VictoryInEuropeDayTest.php index 6ace79694..f325b82b3 100644 --- a/tests/CzechRepublic/VictoryInEuropeDayTest.php +++ b/tests/CzechRepublic/VictoryInEuropeDayTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\CzechRepublic; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -38,8 +36,8 @@ class VictoryInEuropeDayTest extends CzechRepublicBaseTestCase implements Holida * * @dataProvider HolidayDataProvider * - * @param int $year the year for which the holiday defined in this test needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which the holiday defined in this test needs to be tested + * @param \DateTime $expected the expected date */ public function testHoliday(int $year, \DateTimeInterface $expected): void { @@ -51,7 +49,7 @@ public function testHoliday(int $year, \DateTimeInterface $expected): void * * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function HolidayDataProvider(): array { @@ -61,7 +59,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -76,7 +74,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Denmark/AscensionDayTest.php b/tests/Denmark/AscensionDayTest.php index 0d517c15c..acf297729 100644 --- a/tests/Denmark/AscensionDayTest.php +++ b/tests/Denmark/AscensionDayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Denmark; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -33,7 +30,7 @@ class AscensionDayTest extends DenmarkBaseTestCase implements HolidayTestCase /** * Tests Ascension Day. * - * @throws Exception + * @throws \Exception */ public function testAscensionDay(): void { @@ -42,14 +39,14 @@ public function testAscensionDay(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-5-4", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-5-4", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests translated name of Ascension Day. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -64,7 +61,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Denmark/ChristmasDayTest.php b/tests/Denmark/ChristmasDayTest.php index 3bc60f908..f0fcf4b01 100644 --- a/tests/Denmark/ChristmasDayTest.php +++ b/tests/Denmark/ChristmasDayTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\Denmark; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,8 +32,8 @@ class ChristmasDayTest extends DenmarkBaseTestCase implements HolidayTestCase * * @dataProvider HolidayDataProvider * - * @param int $year the year for which the holiday defined in this test needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which the holiday defined in this test needs to be tested + * @param \DateTime $expected the expected date */ public function testHoliday(int $year, \DateTimeInterface $expected): void { @@ -47,7 +45,7 @@ public function testHoliday(int $year, \DateTimeInterface $expected): void * * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function HolidayDataProvider(): array { @@ -57,7 +55,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -72,7 +70,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Denmark/ChristmasEveTest.php b/tests/Denmark/ChristmasEveTest.php index 87ada4ad5..b5d359ed7 100644 --- a/tests/Denmark/ChristmasEveTest.php +++ b/tests/Denmark/ChristmasEveTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\Denmark; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,8 +32,8 @@ class ChristmasEveTest extends DenmarkBaseTestCase implements HolidayTestCase * * @dataProvider HolidayDataProvider * - * @param int $year the year for which the holiday defined in this test needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which the holiday defined in this test needs to be tested + * @param \DateTime $expected the expected date */ public function testHoliday(int $year, \DateTimeInterface $expected): void { @@ -47,7 +45,7 @@ public function testHoliday(int $year, \DateTimeInterface $expected): void * * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function HolidayDataProvider(): array { @@ -57,7 +55,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -72,7 +70,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Denmark/ConstitutionDayTest.php b/tests/Denmark/ConstitutionDayTest.php index a2787feb2..4e552227e 100644 --- a/tests/Denmark/ConstitutionDayTest.php +++ b/tests/Denmark/ConstitutionDayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Denmark; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -38,7 +35,7 @@ class ConstitutionDayTest extends DenmarkBaseTestCase implements HolidayTestCase /** * Tests the holiday defined in this test on or after establishment. * - * @throws Exception + * @throws \Exception */ public function testHolidayOnAfterEstablishment(): void { @@ -47,14 +44,14 @@ public function testHolidayOnAfterEstablishment(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-6-5", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-6-5", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests the holiday defined in this test before establishment. * - * @throws Exception + * @throws \Exception */ public function testHolidayBeforeEstablishment(): void { @@ -68,7 +65,7 @@ public function testHolidayBeforeEstablishment(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -83,7 +80,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Denmark/DenmarkTest.php b/tests/Denmark/DenmarkTest.php index d5a3a928d..b9a0d8dea 100644 --- a/tests/Denmark/DenmarkTest.php +++ b/tests/Denmark/DenmarkTest.php @@ -14,7 +14,6 @@ namespace Yasumi\tests\Denmark; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\ProviderTestCase; @@ -99,7 +98,7 @@ public function testOtherHolidays(): void } /** - * @throws ReflectionException + * @throws \ReflectionException * @throws \Exception */ public function testSources(): void diff --git a/tests/Denmark/EasterMondayTest.php b/tests/Denmark/EasterMondayTest.php index 657a717aa..ef5712d4e 100644 --- a/tests/Denmark/EasterMondayTest.php +++ b/tests/Denmark/EasterMondayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Denmark; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -33,7 +30,7 @@ class EasterMondayTest extends DenmarkBaseTestCase implements HolidayTestCase /** * Tests the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHoliday(): void { @@ -42,14 +39,14 @@ public function testHoliday(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-4-24", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-4-24", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -64,7 +61,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Denmark/EasterTest.php b/tests/Denmark/EasterTest.php index 1a154c98c..63ceb95ed 100644 --- a/tests/Denmark/EasterTest.php +++ b/tests/Denmark/EasterTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Denmark; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -33,7 +30,7 @@ class EasterTest extends DenmarkBaseTestCase implements HolidayTestCase /** * Tests the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHoliday(): void { @@ -42,14 +39,14 @@ public function testHoliday(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-3-26", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-3-26", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -64,7 +61,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Denmark/GoodFridayTest.php b/tests/Denmark/GoodFridayTest.php index 89a55047c..b946d6abf 100644 --- a/tests/Denmark/GoodFridayTest.php +++ b/tests/Denmark/GoodFridayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Denmark; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -33,7 +30,7 @@ class GoodFridayTest extends DenmarkBaseTestCase implements HolidayTestCase /** * Tests the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHoliday(): void { @@ -42,14 +39,14 @@ public function testHoliday(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-4-3", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-4-3", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -64,7 +61,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Denmark/GreatPrayerDayTest.php b/tests/Denmark/GreatPrayerDayTest.php index 494ee5d17..560a1b88d 100644 --- a/tests/Denmark/GreatPrayerDayTest.php +++ b/tests/Denmark/GreatPrayerDayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Denmark; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -38,7 +35,7 @@ class GreatPrayerDayTest extends DenmarkBaseTestCase implements HolidayTestCase /** * Tests the holiday defined in this test on or after establishment. * - * @throws Exception + * @throws \Exception */ public function testHolidayOnAfterEstablishment(): void { @@ -47,14 +44,14 @@ public function testHolidayOnAfterEstablishment(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-5-13", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-5-13", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests the holiday defined in this test before establishment. * - * @throws Exception + * @throws \Exception */ public function testHolidayBeforeEstablishment(): void { @@ -68,7 +65,7 @@ public function testHolidayBeforeEstablishment(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -83,7 +80,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Denmark/InternationalWorkersDayTest.php b/tests/Denmark/InternationalWorkersDayTest.php index 217ec8f07..783f00487 100644 --- a/tests/Denmark/InternationalWorkersDayTest.php +++ b/tests/Denmark/InternationalWorkersDayTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\Denmark; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,8 +32,8 @@ class InternationalWorkersDayTest extends DenmarkBaseTestCase implements Holiday * * @dataProvider InternationalWorkersDayDataProvider * - * @param int $year the year for which International Workers' Day needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which International Workers' Day needs to be tested + * @param \DateTime $expected the expected date */ public function testInternationalWorkersDay(int $year, \DateTimeInterface $expected): void { @@ -47,7 +45,7 @@ public function testInternationalWorkersDay(int $year, \DateTimeInterface $expec * * @return array list of test dates for International Workers' Day * - * @throws Exception + * @throws \Exception */ public function InternationalWorkersDayDataProvider(): array { @@ -57,7 +55,7 @@ public function InternationalWorkersDayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -72,7 +70,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Denmark/MaundyThursdayTest.php b/tests/Denmark/MaundyThursdayTest.php index 6d77b3805..44b2ef66b 100644 --- a/tests/Denmark/MaundyThursdayTest.php +++ b/tests/Denmark/MaundyThursdayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Denmark; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -33,7 +30,7 @@ class MaundyThursdayTest extends DenmarkBaseTestCase implements HolidayTestCase /** * Tests the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHoliday(): void { @@ -42,14 +39,14 @@ public function testHoliday(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-3-29", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-3-29", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -64,7 +61,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Denmark/NewYearsDayTest.php b/tests/Denmark/NewYearsDayTest.php index fdb9555f8..445cc3de4 100644 --- a/tests/Denmark/NewYearsDayTest.php +++ b/tests/Denmark/NewYearsDayTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\Denmark; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,8 +32,8 @@ class NewYearsDayTest extends DenmarkBaseTestCase implements HolidayTestCase * * @dataProvider HolidayDataProvider * - * @param int $year the year for which the holiday defined in this test needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which the holiday defined in this test needs to be tested + * @param \DateTime $expected the expected date */ public function testHoliday(int $year, \DateTimeInterface $expected): void { @@ -47,7 +45,7 @@ public function testHoliday(int $year, \DateTimeInterface $expected): void * * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function HolidayDataProvider(): array { @@ -57,7 +55,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -72,7 +70,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Denmark/NewYearsEveTest.php b/tests/Denmark/NewYearsEveTest.php index 55508ce67..ddb27654b 100644 --- a/tests/Denmark/NewYearsEveTest.php +++ b/tests/Denmark/NewYearsEveTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\Denmark; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,8 +32,8 @@ class NewYearsEveTest extends DenmarkBaseTestCase implements HolidayTestCase * * @dataProvider HolidayDataProvider * - * @param int $year the year for which the holiday defined in this test needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which the holiday defined in this test needs to be tested + * @param \DateTime $expected the expected date */ public function testHoliday(int $year, \DateTimeInterface $expected): void { @@ -47,7 +45,7 @@ public function testHoliday(int $year, \DateTimeInterface $expected): void * * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function HolidayDataProvider(): array { @@ -57,7 +55,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -72,7 +70,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Denmark/PentecostMondayTest.php b/tests/Denmark/PentecostMondayTest.php index 1ee6251e5..a362c4345 100644 --- a/tests/Denmark/PentecostMondayTest.php +++ b/tests/Denmark/PentecostMondayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Denmark; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -33,7 +30,7 @@ class PentecostMondayTest extends DenmarkBaseTestCase implements HolidayTestCase /** * Tests the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHoliday(): void { @@ -42,14 +39,14 @@ public function testHoliday(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-6-1", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-6-1", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -64,7 +61,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Denmark/PentecostTest.php b/tests/Denmark/PentecostTest.php index 59fbdf37b..1ac499815 100644 --- a/tests/Denmark/PentecostTest.php +++ b/tests/Denmark/PentecostTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Denmark; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -33,7 +30,7 @@ class PentecostTest extends DenmarkBaseTestCase implements HolidayTestCase /** * Tests the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHoliday(): void { @@ -42,14 +39,14 @@ public function testHoliday(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-6-9", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-6-9", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -64,7 +61,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Denmark/SecondChristmasDayTest.php b/tests/Denmark/SecondChristmasDayTest.php index f6e5b4773..463d5f5fe 100644 --- a/tests/Denmark/SecondChristmasDayTest.php +++ b/tests/Denmark/SecondChristmasDayTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\Denmark; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,8 +32,8 @@ class SecondChristmasDayTest extends DenmarkBaseTestCase implements HolidayTestC * * @dataProvider HolidayDataProvider * - * @param int $year the year for which the holiday defined in this test needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which the holiday defined in this test needs to be tested + * @param \DateTime $expected the expected date */ public function testHoliday(int $year, \DateTimeInterface $expected): void { @@ -47,7 +45,7 @@ public function testHoliday(int $year, \DateTimeInterface $expected): void * * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function HolidayDataProvider(): array { @@ -57,7 +55,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -72,7 +70,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Denmark/SummerTimeTest.php b/tests/Denmark/SummerTimeTest.php index 087a99535..6f814a14f 100644 --- a/tests/Denmark/SummerTimeTest.php +++ b/tests/Denmark/SummerTimeTest.php @@ -15,9 +15,6 @@ namespace Yasumi\tests\Denmark; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; /** @@ -67,22 +64,22 @@ public function __construct() /** * Tests the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testSummerTime(): void { $this->assertNotHoliday(self::REGION, self::HOLIDAY, $this->randomYearFromArray($this->unobservedYears)); $year = $this->randomYearFromArray($this->observedYears); - $expectedDate = new DateTime("last sunday of march $year", new DateTimeZone(self::TIMEZONE)); + $expectedDate = new \DateTime("last sunday of march $year", new \DateTimeZone(self::TIMEZONE)); if (array_key_exists($year, $this->deviantTransitions)) { - $expectedDate = new DateTime($this->deviantTransitions[$year], new DateTimeZone(self::TIMEZONE)); + $expectedDate = new \DateTime($this->deviantTransitions[$year], new \DateTimeZone(self::TIMEZONE)); } // Since 1980 Summertime in Denmark starts on the last day of March. In 1980 itself however, it started on April, 6th. if (1980 === $year) { - $expectedDate = new DateTime('1980-04-06', new DateTimeZone(self::TIMEZONE)); + $expectedDate = new \DateTime('1980-04-06', new \DateTimeZone(self::TIMEZONE)); } $this->assertHoliday( @@ -96,7 +93,7 @@ public function testSummerTime(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -111,7 +108,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Denmark/WinterTimeTest.php b/tests/Denmark/WinterTimeTest.php index cd8bbb33a..6ec3f8884 100644 --- a/tests/Denmark/WinterTimeTest.php +++ b/tests/Denmark/WinterTimeTest.php @@ -15,9 +15,6 @@ namespace Yasumi\tests\Denmark; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; /** @@ -71,21 +68,21 @@ public function __construct() /** * Tests the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testWinterTime(): void { $this->assertNotHoliday(self::REGION, self::HOLIDAY, $this->randomYearFromArray($this->unobservedYears)); $year = $this->randomYearFromArray($this->observedYears); - $expectedDate = new DateTime("last sunday of september $year", new DateTimeZone(self::TIMEZONE)); + $expectedDate = new \DateTime("last sunday of september $year", new \DateTimeZone(self::TIMEZONE)); if ($year >= 1996) { - $expectedDate = new DateTime("last sunday of october $year", new DateTimeZone(self::TIMEZONE)); + $expectedDate = new \DateTime("last sunday of october $year", new \DateTimeZone(self::TIMEZONE)); } if (array_key_exists($year, $this->deviantTransitions)) { - $expectedDate = new DateTime($this->deviantTransitions[$year], new DateTimeZone(self::TIMEZONE)); + $expectedDate = new \DateTime($this->deviantTransitions[$year], new \DateTimeZone(self::TIMEZONE)); } $this->assertHoliday( @@ -99,7 +96,7 @@ public function testWinterTime(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -114,7 +111,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Estonia/ChristmasDayTest.php b/tests/Estonia/ChristmasDayTest.php index a55638381..94efecb3a 100644 --- a/tests/Estonia/ChristmasDayTest.php +++ b/tests/Estonia/ChristmasDayTest.php @@ -15,7 +15,6 @@ namespace Yasumi\tests\Estonia; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,7 +33,7 @@ class ChristmasDayTest extends EstoniaBaseTestCase implements HolidayTestCase /** * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function holidayDataProvider(): array { @@ -52,7 +51,7 @@ public function testHoliday(int $year, \DateTimeInterface $expected): void /** * {@inheritdoc} * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -67,7 +66,7 @@ public function testTranslation(): void /** * {@inheritdoc} * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Estonia/ChristmasEveDayTest.php b/tests/Estonia/ChristmasEveDayTest.php index 3b6fd804e..138bfdfb6 100644 --- a/tests/Estonia/ChristmasEveDayTest.php +++ b/tests/Estonia/ChristmasEveDayTest.php @@ -15,7 +15,6 @@ namespace Yasumi\tests\Estonia; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,7 +33,7 @@ class ChristmasEveDayTest extends EstoniaBaseTestCase implements HolidayTestCase /** * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function holidayDataProvider(): array { @@ -52,7 +51,7 @@ public function testHoliday(int $year, \DateTimeInterface $expected): void /** * {@inheritdoc} * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -67,7 +66,7 @@ public function testTranslation(): void /** * {@inheritdoc} * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Estonia/EasterDayTest.php b/tests/Estonia/EasterDayTest.php index 096583288..ac3cea273 100644 --- a/tests/Estonia/EasterDayTest.php +++ b/tests/Estonia/EasterDayTest.php @@ -15,9 +15,6 @@ namespace Yasumi\tests\Estonia; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -36,7 +33,7 @@ class EasterDayTest extends EstoniaBaseTestCase implements HolidayTestCase /** * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function holidayDataProvider(): array { @@ -51,7 +48,7 @@ public function holidayDataProvider(): array * @param int $year the year for which the holiday defined in this test needs to be tested * @param string $expected the expected date * - * @throws Exception + * @throws \Exception */ public function testHoliday(int $year, string $expected): void { @@ -59,14 +56,14 @@ public function testHoliday(int $year, string $expected): void self::REGION, self::HOLIDAY, $year, - new DateTime($expected, new DateTimeZone(self::TIMEZONE)) + new \DateTime($expected, new \DateTimeZone(self::TIMEZONE)) ); } /** * {@inheritdoc} * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -81,7 +78,7 @@ public function testTranslation(): void /** * {@inheritdoc} * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Estonia/EstoniaTest.php b/tests/Estonia/EstoniaTest.php index 41c3e8b07..0bff75dce 100644 --- a/tests/Estonia/EstoniaTest.php +++ b/tests/Estonia/EstoniaTest.php @@ -15,7 +15,6 @@ namespace Yasumi\tests\Estonia; -use ReflectionException; use Yasumi\Holiday; use Yasumi\Provider\Estonia; use Yasumi\tests\ProviderTestCase; @@ -104,7 +103,7 @@ public function testOtherHolidays(): void } /** - * @throws ReflectionException + * @throws \ReflectionException * @throws \Exception */ public function testSources(): void diff --git a/tests/Estonia/GoodFridayDayTest.php b/tests/Estonia/GoodFridayDayTest.php index 8aff83895..34561d7b5 100644 --- a/tests/Estonia/GoodFridayDayTest.php +++ b/tests/Estonia/GoodFridayDayTest.php @@ -15,9 +15,6 @@ namespace Yasumi\tests\Estonia; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -36,7 +33,7 @@ class GoodFridayDayTest extends EstoniaBaseTestCase implements HolidayTestCase /** * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function holidayDataProvider(): array { @@ -51,7 +48,7 @@ public function holidayDataProvider(): array * @param int $year the year for which the holiday defined in this test needs to be tested * @param string $expected the expected date * - * @throws Exception + * @throws \Exception */ public function testHoliday(int $year, string $expected): void { @@ -59,14 +56,14 @@ public function testHoliday(int $year, string $expected): void self::REGION, self::HOLIDAY, $year, - new DateTime($expected, new DateTimeZone(self::TIMEZONE)) + new \DateTime($expected, new \DateTimeZone(self::TIMEZONE)) ); } /** * {@inheritdoc} * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -81,7 +78,7 @@ public function testTranslation(): void /** * {@inheritdoc} * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Estonia/IndependenceDayTest.php b/tests/Estonia/IndependenceDayTest.php index d518c6760..45e59a4e8 100644 --- a/tests/Estonia/IndependenceDayTest.php +++ b/tests/Estonia/IndependenceDayTest.php @@ -15,9 +15,6 @@ namespace Yasumi\tests\Estonia; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\Provider\Estonia; use Yasumi\tests\HolidayTestCase; @@ -37,7 +34,7 @@ class IndependenceDayTest extends EstoniaBaseTestCase implements HolidayTestCase /** * Test if holiday is not defined before. * - * @throws Exception + * @throws \Exception */ public function testHolidayBefore(): void { @@ -51,7 +48,7 @@ public function testHolidayBefore(): void /** * Test if holiday is defined after. * - * @throws Exception + * @throws \Exception */ public function testHolidayAfter(): void { @@ -61,14 +58,14 @@ public function testHolidayAfter(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-02-24", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-02-24", new \DateTimeZone(self::TIMEZONE)) ); } /** * {@inheritdoc} * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -89,7 +86,7 @@ public function testTranslation(): void /** * {@inheritdoc} * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Estonia/InternationalWorkersDayTest.php b/tests/Estonia/InternationalWorkersDayTest.php index a55bfc4fc..9b94c6a6f 100644 --- a/tests/Estonia/InternationalWorkersDayTest.php +++ b/tests/Estonia/InternationalWorkersDayTest.php @@ -15,7 +15,6 @@ namespace Yasumi\tests\Estonia; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,7 +33,7 @@ class InternationalWorkersDayTest extends EstoniaBaseTestCase implements Holiday /** * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function holidayDataProvider(): array { @@ -52,7 +51,7 @@ public function testHoliday(int $year, \DateTimeInterface $expected): void /** * {@inheritdoc} * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -67,7 +66,7 @@ public function testTranslation(): void /** * {@inheritdoc} * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Estonia/NewYearsDayTest.php b/tests/Estonia/NewYearsDayTest.php index fc8222463..1955b2394 100644 --- a/tests/Estonia/NewYearsDayTest.php +++ b/tests/Estonia/NewYearsDayTest.php @@ -15,7 +15,6 @@ namespace Yasumi\tests\Estonia; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,7 +33,7 @@ class NewYearsDayTest extends EstoniaBaseTestCase implements HolidayTestCase /** * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function holidayDataProvider(): array { @@ -52,7 +51,7 @@ public function testHoliday(int $year, \DateTimeInterface $expected): void /** * {@inheritdoc} * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -67,7 +66,7 @@ public function testTranslation(): void /** * {@inheritdoc} * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Estonia/PentecostTest.php b/tests/Estonia/PentecostTest.php index b5ebdc056..ef6ab5f88 100644 --- a/tests/Estonia/PentecostTest.php +++ b/tests/Estonia/PentecostTest.php @@ -15,9 +15,6 @@ namespace Yasumi\tests\Estonia; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -36,7 +33,7 @@ class PentecostTest extends EstoniaBaseTestCase implements HolidayTestCase /** * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function holidayDataProvider(): array { @@ -51,7 +48,7 @@ public function holidayDataProvider(): array * @param int $year the year for which the holiday defined in this test needs to be tested * @param string $expected the expected date * - * @throws Exception + * @throws \Exception */ public function testHoliday(int $year, string $expected): void { @@ -59,14 +56,14 @@ public function testHoliday(int $year, string $expected): void self::REGION, self::HOLIDAY, $year, - new DateTime($expected, new DateTimeZone(self::TIMEZONE)) + new \DateTime($expected, new \DateTimeZone(self::TIMEZONE)) ); } /** * {@inheritdoc} * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -81,7 +78,7 @@ public function testTranslation(): void /** * {@inheritdoc} * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Estonia/RestorationOfIndependenceDayTest.php b/tests/Estonia/RestorationOfIndependenceDayTest.php index bc0e1fa07..a5b3d26dd 100644 --- a/tests/Estonia/RestorationOfIndependenceDayTest.php +++ b/tests/Estonia/RestorationOfIndependenceDayTest.php @@ -15,9 +15,6 @@ namespace Yasumi\tests\Estonia; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\Provider\Estonia; use Yasumi\tests\HolidayTestCase; @@ -37,7 +34,7 @@ class RestorationOfIndependenceDayTest extends EstoniaBaseTestCase implements Ho /** * Test if holiday is not defined before. * - * @throws Exception + * @throws \Exception */ public function testHolidayBefore(): void { @@ -51,7 +48,7 @@ public function testHolidayBefore(): void /** * Test if holiday is defined after. * - * @throws Exception + * @throws \Exception */ public function testHolidayAfter(): void { @@ -61,14 +58,14 @@ public function testHolidayAfter(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-08-20", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-08-20", new \DateTimeZone(self::TIMEZONE)) ); } /** * {@inheritdoc} * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -89,7 +86,7 @@ public function testTranslation(): void /** * {@inheritdoc} * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Estonia/SecondChristmasDayTest.php b/tests/Estonia/SecondChristmasDayTest.php index 46d134394..4deb34a30 100644 --- a/tests/Estonia/SecondChristmasDayTest.php +++ b/tests/Estonia/SecondChristmasDayTest.php @@ -15,7 +15,6 @@ namespace Yasumi\tests\Estonia; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,7 +33,7 @@ class SecondChristmasDayTest extends EstoniaBaseTestCase implements HolidayTestC /** * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function holidayDataProvider(): array { @@ -52,7 +51,7 @@ public function testHoliday(int $year, \DateTimeInterface $expected): void /** * {@inheritdoc} * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -67,7 +66,7 @@ public function testTranslation(): void /** * {@inheritdoc} * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Estonia/StJohnsDayTest.php b/tests/Estonia/StJohnsDayTest.php index f1bd2207d..c05c5b226 100644 --- a/tests/Estonia/StJohnsDayTest.php +++ b/tests/Estonia/StJohnsDayTest.php @@ -15,7 +15,6 @@ namespace Yasumi\tests\Estonia; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,7 +33,7 @@ class StJohnsDayTest extends EstoniaBaseTestCase implements HolidayTestCase /** * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function holidayDataProvider(): array { @@ -52,7 +51,7 @@ public function testHoliday(int $year, \DateTimeInterface $expected): void /** * {@inheritdoc} * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -67,7 +66,7 @@ public function testTranslation(): void /** * {@inheritdoc} * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Estonia/VictoryDayTest.php b/tests/Estonia/VictoryDayTest.php index 853b7f329..8337096ab 100644 --- a/tests/Estonia/VictoryDayTest.php +++ b/tests/Estonia/VictoryDayTest.php @@ -15,9 +15,6 @@ namespace Yasumi\tests\Estonia; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\Provider\Estonia; use Yasumi\tests\HolidayTestCase; @@ -37,7 +34,7 @@ class VictoryDayTest extends EstoniaBaseTestCase implements HolidayTestCase /** * Test if holiday is not defined before. * - * @throws Exception + * @throws \Exception */ public function testHolidayBefore(): void { @@ -51,7 +48,7 @@ public function testHolidayBefore(): void /** * Test if holiday is defined after. * - * @throws Exception + * @throws \Exception */ public function testHolidayAfter(): void { @@ -61,14 +58,14 @@ public function testHolidayAfter(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-06-23", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-06-23", new \DateTimeZone(self::TIMEZONE)) ); } /** * {@inheritdoc} * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -89,7 +86,7 @@ public function testTranslation(): void /** * {@inheritdoc} * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Finland/AllSaintsDayTest.php b/tests/Finland/AllSaintsDayTest.php index 3deefeaa3..ecf9c3772 100644 --- a/tests/Finland/AllSaintsDayTest.php +++ b/tests/Finland/AllSaintsDayTest.php @@ -14,10 +14,6 @@ namespace Yasumi\tests\Finland; -use DateInterval; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -36,8 +32,8 @@ class AllSaintsDayTest extends FinlandBaseTestCase implements HolidayTestCase * * @dataProvider HolidayDataProvider * - * @param int $year the year for which the holiday defined in this test needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which the holiday defined in this test needs to be tested + * @param \DateTime $expected the expected date */ public function testHoliday(int $year, \DateTimeInterface $expected): void { @@ -49,7 +45,7 @@ public function testHoliday(int $year, \DateTimeInterface $expected): void * * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function HolidayDataProvider(): array { @@ -57,7 +53,7 @@ public function HolidayDataProvider(): array for ($y = 0; $y < 50; ++$y) { $year = $this->generateRandomYear(); - $date = new DateTime("$year-10-31", new DateTimeZone(self::TIMEZONE)); + $date = new \DateTime("$year-10-31", new \DateTimeZone(self::TIMEZONE)); // Check between 31 October and 6th of November the day that is a Saturday for ($d = 0; $d <= 7; ++$d) { @@ -65,7 +61,7 @@ public function HolidayDataProvider(): array $data[] = [$year, $date]; break; } - $date->add(new DateInterval('P1D')); + $date->add(new \DateInterval('P1D')); } } @@ -75,7 +71,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -90,7 +86,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Finland/AscensionDayTest.php b/tests/Finland/AscensionDayTest.php index d052f8fea..91c03c4d6 100644 --- a/tests/Finland/AscensionDayTest.php +++ b/tests/Finland/AscensionDayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Finland; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -33,7 +30,7 @@ class AscensionDayTest extends FinlandBaseTestCase implements HolidayTestCase /** * Tests the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHoliday(): void { @@ -42,14 +39,14 @@ public function testHoliday(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-5-5", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-5-5", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -64,7 +61,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Finland/ChristmasDayTest.php b/tests/Finland/ChristmasDayTest.php index d5142fee6..6f81b663f 100644 --- a/tests/Finland/ChristmasDayTest.php +++ b/tests/Finland/ChristmasDayTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\Finland; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,8 +32,8 @@ class ChristmasDayTest extends FinlandBaseTestCase implements HolidayTestCase * * @dataProvider HolidayDataProvider * - * @param int $year the year for which the holiday defined in this test needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which the holiday defined in this test needs to be tested + * @param \DateTime $expected the expected date */ public function testHoliday(int $year, \DateTimeInterface $expected): void { @@ -47,7 +45,7 @@ public function testHoliday(int $year, \DateTimeInterface $expected): void * * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function HolidayDataProvider(): array { @@ -57,7 +55,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -72,7 +70,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Finland/EasterMondayTest.php b/tests/Finland/EasterMondayTest.php index ed1e5e3a7..314812acd 100644 --- a/tests/Finland/EasterMondayTest.php +++ b/tests/Finland/EasterMondayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Finland; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -33,7 +30,7 @@ class EasterMondayTest extends FinlandBaseTestCase implements HolidayTestCase /** * Tests the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHoliday(): void { @@ -42,14 +39,14 @@ public function testHoliday(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-4-16", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-4-16", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -64,7 +61,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Finland/EasterTest.php b/tests/Finland/EasterTest.php index 10e0ffa1b..d09d2ba9b 100644 --- a/tests/Finland/EasterTest.php +++ b/tests/Finland/EasterTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Finland; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -33,7 +30,7 @@ class EasterTest extends FinlandBaseTestCase implements HolidayTestCase /** * Tests the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHoliday(): void { @@ -42,14 +39,14 @@ public function testHoliday(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-4-15", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-4-15", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -64,7 +61,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Finland/EpiphanyTest.php b/tests/Finland/EpiphanyTest.php index ede0e1bc8..0841b7980 100644 --- a/tests/Finland/EpiphanyTest.php +++ b/tests/Finland/EpiphanyTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\Finland; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,8 +32,8 @@ class EpiphanyTest extends FinlandBaseTestCase implements HolidayTestCase * * @dataProvider HolidayDataProvider * - * @param int $year the year for which the holiday defined in this test needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which the holiday defined in this test needs to be tested + * @param \DateTime $expected the expected date */ public function testHoliday(int $year, \DateTimeInterface $expected): void { @@ -47,7 +45,7 @@ public function testHoliday(int $year, \DateTimeInterface $expected): void * * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function HolidayDataProvider(): array { @@ -57,7 +55,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -72,7 +70,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Finland/FinlandTest.php b/tests/Finland/FinlandTest.php index 16a8dc1db..859a8ff3a 100644 --- a/tests/Finland/FinlandTest.php +++ b/tests/Finland/FinlandTest.php @@ -14,7 +14,6 @@ namespace Yasumi\tests\Finland; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\ProviderTestCase; @@ -93,7 +92,7 @@ public function testOtherHolidays(): void } /** - * @throws ReflectionException + * @throws \ReflectionException * @throws \Exception */ public function testSources(): void diff --git a/tests/Finland/GoodFridayTest.php b/tests/Finland/GoodFridayTest.php index 196ff2288..4d4359c19 100644 --- a/tests/Finland/GoodFridayTest.php +++ b/tests/Finland/GoodFridayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Finland; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -33,7 +30,7 @@ class GoodFridayTest extends FinlandBaseTestCase implements HolidayTestCase /** * Tests the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHoliday(): void { @@ -42,14 +39,14 @@ public function testHoliday(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-3-21", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-3-21", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -64,7 +61,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Finland/IndependenceDayTest.php b/tests/Finland/IndependenceDayTest.php index 4552495b2..215377dfb 100644 --- a/tests/Finland/IndependenceDayTest.php +++ b/tests/Finland/IndependenceDayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Finland; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -38,7 +35,7 @@ class IndependenceDayTest extends FinlandBaseTestCase implements HolidayTestCase /** * Tests the holiday defined in this test on or after establishment. * - * @throws Exception + * @throws \Exception */ public function testHolidayOnAfterEstablishment(): void { @@ -47,14 +44,14 @@ public function testHolidayOnAfterEstablishment(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-12-6", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-12-6", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests the holiday defined in this test before establishment. * - * @throws Exception + * @throws \Exception */ public function testHolidayBeforeEstablishment(): void { @@ -68,7 +65,7 @@ public function testHolidayBeforeEstablishment(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -83,7 +80,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Finland/InternationalWorkersDayTest.php b/tests/Finland/InternationalWorkersDayTest.php index eca26f759..7c650a6fc 100644 --- a/tests/Finland/InternationalWorkersDayTest.php +++ b/tests/Finland/InternationalWorkersDayTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\Finland; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,8 +32,8 @@ class InternationalWorkersDayTest extends FinlandBaseTestCase implements Holiday * * @dataProvider HolidayDataProvider * - * @param int $year the year for which the holiday defined in this test needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which the holiday defined in this test needs to be tested + * @param \DateTime $expected the expected date */ public function testHoliday(int $year, \DateTimeInterface $expected): void { @@ -45,7 +43,7 @@ public function testHoliday(int $year, \DateTimeInterface $expected): void /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -60,7 +58,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { @@ -72,7 +70,7 @@ public function testHolidayType(): void * * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function HolidayDataProvider(): array { diff --git a/tests/Finland/NewYearsDayTest.php b/tests/Finland/NewYearsDayTest.php index 7d5da8c16..b9811060b 100644 --- a/tests/Finland/NewYearsDayTest.php +++ b/tests/Finland/NewYearsDayTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\Finland; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,8 +32,8 @@ class NewYearsDayTest extends FinlandBaseTestCase implements HolidayTestCase * * @dataProvider HolidayDataProvider * - * @param int $year the year for which the holiday defined in this test needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which the holiday defined in this test needs to be tested + * @param \DateTime $expected the expected date */ public function testHoliday(int $year, \DateTimeInterface $expected): void { @@ -47,7 +45,7 @@ public function testHoliday(int $year, \DateTimeInterface $expected): void * * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function HolidayDataProvider(): array { @@ -57,7 +55,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -72,7 +70,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Finland/PentecostTest.php b/tests/Finland/PentecostTest.php index c3cb5edbd..ffc0b47c9 100644 --- a/tests/Finland/PentecostTest.php +++ b/tests/Finland/PentecostTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Finland; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -33,7 +30,7 @@ class PentecostTest extends FinlandBaseTestCase implements HolidayTestCase /** * Tests the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHoliday(): void { @@ -42,14 +39,14 @@ public function testHoliday(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-5-23", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-5-23", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -64,7 +61,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Finland/SecondChristmasDayTest.php b/tests/Finland/SecondChristmasDayTest.php index f5910b22d..4189931d1 100644 --- a/tests/Finland/SecondChristmasDayTest.php +++ b/tests/Finland/SecondChristmasDayTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\Finland; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,8 +32,8 @@ class SecondChristmasDayTest extends FinlandBaseTestCase implements HolidayTestC * * @dataProvider HolidayDataProvider * - * @param int $year the year for which the holiday defined in this test needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which the holiday defined in this test needs to be tested + * @param \DateTime $expected the expected date */ public function testHoliday(int $year, \DateTimeInterface $expected): void { @@ -47,7 +45,7 @@ public function testHoliday(int $year, \DateTimeInterface $expected): void * * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function HolidayDataProvider(): array { @@ -57,7 +55,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -72,7 +70,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Finland/stJohnsDayTest.php b/tests/Finland/stJohnsDayTest.php index ca7a7fe0b..5c513a1d9 100644 --- a/tests/Finland/stJohnsDayTest.php +++ b/tests/Finland/stJohnsDayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Finland; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; use Yasumi\Yasumi; @@ -42,7 +39,7 @@ class stJohnsDayTest extends FinlandBaseTestCase implements HolidayTestCase /** * Tests the holiday before it was adjusted. * - * @throws Exception + * @throws \Exception */ public function testHolidayBeforeAdjustment(): void { @@ -51,14 +48,14 @@ public function testHolidayBeforeAdjustment(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-6-24", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-6-24", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests the holiday before it was adjusted. * - * @throws Exception + * @throws \Exception */ public function testHolidayAfterAdjustment(): void { @@ -82,7 +79,7 @@ public function testHolidayAfterAdjustment(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -97,7 +94,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/France/AllSaintsDayTest.php b/tests/France/AllSaintsDayTest.php index 4801936cb..5f9499adf 100644 --- a/tests/France/AllSaintsDayTest.php +++ b/tests/France/AllSaintsDayTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\France; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,8 +32,8 @@ class AllSaintsDayTest extends FranceBaseTestCase implements HolidayTestCase * * @dataProvider AllSaintsDayDataProvider * - * @param int $year the year for which All Saints' Day needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which All Saints' Day needs to be tested + * @param \DateTime $expected the expected date */ public function testAllSaintsDay(int $year, \DateTimeInterface $expected): void { @@ -45,7 +43,7 @@ public function testAllSaintsDay(int $year, \DateTimeInterface $expected): void /** * Tests translated name of All Saints' Day. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -60,7 +58,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { @@ -72,7 +70,7 @@ public function testHolidayType(): void * * @return array list of test dates for All Saints' Day * - * @throws Exception + * @throws \Exception */ public function AllSaintsDayDataProvider(): array { diff --git a/tests/France/ArmisticeDayTest.php b/tests/France/ArmisticeDayTest.php index b9a44cebd..4f94c5fa5 100644 --- a/tests/France/ArmisticeDayTest.php +++ b/tests/France/ArmisticeDayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\France; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -38,7 +35,7 @@ class ArmisticeDayTest extends FranceBaseTestCase implements HolidayTestCase /** * Tests Armistice Day on or after 1919. * - * @throws Exception + * @throws \Exception */ public function testArmisticeDayOnAfter1919(): void { @@ -47,14 +44,14 @@ public function testArmisticeDayOnAfter1919(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-11-11", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-11-11", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests Armistice Day before 1919. * - * @throws Exception + * @throws \Exception */ public function testArmisticeDayBefore1919(): void { @@ -68,7 +65,7 @@ public function testArmisticeDayBefore1919(): void /** * Tests translated name of Armistice Day. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -83,7 +80,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/France/AscensionDayTest.php b/tests/France/AscensionDayTest.php index 2d9b2d24a..71ecae3de 100644 --- a/tests/France/AscensionDayTest.php +++ b/tests/France/AscensionDayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\France; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -33,7 +30,7 @@ class AscensionDayTest extends FranceBaseTestCase implements HolidayTestCase /** * Tests Ascension Day. * - * @throws Exception + * @throws \Exception */ public function testAscensionDay(): void { @@ -42,14 +39,14 @@ public function testAscensionDay(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-5-16", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-5-16", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests translated name of Ascension Day. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -64,7 +61,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/France/AssumptionOfMaryTest.php b/tests/France/AssumptionOfMaryTest.php index 64bdcfcb5..d83d0f7ba 100644 --- a/tests/France/AssumptionOfMaryTest.php +++ b/tests/France/AssumptionOfMaryTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\France; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,8 +32,8 @@ class AssumptionOfMaryTest extends FranceBaseTestCase implements HolidayTestCase * * @dataProvider AssumptionOfMaryDataProvider * - * @param int $year the year for which the day of the Assumption of Mary needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which the day of the Assumption of Mary needs to be tested + * @param \DateTime $expected the expected date */ public function testAssumptionOfMary(int $year, \DateTimeInterface $expected): void { @@ -45,7 +43,7 @@ public function testAssumptionOfMary(int $year, \DateTimeInterface $expected): v /** * Tests translated name of the day of the Assumption of Mary. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -60,7 +58,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { @@ -72,7 +70,7 @@ public function testHolidayType(): void * * @return array list of test dates for the day of the Assumption of Mary * - * @throws Exception + * @throws \Exception */ public function AssumptionOfMaryDataProvider(): array { diff --git a/tests/France/BasRhin/BasRhinTest.php b/tests/France/BasRhin/BasRhinTest.php index f9989c4be..1234e41ba 100644 --- a/tests/France/BasRhin/BasRhinTest.php +++ b/tests/France/BasRhin/BasRhinTest.php @@ -14,7 +14,6 @@ namespace Yasumi\tests\France\BasRhin; -use ReflectionException; use Yasumi\Holiday; use Yasumi\Provider\France; use Yasumi\tests\ProviderTestCase; @@ -104,7 +103,7 @@ public function testOtherHolidays(): void } /** - * @throws ReflectionException + * @throws \ReflectionException * @throws \Exception */ public function testSources(): void diff --git a/tests/France/BasRhin/GoodFridayTest.php b/tests/France/BasRhin/GoodFridayTest.php index 17b09c753..f1e1799fd 100644 --- a/tests/France/BasRhin/GoodFridayTest.php +++ b/tests/France/BasRhin/GoodFridayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\France\BasRhin; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -33,7 +30,7 @@ class GoodFridayTest extends BasRhinBaseTestCase implements HolidayTestCase /** * Tests the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHoliday(): void { @@ -42,14 +39,14 @@ public function testHoliday(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-3-21", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-3-21", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -64,7 +61,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/France/BasRhin/stStephensDayTest.php b/tests/France/BasRhin/stStephensDayTest.php index ae97de54a..e6d0990ef 100644 --- a/tests/France/BasRhin/stStephensDayTest.php +++ b/tests/France/BasRhin/stStephensDayTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\France\BasRhin; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,8 +32,8 @@ class stStephensDayTest extends BasRhinBaseTestCase implements HolidayTestCase * * @dataProvider HolidayDataProvider * - * @param int $year the year for which the holiday defined in this test needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which the holiday defined in this test needs to be tested + * @param \DateTime $expected the expected date */ public function testHoliday(int $year, \DateTimeInterface $expected): void { @@ -47,7 +45,7 @@ public function testHoliday(int $year, \DateTimeInterface $expected): void * * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function HolidayDataProvider(): array { @@ -57,7 +55,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -72,7 +70,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/France/BastilleDayTest.php b/tests/France/BastilleDayTest.php index fda55e4e0..b5561d67c 100644 --- a/tests/France/BastilleDayTest.php +++ b/tests/France/BastilleDayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\France; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -38,7 +35,7 @@ class BastilleDayTest extends FranceBaseTestCase implements HolidayTestCase /** * Tests Bastille Day on or after 1790. * - * @throws Exception + * @throws \Exception */ public function testBastilleDayOnAfter1790(): void { @@ -47,14 +44,14 @@ public function testBastilleDayOnAfter1790(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-7-14", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-7-14", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests Bastille Day before 1790. * - * @throws Exception + * @throws \Exception */ public function testBastilleDayBefore1790(): void { @@ -68,7 +65,7 @@ public function testBastilleDayBefore1790(): void /** * Tests translated name of Bastille Day. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -83,7 +80,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/France/ChristmasDayTest.php b/tests/France/ChristmasDayTest.php index b23b24a16..4f4292fee 100644 --- a/tests/France/ChristmasDayTest.php +++ b/tests/France/ChristmasDayTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\France; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,8 +32,8 @@ class ChristmasDayTest extends FranceBaseTestCase implements HolidayTestCase * * @dataProvider ChristmasDayDataProvider * - * @param int $year the year for which Christmas Day needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which Christmas Day needs to be tested + * @param \DateTime $expected the expected date */ public function testChristmasDay(int $year, \DateTimeInterface $expected): void { @@ -47,7 +45,7 @@ public function testChristmasDay(int $year, \DateTimeInterface $expected): void * * @return array list of test dates for Christmas Day * - * @throws Exception + * @throws \Exception */ public function ChristmasDayDataProvider(): array { @@ -57,7 +55,7 @@ public function ChristmasDayDataProvider(): array /** * Tests translated name of Christmas Day. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -72,7 +70,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/France/EasterMondayTest.php b/tests/France/EasterMondayTest.php index 63b506330..6a880df5a 100644 --- a/tests/France/EasterMondayTest.php +++ b/tests/France/EasterMondayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\France; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -33,7 +30,7 @@ class EasterMondayTest extends FranceBaseTestCase implements HolidayTestCase /** * Tests Easter Monday. * - * @throws Exception + * @throws \Exception */ public function testEasterMonday(): void { @@ -42,14 +39,14 @@ public function testEasterMonday(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-3-28", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-3-28", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests translated name of Easter Monday. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -64,7 +61,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/France/FranceTest.php b/tests/France/FranceTest.php index d73298a89..9f444f421 100644 --- a/tests/France/FranceTest.php +++ b/tests/France/FranceTest.php @@ -14,7 +14,6 @@ namespace Yasumi\tests\France; -use ReflectionException; use Yasumi\Holiday; use Yasumi\Provider\France; use Yasumi\tests\ProviderTestCase; @@ -104,7 +103,7 @@ public function testOtherHolidays(): void } /** - * @throws ReflectionException + * @throws \ReflectionException * @throws \Exception */ public function testSources(): void diff --git a/tests/France/HautRhin/GoodFridayTest.php b/tests/France/HautRhin/GoodFridayTest.php index 4e06aaeca..d7f599a10 100644 --- a/tests/France/HautRhin/GoodFridayTest.php +++ b/tests/France/HautRhin/GoodFridayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\France\HautRhin; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -33,7 +30,7 @@ class GoodFridayTest extends HautRhinBaseTestCase implements HolidayTestCase /** * Tests the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHoliday(): void { @@ -42,14 +39,14 @@ public function testHoliday(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-3-21", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-3-21", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -64,7 +61,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/France/HautRhin/HautRhinTest.php b/tests/France/HautRhin/HautRhinTest.php index 245177756..38d33c3b1 100644 --- a/tests/France/HautRhin/HautRhinTest.php +++ b/tests/France/HautRhin/HautRhinTest.php @@ -14,7 +14,6 @@ namespace Yasumi\tests\France\HautRhin; -use ReflectionException; use Yasumi\Holiday; use Yasumi\Provider\France; use Yasumi\tests\ProviderTestCase; @@ -104,7 +103,7 @@ public function testOtherHolidays(): void } /** - * @throws ReflectionException + * @throws \ReflectionException * @throws \Exception */ public function testSources(): void diff --git a/tests/France/HautRhin/stStephensDayTest.php b/tests/France/HautRhin/stStephensDayTest.php index 523cc1b04..b350a2470 100644 --- a/tests/France/HautRhin/stStephensDayTest.php +++ b/tests/France/HautRhin/stStephensDayTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\France\HautRhin; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,8 +32,8 @@ class stStephensDayTest extends HautRhinBaseTestCase implements HolidayTestCase * * @dataProvider HolidayDataProvider * - * @param int $year the year for which the holiday defined in this test needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which the holiday defined in this test needs to be tested + * @param \DateTime $expected the expected date */ public function testHoliday(int $year, \DateTimeInterface $expected): void { @@ -47,7 +45,7 @@ public function testHoliday(int $year, \DateTimeInterface $expected): void * * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function HolidayDataProvider(): array { @@ -57,7 +55,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -72,7 +70,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/France/InternationalWorkersDayTest.php b/tests/France/InternationalWorkersDayTest.php index 3d8dbb63f..5a34513e0 100644 --- a/tests/France/InternationalWorkersDayTest.php +++ b/tests/France/InternationalWorkersDayTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\France; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,8 +32,8 @@ class InternationalWorkersDayTest extends FranceBaseTestCase implements HolidayT * * @dataProvider InternationalWorkersDayDataProvider * - * @param int $year the year for which International Workers' Day needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which International Workers' Day needs to be tested + * @param \DateTime $expected the expected date */ public function testInternationalWorkersDay(int $year, \DateTimeInterface $expected): void { @@ -45,7 +43,7 @@ public function testInternationalWorkersDay(int $year, \DateTimeInterface $expec /** * Tests translated name of International Workers' Day. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -60,7 +58,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { @@ -72,7 +70,7 @@ public function testHolidayType(): void * * @return array list of test dates for International Workers' Day * - * @throws Exception + * @throws \Exception */ public function InternationalWorkersDayDataProvider(): array { diff --git a/tests/France/Moselle/GoodFridayTest.php b/tests/France/Moselle/GoodFridayTest.php index 05c2cb6cd..80b6346fc 100644 --- a/tests/France/Moselle/GoodFridayTest.php +++ b/tests/France/Moselle/GoodFridayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\France\Moselle; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -33,7 +30,7 @@ class GoodFridayTest extends MoselleBaseTestCase implements HolidayTestCase /** * Tests the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHoliday(): void { @@ -42,14 +39,14 @@ public function testHoliday(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-3-21", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-3-21", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -64,7 +61,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/France/Moselle/MoselleTest.php b/tests/France/Moselle/MoselleTest.php index 12ed17a99..d036632a7 100644 --- a/tests/France/Moselle/MoselleTest.php +++ b/tests/France/Moselle/MoselleTest.php @@ -14,7 +14,6 @@ namespace Yasumi\tests\France\Moselle; -use ReflectionException; use Yasumi\Holiday; use Yasumi\Provider\France; use Yasumi\tests\ProviderTestCase; @@ -104,7 +103,7 @@ public function testOtherHolidays(): void } /** - * @throws ReflectionException + * @throws \ReflectionException * @throws \Exception */ public function testSources(): void diff --git a/tests/France/Moselle/stStephensDayTest.php b/tests/France/Moselle/stStephensDayTest.php index 894b40288..692342ae3 100644 --- a/tests/France/Moselle/stStephensDayTest.php +++ b/tests/France/Moselle/stStephensDayTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\France\Moselle; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,8 +32,8 @@ class stStephensDayTest extends MoselleBaseTestCase implements HolidayTestCase * * @dataProvider HolidayDataProvider * - * @param int $year the year for which the holiday defined in this test needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which the holiday defined in this test needs to be tested + * @param \DateTime $expected the expected date */ public function testHoliday(int $year, \DateTimeInterface $expected): void { @@ -47,7 +45,7 @@ public function testHoliday(int $year, \DateTimeInterface $expected): void * * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function HolidayDataProvider(): array { @@ -57,7 +55,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -72,7 +70,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/France/NewYearsDayTest.php b/tests/France/NewYearsDayTest.php index 86ebe9251..75b8fc3e3 100644 --- a/tests/France/NewYearsDayTest.php +++ b/tests/France/NewYearsDayTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\France; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,8 +32,8 @@ class NewYearsDayTest extends FranceBaseTestCase implements HolidayTestCase * * @dataProvider NewYearsDayDataProvider * - * @param int $year the year for which New Years Day needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which New Years Day needs to be tested + * @param \DateTime $expected the expected date */ public function testNewYearsDay(int $year, \DateTimeInterface $expected): void { @@ -45,7 +43,7 @@ public function testNewYearsDay(int $year, \DateTimeInterface $expected): void /** * Tests translated name of New Years Day. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -60,7 +58,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { @@ -72,7 +70,7 @@ public function testHolidayType(): void * * @return array list of test dates for New Years Day * - * @throws Exception + * @throws \Exception */ public function NewYearsDayDataProvider(): array { diff --git a/tests/France/PentecostMondayTest.php b/tests/France/PentecostMondayTest.php index 8b9060f06..379b7718d 100644 --- a/tests/France/PentecostMondayTest.php +++ b/tests/France/PentecostMondayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\France; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\Provider\France; use Yasumi\tests\HolidayTestCase; @@ -34,7 +31,7 @@ class PentecostMondayTest extends FranceBaseTestCase implements HolidayTestCase /** * Tests Pentecost Monday. * - * @throws Exception + * @throws \Exception */ public function testPentecostMonday(): void { @@ -43,14 +40,14 @@ public function testPentecostMonday(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-5-30", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-5-30", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests translated name of Pentecost Monday. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -65,7 +62,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/France/VictoryInEuropeDayTest.php b/tests/France/VictoryInEuropeDayTest.php index 3b1dc75b1..e6bf04ed9 100644 --- a/tests/France/VictoryInEuropeDayTest.php +++ b/tests/France/VictoryInEuropeDayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\France; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -38,7 +35,7 @@ class VictoryInEuropeDayTest extends FranceBaseTestCase implements HolidayTestCa /** * Tests Victory In Europe Day on or after 1945. * - * @throws Exception + * @throws \Exception */ public function testVictoryInEuropeDayOnAfter1945(): void { @@ -47,14 +44,14 @@ public function testVictoryInEuropeDayOnAfter1945(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-5-8", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-5-8", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests Victory In Europe Day before 1945. * - * @throws Exception + * @throws \Exception */ public function testVictoryInEuropeDayBefore1945(): void { @@ -68,7 +65,7 @@ public function testVictoryInEuropeDayBefore1945(): void /** * Tests translated name of Victory in Europe Day. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -83,7 +80,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Georgia/EasterTest.php b/tests/Georgia/EasterTest.php index d2207f46c..4cfb47237 100644 --- a/tests/Georgia/EasterTest.php +++ b/tests/Georgia/EasterTest.php @@ -4,9 +4,6 @@ namespace Yasumi\tests\Georgia; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -20,7 +17,7 @@ class EasterTest extends GeorgiaBaseTestCase implements HolidayTestCase /** * Tests the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHoliday(): void { @@ -30,14 +27,14 @@ public function testHoliday(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-04-28", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-04-28", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -52,7 +49,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Georgia/GeorgiaTest.php b/tests/Georgia/GeorgiaTest.php index c135e9b52..9319bd6ed 100644 --- a/tests/Georgia/GeorgiaTest.php +++ b/tests/Georgia/GeorgiaTest.php @@ -15,7 +15,6 @@ namespace Yasumi\tests\Georgia; -use ReflectionException; use Yasumi\Holiday; use Yasumi\Provider\Georgia; use Yasumi\tests\ProviderTestCase; @@ -105,7 +104,7 @@ public function testOtherHolidays(): void } /** - * @throws ReflectionException + * @throws \ReflectionException * @throws \Exception */ public function testSources(): void diff --git a/tests/Georgia/IndependenceDayTest.php b/tests/Georgia/IndependenceDayTest.php index 90afd51f2..c00a43b40 100644 --- a/tests/Georgia/IndependenceDayTest.php +++ b/tests/Georgia/IndependenceDayTest.php @@ -15,9 +15,6 @@ namespace Yasumi\tests\Georgia; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -29,7 +26,7 @@ class IndependenceDayTest extends GeorgiaBaseTestCase implements HolidayTestCase public const HOLIDAY = 'independenceDay'; /** - * @throws Exception + * @throws \Exception */ public function testHoliday(): void { @@ -38,7 +35,7 @@ public function testHoliday(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-05-26", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-05-26", new \DateTimeZone(self::TIMEZONE)) ); } diff --git a/tests/Georgia/InternationalWomensDayTest.php b/tests/Georgia/InternationalWomensDayTest.php index 83d9ddf47..7bda13839 100644 --- a/tests/Georgia/InternationalWomensDayTest.php +++ b/tests/Georgia/InternationalWomensDayTest.php @@ -15,7 +15,6 @@ namespace Yasumi\tests\Georgia; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -39,7 +38,7 @@ public function testHoliday(int $year, \DateTimeInterface $expected): void * * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function HolidayDataProvider(): array { @@ -49,7 +48,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -64,7 +63,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Georgia/MtskhetobaDayTest.php b/tests/Georgia/MtskhetobaDayTest.php index 80724e2d5..be2f9ed62 100644 --- a/tests/Georgia/MtskhetobaDayTest.php +++ b/tests/Georgia/MtskhetobaDayTest.php @@ -15,7 +15,6 @@ namespace Yasumi\tests\Georgia; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -39,7 +38,7 @@ public function testHoliday(int $year, \DateTimeInterface $expected): void * * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function HolidayDataProvider(): array { @@ -49,7 +48,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -64,7 +63,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Georgia/NewYearsDayTest.php b/tests/Georgia/NewYearsDayTest.php index 03de05be4..531633ed0 100644 --- a/tests/Georgia/NewYearsDayTest.php +++ b/tests/Georgia/NewYearsDayTest.php @@ -15,7 +15,6 @@ namespace Yasumi\tests\Georgia; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -39,7 +38,7 @@ public function testHoliday(int $year, \DateTimeInterface $expected): void * * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function HolidayDataProvider(): array { @@ -49,7 +48,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -64,7 +63,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Georgia/OrthodoxChristmasDayTest.php b/tests/Georgia/OrthodoxChristmasDayTest.php index 298514f29..dbf958bca 100644 --- a/tests/Georgia/OrthodoxChristmasDayTest.php +++ b/tests/Georgia/OrthodoxChristmasDayTest.php @@ -15,7 +15,6 @@ namespace Yasumi\tests\Georgia; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -39,7 +38,7 @@ public function testHoliday(int $year, \DateTimeInterface $expected): void * * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function HolidayDataProvider(): array { @@ -49,7 +48,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -64,7 +63,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Georgia/OrthodoxEpiphanyDayTest.php b/tests/Georgia/OrthodoxEpiphanyDayTest.php index a16b21afb..b1833604e 100644 --- a/tests/Georgia/OrthodoxEpiphanyDayTest.php +++ b/tests/Georgia/OrthodoxEpiphanyDayTest.php @@ -15,7 +15,6 @@ namespace Yasumi\tests\Georgia; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -39,7 +38,7 @@ public function testHoliday(int $year, \DateTimeInterface $expected): void * * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function HolidayDataProvider(): array { @@ -49,7 +48,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -64,7 +63,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Georgia/SecondNewYearDayTest.php b/tests/Georgia/SecondNewYearDayTest.php index 778a41967..1f26b69c3 100644 --- a/tests/Georgia/SecondNewYearDayTest.php +++ b/tests/Georgia/SecondNewYearDayTest.php @@ -15,7 +15,6 @@ namespace Yasumi\tests\Georgia; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -39,7 +38,7 @@ public function testHoliday(int $year, \DateTimeInterface $expected): void * * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function HolidayDataProvider(): array { @@ -49,7 +48,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -64,7 +63,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Georgia/StAndrewsDayTest.php b/tests/Georgia/StAndrewsDayTest.php index 6e4fe4fb8..cb565d1ba 100644 --- a/tests/Georgia/StAndrewsDayTest.php +++ b/tests/Georgia/StAndrewsDayTest.php @@ -15,7 +15,6 @@ namespace Yasumi\tests\Georgia; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -39,7 +38,7 @@ public function testHoliday(int $year, \DateTimeInterface $expected): void * * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function HolidayDataProvider(): array { @@ -49,7 +48,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -64,7 +63,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Georgia/StGeorgesDayTest.php b/tests/Georgia/StGeorgesDayTest.php index 5a38a1a6b..7532d327b 100644 --- a/tests/Georgia/StGeorgesDayTest.php +++ b/tests/Georgia/StGeorgesDayTest.php @@ -15,7 +15,6 @@ namespace Yasumi\tests\Georgia; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -39,7 +38,7 @@ public function testHoliday(int $year, \DateTimeInterface $expected): void * * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function HolidayDataProvider(): array { @@ -49,7 +48,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -64,7 +63,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Georgia/StMarysDayTest.php b/tests/Georgia/StMarysDayTest.php index a8789ef16..d11b77c6e 100644 --- a/tests/Georgia/StMarysDayTest.php +++ b/tests/Georgia/StMarysDayTest.php @@ -15,7 +15,6 @@ namespace Yasumi\tests\Georgia; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -39,7 +38,7 @@ public function testHoliday(int $year, \DateTimeInterface $expected): void * * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function HolidayDataProvider(): array { @@ -49,7 +48,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -64,7 +63,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Georgia/UnityDayTest.php b/tests/Georgia/UnityDayTest.php index c0a9724de..7186bd68c 100644 --- a/tests/Georgia/UnityDayTest.php +++ b/tests/Georgia/UnityDayTest.php @@ -15,9 +15,6 @@ namespace Yasumi\tests\Georgia; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -29,7 +26,7 @@ class UnityDayTest extends GeorgiaBaseTestCase implements HolidayTestCase public const HOLIDAY = 'unityDay'; /** - * @throws Exception + * @throws \Exception */ public function testHoliday(): void { @@ -38,7 +35,7 @@ public function testHoliday(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-04-09", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-04-09", new \DateTimeZone(self::TIMEZONE)) ); } diff --git a/tests/Georgia/VictoryDayTest.php b/tests/Georgia/VictoryDayTest.php index 58ace6026..38126bb7a 100644 --- a/tests/Georgia/VictoryDayTest.php +++ b/tests/Georgia/VictoryDayTest.php @@ -15,7 +15,6 @@ namespace Yasumi\tests\Georgia; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -39,7 +38,7 @@ public function testHoliday(int $year, \DateTimeInterface $expected): void * * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function HolidayDataProvider(): array { @@ -49,7 +48,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -64,7 +63,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Germany/AscensionDayTest.php b/tests/Germany/AscensionDayTest.php index 9b6fb6f42..1b0a5762e 100644 --- a/tests/Germany/AscensionDayTest.php +++ b/tests/Germany/AscensionDayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Germany; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -33,7 +30,7 @@ class AscensionDayTest extends GermanyBaseTestCase implements HolidayTestCase /** * Tests Ascension Day. * - * @throws Exception + * @throws \Exception */ public function testAscensionDay(): void { @@ -42,14 +39,14 @@ public function testAscensionDay(): void self::REGION, 'ascensionDay', $year, - new DateTime("$year-5-23", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-5-23", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -64,7 +61,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Germany/BadenWurttemberg/AllSaintsDayTest.php b/tests/Germany/BadenWurttemberg/AllSaintsDayTest.php index 7f5226326..31fd2bd8a 100644 --- a/tests/Germany/BadenWurttemberg/AllSaintsDayTest.php +++ b/tests/Germany/BadenWurttemberg/AllSaintsDayTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\Germany\BadenWurttemberg; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,8 +32,8 @@ class AllSaintsDayTest extends BadenWurttembergBaseTestCase implements HolidayTe * * @dataProvider HolidayDataProvider * - * @param int $year the year for which the holiday defined in this test needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which the holiday defined in this test needs to be tested + * @param \DateTime $expected the expected date */ public function testHoliday(int $year, \DateTimeInterface $expected): void { @@ -47,7 +45,7 @@ public function testHoliday(int $year, \DateTimeInterface $expected): void * * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function HolidayDataProvider(): array { @@ -57,7 +55,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -72,7 +70,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Germany/BadenWurttemberg/BadenWurttembergTest.php b/tests/Germany/BadenWurttemberg/BadenWurttembergTest.php index d3c13b388..9d66930c7 100644 --- a/tests/Germany/BadenWurttemberg/BadenWurttembergTest.php +++ b/tests/Germany/BadenWurttemberg/BadenWurttembergTest.php @@ -14,7 +14,6 @@ namespace Yasumi\tests\Germany\BadenWurttemberg; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\ProviderTestCase; @@ -96,7 +95,7 @@ public function testOtherHolidays(): void } /** - * @throws ReflectionException + * @throws \ReflectionException * @throws \Exception */ public function testSources(): void diff --git a/tests/Germany/BadenWurttemberg/CorpusChristiTest.php b/tests/Germany/BadenWurttemberg/CorpusChristiTest.php index b82749505..f2a797eb9 100644 --- a/tests/Germany/BadenWurttemberg/CorpusChristiTest.php +++ b/tests/Germany/BadenWurttemberg/CorpusChristiTest.php @@ -14,7 +14,6 @@ namespace Yasumi\tests\Germany\BadenWurttemberg; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -31,7 +30,7 @@ class CorpusChristiTest extends BadenWurttembergBaseTestCase implements HolidayT /** * Tests the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHoliday(): void { @@ -48,7 +47,7 @@ public function testHoliday(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -63,7 +62,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Germany/BadenWurttemberg/EpiphanyTest.php b/tests/Germany/BadenWurttemberg/EpiphanyTest.php index f91873b30..1793e204b 100644 --- a/tests/Germany/BadenWurttemberg/EpiphanyTest.php +++ b/tests/Germany/BadenWurttemberg/EpiphanyTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\Germany\BadenWurttemberg; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,8 +32,8 @@ class EpiphanyTest extends BadenWurttembergBaseTestCase implements HolidayTestCa * * @dataProvider HolidayDataProvider * - * @param int $year the year for which the holiday defined in this test needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which the holiday defined in this test needs to be tested + * @param \DateTime $expected the expected date */ public function testHoliday(int $year, \DateTimeInterface $expected): void { @@ -47,7 +45,7 @@ public function testHoliday(int $year, \DateTimeInterface $expected): void * * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function HolidayDataProvider(): array { @@ -57,7 +55,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -72,7 +70,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Germany/Bavaria/AllSaintsDayTest.php b/tests/Germany/Bavaria/AllSaintsDayTest.php index 9134ce1be..bab3fdf97 100644 --- a/tests/Germany/Bavaria/AllSaintsDayTest.php +++ b/tests/Germany/Bavaria/AllSaintsDayTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\Germany\Bavaria; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,8 +32,8 @@ class AllSaintsDayTest extends BavariaBaseTestCase implements HolidayTestCase * * @dataProvider HolidayDataProvider * - * @param int $year the year for which the holiday defined in this test needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which the holiday defined in this test needs to be tested + * @param \DateTime $expected the expected date */ public function testHoliday(int $year, \DateTimeInterface $expected): void { @@ -47,7 +45,7 @@ public function testHoliday(int $year, \DateTimeInterface $expected): void * * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function HolidayDataProvider(): array { @@ -57,7 +55,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -72,7 +70,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Germany/Bavaria/BavariaTest.php b/tests/Germany/Bavaria/BavariaTest.php index 08e7069d6..de32705eb 100644 --- a/tests/Germany/Bavaria/BavariaTest.php +++ b/tests/Germany/Bavaria/BavariaTest.php @@ -14,7 +14,6 @@ namespace Yasumi\tests\Germany\Bavaria; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\ProviderTestCase; @@ -96,7 +95,7 @@ public function testOtherHolidays(): void } /** - * @throws ReflectionException + * @throws \ReflectionException * @throws \Exception */ public function testSources(): void diff --git a/tests/Germany/Bavaria/CorpusChristiTest.php b/tests/Germany/Bavaria/CorpusChristiTest.php index bb41077a0..e6e31471c 100644 --- a/tests/Germany/Bavaria/CorpusChristiTest.php +++ b/tests/Germany/Bavaria/CorpusChristiTest.php @@ -14,7 +14,6 @@ namespace Yasumi\tests\Germany\Bavaria; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -31,7 +30,7 @@ class CorpusChristiTest extends BavariaBaseTestCase implements HolidayTestCase /** * Tests the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHoliday(): void { @@ -48,7 +47,7 @@ public function testHoliday(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -63,7 +62,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Germany/Bavaria/EpiphanyTest.php b/tests/Germany/Bavaria/EpiphanyTest.php index bdbecab0a..c3f909c0d 100644 --- a/tests/Germany/Bavaria/EpiphanyTest.php +++ b/tests/Germany/Bavaria/EpiphanyTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\Germany\Bavaria; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,8 +32,8 @@ class EpiphanyTest extends BavariaBaseTestCase implements HolidayTestCase * * @dataProvider HolidayDataProvider * - * @param int $year the year for which the holiday defined in this test needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which the holiday defined in this test needs to be tested + * @param \DateTime $expected the expected date */ public function testHoliday(int $year, \DateTimeInterface $expected): void { @@ -47,7 +45,7 @@ public function testHoliday(int $year, \DateTimeInterface $expected): void * * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function HolidayDataProvider(): array { @@ -57,7 +55,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -72,7 +70,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Germany/Berlin/BerlinTest.php b/tests/Germany/Berlin/BerlinTest.php index 63cfd5473..dce900f3d 100644 --- a/tests/Germany/Berlin/BerlinTest.php +++ b/tests/Germany/Berlin/BerlinTest.php @@ -14,7 +14,6 @@ namespace Yasumi\tests\Germany\Berlin; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\ProviderTestCase; @@ -89,7 +88,7 @@ public function testOtherHolidays(): void } /** - * @throws ReflectionException + * @throws \ReflectionException * @throws \Exception */ public function testSources(): void diff --git a/tests/Germany/Berlin/DayOfLiberation2020Test.php b/tests/Germany/Berlin/DayOfLiberation2020Test.php index ca001dccc..d409b1959 100644 --- a/tests/Germany/Berlin/DayOfLiberation2020Test.php +++ b/tests/Germany/Berlin/DayOfLiberation2020Test.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Germany\Berlin; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -38,7 +35,7 @@ class DayOfLiberation2020Test extends BerlinBaseTestCase implements HolidayTestC /** * Test the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayInYear(): void { @@ -46,14 +43,14 @@ public function testHolidayInYear(): void self::REGION, self::HOLIDAY, self::YEAR, - new DateTime(self::YEAR.'-05-08', new DateTimeZone(self::TIMEZONE)) + new \DateTime(self::YEAR.'-05-08', new \DateTimeZone(self::TIMEZONE)) ); } /** * Test the holiday defined in this test in the years before. * - * @throws Exception + * @throws \Exception */ public function testHolidayBeforeYear(): void { @@ -67,7 +64,7 @@ public function testHolidayBeforeYear(): void /** * Test the holiday defined in this test in the years after. * - * @throws Exception + * @throws \Exception */ public function testHolidayAfterYear(): void { diff --git a/tests/Germany/Berlin/InternationalWomensDay2019Test.php b/tests/Germany/Berlin/InternationalWomensDay2019Test.php index 7b90c41b0..c2d08f558 100644 --- a/tests/Germany/Berlin/InternationalWomensDay2019Test.php +++ b/tests/Germany/Berlin/InternationalWomensDay2019Test.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Germany\Berlin; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -38,7 +35,7 @@ class InternationalWomensDay2019Test extends BerlinBaseTestCase implements Holid /** * Test the holiday defined in this test upon establishment. * - * @throws Exception + * @throws \Exception */ public function testHolidayOnEstablishment(): void { @@ -46,14 +43,14 @@ public function testHolidayOnEstablishment(): void self::REGION, self::HOLIDAY, self::ESTABLISHMENT_YEAR, - new DateTime(self::ESTABLISHMENT_YEAR.'-03-08', new DateTimeZone(self::TIMEZONE)) + new \DateTime(self::ESTABLISHMENT_YEAR.'-03-08', new \DateTimeZone(self::TIMEZONE)) ); } /** * Test the holiday defined in this test before establishment. * - * @throws Exception + * @throws \Exception */ public function testHolidayBeforeEstablishment(): void { @@ -67,7 +64,7 @@ public function testHolidayBeforeEstablishment(): void /** * Test the holiday defined in this test after completion. * - * @throws Exception + * @throws \Exception */ public function testHolidayAfterCompletion(): void { @@ -77,7 +74,7 @@ public function testHolidayAfterCompletion(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -92,7 +89,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Germany/Brandenburg/BrandenburgTest.php b/tests/Germany/Brandenburg/BrandenburgTest.php index 080281e13..de3408bf4 100644 --- a/tests/Germany/Brandenburg/BrandenburgTest.php +++ b/tests/Germany/Brandenburg/BrandenburgTest.php @@ -14,7 +14,6 @@ namespace Yasumi\tests\Germany\Brandenburg; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\ProviderTestCase; @@ -100,7 +99,7 @@ public function testOtherHolidays(): void } /** - * @throws ReflectionException + * @throws \ReflectionException * @throws \Exception */ public function testSources(): void diff --git a/tests/Germany/Brandenburg/ReformationDayTest.php b/tests/Germany/Brandenburg/ReformationDayTest.php index e1458c633..bdc380def 100644 --- a/tests/Germany/Brandenburg/ReformationDayTest.php +++ b/tests/Germany/Brandenburg/ReformationDayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Germany\Brandenburg; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -40,8 +37,8 @@ class ReformationDayTest extends BrandenburgBaseTestCase implements HolidayTestC * * @dataProvider HolidayDataProvider * - * @param int $year the year for which the holiday defined in this test needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which the holiday defined in this test needs to be tested + * @param \DateTime $expected the expected date */ public function testHoliday(int $year, \DateTimeInterface $expected): void { @@ -53,7 +50,7 @@ public function testHoliday(int $year, \DateTimeInterface $expected): void * * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function HolidayDataProvider(): array { @@ -61,7 +58,7 @@ public function HolidayDataProvider(): array for ($y = 0; $y < self::TEST_ITERATIONS; ++$y) { $year = $this->generateRandomYear(self::ESTABLISHMENT_YEAR); - $data[] = [$year, new DateTime("$year-10-31", new DateTimeZone(self::TIMEZONE))]; + $data[] = [$year, new \DateTime("$year-10-31", new \DateTimeZone(self::TIMEZONE))]; } return $data; @@ -70,7 +67,7 @@ public function HolidayDataProvider(): array /** * Tests the holiday defined in this test before establishment. * - * @throws Exception + * @throws \Exception */ public function testHolidayBeforeEstablishment(): void { @@ -84,7 +81,7 @@ public function testHolidayBeforeEstablishment(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -99,7 +96,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Germany/Bremen/BremenTest.php b/tests/Germany/Bremen/BremenTest.php index e5f3472b9..f1c08a48a 100644 --- a/tests/Germany/Bremen/BremenTest.php +++ b/tests/Germany/Bremen/BremenTest.php @@ -14,7 +14,6 @@ namespace Yasumi\tests\Germany\Bremen; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\ProviderTestCase; @@ -89,7 +88,7 @@ public function testOtherHolidays(): void } /** - * @throws ReflectionException + * @throws \ReflectionException * @throws \Exception */ public function testSources(): void diff --git a/tests/Germany/Bremen/ReformationDayTest.php b/tests/Germany/Bremen/ReformationDayTest.php index 5a3168940..9e719274f 100644 --- a/tests/Germany/Bremen/ReformationDayTest.php +++ b/tests/Germany/Bremen/ReformationDayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Germany\Bremen; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -40,8 +37,8 @@ class ReformationDayTest extends BremenBaseTestCase implements HolidayTestCase * * @dataProvider HolidayDataProvider * - * @param int $year the year for which the holiday defined in this test needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which the holiday defined in this test needs to be tested + * @param \DateTime $expected the expected date */ public function testHoliday(int $year, \DateTimeInterface $expected): void { @@ -53,7 +50,7 @@ public function testHoliday(int $year, \DateTimeInterface $expected): void * * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function HolidayDataProvider(): array { @@ -61,7 +58,7 @@ public function HolidayDataProvider(): array for ($y = 0; $y < self::TEST_ITERATIONS; ++$y) { $year = $this->generateRandomYear(self::ESTABLISHMENT_YEAR); - $data[] = [$year, new DateTime("$year-10-31", new DateTimeZone(self::TIMEZONE))]; + $data[] = [$year, new \DateTime("$year-10-31", new \DateTimeZone(self::TIMEZONE))]; } return $data; @@ -70,7 +67,7 @@ public function HolidayDataProvider(): array /** * Tests the holiday defined in this test before establishment. * - * @throws Exception + * @throws \Exception */ public function testHolidayBeforeEstablishment(): void { @@ -84,7 +81,7 @@ public function testHolidayBeforeEstablishment(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -99,7 +96,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Germany/ChristmasTest.php b/tests/Germany/ChristmasTest.php index 6ffcb2651..25310deef 100644 --- a/tests/Germany/ChristmasTest.php +++ b/tests/Germany/ChristmasTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\Germany; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,8 +32,8 @@ class ChristmasTest extends GermanyBaseTestCase implements HolidayTestCase * * @dataProvider HolidayDataProvider * - * @param int $year the year for which Christmas Day needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which Christmas Day needs to be tested + * @param \DateTime $expected the expected date */ public function testChristmasDay(int $year, \DateTimeInterface $expected): void { @@ -47,7 +45,7 @@ public function testChristmasDay(int $year, \DateTimeInterface $expected): void * * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function HolidayDataProvider(): array { @@ -57,7 +55,7 @@ public function HolidayDataProvider(): array /** * Tests translated name of Christmas Day. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -72,7 +70,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Germany/EasterMondayTest.php b/tests/Germany/EasterMondayTest.php index 4bbe6c792..58d03d8e9 100644 --- a/tests/Germany/EasterMondayTest.php +++ b/tests/Germany/EasterMondayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Germany; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -33,7 +30,7 @@ class EasterMondayTest extends GermanyBaseTestCase implements HolidayTestCase /** * Tests the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHoliday(): void { @@ -42,14 +39,14 @@ public function testHoliday(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-4-24", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-4-24", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -64,7 +61,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Germany/GermanUnityDayTest.php b/tests/Germany/GermanUnityDayTest.php index 1dcae3c36..4c1aafe9a 100644 --- a/tests/Germany/GermanUnityDayTest.php +++ b/tests/Germany/GermanUnityDayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Germany; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -38,7 +35,7 @@ class GermanUnityDayTest extends GermanyBaseTestCase implements HolidayTestCase /** * Tests the holiday defined in this test on or after establishment. * - * @throws Exception + * @throws \Exception */ public function testHolidayOnAfterEstablishment(): void { @@ -47,14 +44,14 @@ public function testHolidayOnAfterEstablishment(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-10-3", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-10-3", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests the holiday defined in this test before establishment. * - * @throws Exception + * @throws \Exception */ public function testHolidayBeforeEstablishment(): void { @@ -68,7 +65,7 @@ public function testHolidayBeforeEstablishment(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -83,7 +80,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Germany/GermanyTest.php b/tests/Germany/GermanyTest.php index ce8cc9c1c..f48bf2886 100644 --- a/tests/Germany/GermanyTest.php +++ b/tests/Germany/GermanyTest.php @@ -14,7 +14,6 @@ namespace Yasumi\tests\Germany; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\ProviderTestCase; @@ -89,7 +88,7 @@ public function testOtherHolidays(): void } /** - * @throws ReflectionException + * @throws \ReflectionException * @throws \Exception */ public function testSources(): void diff --git a/tests/Germany/GoodFridayTest.php b/tests/Germany/GoodFridayTest.php index f4c2486ac..b3cf061fd 100644 --- a/tests/Germany/GoodFridayTest.php +++ b/tests/Germany/GoodFridayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Germany; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -33,7 +30,7 @@ class GoodFridayTest extends GermanyBaseTestCase implements HolidayTestCase /** * Tests Good Friday. * - * @throws Exception + * @throws \Exception */ public function testGoodFriday(): void { @@ -42,14 +39,14 @@ public function testGoodFriday(): void self::REGION, 'goodFriday', $year, - new DateTime("$year-4-14", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-4-14", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -64,7 +61,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Germany/Hamburg/DayOfReformationTest.php b/tests/Germany/Hamburg/DayOfReformationTest.php index 0dc54bd27..fd9b08c18 100644 --- a/tests/Germany/Hamburg/DayOfReformationTest.php +++ b/tests/Germany/Hamburg/DayOfReformationTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Germany\Hamburg; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -40,8 +37,8 @@ class DayOfReformationTest extends HamburgBaseTestCase implements HolidayTestCas * * @dataProvider HolidayDataProvider * - * @param int $year the year for which the holiday defined in this test needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which the holiday defined in this test needs to be tested + * @param \DateTime $expected the expected date */ public function testHoliday(int $year, \DateTimeInterface $expected): void { @@ -53,7 +50,7 @@ public function testHoliday(int $year, \DateTimeInterface $expected): void * * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function HolidayDataProvider(): array { @@ -61,7 +58,7 @@ public function HolidayDataProvider(): array for ($y = 0; $y < self::TEST_ITERATIONS; ++$y) { $year = $this->generateRandomYear(self::ESTABLISHMENT_YEAR); - $data[] = [$year, new DateTime("$year-10-31", new DateTimeZone(self::TIMEZONE))]; + $data[] = [$year, new \DateTime("$year-10-31", new \DateTimeZone(self::TIMEZONE))]; } return $data; @@ -70,7 +67,7 @@ public function HolidayDataProvider(): array /** * Tests the holiday defined in this test before establishment. * - * @throws Exception + * @throws \Exception */ public function testHolidayBeforeEstablishment(): void { @@ -84,7 +81,7 @@ public function testHolidayBeforeEstablishment(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -99,7 +96,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Germany/Hamburg/HamburgTest.php b/tests/Germany/Hamburg/HamburgTest.php index eceee6d43..eaabf9a83 100644 --- a/tests/Germany/Hamburg/HamburgTest.php +++ b/tests/Germany/Hamburg/HamburgTest.php @@ -14,7 +14,6 @@ namespace Yasumi\tests\Germany\Hamburg; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\ProviderTestCase; @@ -89,7 +88,7 @@ public function testOtherHolidays(): void } /** - * @throws ReflectionException + * @throws \ReflectionException * @throws \Exception */ public function testSources(): void diff --git a/tests/Germany/Hesse/CorpusChristiTest.php b/tests/Germany/Hesse/CorpusChristiTest.php index c20838f8f..ed7105812 100644 --- a/tests/Germany/Hesse/CorpusChristiTest.php +++ b/tests/Germany/Hesse/CorpusChristiTest.php @@ -14,7 +14,6 @@ namespace Yasumi\tests\Germany\Hesse; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -31,7 +30,7 @@ class CorpusChristiTest extends HesseBaseTestCase implements HolidayTestCase /** * Tests the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHoliday(): void { @@ -48,7 +47,7 @@ public function testHoliday(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -63,7 +62,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Germany/Hesse/HesseTest.php b/tests/Germany/Hesse/HesseTest.php index 5858f2de9..4fced9447 100644 --- a/tests/Germany/Hesse/HesseTest.php +++ b/tests/Germany/Hesse/HesseTest.php @@ -14,7 +14,6 @@ namespace Yasumi\tests\Germany\Hesse; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\ProviderTestCase; @@ -90,7 +89,7 @@ public function testOtherHolidays(): void } /** - * @throws ReflectionException + * @throws \ReflectionException * @throws \Exception */ public function testSources(): void diff --git a/tests/Germany/InternationalWorkersDayTest.php b/tests/Germany/InternationalWorkersDayTest.php index 40523162c..042825043 100644 --- a/tests/Germany/InternationalWorkersDayTest.php +++ b/tests/Germany/InternationalWorkersDayTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\Germany; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,8 +32,8 @@ class InternationalWorkersDayTest extends GermanyBaseTestCase implements Holiday * * @dataProvider HolidayDataProvider * - * @param int $year the year for which International Workers' Day needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which International Workers' Day needs to be tested + * @param \DateTime $expected the expected date */ public function testHoliday(int $year, \DateTimeInterface $expected): void { @@ -45,7 +43,7 @@ public function testHoliday(int $year, \DateTimeInterface $expected): void /** * Tests translated name of International Workers' Day. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -60,7 +58,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { @@ -72,7 +70,7 @@ public function testHolidayType(): void * * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function HolidayDataProvider(): array { diff --git a/tests/Germany/LowerSaxony/LowerSaxonyTest.php b/tests/Germany/LowerSaxony/LowerSaxonyTest.php index 3ec102887..3bdfd1551 100644 --- a/tests/Germany/LowerSaxony/LowerSaxonyTest.php +++ b/tests/Germany/LowerSaxony/LowerSaxonyTest.php @@ -14,7 +14,6 @@ namespace Yasumi\tests\Germany\LowerSaxony; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\ProviderTestCase; @@ -89,7 +88,7 @@ public function testOtherHolidays(): void } /** - * @throws ReflectionException + * @throws \ReflectionException * @throws \Exception */ public function testSources(): void diff --git a/tests/Germany/LowerSaxony/ReformationDayTest.php b/tests/Germany/LowerSaxony/ReformationDayTest.php index 9d10fffbc..991c552be 100644 --- a/tests/Germany/LowerSaxony/ReformationDayTest.php +++ b/tests/Germany/LowerSaxony/ReformationDayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Germany\LowerSaxony; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -40,8 +37,8 @@ class ReformationDayTest extends LowerSaxonyBaseTestCase implements HolidayTestC * * @dataProvider HolidayDataProvider * - * @param int $year the year for which the holiday defined in this test needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which the holiday defined in this test needs to be tested + * @param \DateTime $expected the expected date */ public function testHoliday(int $year, \DateTimeInterface $expected): void { @@ -53,7 +50,7 @@ public function testHoliday(int $year, \DateTimeInterface $expected): void * * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function HolidayDataProvider(): array { @@ -61,7 +58,7 @@ public function HolidayDataProvider(): array for ($y = 0; $y < self::TEST_ITERATIONS; ++$y) { $year = $this->generateRandomYear(self::ESTABLISHMENT_YEAR); - $data[] = [$year, new DateTime("$year-10-31", new DateTimeZone(self::TIMEZONE))]; + $data[] = [$year, new \DateTime("$year-10-31", new \DateTimeZone(self::TIMEZONE))]; } return $data; @@ -70,7 +67,7 @@ public function HolidayDataProvider(): array /** * Tests the holiday defined in this test before establishment. * - * @throws Exception + * @throws \Exception */ public function testHolidayBeforeEstablishment(): void { @@ -84,7 +81,7 @@ public function testHolidayBeforeEstablishment(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -99,7 +96,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Germany/MecklenburgWesternPomerania/MecklenburgWesternPomeraniaTest.php b/tests/Germany/MecklenburgWesternPomerania/MecklenburgWesternPomeraniaTest.php index 595910468..724635da2 100644 --- a/tests/Germany/MecklenburgWesternPomerania/MecklenburgWesternPomeraniaTest.php +++ b/tests/Germany/MecklenburgWesternPomerania/MecklenburgWesternPomeraniaTest.php @@ -14,7 +14,6 @@ namespace Yasumi\tests\Germany\MecklenburgWesternPomerania; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\ProviderTestCase; @@ -98,7 +97,7 @@ public function testOtherHolidays(): void } /** - * @throws ReflectionException + * @throws \ReflectionException * @throws \Exception */ public function testSources(): void diff --git a/tests/Germany/MecklenburgWesternPomerania/ReformationDayTest.php b/tests/Germany/MecklenburgWesternPomerania/ReformationDayTest.php index ee8de3318..902ac42fc 100644 --- a/tests/Germany/MecklenburgWesternPomerania/ReformationDayTest.php +++ b/tests/Germany/MecklenburgWesternPomerania/ReformationDayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Germany\MecklenburgWesternPomerania; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -40,7 +37,7 @@ class ReformationDayTest extends MecklenburgWesternPomeraniaBaseTestCase impleme * * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function HolidayDataProvider(): array { @@ -48,7 +45,7 @@ public function HolidayDataProvider(): array for ($y = 0; $y < self::TEST_ITERATIONS; ++$y) { $year = $this->generateRandomYear(self::ESTABLISHMENT_YEAR); - $data[] = [$year, new DateTime("$year-10-31", new DateTimeZone(self::TIMEZONE))]; + $data[] = [$year, new \DateTime("$year-10-31", new \DateTimeZone(self::TIMEZONE))]; } return $data; @@ -57,7 +54,7 @@ public function HolidayDataProvider(): array /** * Tests the holiday defined in this test before establishment. * - * @throws Exception + * @throws \Exception */ public function testHolidayBeforeEstablishment(): void { @@ -71,7 +68,7 @@ public function testHolidayBeforeEstablishment(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -86,7 +83,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Germany/NewYearsDayTest.php b/tests/Germany/NewYearsDayTest.php index ba88d480a..83318f015 100644 --- a/tests/Germany/NewYearsDayTest.php +++ b/tests/Germany/NewYearsDayTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\Germany; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,8 +32,8 @@ class NewYearsDayTest extends GermanyBaseTestCase implements HolidayTestCase * * @dataProvider HolidayDataProvider * - * @param int $year the year for which the holiday defined in this test needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which the holiday defined in this test needs to be tested + * @param \DateTime $expected the expected date */ public function testHoliday(int $year, \DateTimeInterface $expected): void { @@ -47,7 +45,7 @@ public function testHoliday(int $year, \DateTimeInterface $expected): void * * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function HolidayDataProvider(): array { @@ -57,7 +55,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -72,7 +70,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Germany/NewYearsEveTest.php b/tests/Germany/NewYearsEveTest.php index 3e49390b3..dd5271fa3 100644 --- a/tests/Germany/NewYearsEveTest.php +++ b/tests/Germany/NewYearsEveTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\Germany; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,8 +32,8 @@ class NewYearsEveTest extends GermanyBaseTestCase implements HolidayTestCase * * @dataProvider HolidayDataProvider * - * @param int $year the year for which the holiday defined in this test needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which the holiday defined in this test needs to be tested + * @param \DateTime $expected the expected date */ public function testHoliday(int $year, \DateTimeInterface $expected): void { @@ -47,7 +45,7 @@ public function testHoliday(int $year, \DateTimeInterface $expected): void * * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function HolidayDataProvider(): array { @@ -57,7 +55,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -72,7 +70,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Germany/NorthRhineWestphalia/AllSaintsDayTest.php b/tests/Germany/NorthRhineWestphalia/AllSaintsDayTest.php index 0e3f54dd1..b024539f6 100644 --- a/tests/Germany/NorthRhineWestphalia/AllSaintsDayTest.php +++ b/tests/Germany/NorthRhineWestphalia/AllSaintsDayTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\Germany\NorthRhineWestphalia; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,8 +32,8 @@ class AllSaintsDayTest extends NorthRhineWestphaliaBaseTestCase implements Holid * * @dataProvider HolidayDataProvider * - * @param int $year the year for which the holiday defined in this test needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which the holiday defined in this test needs to be tested + * @param \DateTime $expected the expected date */ public function testHoliday(int $year, \DateTimeInterface $expected): void { @@ -47,7 +45,7 @@ public function testHoliday(int $year, \DateTimeInterface $expected): void * * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function HolidayDataProvider(): array { @@ -57,7 +55,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -72,7 +70,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Germany/NorthRhineWestphalia/CorpusChristiTest.php b/tests/Germany/NorthRhineWestphalia/CorpusChristiTest.php index dc116b24f..f71e106fc 100644 --- a/tests/Germany/NorthRhineWestphalia/CorpusChristiTest.php +++ b/tests/Germany/NorthRhineWestphalia/CorpusChristiTest.php @@ -14,7 +14,6 @@ namespace Yasumi\tests\Germany\NorthRhineWestphalia; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -31,7 +30,7 @@ class CorpusChristiTest extends NorthRhineWestphaliaBaseTestCase implements Holi /** * Tests the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHoliday(): void { @@ -48,7 +47,7 @@ public function testHoliday(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -63,7 +62,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Germany/NorthRhineWestphalia/NorthRhineWestphaliaTest.php b/tests/Germany/NorthRhineWestphalia/NorthRhineWestphaliaTest.php index fee44f16a..4b87d0cc0 100644 --- a/tests/Germany/NorthRhineWestphalia/NorthRhineWestphaliaTest.php +++ b/tests/Germany/NorthRhineWestphalia/NorthRhineWestphaliaTest.php @@ -14,7 +14,6 @@ namespace Yasumi\tests\Germany\NorthRhineWestphalia; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\ProviderTestCase; @@ -91,7 +90,7 @@ public function testOtherHolidays(): void } /** - * @throws ReflectionException + * @throws \ReflectionException * @throws \Exception */ public function testSources(): void diff --git a/tests/Germany/PentecostMondayTest.php b/tests/Germany/PentecostMondayTest.php index 09b48b042..443ac158c 100644 --- a/tests/Germany/PentecostMondayTest.php +++ b/tests/Germany/PentecostMondayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Germany; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -33,7 +30,7 @@ class PentecostMondayTest extends GermanyBaseTestCase implements HolidayTestCase /** * Tests the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHoliday(): void { @@ -42,14 +39,14 @@ public function testHoliday(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-6-10", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-6-10", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -64,7 +61,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Germany/PentecostTest.php b/tests/Germany/PentecostTest.php index 1f87a4c02..2098498f6 100644 --- a/tests/Germany/PentecostTest.php +++ b/tests/Germany/PentecostTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Germany; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -33,7 +30,7 @@ class PentecostTest extends GermanyBaseTestCase implements HolidayTestCase /** * Tests the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHoliday(): void { @@ -47,14 +44,14 @@ public function testHoliday(): void self::REGION, self::HOLIDAY, $year, - new DateTime($date, new DateTimeZone(self::TIMEZONE)) + new \DateTime($date, new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -69,7 +66,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Germany/ReformationDay2017Test.php b/tests/Germany/ReformationDay2017Test.php index 4c6b9f1cd..798af37d0 100644 --- a/tests/Germany/ReformationDay2017Test.php +++ b/tests/Germany/ReformationDay2017Test.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Germany; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -38,7 +35,7 @@ class ReformationDay2017Test extends GermanyBaseTestCase implements HolidayTestC /** * Test the holiday defined in this test upon establishment. * - * @throws Exception + * @throws \Exception */ public function testHolidayOnEstablishment(): void { @@ -46,14 +43,14 @@ public function testHolidayOnEstablishment(): void self::REGION, self::HOLIDAY, self::ESTABLISHMENT_YEAR, - new DateTime(self::ESTABLISHMENT_YEAR.'-10-31', new DateTimeZone(self::TIMEZONE)) + new \DateTime(self::ESTABLISHMENT_YEAR.'-10-31', new \DateTimeZone(self::TIMEZONE)) ); } /** * Test the holiday defined in this test before establishment. * - * @throws Exception + * @throws \Exception */ public function testHolidayBeforeEstablishment(): void { @@ -67,7 +64,7 @@ public function testHolidayBeforeEstablishment(): void /** * Test the holiday defined in this test after completion. * - * @throws Exception + * @throws \Exception */ public function testHolidayAfterCompletion(): void { @@ -77,7 +74,7 @@ public function testHolidayAfterCompletion(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -92,7 +89,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Germany/RhinelandPalatinate/AllSaintsDayTest.php b/tests/Germany/RhinelandPalatinate/AllSaintsDayTest.php index a0ced8577..1ef668c13 100644 --- a/tests/Germany/RhinelandPalatinate/AllSaintsDayTest.php +++ b/tests/Germany/RhinelandPalatinate/AllSaintsDayTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\Germany\RhinelandPalatinate; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,8 +32,8 @@ class AllSaintsDayTest extends RhinelandPalatinateBaseTestCase implements Holida * * @dataProvider HolidayDataProvider * - * @param int $year the year for which the holiday defined in this test needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which the holiday defined in this test needs to be tested + * @param \DateTime $expected the expected date */ public function testHoliday(int $year, \DateTimeInterface $expected): void { @@ -47,7 +45,7 @@ public function testHoliday(int $year, \DateTimeInterface $expected): void * * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function HolidayDataProvider(): array { @@ -57,7 +55,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -72,7 +70,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Germany/RhinelandPalatinate/CorpusChristiTest.php b/tests/Germany/RhinelandPalatinate/CorpusChristiTest.php index 1dc96c1d7..79e727b04 100644 --- a/tests/Germany/RhinelandPalatinate/CorpusChristiTest.php +++ b/tests/Germany/RhinelandPalatinate/CorpusChristiTest.php @@ -14,7 +14,6 @@ namespace Yasumi\tests\Germany\RhinelandPalatinate; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -31,7 +30,7 @@ class CorpusChristiTest extends RhinelandPalatinateBaseTestCase implements Holid /** * Tests the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHoliday(): void { @@ -48,7 +47,7 @@ public function testHoliday(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -63,7 +62,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Germany/RhinelandPalatinate/RhinelandPalatinateTest.php b/tests/Germany/RhinelandPalatinate/RhinelandPalatinateTest.php index cdc672098..599f91ba7 100644 --- a/tests/Germany/RhinelandPalatinate/RhinelandPalatinateTest.php +++ b/tests/Germany/RhinelandPalatinate/RhinelandPalatinateTest.php @@ -14,7 +14,6 @@ namespace Yasumi\tests\Germany\RhinelandPalatinate; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\ProviderTestCase; @@ -91,7 +90,7 @@ public function testOtherHolidays(): void } /** - * @throws ReflectionException + * @throws \ReflectionException * @throws \Exception */ public function testSources(): void diff --git a/tests/Germany/Saarland/AllSaintsDayTest.php b/tests/Germany/Saarland/AllSaintsDayTest.php index 5f2d8af18..af659c8d9 100644 --- a/tests/Germany/Saarland/AllSaintsDayTest.php +++ b/tests/Germany/Saarland/AllSaintsDayTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\Germany\Saarland; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,8 +32,8 @@ class AllSaintsDayTest extends SaarlandBaseTestCase implements HolidayTestCase * * @dataProvider HolidayDataProvider * - * @param int $year the year for which the holiday defined in this test needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which the holiday defined in this test needs to be tested + * @param \DateTime $expected the expected date */ public function testHoliday(int $year, \DateTimeInterface $expected): void { @@ -47,7 +45,7 @@ public function testHoliday(int $year, \DateTimeInterface $expected): void * * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function HolidayDataProvider(): array { @@ -57,7 +55,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -72,7 +70,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Germany/Saarland/AssumptionOfMaryTest.php b/tests/Germany/Saarland/AssumptionOfMaryTest.php index 572051290..473d5324e 100644 --- a/tests/Germany/Saarland/AssumptionOfMaryTest.php +++ b/tests/Germany/Saarland/AssumptionOfMaryTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\Germany\Saarland; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,8 +32,8 @@ class AssumptionOfMaryTest extends SaarlandBaseTestCase implements HolidayTestCa * * @dataProvider HolidayDataProvider * - * @param int $year the year for which the holiday defined in this test needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which the holiday defined in this test needs to be tested + * @param \DateTime $expected the expected date */ public function testHoliday(int $year, \DateTimeInterface $expected): void { @@ -47,7 +45,7 @@ public function testHoliday(int $year, \DateTimeInterface $expected): void * * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function HolidayDataProvider(): array { @@ -57,7 +55,7 @@ public function HolidayDataProvider(): array /** * Tests translated name of the Assumption of Mary. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -72,7 +70,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Germany/Saarland/CorpusChristiTest.php b/tests/Germany/Saarland/CorpusChristiTest.php index 231347ab7..f8e0867a1 100644 --- a/tests/Germany/Saarland/CorpusChristiTest.php +++ b/tests/Germany/Saarland/CorpusChristiTest.php @@ -14,7 +14,6 @@ namespace Yasumi\tests\Germany\Saarland; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -31,7 +30,7 @@ class CorpusChristiTest extends SaarlandBaseTestCase implements HolidayTestCase /** * Tests the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHoliday(): void { @@ -48,7 +47,7 @@ public function testHoliday(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -63,7 +62,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Germany/Saarland/SaarlandTest.php b/tests/Germany/Saarland/SaarlandTest.php index 988c317b5..984f263c7 100644 --- a/tests/Germany/Saarland/SaarlandTest.php +++ b/tests/Germany/Saarland/SaarlandTest.php @@ -14,7 +14,6 @@ namespace Yasumi\tests\Germany\Saarland; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\ProviderTestCase; @@ -91,7 +90,7 @@ public function testOtherHolidays(): void } /** - * @throws ReflectionException + * @throws \ReflectionException * @throws \Exception */ public function testSources(): void diff --git a/tests/Germany/Saxony/ReformationDayTest.php b/tests/Germany/Saxony/ReformationDayTest.php index c137d5a49..6144797f3 100644 --- a/tests/Germany/Saxony/ReformationDayTest.php +++ b/tests/Germany/Saxony/ReformationDayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Germany\Saxony; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -40,8 +37,8 @@ class ReformationDayTest extends SaxonyBaseTestCase implements HolidayTestCase * * @dataProvider HolidayDataProvider * - * @param int $year the year for which the holiday defined in this test needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which the holiday defined in this test needs to be tested + * @param \DateTime $expected the expected date */ public function testHoliday(int $year, \DateTimeInterface $expected): void { @@ -53,7 +50,7 @@ public function testHoliday(int $year, \DateTimeInterface $expected): void * * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function HolidayDataProvider(): array { @@ -61,7 +58,7 @@ public function HolidayDataProvider(): array for ($y = 0; $y < self::TEST_ITERATIONS; ++$y) { $year = $this->generateRandomYear(self::ESTABLISHMENT_YEAR); - $data[] = [$year, new DateTime("$year-10-31", new DateTimeZone(self::TIMEZONE))]; + $data[] = [$year, new \DateTime("$year-10-31", new \DateTimeZone(self::TIMEZONE))]; } return $data; @@ -70,7 +67,7 @@ public function HolidayDataProvider(): array /** * Tests the holiday defined in this test before establishment. * - * @throws Exception + * @throws \Exception */ public function testHolidayBeforeEstablishment(): void { @@ -84,7 +81,7 @@ public function testHolidayBeforeEstablishment(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -99,7 +96,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Germany/Saxony/RepentanceAndPrayerDayTest.php b/tests/Germany/Saxony/RepentanceAndPrayerDayTest.php index 100724347..1561aaa9f 100644 --- a/tests/Germany/Saxony/RepentanceAndPrayerDayTest.php +++ b/tests/Germany/Saxony/RepentanceAndPrayerDayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Germany\Saxony; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -43,13 +40,13 @@ class RepentanceAndPrayerDayTest extends SaxonyBaseTestCase implements HolidayTe /** * Tests the holiday defined in this test on or after establishment. * - * @throws Exception + * @throws \Exception */ public function testHolidayOnAfterEstablishment(): void { // Check between the 16th and 22nd day the one that is a Wednesday $year = $this->generateRandomYear(self::ESTABLISHMENT_YEAR); - $holiday = new DateTime("next wednesday $year-11-15", new DateTimeZone(self::TIMEZONE)); // Default date + $holiday = new \DateTime("next wednesday $year-11-15", new \DateTimeZone(self::TIMEZONE)); // Default date $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $holiday); @@ -62,7 +59,7 @@ public function testHolidayOnAfterEstablishment(): void /** * Tests the holiday defined in this test before establishment. * - * @throws Exception + * @throws \Exception */ public function testHolidayBeforeEstablishment(): void { @@ -76,7 +73,7 @@ public function testHolidayBeforeEstablishment(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -91,7 +88,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Germany/Saxony/SaxonyTest.php b/tests/Germany/Saxony/SaxonyTest.php index 53e3741a2..b1e40ee5e 100644 --- a/tests/Germany/Saxony/SaxonyTest.php +++ b/tests/Germany/Saxony/SaxonyTest.php @@ -14,7 +14,6 @@ namespace Yasumi\tests\Germany\Saxony; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\ProviderTestCase; @@ -102,7 +101,7 @@ public function testOtherHolidays(): void } /** - * @throws ReflectionException + * @throws \ReflectionException * @throws \Exception */ public function testSources(): void diff --git a/tests/Germany/SaxonyAnhalt/EpiphanyTest.php b/tests/Germany/SaxonyAnhalt/EpiphanyTest.php index adab06704..5af23f22a 100644 --- a/tests/Germany/SaxonyAnhalt/EpiphanyTest.php +++ b/tests/Germany/SaxonyAnhalt/EpiphanyTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\Germany\SaxonyAnhalt; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,8 +32,8 @@ class EpiphanyTest extends SaxonyAnhaltBaseTestCase implements HolidayTestCase * * @dataProvider HolidayDataProvider * - * @param int $year the year for which the holiday defined in this test needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which the holiday defined in this test needs to be tested + * @param \DateTime $expected the expected date */ public function testHoliday(int $year, \DateTimeInterface $expected): void { @@ -47,7 +45,7 @@ public function testHoliday(int $year, \DateTimeInterface $expected): void * * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function HolidayDataProvider(): array { @@ -57,7 +55,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -72,7 +70,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Germany/SaxonyAnhalt/ReformationDayTest.php b/tests/Germany/SaxonyAnhalt/ReformationDayTest.php index f06249426..bb80a9373 100644 --- a/tests/Germany/SaxonyAnhalt/ReformationDayTest.php +++ b/tests/Germany/SaxonyAnhalt/ReformationDayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Germany\SaxonyAnhalt; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -40,8 +37,8 @@ class ReformationDayTest extends SaxonyAnhaltBaseTestCase implements HolidayTest * * @dataProvider HolidayDataProvider * - * @param int $year the year for which the holiday defined in this test needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which the holiday defined in this test needs to be tested + * @param \DateTime $expected the expected date */ public function testHoliday(int $year, \DateTimeInterface $expected): void { @@ -53,7 +50,7 @@ public function testHoliday(int $year, \DateTimeInterface $expected): void * * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function HolidayDataProvider(): array { @@ -61,7 +58,7 @@ public function HolidayDataProvider(): array for ($y = 0; $y < self::TEST_ITERATIONS; ++$y) { $year = $this->generateRandomYear(self::ESTABLISHMENT_YEAR); - $data[] = [$year, new DateTime("$year-10-31", new DateTimeZone(self::TIMEZONE))]; + $data[] = [$year, new \DateTime("$year-10-31", new \DateTimeZone(self::TIMEZONE))]; } return $data; @@ -70,7 +67,7 @@ public function HolidayDataProvider(): array /** * Tests the holiday defined in this test before establishment. * - * @throws Exception + * @throws \Exception */ public function testHolidayBeforeEstablishment(): void { @@ -84,7 +81,7 @@ public function testHolidayBeforeEstablishment(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -99,7 +96,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Germany/SaxonyAnhalt/SaxonyAnhaltTest.php b/tests/Germany/SaxonyAnhalt/SaxonyAnhaltTest.php index 1b3f5949e..0662f0272 100644 --- a/tests/Germany/SaxonyAnhalt/SaxonyAnhaltTest.php +++ b/tests/Germany/SaxonyAnhalt/SaxonyAnhaltTest.php @@ -14,7 +14,6 @@ namespace Yasumi\tests\Germany\SaxonyAnhalt; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\ProviderTestCase; @@ -98,7 +97,7 @@ public function testOtherHolidays(): void } /** - * @throws ReflectionException + * @throws \ReflectionException * @throws \Exception */ public function testSources(): void diff --git a/tests/Germany/SchleswigHolstein/ReformationDayTest.php b/tests/Germany/SchleswigHolstein/ReformationDayTest.php index 16de48d67..3e8e644d0 100644 --- a/tests/Germany/SchleswigHolstein/ReformationDayTest.php +++ b/tests/Germany/SchleswigHolstein/ReformationDayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Germany\SchleswigHolstein; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -40,8 +37,8 @@ class ReformationDayTest extends SchleswigHolsteinBaseTestCase implements Holida * * @dataProvider HolidayDataProvider * - * @param int $year the year for which the holiday defined in this test needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which the holiday defined in this test needs to be tested + * @param \DateTime $expected the expected date */ public function testHoliday(int $year, \DateTimeInterface $expected): void { @@ -53,7 +50,7 @@ public function testHoliday(int $year, \DateTimeInterface $expected): void * * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function HolidayDataProvider(): array { @@ -61,7 +58,7 @@ public function HolidayDataProvider(): array for ($y = 0; $y < self::TEST_ITERATIONS; ++$y) { $year = $this->generateRandomYear(self::ESTABLISHMENT_YEAR); - $data[] = [$year, new DateTime("$year-10-31", new DateTimeZone(self::TIMEZONE))]; + $data[] = [$year, new \DateTime("$year-10-31", new \DateTimeZone(self::TIMEZONE))]; } return $data; @@ -70,7 +67,7 @@ public function HolidayDataProvider(): array /** * Tests the holiday defined in this test before establishment. * - * @throws Exception + * @throws \Exception */ public function testHolidayBeforeEstablishment(): void { @@ -84,7 +81,7 @@ public function testHolidayBeforeEstablishment(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -99,7 +96,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Germany/SchleswigHolstein/SchleswigHolsteinTest.php b/tests/Germany/SchleswigHolstein/SchleswigHolsteinTest.php index 9ccc65097..292ca71f0 100644 --- a/tests/Germany/SchleswigHolstein/SchleswigHolsteinTest.php +++ b/tests/Germany/SchleswigHolstein/SchleswigHolsteinTest.php @@ -14,7 +14,6 @@ namespace Yasumi\tests\Germany\SchleswigHolstein; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\ProviderTestCase; @@ -89,7 +88,7 @@ public function testOtherHolidays(): void } /** - * @throws ReflectionException + * @throws \ReflectionException * @throws \Exception */ public function testSources(): void diff --git a/tests/Germany/SecondChristmasDayTest.php b/tests/Germany/SecondChristmasDayTest.php index a7cacc5f6..9648c59af 100644 --- a/tests/Germany/SecondChristmasDayTest.php +++ b/tests/Germany/SecondChristmasDayTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\Germany; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,8 +32,8 @@ class SecondChristmasDayTest extends GermanyBaseTestCase implements HolidayTestC * * @dataProvider HolidayDataProvider * - * @param int $year the year for which the holiday defined in this test needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which the holiday defined in this test needs to be tested + * @param \DateTime $expected the expected date */ public function testHoliday(int $year, \DateTimeInterface $expected): void { @@ -47,7 +45,7 @@ public function testHoliday(int $year, \DateTimeInterface $expected): void * * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function HolidayDataProvider(): array { @@ -57,7 +55,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -72,7 +70,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Germany/Thuringia/ReformationDayTest.php b/tests/Germany/Thuringia/ReformationDayTest.php index 80e017d60..852938824 100644 --- a/tests/Germany/Thuringia/ReformationDayTest.php +++ b/tests/Germany/Thuringia/ReformationDayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Germany\Thuringia; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -40,8 +37,8 @@ class ReformationDayTest extends ThuringiaBaseTestCase implements HolidayTestCas * * @dataProvider HolidayDataProvider * - * @param int $year the year for which the holiday defined in this test needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which the holiday defined in this test needs to be tested + * @param \DateTime $expected the expected date */ public function testHoliday(int $year, \DateTimeInterface $expected): void { @@ -53,7 +50,7 @@ public function testHoliday(int $year, \DateTimeInterface $expected): void * * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function HolidayDataProvider(): array { @@ -61,7 +58,7 @@ public function HolidayDataProvider(): array for ($y = 0; $y < self::TEST_ITERATIONS; ++$y) { $year = $this->generateRandomYear(self::ESTABLISHMENT_YEAR); - $data[] = [$year, new DateTime("$year-10-31", new DateTimeZone(self::TIMEZONE))]; + $data[] = [$year, new \DateTime("$year-10-31", new \DateTimeZone(self::TIMEZONE))]; } return $data; @@ -70,7 +67,7 @@ public function HolidayDataProvider(): array /** * Tests the holiday defined in this test before establishment. * - * @throws Exception + * @throws \Exception */ public function testHolidayBeforeEstablishment(): void { @@ -84,7 +81,7 @@ public function testHolidayBeforeEstablishment(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -99,7 +96,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Germany/Thuringia/ThuringiaTest.php b/tests/Germany/Thuringia/ThuringiaTest.php index 49b1b3921..439affa6b 100644 --- a/tests/Germany/Thuringia/ThuringiaTest.php +++ b/tests/Germany/Thuringia/ThuringiaTest.php @@ -14,7 +14,6 @@ namespace Yasumi\tests\Germany\Thuringia; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\ProviderTestCase; @@ -102,7 +101,7 @@ public function testOtherHolidays(): void } /** - * @throws ReflectionException + * @throws \ReflectionException * @throws \Exception */ public function testSources(): void diff --git a/tests/Germany/Thuringia/WorldChildrensDayTest.php b/tests/Germany/Thuringia/WorldChildrensDayTest.php index d8b76dee9..b996792c2 100644 --- a/tests/Germany/Thuringia/WorldChildrensDayTest.php +++ b/tests/Germany/Thuringia/WorldChildrensDayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Germany\Thuringia; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -40,8 +37,8 @@ class WorldChildrensDayTest extends ThuringiaBaseTestCase implements HolidayTest * * @dataProvider HolidayDataProvider * - * @param int $year the year for which the holiday defined in this test needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which the holiday defined in this test needs to be tested + * @param \DateTime $expected the expected date */ public function testHoliday(int $year, \DateTimeInterface $expected): void { @@ -53,7 +50,7 @@ public function testHoliday(int $year, \DateTimeInterface $expected): void * * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function HolidayDataProvider(): array { @@ -61,7 +58,7 @@ public function HolidayDataProvider(): array for ($y = 0; $y < self::TEST_ITERATIONS; ++$y) { $year = $this->generateRandomYear(self::ESTABLISHMENT_YEAR); - $data[] = [$year, new DateTime("$year-09-20", new DateTimeZone(self::TIMEZONE))]; + $data[] = [$year, new \DateTime("$year-09-20", new \DateTimeZone(self::TIMEZONE))]; } return $data; @@ -70,7 +67,7 @@ public function HolidayDataProvider(): array /** * Tests the holiday defined in this test before establishment. * - * @throws Exception + * @throws \Exception */ public function testHolidayBeforeEstablishment(): void { @@ -84,7 +81,7 @@ public function testHolidayBeforeEstablishment(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -99,7 +96,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Greece/AnnunciationTest.php b/tests/Greece/AnnunciationTest.php index cd28e0cb3..ae83ebaea 100644 --- a/tests/Greece/AnnunciationTest.php +++ b/tests/Greece/AnnunciationTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\Greece; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,8 +32,8 @@ class AnnunciationTest extends GreeceBaseTestCase implements HolidayTestCase * * @dataProvider HolidayDataProvider * - * @param int $year the year for which the holiday defined in this test needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which the holiday defined in this test needs to be tested + * @param \DateTime $expected the expected date */ public function testHoliday(int $year, \DateTimeInterface $expected): void { @@ -47,7 +45,7 @@ public function testHoliday(int $year, \DateTimeInterface $expected): void * * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function HolidayDataProvider(): array { @@ -57,7 +55,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -72,7 +70,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Greece/AscensionDayTest.php b/tests/Greece/AscensionDayTest.php index e4ff78766..527226aa5 100644 --- a/tests/Greece/AscensionDayTest.php +++ b/tests/Greece/AscensionDayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Greece; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -33,7 +30,7 @@ class AscensionDayTest extends GreeceBaseTestCase implements HolidayTestCase /** * Tests the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHoliday(): void { @@ -42,14 +39,14 @@ public function testHoliday(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-6-9", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-6-9", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -64,7 +61,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Greece/AssumptionOfMaryTest.php b/tests/Greece/AssumptionOfMaryTest.php index e4cf358d7..db5bfcd45 100644 --- a/tests/Greece/AssumptionOfMaryTest.php +++ b/tests/Greece/AssumptionOfMaryTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\Greece; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,8 +32,8 @@ class AssumptionOfMaryTest extends GreeceBaseTestCase implements HolidayTestCase * * @dataProvider HolidayDataProvider * - * @param int $year the year for which the holiday defined in this test needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which the holiday defined in this test needs to be tested + * @param \DateTime $expected the expected date */ public function testHoliday(int $year, \DateTimeInterface $expected): void { @@ -47,7 +45,7 @@ public function testHoliday(int $year, \DateTimeInterface $expected): void * * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function HolidayDataProvider(): array { @@ -57,7 +55,7 @@ public function HolidayDataProvider(): array /** * Tests translated name of the Assumption of Mary. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -72,7 +70,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Greece/ChristmasDayTest.php b/tests/Greece/ChristmasDayTest.php index 612a2e0cc..ef33e36da 100644 --- a/tests/Greece/ChristmasDayTest.php +++ b/tests/Greece/ChristmasDayTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\Greece; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,8 +32,8 @@ class ChristmasDayTest extends GreeceBaseTestCase implements HolidayTestCase * * @dataProvider HolidayDataProvider * - * @param int $year the year for which the holiday defined in this test needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which the holiday defined in this test needs to be tested + * @param \DateTime $expected the expected date */ public function testHoliday(int $year, \DateTimeInterface $expected): void { @@ -47,7 +45,7 @@ public function testHoliday(int $year, \DateTimeInterface $expected): void * * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function HolidayDataProvider(): array { @@ -57,7 +55,7 @@ public function HolidayDataProvider(): array /** * Tests translated name of Christmas Day. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -72,7 +70,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Greece/CleanMondayTest.php b/tests/Greece/CleanMondayTest.php index c05a66a16..b2e7d32ca 100644 --- a/tests/Greece/CleanMondayTest.php +++ b/tests/Greece/CleanMondayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Greece; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -33,7 +30,7 @@ class CleanMondayTest extends GreeceBaseTestCase implements HolidayTestCase /** * Tests the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHoliday(): void { @@ -42,14 +39,14 @@ public function testHoliday(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-3-14", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-3-14", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -64,7 +61,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Greece/EasterMondayTest.php b/tests/Greece/EasterMondayTest.php index 51c8e28a7..031bef360 100644 --- a/tests/Greece/EasterMondayTest.php +++ b/tests/Greece/EasterMondayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Greece; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -33,7 +30,7 @@ class EasterMondayTest extends GreeceBaseTestCase implements HolidayTestCase /** * Tests the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHoliday(): void { @@ -42,14 +39,14 @@ public function testHoliday(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-5-2", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-5-2", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -64,7 +61,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Greece/EasterTest.php b/tests/Greece/EasterTest.php index 76d80df04..4e222961d 100644 --- a/tests/Greece/EasterTest.php +++ b/tests/Greece/EasterTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Greece; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -33,7 +30,7 @@ class EasterTest extends GreeceBaseTestCase implements HolidayTestCase /** * Tests the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHoliday(): void { @@ -42,14 +39,14 @@ public function testHoliday(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-5-1", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-5-1", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests translated name of Easter. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -64,7 +61,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Greece/EpiphanyTest.php b/tests/Greece/EpiphanyTest.php index 517888148..f17a82fd5 100644 --- a/tests/Greece/EpiphanyTest.php +++ b/tests/Greece/EpiphanyTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\Greece; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,8 +32,8 @@ class EpiphanyTest extends GreeceBaseTestCase implements HolidayTestCase * * @dataProvider HolidayDataProvider * - * @param int $year the year for which the holiday defined in this test needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which the holiday defined in this test needs to be tested + * @param \DateTime $expected the expected date */ public function testHoliday(int $year, \DateTimeInterface $expected): void { @@ -47,7 +45,7 @@ public function testHoliday(int $year, \DateTimeInterface $expected): void * * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function HolidayDataProvider(): array { @@ -57,7 +55,7 @@ public function HolidayDataProvider(): array /** * Tests translated name of Epiphany. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -72,7 +70,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Greece/GreeceTest.php b/tests/Greece/GreeceTest.php index 095a5bf6d..abf19075f 100644 --- a/tests/Greece/GreeceTest.php +++ b/tests/Greece/GreeceTest.php @@ -14,7 +14,6 @@ namespace Yasumi\tests\Greece; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\ProviderTestCase; @@ -100,7 +99,7 @@ public function testOtherHolidays(): void } /** - * @throws ReflectionException + * @throws \ReflectionException * @throws \Exception */ public function testSources(): void diff --git a/tests/Greece/IndepencenceDayTest.php b/tests/Greece/IndepencenceDayTest.php index df94009f1..e1eb41cf2 100644 --- a/tests/Greece/IndepencenceDayTest.php +++ b/tests/Greece/IndepencenceDayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Greece; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -38,7 +35,7 @@ class IndepencenceDayTest extends GreeceBaseTestCase implements HolidayTestCase /** * Tests the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHoliday(): void { @@ -47,14 +44,14 @@ public function testHoliday(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-3-25", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-3-25", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests the holiday defined in this test before establishment. * - * @throws Exception + * @throws \Exception */ public function testHolidayBeforeEstablishment(): void { @@ -68,7 +65,7 @@ public function testHolidayBeforeEstablishment(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -83,7 +80,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Greece/InternationalWorkersDayTest.php b/tests/Greece/InternationalWorkersDayTest.php index d461dfb65..3a1b88b3e 100644 --- a/tests/Greece/InternationalWorkersDayTest.php +++ b/tests/Greece/InternationalWorkersDayTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\Greece; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,8 +32,8 @@ class InternationalWorkersDayTest extends GreeceBaseTestCase implements HolidayT * * @dataProvider HolidayDataProvider * - * @param int $year the year for which the holiday defined in this test needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which the holiday defined in this test needs to be tested + * @param \DateTime $expected the expected date */ public function testHoliday(int $year, \DateTimeInterface $expected): void { @@ -45,7 +43,7 @@ public function testHoliday(int $year, \DateTimeInterface $expected): void /** * Tests translated name of International Workers' Day. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -60,7 +58,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { @@ -72,7 +70,7 @@ public function testHolidayType(): void * * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function HolidayDataProvider(): array { diff --git a/tests/Greece/NewYearsDayTest.php b/tests/Greece/NewYearsDayTest.php index bb3a76cce..85153da4d 100644 --- a/tests/Greece/NewYearsDayTest.php +++ b/tests/Greece/NewYearsDayTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\Greece; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,8 +32,8 @@ class NewYearsDayTest extends GreeceBaseTestCase implements HolidayTestCase * * @dataProvider HolidayDataProvider * - * @param int $year the year for which the holiday defined in this test needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which the holiday defined in this test needs to be tested + * @param \DateTime $expected the expected date */ public function testHoliday(int $year, \DateTimeInterface $expected): void { @@ -45,7 +43,7 @@ public function testHoliday(int $year, \DateTimeInterface $expected): void /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -60,7 +58,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { @@ -72,7 +70,7 @@ public function testHolidayType(): void * * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function HolidayDataProvider(): array { diff --git a/tests/Greece/OhiDayTest.php b/tests/Greece/OhiDayTest.php index 091a8d40b..33de702af 100644 --- a/tests/Greece/OhiDayTest.php +++ b/tests/Greece/OhiDayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Greece; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -38,7 +35,7 @@ class OhiDayTest extends GreeceBaseTestCase implements HolidayTestCase /** * Tests the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHoliday(): void { @@ -47,14 +44,14 @@ public function testHoliday(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-10-28", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-10-28", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests the holiday defined in this test before establishment. * - * @throws Exception + * @throws \Exception */ public function testHolidayBeforeEstablishment(): void { @@ -68,7 +65,7 @@ public function testHolidayBeforeEstablishment(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -83,7 +80,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Greece/PentecostMondayTest.php b/tests/Greece/PentecostMondayTest.php index d74eb66b5..899c9a16b 100644 --- a/tests/Greece/PentecostMondayTest.php +++ b/tests/Greece/PentecostMondayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Greece; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -33,7 +30,7 @@ class PentecostMondayTest extends GreeceBaseTestCase implements HolidayTestCase /** * Tests the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHoliday(): void { @@ -42,14 +39,14 @@ public function testHoliday(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-6-20", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-6-20", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -64,7 +61,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Greece/PentecostTest.php b/tests/Greece/PentecostTest.php index 56081bf19..5e5470eca 100644 --- a/tests/Greece/PentecostTest.php +++ b/tests/Greece/PentecostTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Greece; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -33,7 +30,7 @@ class PentecostTest extends GreeceBaseTestCase implements HolidayTestCase /** * Tests the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHoliday(): void { @@ -42,14 +39,14 @@ public function testHoliday(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-6-19", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-6-19", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -64,7 +61,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Greece/PolytechnioTest.php b/tests/Greece/PolytechnioTest.php index 7c428218a..232ed724f 100644 --- a/tests/Greece/PolytechnioTest.php +++ b/tests/Greece/PolytechnioTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Greece; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -38,7 +35,7 @@ class PolytechnioTest extends GreeceBaseTestCase implements HolidayTestCase /** * Tests the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHoliday(): void { @@ -47,14 +44,14 @@ public function testHoliday(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-11-17", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-11-17", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests the holiday defined in this test before establishment. * - * @throws Exception + * @throws \Exception */ public function testHolidayBeforeEstablishment(): void { @@ -68,7 +65,7 @@ public function testHolidayBeforeEstablishment(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -83,7 +80,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Greece/ThreeHolyHierarchsTest.php b/tests/Greece/ThreeHolyHierarchsTest.php index 1174055c1..610df0bb4 100644 --- a/tests/Greece/ThreeHolyHierarchsTest.php +++ b/tests/Greece/ThreeHolyHierarchsTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\Greece; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,8 +32,8 @@ class ThreeHolyHierarchsTest extends GreeceBaseTestCase implements HolidayTestCa * * @dataProvider HolidayDataProvider * - * @param int $year the year for which the holiday defined in this test needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which the holiday defined in this test needs to be tested + * @param \DateTime $expected the expected date */ public function testHoliday(int $year, \DateTimeInterface $expected): void { @@ -47,7 +45,7 @@ public function testHoliday(int $year, \DateTimeInterface $expected): void * * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function HolidayDataProvider(): array { @@ -57,7 +55,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -72,7 +70,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Greece/goodFridayTest.php b/tests/Greece/goodFridayTest.php index b9f912639..c72bd13d2 100644 --- a/tests/Greece/goodFridayTest.php +++ b/tests/Greece/goodFridayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Greece; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -33,7 +30,7 @@ class goodFridayTest extends GreeceBaseTestCase implements HolidayTestCase /** * Tests the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHoliday(): void { @@ -42,14 +39,14 @@ public function testHoliday(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-4-29", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-4-29", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -64,7 +61,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Hungary/AllSaintsDayTest.php b/tests/Hungary/AllSaintsDayTest.php index 4093e11c8..3fe138f6c 100644 --- a/tests/Hungary/AllSaintsDayTest.php +++ b/tests/Hungary/AllSaintsDayTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\Hungary; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,8 +32,8 @@ class AllSaintsDayTest extends HungaryBaseTestCase implements HolidayTestCase * * @dataProvider HolidayDataProvider * - * @param int $year the year for which the holiday defined in this test needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which the holiday defined in this test needs to be tested + * @param \DateTime $expected the expected date */ public function testHoliday(int $year, \DateTimeInterface $expected): void { @@ -47,7 +45,7 @@ public function testHoliday(int $year, \DateTimeInterface $expected): void * * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function HolidayDataProvider(): array { @@ -57,7 +55,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -72,7 +70,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Hungary/ChristmasTest.php b/tests/Hungary/ChristmasTest.php index 8e399c930..f09b91777 100644 --- a/tests/Hungary/ChristmasTest.php +++ b/tests/Hungary/ChristmasTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\Hungary; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,8 +32,8 @@ class ChristmasTest extends HungaryBaseTestCase implements HolidayTestCase * * @dataProvider HolidayDataProvider * - * @param int $year the year for which the holiday defined in this test needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which the holiday defined in this test needs to be tested + * @param \DateTime $expected the expected date */ public function testHoliday(int $year, \DateTimeInterface $expected): void { @@ -47,7 +45,7 @@ public function testHoliday(int $year, \DateTimeInterface $expected): void * * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function HolidayDataProvider(): array { @@ -57,7 +55,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -72,7 +70,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Hungary/EasterMondayTest.php b/tests/Hungary/EasterMondayTest.php index 526c2f208..a496fd2d4 100644 --- a/tests/Hungary/EasterMondayTest.php +++ b/tests/Hungary/EasterMondayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Hungary; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -33,7 +30,7 @@ class EasterMondayTest extends HungaryBaseTestCase implements HolidayTestCase /** * Tests the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHoliday(): void { @@ -42,14 +39,14 @@ public function testHoliday(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-3-28", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-3-28", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -64,7 +61,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Hungary/EasterTest.php b/tests/Hungary/EasterTest.php index 45356ebff..041c3b4a6 100644 --- a/tests/Hungary/EasterTest.php +++ b/tests/Hungary/EasterTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Hungary; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -33,7 +30,7 @@ class EasterTest extends HungaryBaseTestCase implements HolidayTestCase /** * Tests the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHoliday(): void { @@ -42,14 +39,14 @@ public function testHoliday(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-4-12", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-4-12", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -64,7 +61,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Hungary/HungaryTest.php b/tests/Hungary/HungaryTest.php index eb3d8b7fb..af7c03bb4 100644 --- a/tests/Hungary/HungaryTest.php +++ b/tests/Hungary/HungaryTest.php @@ -14,7 +14,6 @@ namespace Yasumi\tests\Hungary; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\ProviderTestCase; @@ -106,7 +105,7 @@ public function testOtherHolidays(): void } /** - * @throws ReflectionException + * @throws \ReflectionException * @throws \Exception */ public function testSources(): void diff --git a/tests/Hungary/InternationalWorkersDayTest.php b/tests/Hungary/InternationalWorkersDayTest.php index 436868a31..34d5bcbcd 100644 --- a/tests/Hungary/InternationalWorkersDayTest.php +++ b/tests/Hungary/InternationalWorkersDayTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\Hungary; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,8 +32,8 @@ class InternationalWorkersDayTest extends HungaryBaseTestCase implements Holiday * * @dataProvider HolidayDataProvider * - * @param int $year the year for which the holiday defined in this test needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which the holiday defined in this test needs to be tested + * @param \DateTime $expected the expected date */ public function testHoliday(int $year, \DateTimeInterface $expected): void { @@ -47,7 +45,7 @@ public function testHoliday(int $year, \DateTimeInterface $expected): void * * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function HolidayDataProvider(): array { @@ -57,7 +55,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -72,7 +70,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Hungary/MemorialDay1848Test.php b/tests/Hungary/MemorialDay1848Test.php index bbac4e42e..2cd6cdeb8 100644 --- a/tests/Hungary/MemorialDay1848Test.php +++ b/tests/Hungary/MemorialDay1848Test.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Hungary; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -38,7 +35,7 @@ class MemorialDay1848Test extends HungaryBaseTestCase implements HolidayTestCase /** * Tests the holiday defined in this test on or after establishment. * - * @throws Exception + * @throws \Exception */ public function testHolidayOnAfterEstablishment(): void { @@ -47,14 +44,14 @@ public function testHolidayOnAfterEstablishment(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-3-15", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-3-15", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests the holiday defined in this test before establishment. * - * @throws Exception + * @throws \Exception */ public function testHolidayBeforeEstablishment(): void { @@ -68,7 +65,7 @@ public function testHolidayBeforeEstablishment(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -83,7 +80,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Hungary/MemorialDay1956Test.php b/tests/Hungary/MemorialDay1956Test.php index 3e746ca28..d9e94645e 100644 --- a/tests/Hungary/MemorialDay1956Test.php +++ b/tests/Hungary/MemorialDay1956Test.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Hungary; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -38,7 +35,7 @@ class MemorialDay1956Test extends HungaryBaseTestCase implements HolidayTestCase /** * Tests the holiday defined in this test on or after establishment. * - * @throws Exception + * @throws \Exception */ public function testHolidayOnAfterEstablishment(): void { @@ -47,14 +44,14 @@ public function testHolidayOnAfterEstablishment(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-10-23", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-10-23", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests the holiday defined in this test before establishment. * - * @throws Exception + * @throws \Exception */ public function testHolidayBeforeEstablishment(): void { @@ -68,7 +65,7 @@ public function testHolidayBeforeEstablishment(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -83,7 +80,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Hungary/NewYearsDayTest.php b/tests/Hungary/NewYearsDayTest.php index 055a14d47..eff401764 100644 --- a/tests/Hungary/NewYearsDayTest.php +++ b/tests/Hungary/NewYearsDayTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\Hungary; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,8 +32,8 @@ class NewYearsDayTest extends HungaryBaseTestCase implements HolidayTestCase * * @dataProvider HolidayDataProvider * - * @param int $year the year for which the holiday defined in this test needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which the holiday defined in this test needs to be tested + * @param \DateTime $expected the expected date */ public function testHoliday(int $year, \DateTimeInterface $expected): void { @@ -47,7 +45,7 @@ public function testHoliday(int $year, \DateTimeInterface $expected): void * * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function HolidayDataProvider(): array { @@ -57,7 +55,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -72,7 +70,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Hungary/PentecostMondayTest.php b/tests/Hungary/PentecostMondayTest.php index 772ef2b54..fe9ba4547 100644 --- a/tests/Hungary/PentecostMondayTest.php +++ b/tests/Hungary/PentecostMondayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Hungary; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -33,7 +30,7 @@ class PentecostMondayTest extends HungaryBaseTestCase implements HolidayTestCase /** * Tests the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHoliday(): void { @@ -42,14 +39,14 @@ public function testHoliday(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-6-10", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-6-10", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -64,7 +61,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Hungary/PentecostTest.php b/tests/Hungary/PentecostTest.php index eec9d311b..f156399a1 100644 --- a/tests/Hungary/PentecostTest.php +++ b/tests/Hungary/PentecostTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Hungary; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -33,7 +30,7 @@ class PentecostTest extends HungaryBaseTestCase implements HolidayTestCase /** * Tests the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHoliday(): void { @@ -42,14 +39,14 @@ public function testHoliday(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-5-23", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-5-23", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -64,7 +61,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Hungary/SecondChristmasDayTest.php b/tests/Hungary/SecondChristmasDayTest.php index ac0cd37ca..7d43334b2 100644 --- a/tests/Hungary/SecondChristmasDayTest.php +++ b/tests/Hungary/SecondChristmasDayTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\Hungary; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,8 +32,8 @@ class SecondChristmasDayTest extends HungaryBaseTestCase implements HolidayTestC * * @dataProvider HolidayDataProvider * - * @param int $year the year for which the holiday defined in this test needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which the holiday defined in this test needs to be tested + * @param \DateTime $expected the expected date */ public function testHoliday(int $year, \DateTimeInterface $expected): void { @@ -47,7 +45,7 @@ public function testHoliday(int $year, \DateTimeInterface $expected): void * * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function HolidayDataProvider(): array { @@ -57,7 +55,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -72,7 +70,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Hungary/StateFoundationDayTest.php b/tests/Hungary/StateFoundationDayTest.php index 8cc745393..c9e13cd4f 100644 --- a/tests/Hungary/StateFoundationDayTest.php +++ b/tests/Hungary/StateFoundationDayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Hungary; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -38,7 +35,7 @@ class StateFoundationDayTest extends HungaryBaseTestCase implements HolidayTestC /** * Tests the holiday defined in this test on or after establishment. * - * @throws Exception + * @throws \Exception */ public function testHolidayOnAfterEstablishment(): void { @@ -47,14 +44,14 @@ public function testHolidayOnAfterEstablishment(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-8-20", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-8-20", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests the holiday defined in this test before establishment. * - * @throws Exception + * @throws \Exception */ public function testHolidayBeforeEstablishment(): void { @@ -68,7 +65,7 @@ public function testHolidayBeforeEstablishment(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -83,7 +80,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Ireland/AugustHolidayTest.php b/tests/Ireland/AugustHolidayTest.php index bbbe28e77..29ea8b566 100644 --- a/tests/Ireland/AugustHolidayTest.php +++ b/tests/Ireland/AugustHolidayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Ireland; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -38,7 +35,7 @@ class AugustHolidayTest extends IrelandBaseTestCase implements HolidayTestCase * @param int $year the year for which the holiday defined in this test needs to be tested * @param string $expected the expected date * - * @throws Exception + * @throws \Exception */ public function testHoliday(int $year, string $expected): void { @@ -46,7 +43,7 @@ public function testHoliday(int $year, string $expected): void self::REGION, self::HOLIDAY, $year, - new DateTime($expected, new DateTimeZone(self::TIMEZONE)) + new \DateTime($expected, new \DateTimeZone(self::TIMEZONE)) ); $this->assertDayOfWeek(self::REGION, self::HOLIDAY, $year, 'Monday'); } @@ -56,7 +53,7 @@ public function testHoliday(int $year, string $expected): void * * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function HolidayDataProvider(): array { @@ -64,7 +61,7 @@ public function HolidayDataProvider(): array for ($y = 0; $y < self::TEST_ITERATIONS; ++$y) { $year = $this->generateRandomYear(); - $date = new DateTime("next monday $year-7-31", new DateTimeZone(self::TIMEZONE)); + $date = new \DateTime("next monday $year-7-31", new \DateTimeZone(self::TIMEZONE)); $data[] = [$year, $date->format('Y-m-d')]; } @@ -75,7 +72,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -96,7 +93,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Ireland/ChristmasDayTest.php b/tests/Ireland/ChristmasDayTest.php index fd577c0f9..ede04689f 100644 --- a/tests/Ireland/ChristmasDayTest.php +++ b/tests/Ireland/ChristmasDayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Ireland; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -38,11 +35,11 @@ class ChristmasDayTest extends IrelandBaseTestCase implements HolidayTestCase * @param int $year the year for which the holiday defined in this test needs to be tested * @param string $expected the expected date * - * @throws Exception + * @throws \Exception */ public function testHoliday(int $year, string $expected): void { - $date = new DateTime($expected, new DateTimeZone(self::TIMEZONE)); + $date = new \DateTime($expected, new \DateTimeZone(self::TIMEZONE)); $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $date); if (\in_array((int) $date->format('w'), [0, 6], true)) { @@ -56,7 +53,7 @@ public function testHoliday(int $year, string $expected): void * * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function HolidayDataProvider(): array { @@ -64,7 +61,7 @@ public function HolidayDataProvider(): array for ($y = 0; $y < self::TEST_ITERATIONS; ++$y) { $year = $this->generateRandomYear(); - $date = new DateTime("$year-12-25", new DateTimeZone(self::TIMEZONE)); + $date = new \DateTime("$year-12-25", new \DateTimeZone(self::TIMEZONE)); $data[] = [$year, $date->format('Y-m-d')]; } @@ -74,7 +71,7 @@ public function HolidayDataProvider(): array /** * Tests translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -95,7 +92,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Ireland/EasterMondayTest.php b/tests/Ireland/EasterMondayTest.php index 235b699dd..a9a96b2fb 100644 --- a/tests/Ireland/EasterMondayTest.php +++ b/tests/Ireland/EasterMondayTest.php @@ -14,10 +14,6 @@ namespace Yasumi\tests\Ireland; -use DateInterval; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -39,7 +35,7 @@ class EasterMondayTest extends IrelandBaseTestCase implements HolidayTestCase * @param int $year the year for which the holiday defined in this test needs to be tested * @param string $expected the expected date * - * @throws Exception + * @throws \Exception */ public function testHoliday(int $year, string $expected): void { @@ -47,7 +43,7 @@ public function testHoliday(int $year, string $expected): void self::REGION, self::HOLIDAY, $year, - new DateTime($expected, new DateTimeZone(self::TIMEZONE)) + new \DateTime($expected, new \DateTimeZone(self::TIMEZONE)) ); } @@ -56,7 +52,7 @@ public function testHoliday(int $year, string $expected): void * * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function HolidayDataProvider(): array { @@ -65,7 +61,7 @@ public function HolidayDataProvider(): array for ($y = 0; $y < self::TEST_ITERATIONS; ++$y) { $year = $this->generateRandomYear(); $date = $this->calculateEaster($year, self::TIMEZONE); - $date->add(new DateInterval('P1D')); + $date->add(new \DateInterval('P1D')); $data[] = [$year, $date->format('Y-m-d')]; } @@ -76,7 +72,7 @@ public function HolidayDataProvider(): array /** * Tests translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -97,7 +93,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Ireland/EasterTest.php b/tests/Ireland/EasterTest.php index c0c235a53..03b76c38d 100644 --- a/tests/Ireland/EasterTest.php +++ b/tests/Ireland/EasterTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Ireland; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -38,7 +35,7 @@ class EasterTest extends IrelandBaseTestCase implements HolidayTestCase * @param int $year the year for which the holiday defined in this test needs to be tested * @param string $expected the expected date * - * @throws Exception + * @throws \Exception */ public function testHoliday(int $year, string $expected): void { @@ -46,7 +43,7 @@ public function testHoliday(int $year, string $expected): void self::REGION, self::HOLIDAY, $year, - new DateTime($expected, new DateTimeZone(self::TIMEZONE)) + new \DateTime($expected, new \DateTimeZone(self::TIMEZONE)) ); } @@ -55,7 +52,7 @@ public function testHoliday(int $year, string $expected): void * * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function HolidayDataProvider(): array { @@ -74,7 +71,7 @@ public function HolidayDataProvider(): array /** * Tests translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -95,7 +92,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Ireland/GoodFridayTest.php b/tests/Ireland/GoodFridayTest.php index 95e4adc4a..d769a4e41 100644 --- a/tests/Ireland/GoodFridayTest.php +++ b/tests/Ireland/GoodFridayTest.php @@ -14,10 +14,6 @@ namespace Yasumi\tests\Ireland; -use DateInterval; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -39,7 +35,7 @@ class GoodFridayTest extends IrelandBaseTestCase implements HolidayTestCase * @param int $year the year for which the holiday defined in this test needs to be tested * @param string $expected the expected date * - * @throws Exception + * @throws \Exception */ public function testHoliday(int $year, string $expected): void { @@ -47,7 +43,7 @@ public function testHoliday(int $year, string $expected): void self::REGION, self::HOLIDAY, $year, - new DateTime($expected, new DateTimeZone(self::TIMEZONE)) + new \DateTime($expected, new \DateTimeZone(self::TIMEZONE)) ); } @@ -56,7 +52,7 @@ public function testHoliday(int $year, string $expected): void * * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function HolidayDataProvider(): array { @@ -65,7 +61,7 @@ public function HolidayDataProvider(): array for ($y = 0; $y < self::TEST_ITERATIONS; ++$y) { $year = $this->generateRandomYear(); $date = $this->calculateEaster($year, self::TIMEZONE); - $date->sub(new DateInterval('P2D')); + $date->sub(new \DateInterval('P2D')); $data[] = [$year, $date->format('Y-m-d')]; } @@ -75,7 +71,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -96,7 +92,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Ireland/IrelandTest.php b/tests/Ireland/IrelandTest.php index 0fe62a448..9e5762659 100644 --- a/tests/Ireland/IrelandTest.php +++ b/tests/Ireland/IrelandTest.php @@ -14,7 +14,6 @@ namespace Yasumi\tests\Ireland; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\ProviderTestCase; @@ -101,7 +100,7 @@ public function testOtherHolidays(): void } /** - * @throws ReflectionException + * @throws \ReflectionException * @throws \Exception */ public function testSources(): void diff --git a/tests/Ireland/JuneHolidayTest.php b/tests/Ireland/JuneHolidayTest.php index 1e8e0d216..fadf5b364 100644 --- a/tests/Ireland/JuneHolidayTest.php +++ b/tests/Ireland/JuneHolidayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Ireland; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -43,7 +40,7 @@ class JuneHolidayTest extends IrelandBaseTestCase implements HolidayTestCase * @param int $year the year for which the holiday defined in this test needs to be tested * @param string $expected the expected date * - * @throws Exception + * @throws \Exception */ public function testHoliday(int $year, string $expected): void { @@ -51,7 +48,7 @@ public function testHoliday(int $year, string $expected): void self::REGION, self::HOLIDAY, $year, - new DateTime($expected, new DateTimeZone(self::TIMEZONE)) + new \DateTime($expected, new \DateTimeZone(self::TIMEZONE)) ); $this->assertDayOfWeek(self::REGION, self::HOLIDAY, $year, 'Monday'); } @@ -61,7 +58,7 @@ public function testHoliday(int $year, string $expected): void * * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function HolidayDataProvider(): array { @@ -69,7 +66,7 @@ public function HolidayDataProvider(): array for ($y = 0; $y < self::TEST_ITERATIONS; ++$y) { $year = $this->generateRandomYear(self::ESTABLISHMENT_YEAR); - $date = new DateTime("next monday $year-5-31", new DateTimeZone(self::TIMEZONE)); + $date = new \DateTime("next monday $year-5-31", new \DateTimeZone(self::TIMEZONE)); $data[] = [$year, $date->format('Y-m-d')]; } @@ -80,7 +77,7 @@ public function HolidayDataProvider(): array /** * Tests the holiday defined in this test before establishment. * - * @throws Exception + * @throws \Exception */ public function testHolidayBeforeEstablishment(): void { @@ -94,7 +91,7 @@ public function testHolidayBeforeEstablishment(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -115,7 +112,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Ireland/MayDayTest.php b/tests/Ireland/MayDayTest.php index 90b8cb541..f925473d6 100644 --- a/tests/Ireland/MayDayTest.php +++ b/tests/Ireland/MayDayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Ireland; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -43,7 +40,7 @@ class MayDayTest extends IrelandBaseTestCase implements HolidayTestCase * @param int $year the year for which the holiday defined in this test needs to be tested * @param string $expected the expected date * - * @throws Exception + * @throws \Exception */ public function testHoliday(int $year, string $expected): void { @@ -51,7 +48,7 @@ public function testHoliday(int $year, string $expected): void self::REGION, self::HOLIDAY, $year, - new DateTime($expected, new DateTimeZone(self::TIMEZONE)) + new \DateTime($expected, new \DateTimeZone(self::TIMEZONE)) ); $this->assertDayOfWeek(self::REGION, self::HOLIDAY, $year, 'Monday'); } @@ -61,7 +58,7 @@ public function testHoliday(int $year, string $expected): void * * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function HolidayDataProvider(): array { @@ -69,7 +66,7 @@ public function HolidayDataProvider(): array for ($y = 0; $y < self::TEST_ITERATIONS; ++$y) { $year = $this->generateRandomYear(self::ESTABLISHMENT_YEAR); - $date = new DateTime("next monday $year-4-30", new DateTimeZone(self::TIMEZONE)); + $date = new \DateTime("next monday $year-4-30", new \DateTimeZone(self::TIMEZONE)); $data[] = [$year, $date->format('Y-m-d')]; } @@ -80,7 +77,7 @@ public function HolidayDataProvider(): array /** * Tests the holiday defined in this test before establishment. * - * @throws Exception + * @throws \Exception */ public function testHolidayBeforeEstablishment(): void { @@ -94,7 +91,7 @@ public function testHolidayBeforeEstablishment(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -115,7 +112,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Ireland/NewYearsDayTest.php b/tests/Ireland/NewYearsDayTest.php index 7c33d94af..67683adad 100644 --- a/tests/Ireland/NewYearsDayTest.php +++ b/tests/Ireland/NewYearsDayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Ireland; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -43,11 +40,11 @@ class NewYearsDayTest extends IrelandBaseTestCase implements HolidayTestCase * @param int $year the year for which the holiday defined in this test needs to be tested * @param string $expected the expected date * - * @throws Exception + * @throws \Exception */ public function testHoliday(int $year, string $expected): void { - $date = new DateTime($expected, new DateTimeZone(self::TIMEZONE)); + $date = new \DateTime($expected, new \DateTimeZone(self::TIMEZONE)); $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $date); if (0 === (int) $date->format('w')) { @@ -61,7 +58,7 @@ public function testHoliday(int $year, string $expected): void * * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function HolidayDataProvider(): array { @@ -69,7 +66,7 @@ public function HolidayDataProvider(): array for ($y = 0; $y < self::TEST_ITERATIONS; ++$y) { $year = $this->generateRandomYear(self::ESTABLISHMENT_YEAR); - $date = new DateTime("$year-1-1", new DateTimeZone(self::TIMEZONE)); + $date = new \DateTime("$year-1-1", new \DateTimeZone(self::TIMEZONE)); $data[] = [$year, $date->format('Y-m-d')]; } @@ -79,7 +76,7 @@ public function HolidayDataProvider(): array /** * Tests the holiday defined in this test before establishment. * - * @throws Exception + * @throws \Exception */ public function testHolidayBeforeEstablishment(): void { @@ -93,7 +90,7 @@ public function testHolidayBeforeEstablishment(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -114,7 +111,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Ireland/OctoberHolidayTest.php b/tests/Ireland/OctoberHolidayTest.php index a210e335c..d5d0ee79f 100644 --- a/tests/Ireland/OctoberHolidayTest.php +++ b/tests/Ireland/OctoberHolidayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Ireland; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -43,7 +40,7 @@ class OctoberHolidayTest extends IrelandBaseTestCase implements HolidayTestCase * @param int $year the year for which the holiday defined in this test needs to be tested * @param string $expected the expected date * - * @throws Exception + * @throws \Exception */ public function testHoliday(int $year, string $expected): void { @@ -51,7 +48,7 @@ public function testHoliday(int $year, string $expected): void self::REGION, self::HOLIDAY, $year, - new DateTime($expected, new DateTimeZone(self::TIMEZONE)) + new \DateTime($expected, new \DateTimeZone(self::TIMEZONE)) ); $this->assertDayOfWeek(self::REGION, self::HOLIDAY, $year, 'Monday'); } @@ -61,7 +58,7 @@ public function testHoliday(int $year, string $expected): void * * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function HolidayDataProvider(): array { @@ -69,7 +66,7 @@ public function HolidayDataProvider(): array for ($y = 0; $y < self::TEST_ITERATIONS; ++$y) { $year = $this->generateRandomYear(self::ESTABLISHMENT_YEAR); - $date = new DateTime("previous monday $year-11-1", new DateTimeZone(self::TIMEZONE)); + $date = new \DateTime("previous monday $year-11-1", new \DateTimeZone(self::TIMEZONE)); $data[] = [$year, $date->format('Y-m-d')]; } @@ -80,7 +77,7 @@ public function HolidayDataProvider(): array /** * Tests the holiday defined in this test before establishment. * - * @throws Exception + * @throws \Exception */ public function testHolidayBeforeEstablishment(): void { @@ -94,7 +91,7 @@ public function testHolidayBeforeEstablishment(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -115,7 +112,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Ireland/PentecostTest.php b/tests/Ireland/PentecostTest.php index 61bf739a3..bad0333ea 100644 --- a/tests/Ireland/PentecostTest.php +++ b/tests/Ireland/PentecostTest.php @@ -14,10 +14,6 @@ namespace Yasumi\tests\Ireland; -use DateInterval; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -39,7 +35,7 @@ class PentecostTest extends IrelandBaseTestCase implements HolidayTestCase * @param int $year the year for which the holiday defined in this test needs to be tested * @param string $expected the expected date * - * @throws Exception + * @throws \Exception */ public function testHoliday(int $year, string $expected): void { @@ -47,7 +43,7 @@ public function testHoliday(int $year, string $expected): void self::REGION, self::HOLIDAY, $year, - new DateTime($expected, new DateTimeZone(self::TIMEZONE)) + new \DateTime($expected, new \DateTimeZone(self::TIMEZONE)) ); } @@ -56,7 +52,7 @@ public function testHoliday(int $year, string $expected): void * * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function HolidayDataProvider(): array { @@ -66,7 +62,7 @@ public function HolidayDataProvider(): array for ($y = 0; $y < 2; ++$y) { $year = $this->generateRandomYear(); $date = $this->calculateEaster($year, self::TIMEZONE); - $date->add(new DateInterval('P49D')); + $date->add(new \DateInterval('P49D')); $data[] = [$year, $date->format('Y-m-d')]; } @@ -76,7 +72,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -97,7 +93,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Ireland/StPatricksDayTest.php b/tests/Ireland/StPatricksDayTest.php index 0ad3e91cb..cec99417a 100644 --- a/tests/Ireland/StPatricksDayTest.php +++ b/tests/Ireland/StPatricksDayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Ireland; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -43,11 +40,11 @@ class StPatricksDayTest extends IrelandBaseTestCase implements HolidayTestCase * @param int $year the year for which the holiday defined in this test needs to be tested * @param string $expected the expected date * - * @throws Exception + * @throws \Exception */ public function testHoliday(int $year, string $expected): void { - $date = new DateTime($expected, new DateTimeZone(self::TIMEZONE)); + $date = new \DateTime($expected, new \DateTimeZone(self::TIMEZONE)); $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $date); if (\in_array((int) $date->format('w'), [0, 6], true)) { @@ -61,7 +58,7 @@ public function testHoliday(int $year, string $expected): void * * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function HolidayDataProvider(): array { @@ -69,7 +66,7 @@ public function HolidayDataProvider(): array for ($y = 0; $y < self::TEST_ITERATIONS; ++$y) { $year = $this->generateRandomYear(self::ESTABLISHMENT_YEAR); - $date = new DateTime("$year-3-17", new DateTimeZone(self::TIMEZONE)); + $date = new \DateTime("$year-3-17", new \DateTimeZone(self::TIMEZONE)); $data[] = [$year, $date->format('Y-m-d')]; } @@ -79,7 +76,7 @@ public function HolidayDataProvider(): array /** * Tests the holiday defined in this test before establishment. * - * @throws Exception + * @throws \Exception */ public function testHolidayBeforeEstablishment(): void { @@ -93,7 +90,7 @@ public function testHolidayBeforeEstablishment(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -114,7 +111,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Ireland/StStephensDayTest.php b/tests/Ireland/StStephensDayTest.php index b0f10b88f..fac07209b 100644 --- a/tests/Ireland/StStephensDayTest.php +++ b/tests/Ireland/StStephensDayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Ireland; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -38,11 +35,11 @@ class StStephensDayTest extends IrelandBaseTestCase implements HolidayTestCase * @param int $year the year for which the holiday defined in this test needs to be tested * @param string $expected the expected date * - * @throws Exception + * @throws \Exception */ public function testHoliday(int $year, string $expected): void { - $date = new DateTime($expected, new DateTimeZone(self::TIMEZONE)); + $date = new \DateTime($expected, new \DateTimeZone(self::TIMEZONE)); $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $date); if (\in_array((int) $date->format('w'), [0, 6], true)) { @@ -56,7 +53,7 @@ public function testHoliday(int $year, string $expected): void * * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function HolidayDataProvider(): array { @@ -64,7 +61,7 @@ public function HolidayDataProvider(): array for ($y = 0; $y < self::TEST_ITERATIONS; ++$y) { $year = $this->generateRandomYear(); - $date = new DateTime("$year-12-26", new DateTimeZone(self::TIMEZONE)); + $date = new \DateTime("$year-12-26", new \DateTimeZone(self::TIMEZONE)); $data[] = [$year, $date->format('Y-m-d')]; } @@ -74,7 +71,7 @@ public function HolidayDataProvider(): array /** * Tests translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -95,7 +92,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Ireland/pentecostMondayTest.php b/tests/Ireland/pentecostMondayTest.php index f1028a971..af37e0a66 100644 --- a/tests/Ireland/pentecostMondayTest.php +++ b/tests/Ireland/pentecostMondayTest.php @@ -14,10 +14,6 @@ namespace Yasumi\tests\Ireland; -use DateInterval; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -44,7 +40,7 @@ class pentecostMondayTest extends IrelandBaseTestCase implements HolidayTestCase * @param int $year the year for which the holiday defined in this test needs to be tested * @param string $expected the expected date * - * @throws Exception + * @throws \Exception */ public function testHoliday(int $year, string $expected): void { @@ -52,7 +48,7 @@ public function testHoliday(int $year, string $expected): void self::REGION, self::HOLIDAY, $year, - new DateTime($expected, new DateTimeZone(self::TIMEZONE)) + new \DateTime($expected, new \DateTimeZone(self::TIMEZONE)) ); } @@ -61,7 +57,7 @@ public function testHoliday(int $year, string $expected): void * * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function HolidayDataProvider(): array { @@ -70,7 +66,7 @@ public function HolidayDataProvider(): array for ($y = 0; $y < self::TEST_ITERATIONS; ++$y) { $year = $this->generateRandomYear(1000, self::ABOLISHMENT_YEAR); $date = $this->calculateEaster($year, self::TIMEZONE); - $date->add(new DateInterval('P50D')); + $date->add(new \DateInterval('P50D')); $data[] = [$year, $date->format('Y-m-d')]; } @@ -80,7 +76,7 @@ public function HolidayDataProvider(): array /** * Tests the holiday defined in this test after abolishment. * - * @throws Exception + * @throws \Exception */ public function testHolidayDayAfterAbolishment(): void { @@ -90,7 +86,7 @@ public function testHolidayDayAfterAbolishment(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -111,7 +107,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Italy/AllSaintsDayTest.php b/tests/Italy/AllSaintsDayTest.php index 73ae8a0c7..63d7bec75 100644 --- a/tests/Italy/AllSaintsDayTest.php +++ b/tests/Italy/AllSaintsDayTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\Italy; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,8 +32,8 @@ class AllSaintsDayTest extends ItalyBaseTestCase implements HolidayTestCase * * @dataProvider AllSaintsDayDataProvider * - * @param int $year the year for which All Saints' Day needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which All Saints' Day needs to be tested + * @param \DateTime $expected the expected date */ public function testAssumptionOfMary(int $year, \DateTimeInterface $expected): void { @@ -47,7 +45,7 @@ public function testAssumptionOfMary(int $year, \DateTimeInterface $expected): v * * @return array list of test dates for All Saints' Day * - * @throws Exception + * @throws \Exception */ public function AllSaintsDayDataProvider(): array { @@ -57,7 +55,7 @@ public function AllSaintsDayDataProvider(): array /** * Tests translated name of All Saints' Day. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -72,7 +70,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Italy/AssumptionOfMaryTest.php b/tests/Italy/AssumptionOfMaryTest.php index a8c0fd748..62ebf3d84 100644 --- a/tests/Italy/AssumptionOfMaryTest.php +++ b/tests/Italy/AssumptionOfMaryTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\Italy; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,8 +32,8 @@ class AssumptionOfMaryTest extends ItalyBaseTestCase implements HolidayTestCase * * @dataProvider AssumptionOfMaryDataProvider * - * @param int $year the year for which the day of the Assumption of Mary needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which the day of the Assumption of Mary needs to be tested + * @param \DateTime $expected the expected date */ public function testAssumptionOfMary(int $year, \DateTimeInterface $expected): void { @@ -47,7 +45,7 @@ public function testAssumptionOfMary(int $year, \DateTimeInterface $expected): v * * @return array list of test dates for the day of the Assumption of Mary * - * @throws Exception + * @throws \Exception */ public function AssumptionOfMaryDataProvider(): array { @@ -57,7 +55,7 @@ public function AssumptionOfMaryDataProvider(): array /** * Tests translated name of the Assumption of Mary. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -72,7 +70,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Italy/ChristmasTest.php b/tests/Italy/ChristmasTest.php index 343c4de23..6047ac989 100644 --- a/tests/Italy/ChristmasTest.php +++ b/tests/Italy/ChristmasTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\Italy; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,8 +32,8 @@ class ChristmasTest extends ItalyBaseTestCase implements HolidayTestCase * * @dataProvider ChristmasDayDataProvider * - * @param int $year the year for which Christmas Day needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which Christmas Day needs to be tested + * @param \DateTime $expected the expected date */ public function testChristmasDay(int $year, \DateTimeInterface $expected): void { @@ -47,7 +45,7 @@ public function testChristmasDay(int $year, \DateTimeInterface $expected): void * * @return array list of test dates for Christmas Day * - * @throws Exception + * @throws \Exception */ public function ChristmasDayDataProvider(): array { @@ -57,7 +55,7 @@ public function ChristmasDayDataProvider(): array /** * Tests translated name of Christmas Day. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -72,7 +70,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Italy/EasterMondayTest.php b/tests/Italy/EasterMondayTest.php index 8ccd7e6f5..b50c6e148 100644 --- a/tests/Italy/EasterMondayTest.php +++ b/tests/Italy/EasterMondayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Italy; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -33,7 +30,7 @@ class EasterMondayTest extends ItalyBaseTestCase implements HolidayTestCase /** * Tests the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHoliday(): void { @@ -42,14 +39,14 @@ public function testHoliday(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-3-28", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-3-28", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -64,7 +61,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Italy/EasterTest.php b/tests/Italy/EasterTest.php index 7a7e9887f..a29932547 100644 --- a/tests/Italy/EasterTest.php +++ b/tests/Italy/EasterTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Italy; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -33,7 +30,7 @@ class EasterTest extends ItalyBaseTestCase implements HolidayTestCase /** * Tests Easter. * - * @throws Exception + * @throws \Exception */ public function testEaster(): void { @@ -42,14 +39,14 @@ public function testEaster(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-4-12", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-4-12", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests translated name of Easter. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -64,7 +61,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Italy/EpiphanyTest.php b/tests/Italy/EpiphanyTest.php index a11c21734..88e43b584 100644 --- a/tests/Italy/EpiphanyTest.php +++ b/tests/Italy/EpiphanyTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\Italy; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,8 +32,8 @@ class EpiphanyTest extends ItalyBaseTestCase implements HolidayTestCase * * @dataProvider EpiphanyDataProvider * - * @param int $year the year for which Epiphany needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which Epiphany needs to be tested + * @param \DateTime $expected the expected date */ public function testEpiphany(int $year, \DateTimeInterface $expected): void { @@ -47,7 +45,7 @@ public function testEpiphany(int $year, \DateTimeInterface $expected): void * * @return array list of test dates for Epiphany * - * @throws Exception + * @throws \Exception */ public function EpiphanyDataProvider(): array { @@ -57,7 +55,7 @@ public function EpiphanyDataProvider(): array /** * Tests translated name of Epiphany. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -72,7 +70,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Italy/ImmaculateConceptionTest.php b/tests/Italy/ImmaculateConceptionTest.php index cc3507025..cba706a4c 100644 --- a/tests/Italy/ImmaculateConceptionTest.php +++ b/tests/Italy/ImmaculateConceptionTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\Italy; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,8 +32,8 @@ class ImmaculateConceptionTest extends ItalyBaseTestCase implements HolidayTestC * * @dataProvider ImmaculateConceptionDataProvider * - * @param int $year the year for which the day of Immaculate Conception needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which the day of Immaculate Conception needs to be tested + * @param \DateTime $expected the expected date */ public function testImmaculateConception(int $year, \DateTimeInterface $expected): void { @@ -47,7 +45,7 @@ public function testImmaculateConception(int $year, \DateTimeInterface $expected * * @return array list of test dates for the day of Immaculate Conception * - * @throws Exception + * @throws \Exception */ public function ImmaculateConceptionDataProvider(): array { @@ -57,7 +55,7 @@ public function ImmaculateConceptionDataProvider(): array /** * Tests translated name of the day of Immaculate Conception. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -72,7 +70,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Italy/InternationalWorkersDayTest.php b/tests/Italy/InternationalWorkersDayTest.php index 55fbe57f0..d2eee45a9 100644 --- a/tests/Italy/InternationalWorkersDayTest.php +++ b/tests/Italy/InternationalWorkersDayTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\Italy; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,8 +32,8 @@ class InternationalWorkersDayTest extends ItalyBaseTestCase implements HolidayTe * * @dataProvider InternationalWorkersDayDataProvider * - * @param int $year the year for which International Workers' Day needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which International Workers' Day needs to be tested + * @param \DateTime $expected the expected date */ public function testInternationalWorkersDay(int $year, \DateTimeInterface $expected): void { @@ -47,7 +45,7 @@ public function testInternationalWorkersDay(int $year, \DateTimeInterface $expec * * @return array list of test dates for International Workers' Day * - * @throws Exception + * @throws \Exception */ public function InternationalWorkersDayDataProvider(): array { @@ -57,7 +55,7 @@ public function InternationalWorkersDayDataProvider(): array /** * Tests translated name of International Workers' Day. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -72,7 +70,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Italy/ItalyTest.php b/tests/Italy/ItalyTest.php index 30d7a5632..9870a2249 100644 --- a/tests/Italy/ItalyTest.php +++ b/tests/Italy/ItalyTest.php @@ -14,7 +14,6 @@ namespace Yasumi\tests\Italy; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\ProviderTestCase; @@ -92,7 +91,7 @@ public function testOtherHolidays(): void } /** - * @throws ReflectionException + * @throws \ReflectionException * @throws \Exception */ public function testSources(): void diff --git a/tests/Italy/LiberationDayTest.php b/tests/Italy/LiberationDayTest.php index 626aedf22..c7b24ee68 100644 --- a/tests/Italy/LiberationDayTest.php +++ b/tests/Italy/LiberationDayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Italy; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -45,7 +42,7 @@ class LiberationDayTest extends ItalyBaseTestCase implements HolidayTestCase /** * Tests Liberation Day on or after 1949. * - * @throws Exception + * @throws \Exception */ public function testLiberationDayOnAfter1949(): void { @@ -54,14 +51,14 @@ public function testLiberationDayOnAfter1949(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-4-25", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-4-25", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests Liberation Day before 1949. * - * @throws Exception + * @throws \Exception */ public function testLiberationDayBefore1949(): void { @@ -75,7 +72,7 @@ public function testLiberationDayBefore1949(): void /** * Tests translated name of Liberation Day. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -90,7 +87,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Italy/NewYearsDayTest.php b/tests/Italy/NewYearsDayTest.php index e8e3d2bf5..d5f2f21f0 100644 --- a/tests/Italy/NewYearsDayTest.php +++ b/tests/Italy/NewYearsDayTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\Italy; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,8 +32,8 @@ class NewYearsDayTest extends ItalyBaseTestCase implements HolidayTestCase * * @dataProvider NewYearsDayDataProvider * - * @param int $year the year for which New Years Day needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which New Years Day needs to be tested + * @param \DateTime $expected the expected date */ public function testNewYearsDay(int $year, \DateTimeInterface $expected): void { @@ -47,7 +45,7 @@ public function testNewYearsDay(int $year, \DateTimeInterface $expected): void * * @return array list of test dates for New Years Day * - * @throws Exception + * @throws \Exception */ public function NewYearsDayDataProvider(): array { @@ -57,7 +55,7 @@ public function NewYearsDayDataProvider(): array /** * Tests translated name of New Years Day. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -72,7 +70,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Italy/RepublicDayTest.php b/tests/Italy/RepublicDayTest.php index 91fda23f2..702a667b9 100644 --- a/tests/Italy/RepublicDayTest.php +++ b/tests/Italy/RepublicDayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Italy; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -45,7 +42,7 @@ class RepublicDayTest extends ItalyBaseTestCase implements HolidayTestCase /** * Tests Republic Day on or after 1946. * - * @throws Exception + * @throws \Exception */ public function testRepublicDayOnAfter1946(): void { @@ -54,14 +51,14 @@ public function testRepublicDayOnAfter1946(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-6-2", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-6-2", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests Republic Day before 1946. * - * @throws Exception + * @throws \Exception */ public function testRepublicDayBefore1946(): void { @@ -75,7 +72,7 @@ public function testRepublicDayBefore1946(): void /** * Tests translated name of Republic Day. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -90,7 +87,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Italy/stStephensDayTest.php b/tests/Italy/stStephensDayTest.php index 217782c29..e2a728cc7 100644 --- a/tests/Italy/stStephensDayTest.php +++ b/tests/Italy/stStephensDayTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\Italy; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,8 +32,8 @@ class stStephensDayTest extends ItalyBaseTestCase implements HolidayTestCase * * @dataProvider stStephensDayDataProvider * - * @param int $year the year for which St. Stephen's Day needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which St. Stephen's Day needs to be tested + * @param \DateTime $expected the expected date */ public function teststStephensDay(int $year, \DateTimeInterface $expected): void { @@ -47,7 +45,7 @@ public function teststStephensDay(int $year, \DateTimeInterface $expected): void * * @return array list of test dates for St. Stephen's Day * - * @throws Exception + * @throws \Exception */ public function stStephensDayDataProvider(): array { @@ -57,7 +55,7 @@ public function stStephensDayDataProvider(): array /** * Tests translated name of St. Stephen's Day. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -72,7 +70,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Japan/AutumnalEquinoxDayTest.php b/tests/Japan/AutumnalEquinoxDayTest.php index 29fca97ed..2d97f2d47 100644 --- a/tests/Japan/AutumnalEquinoxDayTest.php +++ b/tests/Japan/AutumnalEquinoxDayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Japan; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -42,7 +39,7 @@ class AutumnalEquinoxDayTest extends JapanBaseTestCase implements HolidayTestCas * * After 2150 no calculations are available yet. * - * @throws Exception + * @throws \Exception */ public function testAutumnalEquinoxDayOnAfter2150(): void { @@ -62,7 +59,7 @@ public function testAutumnalEquinoxDayOnAfter2150(): void * @param int $month month (number) of example data to be tested * @param int $day day of the month (number) of example data to be tested * - * @throws Exception + * @throws \Exception */ public function testAutumnalEquinoxDayBetween1948And2150(int $year, int $month, int $day): void { @@ -70,7 +67,7 @@ public function testAutumnalEquinoxDayBetween1948And2150(int $year, int $month, self::REGION, self::HOLIDAY, $year, - new DateTime("$year-$month-$day", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-$month-$day", new \DateTimeZone(self::TIMEZONE)) ); } @@ -95,7 +92,7 @@ public function autumnalEquinoxHolidaysProvider(): array * one's ancestors and remember the dead. Prior to 1948, the autumnal equinox was an imperial ancestor worship * festival called Shūki kōrei-sai (秋季皇霊祭). * - * @throws Exception + * @throws \Exception */ public function testAutumnalEquinoxDayBefore1948(): void { @@ -109,7 +106,7 @@ public function testAutumnalEquinoxDayBefore1948(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -124,7 +121,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Japan/ChildrensDayTest.php b/tests/Japan/ChildrensDayTest.php index b99c04bda..fdad4ed3a 100644 --- a/tests/Japan/ChildrensDayTest.php +++ b/tests/Japan/ChildrensDayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Japan; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -38,7 +35,7 @@ class ChildrensDayTest extends JapanBaseTestCase implements HolidayTestCase /** * Tests Children's Day after 1948. Children's Day was established after 1948. * - * @throws Exception + * @throws \Exception */ public function testChildrensDayOnAfter1948(): void { @@ -47,14 +44,14 @@ public function testChildrensDayOnAfter1948(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-5-5", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-5-5", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests Children's Day after 1948 substituted next working day (when Children's Day falls on a Sunday). * - * @throws Exception + * @throws \Exception */ public function testChildrensDayOnAfter1948SubstitutedNextWorkingDay(): void { @@ -63,14 +60,14 @@ public function testChildrensDayOnAfter1948SubstitutedNextWorkingDay(): void self::REGION, self::SUBSTITUTE_PREFIX.self::HOLIDAY, $year, - new DateTime("$year-5-6", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-5-6", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests Children's Day before 1948. Children's Day was established after 1948. * - * @throws Exception + * @throws \Exception */ public function testChildrensDayBefore1948(): void { @@ -84,7 +81,7 @@ public function testChildrensDayBefore1948(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -99,7 +96,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Japan/ComingOfAgeDayTest.php b/tests/Japan/ComingOfAgeDayTest.php index 717a07c04..121345b90 100644 --- a/tests/Japan/ComingOfAgeDayTest.php +++ b/tests/Japan/ComingOfAgeDayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Japan; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -39,7 +36,7 @@ class ComingOfAgeDayTest extends JapanBaseTestCase implements HolidayTestCase * Tests Coming of Age Day after 2000. Coming of Age Day was established after 1948 on January 15th. After 2000 it * was changed to be the second monday of January. * - * @throws Exception + * @throws \Exception */ public function testComingOfAgeDayOnAfter2000(): void { @@ -48,7 +45,7 @@ public function testComingOfAgeDayOnAfter2000(): void self::REGION, self::HOLIDAY, $year, - new DateTime("second monday of january $year", new DateTimeZone(self::TIMEZONE)) + new \DateTime("second monday of january $year", new \DateTimeZone(self::TIMEZONE)) ); } @@ -56,7 +53,7 @@ public function testComingOfAgeDayOnAfter2000(): void * Tests Coming of Age Day between 1948 and 2000. Coming of Age Day was established after 1948 on January 15th. * After 2000 it was changed to be the second monday of January. * - * @throws Exception + * @throws \Exception */ public function testComingOfAgeDayBetween1948And2000(): void { @@ -65,7 +62,7 @@ public function testComingOfAgeDayBetween1948And2000(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-1-15", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-1-15", new \DateTimeZone(self::TIMEZONE)) ); } @@ -73,7 +70,7 @@ public function testComingOfAgeDayBetween1948And2000(): void * Tests Coming of Age Day before 1948. Coming of Age Day was established after 1948 on January 15th. After 2000 it * was changed to be the second monday of January. * - * @throws Exception + * @throws \Exception */ public function testConstitutionMemorialDayBefore1948(): void { @@ -87,7 +84,7 @@ public function testConstitutionMemorialDayBefore1948(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -102,7 +99,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Japan/ConstitutionMemorialDayTest.php b/tests/Japan/ConstitutionMemorialDayTest.php index 7f8601adf..d2714b1bc 100644 --- a/tests/Japan/ConstitutionMemorialDayTest.php +++ b/tests/Japan/ConstitutionMemorialDayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Japan; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -38,7 +35,7 @@ class ConstitutionMemorialDayTest extends JapanBaseTestCase implements HolidayTe /** * Tests Constitution Memorial Day after 1948. Constitution Memorial Day was established after 1948. * - * @throws Exception + * @throws \Exception */ public function testConstitutionMemorialDayOnAfter1948(): void { @@ -47,7 +44,7 @@ public function testConstitutionMemorialDayOnAfter1948(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-5-3", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-5-3", new \DateTimeZone(self::TIMEZONE)) ); } @@ -55,7 +52,7 @@ public function testConstitutionMemorialDayOnAfter1948(): void * Tests Constitution Memorial Day after 1948 substituted next working day (when Constitution Memorial Day falls on * a Sunday). * - * @throws Exception + * @throws \Exception */ public function testConstitutionMemorialDayOnAfter1948SubstitutedNextWorkingDay(): void { @@ -64,14 +61,14 @@ public function testConstitutionMemorialDayOnAfter1948SubstitutedNextWorkingDay( self::REGION, self::SUBSTITUTE_PREFIX.self::HOLIDAY, $year, - new DateTime("$year-5-6", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-5-6", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests Constitution Memorial Day before 1948. Constitution Memorial Day was established after 1948. * - * @throws Exception + * @throws \Exception */ public function testConstitutionMemorialDayBefore1948(): void { @@ -85,7 +82,7 @@ public function testConstitutionMemorialDayBefore1948(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -100,7 +97,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Japan/CoronationDayTest.php b/tests/Japan/CoronationDayTest.php index 4c007674d..7068a960e 100644 --- a/tests/Japan/CoronationDayTest.php +++ b/tests/Japan/CoronationDayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Japan; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -36,7 +33,7 @@ class CoronationDayTest extends JapanBaseTestCase implements HolidayTestCase public const ESTABLISHMENT_YEAR = 2019; /** - * @throws Exception + * @throws \Exception */ public function testEmperorsCoronationDay(): void { @@ -44,12 +41,12 @@ public function testEmperorsCoronationDay(): void self::REGION, self::HOLIDAY, 2019, - new DateTime('2019-5-1', new DateTimeZone(self::TIMEZONE)) + new \DateTime('2019-5-1', new \DateTimeZone(self::TIMEZONE)) ); } /** - * @throws Exception + * @throws \Exception */ public function testEmperorsBirthdayBefore2019(): void { @@ -61,7 +58,7 @@ public function testEmperorsBirthdayBefore2019(): void } /** - * @throws Exception + * @throws \Exception */ public function testEmperorsBirthdayAfter2020(): void { diff --git a/tests/Japan/CultureDayTest.php b/tests/Japan/CultureDayTest.php index 150c29e9f..50395cb92 100644 --- a/tests/Japan/CultureDayTest.php +++ b/tests/Japan/CultureDayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Japan; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -38,7 +35,7 @@ class CultureDayTest extends JapanBaseTestCase implements HolidayTestCase /** * Tests Culture Day after 1948. Culture Day Day was established after 1948. * - * @throws Exception + * @throws \Exception */ public function testCultureDayOnAfter1948(): void { @@ -47,14 +44,14 @@ public function testCultureDayOnAfter1948(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-11-3", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-11-3", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests Culture Day after 1948 substituted next working day (when Culture Day falls on a Sunday). * - * @throws Exception + * @throws \Exception */ public function testCultureDayOnAfter1948SubstitutedNextWorkingDay(): void { @@ -63,14 +60,14 @@ public function testCultureDayOnAfter1948SubstitutedNextWorkingDay(): void self::REGION, self::SUBSTITUTE_PREFIX.self::HOLIDAY, $year, - new DateTime("$year-11-4", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-11-4", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests Culture Day before 1948. Culture Day was established after 1948. * - * @throws Exception + * @throws \Exception */ public function testCultureDayBefore1948(): void { @@ -84,7 +81,7 @@ public function testCultureDayBefore1948(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -99,7 +96,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Japan/EmperorsBirthdayTest.php b/tests/Japan/EmperorsBirthdayTest.php index da34dbad5..a6168a508 100644 --- a/tests/Japan/EmperorsBirthdayTest.php +++ b/tests/Japan/EmperorsBirthdayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Japan; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -40,7 +37,7 @@ class EmperorsBirthdayTest extends JapanBaseTestCase implements HolidayTestCase * Tests the Emperors Birthday after 1949 to 1988. The Emperors Birthday is on April 28rd and celebrated as such since * 1949. * - * @throws Exception + * @throws \Exception */ public function testEmperorsBirthdayOnAfter1949(): void { @@ -49,7 +46,7 @@ public function testEmperorsBirthdayOnAfter1949(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-4-29", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-4-29", new \DateTimeZone(self::TIMEZONE)) ); } @@ -58,7 +55,7 @@ public function testEmperorsBirthdayOnAfter1949(): void * 1989. Prior to the death of Emperor Hirohito in 1989, this holiday was celebrated on April 29. See also "Shōwa * Day". * - * @throws Exception + * @throws \Exception */ public function testEmperorsBirthdayOnAfter1989(): void { @@ -67,7 +64,7 @@ public function testEmperorsBirthdayOnAfter1989(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-12-23", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-12-23", new \DateTimeZone(self::TIMEZONE)) ); } @@ -75,7 +72,7 @@ public function testEmperorsBirthdayOnAfter1989(): void * Tests the Emperors Birthday after 2020. The Emperors Birthday is on February 23rd and celebrated as such since * 2020. * - * @throws Exception + * @throws \Exception */ public function testEmperorsBirthdayOnAfter2020(): void { @@ -84,7 +81,7 @@ public function testEmperorsBirthdayOnAfter2020(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-2-23", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-2-23", new \DateTimeZone(self::TIMEZONE)) ); } @@ -92,7 +89,7 @@ public function testEmperorsBirthdayOnAfter2020(): void * Tests the Emperors Birthday after 1989 substituted next working day (when the Emperors Birthday falls on a * Sunday). * - * @throws Exception + * @throws \Exception */ public function testEmperorsBirthdayOnAfter1989SubstitutedNextWorkingDay(): void { @@ -101,7 +98,7 @@ public function testEmperorsBirthdayOnAfter1989SubstitutedNextWorkingDay(): void self::REGION, self::SUBSTITUTE_PREFIX.self::HOLIDAY, $year, - new DateTime("$year-12-24", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-12-24", new \DateTimeZone(self::TIMEZONE)) ); } @@ -110,7 +107,7 @@ public function testEmperorsBirthdayOnAfter1989SubstitutedNextWorkingDay(): void * 1989. Prior to the death of Emperor Hirohito in 1989, this holiday was celebrated on April 29. See also "Shōwa * Day"/"Greenery Day". * - * @throws Exception + * @throws \Exception */ public function testEmperorsBirthdayBefore1989(): void { @@ -136,7 +133,7 @@ public function testEmperorsBirthdayAt2019(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -151,7 +148,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Japan/EnthronementProclamationCeremonyTest.php b/tests/Japan/EnthronementProclamationCeremonyTest.php index 412ac45cb..17fe2a313 100644 --- a/tests/Japan/EnthronementProclamationCeremonyTest.php +++ b/tests/Japan/EnthronementProclamationCeremonyTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Japan; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -36,7 +33,7 @@ class EnthronementProclamationCeremonyTest extends JapanBaseTestCase implements public const IMPLEMENT_YEAR = 2019; /** - * @throws Exception + * @throws \Exception */ public function testEmperorsCoronationDay(): void { @@ -44,12 +41,12 @@ public function testEmperorsCoronationDay(): void self::REGION, self::HOLIDAY, 2019, - new DateTime('2019-10-22', new DateTimeZone(self::TIMEZONE)) + new \DateTime('2019-10-22', new \DateTimeZone(self::TIMEZONE)) ); } /** - * @throws Exception + * @throws \Exception */ public function testEmperorsBirthdayBefore2019(): void { @@ -61,7 +58,7 @@ public function testEmperorsBirthdayBefore2019(): void } /** - * @throws Exception + * @throws \Exception */ public function testEmperorsBirthdayAfter2020(): void { diff --git a/tests/Japan/GreeneryDayTest.php b/tests/Japan/GreeneryDayTest.php index 6ae952511..baa96d8a6 100644 --- a/tests/Japan/GreeneryDayTest.php +++ b/tests/Japan/GreeneryDayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Japan; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -39,7 +36,7 @@ class GreeneryDayTest extends JapanBaseTestCase implements HolidayTestCase * Tests Greenery Day after 2007. Greenery Day was established from 1989 on April 29th. After 2007 * it was changed to be May 4th. * - * @throws Exception + * @throws \Exception */ public function testHolidayOnAfter2007(): void { @@ -48,14 +45,14 @@ public function testHolidayOnAfter2007(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-5-4", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-5-4", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests Greenery Day after 2007 substituted next working day (when Greenery Day falls on a Sunday). * - * @throws Exception + * @throws \Exception */ public function testHolidayOnAfter2007SubstitutedNextWorkingDay(): void { @@ -64,7 +61,7 @@ public function testHolidayOnAfter2007SubstitutedNextWorkingDay(): void self::REGION, self::SUBSTITUTE_PREFIX.self::HOLIDAY, $year, - new DateTime("$year-5-6", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-5-6", new \DateTimeZone(self::TIMEZONE)) ); } @@ -72,7 +69,7 @@ public function testHolidayOnAfter2007SubstitutedNextWorkingDay(): void * Tests Greenery Day between 1989 and 2007. Greenery Day was established from 1989 on April 29th. After 2007 * it was changed to be May 4th. * - * @throws Exception + * @throws \Exception */ public function testHolidayBetween1989And2007(): void { @@ -81,14 +78,14 @@ public function testHolidayBetween1989And2007(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-4-29", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-4-29", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests Greenery Day between 1989 and 2007 substituted next working day (when Greenery Day falls on a Sunday). * - * @throws Exception + * @throws \Exception */ public function testHolidayBetween1989And2007SubstitutedNextWorkingDay(): void { @@ -97,7 +94,7 @@ public function testHolidayBetween1989And2007SubstitutedNextWorkingDay(): void self::REGION, self::SUBSTITUTE_PREFIX.self::HOLIDAY, $year, - new DateTime("$year-4-30", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-4-30", new \DateTimeZone(self::TIMEZONE)) ); } @@ -105,7 +102,7 @@ public function testHolidayBetween1989And2007SubstitutedNextWorkingDay(): void * Tests Greenery Day before 1989. Greenery Day was established from 1989 on April 29th. After 2007 * it was changed to be May 4th. * - * @throws Exception + * @throws \Exception */ public function testHolidayBefore1989(): void { @@ -119,7 +116,7 @@ public function testHolidayBefore1989(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -134,7 +131,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Japan/JapanTest.php b/tests/Japan/JapanTest.php index d10a1b223..4136d8f59 100644 --- a/tests/Japan/JapanTest.php +++ b/tests/Japan/JapanTest.php @@ -14,7 +14,6 @@ namespace Yasumi\tests\Japan; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\ProviderTestCase; @@ -122,7 +121,7 @@ public function testOtherHolidays(): void } /** - * @throws ReflectionException + * @throws \ReflectionException * @throws \Exception */ public function testSources(): void diff --git a/tests/Japan/LabourThanksgivingDayTest.php b/tests/Japan/LabourThanksgivingDayTest.php index 34f7dc716..b28903335 100644 --- a/tests/Japan/LabourThanksgivingDayTest.php +++ b/tests/Japan/LabourThanksgivingDayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Japan; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -39,7 +36,7 @@ class LabourThanksgivingDayTest extends JapanBaseTestCase implements HolidayTest * Tests Labor Thanksgiving Day after 1948. Labor Thanksgiving Day is held on November 23rd and established since * 1948. * - * @throws Exception + * @throws \Exception */ public function testLabourThanksgivingDayOnAfter1948(): void { @@ -48,7 +45,7 @@ public function testLabourThanksgivingDayOnAfter1948(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-11-23", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-11-23", new \DateTimeZone(self::TIMEZONE)) ); } @@ -56,7 +53,7 @@ public function testLabourThanksgivingDayOnAfter1948(): void * Tests Labor Thanksgiving Day after 1948 substituted next working day (when Labor Thanksgiving Day falls on a * Sunday). * - * @throws Exception + * @throws \Exception */ public function testLabourThanksgivingDayOnAfter1948SubstitutedNextWorkingDay(): void { @@ -65,7 +62,7 @@ public function testLabourThanksgivingDayOnAfter1948SubstitutedNextWorkingDay(): self::REGION, self::SUBSTITUTE_PREFIX.self::HOLIDAY, $year, - new DateTime("$year-11-24", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-11-24", new \DateTimeZone(self::TIMEZONE)) ); } @@ -73,7 +70,7 @@ public function testLabourThanksgivingDayOnAfter1948SubstitutedNextWorkingDay(): * Tests Labor Thanksgiving Day before 1948. Labor Thanksgiving Day is held on November 23rd and established since * 1948. * - * @throws Exception + * @throws \Exception */ public function testLabourThanksgivingDayBefore1948(): void { @@ -87,7 +84,7 @@ public function testLabourThanksgivingDayBefore1948(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -102,7 +99,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Japan/MarineDayTest.php b/tests/Japan/MarineDayTest.php index 1f22f8b82..e200b5e51 100644 --- a/tests/Japan/MarineDayTest.php +++ b/tests/Japan/MarineDayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Japan; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -38,7 +35,7 @@ class MarineDayTest extends JapanBaseTestCase implements HolidayTestCase /** * Tests Marine Day in 2021. Marine Day in 2021 is July 22th for rescheduled Olympic Games after COVID-19. * - * @throws Exception + * @throws \Exception */ public function testMarineDayIn2021(): void { @@ -47,7 +44,7 @@ public function testMarineDayIn2021(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-7-22", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-7-22", new \DateTimeZone(self::TIMEZONE)) ); } @@ -55,7 +52,7 @@ public function testMarineDayIn2021(): void * Tests Marine Day after 2003. Marine Day was established since 1996 on July 20th. After 2003 it was changed * to be the third monday of July. * - * @throws Exception + * @throws \Exception */ public function testMarineDayOnAfter2003(): void { @@ -69,7 +66,7 @@ public function testMarineDayOnAfter2003(): void self::REGION, self::HOLIDAY, $year, - new DateTime("third monday of july $year", new DateTimeZone(self::TIMEZONE)) + new \DateTime("third monday of july $year", new \DateTimeZone(self::TIMEZONE)) ); } @@ -77,7 +74,7 @@ public function testMarineDayOnAfter2003(): void * Tests Marine Day between 1996 and 2003. Marine Day was established since 1996 on July 20th. After 2003 it was * changed to be the third monday of July. * - * @throws Exception + * @throws \Exception */ public function testMarineDayBetween1996And2003(): void { @@ -86,14 +83,14 @@ public function testMarineDayBetween1996And2003(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-7-20", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-7-20", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests Marine Day between 1996 and 2003 substituted next working day (when Marine Day falls on a Sunday). * - * @throws Exception + * @throws \Exception */ public function testMarineDayBetween1996And2003SubstitutedNextWorkingDay(): void { @@ -102,7 +99,7 @@ public function testMarineDayBetween1996And2003SubstitutedNextWorkingDay(): void self::REGION, self::SUBSTITUTE_PREFIX.self::HOLIDAY, $year, - new DateTime("$year-7-21", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-7-21", new \DateTimeZone(self::TIMEZONE)) ); } @@ -110,7 +107,7 @@ public function testMarineDayBetween1996And2003SubstitutedNextWorkingDay(): void * Tests Marine Day before 1996. Marine Day was established since 1996 on July 20th. After 2003 it was changed * to be the third monday of July. * - * @throws Exception + * @throws \Exception */ public function testMarineDayBefore1996(): void { @@ -124,7 +121,7 @@ public function testMarineDayBefore1996(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -139,7 +136,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Japan/MountainDayTest.php b/tests/Japan/MountainDayTest.php index 4f29af8e5..b48b23aa2 100644 --- a/tests/Japan/MountainDayTest.php +++ b/tests/Japan/MountainDayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Japan; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -38,7 +35,7 @@ class MountainDayTest extends JapanBaseTestCase implements HolidayTestCase /** * Tests Mountain Day in 2021. Mountain Day in 2021 is August 8th for rescheduled Olympic Games after COVID-19. * - * @throws Exception + * @throws \Exception */ public function testMountainDayIn2021(): void { @@ -47,14 +44,14 @@ public function testMountainDayIn2021(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-8-8", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-8-8", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests Mountain Day in 2020. Mountain Day in 2020 is August 10th for the Olympic Games. * - * @throws Exception + * @throws \Exception */ public function testMountainDayIn2020(): void { @@ -63,14 +60,14 @@ public function testMountainDayIn2020(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-8-10", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-8-10", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests Mountain Day after 2016. Mountain Day was established in 2014 and is held from 2016 on August 11th. * - * @throws Exception + * @throws \Exception */ public function testMountainDayOnAfter2016(): void { @@ -79,14 +76,14 @@ public function testMountainDayOnAfter2016(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-8-11", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-8-11", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests Mountain Day after 2016 substituted next working day (when Mountain Day falls on a Sunday). * - * @throws Exception + * @throws \Exception */ public function testMountainDayOnAfter2016SubstitutedNextWorkingDay(): void { @@ -95,14 +92,14 @@ public function testMountainDayOnAfter2016SubstitutedNextWorkingDay(): void self::REGION, self::SUBSTITUTE_PREFIX.self::HOLIDAY, $year, - new DateTime("$year-8-12", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-8-12", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests Mountain Day before 2016. Mountain Day was established in 2014 and is held from 2016 on August 11th. * - * @throws Exception + * @throws \Exception */ public function testMountainDayBefore2016(): void { @@ -116,7 +113,7 @@ public function testMountainDayBefore2016(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -131,7 +128,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Japan/NationalFoundationDayTest.php b/tests/Japan/NationalFoundationDayTest.php index d08e402b2..0ce1ab236 100644 --- a/tests/Japan/NationalFoundationDayTest.php +++ b/tests/Japan/NationalFoundationDayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Japan; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -38,7 +35,7 @@ class NationalFoundationDayTest extends JapanBaseTestCase implements HolidayTest /** * Tests National Foundation Day after 1966. National Foundation day was established after 1966. * - * @throws Exception + * @throws \Exception */ public function testNationalFoundationDayOnAfter1966(): void { @@ -47,7 +44,7 @@ public function testNationalFoundationDayOnAfter1966(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-2-11", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-2-11", new \DateTimeZone(self::TIMEZONE)) ); } @@ -55,7 +52,7 @@ public function testNationalFoundationDayOnAfter1966(): void * Tests National Foundation Day after 1966. substituted next working day (when National Foundation Day falls on a * Sunday). * - * @throws Exception + * @throws \Exception */ public function testNationalFoundationDayOnAfter1966SubstitutedNextWorkingDay(): void { @@ -64,14 +61,14 @@ public function testNationalFoundationDayOnAfter1966SubstitutedNextWorkingDay(): self::REGION, self::SUBSTITUTE_PREFIX.self::HOLIDAY, $year, - new DateTime("$year-2-12", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-2-12", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests National Foundation Day before 1966. National Foundation day was established after 1966. * - * @throws Exception + * @throws \Exception */ public function testNationalFoundationDayBefore1966(): void { @@ -85,7 +82,7 @@ public function testNationalFoundationDayBefore1966(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -100,7 +97,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Japan/NewYearsDayTest.php b/tests/Japan/NewYearsDayTest.php index fbc815aff..5ecfc88bc 100644 --- a/tests/Japan/NewYearsDayTest.php +++ b/tests/Japan/NewYearsDayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Japan; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -38,7 +35,7 @@ class NewYearsDayTest extends JapanBaseTestCase implements HolidayTestCase /** * Tests New Years Day after 1948. New Years Day was established after 1948. * - * @throws Exception + * @throws \Exception */ public function testNewYearsDayOnAfter1948(): void { @@ -47,14 +44,14 @@ public function testNewYearsDayOnAfter1948(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-1-1", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-1-1", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests New Years Day after 1948 substituted next working day (when New Years Day falls on a Sunday). * - * @throws Exception + * @throws \Exception */ public function testNewYearsDayOnAfter1948SubstitutedNextWorkingDay(): void { @@ -63,14 +60,14 @@ public function testNewYearsDayOnAfter1948SubstitutedNextWorkingDay(): void self::REGION, self::SUBSTITUTE_PREFIX.self::HOLIDAY, $year, - new DateTime("$year-1-2", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-1-2", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests New Years Day before 1948. New Years Day was established after 1948. * - * @throws Exception + * @throws \Exception */ public function testNewYearsDayBefore1948(): void { @@ -84,7 +81,7 @@ public function testNewYearsDayBefore1948(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -99,7 +96,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Japan/PublicBridgeDayTest.php b/tests/Japan/PublicBridgeDayTest.php index c99e49c7b..e70d9c1cb 100644 --- a/tests/Japan/PublicBridgeDayTest.php +++ b/tests/Japan/PublicBridgeDayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Japan; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -46,7 +43,7 @@ protected function setUp(): void /** * Tests public bridge days. * - * @throws Exception + * @throws \Exception */ public function testPublicBridgeDay(): void { @@ -54,13 +51,13 @@ public function testPublicBridgeDay(): void self::REGION, self::HOLIDAY.'1', $this->year, - new DateTime("$this->year-4-30", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$this->year-4-30", new \DateTimeZone(self::TIMEZONE)) ); $this->assertHoliday( self::REGION, self::HOLIDAY.'2', $this->year, - new DateTime("$this->year-5-2", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$this->year-5-2", new \DateTimeZone(self::TIMEZONE)) ); } diff --git a/tests/Japan/RespectForTheAgedDayTest.php b/tests/Japan/RespectForTheAgedDayTest.php index 3c98b810e..cbac1b177 100644 --- a/tests/Japan/RespectForTheAgedDayTest.php +++ b/tests/Japan/RespectForTheAgedDayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Japan; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -39,7 +36,7 @@ class RespectForTheAgedDayTest extends JapanBaseTestCase implements HolidayTestC * Tests Respect for the Aged Day after 2003. Respect for the Aged Day was established since 1996 on September * 15th. After 2003 it was changed to be the third monday of September. * - * @throws Exception + * @throws \Exception */ public function testRespectForTheAgedDayOnAfter2003(): void { @@ -48,7 +45,7 @@ public function testRespectForTheAgedDayOnAfter2003(): void self::REGION, self::HOLIDAY, $year, - new DateTime("third monday of september $year", new DateTimeZone(self::TIMEZONE)) + new \DateTime("third monday of september $year", new \DateTimeZone(self::TIMEZONE)) ); } @@ -56,7 +53,7 @@ public function testRespectForTheAgedDayOnAfter2003(): void * Tests Respect for the Aged Day between 1996 and 2003. Respect for the Aged Day was established since 1996 on * September 15th. After 2003 it was changed to be the third monday of September. * - * @throws Exception + * @throws \Exception */ public function testRespectForTheAgedDayBetween1996And2003(): void { @@ -65,7 +62,7 @@ public function testRespectForTheAgedDayBetween1996And2003(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-9-15", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-9-15", new \DateTimeZone(self::TIMEZONE)) ); } @@ -73,7 +70,7 @@ public function testRespectForTheAgedDayBetween1996And2003(): void * Tests Respect for the Aged Day between 1996 and 2003 substituted next working day (when Respect for the Aged Day * falls on a Sunday). * - * @throws Exception + * @throws \Exception */ public function testRespectForTheAgedDayBetween1996And2003SubstitutedNextWorkingDay(): void { @@ -82,7 +79,7 @@ public function testRespectForTheAgedDayBetween1996And2003SubstitutedNextWorking self::REGION, self::SUBSTITUTE_PREFIX.self::HOLIDAY, $year, - new DateTime("$year-9-16", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-9-16", new \DateTimeZone(self::TIMEZONE)) ); } @@ -90,7 +87,7 @@ public function testRespectForTheAgedDayBetween1996And2003SubstitutedNextWorking * Tests Respect for the Aged Day before 1996. Respect for the Aged Day was established since 1996 on September * 15th. After 2003 it was changed to be the third monday of September. * - * @throws Exception + * @throws \Exception */ public function testRespectForTheAgedDayBefore1996(): void { @@ -104,7 +101,7 @@ public function testRespectForTheAgedDayBefore1996(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -119,7 +116,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Japan/ShowaDayTest.php b/tests/Japan/ShowaDayTest.php index 2c131bc75..0d303b350 100644 --- a/tests/Japan/ShowaDayTest.php +++ b/tests/Japan/ShowaDayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Japan; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -38,7 +35,7 @@ class ShowaDayTest extends JapanBaseTestCase implements HolidayTestCase /** * Tests the holiday defined in the test on or after establishment. * - * @throws Exception + * @throws \Exception */ public function testHolidayOnAfter2007(): void { @@ -47,14 +44,14 @@ public function testHolidayOnAfter2007(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-4-29", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-4-29", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests the holiday defined in the test on or after the establishment and substituted next working day. * - * @throws Exception + * @throws \Exception */ public function testHolidayOnAfterEstablishmentSubstitutedNextWorkingDay(): void { @@ -63,14 +60,14 @@ public function testHolidayOnAfterEstablishmentSubstitutedNextWorkingDay(): void self::REGION, self::SUBSTITUTE_PREFIX.self::HOLIDAY, $year, - new DateTime("$year-4-30", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-4-30", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests the holiday defined in the test before establishment. * - * @throws Exception + * @throws \Exception */ public function testHolidayBeforeEstablishment(): void { @@ -84,7 +81,7 @@ public function testHolidayBeforeEstablishment(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -99,7 +96,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Japan/SportsDayTest.php b/tests/Japan/SportsDayTest.php index 1b0f4fb66..d9b678e20 100644 --- a/tests/Japan/SportsDayTest.php +++ b/tests/Japan/SportsDayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Japan; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -39,7 +36,7 @@ class SportsDayTest extends JapanBaseTestCase implements HolidayTestCase * Tests Health And Sports Day in 2021. Health And Sports Day in 2021 is July 23th for rescheduled Olympic Games * after COVID-19. * - * @throws Exception + * @throws \Exception */ public function testSportsDayIn2021(): void { @@ -48,14 +45,14 @@ public function testSportsDayIn2021(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-7-23", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-7-23", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests Health And Sports Day in 2020. Health And Sports Day in 2020 is July 24th for the Olympic Games. * - * @throws Exception + * @throws \Exception */ public function testSportsDayIn2020(): void { @@ -64,7 +61,7 @@ public function testSportsDayIn2020(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-7-24", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-7-24", new \DateTimeZone(self::TIMEZONE)) ); } @@ -72,7 +69,7 @@ public function testSportsDayIn2020(): void * Tests Health And Sports Day after 2000. Health And Sports Day was established since 1996 on October 10th. After * 2000 it was changed to be the second monday of October. * - * @throws Exception + * @throws \Exception */ public function testSportsDayOnAfter2000(): void { @@ -81,7 +78,7 @@ public function testSportsDayOnAfter2000(): void self::REGION, self::HOLIDAY, $year, - new DateTime("second monday of october $year", new DateTimeZone(self::TIMEZONE)) + new \DateTime("second monday of october $year", new \DateTimeZone(self::TIMEZONE)) ); } @@ -89,7 +86,7 @@ public function testSportsDayOnAfter2000(): void * Tests Health And Sports Day between 1996 and 2000. Health And Sports Day was established since 1996 on October * 10th. After 2000 it was changed to be the second monday of October. * - * @throws Exception + * @throws \Exception */ public function testSportsDayBetween1996And2000(): void { @@ -98,7 +95,7 @@ public function testSportsDayBetween1996And2000(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-10-10", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-10-10", new \DateTimeZone(self::TIMEZONE)) ); } @@ -106,7 +103,7 @@ public function testSportsDayBetween1996And2000(): void * Tests Health And Sports Day between 1996 and 2000 substituted next working day (when Health And Sports Day falls * on a Sunday). * - * @throws Exception + * @throws \Exception */ public function testSportsDayBetween1996And2000SubstitutedNextWorkingDay(): void { @@ -115,7 +112,7 @@ public function testSportsDayBetween1996And2000SubstitutedNextWorkingDay(): void self::REGION, self::SUBSTITUTE_PREFIX.self::HOLIDAY, $year, - new DateTime("$year-10-11", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-10-11", new \DateTimeZone(self::TIMEZONE)) ); } @@ -123,7 +120,7 @@ public function testSportsDayBetween1996And2000SubstitutedNextWorkingDay(): void * Tests Health And Sports Day before. Health And Sports Day was established since 1996 on October 10th. After * 2000 it was changed to be the second monday of October. * - * @throws Exception + * @throws \Exception */ public function testSportsDayBefore1996(): void { @@ -138,7 +135,7 @@ public function testSportsDayBefore1996(): void * Tests the translated name of the holiday defined in this test. * 1996-2019:Health And Sports Day. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -154,7 +151,7 @@ public function testTranslation(): void * Tests the translated name of the holiday defined in this test. * 2020 - :Sports Day. * - * @throws Exception + * @throws \Exception */ public function testTranslationFrom2020(): void { @@ -170,7 +167,7 @@ public function testTranslationFrom2020(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Japan/VernalEquinoxDayTest.php b/tests/Japan/VernalEquinoxDayTest.php index 19d90f7b0..0a968c8a3 100644 --- a/tests/Japan/VernalEquinoxDayTest.php +++ b/tests/Japan/VernalEquinoxDayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Japan; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -42,7 +39,7 @@ class VernalEquinoxDayTest extends JapanBaseTestCase implements HolidayTestCase * * After 2150 no calculations are available yet. * - * @throws Exception + * @throws \Exception */ public function testVernalEquinoxDayOnAfter2150(): void { @@ -62,7 +59,7 @@ public function testVernalEquinoxDayOnAfter2150(): void * @param int $month month (number) of example data to be tested * @param int $day day of the month (number) of example data to be tested * - * @throws Exception + * @throws \Exception */ public function testVernalEquinoxDayBetween1948And2150(int $year, int $month, int $day): void { @@ -70,7 +67,7 @@ public function testVernalEquinoxDayBetween1948And2150(int $year, int $month, in self::REGION, self::HOLIDAY, $year, - new DateTime("$year-$month-$day", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-$month-$day", new \DateTimeZone(self::TIMEZONE)) ); } @@ -95,7 +92,7 @@ public function vernalEquinoxHolidaysProvider(): array * of nature and the love of living things. Prior to 1948, the vernal equinox was an imperial ancestor worship * festival called Shunki kōrei-sai (春季皇霊祭). * - * @throws Exception + * @throws \Exception */ public function testVernalEquinoxDayBefore1948(): void { @@ -109,7 +106,7 @@ public function testVernalEquinoxDayBefore1948(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -124,7 +121,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Latvia/ChristmasDayTest.php b/tests/Latvia/ChristmasDayTest.php index 3aa83584e..2c4d76acb 100644 --- a/tests/Latvia/ChristmasDayTest.php +++ b/tests/Latvia/ChristmasDayTest.php @@ -15,7 +15,6 @@ namespace Yasumi\tests\Latvia; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,7 +33,7 @@ class ChristmasDayTest extends LatviaBaseTestCase implements HolidayTestCase /** * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function holidayDataProvider(): array { @@ -52,7 +51,7 @@ public function testHoliday(int $year, \DateTimeInterface $expected): void /** * {@inheritdoc} * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -67,7 +66,7 @@ public function testTranslation(): void /** * {@inheritdoc} * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Latvia/ChristmasEveDayTest.php b/tests/Latvia/ChristmasEveDayTest.php index 68778223c..45261b314 100644 --- a/tests/Latvia/ChristmasEveDayTest.php +++ b/tests/Latvia/ChristmasEveDayTest.php @@ -15,7 +15,6 @@ namespace Yasumi\tests\Latvia; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,7 +33,7 @@ class ChristmasEveDayTest extends LatviaBaseTestCase implements HolidayTestCase /** * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function holidayDataProvider(): array { @@ -52,7 +51,7 @@ public function testHoliday(int $year, \DateTimeInterface $expected): void /** * {@inheritdoc} * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -67,7 +66,7 @@ public function testTranslation(): void /** * {@inheritdoc} * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Latvia/EasterDayTest.php b/tests/Latvia/EasterDayTest.php index 76676758d..250b70774 100644 --- a/tests/Latvia/EasterDayTest.php +++ b/tests/Latvia/EasterDayTest.php @@ -15,9 +15,6 @@ namespace Yasumi\tests\Latvia; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -36,7 +33,7 @@ class EasterDayTest extends LatviaBaseTestCase implements HolidayTestCase /** * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function holidayDataProvider(): array { @@ -51,7 +48,7 @@ public function holidayDataProvider(): array * @param int $year the year for which the holiday defined in this test needs to be tested * @param string $expected the expected date * - * @throws Exception + * @throws \Exception */ public function testHoliday(int $year, string $expected): void { @@ -59,14 +56,14 @@ public function testHoliday(int $year, string $expected): void self::REGION, self::HOLIDAY, $year, - new DateTime($expected, new DateTimeZone(self::TIMEZONE)) + new \DateTime($expected, new \DateTimeZone(self::TIMEZONE)) ); } /** * {@inheritdoc} * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -81,7 +78,7 @@ public function testTranslation(): void /** * {@inheritdoc} * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Latvia/EasterMondayDayTest.php b/tests/Latvia/EasterMondayDayTest.php index 7bf4b20ae..c723341bb 100644 --- a/tests/Latvia/EasterMondayDayTest.php +++ b/tests/Latvia/EasterMondayDayTest.php @@ -15,9 +15,6 @@ namespace Yasumi\tests\Latvia; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -36,7 +33,7 @@ class EasterMondayDayTest extends LatviaBaseTestCase implements HolidayTestCase /** * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function holidayDataProvider(): array { @@ -51,7 +48,7 @@ public function holidayDataProvider(): array * @param int $year the year for which the holiday defined in this test needs to be tested * @param string $expected the expected date * - * @throws Exception + * @throws \Exception */ public function testHoliday(int $year, string $expected): void { @@ -59,14 +56,14 @@ public function testHoliday(int $year, string $expected): void self::REGION, self::HOLIDAY, $year, - new DateTime($expected, new DateTimeZone(self::TIMEZONE)) + new \DateTime($expected, new \DateTimeZone(self::TIMEZONE)) ); } /** * {@inheritdoc} * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -81,7 +78,7 @@ public function testTranslation(): void /** * {@inheritdoc} * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Latvia/GoodFridayDayTest.php b/tests/Latvia/GoodFridayDayTest.php index cd67382cf..cf3ad5cbe 100644 --- a/tests/Latvia/GoodFridayDayTest.php +++ b/tests/Latvia/GoodFridayDayTest.php @@ -15,9 +15,6 @@ namespace Yasumi\tests\Latvia; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -36,7 +33,7 @@ class GoodFridayDayTest extends LatviaBaseTestCase implements HolidayTestCase /** * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function holidayDataProvider(): array { @@ -51,7 +48,7 @@ public function holidayDataProvider(): array * @param int $year the year for which the holiday defined in this test needs to be tested * @param string $expected the expected date * - * @throws Exception + * @throws \Exception */ public function testHoliday(int $year, string $expected): void { @@ -59,14 +56,14 @@ public function testHoliday(int $year, string $expected): void self::REGION, self::HOLIDAY, $year, - new DateTime($expected, new DateTimeZone(self::TIMEZONE)) + new \DateTime($expected, new \DateTimeZone(self::TIMEZONE)) ); } /** * {@inheritdoc} * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -81,7 +78,7 @@ public function testTranslation(): void /** * {@inheritdoc} * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Latvia/InternationalWorkersDayTest.php b/tests/Latvia/InternationalWorkersDayTest.php index 86841f009..37b9e3db2 100644 --- a/tests/Latvia/InternationalWorkersDayTest.php +++ b/tests/Latvia/InternationalWorkersDayTest.php @@ -15,7 +15,6 @@ namespace Yasumi\tests\Latvia; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,7 +33,7 @@ class InternationalWorkersDayTest extends LatviaBaseTestCase implements HolidayT /** * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function holidayDataProvider(): array { @@ -52,7 +51,7 @@ public function testHoliday(int $year, \DateTimeInterface $expected): void /** * {@inheritdoc} * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -67,7 +66,7 @@ public function testTranslation(): void /** * {@inheritdoc} * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Latvia/LatviaTest.php b/tests/Latvia/LatviaTest.php index eb87dd5a5..63de017ff 100644 --- a/tests/Latvia/LatviaTest.php +++ b/tests/Latvia/LatviaTest.php @@ -15,7 +15,6 @@ namespace Yasumi\tests\Latvia; -use ReflectionException; use Yasumi\Holiday; use Yasumi\Provider\Latvia; use Yasumi\tests\ProviderTestCase; @@ -102,7 +101,7 @@ public function testOtherHolidays(): void } /** - * @throws ReflectionException + * @throws \ReflectionException * @throws \Exception */ public function testSources(): void diff --git a/tests/Latvia/MidsummerEveDayTest.php b/tests/Latvia/MidsummerEveDayTest.php index 127fac9f2..dfacfc99e 100644 --- a/tests/Latvia/MidsummerEveDayTest.php +++ b/tests/Latvia/MidsummerEveDayTest.php @@ -15,7 +15,6 @@ namespace Yasumi\tests\Latvia; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,7 +33,7 @@ class MidsummerEveDayTest extends LatviaBaseTestCase implements HolidayTestCase /** * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function holidayDataProvider(): array { @@ -52,7 +51,7 @@ public function testHoliday(int $year, \DateTimeInterface $expected): void /** * {@inheritdoc} * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -67,7 +66,7 @@ public function testTranslation(): void /** * {@inheritdoc} * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Latvia/NewYearsDayTest.php b/tests/Latvia/NewYearsDayTest.php index a035e2d8c..9e0d391e5 100644 --- a/tests/Latvia/NewYearsDayTest.php +++ b/tests/Latvia/NewYearsDayTest.php @@ -15,7 +15,6 @@ namespace Yasumi\tests\Latvia; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,7 +33,7 @@ class NewYearsDayTest extends LatviaBaseTestCase implements HolidayTestCase /** * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function holidayDataProvider(): array { @@ -52,7 +51,7 @@ public function testHoliday(int $year, \DateTimeInterface $expected): void /** * {@inheritdoc} * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -67,7 +66,7 @@ public function testTranslation(): void /** * {@inheritdoc} * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Latvia/NewYearsEveDayTest.php b/tests/Latvia/NewYearsEveDayTest.php index 855de4afd..5e6491e64 100644 --- a/tests/Latvia/NewYearsEveDayTest.php +++ b/tests/Latvia/NewYearsEveDayTest.php @@ -15,7 +15,6 @@ namespace Yasumi\tests\Latvia; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,7 +33,7 @@ class NewYearsEveDayTest extends LatviaBaseTestCase implements HolidayTestCase /** * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function holidayDataProvider(): array { @@ -52,7 +51,7 @@ public function testHoliday(int $year, \DateTimeInterface $expected): void /** * {@inheritdoc} * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -67,7 +66,7 @@ public function testTranslation(): void /** * {@inheritdoc} * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Latvia/ProclamationOfTheRepublicOfLatviaDayTest.php b/tests/Latvia/ProclamationOfTheRepublicOfLatviaDayTest.php index f53cd107b..779b3cb6a 100644 --- a/tests/Latvia/ProclamationOfTheRepublicOfLatviaDayTest.php +++ b/tests/Latvia/ProclamationOfTheRepublicOfLatviaDayTest.php @@ -15,9 +15,6 @@ namespace Yasumi\tests\Latvia; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\Provider\Latvia; use Yasumi\tests\HolidayTestCase; @@ -37,7 +34,7 @@ class ProclamationOfTheRepublicOfLatviaDayTest extends LatviaBaseTestCase implem /** * Test if holiday is not defined before proclamation. * - * @throws Exception + * @throws \Exception */ public function testNotHoliday(): void { @@ -51,7 +48,7 @@ public function testNotHoliday(): void /** * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function holidayDataProvider(): array { @@ -72,7 +69,7 @@ public function holidayDataProvider(): array * @param int $year the year for which the holiday defined in this test needs to be tested * @param string $expected the expected date * - * @throws Exception + * @throws \Exception */ public function testHoliday(int $year, string $expected): void { @@ -80,14 +77,14 @@ public function testHoliday(int $year, string $expected): void self::REGION, self::HOLIDAY, $year, - new DateTime($expected, new DateTimeZone(self::TIMEZONE)) + new \DateTime($expected, new \DateTimeZone(self::TIMEZONE)) ); } /** * {@inheritdoc} * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -105,7 +102,7 @@ public function testTranslation(): void /** * {@inheritdoc} * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Latvia/RestorationOfIndependenceDayTest.php b/tests/Latvia/RestorationOfIndependenceDayTest.php index 769c5d342..c1352f652 100644 --- a/tests/Latvia/RestorationOfIndependenceDayTest.php +++ b/tests/Latvia/RestorationOfIndependenceDayTest.php @@ -15,9 +15,6 @@ namespace Yasumi\tests\Latvia; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\Provider\Latvia; use Yasumi\tests\HolidayTestCase; @@ -37,7 +34,7 @@ class RestorationOfIndependenceDayTest extends LatviaBaseTestCase implements Hol /** * Test if holiday is not defined before restoration. * - * @throws Exception + * @throws \Exception */ public function testNotHoliday(): void { @@ -51,7 +48,7 @@ public function testNotHoliday(): void /** * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function holidayDataProvider(): array { @@ -72,7 +69,7 @@ public function holidayDataProvider(): array * @param int $year the year for which the holiday defined in this test needs to be tested * @param string $expected the expected date * - * @throws Exception + * @throws \Exception */ public function testHoliday(int $year, string $expected): void { @@ -80,14 +77,14 @@ public function testHoliday(int $year, string $expected): void self::REGION, self::HOLIDAY, $year, - new DateTime($expected, new DateTimeZone(self::TIMEZONE)) + new \DateTime($expected, new \DateTimeZone(self::TIMEZONE)) ); } /** * {@inheritdoc} * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -105,7 +102,7 @@ public function testTranslation(): void /** * {@inheritdoc} * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Latvia/SecondChristmasDayTest.php b/tests/Latvia/SecondChristmasDayTest.php index cffb75249..ad2550dd1 100644 --- a/tests/Latvia/SecondChristmasDayTest.php +++ b/tests/Latvia/SecondChristmasDayTest.php @@ -15,7 +15,6 @@ namespace Yasumi\tests\Latvia; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,7 +33,7 @@ class SecondChristmasDayTest extends LatviaBaseTestCase implements HolidayTestCa /** * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function holidayDataProvider(): array { @@ -52,7 +51,7 @@ public function testHoliday(int $year, \DateTimeInterface $expected): void /** * {@inheritdoc} * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -67,7 +66,7 @@ public function testTranslation(): void /** * {@inheritdoc} * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Latvia/StJohnsDayTest.php b/tests/Latvia/StJohnsDayTest.php index 367145fa4..81ddc9259 100644 --- a/tests/Latvia/StJohnsDayTest.php +++ b/tests/Latvia/StJohnsDayTest.php @@ -15,7 +15,6 @@ namespace Yasumi\tests\Latvia; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,7 +33,7 @@ class StJohnsDayTest extends LatviaBaseTestCase implements HolidayTestCase /** * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function holidayDataProvider(): array { @@ -52,7 +51,7 @@ public function testHoliday(int $year, \DateTimeInterface $expected): void /** * {@inheritdoc} * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -67,7 +66,7 @@ public function testTranslation(): void /** * {@inheritdoc} * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Lithuania/AllSaintsDayTest.php b/tests/Lithuania/AllSaintsDayTest.php index 116f72c3f..18b253176 100644 --- a/tests/Lithuania/AllSaintsDayTest.php +++ b/tests/Lithuania/AllSaintsDayTest.php @@ -15,7 +15,6 @@ namespace Yasumi\tests\Lithuania; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,7 +33,7 @@ class AllSaintsDayTest extends LithuaniaBaseTestCase implements HolidayTestCase /** * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function holidayDataProvider(): array { @@ -52,7 +51,7 @@ public function testHoliday(int $year, \DateTimeInterface $expected): void /** * {@inheritdoc} * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -67,7 +66,7 @@ public function testTranslation(): void /** * {@inheritdoc} * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Lithuania/AllSoulsDayTest.php b/tests/Lithuania/AllSoulsDayTest.php index d8a008a9e..6a1e6d11b 100644 --- a/tests/Lithuania/AllSoulsDayTest.php +++ b/tests/Lithuania/AllSoulsDayTest.php @@ -15,9 +15,6 @@ namespace Yasumi\tests\Lithuania; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\Provider\Lithuania; use Yasumi\tests\HolidayTestCase; @@ -35,7 +32,7 @@ class AllSoulsDayTest extends LithuaniaBaseTestCase implements HolidayTestCase public const HOLIDAY = 'allSoulsDay'; /** - * @throws Exception + * @throws \Exception */ public function testHolidayBeforeAnnounce(): void { @@ -49,7 +46,7 @@ public function testHolidayBeforeAnnounce(): void /** * Test if holiday is defined after restoration. * - * @throws Exception + * @throws \Exception */ public function testHolidayAfterAnnounce(): void { @@ -59,14 +56,14 @@ public function testHolidayAfterAnnounce(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-11-02", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-11-02", new \DateTimeZone(self::TIMEZONE)) ); } /** * {@inheritdoc} * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -81,7 +78,7 @@ public function testTranslation(): void /** * {@inheritdoc} * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Lithuania/AssumptionOfMaryDayTest.php b/tests/Lithuania/AssumptionOfMaryDayTest.php index e97513224..ba55b4265 100644 --- a/tests/Lithuania/AssumptionOfMaryDayTest.php +++ b/tests/Lithuania/AssumptionOfMaryDayTest.php @@ -15,7 +15,6 @@ namespace Yasumi\tests\Lithuania; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,7 +33,7 @@ class AssumptionOfMaryDayTest extends LithuaniaBaseTestCase implements HolidayTe /** * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function holidayDataProvider(): array { @@ -52,7 +51,7 @@ public function testHoliday(int $year, \DateTimeInterface $expected): void /** * {@inheritdoc} * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -67,7 +66,7 @@ public function testTranslation(): void /** * {@inheritdoc} * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Lithuania/ChristmasDayTest.php b/tests/Lithuania/ChristmasDayTest.php index d2d5cee36..1a4e40e13 100644 --- a/tests/Lithuania/ChristmasDayTest.php +++ b/tests/Lithuania/ChristmasDayTest.php @@ -15,7 +15,6 @@ namespace Yasumi\tests\Lithuania; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,7 +33,7 @@ class ChristmasDayTest extends LithuaniaBaseTestCase implements HolidayTestCase /** * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function holidayDataProvider(): array { @@ -52,7 +51,7 @@ public function testHoliday(int $year, \DateTimeInterface $expected): void /** * {@inheritdoc} * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -67,7 +66,7 @@ public function testTranslation(): void /** * {@inheritdoc} * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Lithuania/ChristmasEveDayTest.php b/tests/Lithuania/ChristmasEveDayTest.php index 48f88b828..09a0fc5df 100644 --- a/tests/Lithuania/ChristmasEveDayTest.php +++ b/tests/Lithuania/ChristmasEveDayTest.php @@ -15,7 +15,6 @@ namespace Yasumi\tests\Lithuania; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,7 +33,7 @@ class ChristmasEveDayTest extends LithuaniaBaseTestCase implements HolidayTestCa /** * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function holidayDataProvider(): array { @@ -52,7 +51,7 @@ public function testHoliday(int $year, \DateTimeInterface $expected): void /** * {@inheritdoc} * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -67,7 +66,7 @@ public function testTranslation(): void /** * {@inheritdoc} * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Lithuania/EasterDayTest.php b/tests/Lithuania/EasterDayTest.php index b7dfce109..3aa21e574 100644 --- a/tests/Lithuania/EasterDayTest.php +++ b/tests/Lithuania/EasterDayTest.php @@ -15,9 +15,6 @@ namespace Yasumi\tests\Lithuania; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -36,7 +33,7 @@ class EasterDayTest extends LithuaniaBaseTestCase implements HolidayTestCase /** * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function holidayDataProvider(): array { @@ -51,7 +48,7 @@ public function holidayDataProvider(): array * @param int $year the year for which the holiday defined in this test needs to be tested * @param string $expected the expected date * - * @throws Exception + * @throws \Exception */ public function testHoliday(int $year, string $expected): void { @@ -59,14 +56,14 @@ public function testHoliday(int $year, string $expected): void self::REGION, self::HOLIDAY, $year, - new DateTime($expected, new DateTimeZone(self::TIMEZONE)) + new \DateTime($expected, new \DateTimeZone(self::TIMEZONE)) ); } /** * {@inheritdoc} * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -81,7 +78,7 @@ public function testTranslation(): void /** * {@inheritdoc} * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Lithuania/EasterMondayDayTest.php b/tests/Lithuania/EasterMondayDayTest.php index 8a42568d3..fb0494df8 100644 --- a/tests/Lithuania/EasterMondayDayTest.php +++ b/tests/Lithuania/EasterMondayDayTest.php @@ -15,9 +15,6 @@ namespace Yasumi\tests\Lithuania; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -36,7 +33,7 @@ class EasterMondayDayTest extends LithuaniaBaseTestCase implements HolidayTestCa /** * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function holidayDataProvider(): array { @@ -51,7 +48,7 @@ public function holidayDataProvider(): array * @param int $year the year for which the holiday defined in this test needs to be tested * @param string $expected the expected date * - * @throws Exception + * @throws \Exception */ public function testHoliday(int $year, string $expected): void { @@ -59,14 +56,14 @@ public function testHoliday(int $year, string $expected): void self::REGION, self::HOLIDAY, $year, - new DateTime($expected, new DateTimeZone(self::TIMEZONE)) + new \DateTime($expected, new \DateTimeZone(self::TIMEZONE)) ); } /** * {@inheritdoc} * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -81,7 +78,7 @@ public function testTranslation(): void /** * {@inheritdoc} * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Lithuania/InternationalWorkersDayTest.php b/tests/Lithuania/InternationalWorkersDayTest.php index 6ce049ce7..24e5e077f 100644 --- a/tests/Lithuania/InternationalWorkersDayTest.php +++ b/tests/Lithuania/InternationalWorkersDayTest.php @@ -15,7 +15,6 @@ namespace Yasumi\tests\Lithuania; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,7 +33,7 @@ class InternationalWorkersDayTest extends LithuaniaBaseTestCase implements Holid /** * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function holidayDataProvider(): array { @@ -52,7 +51,7 @@ public function testHoliday(int $year, \DateTimeInterface $expected): void /** * {@inheritdoc} * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -67,7 +66,7 @@ public function testTranslation(): void /** * {@inheritdoc} * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Lithuania/LithuaniaTest.php b/tests/Lithuania/LithuaniaTest.php index 9213e832c..c0a5f1cb4 100644 --- a/tests/Lithuania/LithuaniaTest.php +++ b/tests/Lithuania/LithuaniaTest.php @@ -15,7 +15,6 @@ namespace Yasumi\tests\Lithuania; -use ReflectionException; use Yasumi\Holiday; use Yasumi\Provider\Lithuania; @@ -104,7 +103,7 @@ public function testOtherHolidays(): void } /** - * @throws ReflectionException + * @throws \ReflectionException * @throws \Exception */ public function testSources(): void diff --git a/tests/Lithuania/NewYearsDayTest.php b/tests/Lithuania/NewYearsDayTest.php index e3163cffa..01135a40b 100644 --- a/tests/Lithuania/NewYearsDayTest.php +++ b/tests/Lithuania/NewYearsDayTest.php @@ -15,7 +15,6 @@ namespace Yasumi\tests\Lithuania; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,7 +33,7 @@ class NewYearsDayTest extends LithuaniaBaseTestCase implements HolidayTestCase /** * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function holidayDataProvider(): array { @@ -52,7 +51,7 @@ public function testHoliday(int $year, \DateTimeInterface $expected): void /** * {@inheritdoc} * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -67,7 +66,7 @@ public function testTranslation(): void /** * {@inheritdoc} * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Lithuania/RestorationOfIndependenceOfLithuaniaDayTest.php b/tests/Lithuania/RestorationOfIndependenceOfLithuaniaDayTest.php index 7c7ce62b4..1603185af 100644 --- a/tests/Lithuania/RestorationOfIndependenceOfLithuaniaDayTest.php +++ b/tests/Lithuania/RestorationOfIndependenceOfLithuaniaDayTest.php @@ -15,9 +15,6 @@ namespace Yasumi\tests\Lithuania; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\Provider\Lithuania; use Yasumi\tests\HolidayTestCase; @@ -37,7 +34,7 @@ class RestorationOfIndependenceOfLithuaniaDayTest extends LithuaniaBaseTestCase /** * Test if holiday is not defined before restoration. * - * @throws Exception + * @throws \Exception */ public function testHolidayBeforeRestoration(): void { @@ -51,7 +48,7 @@ public function testHolidayBeforeRestoration(): void /** * Test if holiday is defined after restoration. * - * @throws Exception + * @throws \Exception */ public function testHolidayAfterRestoration(): void { @@ -61,14 +58,14 @@ public function testHolidayAfterRestoration(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-03-11", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-03-11", new \DateTimeZone(self::TIMEZONE)) ); } /** * {@inheritdoc} * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -89,7 +86,7 @@ public function testTranslation(): void /** * {@inheritdoc} * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Lithuania/RestorationOfTheStateOfLithuaniaDayTest.php b/tests/Lithuania/RestorationOfTheStateOfLithuaniaDayTest.php index 97b2d4f0b..7ddf7fbe7 100644 --- a/tests/Lithuania/RestorationOfTheStateOfLithuaniaDayTest.php +++ b/tests/Lithuania/RestorationOfTheStateOfLithuaniaDayTest.php @@ -15,9 +15,6 @@ namespace Yasumi\tests\Lithuania; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\Provider\Lithuania; use Yasumi\tests\HolidayTestCase; @@ -37,7 +34,7 @@ class RestorationOfTheStateOfLithuaniaDayTest extends LithuaniaBaseTestCase impl /** * Test if holiday is not defined before restoration. * - * @throws Exception + * @throws \Exception */ public function testHolidayBeforeRestoration(): void { @@ -51,7 +48,7 @@ public function testHolidayBeforeRestoration(): void /** * Test if holiday is defined after restoration. * - * @throws Exception + * @throws \Exception */ public function testHolidayAfterRestoration(): void { @@ -61,14 +58,14 @@ public function testHolidayAfterRestoration(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-02-16", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-02-16", new \DateTimeZone(self::TIMEZONE)) ); } /** * {@inheritdoc} * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -89,7 +86,7 @@ public function testTranslation(): void /** * {@inheritdoc} * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Lithuania/SecondChristmasDayTest.php b/tests/Lithuania/SecondChristmasDayTest.php index 6973f03de..3417d2d66 100644 --- a/tests/Lithuania/SecondChristmasDayTest.php +++ b/tests/Lithuania/SecondChristmasDayTest.php @@ -15,7 +15,6 @@ namespace Yasumi\tests\Lithuania; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,7 +33,7 @@ class SecondChristmasDayTest extends LithuaniaBaseTestCase implements HolidayTes /** * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function holidayDataProvider(): array { @@ -52,7 +51,7 @@ public function testHoliday(int $year, \DateTimeInterface $expected): void /** * {@inheritdoc} * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -67,7 +66,7 @@ public function testTranslation(): void /** * {@inheritdoc} * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Lithuania/StJohnsDayTest.php b/tests/Lithuania/StJohnsDayTest.php index 898d65379..22ef52b58 100644 --- a/tests/Lithuania/StJohnsDayTest.php +++ b/tests/Lithuania/StJohnsDayTest.php @@ -15,7 +15,6 @@ namespace Yasumi\tests\Lithuania; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,7 +33,7 @@ class StJohnsDayTest extends LithuaniaBaseTestCase implements HolidayTestCase /** * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function holidayDataProvider(): array { @@ -52,7 +51,7 @@ public function testHoliday(int $year, \DateTimeInterface $expected): void /** * {@inheritdoc} * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -67,7 +66,7 @@ public function testTranslation(): void /** * {@inheritdoc} * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Lithuania/StatehoodDayTest.php b/tests/Lithuania/StatehoodDayTest.php index 6fff94765..ecc1020c7 100644 --- a/tests/Lithuania/StatehoodDayTest.php +++ b/tests/Lithuania/StatehoodDayTest.php @@ -15,9 +15,6 @@ namespace Yasumi\tests\Lithuania; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\Provider\Lithuania; use Yasumi\tests\HolidayTestCase; @@ -37,7 +34,7 @@ class StatehoodDayTest extends LithuaniaBaseTestCase implements HolidayTestCase /** * Test if holiday is not defined before restoration. * - * @throws Exception + * @throws \Exception */ public function testHolidayBeforeRestoration(): void { @@ -51,7 +48,7 @@ public function testHolidayBeforeRestoration(): void /** * Test if holiday is defined after restoration. * - * @throws Exception + * @throws \Exception */ public function testHolidayAfterRestoration(): void { @@ -61,14 +58,14 @@ public function testHolidayAfterRestoration(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-07-06", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-07-06", new \DateTimeZone(self::TIMEZONE)) ); } /** * {@inheritdoc} * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -89,7 +86,7 @@ public function testTranslation(): void /** * {@inheritdoc} * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Luxembourg/AllSaintsDayTest.php b/tests/Luxembourg/AllSaintsDayTest.php index 2183d6c44..453916e37 100644 --- a/tests/Luxembourg/AllSaintsDayTest.php +++ b/tests/Luxembourg/AllSaintsDayTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\Luxembourg; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,8 +32,8 @@ class AllSaintsDayTest extends LuxembourgBaseTestCase implements HolidayTestCase * * @dataProvider AllSaintsDayDataProvider * - * @param int $year the year for which All Saints' Day needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which All Saints' Day needs to be tested + * @param \DateTime $expected the expected date */ public function testAllSaintsDay(int $year, \DateTimeInterface $expected): void { @@ -45,7 +43,7 @@ public function testAllSaintsDay(int $year, \DateTimeInterface $expected): void /** * Tests translated name of All Saints' Day. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -60,7 +58,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { @@ -72,7 +70,7 @@ public function testHolidayType(): void * * @return array list of test dates for All Saints' Day * - * @throws Exception + * @throws \Exception */ public function AllSaintsDayDataProvider(): array { diff --git a/tests/Luxembourg/AscensionDayTest.php b/tests/Luxembourg/AscensionDayTest.php index 192bd6276..0876b1bdd 100644 --- a/tests/Luxembourg/AscensionDayTest.php +++ b/tests/Luxembourg/AscensionDayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Luxembourg; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -33,7 +30,7 @@ class AscensionDayTest extends LuxembourgBaseTestCase implements HolidayTestCase /** * Tests Ascension Day. * - * @throws Exception + * @throws \Exception */ public function testAscensionDay(): void { @@ -42,14 +39,14 @@ public function testAscensionDay(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-5-16", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-5-16", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests translated name of Ascension Day. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -64,7 +61,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Luxembourg/AssumptionOfMaryTest.php b/tests/Luxembourg/AssumptionOfMaryTest.php index 03498d83e..a66fe32e6 100644 --- a/tests/Luxembourg/AssumptionOfMaryTest.php +++ b/tests/Luxembourg/AssumptionOfMaryTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\Luxembourg; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,8 +32,8 @@ class AssumptionOfMaryTest extends LuxembourgBaseTestCase implements HolidayTest * * @dataProvider HolidayDataProvider * - * @param int $year the year for which the holiday defined in this test needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which the holiday defined in this test needs to be tested + * @param \DateTime $expected the expected date */ public function testHoliday(int $year, \DateTimeInterface $expected): void { @@ -47,7 +45,7 @@ public function testHoliday(int $year, \DateTimeInterface $expected): void * * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function HolidayDataProvider(): array { @@ -57,7 +55,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -72,7 +70,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Luxembourg/ChristmasDayTest.php b/tests/Luxembourg/ChristmasDayTest.php index 2c186e27c..b10133790 100644 --- a/tests/Luxembourg/ChristmasDayTest.php +++ b/tests/Luxembourg/ChristmasDayTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\Luxembourg; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,8 +32,8 @@ class ChristmasDayTest extends LuxembourgBaseTestCase implements HolidayTestCase * * @dataProvider ChristmasDayDataProvider * - * @param int $year the year for which Christmas Day needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which Christmas Day needs to be tested + * @param \DateTime $expected the expected date */ public function testChristmasDay(int $year, \DateTimeInterface $expected): void { @@ -47,7 +45,7 @@ public function testChristmasDay(int $year, \DateTimeInterface $expected): void * * @return array list of test dates for Christmas Day * - * @throws Exception + * @throws \Exception */ public function ChristmasDayDataProvider(): array { @@ -57,7 +55,7 @@ public function ChristmasDayDataProvider(): array /** * Tests translated name of Christmas Day. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -72,7 +70,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Luxembourg/EasterMondayTest.php b/tests/Luxembourg/EasterMondayTest.php index b09e98b5c..38434ee7f 100644 --- a/tests/Luxembourg/EasterMondayTest.php +++ b/tests/Luxembourg/EasterMondayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Luxembourg; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -33,7 +30,7 @@ class EasterMondayTest extends LuxembourgBaseTestCase implements HolidayTestCase /** * Tests Easter Monday. * - * @throws Exception + * @throws \Exception */ public function testEasterMonday(): void { @@ -42,14 +39,14 @@ public function testEasterMonday(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-3-28", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-3-28", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests translated name of Easter Monday. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -64,7 +61,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Luxembourg/EuropeDayTest.php b/tests/Luxembourg/EuropeDayTest.php index 95c35624d..74853c416 100644 --- a/tests/Luxembourg/EuropeDayTest.php +++ b/tests/Luxembourg/EuropeDayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Luxembourg; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -38,7 +35,7 @@ class EuropeDayTest extends LuxembourgBaseTestCase implements HolidayTestCase /** * Tests Europe Day on or after 2019. * - * @throws Exception + * @throws \Exception */ public function testEuropeDayOnAfter2019(): void { @@ -47,14 +44,14 @@ public function testEuropeDayOnAfter2019(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-5-9", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-5-9", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests Europe Day before 2019. * - * @throws Exception + * @throws \Exception */ public function testEuropeDayBefore2019(): void { @@ -68,7 +65,7 @@ public function testEuropeDayBefore2019(): void /** * Tests translated name of Europe Day. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -83,7 +80,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Luxembourg/InternationalWorkersDayTest.php b/tests/Luxembourg/InternationalWorkersDayTest.php index aafa0bcc5..09b86810e 100644 --- a/tests/Luxembourg/InternationalWorkersDayTest.php +++ b/tests/Luxembourg/InternationalWorkersDayTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\Luxembourg; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,8 +32,8 @@ class InternationalWorkersDayTest extends LuxembourgBaseTestCase implements Holi * * @dataProvider InternationalWorkersDayDataProvider * - * @param int $year the year for which International Workers' Day needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which International Workers' Day needs to be tested + * @param \DateTime $expected the expected date */ public function testInternationalWorkersDay(int $year, \DateTimeInterface $expected): void { @@ -45,7 +43,7 @@ public function testInternationalWorkersDay(int $year, \DateTimeInterface $expec /** * Tests translated name of International Workers' Day. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -60,7 +58,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { @@ -72,7 +70,7 @@ public function testHolidayType(): void * * @return array list of test dates for International Workers' Day * - * @throws Exception + * @throws \Exception */ public function InternationalWorkersDayDataProvider(): array { diff --git a/tests/Luxembourg/LuxembourgTest.php b/tests/Luxembourg/LuxembourgTest.php index 8abe1b8da..e9b09c428 100644 --- a/tests/Luxembourg/LuxembourgTest.php +++ b/tests/Luxembourg/LuxembourgTest.php @@ -14,7 +14,6 @@ namespace Yasumi\tests\Luxembourg; -use ReflectionException; use Yasumi\Holiday; use Yasumi\Provider\Luxembourg; use Yasumi\tests\ProviderTestCase; @@ -99,7 +98,7 @@ public function testOtherHolidays(): void } /** - * @throws ReflectionException + * @throws \ReflectionException * @throws \Exception */ public function testSources(): void diff --git a/tests/Luxembourg/NationalDayTest.php b/tests/Luxembourg/NationalDayTest.php index 8c0261140..e9638f553 100644 --- a/tests/Luxembourg/NationalDayTest.php +++ b/tests/Luxembourg/NationalDayTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\Luxembourg; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,8 +32,8 @@ class NationalDayTest extends LuxembourgBaseTestCase implements HolidayTestCase * * @dataProvider HolidayDataProvider * - * @param int $year the year for which the holiday defined in this test needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which the holiday defined in this test needs to be tested + * @param \DateTime $expected the expected date */ public function testHoliday(int $year, \DateTimeInterface $expected): void { @@ -47,7 +45,7 @@ public function testHoliday(int $year, \DateTimeInterface $expected): void * * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function HolidayDataProvider(): array { @@ -57,7 +55,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -72,7 +70,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Luxembourg/NewYearsDayTest.php b/tests/Luxembourg/NewYearsDayTest.php index 1e9f2a3ac..65fffb0b8 100644 --- a/tests/Luxembourg/NewYearsDayTest.php +++ b/tests/Luxembourg/NewYearsDayTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\Luxembourg; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,8 +32,8 @@ class NewYearsDayTest extends LuxembourgBaseTestCase implements HolidayTestCase * * @dataProvider NewYearsDayDataProvider * - * @param int $year the year for which New Years Day needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which New Years Day needs to be tested + * @param \DateTime $expected the expected date */ public function testNewYearsDay(int $year, \DateTimeInterface $expected): void { @@ -45,7 +43,7 @@ public function testNewYearsDay(int $year, \DateTimeInterface $expected): void /** * Tests translated name of New Years Day. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -60,7 +58,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { @@ -72,7 +70,7 @@ public function testHolidayType(): void * * @return array list of test dates for New Years Day * - * @throws Exception + * @throws \Exception */ public function NewYearsDayDataProvider(): array { diff --git a/tests/Luxembourg/PentecostMondayTest.php b/tests/Luxembourg/PentecostMondayTest.php index 9af50c120..611a64ce3 100644 --- a/tests/Luxembourg/PentecostMondayTest.php +++ b/tests/Luxembourg/PentecostMondayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Luxembourg; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -33,7 +30,7 @@ class PentecostMondayTest extends LuxembourgBaseTestCase implements HolidayTestC /** * Tests Pentecost Monday. * - * @throws Exception + * @throws \Exception */ public function testPentecostMonday(): void { @@ -42,14 +39,14 @@ public function testPentecostMonday(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-5-30", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-5-30", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests translated name of Pentecost Monday. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -64,7 +61,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Luxembourg/SecondChristmasDayTest.php b/tests/Luxembourg/SecondChristmasDayTest.php index a64dfb3f8..da2b71bdd 100644 --- a/tests/Luxembourg/SecondChristmasDayTest.php +++ b/tests/Luxembourg/SecondChristmasDayTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\Luxembourg; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,8 +32,8 @@ class SecondChristmasDayTest extends LuxembourgBaseTestCase implements HolidayTe * * @dataProvider HolidayDataProvider * - * @param int $year the year for which the holiday defined in this test needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which the holiday defined in this test needs to be tested + * @param \DateTime $expected the expected date */ public function testHoliday(int $year, \DateTimeInterface $expected): void { @@ -47,7 +45,7 @@ public function testHoliday(int $year, \DateTimeInterface $expected): void * * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function HolidayDataProvider(): array { @@ -57,7 +55,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -72,7 +70,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Netherlands/AscensionDayTest.php b/tests/Netherlands/AscensionDayTest.php index f4fd68b63..c10794142 100644 --- a/tests/Netherlands/AscensionDayTest.php +++ b/tests/Netherlands/AscensionDayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Netherlands; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -33,7 +30,7 @@ class AscensionDayTest extends NetherlandsBaseTestCase implements HolidayTestCas /** * Tests the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHoliday(): void { @@ -42,14 +39,14 @@ public function testHoliday(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-5-23", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-5-23", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -64,7 +61,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Netherlands/AshWednesdayTest.php b/tests/Netherlands/AshWednesdayTest.php index d757817c3..49f296cac 100644 --- a/tests/Netherlands/AshWednesdayTest.php +++ b/tests/Netherlands/AshWednesdayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Netherlands; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -33,7 +30,7 @@ class AshWednesdayTest extends NetherlandsBaseTestCase implements HolidayTestCas /** * Tests the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHoliday(): void { @@ -42,14 +39,14 @@ public function testHoliday(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-2-17", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-2-17", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests translated name of Ash Wednesday. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -64,7 +61,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Netherlands/ChristmasDayTest.php b/tests/Netherlands/ChristmasDayTest.php index 35af70baa..bb67b9267 100644 --- a/tests/Netherlands/ChristmasDayTest.php +++ b/tests/Netherlands/ChristmasDayTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\Netherlands; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,8 +32,8 @@ class ChristmasDayTest extends NetherlandsBaseTestCase implements HolidayTestCas * * @dataProvider HolidayDataProvider * - * @param int $year the year for which the holiday defined in this test needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which the holiday defined in this test needs to be tested + * @param \DateTime $expected the expected date */ public function testHoliday(int $year, \DateTimeInterface $expected): void { @@ -47,7 +45,7 @@ public function testHoliday(int $year, \DateTimeInterface $expected): void * * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function HolidayDataProvider(): array { @@ -57,7 +55,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -72,7 +70,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Netherlands/CommemorationDayTest.php b/tests/Netherlands/CommemorationDayTest.php index 993cfcc05..e3a1178ea 100644 --- a/tests/Netherlands/CommemorationDayTest.php +++ b/tests/Netherlands/CommemorationDayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Netherlands; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -38,7 +35,7 @@ class CommemorationDayTest extends NetherlandsBaseTestCase implements HolidayTes /** * Tests Commemoration Day before 1947. Commemoration Day was established after WWII in 1947. * - * @throws Exception + * @throws \Exception */ public function testCommemorationDayBefore1947(): void { @@ -52,7 +49,7 @@ public function testCommemorationDayBefore1947(): void /** * Tests Commemoration Day after 1947. Commemoration Day was established after WWII in 1947. * - * @throws Exception + * @throws \Exception */ public function testCommemorationDayOnAfter1947(): void { @@ -61,14 +58,14 @@ public function testCommemorationDayOnAfter1947(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-5-4", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-5-4", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -83,7 +80,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Netherlands/EasterMondayTest.php b/tests/Netherlands/EasterMondayTest.php index fcc5f1d88..3a27c50b6 100644 --- a/tests/Netherlands/EasterMondayTest.php +++ b/tests/Netherlands/EasterMondayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Netherlands; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -33,7 +30,7 @@ class EasterMondayTest extends NetherlandsBaseTestCase implements HolidayTestCas /** * Tests the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHoliday(): void { @@ -42,14 +39,14 @@ public function testHoliday(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-3-28", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-3-28", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -64,7 +61,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Netherlands/EasterTest.php b/tests/Netherlands/EasterTest.php index c62304672..a7f7f551d 100644 --- a/tests/Netherlands/EasterTest.php +++ b/tests/Netherlands/EasterTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Netherlands; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -33,7 +30,7 @@ class EasterTest extends NetherlandsBaseTestCase implements HolidayTestCase /** * Tests Easter. * - * @throws Exception + * @throws \Exception */ public function testEaster(): void { @@ -42,14 +39,14 @@ public function testEaster(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-4-4", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-4-4", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -64,7 +61,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Netherlands/EpiphanyTest.php b/tests/Netherlands/EpiphanyTest.php index 0ae287ac4..ca512b09b 100644 --- a/tests/Netherlands/EpiphanyTest.php +++ b/tests/Netherlands/EpiphanyTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\Netherlands; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,8 +32,8 @@ class EpiphanyTest extends NetherlandsBaseTestCase implements HolidayTestCase * * @dataProvider EpiphanyDataProvider * - * @param int $year the year for which Epiphany needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which Epiphany needs to be tested + * @param \DateTime $expected the expected date */ public function testEpiphany(int $year, \DateTimeInterface $expected): void { @@ -47,7 +45,7 @@ public function testEpiphany(int $year, \DateTimeInterface $expected): void * * @return array list of test dates for Epiphany * - * @throws Exception + * @throws \Exception */ public function EpiphanyDataProvider(): array { @@ -57,7 +55,7 @@ public function EpiphanyDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -72,7 +70,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Netherlands/FathersDayTest.php b/tests/Netherlands/FathersDayTest.php index 10f943eb3..ae327a90a 100644 --- a/tests/Netherlands/FathersDayTest.php +++ b/tests/Netherlands/FathersDayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Netherlands; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -33,7 +30,7 @@ class FathersDayTest extends NetherlandsBaseTestCase implements HolidayTestCase /** * Tests the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHoliday(): void { @@ -42,14 +39,14 @@ public function testHoliday(): void self::REGION, self::HOLIDAY, $year, - new DateTime("third sunday of june $year", new DateTimeZone(self::TIMEZONE)) + new \DateTime("third sunday of june $year", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -64,7 +61,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Netherlands/GoodFridayTest.php b/tests/Netherlands/GoodFridayTest.php index c99d1048e..ad996d7cd 100644 --- a/tests/Netherlands/GoodFridayTest.php +++ b/tests/Netherlands/GoodFridayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Netherlands; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -33,7 +30,7 @@ class GoodFridayTest extends NetherlandsBaseTestCase implements HolidayTestCase /** * Tests Good Friday. * - * @throws Exception + * @throws \Exception */ public function testGoodFriday(): void { @@ -42,14 +39,14 @@ public function testGoodFriday(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-4-14", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-4-14", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -64,7 +61,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Netherlands/HalloweenTest.php b/tests/Netherlands/HalloweenTest.php index d3857c14e..d366602a5 100644 --- a/tests/Netherlands/HalloweenTest.php +++ b/tests/Netherlands/HalloweenTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\Netherlands; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,8 +32,8 @@ class HalloweenTest extends NetherlandsBaseTestCase implements HolidayTestCase * * @dataProvider HalloweenDataProvider * - * @param int $year the year for which Halloween needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which Halloween needs to be tested + * @param \DateTime $expected the expected date */ public function testHoliday(int $year, \DateTimeInterface $expected): void { @@ -47,7 +45,7 @@ public function testHoliday(int $year, \DateTimeInterface $expected): void * * @return array list of test dates for Halloween * - * @throws Exception + * @throws \Exception */ public function HalloweenDataProvider(): array { @@ -57,7 +55,7 @@ public function HalloweenDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -72,7 +70,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Netherlands/InternationalWorkersDayTest.php b/tests/Netherlands/InternationalWorkersDayTest.php index 259d62bb1..0cebb4c21 100644 --- a/tests/Netherlands/InternationalWorkersDayTest.php +++ b/tests/Netherlands/InternationalWorkersDayTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\Netherlands; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,8 +32,8 @@ class InternationalWorkersDayTest extends NetherlandsBaseTestCase implements Hol * * @dataProvider InternationalWorkersDayDataProvider * - * @param int $year the year for which International Workers' Day needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which International Workers' Day needs to be tested + * @param \DateTime $expected the expected date */ public function testInternationalWorkersDay(int $year, \DateTimeInterface $expected): void { @@ -47,7 +45,7 @@ public function testInternationalWorkersDay(int $year, \DateTimeInterface $expec * * @return array list of test dates for International Workers' Day * - * @throws Exception + * @throws \Exception */ public function InternationalWorkersDayDataProvider(): array { @@ -57,7 +55,7 @@ public function InternationalWorkersDayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -72,7 +70,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Netherlands/KingsDayTest.php b/tests/Netherlands/KingsDayTest.php index 38139c985..53d61a66d 100644 --- a/tests/Netherlands/KingsDayTest.php +++ b/tests/Netherlands/KingsDayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Netherlands; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -38,7 +35,7 @@ class KingsDayTest extends NetherlandsBaseTestCase implements HolidayTestCase /** * Tests Kings Day on or after 2014. King's Day is celebrated from 2014 onwards on April 27th. * - * @throws Exception + * @throws \Exception */ public function testKingsDayOnAfter2014(): void { @@ -47,14 +44,14 @@ public function testKingsDayOnAfter2014(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-4-27", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-4-27", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests Kings Day substituted on Saturday (when Kings Day falls on a Sunday). * - * @throws Exception + * @throws \Exception */ public function testKingsDayOnAfter2014SubstitutedDay(): void { @@ -63,14 +60,14 @@ public function testKingsDayOnAfter2014SubstitutedDay(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-4-26", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-4-26", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests Kings Day before 2014. King's Day is celebrated from 2014 onwards on April 27th. * - * @throws Exception + * @throws \Exception */ public function testKingsDayBefore2014(): void { @@ -84,7 +81,7 @@ public function testKingsDayBefore2014(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -99,7 +96,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Netherlands/LiberationDayTest.php b/tests/Netherlands/LiberationDayTest.php index b90be24e8..e84650aff 100644 --- a/tests/Netherlands/LiberationDayTest.php +++ b/tests/Netherlands/LiberationDayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Netherlands; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -38,7 +35,7 @@ class LiberationDayTest extends NetherlandsBaseTestCase implements HolidayTestCa /** * Tests Liberation Day before 1947. Liberation Day was established after WWII in 1947. * - * @throws Exception + * @throws \Exception */ public function testLiberationDayBefore1947(): void { @@ -52,7 +49,7 @@ public function testLiberationDayBefore1947(): void /** * Tests Liberation Day after 1947. Liberation Day was established after WWII in 1947. * - * @throws Exception + * @throws \Exception */ public function testLiberationDayOnAfter1947(): void { @@ -61,14 +58,14 @@ public function testLiberationDayOnAfter1947(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-5-5", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-5-5", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -83,7 +80,7 @@ public function testTranslation(): void /** * Tests Liberation Day official holiday type every 5 years, observance type on other years. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Netherlands/MothersDayTest.php b/tests/Netherlands/MothersDayTest.php index fccd58c64..b7ca1b493 100644 --- a/tests/Netherlands/MothersDayTest.php +++ b/tests/Netherlands/MothersDayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Netherlands; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -33,7 +30,7 @@ class MothersDayTest extends NetherlandsBaseTestCase implements HolidayTestCase /** * Tests Mother's Day. * - * @throws Exception + * @throws \Exception */ public function testMothersDay(): void { @@ -42,14 +39,14 @@ public function testMothersDay(): void self::REGION, self::HOLIDAY, $year, - new DateTime("second sunday of may $year", new DateTimeZone(self::TIMEZONE)) + new \DateTime("second sunday of may $year", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -64,7 +61,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Netherlands/NetherlandsTest.php b/tests/Netherlands/NetherlandsTest.php index d082935e0..ec7dd632b 100644 --- a/tests/Netherlands/NetherlandsTest.php +++ b/tests/Netherlands/NetherlandsTest.php @@ -14,7 +14,6 @@ namespace Yasumi\tests\Netherlands; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\ProviderTestCase; @@ -122,7 +121,7 @@ public function testOtherHolidays(): void } /** - * @throws ReflectionException + * @throws \ReflectionException * @throws \Exception */ public function testSources(): void diff --git a/tests/Netherlands/NewYearsDayTest.php b/tests/Netherlands/NewYearsDayTest.php index 5bcbe7845..714664cfd 100644 --- a/tests/Netherlands/NewYearsDayTest.php +++ b/tests/Netherlands/NewYearsDayTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\Netherlands; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,8 +32,8 @@ class NewYearsDayTest extends NetherlandsBaseTestCase implements HolidayTestCase * * @dataProvider NewYearsDayDataProvider * - * @param int $year the year for which New Years Day needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which New Years Day needs to be tested + * @param \DateTime $expected the expected date */ public function testNewYearsDay(int $year, \DateTimeInterface $expected): void { @@ -47,7 +45,7 @@ public function testNewYearsDay(int $year, \DateTimeInterface $expected): void * * @return array list of test dates for New Years Day * - * @throws Exception + * @throws \Exception */ public function NewYearsDayDataProvider(): array { @@ -57,7 +55,7 @@ public function NewYearsDayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -72,7 +70,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Netherlands/PentecostTest.php b/tests/Netherlands/PentecostTest.php index 136c7e4df..b0b210f40 100644 --- a/tests/Netherlands/PentecostTest.php +++ b/tests/Netherlands/PentecostTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Netherlands; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -33,7 +30,7 @@ class PentecostTest extends NetherlandsBaseTestCase implements HolidayTestCase /** * Tests the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHoliday(): void { @@ -42,14 +39,14 @@ public function testHoliday(): void self::REGION, 'pentecost', $year, - new DateTime("$year-5-31", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-5-31", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -64,7 +61,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Netherlands/QueensDayTest.php b/tests/Netherlands/QueensDayTest.php index 3ab39c73f..04a5766f2 100644 --- a/tests/Netherlands/QueensDayTest.php +++ b/tests/Netherlands/QueensDayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Netherlands; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -33,7 +30,7 @@ class QueensDayTest extends NetherlandsBaseTestCase implements HolidayTestCase /** * Tests Queens Day between 1891 and 1948. * - * @throws Exception + * @throws \Exception */ public function testQueensBetween1891and1948(): void { @@ -42,14 +39,14 @@ public function testQueensBetween1891and1948(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-8-31", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-8-31", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests Queens Day between 1891 and 1948 substituted one day later (when Queens Day falls on a Sunday). * - * @throws Exception + * @throws \Exception */ public function testQueensBetween1891and1948SubstitutedLater(): void { @@ -58,14 +55,14 @@ public function testQueensBetween1891and1948SubstitutedLater(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-9-1", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-9-1", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests Queens Day between 1949 and 2013. * - * @throws Exception + * @throws \Exception */ public function testQueensBetween1949and2013(): void { @@ -74,14 +71,14 @@ public function testQueensBetween1949and2013(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-4-30", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-4-30", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests Queens Day between 1949 and 2013 substituted one day later. * - * @throws Exception + * @throws \Exception */ public function testQueensBetween1949and2013SubstitutedLater(): void { @@ -90,14 +87,14 @@ public function testQueensBetween1949and2013SubstitutedLater(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-5-1", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-5-1", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests Queens Day between 1949 and 2013 substituted one day earlier. * - * @throws Exception + * @throws \Exception */ public function testQueensBetween1949and2013SubstitutedEarlier(): void { @@ -106,14 +103,14 @@ public function testQueensBetween1949and2013SubstitutedEarlier(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-4-29", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-4-29", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests Queen's Day before 1891. * - * @throws Exception + * @throws \Exception */ public function testQueensDayBefore1891(): void { @@ -123,7 +120,7 @@ public function testQueensDayBefore1891(): void /** * Tests Queen's Day after 2013. * - * @throws Exception + * @throws \Exception */ public function testQueensDayAfter2013(): void { @@ -133,7 +130,7 @@ public function testQueensDayAfter2013(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -148,7 +145,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Netherlands/SummertimeTest.php b/tests/Netherlands/SummertimeTest.php index 4727ef608..b1404af9f 100644 --- a/tests/Netherlands/SummertimeTest.php +++ b/tests/Netherlands/SummertimeTest.php @@ -15,9 +15,6 @@ namespace Yasumi\tests\Netherlands; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; /** @@ -41,7 +38,7 @@ public function __construct() /** * Tests Summertime. * - * @throws Exception + * @throws \Exception */ public function testSummertime(): void { @@ -52,7 +49,7 @@ public function testSummertime(): void self::REGION, self::HOLIDAY, $year, - new DateTime("first sunday of april $year", new DateTimeZone(self::TIMEZONE)) + new \DateTime("first sunday of april $year", new \DateTimeZone(self::TIMEZONE)) ); $year = $this->generateRandomYear(1981, 2037); @@ -60,14 +57,14 @@ public function testSummertime(): void self::REGION, self::HOLIDAY, $year, - new DateTime("last sunday of march $year", new DateTimeZone(self::TIMEZONE)) + new \DateTime("last sunday of march $year", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -82,7 +79,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Netherlands/ValentinesDayTest.php b/tests/Netherlands/ValentinesDayTest.php index 1d4445749..9be48a4a5 100644 --- a/tests/Netherlands/ValentinesDayTest.php +++ b/tests/Netherlands/ValentinesDayTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\Netherlands; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,8 +32,8 @@ class ValentinesDayTest extends NetherlandsBaseTestCase implements HolidayTestCa * * @dataProvider ValentinesDayDataProvider * - * @param int $year the year for which Valentines Day needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which Valentines Day needs to be tested + * @param \DateTime $expected the expected date */ public function testValentinesDay(int $year, \DateTimeInterface $expected): void { @@ -47,7 +45,7 @@ public function testValentinesDay(int $year, \DateTimeInterface $expected): void * * @return array list of test dates for Valentines Day * - * @throws Exception + * @throws \Exception */ public function ValentinesDayDataProvider(): array { @@ -57,7 +55,7 @@ public function ValentinesDayDataProvider(): array /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { @@ -67,7 +65,7 @@ public function testHolidayType(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { diff --git a/tests/Netherlands/WintertimeTest.php b/tests/Netherlands/WintertimeTest.php index 6b29b5cbe..f1704116f 100644 --- a/tests/Netherlands/WintertimeTest.php +++ b/tests/Netherlands/WintertimeTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Netherlands; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; /** @@ -40,7 +37,7 @@ public function __construct() /** * Tests Wintertime. * - * @throws Exception + * @throws \Exception */ public function testWintertime(): void { @@ -51,7 +48,7 @@ public function testWintertime(): void self::REGION, self::HOLIDAY, $year, - new DateTime("last sunday of september $year", new DateTimeZone(self::TIMEZONE)) + new \DateTime("last sunday of september $year", new \DateTimeZone(self::TIMEZONE)) ); $year = $this->generateRandomYear(1996, 2037); @@ -59,14 +56,14 @@ public function testWintertime(): void self::REGION, self::HOLIDAY, $year, - new DateTime("last sunday of october $year", new DateTimeZone(self::TIMEZONE)) + new \DateTime("last sunday of october $year", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -81,7 +78,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Netherlands/WorldAnimalDayTest.php b/tests/Netherlands/WorldAnimalDayTest.php index b589a8dc0..823e6251a 100644 --- a/tests/Netherlands/WorldAnimalDayTest.php +++ b/tests/Netherlands/WorldAnimalDayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Netherlands; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -38,7 +35,7 @@ class WorldAnimalDayTest extends NetherlandsBaseTestCase implements HolidayTestC /** * Tests World Animal Day on or after 1931. * - * @throws Exception + * @throws \Exception */ public function testWorldAnimalDayOnAfter1931(): void { @@ -47,14 +44,14 @@ public function testWorldAnimalDayOnAfter1931(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-10-4", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-10-4", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests World Animal Day before 1931. * - * @throws Exception + * @throws \Exception */ public function testWorldAnimalBefore1931(): void { @@ -68,7 +65,7 @@ public function testWorldAnimalBefore1931(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { @@ -83,7 +80,7 @@ public function testHolidayType(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { diff --git a/tests/Netherlands/carnivalDayTest.php b/tests/Netherlands/carnivalDayTest.php index a6d134fc2..1fdc2db50 100644 --- a/tests/Netherlands/carnivalDayTest.php +++ b/tests/Netherlands/carnivalDayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Netherlands; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -33,7 +30,7 @@ class carnivalDayTest extends NetherlandsBaseTestCase implements HolidayTestCase /** * Tests the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHoliday(): void { @@ -42,14 +39,14 @@ public function testHoliday(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-2-15", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-2-15", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { @@ -59,7 +56,7 @@ public function testHolidayType(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { diff --git a/tests/Netherlands/pentecostMondayTest.php b/tests/Netherlands/pentecostMondayTest.php index 92fc4b66c..b01076964 100644 --- a/tests/Netherlands/pentecostMondayTest.php +++ b/tests/Netherlands/pentecostMondayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Netherlands; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -33,7 +30,7 @@ class pentecostMondayTest extends NetherlandsBaseTestCase implements HolidayTest /** * Tests Pentecost Monday. * - * @throws Exception + * @throws \Exception */ public function testPentecostMonday(): void { @@ -42,14 +39,14 @@ public function testPentecostMonday(): void self::REGION, 'pentecostMonday', $year, - new DateTime("$year-6-1", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-6-1", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -64,7 +61,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Netherlands/princesDayTest.php b/tests/Netherlands/princesDayTest.php index 5610b2818..c6d552ae7 100644 --- a/tests/Netherlands/princesDayTest.php +++ b/tests/Netherlands/princesDayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Netherlands; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -33,7 +30,7 @@ class princesDayTest extends NetherlandsBaseTestCase implements HolidayTestCase /** * Tests Prince's Day. * - * @throws Exception + * @throws \Exception */ public function testPrincesDay(): void { @@ -42,14 +39,14 @@ public function testPrincesDay(): void self::REGION, self::HOLIDAY, $year, - new DateTime("third tuesday of september $year", new DateTimeZone(self::TIMEZONE)) + new \DateTime("third tuesday of september $year", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -64,7 +61,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Netherlands/secondCarnivalDay.php b/tests/Netherlands/secondCarnivalDay.php index 98ea9f19f..28577cf11 100644 --- a/tests/Netherlands/secondCarnivalDay.php +++ b/tests/Netherlands/secondCarnivalDay.php @@ -14,11 +14,6 @@ namespace Yasumi\tests\Netherlands; -use DateTime; -use DateTimeZone; -use Exception; -use InvalidArgumentException; -use RuntimeException; use Yasumi\Exception\UnknownLocaleException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -37,9 +32,9 @@ class secondCarnivalDay extends NetherlandsBaseTestCase implements HolidayTestCa * Tests the holiday defined in this test. * * @throws UnknownLocaleException - * @throws InvalidArgumentException - * @throws RuntimeException - * @throws Exception + * @throws \InvalidArgumentException + * @throws \RuntimeException + * @throws \Exception */ public function testHoliday(): void { @@ -48,17 +43,17 @@ public function testHoliday(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-2-16", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-2-16", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests type of the holiday defined in this test. * - * @throws InvalidArgumentException - * @throws RuntimeException + * @throws \InvalidArgumentException + * @throws \RuntimeException * @throws UnknownLocaleException - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { @@ -68,10 +63,10 @@ public function testHolidayType(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws InvalidArgumentException - * @throws RuntimeException + * @throws \InvalidArgumentException + * @throws \RuntimeException * @throws UnknownLocaleException - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { diff --git a/tests/Netherlands/secondChristmasdayTest.php b/tests/Netherlands/secondChristmasdayTest.php index 8fed083af..1e7fff418 100644 --- a/tests/Netherlands/secondChristmasdayTest.php +++ b/tests/Netherlands/secondChristmasdayTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\Netherlands; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,8 +32,8 @@ class secondChristmasdayTest extends NetherlandsBaseTestCase implements HolidayT * * @dataProvider HolidayDataProvider * - * @param int $year the year for which the holiday defined in this test needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which the holiday defined in this test needs to be tested + * @param \DateTime $expected the expected date */ public function testHoliday(int $year, \DateTimeInterface $expected): void { @@ -47,7 +45,7 @@ public function testHoliday(int $year, \DateTimeInterface $expected): void * * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function HolidayDataProvider(): array { @@ -57,7 +55,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -72,7 +70,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Netherlands/stMartinsDayTest.php b/tests/Netherlands/stMartinsDayTest.php index f3a1dbe5c..95a073890 100644 --- a/tests/Netherlands/stMartinsDayTest.php +++ b/tests/Netherlands/stMartinsDayTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\Netherlands; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,8 +32,8 @@ class stMartinsDayTest extends NetherlandsBaseTestCase implements HolidayTestCas * * @dataProvider stMartinsDayDataProvider * - * @param int $year the year for which Sint Martins Day needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which Sint Martins Day needs to be tested + * @param \DateTime $expected the expected date */ public function teststMartinsDay(int $year, \DateTimeInterface $expected): void { @@ -47,7 +45,7 @@ public function teststMartinsDay(int $year, \DateTimeInterface $expected): void * * @return array list of test dates for Sint Martins Day * - * @throws Exception + * @throws \Exception */ public function stMartinsDayDataProvider(): array { @@ -57,7 +55,7 @@ public function stMartinsDayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -72,7 +70,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Netherlands/stNicholasDayTest.php b/tests/Netherlands/stNicholasDayTest.php index 010ffa124..f42f80326 100644 --- a/tests/Netherlands/stNicholasDayTest.php +++ b/tests/Netherlands/stNicholasDayTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\Netherlands; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,8 +32,8 @@ class stNicholasDayTest extends NetherlandsBaseTestCase implements HolidayTestCa * * @dataProvider stNicholasDayDataProvider * - * @param int $year the year for which Sint Nicholas Day needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which Sint Nicholas Day needs to be tested + * @param \DateTime $expected the expected date */ public function teststNicholasDay(int $year, \DateTimeInterface $expected): void { @@ -47,7 +45,7 @@ public function teststNicholasDay(int $year, \DateTimeInterface $expected): void * * @return array list of test dates for Sint Nicholas Day * - * @throws Exception + * @throws \Exception */ public function stNicholasDayDataProvider(): array { @@ -57,7 +55,7 @@ public function stNicholasDayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -72,7 +70,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Netherlands/thirdCarnivalDay.php b/tests/Netherlands/thirdCarnivalDay.php index 0943572af..2d9ce1fd5 100644 --- a/tests/Netherlands/thirdCarnivalDay.php +++ b/tests/Netherlands/thirdCarnivalDay.php @@ -14,11 +14,6 @@ namespace Yasumi\tests\Netherlands; -use DateTime; -use DateTimeZone; -use Exception; -use InvalidArgumentException; -use RuntimeException; use Yasumi\Exception\UnknownLocaleException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -37,9 +32,9 @@ class thirdCarnivalDay extends NetherlandsBaseTestCase implements HolidayTestCas * Tests the holiday defined in this test. * * @throws UnknownLocaleException - * @throws InvalidArgumentException - * @throws RuntimeException - * @throws Exception + * @throws \InvalidArgumentException + * @throws \RuntimeException + * @throws \Exception */ public function testHoliday(): void { @@ -48,17 +43,17 @@ public function testHoliday(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-2-17", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-2-17", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests type of the holiday defined in this test. * - * @throws InvalidArgumentException - * @throws RuntimeException + * @throws \InvalidArgumentException + * @throws \RuntimeException * @throws UnknownLocaleException - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { @@ -68,10 +63,10 @@ public function testHolidayType(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws InvalidArgumentException - * @throws RuntimeException + * @throws \InvalidArgumentException + * @throws \RuntimeException * @throws UnknownLocaleException - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { diff --git a/tests/NewZealand/AnzacDayTest.php b/tests/NewZealand/AnzacDayTest.php index c5d58576f..d9cf97cf5 100644 --- a/tests/NewZealand/AnzacDayTest.php +++ b/tests/NewZealand/AnzacDayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\NewZealand; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -43,7 +40,7 @@ class AnzacDayTest extends NewZealandBaseTestCase implements HolidayTestCase * @param int $year the year for which the holiday defined in this test needs to be tested * @param string $expected the expected date * - * @throws Exception + * @throws \Exception */ public function testHoliday(int $year, string $expected): void { @@ -51,7 +48,7 @@ public function testHoliday(int $year, string $expected): void self::REGION, self::HOLIDAY, $year, - new DateTime($expected, new DateTimeZone(self::TIMEZONE)) + new \DateTime($expected, new \DateTimeZone(self::TIMEZONE)) ); } @@ -68,11 +65,11 @@ public function testNotHoliday(): void * * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function HolidayDataProvider(): array { - return $this->generateRandomDatesWithModifier(4, 25, function ($year, DateTime $date): void { + return $this->generateRandomDatesWithModifier(4, 25, function ($year, \DateTime $date): void { // in 2015 some policy was introduced to make sure this holiday was celebrated during the working week. if ($year >= 2015 && $this->isWeekend($date)) { $date->modify('next monday'); @@ -83,7 +80,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -98,7 +95,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/NewZealand/BoxingDayTest.php b/tests/NewZealand/BoxingDayTest.php index 7957adddf..030c8480f 100644 --- a/tests/NewZealand/BoxingDayTest.php +++ b/tests/NewZealand/BoxingDayTest.php @@ -14,10 +14,6 @@ namespace Yasumi\tests\NewZealand; -use DateInterval; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -39,7 +35,7 @@ class BoxingDayTest extends NewZealandBaseTestCase implements HolidayTestCase * @param int $year the year for which the holiday defined in this test needs to be tested * @param string $expected the expected date * - * @throws Exception + * @throws \Exception */ public function testHoliday(int $year, string $expected): void { @@ -47,7 +43,7 @@ public function testHoliday(int $year, string $expected): void self::REGION, self::HOLIDAY, $year, - new DateTime($expected, new DateTimeZone(self::TIMEZONE)) + new \DateTime($expected, new \DateTimeZone(self::TIMEZONE)) ); } @@ -56,7 +52,7 @@ public function testHoliday(int $year, string $expected): void * * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function HolidayDataProvider(): array { @@ -64,10 +60,10 @@ public function HolidayDataProvider(): array for ($y = 0; $y < 50; ++$y) { $year = $this->generateRandomYear(); - $date = new DateTime("$year-12-26", new DateTimeZone(self::TIMEZONE)); + $date = new \DateTime("$year-12-26", new \DateTimeZone(self::TIMEZONE)); if (\in_array((int) $date->format('w'), [0, 6], true)) { - $date->add(new DateInterval('P2D')); + $date->add(new \DateInterval('P2D')); } $data[] = [$year, $date->format('Y-m-d')]; @@ -79,7 +75,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -94,7 +90,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/NewZealand/ChristmasDayTest.php b/tests/NewZealand/ChristmasDayTest.php index 1cfbd4639..935819500 100644 --- a/tests/NewZealand/ChristmasDayTest.php +++ b/tests/NewZealand/ChristmasDayTest.php @@ -14,10 +14,6 @@ namespace Yasumi\tests\NewZealand; -use DateInterval; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -39,7 +35,7 @@ class ChristmasDayTest extends NewZealandBaseTestCase implements HolidayTestCase * @param int $year the year for which the holiday defined in this test needs to be tested * @param string $expected the expected date * - * @throws Exception + * @throws \Exception */ public function testHoliday(int $year, string $expected): void { @@ -47,7 +43,7 @@ public function testHoliday(int $year, string $expected): void self::REGION, self::HOLIDAY, $year, - new DateTime($expected, new DateTimeZone(self::TIMEZONE)) + new \DateTime($expected, new \DateTimeZone(self::TIMEZONE)) ); } @@ -56,7 +52,7 @@ public function testHoliday(int $year, string $expected): void * * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function HolidayDataProvider(): array { @@ -64,10 +60,10 @@ public function HolidayDataProvider(): array for ($y = 0; $y < 50; ++$y) { $year = $this->generateRandomYear(); - $date = new DateTime("$year-12-25", new DateTimeZone(self::TIMEZONE)); + $date = new \DateTime("$year-12-25", new \DateTimeZone(self::TIMEZONE)); if (\in_array((int) $date->format('w'), [0, 6], true)) { - $date->add(new DateInterval('P2D')); + $date->add(new \DateInterval('P2D')); } $data[] = [$year, $date->format('Y-m-d')]; @@ -79,7 +75,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -94,7 +90,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/NewZealand/DayAfterNewYearsDayTest.php b/tests/NewZealand/DayAfterNewYearsDayTest.php index 6924635cb..46e6dd5f7 100644 --- a/tests/NewZealand/DayAfterNewYearsDayTest.php +++ b/tests/NewZealand/DayAfterNewYearsDayTest.php @@ -14,10 +14,6 @@ namespace Yasumi\tests\NewZealand; -use DateInterval; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -39,7 +35,7 @@ class DayAfterNewYearsDayTest extends NewZealandBaseTestCase implements HolidayT * @param int $year the year for which the holiday defined in this test needs to be tested * @param string $expected the expected date * - * @throws Exception + * @throws \Exception */ public function testHoliday(int $year, string $expected): void { @@ -47,14 +43,14 @@ public function testHoliday(int $year, string $expected): void self::REGION, self::HOLIDAY, $year, - new DateTime($expected, new DateTimeZone(self::TIMEZONE)) + new \DateTime($expected, new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -69,7 +65,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { @@ -81,7 +77,7 @@ public function testHolidayType(): void * * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function HolidayDataProvider(): array { @@ -89,15 +85,15 @@ public function HolidayDataProvider(): array for ($y = 0; $y < 50; ++$y) { $year = $this->generateRandomYear(); - $date = new DateTime("$year-01-02", new DateTimeZone(self::TIMEZONE)); + $date = new \DateTime("$year-01-02", new \DateTimeZone(self::TIMEZONE)); switch ($date->format('w')) { case 0: case 6: - $date->add(new DateInterval('P2D')); + $date->add(new \DateInterval('P2D')); break; case 1: - $date->add(new DateInterval('P1D')); + $date->add(new \DateInterval('P1D')); } $data[] = [$year, $date->format('Y-m-d')]; diff --git a/tests/NewZealand/EasterMondayTest.php b/tests/NewZealand/EasterMondayTest.php index b3380d7ca..0750fe0eb 100644 --- a/tests/NewZealand/EasterMondayTest.php +++ b/tests/NewZealand/EasterMondayTest.php @@ -14,10 +14,6 @@ namespace Yasumi\tests\NewZealand; -use DateInterval; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -39,7 +35,7 @@ class EasterMondayTest extends NewZealandBaseTestCase implements HolidayTestCase * @param int $year the year for which the holiday defined in this test needs to be tested * @param string $expected the expected date * - * @throws Exception + * @throws \Exception */ public function testHoliday(int $year, string $expected): void { @@ -47,7 +43,7 @@ public function testHoliday(int $year, string $expected): void self::REGION, self::HOLIDAY, $year, - new DateTime($expected, new DateTimeZone(self::TIMEZONE)) + new \DateTime($expected, new \DateTimeZone(self::TIMEZONE)) ); } @@ -56,7 +52,7 @@ public function testHoliday(int $year, string $expected): void * * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function HolidayDataProvider(): array { @@ -65,7 +61,7 @@ public function HolidayDataProvider(): array for ($y = 0; $y < 50; ++$y) { $year = $this->generateRandomYear(); $date = $this->calculateEaster($year, self::TIMEZONE); - $date->add(new DateInterval('P1D')); + $date->add(new \DateInterval('P1D')); $data[] = [$year, $date->format('Y-m-d')]; } @@ -76,7 +72,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -91,7 +87,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/NewZealand/GoodFridayTest.php b/tests/NewZealand/GoodFridayTest.php index 00a83a9f8..1024cbd1b 100644 --- a/tests/NewZealand/GoodFridayTest.php +++ b/tests/NewZealand/GoodFridayTest.php @@ -14,10 +14,6 @@ namespace Yasumi\tests\NewZealand; -use DateInterval; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -39,7 +35,7 @@ class GoodFridayTest extends NewZealandBaseTestCase implements HolidayTestCase * @param int $year the year for which the holiday defined in this test needs to be tested * @param string $expected the expected date * - * @throws Exception + * @throws \Exception */ public function testHoliday(int $year, string $expected): void { @@ -47,7 +43,7 @@ public function testHoliday(int $year, string $expected): void self::REGION, self::HOLIDAY, $year, - new DateTime($expected, new DateTimeZone(self::TIMEZONE)) + new \DateTime($expected, new \DateTimeZone(self::TIMEZONE)) ); } @@ -56,7 +52,7 @@ public function testHoliday(int $year, string $expected): void * * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function HolidayDataProvider(): array { @@ -65,7 +61,7 @@ public function HolidayDataProvider(): array for ($y = 0; $y < 50; ++$y) { $year = $this->generateRandomYear(); $date = $this->calculateEaster($year, self::TIMEZONE); - $date->sub(new DateInterval('P2D')); + $date->sub(new \DateInterval('P2D')); $data[] = [$year, $date->format('Y-m-d')]; } @@ -75,7 +71,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -90,7 +86,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/NewZealand/LabourDayTest.php b/tests/NewZealand/LabourDayTest.php index 9bbdfa020..2a00648d3 100644 --- a/tests/NewZealand/LabourDayTest.php +++ b/tests/NewZealand/LabourDayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\NewZealand; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -43,7 +40,7 @@ class LabourDayTest extends NewZealandBaseTestCase implements HolidayTestCase * @param int $year the year for which the holiday defined in this test needs to be tested * @param string $expected the expected date * - * @throws Exception + * @throws \Exception */ public function testHoliday(int $year, string $expected): void { @@ -51,7 +48,7 @@ public function testHoliday(int $year, string $expected): void self::REGION, self::HOLIDAY, $year, - new DateTime($expected, new DateTimeZone(self::TIMEZONE)) + new \DateTime($expected, new \DateTimeZone(self::TIMEZONE)) ); } @@ -68,7 +65,7 @@ public function testNotHoliday(): void * * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function HolidayDataProvider(): array { @@ -76,9 +73,9 @@ public function HolidayDataProvider(): array for ($y = 0; $y < 100; ++$y) { $year = $this->generateRandomYear(self::ESTABLISHMENT_YEAR); - $expected = new DateTime( + $expected = new \DateTime( (($year < 1910) ? 'second wednesday of october' : 'fourth monday of october')." $year", - new DateTimeZone(self::TIMEZONE) + new \DateTimeZone(self::TIMEZONE) ); $data[] = [$year, $expected->format('Y-m-d')]; @@ -90,7 +87,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -105,7 +102,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/NewZealand/NewYearsDayTest.php b/tests/NewZealand/NewYearsDayTest.php index d1cf7b913..01aac54cd 100644 --- a/tests/NewZealand/NewYearsDayTest.php +++ b/tests/NewZealand/NewYearsDayTest.php @@ -14,10 +14,6 @@ namespace Yasumi\tests\NewZealand; -use DateInterval; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -39,7 +35,7 @@ class NewYearsDayTest extends NewZealandBaseTestCase implements HolidayTestCase * @param int $year the year for which the holiday defined in this test needs to be tested * @param string $expected the expected date * - * @throws Exception + * @throws \Exception */ public function testHoliday(int $year, string $expected): void { @@ -47,7 +43,7 @@ public function testHoliday(int $year, string $expected): void self::REGION, self::HOLIDAY, $year, - new DateTime($expected, new DateTimeZone(self::TIMEZONE)) + new \DateTime($expected, new \DateTimeZone(self::TIMEZONE)) ); } @@ -56,7 +52,7 @@ public function testHoliday(int $year, string $expected): void * * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function HolidayDataProvider(): array { @@ -64,14 +60,14 @@ public function HolidayDataProvider(): array for ($y = 0; $y < 50; ++$y) { $year = $this->generateRandomYear(); - $date = new DateTime("$year-01-01", new DateTimeZone(self::TIMEZONE)); + $date = new \DateTime("$year-01-01", new \DateTimeZone(self::TIMEZONE)); switch ($date->format('w')) { case 0: - $date->add(new DateInterval('P1D')); + $date->add(new \DateInterval('P1D')); break; case 6: - $date->add(new DateInterval('P2D')); + $date->add(new \DateInterval('P2D')); break; } @@ -84,7 +80,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -99,7 +95,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/NewZealand/NewZealandTest.php b/tests/NewZealand/NewZealandTest.php index e17ef47b8..9093e78d7 100644 --- a/tests/NewZealand/NewZealandTest.php +++ b/tests/NewZealand/NewZealandTest.php @@ -14,7 +14,6 @@ namespace Yasumi\tests\NewZealand; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\ProviderTestCase; @@ -89,7 +88,7 @@ public function testOtherHolidays(): void } /** - * @throws ReflectionException + * @throws \ReflectionException * @throws \Exception */ public function testSources(): void diff --git a/tests/NewZealand/QueensBirthdayTest.php b/tests/NewZealand/QueensBirthdayTest.php index e5189c918..a843f1af6 100644 --- a/tests/NewZealand/QueensBirthdayTest.php +++ b/tests/NewZealand/QueensBirthdayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\NewZealand; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -40,8 +37,8 @@ class QueensBirthdayTest extends NewZealandBaseTestCase implements HolidayTestCa * * @dataProvider HolidayDataProvider * - * @param int $year the year for which the holiday defined in this test needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which the holiday defined in this test needs to be tested + * @param \DateTime $expected the expected date */ public function testHoliday(int $year, \DateTimeInterface $expected): void { @@ -61,7 +58,7 @@ public function testNotHoliday(): void * * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function HolidayDataProvider(): array { @@ -69,7 +66,7 @@ public function HolidayDataProvider(): array for ($y = 1; $y <= 100; ++$y) { $year = $this->generateRandomYear(self::ESTABLISHMENT_YEAR); - $expected = new DateTime("first monday of june $year", new DateTimeZone(self::TIMEZONE)); + $expected = new \DateTime("first monday of june $year", new \DateTimeZone(self::TIMEZONE)); $data[] = [$year, $expected]; } @@ -79,7 +76,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -94,7 +91,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/NewZealand/WaitangiDayTest.php b/tests/NewZealand/WaitangiDayTest.php index c03902f14..4db3a70ac 100644 --- a/tests/NewZealand/WaitangiDayTest.php +++ b/tests/NewZealand/WaitangiDayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\NewZealand; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -43,7 +40,7 @@ class WaitangiDayTest extends NewZealandBaseTestCase implements HolidayTestCase * @param int $year the year for which the holiday defined in this test needs to be tested * @param string $expected the expected date * - * @throws Exception + * @throws \Exception */ public function testHoliday(int $year, string $expected): void { @@ -51,7 +48,7 @@ public function testHoliday(int $year, string $expected): void self::REGION, self::HOLIDAY, $year, - new DateTime($expected, new DateTimeZone(self::TIMEZONE)) + new \DateTime($expected, new \DateTimeZone(self::TIMEZONE)) ); } @@ -66,7 +63,7 @@ public function testNotHoliday(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -81,7 +78,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { @@ -98,11 +95,11 @@ public function testHolidayType(): void * * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function HolidayDataProvider(): array { - return $this->generateRandomDatesWithModifier(2, 06, function ($year, DateTime $date): void { + return $this->generateRandomDatesWithModifier(2, 06, function ($year, \DateTime $date): void { // in 2015 some policy was introduced to make sure this holiday was celebrated during the working week. if ($year >= 2015 && $this->isWeekend($date)) { $date->modify('next monday'); diff --git a/tests/Norway/AscensionDayTest.php b/tests/Norway/AscensionDayTest.php index 6fc44b880..f6011ca5b 100644 --- a/tests/Norway/AscensionDayTest.php +++ b/tests/Norway/AscensionDayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Norway; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -33,7 +30,7 @@ class AscensionDayTest extends NorwayBaseTestCase implements HolidayTestCase /** * Tests Ascension Day. * - * @throws Exception + * @throws \Exception */ public function testAscensionDay(): void { @@ -42,14 +39,14 @@ public function testAscensionDay(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-5-10", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-5-10", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests translated name of Ascension Day. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -64,7 +61,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Norway/ChristmasDayTest.php b/tests/Norway/ChristmasDayTest.php index a9d7daf00..57c905cd0 100644 --- a/tests/Norway/ChristmasDayTest.php +++ b/tests/Norway/ChristmasDayTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\Norway; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,8 +32,8 @@ class ChristmasDayTest extends NorwayBaseTestCase implements HolidayTestCase * * @dataProvider HolidayDataProvider * - * @param int $year the year for which the holiday defined in this test needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which the holiday defined in this test needs to be tested + * @param \DateTime $expected the expected date */ public function testHoliday(int $year, \DateTimeInterface $expected): void { @@ -47,7 +45,7 @@ public function testHoliday(int $year, \DateTimeInterface $expected): void * * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function HolidayDataProvider(): array { @@ -57,7 +55,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -72,7 +70,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Norway/ConstitutionDayTest.php b/tests/Norway/ConstitutionDayTest.php index 03946d6ff..3c93657c2 100644 --- a/tests/Norway/ConstitutionDayTest.php +++ b/tests/Norway/ConstitutionDayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Norway; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -38,7 +35,7 @@ class ConstitutionDayTest extends NorwayBaseTestCase implements HolidayTestCase /** * Tests the holiday defined in this test on or after establishment. * - * @throws Exception + * @throws \Exception */ public function testHolidayOnAfterEstablishment(): void { @@ -47,14 +44,14 @@ public function testHolidayOnAfterEstablishment(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-5-17", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-5-17", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests the holiday defined in this test before establishment. * - * @throws Exception + * @throws \Exception */ public function testHolidayBeforeEstablishment(): void { @@ -68,7 +65,7 @@ public function testHolidayBeforeEstablishment(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -83,7 +80,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Norway/EasterMondayTest.php b/tests/Norway/EasterMondayTest.php index 333f8374b..b8e1a5060 100644 --- a/tests/Norway/EasterMondayTest.php +++ b/tests/Norway/EasterMondayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Norway; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -33,7 +30,7 @@ class EasterMondayTest extends NorwayBaseTestCase implements HolidayTestCase /** * Tests the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHoliday(): void { @@ -42,14 +39,14 @@ public function testHoliday(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-4-4", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-4-4", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -64,7 +61,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Norway/EasterTest.php b/tests/Norway/EasterTest.php index 098b921cf..9b00771fb 100644 --- a/tests/Norway/EasterTest.php +++ b/tests/Norway/EasterTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Norway; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -33,7 +30,7 @@ class EasterTest extends NorwayBaseTestCase implements HolidayTestCase /** * Tests the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHoliday(): void { @@ -42,14 +39,14 @@ public function testHoliday(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-4-3", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-4-3", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -64,7 +61,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Norway/GoodFridayTest.php b/tests/Norway/GoodFridayTest.php index 274d6ab66..715d1f726 100644 --- a/tests/Norway/GoodFridayTest.php +++ b/tests/Norway/GoodFridayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Norway; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -33,7 +30,7 @@ class GoodFridayTest extends NorwayBaseTestCase implements HolidayTestCase /** * Tests the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHoliday(): void { @@ -42,14 +39,14 @@ public function testHoliday(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-4-17", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-4-17", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -64,7 +61,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Norway/InternationalWorkersDayTest.php b/tests/Norway/InternationalWorkersDayTest.php index b79334b04..7f3642436 100644 --- a/tests/Norway/InternationalWorkersDayTest.php +++ b/tests/Norway/InternationalWorkersDayTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\Norway; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,8 +32,8 @@ class InternationalWorkersDayTest extends NorwayBaseTestCase implements HolidayT * * @dataProvider InternationalWorkersDayDataProvider * - * @param int $year the year for which International Workers' Day needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which International Workers' Day needs to be tested + * @param \DateTime $expected the expected date */ public function testInternationalWorkersDay(int $year, \DateTimeInterface $expected): void { @@ -45,7 +43,7 @@ public function testInternationalWorkersDay(int $year, \DateTimeInterface $expec /** * Tests translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -60,7 +58,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { @@ -72,7 +70,7 @@ public function testHolidayType(): void * * @return array list of test dates for International Workers' Day * - * @throws Exception + * @throws \Exception */ public function InternationalWorkersDayDataProvider(): array { diff --git a/tests/Norway/MaundyThursdayTest.php b/tests/Norway/MaundyThursdayTest.php index f2c0a03b8..fafe6b728 100644 --- a/tests/Norway/MaundyThursdayTest.php +++ b/tests/Norway/MaundyThursdayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Norway; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -33,7 +30,7 @@ class MaundyThursdayTest extends NorwayBaseTestCase implements HolidayTestCase /** * Tests the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHoliday(): void { @@ -42,14 +39,14 @@ public function testHoliday(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-4-12", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-4-12", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -64,7 +61,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Norway/NewYearsDayTest.php b/tests/Norway/NewYearsDayTest.php index 451096fd2..4b02ff9ce 100644 --- a/tests/Norway/NewYearsDayTest.php +++ b/tests/Norway/NewYearsDayTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\Norway; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,8 +32,8 @@ class NewYearsDayTest extends NorwayBaseTestCase implements HolidayTestCase * * @dataProvider HolidayDataProvider * - * @param int $year the year for which the holiday defined in this test needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which the holiday defined in this test needs to be tested + * @param \DateTime $expected the expected date */ public function testHoliday(int $year, \DateTimeInterface $expected): void { @@ -47,7 +45,7 @@ public function testHoliday(int $year, \DateTimeInterface $expected): void * * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function HolidayDataProvider(): array { @@ -57,7 +55,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -72,7 +70,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Norway/NorwayTest.php b/tests/Norway/NorwayTest.php index f2a8a0713..1886e26ef 100644 --- a/tests/Norway/NorwayTest.php +++ b/tests/Norway/NorwayTest.php @@ -14,7 +14,6 @@ namespace Yasumi\tests\Norway; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\ProviderTestCase; @@ -92,7 +91,7 @@ public function testOtherHolidays(): void } /** - * @throws ReflectionException + * @throws \ReflectionException * @throws \Exception */ public function testSources(): void diff --git a/tests/Norway/PentecostMondayTest.php b/tests/Norway/PentecostMondayTest.php index a472d8f81..a2f798840 100644 --- a/tests/Norway/PentecostMondayTest.php +++ b/tests/Norway/PentecostMondayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Norway; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -33,7 +30,7 @@ class PentecostMondayTest extends NorwayBaseTestCase implements HolidayTestCase /** * Tests the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHoliday(): void { @@ -42,14 +39,14 @@ public function testHoliday(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-6-10", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-6-10", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -64,7 +61,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Norway/PentecostTest.php b/tests/Norway/PentecostTest.php index ee793c19c..b214f6ed8 100644 --- a/tests/Norway/PentecostTest.php +++ b/tests/Norway/PentecostTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Norway; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -33,7 +30,7 @@ class PentecostTest extends NorwayBaseTestCase implements HolidayTestCase /** * Tests the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHoliday(): void { @@ -42,14 +39,14 @@ public function testHoliday(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-6-9", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-6-9", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -64,7 +61,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Norway/SecondChristmasDayTest.php b/tests/Norway/SecondChristmasDayTest.php index d068e09b6..e614bf9e6 100644 --- a/tests/Norway/SecondChristmasDayTest.php +++ b/tests/Norway/SecondChristmasDayTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\Norway; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,8 +32,8 @@ class SecondChristmasDayTest extends NorwayBaseTestCase implements HolidayTestCa * * @dataProvider HolidayDataProvider * - * @param int $year the year for which the holiday defined in this test needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which the holiday defined in this test needs to be tested + * @param \DateTime $expected the expected date */ public function testHoliday(int $year, \DateTimeInterface $expected): void { @@ -47,7 +45,7 @@ public function testHoliday(int $year, \DateTimeInterface $expected): void * * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function HolidayDataProvider(): array { @@ -57,7 +55,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -72,7 +70,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Poland/AllSaintsDayTest.php b/tests/Poland/AllSaintsDayTest.php index a04330ad6..66468fec2 100644 --- a/tests/Poland/AllSaintsDayTest.php +++ b/tests/Poland/AllSaintsDayTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\Poland; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,8 +32,8 @@ class AllSaintsDayTest extends PolandBaseTestCase implements HolidayTestCase * * @dataProvider HolidayDataProvider * - * @param int $year the year for which the holiday defined in this test needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which the holiday defined in this test needs to be tested + * @param \DateTime $expected the expected date */ public function testHoliday(int $year, \DateTimeInterface $expected): void { @@ -47,7 +45,7 @@ public function testHoliday(int $year, \DateTimeInterface $expected): void * * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function HolidayDataProvider(): array { @@ -57,7 +55,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -72,7 +70,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Poland/AssumptionOfMaryTest.php b/tests/Poland/AssumptionOfMaryTest.php index 0f42bb4c0..11aeb9f62 100644 --- a/tests/Poland/AssumptionOfMaryTest.php +++ b/tests/Poland/AssumptionOfMaryTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\Poland; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,8 +32,8 @@ class AssumptionOfMaryTest extends PolandBaseTestCase implements HolidayTestCase * * @dataProvider HolidayDataProvider * - * @param int $year the year for which the holiday defined in this test needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which the holiday defined in this test needs to be tested + * @param \DateTime $expected the expected date */ public function testHoliday(int $year, \DateTimeInterface $expected): void { @@ -47,7 +45,7 @@ public function testHoliday(int $year, \DateTimeInterface $expected): void * * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function HolidayDataProvider(): array { @@ -57,7 +55,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -72,7 +70,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Poland/ChristmasTest.php b/tests/Poland/ChristmasTest.php index 90945d0d7..aa9d093f4 100644 --- a/tests/Poland/ChristmasTest.php +++ b/tests/Poland/ChristmasTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\Poland; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,8 +32,8 @@ class ChristmasTest extends PolandBaseTestCase implements HolidayTestCase * * @dataProvider ChristmasDayDataProvider * - * @param int $year the year for which Christmas Day needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which Christmas Day needs to be tested + * @param \DateTime $expected the expected date */ public function testChristmasDay(int $year, \DateTimeInterface $expected): void { @@ -47,7 +45,7 @@ public function testChristmasDay(int $year, \DateTimeInterface $expected): void * * @return array list of test dates for Christmas Day * - * @throws Exception + * @throws \Exception */ public function ChristmasDayDataProvider(): array { @@ -57,7 +55,7 @@ public function ChristmasDayDataProvider(): array /** * Tests translated name of Christmas Day. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -72,7 +70,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Poland/ConstitutionDayTest.php b/tests/Poland/ConstitutionDayTest.php index 1376c3995..acae432e1 100644 --- a/tests/Poland/ConstitutionDayTest.php +++ b/tests/Poland/ConstitutionDayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Poland; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -38,7 +35,7 @@ class ConstitutionDayTest extends PolandBaseTestCase implements HolidayTestCase /** * Tests the holiday defined in this test on or after establishment. * - * @throws Exception + * @throws \Exception */ public function testHolidayOnAfterEstablishment(): void { @@ -47,14 +44,14 @@ public function testHolidayOnAfterEstablishment(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-5-3", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-5-3", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests the holiday defined in this test before establishment. * - * @throws Exception + * @throws \Exception */ public function testHolidayBeforeEstablishment(): void { @@ -68,7 +65,7 @@ public function testHolidayBeforeEstablishment(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -83,7 +80,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Poland/CorpusChristiTest.php b/tests/Poland/CorpusChristiTest.php index c3b446cd6..9ef515829 100644 --- a/tests/Poland/CorpusChristiTest.php +++ b/tests/Poland/CorpusChristiTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Poland; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -33,7 +30,7 @@ class CorpusChristiTest extends PolandBaseTestCase implements HolidayTestCase /** * Tests the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHoliday(): void { @@ -42,14 +39,14 @@ public function testHoliday(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-6-15", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-6-15", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests translated name of Corpus Christi. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -64,7 +61,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Poland/EasterMondayTest.php b/tests/Poland/EasterMondayTest.php index 3c9f29b08..37070cb6b 100644 --- a/tests/Poland/EasterMondayTest.php +++ b/tests/Poland/EasterMondayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Poland; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -33,7 +30,7 @@ class EasterMondayTest extends PolandBaseTestCase implements HolidayTestCase /** * Tests the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHoliday(): void { @@ -42,14 +39,14 @@ public function testHoliday(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-4-17", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-4-17", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -64,7 +61,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Poland/EasterTest.php b/tests/Poland/EasterTest.php index cf3a22d3c..5910008c4 100644 --- a/tests/Poland/EasterTest.php +++ b/tests/Poland/EasterTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Poland; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -33,7 +30,7 @@ class EasterTest extends PolandBaseTestCase implements HolidayTestCase /** * Tests the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHoliday(): void { @@ -42,14 +39,14 @@ public function testHoliday(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-4-12", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-4-12", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -64,7 +61,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Poland/EpiphanyTest.php b/tests/Poland/EpiphanyTest.php index abc4c72c1..39f93d80c 100644 --- a/tests/Poland/EpiphanyTest.php +++ b/tests/Poland/EpiphanyTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\Poland; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,8 +32,8 @@ class EpiphanyTest extends PolandBaseTestCase implements HolidayTestCase * * @dataProvider EpiphanyDataProvider * - * @param int $year the year for which Epiphany needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which Epiphany needs to be tested + * @param \DateTime $expected the expected date */ public function testEpiphany(int $year, \DateTimeInterface $expected): void { @@ -47,7 +45,7 @@ public function testEpiphany(int $year, \DateTimeInterface $expected): void * * @return array list of test dates for Epiphany * - * @throws Exception + * @throws \Exception */ public function EpiphanyDataProvider(): array { @@ -57,7 +55,7 @@ public function EpiphanyDataProvider(): array /** * Tests translated name of Epiphany. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -72,7 +70,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Poland/IndependenceDayTest.php b/tests/Poland/IndependenceDayTest.php index 7f51f3f74..e5363ce42 100644 --- a/tests/Poland/IndependenceDayTest.php +++ b/tests/Poland/IndependenceDayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Poland; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -38,7 +35,7 @@ class IndependenceDayTest extends PolandBaseTestCase implements HolidayTestCase /** * Tests the holiday defined in this test on or after establishment. * - * @throws Exception + * @throws \Exception */ public function testHolidayOnAfterEstablishment(): void { @@ -47,14 +44,14 @@ public function testHolidayOnAfterEstablishment(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-11-11", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-11-11", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests the holiday defined in this test before establishment. * - * @throws Exception + * @throws \Exception */ public function testHolidayBeforeEstablishment(): void { @@ -68,7 +65,7 @@ public function testHolidayBeforeEstablishment(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -83,7 +80,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Poland/InternationalWorkersDayTest.php b/tests/Poland/InternationalWorkersDayTest.php index ba0c0c14e..072b10ff2 100644 --- a/tests/Poland/InternationalWorkersDayTest.php +++ b/tests/Poland/InternationalWorkersDayTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\Poland; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,8 +32,8 @@ class InternationalWorkersDayTest extends PolandBaseTestCase implements HolidayT * * @dataProvider InternationalWorkersDayDataProvider * - * @param int $year the year for which International Workers' Day needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which International Workers' Day needs to be tested + * @param \DateTime $expected the expected date */ public function testInternationalWorkersDay(int $year, \DateTimeInterface $expected): void { @@ -45,7 +43,7 @@ public function testInternationalWorkersDay(int $year, \DateTimeInterface $expec /** * Tests translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -60,7 +58,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { @@ -72,7 +70,7 @@ public function testHolidayType(): void * * @return array list of test dates for International Workers' Day * - * @throws Exception + * @throws \Exception */ public function InternationalWorkersDayDataProvider(): array { diff --git a/tests/Poland/NewYearsDayTest.php b/tests/Poland/NewYearsDayTest.php index d0b28620a..955ef1682 100644 --- a/tests/Poland/NewYearsDayTest.php +++ b/tests/Poland/NewYearsDayTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\Poland; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,8 +32,8 @@ class NewYearsDayTest extends PolandBaseTestCase implements HolidayTestCase * * @dataProvider HolidayDataProvider * - * @param int $year the year for which the holiday defined in this test needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which the holiday defined in this test needs to be tested + * @param \DateTime $expected the expected date */ public function testHoliday(int $year, \DateTimeInterface $expected): void { @@ -47,7 +45,7 @@ public function testHoliday(int $year, \DateTimeInterface $expected): void * * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function HolidayDataProvider(): array { @@ -57,7 +55,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -72,7 +70,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Poland/PentecostTest.php b/tests/Poland/PentecostTest.php index 324862c4d..1f5a145d7 100644 --- a/tests/Poland/PentecostTest.php +++ b/tests/Poland/PentecostTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Poland; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -33,7 +30,7 @@ class PentecostTest extends PolandBaseTestCase implements HolidayTestCase /** * Tests the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHoliday(): void { @@ -42,14 +39,14 @@ public function testHoliday(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-6-9", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-6-9", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -64,7 +61,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Poland/PolandTest.php b/tests/Poland/PolandTest.php index cb143e78a..3e173509f 100644 --- a/tests/Poland/PolandTest.php +++ b/tests/Poland/PolandTest.php @@ -14,7 +14,6 @@ namespace Yasumi\tests\Poland; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\ProviderTestCase; @@ -93,7 +92,7 @@ public function testOtherHolidays(): void } /** - * @throws ReflectionException + * @throws \ReflectionException * @throws \Exception */ public function testSources(): void diff --git a/tests/Poland/SecondChristmasDayTest.php b/tests/Poland/SecondChristmasDayTest.php index 83dfcf003..45900ebf8 100644 --- a/tests/Poland/SecondChristmasDayTest.php +++ b/tests/Poland/SecondChristmasDayTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\Poland; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,8 +32,8 @@ class SecondChristmasDayTest extends PolandBaseTestCase implements HolidayTestCa * * @dataProvider HolidayDataProvider * - * @param int $year the year for which the holiday defined in this test needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which the holiday defined in this test needs to be tested + * @param \DateTime $expected the expected date */ public function testHoliday(int $year, \DateTimeInterface $expected): void { @@ -47,7 +45,7 @@ public function testHoliday(int $year, \DateTimeInterface $expected): void * * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function HolidayDataProvider(): array { @@ -57,7 +55,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -72,7 +70,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Portugal/AllSaintsDayTest.php b/tests/Portugal/AllSaintsDayTest.php index 877d69f11..ca22bfd72 100644 --- a/tests/Portugal/AllSaintsDayTest.php +++ b/tests/Portugal/AllSaintsDayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Portugal; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -43,23 +40,23 @@ class AllSaintsDayTest extends PortugalBaseTestCase implements HolidayTestCase /** * Tests the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHoliday(): void { $year = 2016; - $expected = new DateTime("$year-11-01", new DateTimeZone(self::TIMEZONE)); + $expected = new \DateTime("$year-11-01", new \DateTimeZone(self::TIMEZONE)); $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); $year = 2012; - $expected = new DateTime("$year-11-01", new DateTimeZone(self::TIMEZONE)); + $expected = new \DateTime("$year-11-01", new \DateTimeZone(self::TIMEZONE)); $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } /** * Test that the holiday did not happen in 2013-2015. * - * @throws Exception + * @throws \Exception */ public function testNotHoliday(): void { @@ -70,7 +67,7 @@ public function testNotHoliday(): void /** * Tests translated name of Corpus Christi. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -86,7 +83,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Portugal/AssumptionOfMaryTest.php b/tests/Portugal/AssumptionOfMaryTest.php index f51f2fe57..d7dfe41ae 100644 --- a/tests/Portugal/AssumptionOfMaryTest.php +++ b/tests/Portugal/AssumptionOfMaryTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\Portugal; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,8 +32,8 @@ class AssumptionOfMaryTest extends PortugalBaseTestCase implements HolidayTestCa * * @dataProvider HolidayDataProvider * - * @param int $year the year for which the holiday defined in this test needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which the holiday defined in this test needs to be tested + * @param \DateTime $expected the expected date */ public function testHoliday(int $year, \DateTimeInterface $expected): void { @@ -47,7 +45,7 @@ public function testHoliday(int $year, \DateTimeInterface $expected): void * * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function HolidayDataProvider(): array { @@ -57,7 +55,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -72,7 +70,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Portugal/CarnationRevolutionDayTest.php b/tests/Portugal/CarnationRevolutionDayTest.php index 38a464542..b452f7482 100644 --- a/tests/Portugal/CarnationRevolutionDayTest.php +++ b/tests/Portugal/CarnationRevolutionDayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Portugal; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -38,19 +35,19 @@ class CarnationRevolutionDayTest extends PortugalBaseTestCase implements Holiday /** * Test that the holiday is valid after the year of establishment. * - * @throws Exception + * @throws \Exception */ public function testHolidayAfterEstablishment(): void { $year = $this->generateRandomYear(self::ESTABLISHMENT_YEAR); - $expected = new DateTime("$year-04-25", new DateTimeZone(self::TIMEZONE)); + $expected = new \DateTime("$year-04-25", new \DateTimeZone(self::TIMEZONE)); $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } /** * Tests that the holiday is not a holiday before the year of establishment. * - * @throws Exception + * @throws \Exception */ public function testNotHolidayBeforeEstablishment(): void { @@ -61,7 +58,7 @@ public function testNotHolidayBeforeEstablishment(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -72,7 +69,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Portugal/ChristmasTest.php b/tests/Portugal/ChristmasTest.php index f6a837e51..169e99c22 100644 --- a/tests/Portugal/ChristmasTest.php +++ b/tests/Portugal/ChristmasTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\Portugal; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,8 +32,8 @@ class ChristmasTest extends PortugalBaseTestCase implements HolidayTestCase * * @dataProvider ChristmasDayDataProvider * - * @param int $year the year for which Christmas Day needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which Christmas Day needs to be tested + * @param \DateTime $expected the expected date */ public function testChristmasDay(int $year, \DateTimeInterface $expected): void { @@ -47,7 +45,7 @@ public function testChristmasDay(int $year, \DateTimeInterface $expected): void * * @return array list of test dates for Christmas Day * - * @throws Exception + * @throws \Exception */ public function ChristmasDayDataProvider(): array { @@ -57,7 +55,7 @@ public function ChristmasDayDataProvider(): array /** * Tests translated name of Christmas Day. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -72,7 +70,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Portugal/CorpusChristiTest.php b/tests/Portugal/CorpusChristiTest.php index 07450e48c..9b9e9b30d 100644 --- a/tests/Portugal/CorpusChristiTest.php +++ b/tests/Portugal/CorpusChristiTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Portugal; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -43,19 +40,19 @@ class CorpusChristiTest extends PortugalBaseTestCase implements HolidayTestCase /** * Tests the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHoliday(): void { $year = 2016; - $expected = new DateTime("$year-5-26", new DateTimeZone(self::TIMEZONE)); + $expected = new \DateTime("$year-5-26", new \DateTimeZone(self::TIMEZONE)); $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } /** * Test that the holiday did not happen in 2013-2015. * - * @throws Exception + * @throws \Exception */ public function testNotHoliday(): void { @@ -66,7 +63,7 @@ public function testNotHoliday(): void /** * Tests translated name of Corpus Christi. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -77,7 +74,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Portugal/EasterTest.php b/tests/Portugal/EasterTest.php index f1d701ea2..87b09ccfc 100644 --- a/tests/Portugal/EasterTest.php +++ b/tests/Portugal/EasterTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Portugal; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -33,7 +30,7 @@ class EasterTest extends PortugalBaseTestCase implements HolidayTestCase /** * Tests the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHoliday(): void { @@ -42,14 +39,14 @@ public function testHoliday(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-03-27", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-03-27", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -64,7 +61,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Portugal/GoodFridayTest.php b/tests/Portugal/GoodFridayTest.php index 33d85bb58..c07351b7e 100644 --- a/tests/Portugal/GoodFridayTest.php +++ b/tests/Portugal/GoodFridayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Portugal; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -33,7 +30,7 @@ class GoodFridayTest extends PortugalBaseTestCase implements HolidayTestCase /** * Tests the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHoliday(): void { @@ -42,14 +39,14 @@ public function testHoliday(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-3-25", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-3-25", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -64,7 +61,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Portugal/ImmaculateConceptionTest.php b/tests/Portugal/ImmaculateConceptionTest.php index a169721de..c4b1dc36c 100644 --- a/tests/Portugal/ImmaculateConceptionTest.php +++ b/tests/Portugal/ImmaculateConceptionTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\Portugal; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,8 +32,8 @@ class ImmaculateConceptionTest extends PortugalBaseTestCase implements HolidayTe * * @dataProvider HolidayDataProvider * - * @param int $year the year for which the holiday defined in this test needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which the holiday defined in this test needs to be tested + * @param \DateTime $expected the expected date */ public function testHoliday(int $year, \DateTimeInterface $expected): void { @@ -47,7 +45,7 @@ public function testHoliday(int $year, \DateTimeInterface $expected): void * * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function HolidayDataProvider(): array { @@ -57,7 +55,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -72,7 +70,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Portugal/InternationalWorkersDayTest.php b/tests/Portugal/InternationalWorkersDayTest.php index 3a2c4fd75..720735db7 100644 --- a/tests/Portugal/InternationalWorkersDayTest.php +++ b/tests/Portugal/InternationalWorkersDayTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\Portugal; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,8 +32,8 @@ class InternationalWorkersDayTest extends PortugalBaseTestCase implements Holida * * @dataProvider InternationalWorkersDayDataProvider * - * @param int $year the year for which International Workers' Day needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which International Workers' Day needs to be tested + * @param \DateTime $expected the expected date */ public function testInternationalWorkersDay(int $year, \DateTimeInterface $expected): void { @@ -45,7 +43,7 @@ public function testInternationalWorkersDay(int $year, \DateTimeInterface $expec /** * Tests translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -60,7 +58,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { @@ -72,7 +70,7 @@ public function testHolidayType(): void * * @return array list of test dates for International Workers' Day * - * @throws Exception + * @throws \Exception */ public function InternationalWorkersDayDataProvider(): array { diff --git a/tests/Portugal/NewYearsDayTest.php b/tests/Portugal/NewYearsDayTest.php index 9c64ede83..564a0bf31 100644 --- a/tests/Portugal/NewYearsDayTest.php +++ b/tests/Portugal/NewYearsDayTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\Portugal; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,8 +32,8 @@ class NewYearsDayTest extends PortugalBaseTestCase implements HolidayTestCase * * @dataProvider HolidayDataProvider * - * @param int $year the year for which the holiday defined in this test needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which the holiday defined in this test needs to be tested + * @param \DateTime $expected the expected date */ public function testHoliday(int $year, \DateTimeInterface $expected): void { @@ -47,7 +45,7 @@ public function testHoliday(int $year, \DateTimeInterface $expected): void * * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function HolidayDataProvider(): array { @@ -57,7 +55,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -72,7 +70,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Portugal/PortugalDayTest.php b/tests/Portugal/PortugalDayTest.php index 14802fef8..7b8945ca0 100644 --- a/tests/Portugal/PortugalDayTest.php +++ b/tests/Portugal/PortugalDayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Portugal; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\Provider\Portugal; use Yasumi\tests\HolidayTestCase; @@ -44,35 +41,35 @@ class PortugalDayTest extends PortugalBaseTestCase implements HolidayTestCase /** * Tests the holiday defined in this test before it was abolished. * - * @throws Exception + * @throws \Exception * * @see Portugal::calculatePortugalDay() */ public function testHolidayBeforeAbolishment(): void { $year = $this->generateRandomYear(1000, self::ESTABLISHMENT_YEAR_BEFORE); - $expected = new DateTime("$year-06-10", new DateTimeZone(self::TIMEZONE)); + $expected = new \DateTime("$year-06-10", new \DateTimeZone(self::TIMEZONE)); $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } /** * Tests the holiday defined in this test after it was restored. * - * @throws Exception + * @throws \Exception * * @see Portugal::calculatePortugalDay() */ public function testHolidayAfterRestoration(): void { $year = $this->generateRandomYear(self::ESTABLISHMENT_YEAR_AFTER); - $expected = new DateTime("$year-06-10", new DateTimeZone(self::TIMEZONE)); + $expected = new \DateTime("$year-06-10", new \DateTimeZone(self::TIMEZONE)); $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } /** * Tests that the holiday defined in this test does not exist during the period that it was abolished. * - * @throws Exception + * @throws \Exception * * @see Portugal::calculatePortugalDay() */ @@ -88,7 +85,7 @@ public function testNotHolidayDuringAbolishment(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -102,7 +99,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Portugal/PortugalTest.php b/tests/Portugal/PortugalTest.php index 943cdd3fe..95ef29bd6 100644 --- a/tests/Portugal/PortugalTest.php +++ b/tests/Portugal/PortugalTest.php @@ -14,7 +14,6 @@ namespace Yasumi\tests\Portugal; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\ProviderTestCase; @@ -103,7 +102,7 @@ public function testOtherHolidays(): void } /** - * @throws ReflectionException + * @throws \ReflectionException * @throws \Exception */ public function testSources(): void diff --git a/tests/Portugal/PortugueseRepublicDayTest.php b/tests/Portugal/PortugueseRepublicDayTest.php index 78159720f..e8a4002f0 100644 --- a/tests/Portugal/PortugueseRepublicDayTest.php +++ b/tests/Portugal/PortugueseRepublicDayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Portugal; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -31,7 +28,7 @@ class PortugueseRepublicDayTest extends PortugalBaseTestCase implements HolidayT public const HOLIDAY = 'portugueseRepublic'; /** - * @throws Exception + * @throws \Exception */ public function testHolidayOnAfterRestoration(): void { @@ -40,13 +37,13 @@ public function testHolidayOnAfterRestoration(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-10-05", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-10-05", new \DateTimeZone(self::TIMEZONE)) ); } } /** - * @throws Exception + * @throws \Exception */ public function testNotHolidayDuringAbolishment(): void { @@ -58,7 +55,7 @@ public function testNotHolidayDuringAbolishment(): void } /** - * @throws Exception + * @throws \Exception */ public function testHolidayOnAfterEstablishment(): void { @@ -67,7 +64,7 @@ public function testHolidayOnAfterEstablishment(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-10-05", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-10-05", new \DateTimeZone(self::TIMEZONE)) ); } } @@ -78,7 +75,7 @@ public function testHolidayBeforeEstablishment(): void foreach ($this->randomYearsBeforeEstablishment() as $year) { $this->assertNotHoliday(self::REGION, self::HOLIDAY, $year); } - } catch (Exception $e) { + } catch (\Exception $e) { } } @@ -93,7 +90,7 @@ public function testTranslation(): void [self::LOCALE => 'Implantação da República Portuguesa'] ); } - } catch (Exception $e) { + } catch (\Exception $e) { } } @@ -108,12 +105,12 @@ public function testHolidayType(): void Holiday::TYPE_OFFICIAL ); } - } catch (Exception $e) { + } catch (\Exception $e) { } } /** @return \Generator - * @throws Exception + * @throws \Exception */ private function randomEstablishedYear(): \Generator { @@ -122,7 +119,7 @@ private function randomEstablishedYear(): \Generator } /** @return \Generator - * @throws Exception + * @throws \Exception */ private function randomYearsBeforeEstablishment(): \Generator { @@ -131,7 +128,7 @@ private function randomYearsBeforeEstablishment(): \Generator } /** @return \Generator - * @throws Exception + * @throws \Exception */ private function randomYearsOnAfterEstablishment(): \Generator { @@ -140,7 +137,7 @@ private function randomYearsOnAfterEstablishment(): \Generator } /** @return \Generator - * @throws Exception + * @throws \Exception */ private function randomYearsOnAfterRestoration(): \Generator { diff --git a/tests/Portugal/RestorationOfIndependenceTest.php b/tests/Portugal/RestorationOfIndependenceTest.php index 87204ab9d..89df30275 100644 --- a/tests/Portugal/RestorationOfIndependenceTest.php +++ b/tests/Portugal/RestorationOfIndependenceTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Portugal; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -48,43 +45,43 @@ class RestorationOfIndependenceTest extends PortugalBaseTestCase implements Holi /** * Tests the holiday defined in this test on or after establishment. * - * @throws Exception + * @throws \Exception */ public function testHolidayOnAfterEstablishment(): void { $year = $this->generateRandomYear(self::ESTABLISHMENT_YEAR, self::HOLIDAY_YEAR_ABOLISHED - 1); - $expected = new DateTime("$year-12-01", new DateTimeZone(self::TIMEZONE)); + $expected = new \DateTime("$year-12-01", new \DateTimeZone(self::TIMEZONE)); $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); $year = self::ESTABLISHMENT_YEAR; - $expected = new DateTime("$year-12-01", new DateTimeZone(self::TIMEZONE)); + $expected = new \DateTime("$year-12-01", new \DateTimeZone(self::TIMEZONE)); $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } /** * Test that the holiday if in effect in 2016 and later dates. * - * @throws Exception - * @throws Exception + * @throws \Exception + * @throws \Exception */ public function testHolidayOnAfterRestoration(): void { $year = 2016; - $expected = new DateTime("$year-12-01", new DateTimeZone(self::TIMEZONE)); + $expected = new \DateTime("$year-12-01", new \DateTimeZone(self::TIMEZONE)); $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); $year = $this->generateRandomYear(self::HOLIDAY_YEAR_RESTORED); - $expected = new DateTime("$year-12-01", new DateTimeZone(self::TIMEZONE)); + $expected = new \DateTime("$year-12-01", new \DateTimeZone(self::TIMEZONE)); $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $expected); } /** * Test that the holiday did not happen in 2013-2015. * - * @throws Exception + * @throws \Exception */ public function testNotHolidayDuringAbolishment(): void { @@ -95,7 +92,7 @@ public function testNotHolidayDuringAbolishment(): void /** * Tests the holiday defined in this test before establishment. * - * @throws Exception + * @throws \Exception */ public function testHolidayBeforeEstablishment(): void { @@ -109,7 +106,7 @@ public function testHolidayBeforeEstablishment(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -133,7 +130,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Randomizer.php b/tests/Randomizer.php index 2e58dbf9e..8d70250a8 100644 --- a/tests/Randomizer.php +++ b/tests/Randomizer.php @@ -15,11 +15,7 @@ namespace Yasumi\tests; -use DateInterval; use DateTime; -use DateTimeInterface; -use DateTimeZone; -use Exception; use Yasumi\Holiday; /** @@ -40,7 +36,7 @@ trait Randomizer * * @return array list of random test dates used for assertion of holidays * - * @throws Exception + * @throws \Exception */ public function generateRandomDates( int $month, @@ -53,7 +49,7 @@ public function generateRandomDates( $range ??= 1000; for ($y = 1; $y <= ($iterations ?? 10); ++$y) { $year = (int) self::dateTimeBetween("-$range years", "+$range years")->format('Y'); - $data[] = [$year, new DateTime("$year-$month-$day", new DateTimeZone($timezone ?? 'UTC'))]; + $data[] = [$year, new \DateTime("$year-$month-$day", new \DateTimeZone($timezone ?? 'UTC'))]; } return $data; @@ -68,7 +64,7 @@ public function generateRandomDates( * * @return array list of random easter test dates used for assertion of holidays * - * @throws Exception + * @throws \Exception */ public function generateRandomEasterDates( string $timezone = null, @@ -97,7 +93,7 @@ public function generateRandomEasterDates( * * @return array list of random Easter Monday test dates used for assertion of holidays * - * @throws Exception + * @throws \Exception */ public function generateRandomEasterMondayDates( string $timezone = null, @@ -106,8 +102,8 @@ public function generateRandomEasterMondayDates( ): array { $range ??= 1000; - return $this->generateRandomModifiedEasterDates(static function (DateTime $date): void { - $date->add(new DateInterval('P1D')); + return $this->generateRandomModifiedEasterDates(static function (\DateTime $date): void { + $date->add(new \DateInterval('P1D')); }, $timezone ?? 'UTC', $iterations ?? 10, $range); } @@ -121,7 +117,7 @@ public function generateRandomEasterMondayDates( * * @return array list of random modified Easter day test dates for assertion of holidays * - * @throws Exception + * @throws \Exception */ public function generateRandomModifiedEasterDates( callable $cb, @@ -152,7 +148,7 @@ public function generateRandomModifiedEasterDates( * * @return array list of random Good Friday test dates used for assertion of holidays * - * @throws Exception + * @throws \Exception */ public function generateRandomGoodFridayDates( string $timezone = null, @@ -161,8 +157,8 @@ public function generateRandomGoodFridayDates( ): array { $range ??= 1000; - return $this->generateRandomModifiedEasterDates(static function (DateTime $date): void { - $date->sub(new DateInterval('P2D')); + return $this->generateRandomModifiedEasterDates(static function (\DateTime $date): void { + $date->sub(new \DateInterval('P2D')); }, $timezone ?? 'UTC', $iterations ?? 10, $range); } @@ -175,7 +171,7 @@ public function generateRandomGoodFridayDates( * * @return array list of random Pentecost test dates used for assertion of holidays * - * @throws Exception + * @throws \Exception */ public function generateRandomPentecostDates( string $timezone = null, @@ -184,8 +180,8 @@ public function generateRandomPentecostDates( ): array { $range ??= 1000; - return $this->generateRandomModifiedEasterDates(static function (DateTime $date): void { - $date->add(new DateInterval('P49D')); + return $this->generateRandomModifiedEasterDates(static function (\DateTime $date): void { + $date->add(new \DateInterval('P49D')); }, $timezone ?? 'UTC', $iterations ?? 10, $range); } @@ -201,7 +197,7 @@ public function generateRandomPentecostDates( * * @return array list of random test dates used for assertion of holidays * - * @throws Exception + * @throws \Exception */ public function generateRandomDatesWithHolidayMovedToMonday( int $month, @@ -210,7 +206,7 @@ public function generateRandomDatesWithHolidayMovedToMonday( int $iterations = null, int $range = null ): array { - return $this->generateRandomDatesWithModifier($month, $day, function ($range, DateTime $date): void { + return $this->generateRandomDatesWithModifier($month, $day, function ($range, \DateTime $date): void { if ($this->isWeekend($date)) { $date->modify('next monday'); } @@ -229,7 +225,7 @@ public function generateRandomDatesWithHolidayMovedToMonday( * * @return array list of random test dates used for assertion of holidays with an applied callback * - * @throws Exception + * @throws \Exception */ public function generateRandomDatesWithModifier( int $month, @@ -243,7 +239,7 @@ public function generateRandomDatesWithModifier( for ($i = 1; $i <= $iterations; ++$i) { $year = $this->generateRandomYear($range); - $date = new DateTime("$year-$month-$day", new DateTimeZone($timezone ?? 'UTC')); + $date = new \DateTime("$year-$month-$day", new \DateTimeZone($timezone ?? 'UTC')); $callback($year, $date); @@ -261,7 +257,7 @@ public function generateRandomDatesWithModifier( * * @return int a year number * - * @throws Exception + * @throws \Exception */ public function generateRandomYear( int $lowerLimit = null, @@ -273,13 +269,13 @@ public function generateRandomYear( /** * Checks if given $dateTime is a weekend. * - * @param DateTimeInterface $dateTime date for which weekend will be checked - * @param array $weekendDays weekend days. Saturday and Sunday are used by default. + * @param \DateTimeInterface $dateTime date for which weekend will be checked + * @param array $weekendDays weekend days. Saturday and Sunday are used by default. * * @return bool true if $dateTime is a weekend, false otherwise */ public function isWeekend( - DateTimeInterface $dateTime, + \DateTimeInterface $dateTime, array $weekendDays = [0, 6] ): bool { return \in_array((int) $dateTime->format('w'), $weekendDays, true); @@ -288,7 +284,7 @@ public function isWeekend( /** * Returns a random number between $int1 and $int2 (any order). * - * @throws Exception + * @throws \Exception * * @example 79907610 */ @@ -308,14 +304,14 @@ public static function numberBetween(int $int1 = 0, int $int2 = 2_147_483_647): * @param \DateTime|string $endDate Defaults to "now" * @param string|null $timezone time zone in which the date time should be set, default to DateTime::$defaultTimezone, if set, otherwise the result of `date_default_timezone_get` * - * @throws Exception + * @throws \Exception * * @see http://php.net/manual/en/timezones.php * @see http://php.net/manual/en/function.date-default-timezone-get.php * * @example DateTime('1999-02-02 11:42:52') */ - public static function dateTimeBetween($startDate = '-30 years', $endDate = 'now', $timezone = null): DateTimeInterface + public static function dateTimeBetween($startDate = '-30 years', $endDate = 'now', $timezone = null): \DateTimeInterface { $startTimestamp = $startDate instanceof \DateTime ? $startDate->getTimestamp() : strtotime($startDate); @@ -365,16 +361,16 @@ public function randomYearFromArray(array $years): int * @param int $year year for which Easter needs to be calculated * @param string $timezone timezone in which Easter is celebrated * - * @return DateTime date of Easter + * @return \DateTime date of Easter * - * @throws Exception + * @throws \Exception * * @see easter_days * @see https://github.com/php/php-src/blob/c8aa6f3a9a3d2c114d0c5e0c9fdd0a465dbb54a5/ext/calendar/easter.c * @see http://www.gmarts.org/index.php?go=415#EasterMallen * @see http://www.tondering.dk/claus/cal/easter.php */ - protected function calculateEaster(int $year, string $timezone): DateTimeInterface + protected function calculateEaster(int $year, string $timezone): \DateTimeInterface { if (\extension_loaded('calendar')) { $easter_days = easter_days($year); @@ -423,8 +419,8 @@ protected function calculateEaster(int $year, string $timezone): DateTimeInterfa $easter_days = ($pfm + $tmp + 1); // Easter as the number of days after 21st March } - $easter = new DateTime("$year-3-21", new DateTimeZone($timezone)); - $easter->add(new DateInterval('P'.$easter_days.'D')); + $easter = new \DateTime("$year-3-21", new \DateTimeZone($timezone)); + $easter->add(new \DateInterval('P'.$easter_days.'D')); return $easter; } @@ -447,7 +443,7 @@ protected static function getMaxTimestamp($max = 'now') return $ts; } - private static function setTimezone(DateTimeInterface $dt, ?string $timezone): DateTimeInterface + private static function setTimezone(\DateTimeInterface $dt, ?string $timezone): \DateTimeInterface { return $dt->setTimezone(new \DateTimeZone(static::resolveTimezone($timezone))); } diff --git a/tests/Romania/AssumptionOfMaryTest.php b/tests/Romania/AssumptionOfMaryTest.php index 22073f325..54d860dc9 100644 --- a/tests/Romania/AssumptionOfMaryTest.php +++ b/tests/Romania/AssumptionOfMaryTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Romania; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -38,7 +35,7 @@ class AssumptionOfMaryTest extends RomaniaBaseTestCase implements HolidayTestCas /** * Tests Assumption Of Mary Day on or after 2008. * - * @throws Exception + * @throws \Exception */ public function testAssumptionOfMaryDayOnAfter2008(): void { @@ -47,14 +44,14 @@ public function testAssumptionOfMaryDayOnAfter2008(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-8-15", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-8-15", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests Assumption of Mary Day before 2008. * - * @throws Exception + * @throws \Exception */ public function testAssumptionOfMaryDayBefore2008(): void { @@ -68,7 +65,7 @@ public function testAssumptionOfMaryDayBefore2008(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -83,7 +80,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Romania/ChildrensDayTest.php b/tests/Romania/ChildrensDayTest.php index c4d676297..88d42c5dd 100644 --- a/tests/Romania/ChildrensDayTest.php +++ b/tests/Romania/ChildrensDayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Romania; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -38,7 +35,7 @@ class ChildrensDayTest extends RomaniaBaseTestCase implements HolidayTestCase /** * Tests Children's Day on or after 1950. * - * @throws Exception + * @throws \Exception */ public function testChildrensDayOnAfter1950(): void { @@ -47,14 +44,14 @@ public function testChildrensDayOnAfter1950(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-06-01", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-06-01", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests Children's Day before 1950. * - * @throws Exception + * @throws \Exception */ public function testChildrensDayBefore1950(): void { @@ -68,7 +65,7 @@ public function testChildrensDayBefore1950(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -83,7 +80,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Romania/ChristmasDayTest.php b/tests/Romania/ChristmasDayTest.php index ca6dea968..6ca7b0273 100644 --- a/tests/Romania/ChristmasDayTest.php +++ b/tests/Romania/ChristmasDayTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\Romania; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,8 +32,8 @@ class ChristmasDayTest extends RomaniaBaseTestCase implements HolidayTestCase * * @dataProvider HolidayDataProvider * - * @param int $year the year for which the holiday defined in this test needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which the holiday defined in this test needs to be tested + * @param \DateTime $expected the expected date */ public function testHoliday(int $year, \DateTimeInterface $expected): void { @@ -47,7 +45,7 @@ public function testHoliday(int $year, \DateTimeInterface $expected): void * * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function HolidayDataProvider(): array { @@ -57,7 +55,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -72,7 +70,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Romania/ConstantinBrancusiDayTest.php b/tests/Romania/ConstantinBrancusiDayTest.php index 761907f19..6132496c1 100644 --- a/tests/Romania/ConstantinBrancusiDayTest.php +++ b/tests/Romania/ConstantinBrancusiDayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Romania; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -38,7 +35,7 @@ class ConstantinBrancusiDayTest extends RomaniaBaseTestCase implements HolidayTe /** * Tests Constantin Brancusi Day on or after 2016. * - * @throws Exception + * @throws \Exception */ public function testConstantinBrancusiDayOnAfter2016(): void { @@ -47,14 +44,14 @@ public function testConstantinBrancusiDayOnAfter2016(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-02-19", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-02-19", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests Constantin Brancusi Day before 2016. * - * @throws Exception + * @throws \Exception */ public function testConstantinBrancusiDayBefore2016(): void { @@ -68,7 +65,7 @@ public function testConstantinBrancusiDayBefore2016(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -83,7 +80,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Romania/DayAfterNewYearsDayTest.php b/tests/Romania/DayAfterNewYearsDayTest.php index 85e4c14e4..44a7cb856 100644 --- a/tests/Romania/DayAfterNewYearsDayTest.php +++ b/tests/Romania/DayAfterNewYearsDayTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\Romania; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,8 +32,8 @@ class DayAfterNewYearsDayTest extends RomaniaBaseTestCase implements HolidayTest * * @dataProvider HolidayDataProvider * - * @param int $year the year for which the holiday defined in this test needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which the holiday defined in this test needs to be tested + * @param \DateTime $expected the expected date */ public function testHoliday(int $year, \DateTimeInterface $expected): void { @@ -47,7 +45,7 @@ public function testHoliday(int $year, \DateTimeInterface $expected): void * * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function HolidayDataProvider(): array { @@ -57,7 +55,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -72,7 +70,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Romania/EasterMondayTest.php b/tests/Romania/EasterMondayTest.php index a918af0a3..b2e637785 100644 --- a/tests/Romania/EasterMondayTest.php +++ b/tests/Romania/EasterMondayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Romania; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -33,7 +30,7 @@ class EasterMondayTest extends RomaniaBaseTestCase implements HolidayTestCase /** * Tests the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHoliday(): void { @@ -42,14 +39,14 @@ public function testHoliday(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-04-20", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-04-20", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -64,7 +61,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Romania/EasterTest.php b/tests/Romania/EasterTest.php index ff87b3532..3ae92f6ae 100644 --- a/tests/Romania/EasterTest.php +++ b/tests/Romania/EasterTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Romania; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -33,7 +30,7 @@ class EasterTest extends RomaniaBaseTestCase implements HolidayTestCase /** * Tests the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHoliday(): void { @@ -42,14 +39,14 @@ public function testHoliday(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-04-19", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-04-19", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -64,7 +61,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Romania/InternationalWorkersDayTest.php b/tests/Romania/InternationalWorkersDayTest.php index 6db5dc108..050d9bef5 100644 --- a/tests/Romania/InternationalWorkersDayTest.php +++ b/tests/Romania/InternationalWorkersDayTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\Romania; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,8 +32,8 @@ class InternationalWorkersDayTest extends RomaniaBaseTestCase implements Holiday * * @dataProvider InternationalWorkersDayDataProvider * - * @param int $year the year for which International Workers' Day needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which International Workers' Day needs to be tested + * @param \DateTime $expected the expected date */ public function testInternationalWorkersDay(int $year, \DateTimeInterface $expected): void { @@ -45,7 +43,7 @@ public function testInternationalWorkersDay(int $year, \DateTimeInterface $expec /** * Tests translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -60,7 +58,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { @@ -72,7 +70,7 @@ public function testHolidayType(): void * * @return array list of test dates for International Workers' Day * - * @throws Exception + * @throws \Exception */ public function InternationalWorkersDayDataProvider(): array { diff --git a/tests/Romania/NationalDayTest.php b/tests/Romania/NationalDayTest.php index 151a1d83d..95e20e3fb 100644 --- a/tests/Romania/NationalDayTest.php +++ b/tests/Romania/NationalDayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Romania; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -38,7 +35,7 @@ class NationalDayTest extends RomaniaBaseTestCase implements HolidayTestCase /** * Tests National Day on or after 1990. * - * @throws Exception + * @throws \Exception */ public function testNationalDayOnAfter1990(): void { @@ -47,14 +44,14 @@ public function testNationalDayOnAfter1990(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-12-1", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-12-1", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests National Day between 1948 - 1989. * - * @throws Exception + * @throws \Exception */ public function testNationalDayBetween19481989(): void { @@ -63,14 +60,14 @@ public function testNationalDayBetween19481989(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-08-23", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-08-23", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests National Day between 1866 - 1947. * - * @throws Exception + * @throws \Exception */ public function testNationalDayBetween18661947(): void { @@ -79,14 +76,14 @@ public function testNationalDayBetween18661947(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-05-10", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-05-10", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests National Day before 1865. * - * @throws Exception + * @throws \Exception */ public function testNationalDayBefore1865(): void { @@ -100,7 +97,7 @@ public function testNationalDayBefore1865(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -115,7 +112,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Romania/NewYearsDayTest.php b/tests/Romania/NewYearsDayTest.php index 7d7723dd7..bc22f3678 100644 --- a/tests/Romania/NewYearsDayTest.php +++ b/tests/Romania/NewYearsDayTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\Romania; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,8 +32,8 @@ class NewYearsDayTest extends RomaniaBaseTestCase implements HolidayTestCase * * @dataProvider HolidayDataProvider * - * @param int $year the year for which the holiday defined in this test needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which the holiday defined in this test needs to be tested + * @param \DateTime $expected the expected date */ public function testHoliday(int $year, \DateTimeInterface $expected): void { @@ -47,7 +45,7 @@ public function testHoliday(int $year, \DateTimeInterface $expected): void * * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function HolidayDataProvider(): array { @@ -57,7 +55,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -72,7 +70,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Romania/PentecostMondayTest.php b/tests/Romania/PentecostMondayTest.php index c9116adcd..53b9b2496 100644 --- a/tests/Romania/PentecostMondayTest.php +++ b/tests/Romania/PentecostMondayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Romania; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -38,7 +35,7 @@ class PentecostMondayTest extends RomaniaBaseTestCase implements HolidayTestCase /** * Tests the Pentecost Monday Day on and after 2008. * - * @throws Exception + * @throws \Exception */ public function testPentecostMondayOnAfter2008(): void { @@ -47,14 +44,14 @@ public function testPentecostMondayOnAfter2008(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-06-08", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-06-08", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests the Pentecost Day before 2008. * - * @throws Exception + * @throws \Exception */ public function testPentecostMondayBefore2008(): void { @@ -68,7 +65,7 @@ public function testPentecostMondayBefore2008(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -83,7 +80,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Romania/PentecostTest.php b/tests/Romania/PentecostTest.php index a8eeff335..00501367e 100644 --- a/tests/Romania/PentecostTest.php +++ b/tests/Romania/PentecostTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Romania; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -38,7 +35,7 @@ class PentecostTest extends RomaniaBaseTestCase implements HolidayTestCase /** * Tests the Pentecost Day on and after 2008. * - * @throws Exception + * @throws \Exception */ public function testPentecostDayOnAfter2008(): void { @@ -47,14 +44,14 @@ public function testPentecostDayOnAfter2008(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-06-07", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-06-07", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests the Pentecost Day before 2008. * - * @throws Exception + * @throws \Exception */ public function testPentecostDayBefore2008(): void { @@ -68,7 +65,7 @@ public function testPentecostDayBefore2008(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -83,7 +80,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Romania/RomaniaTest.php b/tests/Romania/RomaniaTest.php index 1d4d48a7e..259ce3a36 100644 --- a/tests/Romania/RomaniaTest.php +++ b/tests/Romania/RomaniaTest.php @@ -15,7 +15,6 @@ namespace Yasumi\tests\Romania; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\ProviderTestCase; @@ -110,7 +109,7 @@ public function testOtherHolidays(): void } /** - * @throws ReflectionException + * @throws \ReflectionException * @throws \Exception */ public function testSources(): void diff --git a/tests/Romania/SecondChristmasDayTest.php b/tests/Romania/SecondChristmasDayTest.php index 7f89cc0ef..d7d62d3fb 100644 --- a/tests/Romania/SecondChristmasDayTest.php +++ b/tests/Romania/SecondChristmasDayTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\Romania; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,8 +32,8 @@ class SecondChristmasDayTest extends RomaniaBaseTestCase implements HolidayTestC * * @dataProvider HolidayDataProvider * - * @param int $year the year for which the holiday defined in this test needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which the holiday defined in this test needs to be tested + * @param \DateTime $expected the expected date */ public function testHoliday(int $year, \DateTimeInterface $expected): void { @@ -47,7 +45,7 @@ public function testHoliday(int $year, \DateTimeInterface $expected): void * * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function HolidayDataProvider(): array { @@ -57,7 +55,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -72,7 +70,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Romania/StAndrewsDayTest.php b/tests/Romania/StAndrewsDayTest.php index f1dfe979a..646f906b2 100644 --- a/tests/Romania/StAndrewsDayTest.php +++ b/tests/Romania/StAndrewsDayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Romania; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -38,7 +35,7 @@ class StAndrewsDayTest extends RomaniaBaseTestCase implements HolidayTestCase /** * Tests Saint Andrew Day on or after 2012. * - * @throws Exception + * @throws \Exception */ public function testStAndrewDayOnAfter2012(): void { @@ -47,14 +44,14 @@ public function testStAndrewDayOnAfter2012(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-11-30", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-11-30", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests Saint Andrew before 2012. * - * @throws Exception + * @throws \Exception */ public function testStAndrewDayBefore2012(): void { @@ -68,7 +65,7 @@ public function testStAndrewDayBefore2012(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -83,7 +80,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Romania/UnitedPrincipalitiesDayTest.php b/tests/Romania/UnitedPrincipalitiesDayTest.php index 9030e9f22..2d8b3284d 100644 --- a/tests/Romania/UnitedPrincipalitiesDayTest.php +++ b/tests/Romania/UnitedPrincipalitiesDayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Romania; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -38,7 +35,7 @@ class UnitedPrincipalitiesDayTest extends RomaniaBaseTestCase implements Holiday /** * Tests united Principalities Day on or after 2015. * - * @throws Exception + * @throws \Exception */ public function testUnitedPrincipalitiesDayOnAfter2015(): void { @@ -47,14 +44,14 @@ public function testUnitedPrincipalitiesDayOnAfter2015(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-1-24", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-1-24", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests unitedPrincipalitiesDay before 2015. * - * @throws Exception + * @throws \Exception */ public function testUnitedPrincipalitiesDayBefore2015(): void { @@ -68,7 +65,7 @@ public function testUnitedPrincipalitiesDayBefore2015(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -83,7 +80,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Russia/DefenceOfTheFatherlandDayTest.php b/tests/Russia/DefenceOfTheFatherlandDayTest.php index a99f46505..203145ba2 100644 --- a/tests/Russia/DefenceOfTheFatherlandDayTest.php +++ b/tests/Russia/DefenceOfTheFatherlandDayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Russia; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\Provider\Russia; use Yasumi\tests\HolidayTestCase; @@ -36,7 +33,7 @@ class DefenceOfTheFatherlandDayTest extends RussiaBaseTestCase implements Holida /** * Test if holiday is not defined before. * - * @throws Exception + * @throws \Exception */ public function testHolidayBefore(): void { @@ -50,7 +47,7 @@ public function testHolidayBefore(): void /** * Test if holiday is defined after. * - * @throws Exception + * @throws \Exception */ public function testHolidayAfter(): void { @@ -60,14 +57,14 @@ public function testHolidayAfter(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-02-23", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-02-23", new \DateTimeZone(self::TIMEZONE)) ); } /** * {@inheritdoc} * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -88,7 +85,7 @@ public function testTranslation(): void /** * {@inheritdoc} * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Russia/InternationalWomensDayTest.php b/tests/Russia/InternationalWomensDayTest.php index 6450afd76..e2a80fd82 100644 --- a/tests/Russia/InternationalWomensDayTest.php +++ b/tests/Russia/InternationalWomensDayTest.php @@ -15,7 +15,6 @@ namespace Yasumi\tests\Russia; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,7 +33,7 @@ class InternationalWomensDayTest extends RussiaBaseTestCase implements HolidayTe /** * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function holidayDataProvider(): array { @@ -52,7 +51,7 @@ public function testHoliday(int $year, \DateTimeInterface $expected): void /** * {@inheritdoc} * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -67,7 +66,7 @@ public function testTranslation(): void /** * {@inheritdoc} * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Russia/NewYearHolidaysDay2Test.php b/tests/Russia/NewYearHolidaysDay2Test.php index 94b2a94b0..bdecb2ac2 100644 --- a/tests/Russia/NewYearHolidaysDay2Test.php +++ b/tests/Russia/NewYearHolidaysDay2Test.php @@ -15,7 +15,6 @@ namespace Yasumi\tests\Russia; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,7 +33,7 @@ class NewYearHolidaysDay2Test extends RussiaBaseTestCase implements HolidayTestC /** * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function holidayDataProvider(): array { @@ -52,7 +51,7 @@ public function testHoliday(int $year, \DateTimeInterface $expected): void /** * {@inheritdoc} * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -67,7 +66,7 @@ public function testTranslation(): void /** * {@inheritdoc} * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Russia/NewYearHolidaysDay3Test.php b/tests/Russia/NewYearHolidaysDay3Test.php index 40e414232..73b4f4681 100644 --- a/tests/Russia/NewYearHolidaysDay3Test.php +++ b/tests/Russia/NewYearHolidaysDay3Test.php @@ -15,7 +15,6 @@ namespace Yasumi\tests\Russia; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,7 +33,7 @@ class NewYearHolidaysDay3Test extends RussiaBaseTestCase implements HolidayTestC /** * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function holidayDataProvider(): array { @@ -52,7 +51,7 @@ public function testHoliday(int $year, \DateTimeInterface $expected): void /** * {@inheritdoc} * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -67,7 +66,7 @@ public function testTranslation(): void /** * {@inheritdoc} * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Russia/NewYearHolidaysDay4Test.php b/tests/Russia/NewYearHolidaysDay4Test.php index d8ed91802..e921e50d8 100644 --- a/tests/Russia/NewYearHolidaysDay4Test.php +++ b/tests/Russia/NewYearHolidaysDay4Test.php @@ -14,7 +14,6 @@ namespace Yasumi\tests\Russia; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -33,7 +32,7 @@ class NewYearHolidaysDay4Test extends RussiaBaseTestCase implements HolidayTestC /** * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function holidayDataProvider(): array { @@ -51,7 +50,7 @@ public function testHoliday(int $year, \DateTimeInterface $expected): void /** * {@inheritdoc} * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -66,7 +65,7 @@ public function testTranslation(): void /** * {@inheritdoc} * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Russia/NewYearHolidaysDay5Test.php b/tests/Russia/NewYearHolidaysDay5Test.php index 331b28071..f7720f1d1 100644 --- a/tests/Russia/NewYearHolidaysDay5Test.php +++ b/tests/Russia/NewYearHolidaysDay5Test.php @@ -15,7 +15,6 @@ namespace Yasumi\tests\Russia; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,7 +33,7 @@ class NewYearHolidaysDay5Test extends RussiaBaseTestCase implements HolidayTestC /** * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function holidayDataProvider(): array { @@ -52,7 +51,7 @@ public function testHoliday(int $year, \DateTimeInterface $expected): void /** * {@inheritdoc} * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -67,7 +66,7 @@ public function testTranslation(): void /** * {@inheritdoc} * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Russia/NewYearHolidaysDay6Test.php b/tests/Russia/NewYearHolidaysDay6Test.php index 4eab9c016..5503ac11a 100644 --- a/tests/Russia/NewYearHolidaysDay6Test.php +++ b/tests/Russia/NewYearHolidaysDay6Test.php @@ -15,7 +15,6 @@ namespace Yasumi\tests\Russia; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,7 +33,7 @@ class NewYearHolidaysDay6Test extends RussiaBaseTestCase implements HolidayTestC /** * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function holidayDataProvider(): array { @@ -52,7 +51,7 @@ public function testHoliday(int $year, \DateTimeInterface $expected): void /** * {@inheritdoc} * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -67,7 +66,7 @@ public function testTranslation(): void /** * {@inheritdoc} * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Russia/NewYearHolidaysDay8Test.php b/tests/Russia/NewYearHolidaysDay8Test.php index d5073cbbb..32f85482c 100644 --- a/tests/Russia/NewYearHolidaysDay8Test.php +++ b/tests/Russia/NewYearHolidaysDay8Test.php @@ -14,7 +14,6 @@ namespace Yasumi\tests\Russia; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -33,7 +32,7 @@ class NewYearHolidaysDay8Test extends RussiaBaseTestCase implements HolidayTestC /** * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function holidayDataProvider(): array { @@ -51,7 +50,7 @@ public function testHoliday(int $year, \DateTimeInterface $expected): void /** * {@inheritdoc} * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -66,7 +65,7 @@ public function testTranslation(): void /** * {@inheritdoc} * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Russia/NewYearsDayTest.php b/tests/Russia/NewYearsDayTest.php index d69155c9a..e060ed12c 100644 --- a/tests/Russia/NewYearsDayTest.php +++ b/tests/Russia/NewYearsDayTest.php @@ -15,7 +15,6 @@ namespace Yasumi\tests\Russia; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,7 +33,7 @@ class NewYearsDayTest extends RussiaBaseTestCase implements HolidayTestCase /** * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function holidayDataProvider(): array { @@ -52,7 +51,7 @@ public function testHoliday(int $year, \DateTimeInterface $expected): void /** * {@inheritdoc} * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -67,7 +66,7 @@ public function testTranslation(): void /** * {@inheritdoc} * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Russia/OrthodoxChristmasDayTest.php b/tests/Russia/OrthodoxChristmasDayTest.php index 81d1a5d8e..8184ba218 100644 --- a/tests/Russia/OrthodoxChristmasDayTest.php +++ b/tests/Russia/OrthodoxChristmasDayTest.php @@ -15,7 +15,6 @@ namespace Yasumi\tests\Russia; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,7 +33,7 @@ class OrthodoxChristmasDayTest extends RussiaBaseTestCase implements HolidayTest /** * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function holidayDataProvider(): array { @@ -52,7 +51,7 @@ public function testHoliday(int $year, \DateTimeInterface $expected): void /** * {@inheritdoc} * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -67,7 +66,7 @@ public function testTranslation(): void /** * {@inheritdoc} * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Russia/RussiaDayTest.php b/tests/Russia/RussiaDayTest.php index ed068bed7..f1c9eee75 100644 --- a/tests/Russia/RussiaDayTest.php +++ b/tests/Russia/RussiaDayTest.php @@ -15,9 +15,6 @@ namespace Yasumi\tests\Russia; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\Provider\Russia; use Yasumi\tests\HolidayTestCase; @@ -37,7 +34,7 @@ class RussiaDayTest extends RussiaBaseTestCase implements HolidayTestCase /** * Test if holiday is not defined before. * - * @throws Exception + * @throws \Exception */ public function testHolidayBefore(): void { @@ -51,7 +48,7 @@ public function testHolidayBefore(): void /** * Test if holiday is defined after. * - * @throws Exception + * @throws \Exception */ public function testHolidayAfter(): void { @@ -61,14 +58,14 @@ public function testHolidayAfter(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-06-12", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-06-12", new \DateTimeZone(self::TIMEZONE)) ); } /** * {@inheritdoc} * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -89,7 +86,7 @@ public function testTranslation(): void /** * {@inheritdoc} * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Russia/RussiaTest.php b/tests/Russia/RussiaTest.php index bb8fde6bf..e9602a4f2 100644 --- a/tests/Russia/RussiaTest.php +++ b/tests/Russia/RussiaTest.php @@ -15,7 +15,6 @@ namespace Yasumi\tests\Russia; -use ReflectionException; use Yasumi\Holiday; use Yasumi\Provider\Russia; use Yasumi\tests\ProviderTestCase; @@ -106,7 +105,7 @@ public function testOtherHolidays(): void } /** - * @throws ReflectionException + * @throws \ReflectionException * @throws \Exception */ public function testSources(): void diff --git a/tests/Russia/SpringAndLabourDayTest.php b/tests/Russia/SpringAndLabourDayTest.php index 99f330001..bd4f3346c 100644 --- a/tests/Russia/SpringAndLabourDayTest.php +++ b/tests/Russia/SpringAndLabourDayTest.php @@ -15,7 +15,6 @@ namespace Yasumi\tests\Russia; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,7 +33,7 @@ class SpringAndLabourDayTest extends RussiaBaseTestCase implements HolidayTestCa /** * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function holidayDataProvider(): array { @@ -52,7 +51,7 @@ public function testHoliday(int $year, \DateTimeInterface $expected): void /** * {@inheritdoc} * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -67,7 +66,7 @@ public function testTranslation(): void /** * {@inheritdoc} * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Russia/UnityDayTest.php b/tests/Russia/UnityDayTest.php index 2d071adab..09a9b999b 100644 --- a/tests/Russia/UnityDayTest.php +++ b/tests/Russia/UnityDayTest.php @@ -15,9 +15,6 @@ namespace Yasumi\tests\Russia; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\Provider\Russia; use Yasumi\tests\HolidayTestCase; @@ -37,7 +34,7 @@ class UnityDayTest extends RussiaBaseTestCase implements HolidayTestCase /** * Test if holiday is not defined before. * - * @throws Exception + * @throws \Exception */ public function testHolidayBefore(): void { @@ -51,7 +48,7 @@ public function testHolidayBefore(): void /** * Test if holiday is defined after. * - * @throws Exception + * @throws \Exception */ public function testHolidayAfter(): void { @@ -61,14 +58,14 @@ public function testHolidayAfter(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-11-04", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-11-04", new \DateTimeZone(self::TIMEZONE)) ); } /** * {@inheritdoc} * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -89,7 +86,7 @@ public function testTranslation(): void /** * {@inheritdoc} * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Russia/VictoryDayTest.php b/tests/Russia/VictoryDayTest.php index 4dea7d929..751d287f9 100644 --- a/tests/Russia/VictoryDayTest.php +++ b/tests/Russia/VictoryDayTest.php @@ -15,7 +15,6 @@ namespace Yasumi\tests\Russia; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,7 +33,7 @@ class VictoryDayTest extends RussiaBaseTestCase implements HolidayTestCase /** * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function holidayDataProvider(): array { @@ -52,7 +51,7 @@ public function testHoliday(int $year, \DateTimeInterface $expected): void /** * {@inheritdoc} * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -67,7 +66,7 @@ public function testTranslation(): void /** * {@inheritdoc} * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Slovakia/AllSaintsDayTest.php b/tests/Slovakia/AllSaintsDayTest.php index 26a546d3c..cae6be8d3 100644 --- a/tests/Slovakia/AllSaintsDayTest.php +++ b/tests/Slovakia/AllSaintsDayTest.php @@ -15,8 +15,6 @@ namespace Yasumi\tests\Slovakia; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -37,8 +35,8 @@ class AllSaintsDayTest extends SlovakiaBaseTestCase implements HolidayTestCase * * @dataProvider HolidayDataProvider * - * @param int $year the year for which the holiday defined in this test needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which the holiday defined in this test needs to be tested + * @param \DateTime $expected the expected date */ public function testHoliday(int $year, \DateTimeInterface $expected): void { @@ -50,7 +48,7 @@ public function testHoliday(int $year, \DateTimeInterface $expected): void * * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function HolidayDataProvider(): array { @@ -60,7 +58,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -75,7 +73,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Slovakia/ChristmasDayTest.php b/tests/Slovakia/ChristmasDayTest.php index a7a04a7f8..5b2cb2b93 100644 --- a/tests/Slovakia/ChristmasDayTest.php +++ b/tests/Slovakia/ChristmasDayTest.php @@ -15,8 +15,6 @@ namespace Yasumi\tests\Slovakia; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -37,8 +35,8 @@ class ChristmasDayTest extends SlovakiaBaseTestCase implements HolidayTestCase * * @dataProvider HolidayDataProvider * - * @param int $year the year for which Christmas Day needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which Christmas Day needs to be tested + * @param \DateTime $expected the expected date */ public function testChristmasDay(int $year, \DateTimeInterface $expected): void { @@ -50,7 +48,7 @@ public function testChristmasDay(int $year, \DateTimeInterface $expected): void * * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function HolidayDataProvider(): array { @@ -60,7 +58,7 @@ public function HolidayDataProvider(): array /** * Tests translated name of Christmas Day. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -75,7 +73,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Slovakia/ChristmasEveTest.php b/tests/Slovakia/ChristmasEveTest.php index 9ef38715f..c9d2cc0b1 100644 --- a/tests/Slovakia/ChristmasEveTest.php +++ b/tests/Slovakia/ChristmasEveTest.php @@ -15,8 +15,6 @@ namespace Yasumi\tests\Slovakia; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -37,8 +35,8 @@ class ChristmasEveTest extends SlovakiaBaseTestCase implements HolidayTestCase * * @dataProvider HolidayDataProvider * - * @param int $year the year for which Christmas Day needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which Christmas Day needs to be tested + * @param \DateTime $expected the expected date */ public function testChristmasEve(int $year, \DateTimeInterface $expected): void { @@ -50,7 +48,7 @@ public function testChristmasEve(int $year, \DateTimeInterface $expected): void * * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function HolidayDataProvider(): array { @@ -60,7 +58,7 @@ public function HolidayDataProvider(): array /** * Tests translated name of Christmas Eve. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -75,7 +73,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Slovakia/EasterMondayTest.php b/tests/Slovakia/EasterMondayTest.php index c615c18e0..5f2eecac7 100644 --- a/tests/Slovakia/EasterMondayTest.php +++ b/tests/Slovakia/EasterMondayTest.php @@ -15,9 +15,6 @@ namespace Yasumi\tests\Slovakia; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -38,8 +35,8 @@ class EasterMondayTest extends SlovakiaBaseTestCase implements HolidayTestCase * * @dataProvider HolidayDataProvider * - * @param int $year the year for which Christmas Day needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which Christmas Day needs to be tested + * @param \DateTime $expected the expected date */ public function testHoliday(int $year, \DateTimeInterface $expected): void { @@ -51,28 +48,28 @@ public function testHoliday(int $year, \DateTimeInterface $expected): void * * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function HolidayDataProvider(): array { $timezone = self::TIMEZONE; return [ - [1788, new DateTime('1788-3-24', new DateTimeZone($timezone))], - [1876, new DateTime('1876-4-17', new DateTimeZone($timezone))], - [2016, new DateTime('2016-3-28', new DateTimeZone($timezone))], - [2017, new DateTime('2017-4-17', new DateTimeZone($timezone))], - [2018, new DateTime('2018-4-2', new DateTimeZone($timezone))], - [2019, new DateTime('2019-4-22', new DateTimeZone($timezone))], - [2020, new DateTime('2020-4-13', new DateTimeZone($timezone))], - [2050, new DateTime('2050-4-11', new DateTimeZone($timezone))], + [1788, new \DateTime('1788-3-24', new \DateTimeZone($timezone))], + [1876, new \DateTime('1876-4-17', new \DateTimeZone($timezone))], + [2016, new \DateTime('2016-3-28', new \DateTimeZone($timezone))], + [2017, new \DateTime('2017-4-17', new \DateTimeZone($timezone))], + [2018, new \DateTime('2018-4-2', new \DateTimeZone($timezone))], + [2019, new \DateTime('2019-4-22', new \DateTimeZone($timezone))], + [2020, new \DateTime('2020-4-13', new \DateTimeZone($timezone))], + [2050, new \DateTime('2050-4-11', new \DateTimeZone($timezone))], ]; } /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -87,7 +84,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Slovakia/EpiphanyTest.php b/tests/Slovakia/EpiphanyTest.php index 024857486..ddd206123 100644 --- a/tests/Slovakia/EpiphanyTest.php +++ b/tests/Slovakia/EpiphanyTest.php @@ -15,8 +15,6 @@ namespace Yasumi\tests\Slovakia; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -37,8 +35,8 @@ class EpiphanyTest extends SlovakiaBaseTestCase implements HolidayTestCase * * @dataProvider HolidayDataProvider * - * @param int $year the year for which Christmas Day needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which Christmas Day needs to be tested + * @param \DateTime $expected the expected date */ public function testHoliday(int $year, \DateTimeInterface $expected): void { @@ -50,7 +48,7 @@ public function testHoliday(int $year, \DateTimeInterface $expected): void * * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function HolidayDataProvider(): array { @@ -60,7 +58,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -75,7 +73,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Slovakia/GoodFridayTest.php b/tests/Slovakia/GoodFridayTest.php index 19b22433c..e6142f6b2 100644 --- a/tests/Slovakia/GoodFridayTest.php +++ b/tests/Slovakia/GoodFridayTest.php @@ -15,9 +15,6 @@ namespace Yasumi\tests\Slovakia; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -38,8 +35,8 @@ class GoodFridayTest extends SlovakiaBaseTestCase implements HolidayTestCase * * @dataProvider HolidayDataProvider * - * @param int $year the year for which Christmas Day needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which Christmas Day needs to be tested + * @param \DateTime $expected the expected date */ public function testHoliday(int $year, \DateTimeInterface $expected): void { @@ -51,28 +48,28 @@ public function testHoliday(int $year, \DateTimeInterface $expected): void * * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function HolidayDataProvider(): array { $timezone = self::TIMEZONE; return [ - [1788, new DateTime('1788-3-21', new DateTimeZone($timezone))], - [1876, new DateTime('1876-4-14', new DateTimeZone($timezone))], - [2016, new DateTime('2016-3-25', new DateTimeZone($timezone))], - [2017, new DateTime('2017-4-14', new DateTimeZone($timezone))], - [2018, new DateTime('2018-3-30', new DateTimeZone($timezone))], - [2019, new DateTime('2019-4-19', new DateTimeZone($timezone))], - [2020, new DateTime('2020-4-10', new DateTimeZone($timezone))], - [2050, new DateTime('2050-4-8', new DateTimeZone($timezone))], + [1788, new \DateTime('1788-3-21', new \DateTimeZone($timezone))], + [1876, new \DateTime('1876-4-14', new \DateTimeZone($timezone))], + [2016, new \DateTime('2016-3-25', new \DateTimeZone($timezone))], + [2017, new \DateTime('2017-4-14', new \DateTimeZone($timezone))], + [2018, new \DateTime('2018-3-30', new \DateTimeZone($timezone))], + [2019, new \DateTime('2019-4-19', new \DateTimeZone($timezone))], + [2020, new \DateTime('2020-4-10', new \DateTimeZone($timezone))], + [2050, new \DateTime('2050-4-8', new \DateTimeZone($timezone))], ]; } /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -87,7 +84,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Slovakia/InternationalWorkersDayTest.php b/tests/Slovakia/InternationalWorkersDayTest.php index 1bdf0c46f..a78ec0d98 100644 --- a/tests/Slovakia/InternationalWorkersDayTest.php +++ b/tests/Slovakia/InternationalWorkersDayTest.php @@ -15,8 +15,6 @@ namespace Yasumi\tests\Slovakia; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -37,8 +35,8 @@ class InternationalWorkersDayTest extends SlovakiaBaseTestCase implements Holida * * @dataProvider HolidayDataProvider * - * @param int $year the year for which Christmas Day needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which Christmas Day needs to be tested + * @param \DateTime $expected the expected date */ public function testHoliday(int $year, \DateTimeInterface $expected): void { @@ -50,7 +48,7 @@ public function testHoliday(int $year, \DateTimeInterface $expected): void * * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function HolidayDataProvider(): array { @@ -60,7 +58,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -75,7 +73,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Slovakia/OurLadyOfSorrowsDayTest.php b/tests/Slovakia/OurLadyOfSorrowsDayTest.php index fe1ad0554..36b480d27 100644 --- a/tests/Slovakia/OurLadyOfSorrowsDayTest.php +++ b/tests/Slovakia/OurLadyOfSorrowsDayTest.php @@ -15,8 +15,6 @@ namespace Yasumi\tests\Slovakia; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -37,8 +35,8 @@ class OurLadyOfSorrowsDayTest extends SlovakiaBaseTestCase implements HolidayTes * * @dataProvider HolidayDataProvider * - * @param int $year the year for which Christmas Day needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which Christmas Day needs to be tested + * @param \DateTime $expected the expected date */ public function testHoliday(int $year, \DateTimeInterface $expected): void { @@ -50,7 +48,7 @@ public function testHoliday(int $year, \DateTimeInterface $expected): void * * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function HolidayDataProvider(): array { @@ -60,7 +58,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -75,7 +73,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Slovakia/SaintsCyrilAndMethodiusDayTest.php b/tests/Slovakia/SaintsCyrilAndMethodiusDayTest.php index d5fd7b164..e1a20eb77 100644 --- a/tests/Slovakia/SaintsCyrilAndMethodiusDayTest.php +++ b/tests/Slovakia/SaintsCyrilAndMethodiusDayTest.php @@ -15,8 +15,6 @@ namespace Yasumi\tests\Slovakia; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -37,8 +35,8 @@ class SaintsCyrilAndMethodiusDayTest extends SlovakiaBaseTestCase implements Hol * * @dataProvider HolidayDataProvider * - * @param int $year the year for which the holiday defined in this test needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which the holiday defined in this test needs to be tested + * @param \DateTime $expected the expected date */ public function testHoliday(int $year, \DateTimeInterface $expected): void { @@ -50,7 +48,7 @@ public function testHoliday(int $year, \DateTimeInterface $expected): void * * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function HolidayDataProvider(): array { @@ -60,7 +58,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -75,7 +73,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Slovakia/SecondChristmasDayTest.php b/tests/Slovakia/SecondChristmasDayTest.php index f758ad64c..6221a9c84 100644 --- a/tests/Slovakia/SecondChristmasDayTest.php +++ b/tests/Slovakia/SecondChristmasDayTest.php @@ -15,8 +15,6 @@ namespace Yasumi\tests\Slovakia; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -37,8 +35,8 @@ class SecondChristmasDayTest extends SlovakiaBaseTestCase implements HolidayTest * * @dataProvider HolidayDataProvider * - * @param int $year the year for which Christmas Day needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which Christmas Day needs to be tested + * @param \DateTime $expected the expected date */ public function testHoliday(int $year, \DateTimeInterface $expected): void { @@ -50,7 +48,7 @@ public function testHoliday(int $year, \DateTimeInterface $expected): void * * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function HolidayDataProvider(): array { @@ -60,7 +58,7 @@ public function HolidayDataProvider(): array /** * Tests translated name of Second Christmas Day. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -75,7 +73,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Slovakia/SlovakConstitutionDayTest.php b/tests/Slovakia/SlovakConstitutionDayTest.php index b991ef989..da519c868 100644 --- a/tests/Slovakia/SlovakConstitutionDayTest.php +++ b/tests/Slovakia/SlovakConstitutionDayTest.php @@ -15,8 +15,6 @@ namespace Yasumi\tests\Slovakia; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -37,8 +35,8 @@ class SlovakConstitutionDayTest extends SlovakiaBaseTestCase implements HolidayT * * @dataProvider HolidayDataProvider * - * @param int $year the year for which the holiday defined in this test needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which the holiday defined in this test needs to be tested + * @param \DateTime $expected the expected date */ public function testHoliday(int $year, \DateTimeInterface $expected): void { @@ -50,7 +48,7 @@ public function testHoliday(int $year, \DateTimeInterface $expected): void * * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function HolidayDataProvider(): array { @@ -60,7 +58,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -75,7 +73,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Slovakia/SlovakIndependeceDayTest.php b/tests/Slovakia/SlovakIndependeceDayTest.php index 6a91fbddd..95dae3237 100644 --- a/tests/Slovakia/SlovakIndependeceDayTest.php +++ b/tests/Slovakia/SlovakIndependeceDayTest.php @@ -15,8 +15,6 @@ namespace Yasumi\tests\Slovakia; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -38,8 +36,8 @@ class SlovakIndependeceDayTest extends SlovakiaBaseTestCase implements HolidayTe * * @dataProvider HolidayDataProvider * - * @param int $year the year for which the holiday defined in this test needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which the holiday defined in this test needs to be tested + * @param \DateTime $expected the expected date */ public function testHoliday(int $year, \DateTimeInterface $expected): void { @@ -51,7 +49,7 @@ public function testHoliday(int $year, \DateTimeInterface $expected): void * * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function HolidayDataProvider(): array { @@ -61,7 +59,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -76,7 +74,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Slovakia/SlovakNationalUprisingDayTest.php b/tests/Slovakia/SlovakNationalUprisingDayTest.php index dc9e872b7..800f694b8 100644 --- a/tests/Slovakia/SlovakNationalUprisingDayTest.php +++ b/tests/Slovakia/SlovakNationalUprisingDayTest.php @@ -15,8 +15,6 @@ namespace Yasumi\tests\Slovakia; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -37,8 +35,8 @@ class SlovakNationalUprisingDayTest extends SlovakiaBaseTestCase implements Holi * * @dataProvider HolidayDataProvider * - * @param int $year the year for which the holiday defined in this test needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which the holiday defined in this test needs to be tested + * @param \DateTime $expected the expected date */ public function testHoliday(int $year, \DateTimeInterface $expected): void { @@ -50,7 +48,7 @@ public function testHoliday(int $year, \DateTimeInterface $expected): void * * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function HolidayDataProvider(): array { @@ -60,7 +58,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -75,7 +73,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Slovakia/SlovakiaTest.php b/tests/Slovakia/SlovakiaTest.php index 5cb85e7bf..0890ceeba 100644 --- a/tests/Slovakia/SlovakiaTest.php +++ b/tests/Slovakia/SlovakiaTest.php @@ -15,7 +15,6 @@ namespace Yasumi\tests\Slovakia; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\ProviderTestCase; @@ -100,7 +99,7 @@ public function testOtherHolidays(): void } /** - * @throws ReflectionException + * @throws \ReflectionException * @throws \Exception */ public function testSources(): void diff --git a/tests/Slovakia/StruggleForFreedomAndDemocracyDayTest.php b/tests/Slovakia/StruggleForFreedomAndDemocracyDayTest.php index f264fa3d9..94ab851ac 100644 --- a/tests/Slovakia/StruggleForFreedomAndDemocracyDayTest.php +++ b/tests/Slovakia/StruggleForFreedomAndDemocracyDayTest.php @@ -15,8 +15,6 @@ namespace Yasumi\tests\Slovakia; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -37,8 +35,8 @@ class StruggleForFreedomAndDemocracyDayTest extends SlovakiaBaseTestCase impleme * * @dataProvider HolidayDataProvider * - * @param int $year the year for which the holiday defined in this test needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which the holiday defined in this test needs to be tested + * @param \DateTime $expected the expected date */ public function testHoliday(int $year, \DateTimeInterface $expected): void { @@ -50,7 +48,7 @@ public function testHoliday(int $year, \DateTimeInterface $expected): void * * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function HolidayDataProvider(): array { @@ -60,7 +58,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -75,7 +73,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Slovakia/VictoryInEuropeDayTest.php b/tests/Slovakia/VictoryInEuropeDayTest.php index 8c84b564a..93a75b88a 100644 --- a/tests/Slovakia/VictoryInEuropeDayTest.php +++ b/tests/Slovakia/VictoryInEuropeDayTest.php @@ -15,8 +15,6 @@ namespace Yasumi\tests\Slovakia; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -37,8 +35,8 @@ class VictoryInEuropeDayTest extends SlovakiaBaseTestCase implements HolidayTest * * @dataProvider HolidayDataProvider * - * @param int $year the year for which Christmas Day needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which Christmas Day needs to be tested + * @param \DateTime $expected the expected date */ public function testHoliday(int $year, \DateTimeInterface $expected): void { @@ -50,7 +48,7 @@ public function testHoliday(int $year, \DateTimeInterface $expected): void * * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function HolidayDataProvider(): array { @@ -60,7 +58,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -75,7 +73,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/SouthAfrica/ChristmasDayTest.php b/tests/SouthAfrica/ChristmasDayTest.php index 2cc97e540..a99b4b4cc 100644 --- a/tests/SouthAfrica/ChristmasDayTest.php +++ b/tests/SouthAfrica/ChristmasDayTest.php @@ -14,10 +14,6 @@ namespace Yasumi\tests\SouthAfrica; -use DateInterval; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -48,16 +44,16 @@ class ChristmasDayTest extends SouthAfricaBaseTestCase implements HolidayTestCas * @param int $year the year for which the holiday defined in this test needs to be tested * @param string $expected the expected date * - * @throws Exception + * @throws \Exception */ public function testHoliday(int $year, string $expected): void { - $date = new DateTime($expected, new DateTimeZone(self::TIMEZONE)); + $date = new \DateTime($expected, new \DateTimeZone(self::TIMEZONE)); $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $date); // Whenever any public holiday falls on a Sunday, the Monday following on it shall be a public holiday. if (0 === (int) $date->format('w')) { - $date->add(new DateInterval('P1D')); + $date->add(new \DateInterval('P1D')); $this->assertHoliday(self::REGION, 'substituteHoliday:'.self::HOLIDAY, $year, $date); } } @@ -67,7 +63,7 @@ public function testHoliday(int $year, string $expected): void * * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function HolidayDataProvider(): array { @@ -75,7 +71,7 @@ public function HolidayDataProvider(): array for ($y = 0; $y < 50; ++$y) { $year = $this->generateRandomYear(self::ESTABLISHMENT_YEAR); - $date = new DateTime("$year-12-25", new DateTimeZone(self::TIMEZONE)); + $date = new \DateTime("$year-12-25", new \DateTimeZone(self::TIMEZONE)); $data[] = [$year, $date->format('Y-m-d')]; } @@ -85,7 +81,7 @@ public function HolidayDataProvider(): array /** * Tests the holiday defined in this test before establishment. * - * @throws Exception + * @throws \Exception */ public function testHolidayBeforeEstablishment(): void { @@ -99,7 +95,7 @@ public function testHolidayBeforeEstablishment(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -114,7 +110,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/SouthAfrica/FamilyDayTest.php b/tests/SouthAfrica/FamilyDayTest.php index 751a70a48..13742e622 100644 --- a/tests/SouthAfrica/FamilyDayTest.php +++ b/tests/SouthAfrica/FamilyDayTest.php @@ -14,10 +14,6 @@ namespace Yasumi\tests\SouthAfrica; -use DateInterval; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -48,7 +44,7 @@ class FamilyDayTest extends SouthAfricaBaseTestCase implements HolidayTestCase * @param int $year the year for which the holiday defined in this test needs to be tested * @param string $expected the expected date * - * @throws Exception + * @throws \Exception */ public function testHoliday(int $year, string $expected): void { @@ -56,7 +52,7 @@ public function testHoliday(int $year, string $expected): void self::REGION, self::HOLIDAY, $year, - new DateTime($expected, new DateTimeZone(self::TIMEZONE)) + new \DateTime($expected, new \DateTimeZone(self::TIMEZONE)) ); } @@ -65,7 +61,7 @@ public function testHoliday(int $year, string $expected): void * * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function HolidayDataProvider(): array { @@ -74,7 +70,7 @@ public function HolidayDataProvider(): array for ($y = 0; $y < 50; ++$y) { $year = $this->generateRandomYear(self::ESTABLISHMENT_YEAR); $date = $this->calculateEaster($year, self::TIMEZONE); - $date->add(new DateInterval('P1D')); + $date->add(new \DateInterval('P1D')); $data[] = [$year, $date->format('Y-m-d')]; } @@ -84,7 +80,7 @@ public function HolidayDataProvider(): array /** * Tests the holiday defined in this test before establishment. * - * @throws Exception + * @throws \Exception */ public function testHolidayBeforeEstablishment(): void { @@ -98,7 +94,7 @@ public function testHolidayBeforeEstablishment(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -113,7 +109,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/SouthAfrica/FreedomDayTest.php b/tests/SouthAfrica/FreedomDayTest.php index 4b9184b95..c09cfb13b 100644 --- a/tests/SouthAfrica/FreedomDayTest.php +++ b/tests/SouthAfrica/FreedomDayTest.php @@ -14,10 +14,6 @@ namespace Yasumi\tests\SouthAfrica; -use DateInterval; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -48,16 +44,16 @@ class FreedomDayTest extends SouthAfricaBaseTestCase implements HolidayTestCase * @param int $year the year for which the holiday defined in this test needs to be tested * @param string $expected the expected date * - * @throws Exception + * @throws \Exception */ public function testHoliday(int $year, string $expected): void { - $date = new DateTime($expected, new DateTimeZone(self::TIMEZONE)); + $date = new \DateTime($expected, new \DateTimeZone(self::TIMEZONE)); $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $date); // Whenever any public holiday falls on a Sunday, the Monday following on it shall be a public holiday. if (0 === (int) $date->format('w')) { - $date->add(new DateInterval('P1D')); + $date->add(new \DateInterval('P1D')); $this->assertHoliday(self::REGION, 'substituteHoliday:'.self::HOLIDAY, $year, $date); } } @@ -67,7 +63,7 @@ public function testHoliday(int $year, string $expected): void * * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function HolidayDataProvider(): array { @@ -75,7 +71,7 @@ public function HolidayDataProvider(): array for ($y = 0; $y < 50; ++$y) { $year = $this->generateRandomYear(self::ESTABLISHMENT_YEAR); - $date = new DateTime("$year-4-27", new DateTimeZone(self::TIMEZONE)); + $date = new \DateTime("$year-4-27", new \DateTimeZone(self::TIMEZONE)); $data[] = [$year, $date->format('Y-m-d')]; } @@ -85,7 +81,7 @@ public function HolidayDataProvider(): array /** * Tests the holiday defined in this test before establishment. * - * @throws Exception + * @throws \Exception */ public function testHolidayBeforeEstablishment(): void { @@ -99,7 +95,7 @@ public function testHolidayBeforeEstablishment(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -114,7 +110,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/SouthAfrica/GoodFridayTest.php b/tests/SouthAfrica/GoodFridayTest.php index 9bc753408..809b5f42c 100644 --- a/tests/SouthAfrica/GoodFridayTest.php +++ b/tests/SouthAfrica/GoodFridayTest.php @@ -14,10 +14,6 @@ namespace Yasumi\tests\SouthAfrica; -use DateInterval; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -48,7 +44,7 @@ class GoodFridayTest extends SouthAfricaBaseTestCase implements HolidayTestCase * @param int $year the year for which the holiday defined in this test needs to be tested * @param string $expected the expected date * - * @throws Exception + * @throws \Exception */ public function testHoliday(int $year, string $expected): void { @@ -56,7 +52,7 @@ public function testHoliday(int $year, string $expected): void self::REGION, self::HOLIDAY, $year, - new DateTime($expected, new DateTimeZone(self::TIMEZONE)) + new \DateTime($expected, new \DateTimeZone(self::TIMEZONE)) ); } @@ -65,7 +61,7 @@ public function testHoliday(int $year, string $expected): void * * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function HolidayDataProvider(): array { @@ -74,7 +70,7 @@ public function HolidayDataProvider(): array for ($y = 0; $y < 50; ++$y) { $year = $this->generateRandomYear(self::ESTABLISHMENT_YEAR); $date = $this->calculateEaster($year, self::TIMEZONE); - $date->sub(new DateInterval('P2D')); + $date->sub(new \DateInterval('P2D')); $data[] = [$year, $date->format('Y-m-d')]; } @@ -84,7 +80,7 @@ public function HolidayDataProvider(): array /** * Tests the holiday defined in this test before establishment. * - * @throws Exception + * @throws \Exception */ public function testHolidayBeforeEstablishment(): void { @@ -98,7 +94,7 @@ public function testHolidayBeforeEstablishment(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -113,7 +109,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/SouthAfrica/HeritageDayTest.php b/tests/SouthAfrica/HeritageDayTest.php index 06bb662f4..6ef81bcaa 100644 --- a/tests/SouthAfrica/HeritageDayTest.php +++ b/tests/SouthAfrica/HeritageDayTest.php @@ -14,10 +14,6 @@ namespace Yasumi\tests\SouthAfrica; -use DateInterval; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -48,16 +44,16 @@ class HeritageDayTest extends SouthAfricaBaseTestCase implements HolidayTestCase * @param int $year the year for which the holiday defined in this test needs to be tested * @param string $expected the expected date * - * @throws Exception + * @throws \Exception */ public function testHoliday(int $year, string $expected): void { - $date = new DateTime($expected, new DateTimeZone(self::TIMEZONE)); + $date = new \DateTime($expected, new \DateTimeZone(self::TIMEZONE)); $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $date); // Whenever any public holiday falls on a Sunday, the Monday following on it shall be a public holiday. if (0 === (int) $date->format('w')) { - $date->add(new DateInterval('P1D')); + $date->add(new \DateInterval('P1D')); $this->assertHoliday(self::REGION, 'substituteHoliday:'.self::HOLIDAY, $year, $date); } } @@ -67,7 +63,7 @@ public function testHoliday(int $year, string $expected): void * * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function HolidayDataProvider(): array { @@ -75,7 +71,7 @@ public function HolidayDataProvider(): array for ($y = 0; $y < 50; ++$y) { $year = $this->generateRandomYear(self::ESTABLISHMENT_YEAR); - $date = new DateTime("$year-9-24", new DateTimeZone(self::TIMEZONE)); + $date = new \DateTime("$year-9-24", new \DateTimeZone(self::TIMEZONE)); $data[] = [$year, $date->format('Y-m-d')]; } @@ -85,7 +81,7 @@ public function HolidayDataProvider(): array /** * Tests the holiday defined in this test before establishment. * - * @throws Exception + * @throws \Exception */ public function testHolidayBeforeEstablishment(): void { @@ -99,7 +95,7 @@ public function testHolidayBeforeEstablishment(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -114,7 +110,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/SouthAfrica/HumanRightsDayTest.php b/tests/SouthAfrica/HumanRightsDayTest.php index bfbd2d47e..4ae47bb2e 100644 --- a/tests/SouthAfrica/HumanRightsDayTest.php +++ b/tests/SouthAfrica/HumanRightsDayTest.php @@ -14,10 +14,6 @@ namespace Yasumi\tests\SouthAfrica; -use DateInterval; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -48,16 +44,16 @@ class HumanRightsDayTest extends SouthAfricaBaseTestCase implements HolidayTestC * @param int $year the year for which the holiday defined in this test needs to be tested * @param string $expected the expected date * - * @throws Exception + * @throws \Exception */ public function testHoliday(int $year, string $expected): void { - $date = new DateTime($expected, new DateTimeZone(self::TIMEZONE)); + $date = new \DateTime($expected, new \DateTimeZone(self::TIMEZONE)); $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $date); // Whenever any public holiday falls on a Sunday, the Monday following on it shall be a public holiday. if (0 === (int) $date->format('w')) { - $date->add(new DateInterval('P1D')); + $date->add(new \DateInterval('P1D')); $this->assertHoliday(self::REGION, 'substituteHoliday:'.self::HOLIDAY, $year, $date); } } @@ -67,7 +63,7 @@ public function testHoliday(int $year, string $expected): void * * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function HolidayDataProvider(): array { @@ -75,7 +71,7 @@ public function HolidayDataProvider(): array for ($y = 0; $y < 50; ++$y) { $year = $this->generateRandomYear(self::ESTABLISHMENT_YEAR); - $date = new DateTime("$year-3-21", new DateTimeZone(self::TIMEZONE)); + $date = new \DateTime("$year-3-21", new \DateTimeZone(self::TIMEZONE)); $data[] = [$year, $date->format('Y-m-d')]; } @@ -85,7 +81,7 @@ public function HolidayDataProvider(): array /** * Tests the holiday defined in this test before establishment. * - * @throws Exception + * @throws \Exception */ public function testHolidayBeforeEstablishment(): void { @@ -99,7 +95,7 @@ public function testHolidayBeforeEstablishment(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -114,7 +110,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/SouthAfrica/MunicipalElections2016DayTest.php b/tests/SouthAfrica/MunicipalElections2016DayTest.php index 47c1ee4c9..131e2c6d8 100644 --- a/tests/SouthAfrica/MunicipalElections2016DayTest.php +++ b/tests/SouthAfrica/MunicipalElections2016DayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\SouthAfrica; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -42,7 +39,7 @@ class MunicipalElections2016DayTest extends SouthAfricaBaseTestCase implements H /** * Tests the holiday defined in this test on or after establishment. * - * @throws Exception + * @throws \Exception */ public function testHolidayOnAfterEstablishment(): void { @@ -50,14 +47,14 @@ public function testHolidayOnAfterEstablishment(): void self::REGION, self::HOLIDAY, self::ESTABLISHMENT_YEAR, - new DateTime(self::ESTABLISHMENT_YEAR.'-8-3', new DateTimeZone(self::TIMEZONE)) + new \DateTime(self::ESTABLISHMENT_YEAR.'-8-3', new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests the holiday defined in this test before establishment. * - * @throws Exception + * @throws \Exception */ public function testHolidayBeforeEstablishment(): void { @@ -71,7 +68,7 @@ public function testHolidayBeforeEstablishment(): void /** * Tests the holiday defined in this test after completion. * - * @throws Exception + * @throws \Exception */ public function testHolidayDayAfterCompletion(): void { @@ -81,7 +78,7 @@ public function testHolidayDayAfterCompletion(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -96,7 +93,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/SouthAfrica/NationalWomensDayTest.php b/tests/SouthAfrica/NationalWomensDayTest.php index 6c5c7bbd3..ae0979495 100644 --- a/tests/SouthAfrica/NationalWomensDayTest.php +++ b/tests/SouthAfrica/NationalWomensDayTest.php @@ -14,10 +14,6 @@ namespace Yasumi\tests\SouthAfrica; -use DateInterval; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -48,16 +44,16 @@ class NationalWomensDayTest extends SouthAfricaBaseTestCase implements HolidayTe * @param int $year the year for which the holiday defined in this test needs to be tested * @param string $expected the expected date * - * @throws Exception + * @throws \Exception */ public function testHoliday(int $year, string $expected): void { - $date = new DateTime($expected, new DateTimeZone(self::TIMEZONE)); + $date = new \DateTime($expected, new \DateTimeZone(self::TIMEZONE)); $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $date); // Whenever any public holiday falls on a Sunday, the Monday following on it shall be a public holiday. if (0 === (int) $date->format('w')) { - $date->add(new DateInterval('P1D')); + $date->add(new \DateInterval('P1D')); $this->assertHoliday(self::REGION, 'substituteHoliday:'.self::HOLIDAY, $year, $date); } } @@ -67,7 +63,7 @@ public function testHoliday(int $year, string $expected): void * * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function HolidayDataProvider(): array { @@ -75,7 +71,7 @@ public function HolidayDataProvider(): array for ($y = 0; $y < 50; ++$y) { $year = $this->generateRandomYear(self::ESTABLISHMENT_YEAR); - $date = new DateTime("$year-8-9", new DateTimeZone(self::TIMEZONE)); + $date = new \DateTime("$year-8-9", new \DateTimeZone(self::TIMEZONE)); $data[] = [$year, $date->format('Y-m-d')]; } @@ -85,7 +81,7 @@ public function HolidayDataProvider(): array /** * Tests the holiday defined in this test before establishment. * - * @throws Exception + * @throws \Exception */ public function testHolidayBeforeEstablishment(): void { @@ -99,7 +95,7 @@ public function testHolidayBeforeEstablishment(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -114,7 +110,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/SouthAfrica/NewYearsDayTest.php b/tests/SouthAfrica/NewYearsDayTest.php index d8735dfe5..fc614b3f7 100644 --- a/tests/SouthAfrica/NewYearsDayTest.php +++ b/tests/SouthAfrica/NewYearsDayTest.php @@ -14,10 +14,6 @@ namespace Yasumi\tests\SouthAfrica; -use DateInterval; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -48,16 +44,16 @@ class NewYearsDayTest extends SouthAfricaBaseTestCase implements HolidayTestCase * @param int $year the year for which the holiday defined in this test needs to be tested * @param string $expected the expected date * - * @throws Exception + * @throws \Exception */ public function testHoliday(int $year, string $expected): void { - $date = new DateTime($expected, new DateTimeZone(self::TIMEZONE)); + $date = new \DateTime($expected, new \DateTimeZone(self::TIMEZONE)); $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $date); // Whenever any public holiday falls on a Sunday, the Monday following on it shall be a public holiday. if (0 === (int) $date->format('w')) { - $date->add(new DateInterval('P1D')); + $date->add(new \DateInterval('P1D')); $this->assertHoliday(self::REGION, 'substituteHoliday:'.self::HOLIDAY, $year, $date); } } @@ -67,7 +63,7 @@ public function testHoliday(int $year, string $expected): void * * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function HolidayDataProvider(): array { @@ -75,7 +71,7 @@ public function HolidayDataProvider(): array for ($y = 0; $y < 50; ++$y) { $year = $this->generateRandomYear(self::ESTABLISHMENT_YEAR); - $date = new DateTime("$year-1-1", new DateTimeZone(self::TIMEZONE)); + $date = new \DateTime("$year-1-1", new \DateTimeZone(self::TIMEZONE)); $data[] = [$year, $date->format('Y-m-d')]; } @@ -85,7 +81,7 @@ public function HolidayDataProvider(): array /** * Tests the holiday defined in this test before establishment. * - * @throws Exception + * @throws \Exception */ public function testHolidayBeforeEstablishment(): void { @@ -99,7 +95,7 @@ public function testHolidayBeforeEstablishment(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -114,7 +110,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/SouthAfrica/ReconciliationDayTest.php b/tests/SouthAfrica/ReconciliationDayTest.php index 010656e65..a259ca035 100644 --- a/tests/SouthAfrica/ReconciliationDayTest.php +++ b/tests/SouthAfrica/ReconciliationDayTest.php @@ -14,10 +14,6 @@ namespace Yasumi\tests\SouthAfrica; -use DateInterval; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -48,16 +44,16 @@ class ReconciliationDayTest extends SouthAfricaBaseTestCase implements HolidayTe * @param int $year the year for which the holiday defined in this test needs to be tested * @param string $expected the expected date * - * @throws Exception + * @throws \Exception */ public function testHoliday(int $year, string $expected): void { - $date = new DateTime($expected, new DateTimeZone(self::TIMEZONE)); + $date = new \DateTime($expected, new \DateTimeZone(self::TIMEZONE)); $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $date); // Whenever any public holiday falls on a Sunday, the Monday following on it shall be a public holiday. if (0 === (int) $date->format('w')) { - $date->add(new DateInterval('P1D')); + $date->add(new \DateInterval('P1D')); $this->assertHoliday(self::REGION, 'substituteHoliday:'.self::HOLIDAY, $year, $date); } } @@ -67,7 +63,7 @@ public function testHoliday(int $year, string $expected): void * * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function HolidayDataProvider(): array { @@ -75,7 +71,7 @@ public function HolidayDataProvider(): array for ($y = 0; $y < 50; ++$y) { $year = $this->generateRandomYear(self::ESTABLISHMENT_YEAR); - $date = new DateTime("$year-12-16", new DateTimeZone(self::TIMEZONE)); + $date = new \DateTime("$year-12-16", new \DateTimeZone(self::TIMEZONE)); $data[] = [$year, $date->format('Y-m-d')]; } @@ -85,7 +81,7 @@ public function HolidayDataProvider(): array /** * Tests the holiday defined in this test before establishment. * - * @throws Exception + * @throws \Exception */ public function testHolidayBeforeEstablishment(): void { @@ -99,7 +95,7 @@ public function testHolidayBeforeEstablishment(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -114,7 +110,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/SouthAfrica/SecondChristmasDayTest.php b/tests/SouthAfrica/SecondChristmasDayTest.php index f4519ed06..fd5abe3e3 100644 --- a/tests/SouthAfrica/SecondChristmasDayTest.php +++ b/tests/SouthAfrica/SecondChristmasDayTest.php @@ -14,10 +14,6 @@ namespace Yasumi\tests\SouthAfrica; -use DateInterval; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -48,16 +44,16 @@ class SecondChristmasDayTest extends SouthAfricaBaseTestCase implements HolidayT * @param int $year the year for which the holiday defined in this test needs to be tested * @param string $expected the expected date * - * @throws Exception + * @throws \Exception */ public function testHoliday(int $year, string $expected): void { - $date = new DateTime($expected, new DateTimeZone(self::TIMEZONE)); + $date = new \DateTime($expected, new \DateTimeZone(self::TIMEZONE)); $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $date); // Whenever any public holiday falls on a Sunday, the Monday following on it shall be a public holiday. if (0 === (int) $date->format('w')) { - $date->add(new DateInterval('P1D')); + $date->add(new \DateInterval('P1D')); $this->assertHoliday(self::REGION, 'substituteHoliday:'.self::HOLIDAY, $year, $date); } } @@ -67,7 +63,7 @@ public function testHoliday(int $year, string $expected): void * * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function HolidayDataProvider(): array { @@ -75,7 +71,7 @@ public function HolidayDataProvider(): array for ($y = 0; $y < 50; ++$y) { $year = $this->generateRandomYear(self::ESTABLISHMENT_YEAR); - $date = new DateTime("$year-12-26", new DateTimeZone(self::TIMEZONE)); + $date = new \DateTime("$year-12-26", new \DateTimeZone(self::TIMEZONE)); $data[] = [$year, $date->format('Y-m-d')]; } @@ -85,7 +81,7 @@ public function HolidayDataProvider(): array /** * Tests the holiday defined in this test before establishment. * - * @throws Exception + * @throws \Exception */ public function testHolidayBeforeEstablishment(): void { @@ -99,7 +95,7 @@ public function testHolidayBeforeEstablishment(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -114,7 +110,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/SouthAfrica/SouthAfricaTest.php b/tests/SouthAfrica/SouthAfricaTest.php index 66a882034..5d225a300 100644 --- a/tests/SouthAfrica/SouthAfricaTest.php +++ b/tests/SouthAfrica/SouthAfricaTest.php @@ -15,7 +15,6 @@ namespace Yasumi\tests\SouthAfrica; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\ProviderTestCase; @@ -102,7 +101,7 @@ public function testOtherHolidays(): void } /** - * @throws ReflectionException + * @throws \ReflectionException * @throws \Exception */ public function testSources(): void diff --git a/tests/SouthAfrica/SubstituteDayOfGoodwillTest.php b/tests/SouthAfrica/SubstituteDayOfGoodwillTest.php index 26aaadb16..6091c3f02 100644 --- a/tests/SouthAfrica/SubstituteDayOfGoodwillTest.php +++ b/tests/SouthAfrica/SubstituteDayOfGoodwillTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\SouthAfrica; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -42,7 +39,7 @@ class SubstituteDayOfGoodwillTest extends SouthAfricaBaseTestCase implements Hol /** * Tests the holiday defined in this test on or after establishment. * - * @throws Exception + * @throws \Exception */ public function testHolidayOnAfterEstablishment(): void { @@ -50,14 +47,14 @@ public function testHolidayOnAfterEstablishment(): void self::REGION, self::HOLIDAY, self::ESTABLISHMENT_YEAR, - new DateTime(self::ESTABLISHMENT_YEAR.'-12-27', new DateTimeZone(self::TIMEZONE)) + new \DateTime(self::ESTABLISHMENT_YEAR.'-12-27', new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests the holiday defined in this test before establishment. * - * @throws Exception + * @throws \Exception */ public function testHolidayBeforeEstablishment(): void { @@ -71,7 +68,7 @@ public function testHolidayBeforeEstablishment(): void /** * Tests the holiday defined in this test after completion. * - * @throws Exception + * @throws \Exception */ public function testHolidayDayAfterCompletion(): void { @@ -81,7 +78,7 @@ public function testHolidayDayAfterCompletion(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -96,7 +93,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/SouthAfrica/WorkersDayTest.php b/tests/SouthAfrica/WorkersDayTest.php index a0be0cf41..1823e929d 100644 --- a/tests/SouthAfrica/WorkersDayTest.php +++ b/tests/SouthAfrica/WorkersDayTest.php @@ -14,10 +14,6 @@ namespace Yasumi\tests\SouthAfrica; -use DateInterval; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -48,16 +44,16 @@ class WorkersDayTest extends SouthAfricaBaseTestCase implements HolidayTestCase * @param int $year the year for which the holiday defined in this test needs to be tested * @param string $expected the expected date * - * @throws Exception + * @throws \Exception */ public function testHoliday(int $year, string $expected): void { - $date = new DateTime($expected, new DateTimeZone(self::TIMEZONE)); + $date = new \DateTime($expected, new \DateTimeZone(self::TIMEZONE)); $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $date); // Whenever any public holiday falls on a Sunday, the Monday following on it shall be a public holiday. if (0 === (int) $date->format('w')) { - $date->add(new DateInterval('P1D')); + $date->add(new \DateInterval('P1D')); $this->assertHoliday(self::REGION, 'substituteHoliday:'.self::HOLIDAY, $year, $date); } } @@ -67,7 +63,7 @@ public function testHoliday(int $year, string $expected): void * * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function HolidayDataProvider(): array { @@ -75,7 +71,7 @@ public function HolidayDataProvider(): array for ($y = 0; $y < 50; ++$y) { $year = $this->generateRandomYear(self::ESTABLISHMENT_YEAR); - $date = new DateTime("$year-5-1", new DateTimeZone(self::TIMEZONE)); + $date = new \DateTime("$year-5-1", new \DateTimeZone(self::TIMEZONE)); $data[] = [$year, $date->format('Y-m-d')]; } @@ -85,7 +81,7 @@ public function HolidayDataProvider(): array /** * Tests the holiday defined in this test before establishment. * - * @throws Exception + * @throws \Exception */ public function testHolidayBeforeEstablishment(): void { @@ -99,7 +95,7 @@ public function testHolidayBeforeEstablishment(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -114,7 +110,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/SouthAfrica/YouthDayTest.php b/tests/SouthAfrica/YouthDayTest.php index 81ce3c8d7..ba877e07f 100644 --- a/tests/SouthAfrica/YouthDayTest.php +++ b/tests/SouthAfrica/YouthDayTest.php @@ -14,10 +14,6 @@ namespace Yasumi\tests\SouthAfrica; -use DateInterval; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -48,16 +44,16 @@ class YouthDayTest extends SouthAfricaBaseTestCase implements HolidayTestCase * @param int $year the year for which the holiday defined in this test needs to be tested * @param string $expected the expected date * - * @throws Exception + * @throws \Exception */ public function testHoliday(int $year, string $expected): void { - $date = new DateTime($expected, new DateTimeZone(self::TIMEZONE)); + $date = new \DateTime($expected, new \DateTimeZone(self::TIMEZONE)); $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $date); // Whenever any public holiday falls on a Sunday, the Monday following on it shall be a public holiday. if (0 === (int) $date->format('w')) { - $date->add(new DateInterval('P1D')); + $date->add(new \DateInterval('P1D')); $this->assertHoliday(self::REGION, 'substituteHoliday:'.self::HOLIDAY, $year, $date); } } @@ -67,7 +63,7 @@ public function testHoliday(int $year, string $expected): void * * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function HolidayDataProvider(): array { @@ -75,7 +71,7 @@ public function HolidayDataProvider(): array for ($y = 0; $y < 50; ++$y) { $year = $this->generateRandomYear(self::ESTABLISHMENT_YEAR); - $date = new DateTime("$year-6-16", new DateTimeZone(self::TIMEZONE)); + $date = new \DateTime("$year-6-16", new \DateTimeZone(self::TIMEZONE)); $data[] = [$year, $date->format('Y-m-d')]; } @@ -85,7 +81,7 @@ public function HolidayDataProvider(): array /** * Tests the holiday defined in this test before establishment. * - * @throws Exception + * @throws \Exception */ public function testHolidayBeforeEstablishment(): void { @@ -99,7 +95,7 @@ public function testHolidayBeforeEstablishment(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -114,7 +110,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/SouthKorea/ArborDayTest.php b/tests/SouthKorea/ArborDayTest.php index 0e14aeea1..27b9604be 100644 --- a/tests/SouthKorea/ArborDayTest.php +++ b/tests/SouthKorea/ArborDayTest.php @@ -15,9 +15,6 @@ namespace Yasumi\tests\SouthKorea; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -48,7 +45,7 @@ class ArborDayTest extends SouthKoreaBaseTestCase implements HolidayTestCase /** * Tests the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHoliday(): void { @@ -64,7 +61,7 @@ public function testHoliday(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-4-5", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-4-5", new \DateTimeZone(self::TIMEZONE)) ); } } @@ -72,7 +69,7 @@ public function testHoliday(): void /** * Tests the holiday defined in this test after removal. * - * @throws Exception + * @throws \Exception */ public function testHolidayAfterRemoval(): void { @@ -86,7 +83,7 @@ public function testHolidayAfterRemoval(): void /** * Tests the holiday defined in this test before establishment. * - * @throws Exception + * @throws \Exception */ public function testHolidayBeforeEstablishment(): void { @@ -100,7 +97,7 @@ public function testHolidayBeforeEstablishment(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -118,7 +115,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/SouthKorea/ArmedForcesDayTest.php b/tests/SouthKorea/ArmedForcesDayTest.php index 2a1399755..004910257 100644 --- a/tests/SouthKorea/ArmedForcesDayTest.php +++ b/tests/SouthKorea/ArmedForcesDayTest.php @@ -15,9 +15,6 @@ namespace Yasumi\tests\SouthKorea; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -44,7 +41,7 @@ class ArmedForcesDayTest extends SouthKoreaBaseTestCase implements HolidayTestCa /** * Tests the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHoliday(): void { @@ -53,14 +50,14 @@ public function testHoliday(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-10-1", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-10-1", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests the holiday defined in this test after removal. * - * @throws Exception + * @throws \Exception */ public function testHolidayAfterRemoval(): void { @@ -74,7 +71,7 @@ public function testHolidayAfterRemoval(): void /** * Tests the holiday defined in this test before establishment. * - * @throws Exception + * @throws \Exception */ public function testHolidayBeforeEstablishment(): void { @@ -88,7 +85,7 @@ public function testHolidayBeforeEstablishment(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -103,7 +100,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/SouthKorea/BuddhasBirthdayTest.php b/tests/SouthKorea/BuddhasBirthdayTest.php index 100e043f9..a4e8e9cde 100644 --- a/tests/SouthKorea/BuddhasBirthdayTest.php +++ b/tests/SouthKorea/BuddhasBirthdayTest.php @@ -15,9 +15,6 @@ namespace Yasumi\tests\SouthKorea; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\Provider\SouthKorea; use Yasumi\tests\HolidayTestCase; @@ -40,7 +37,7 @@ class BuddhasBirthdayTest extends SouthKoreaBaseTestCase implements HolidayTestC /** * Tests the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHoliday(): void { @@ -50,7 +47,7 @@ public function testHoliday(): void self::REGION, self::HOLIDAY, $year, - new DateTime(SouthKorea::LUNAR_HOLIDAY[self::HOLIDAY][$year], new DateTimeZone(self::TIMEZONE)) + new \DateTime(SouthKorea::LUNAR_HOLIDAY[self::HOLIDAY][$year], new \DateTimeZone(self::TIMEZONE)) ); } } @@ -58,7 +55,7 @@ public function testHoliday(): void /** * Tests the holiday defined in this test before establishment. * - * @throws Exception + * @throws \Exception */ public function testHolidayBeforeEstablishment(): void { @@ -72,7 +69,7 @@ public function testHolidayBeforeEstablishment(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -90,7 +87,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/SouthKorea/ChildrensDayTest.php b/tests/SouthKorea/ChildrensDayTest.php index 151a09430..abdd12a1c 100644 --- a/tests/SouthKorea/ChildrensDayTest.php +++ b/tests/SouthKorea/ChildrensDayTest.php @@ -15,9 +15,6 @@ namespace Yasumi\tests\SouthKorea; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -39,7 +36,7 @@ class ChildrensDayTest extends SouthKoreaBaseTestCase implements HolidayTestCase /** * Tests the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHoliday(): void { @@ -48,32 +45,32 @@ public function testHoliday(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-5-5", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-5-5", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests the substitute holiday defined in this test (conflict with Buddha's Birthday). * - * @throws Exception + * @throws \Exception */ public function testSubstituteHolidayByBuddhasBirthday(): void { - $tz = new DateTimeZone(self::TIMEZONE); + $tz = new \DateTimeZone(self::TIMEZONE); foreach ([2025, 2044] as $year) { $this->assertHoliday( self::REGION, 'buddhasBirthday', $year, - new DateTime("$year-5-5", $tz) + new \DateTime("$year-5-5", $tz) ); $this->assertSubstituteHoliday( self::REGION, 'buddhasBirthday', $year, - new DateTime("$year-5-6", $tz) + new \DateTime("$year-5-6", $tz) ); } } @@ -81,11 +78,11 @@ public function testSubstituteHolidayByBuddhasBirthday(): void /** * Tests the substitute holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testSubstituteHoliday(): void { - $tz = new DateTimeZone(self::TIMEZONE); + $tz = new \DateTimeZone(self::TIMEZONE); // Before 2022 $this->assertNotSubstituteHoliday(self::REGION, self::HOLIDAY, 2013); @@ -93,7 +90,7 @@ public function testSubstituteHoliday(): void self::REGION, self::HOLIDAY, 2019, - new DateTime('2019-5-6', $tz) + new \DateTime('2019-5-6', $tz) ); // By saturday @@ -101,7 +98,7 @@ public function testSubstituteHoliday(): void self::REGION, self::HOLIDAY, 2029, - new DateTime('2029-5-7', $tz) + new \DateTime('2029-5-7', $tz) ); // By sunday @@ -109,14 +106,14 @@ public function testSubstituteHoliday(): void self::REGION, self::HOLIDAY, 2024, - new DateTime('2024-5-6', $tz) + new \DateTime('2024-5-6', $tz) ); } /** * Tests the holiday defined in this test before establishment. * - * @throws Exception + * @throws \Exception */ public function testHolidayBeforeEstablishment(): void { @@ -130,7 +127,7 @@ public function testHolidayBeforeEstablishment(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -145,7 +142,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/SouthKorea/ChristmasDayTest.php b/tests/SouthKorea/ChristmasDayTest.php index 6ffa74eab..678ac790d 100644 --- a/tests/SouthKorea/ChristmasDayTest.php +++ b/tests/SouthKorea/ChristmasDayTest.php @@ -15,9 +15,6 @@ namespace Yasumi\tests\SouthKorea; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -39,7 +36,7 @@ class ChristmasDayTest extends SouthKoreaBaseTestCase implements HolidayTestCase /** * Tests the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHoliday(): void { @@ -48,14 +45,14 @@ public function testHoliday(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-12-25", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-12-25", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests the holiday defined in this test before establishment. * - * @throws Exception + * @throws \Exception */ public function testHolidayBeforeEstablishment(): void { @@ -69,7 +66,7 @@ public function testHolidayBeforeEstablishment(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -84,7 +81,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/SouthKorea/ChuseokTest.php b/tests/SouthKorea/ChuseokTest.php index 18998348f..dac1b1fe5 100644 --- a/tests/SouthKorea/ChuseokTest.php +++ b/tests/SouthKorea/ChuseokTest.php @@ -15,10 +15,6 @@ namespace Yasumi\tests\SouthKorea; -use DateInterval; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\Provider\SouthKorea; use Yasumi\tests\HolidayTestCase; @@ -41,13 +37,13 @@ class ChuseokTest extends SouthKoreaBaseTestCase implements HolidayTestCase /** * Tests the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHoliday(): void { $year = $this->generateRandomYear(self::ESTABLISHMENT_YEAR, 2050); if (isset(SouthKorea::LUNAR_HOLIDAY[self::HOLIDAY][$year])) { - $date = new DateTime(SouthKorea::LUNAR_HOLIDAY[self::HOLIDAY][$year], new DateTimeZone(self::TIMEZONE)); + $date = new \DateTime(SouthKorea::LUNAR_HOLIDAY[self::HOLIDAY][$year], new \DateTimeZone(self::TIMEZONE)); // Chuseok $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $date); @@ -58,7 +54,7 @@ public function testHoliday(): void self::REGION, 'dayAfterChuseok', $year, - (clone $date)->add(new DateInterval('P1D')) + (clone $date)->add(new \DateInterval('P1D')) ); } @@ -68,7 +64,7 @@ public function testHoliday(): void self::REGION, 'dayBeforeChuseok', $year, - (clone $date)->sub(new DateInterval('P1D')) + (clone $date)->sub(new \DateInterval('P1D')) ); } } @@ -77,18 +73,18 @@ public function testHoliday(): void /** * Tests the substitute holiday defined in this test (conflict with Gaecheonjeol). * - * @throws Exception + * @throws \Exception */ public function testSubstituteHolidayByGaecheonjeol(): void { - $tz = new DateTimeZone(self::TIMEZONE); + $tz = new \DateTimeZone(self::TIMEZONE); foreach ([2017, 2028, 2036, 2039] as $year) { $this->assertHoliday( self::REGION, 'nationalFoundationDay', $year, - new DateTime("$year-10-3", $tz) + new \DateTime("$year-10-3", $tz) ); } @@ -96,43 +92,43 @@ public function testSubstituteHolidayByGaecheonjeol(): void self::REGION, 'dayBeforeChuseok', 2017, - new DateTime('2017-10-6', $tz) + new \DateTime('2017-10-6', $tz) ); $this->assertSubstituteHoliday( self::REGION, 'chuseok', 2028, - new DateTime('2028-10-5', $tz) + new \DateTime('2028-10-5', $tz) ); $this->assertSubstituteHoliday( self::REGION, 'dayBeforeChuseok', 2036, - new DateTime('2036-10-6', $tz) + new \DateTime('2036-10-6', $tz) ); $this->assertSubstituteHoliday( self::REGION, 'dayAfterChuseok', 2039, - new DateTime('2039-10-5', $tz) + new \DateTime('2039-10-5', $tz) ); } /** * Tests the substitute holiday defined in this test (conflict with Sunday). * - * @throws Exception + * @throws \Exception */ public function testSubstituteHoliday(): void { - $tz = new DateTimeZone(self::TIMEZONE); + $tz = new \DateTimeZone(self::TIMEZONE); // Before 2022 $this->assertSubstituteHoliday( self::REGION, 'dayBeforeChuseok', 2014, - new DateTime('2014-9-10', $tz) + new \DateTime('2014-9-10', $tz) ); // By sunday @@ -140,26 +136,26 @@ public function testSubstituteHoliday(): void self::REGION, 'dayBeforeChuseok', 2025, - new DateTime('2025-10-8', $tz) + new \DateTime('2025-10-8', $tz) ); $this->assertSubstituteHoliday( self::REGION, 'chuseok', 2032, - new DateTime('2032-9-21', $tz) + new \DateTime('2032-9-21', $tz) ); $this->assertSubstituteHoliday( self::REGION, 'dayAfterChuseok', 2036, - new DateTime('2036-10-7', $tz) + new \DateTime('2036-10-7', $tz) ); } /** * Tests the holiday defined in this test before establishment. * - * @throws Exception + * @throws \Exception */ public function testHolidayBeforeEstablishment(): void { @@ -173,7 +169,7 @@ public function testHolidayBeforeEstablishment(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -207,7 +203,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/SouthKorea/ConstitutionDayTest.php b/tests/SouthKorea/ConstitutionDayTest.php index 0933b6f1a..4793359be 100644 --- a/tests/SouthKorea/ConstitutionDayTest.php +++ b/tests/SouthKorea/ConstitutionDayTest.php @@ -15,9 +15,6 @@ namespace Yasumi\tests\SouthKorea; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -44,7 +41,7 @@ class ConstitutionDayTest extends SouthKoreaBaseTestCase implements HolidayTestC /** * Tests the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHoliday(): void { @@ -53,14 +50,14 @@ public function testHoliday(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-7-17", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-7-17", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests the holiday defined in this test after removal. * - * @throws Exception + * @throws \Exception */ public function testHolidayAfterRemoval(): void { @@ -74,7 +71,7 @@ public function testHolidayAfterRemoval(): void /** * Tests the holiday defined in this test before establishment. * - * @throws Exception + * @throws \Exception */ public function testHolidayBeforeEstablishment(): void { @@ -88,7 +85,7 @@ public function testHolidayBeforeEstablishment(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -103,7 +100,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/SouthKorea/GaecheonjeolTest.php b/tests/SouthKorea/GaecheonjeolTest.php index eea712535..047e50859 100644 --- a/tests/SouthKorea/GaecheonjeolTest.php +++ b/tests/SouthKorea/GaecheonjeolTest.php @@ -15,9 +15,6 @@ namespace Yasumi\tests\SouthKorea; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -39,7 +36,7 @@ class GaecheonjeolTest extends SouthKoreaBaseTestCase implements HolidayTestCase /** * Tests the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHoliday(): void { @@ -48,30 +45,30 @@ public function testHoliday(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-10-3", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-10-3", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests the substitute holiday defined in this test (conflict with Chuseok). * - * @throws Exception + * @throws \Exception */ public function testSubstituteByChuseok(): void { - $tz = new DateTimeZone(self::TIMEZONE); + $tz = new \DateTimeZone(self::TIMEZONE); $this->assertHoliday( self::REGION, 'chuseok', 2028, - new DateTime('2028-10-3', $tz) + new \DateTime('2028-10-3', $tz) ); $this->assertHoliday( self::REGION, 'dayBeforeChuseok', 2036, - new DateTime('2036-10-3', $tz) + new \DateTime('2036-10-3', $tz) ); // Chuseok will be substitute instead of Gaecheonjeol. $this->assertNotSubstituteHoliday(self::REGION, self::HOLIDAY, 2028); @@ -81,11 +78,11 @@ public function testSubstituteByChuseok(): void /** * Tests the substitute holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testSubstituteHoliday(): void { - $tz = new DateTimeZone(self::TIMEZONE); + $tz = new \DateTimeZone(self::TIMEZONE); // Before 2022 $this->assertNotSubstituteHoliday(self::REGION, self::HOLIDAY, 2015); @@ -94,7 +91,7 @@ public function testSubstituteHoliday(): void self::REGION, self::HOLIDAY, 2021, - new DateTime('2021-10-4', $tz) + new \DateTime('2021-10-4', $tz) ); // By saturday @@ -102,7 +99,7 @@ public function testSubstituteHoliday(): void self::REGION, self::HOLIDAY, 2026, - new DateTime('2026-10-5', $tz) + new \DateTime('2026-10-5', $tz) ); // By sunday @@ -110,14 +107,14 @@ public function testSubstituteHoliday(): void self::REGION, self::HOLIDAY, 2032, - new DateTime('2032-10-4', $tz) + new \DateTime('2032-10-4', $tz) ); } /** * Tests the holiday defined in this test before establishment. * - * @throws Exception + * @throws \Exception */ public function testHolidayBeforeEstablishment(): void { @@ -131,7 +128,7 @@ public function testHolidayBeforeEstablishment(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -146,7 +143,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/SouthKorea/HangulDayTest.php b/tests/SouthKorea/HangulDayTest.php index dd540e8a4..bb370127e 100644 --- a/tests/SouthKorea/HangulDayTest.php +++ b/tests/SouthKorea/HangulDayTest.php @@ -15,9 +15,6 @@ namespace Yasumi\tests\SouthKorea; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -39,7 +36,7 @@ class HangulDayTest extends SouthKoreaBaseTestCase implements HolidayTestCase /** * Tests the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHoliday(): void { @@ -55,7 +52,7 @@ public function testHoliday(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-10-9", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-10-9", new \DateTimeZone(self::TIMEZONE)) ); } } @@ -63,11 +60,11 @@ public function testHoliday(): void /** * Tests the substitute holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testSubstituteHoliday(): void { - $tz = new DateTimeZone(self::TIMEZONE); + $tz = new \DateTimeZone(self::TIMEZONE); // Before 2022 $this->assertNotSubstituteHoliday(self::REGION, self::HOLIDAY, 2016); @@ -75,7 +72,7 @@ public function testSubstituteHoliday(): void self::REGION, self::HOLIDAY, 2021, - new DateTime('2021-10-11', $tz) + new \DateTime('2021-10-11', $tz) ); // By saturday @@ -83,7 +80,7 @@ public function testSubstituteHoliday(): void self::REGION, self::HOLIDAY, 2027, - new DateTime('2027-10-11', $tz) + new \DateTime('2027-10-11', $tz) ); // By sunday @@ -91,14 +88,14 @@ public function testSubstituteHoliday(): void self::REGION, self::HOLIDAY, 2022, - new DateTime('2022-10-10', $tz) + new \DateTime('2022-10-10', $tz) ); } /** * Tests the holiday defined in this test before establishment. * - * @throws Exception + * @throws \Exception */ public function testHolidayBeforeEstablishment(): void { @@ -112,7 +109,7 @@ public function testHolidayBeforeEstablishment(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -130,7 +127,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/SouthKorea/IndependenceMovementDayTest.php b/tests/SouthKorea/IndependenceMovementDayTest.php index 9bc657de6..80c7ddc1a 100644 --- a/tests/SouthKorea/IndependenceMovementDayTest.php +++ b/tests/SouthKorea/IndependenceMovementDayTest.php @@ -15,9 +15,6 @@ namespace Yasumi\tests\SouthKorea; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -39,7 +36,7 @@ class IndependenceMovementDayTest extends SouthKoreaBaseTestCase implements Holi /** * Tests the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHoliday(): void { @@ -48,18 +45,18 @@ public function testHoliday(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-3-1", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-3-1", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests the substitute holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testSubstituteHoliday(): void { - $tz = new DateTimeZone(self::TIMEZONE); + $tz = new \DateTimeZone(self::TIMEZONE); // Before 2022 $this->assertNotSubstituteHoliday(self::REGION, self::HOLIDAY, 2020); @@ -69,13 +66,13 @@ public function testSubstituteHoliday(): void self::REGION, self::HOLIDAY, 2025, - new DateTime('2025-3-3', $tz) + new \DateTime('2025-3-3', $tz) ); $this->assertSubstituteHoliday( self::REGION, self::HOLIDAY, 2031, - new DateTime('2031-3-3', $tz) + new \DateTime('2031-3-3', $tz) ); // By sunday @@ -83,21 +80,21 @@ public function testSubstituteHoliday(): void self::REGION, self::HOLIDAY, 2026, - new DateTime('2026-3-2', $tz) + new \DateTime('2026-3-2', $tz) ); // By sunday $this->assertSubstituteHoliday( self::REGION, self::HOLIDAY, 2037, - new DateTime('2037-3-2', $tz) + new \DateTime('2037-3-2', $tz) ); } /** * Tests the holiday defined in this test before establishment. * - * @throws Exception + * @throws \Exception */ public function testHolidayBeforeEstablishment(): void { @@ -111,7 +108,7 @@ public function testHolidayBeforeEstablishment(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -126,7 +123,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/SouthKorea/LiberationDayTest.php b/tests/SouthKorea/LiberationDayTest.php index 24ffec961..3a250f2fe 100644 --- a/tests/SouthKorea/LiberationDayTest.php +++ b/tests/SouthKorea/LiberationDayTest.php @@ -15,9 +15,6 @@ namespace Yasumi\tests\SouthKorea; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -39,7 +36,7 @@ class LiberationDayTest extends SouthKoreaBaseTestCase implements HolidayTestCas /** * Tests the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHoliday(): void { @@ -48,18 +45,18 @@ public function testHoliday(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-8-15", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-8-15", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests the substitute holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testSubstituteHoliday(): void { - $tz = new DateTimeZone(self::TIMEZONE); + $tz = new \DateTimeZone(self::TIMEZONE); // Before 2022 $this->assertNotSubstituteHoliday(self::REGION, self::HOLIDAY, 2020); @@ -69,7 +66,7 @@ public function testSubstituteHoliday(): void self::REGION, self::HOLIDAY, 2021, - new DateTime('2021-8-16', $tz) + new \DateTime('2021-8-16', $tz) ); // By saturday @@ -77,7 +74,7 @@ public function testSubstituteHoliday(): void self::REGION, self::HOLIDAY, 2037, - new DateTime('2037-8-17', $tz) + new \DateTime('2037-8-17', $tz) ); // By sunday @@ -85,14 +82,14 @@ public function testSubstituteHoliday(): void self::REGION, self::HOLIDAY, 2027, - new DateTime('2027-8-16', $tz) + new \DateTime('2027-8-16', $tz) ); } /** * Tests the holiday defined in this test before establishment. * - * @throws Exception + * @throws \Exception */ public function testHolidayBeforeEstablishment(): void { @@ -106,7 +103,7 @@ public function testHolidayBeforeEstablishment(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -121,7 +118,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/SouthKorea/MemorialDayTest.php b/tests/SouthKorea/MemorialDayTest.php index 7e71fbdf2..43b882e33 100644 --- a/tests/SouthKorea/MemorialDayTest.php +++ b/tests/SouthKorea/MemorialDayTest.php @@ -15,9 +15,6 @@ namespace Yasumi\tests\SouthKorea; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -39,7 +36,7 @@ class MemorialDayTest extends SouthKoreaBaseTestCase implements HolidayTestCase /** * Tests the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHoliday(): void { @@ -48,14 +45,14 @@ public function testHoliday(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-6-6", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-6-6", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests the holiday defined in this test before establishment. * - * @throws Exception + * @throws \Exception */ public function testHolidayBeforeEstablishment(): void { @@ -69,7 +66,7 @@ public function testHolidayBeforeEstablishment(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -84,7 +81,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/SouthKorea/NewYearsDayTest.php b/tests/SouthKorea/NewYearsDayTest.php index 7954c4e7c..8d2b9e6dc 100644 --- a/tests/SouthKorea/NewYearsDayTest.php +++ b/tests/SouthKorea/NewYearsDayTest.php @@ -15,10 +15,6 @@ namespace Yasumi\tests\SouthKorea; -use DateInterval; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -40,12 +36,12 @@ class NewYearsDayTest extends SouthKoreaBaseTestCase implements HolidayTestCase /** * Tests the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHoliday(): void { $year = $this->generateRandomYear(self::ESTABLISHMENT_YEAR); - $date = new DateTime("$year-1-1", new DateTimeZone(self::TIMEZONE)); + $date = new \DateTime("$year-1-1", new \DateTimeZone(self::TIMEZONE)); // New Year's Day $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $date); @@ -56,7 +52,7 @@ public function testHoliday(): void self::REGION, 'dayAfterNewYearsDay', $year, - (clone $date)->add(new DateInterval('P1D')) + (clone $date)->add(new \DateInterval('P1D')) ); } @@ -66,7 +62,7 @@ public function testHoliday(): void self::REGION, 'twoDaysLaterNewYearsDay', $year, - (clone $date)->add(new DateInterval('P2D')) + (clone $date)->add(new \DateInterval('P2D')) ); } } @@ -74,7 +70,7 @@ public function testHoliday(): void /** * Tests the holiday defined in this test after removal. * - * @throws Exception + * @throws \Exception */ public function testHolidayAfterRemoval(): void { @@ -93,7 +89,7 @@ public function testHolidayAfterRemoval(): void /** * Tests the holiday defined in this test before establishment. * - * @throws Exception + * @throws \Exception */ public function testHolidayBeforeEstablishment(): void { @@ -107,7 +103,7 @@ public function testHolidayBeforeEstablishment(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -134,7 +130,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/SouthKorea/SeollalTest.php b/tests/SouthKorea/SeollalTest.php index 5da618126..3a86a5147 100644 --- a/tests/SouthKorea/SeollalTest.php +++ b/tests/SouthKorea/SeollalTest.php @@ -15,10 +15,6 @@ namespace Yasumi\tests\SouthKorea; -use DateInterval; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\Provider\SouthKorea; use Yasumi\tests\HolidayTestCase; @@ -41,13 +37,13 @@ class SeollalTest extends SouthKoreaBaseTestCase implements HolidayTestCase /** * Tests the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHoliday(): void { $year = $this->generateRandomYear(self::ESTABLISHMENT_YEAR, 2050); if (isset(SouthKorea::LUNAR_HOLIDAY[self::HOLIDAY][$year])) { - $date = new DateTime(SouthKorea::LUNAR_HOLIDAY[self::HOLIDAY][$year], new DateTimeZone(self::TIMEZONE)); + $date = new \DateTime(SouthKorea::LUNAR_HOLIDAY[self::HOLIDAY][$year], new \DateTimeZone(self::TIMEZONE)); // Seollal $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $date); @@ -58,7 +54,7 @@ public function testHoliday(): void self::REGION, 'dayBeforeSeollal', $year, - (clone $date)->sub(new DateInterval('P1D')) + (clone $date)->sub(new \DateInterval('P1D')) ); // Day after Seollal @@ -66,7 +62,7 @@ public function testHoliday(): void self::REGION, 'dayAfterSeollal', $year, - (clone $date)->add(new DateInterval('P1D')) + (clone $date)->add(new \DateInterval('P1D')) ); } } @@ -75,18 +71,18 @@ public function testHoliday(): void /** * Tests the substitute holiday defined in this test (conflict with Sunday). * - * @throws Exception + * @throws \Exception */ public function testSubstituteHoliday(): void { - $tz = new DateTimeZone(self::TIMEZONE); + $tz = new \DateTimeZone(self::TIMEZONE); // Before 2022 $this->assertSubstituteHoliday( self::REGION, 'dayBeforeSeollal', 2016, - new DateTime('2016-2-10', $tz) + new \DateTime('2016-2-10', $tz) ); $this->assertNotSubstituteHoliday(self::REGION, 'dayAfterSeollal', 2021); @@ -95,26 +91,26 @@ public function testSubstituteHoliday(): void self::REGION, 'dayBeforeSeollal', 2033, - new DateTime('2033-2-2', $tz) + new \DateTime('2033-2-2', $tz) ); $this->assertSubstituteHoliday( self::REGION, 'seollal', 2034, - new DateTime('2034-2-21', $tz) + new \DateTime('2034-2-21', $tz) ); $this->assertSubstituteHoliday( self::REGION, 'dayAfterSeollal', 2024, - new DateTime('2024-2-12', $tz) + new \DateTime('2024-2-12', $tz) ); } /** * Tests the holiday defined in this test before establishment. * - * @throws Exception + * @throws \Exception */ public function testHolidayBeforeEstablishment(): void { @@ -128,7 +124,7 @@ public function testHolidayBeforeEstablishment(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -160,7 +156,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/SouthKorea/SouthKoreaTest.php b/tests/SouthKorea/SouthKoreaTest.php index 00775c6f3..31a30330d 100644 --- a/tests/SouthKorea/SouthKoreaTest.php +++ b/tests/SouthKorea/SouthKoreaTest.php @@ -15,7 +15,6 @@ namespace Yasumi\tests\SouthKorea; -use ReflectionException; use Yasumi\Holiday; use Yasumi\Provider\SouthKorea; use Yasumi\tests\ProviderTestCase; @@ -134,7 +133,7 @@ public function testOtherHolidays(): void } /** - * @throws ReflectionException + * @throws \ReflectionException * @throws \Exception */ public function testSources(): void diff --git a/tests/Spain/AllSaintsDayTest.php b/tests/Spain/AllSaintsDayTest.php index 7751c91f5..a5ca65df3 100644 --- a/tests/Spain/AllSaintsDayTest.php +++ b/tests/Spain/AllSaintsDayTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\Spain; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,8 +32,8 @@ class AllSaintsDayTest extends SpainBaseTestCase implements HolidayTestCase * * @dataProvider HolidayDataProvider * - * @param int $year the year for which the holiday defined in this test needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which the holiday defined in this test needs to be tested + * @param \DateTime $expected the expected date */ public function testHoliday(int $year, \DateTimeInterface $expected): void { @@ -47,7 +45,7 @@ public function testHoliday(int $year, \DateTimeInterface $expected): void * * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function HolidayDataProvider(): array { @@ -57,7 +55,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -72,7 +70,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Spain/Andalusia/AndalusiaDayTest.php b/tests/Spain/Andalusia/AndalusiaDayTest.php index 41d42e714..d29b996f0 100644 --- a/tests/Spain/Andalusia/AndalusiaDayTest.php +++ b/tests/Spain/Andalusia/AndalusiaDayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Spain\Andalusia; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -38,7 +35,7 @@ class AndalusiaDayTest extends AndalusiaBaseTestCase implements HolidayTestCase /** * Tests the holiday defined in this test on or after establishment. * - * @throws Exception + * @throws \Exception */ public function testHolidayOnAfterEstablishment(): void { @@ -47,14 +44,14 @@ public function testHolidayOnAfterEstablishment(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-2-28", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-2-28", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests the holiday defined in this test before establishment. * - * @throws Exception + * @throws \Exception */ public function testHolidayBeforeEstablishment(): void { @@ -68,7 +65,7 @@ public function testHolidayBeforeEstablishment(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -83,7 +80,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Spain/Andalusia/AndalusiaTest.php b/tests/Spain/Andalusia/AndalusiaTest.php index 028ecb24d..503a60328 100644 --- a/tests/Spain/Andalusia/AndalusiaTest.php +++ b/tests/Spain/Andalusia/AndalusiaTest.php @@ -14,7 +14,6 @@ namespace Yasumi\tests\Spain\Andalusia; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\ProviderTestCase; @@ -94,7 +93,7 @@ public function testOtherHolidays(): void } /** - * @throws ReflectionException + * @throws \ReflectionException * @throws \Exception */ public function testSources(): void diff --git a/tests/Spain/Aragon/AragonTest.php b/tests/Spain/Aragon/AragonTest.php index 4e4ab5a19..419123298 100644 --- a/tests/Spain/Aragon/AragonTest.php +++ b/tests/Spain/Aragon/AragonTest.php @@ -14,7 +14,6 @@ namespace Yasumi\tests\Spain\Aragon; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\ProviderTestCase; @@ -94,7 +93,7 @@ public function testOtherHolidays(): void } /** - * @throws ReflectionException + * @throws \ReflectionException * @throws \Exception */ public function testSources(): void diff --git a/tests/Spain/Aragon/StGeorgesDayTest.php b/tests/Spain/Aragon/StGeorgesDayTest.php index bbf9c7167..18facfc03 100644 --- a/tests/Spain/Aragon/StGeorgesDayTest.php +++ b/tests/Spain/Aragon/StGeorgesDayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Spain\Aragon; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -33,7 +30,7 @@ class StGeorgesDayTest extends AragonBaseTestCase implements HolidayTestCase /** * Tests the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHoliday(): void { @@ -42,14 +39,14 @@ public function testHoliday(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-4-23", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-4-23", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -64,7 +61,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Spain/AssumptionOfMaryTest.php b/tests/Spain/AssumptionOfMaryTest.php index cd67bf140..7b18abd7b 100644 --- a/tests/Spain/AssumptionOfMaryTest.php +++ b/tests/Spain/AssumptionOfMaryTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\Spain; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,8 +32,8 @@ class AssumptionOfMaryTest extends SpainBaseTestCase implements HolidayTestCase * * @dataProvider HolidayDataProvider * - * @param int $year the year for which the holiday defined in this test needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which the holiday defined in this test needs to be tested + * @param \DateTime $expected the expected date */ public function testHoliday(int $year, \DateTimeInterface $expected): void { @@ -47,7 +45,7 @@ public function testHoliday(int $year, \DateTimeInterface $expected): void * * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function HolidayDataProvider(): array { @@ -57,7 +55,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -72,7 +70,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Spain/Asturias/AsturiasDayTest.php b/tests/Spain/Asturias/AsturiasDayTest.php index 09415ae02..24097f52a 100644 --- a/tests/Spain/Asturias/AsturiasDayTest.php +++ b/tests/Spain/Asturias/AsturiasDayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Spain\Asturias; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -38,7 +35,7 @@ class AsturiasDayTest extends AsturiasBaseTestCase implements HolidayTestCase /** * Tests the holiday defined in this test on or after establishment. * - * @throws Exception + * @throws \Exception */ public function testHolidayOnAfterEstablishment(): void { @@ -47,14 +44,14 @@ public function testHolidayOnAfterEstablishment(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-9-8", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-9-8", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests the holiday defined in this test before establishment. * - * @throws Exception + * @throws \Exception */ public function testHolidayBeforeEstablishment(): void { @@ -68,7 +65,7 @@ public function testHolidayBeforeEstablishment(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -83,7 +80,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Spain/Asturias/AsturiasTest.php b/tests/Spain/Asturias/AsturiasTest.php index 2ad468457..80466d323 100644 --- a/tests/Spain/Asturias/AsturiasTest.php +++ b/tests/Spain/Asturias/AsturiasTest.php @@ -14,7 +14,6 @@ namespace Yasumi\tests\Spain\Asturias; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\ProviderTestCase; @@ -95,7 +94,7 @@ public function testOtherHolidays(): void } /** - * @throws ReflectionException + * @throws \ReflectionException * @throws \Exception */ public function testSources(): void diff --git a/tests/Spain/BalearicIslands/BalearicIslandsDayTest.php b/tests/Spain/BalearicIslands/BalearicIslandsDayTest.php index 586a07618..db581d24b 100644 --- a/tests/Spain/BalearicIslands/BalearicIslandsDayTest.php +++ b/tests/Spain/BalearicIslands/BalearicIslandsDayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Spain\BalearicIslands; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -38,7 +35,7 @@ class BalearicIslandsDayTest extends BalearicIslandsBaseTestCase implements Holi /** * Tests the holiday defined in this test on or after establishment. * - * @throws Exception + * @throws \Exception */ public function testHolidayOnAfterEstablishment(): void { @@ -47,14 +44,14 @@ public function testHolidayOnAfterEstablishment(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-3-1", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-3-1", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests the holiday defined in this test before establishment. * - * @throws Exception + * @throws \Exception */ public function testHolidayBeforeEstablishment(): void { @@ -68,7 +65,7 @@ public function testHolidayBeforeEstablishment(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -83,7 +80,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Spain/BalearicIslands/BalearicIslandsTest.php b/tests/Spain/BalearicIslands/BalearicIslandsTest.php index 62447a408..f1c3814c8 100644 --- a/tests/Spain/BalearicIslands/BalearicIslandsTest.php +++ b/tests/Spain/BalearicIslands/BalearicIslandsTest.php @@ -14,7 +14,6 @@ namespace Yasumi\tests\Spain\BalearicIslands; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\ProviderTestCase; @@ -102,7 +101,7 @@ public function testOtherHolidays(): void } /** - * @throws ReflectionException + * @throws \ReflectionException * @throws \Exception */ public function testSources(): void diff --git a/tests/Spain/BasqueCountry/BasqueCountryDayTest.php b/tests/Spain/BasqueCountry/BasqueCountryDayTest.php index 783c2acf0..e2d888ba2 100644 --- a/tests/Spain/BasqueCountry/BasqueCountryDayTest.php +++ b/tests/Spain/BasqueCountry/BasqueCountryDayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Spain\BasqueCountry; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -43,7 +40,7 @@ class BasqueCountryDayTest extends BasqueCountryBaseTestCase implements HolidayT /** * Tests the holiday defined in this test on or after establishment. * - * @throws Exception + * @throws \Exception */ public function testHolidayOnAfterEstablishment(): void { @@ -52,14 +49,14 @@ public function testHolidayOnAfterEstablishment(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-10-25", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-10-25", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests the holiday defined in this test before establishment. * - * @throws Exception + * @throws \Exception */ public function testHolidayBeforeEstablishment(): void { @@ -73,7 +70,7 @@ public function testHolidayBeforeEstablishment(): void /** * Tests the holiday defined in this test after abolishment. * - * @throws Exception + * @throws \Exception */ public function testHolidayDayAfterAbolishment(): void { @@ -83,7 +80,7 @@ public function testHolidayDayAfterAbolishment(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -98,7 +95,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Spain/BasqueCountry/BasqueCountryTest.php b/tests/Spain/BasqueCountry/BasqueCountryTest.php index f447b6d23..ffbc6b86f 100644 --- a/tests/Spain/BasqueCountry/BasqueCountryTest.php +++ b/tests/Spain/BasqueCountry/BasqueCountryTest.php @@ -14,7 +14,6 @@ namespace Yasumi\tests\Spain\BasqueCountry; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\ProviderTestCase; @@ -95,7 +94,7 @@ public function testOtherHolidays(): void } /** - * @throws ReflectionException + * @throws \ReflectionException * @throws \Exception */ public function testSources(): void diff --git a/tests/Spain/CanaryIslands/CanaryIslandsDayTest.php b/tests/Spain/CanaryIslands/CanaryIslandsDayTest.php index a1e7f035f..bf4f829e8 100644 --- a/tests/Spain/CanaryIslands/CanaryIslandsDayTest.php +++ b/tests/Spain/CanaryIslands/CanaryIslandsDayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Spain\CanaryIslands; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -38,7 +35,7 @@ class CanaryIslandsDayTest extends CanaryIslandsBaseTestCase implements HolidayT /** * Tests the holiday defined in this test on or after establishment. * - * @throws Exception + * @throws \Exception */ public function testHolidayOnAfterEstablishment(): void { @@ -47,14 +44,14 @@ public function testHolidayOnAfterEstablishment(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-5-30", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-5-30", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests the holiday defined in this test before establishment. * - * @throws Exception + * @throws \Exception */ public function testHolidayBeforeEstablishment(): void { @@ -68,7 +65,7 @@ public function testHolidayBeforeEstablishment(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -83,7 +80,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Spain/CanaryIslands/CanaryIslandsTest.php b/tests/Spain/CanaryIslands/CanaryIslandsTest.php index 97b996cb1..790864e5f 100644 --- a/tests/Spain/CanaryIslands/CanaryIslandsTest.php +++ b/tests/Spain/CanaryIslands/CanaryIslandsTest.php @@ -14,7 +14,6 @@ namespace Yasumi\tests\Spain\CanaryIslands; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\ProviderTestCase; @@ -94,7 +93,7 @@ public function testOtherHolidays(): void } /** - * @throws ReflectionException + * @throws \ReflectionException * @throws \Exception */ public function testSources(): void diff --git a/tests/Spain/Cantabria/CantabriaDayTest.php b/tests/Spain/Cantabria/CantabriaDayTest.php index a8ca80019..69fbaa957 100644 --- a/tests/Spain/Cantabria/CantabriaDayTest.php +++ b/tests/Spain/Cantabria/CantabriaDayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Spain\Cantabria; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -38,7 +35,7 @@ class CantabriaDayTest extends CantabriaBaseTestCase implements HolidayTestCase /** * Tests the holiday defined in this test on or after establishment. * - * @throws Exception + * @throws \Exception */ public function testHolidayOnAfterEstablishment(): void { @@ -47,14 +44,14 @@ public function testHolidayOnAfterEstablishment(): void self::REGION, self::HOLIDAY, $year, - new DateTime("second sunday of august $year", new DateTimeZone(self::TIMEZONE)) + new \DateTime("second sunday of august $year", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests the holiday defined in this test before establishment. * - * @throws Exception + * @throws \Exception */ public function testHolidayBeforeEstablishment(): void { @@ -68,7 +65,7 @@ public function testHolidayBeforeEstablishment(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -83,7 +80,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Spain/Cantabria/CantabriaTest.php b/tests/Spain/Cantabria/CantabriaTest.php index 276bfb00a..7b387cb1d 100644 --- a/tests/Spain/Cantabria/CantabriaTest.php +++ b/tests/Spain/Cantabria/CantabriaTest.php @@ -14,7 +14,6 @@ namespace Yasumi\tests\Spain\Cantabria; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\ProviderTestCase; @@ -94,7 +93,7 @@ public function testOtherHolidays(): void } /** - * @throws ReflectionException + * @throws \ReflectionException * @throws \Exception */ public function testSources(): void diff --git a/tests/Spain/CastileAndLeon/CastileAndLeonDayTest.php b/tests/Spain/CastileAndLeon/CastileAndLeonDayTest.php index b408bf96b..58240e25e 100644 --- a/tests/Spain/CastileAndLeon/CastileAndLeonDayTest.php +++ b/tests/Spain/CastileAndLeon/CastileAndLeonDayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Spain\CastileAndLeon; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -38,7 +35,7 @@ class CastileAndLeonDayTest extends CastileAndLeonBaseTestCase implements Holida /** * Tests the holiday defined in this test on or after establishment. * - * @throws Exception + * @throws \Exception */ public function testHolidayOnAfterEstablishment(): void { @@ -47,14 +44,14 @@ public function testHolidayOnAfterEstablishment(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-4-23", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-4-23", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests the holiday defined in this test before establishment. * - * @throws Exception + * @throws \Exception */ public function testHolidayBeforeEstablishment(): void { @@ -68,7 +65,7 @@ public function testHolidayBeforeEstablishment(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -83,7 +80,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Spain/CastileAndLeon/CastileAndLeonTest.php b/tests/Spain/CastileAndLeon/CastileAndLeonTest.php index 2a23d3a8c..ef6f77083 100644 --- a/tests/Spain/CastileAndLeon/CastileAndLeonTest.php +++ b/tests/Spain/CastileAndLeon/CastileAndLeonTest.php @@ -14,7 +14,6 @@ namespace Yasumi\tests\Spain\CastileAndLeon; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\ProviderTestCase; @@ -94,7 +93,7 @@ public function testOtherHolidays(): void } /** - * @throws ReflectionException + * @throws \ReflectionException * @throws \Exception */ public function testSources(): void diff --git a/tests/Spain/CastillaLaMancha/CastillaLaManchaDayTest.php b/tests/Spain/CastillaLaMancha/CastillaLaManchaDayTest.php index 966de18e0..83326739c 100644 --- a/tests/Spain/CastillaLaMancha/CastillaLaManchaDayTest.php +++ b/tests/Spain/CastillaLaMancha/CastillaLaManchaDayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Spain\CastillaLaMancha; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -38,7 +35,7 @@ class CastillaLaManchaDayTest extends CastillaLaManchaBaseTestCase implements Ho /** * Tests the holiday defined in this test on or after establishment. * - * @throws Exception + * @throws \Exception */ public function testHolidayOnAfterEstablishment(): void { @@ -47,14 +44,14 @@ public function testHolidayOnAfterEstablishment(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-5-31", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-5-31", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests the holiday defined in this test before establishment. * - * @throws Exception + * @throws \Exception */ public function testHolidayBeforeEstablishment(): void { @@ -68,7 +65,7 @@ public function testHolidayBeforeEstablishment(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -83,7 +80,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Spain/CastillaLaMancha/CastillaLaManchaTest.php b/tests/Spain/CastillaLaMancha/CastillaLaManchaTest.php index 6849f981f..9174f866d 100644 --- a/tests/Spain/CastillaLaMancha/CastillaLaManchaTest.php +++ b/tests/Spain/CastillaLaMancha/CastillaLaManchaTest.php @@ -14,7 +14,6 @@ namespace Yasumi\tests\Spain\CastillaLaMancha; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\ProviderTestCase; @@ -95,7 +94,7 @@ public function testOtherHolidays(): void } /** - * @throws ReflectionException + * @throws \ReflectionException * @throws \Exception */ public function testSources(): void diff --git a/tests/Spain/Catalonia/CataloniaTest.php b/tests/Spain/Catalonia/CataloniaTest.php index 4a4a9381c..719d05d14 100644 --- a/tests/Spain/Catalonia/CataloniaTest.php +++ b/tests/Spain/Catalonia/CataloniaTest.php @@ -14,7 +14,6 @@ namespace Yasumi\tests\Spain\Catalonia; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\ProviderTestCase; @@ -96,7 +95,7 @@ public function testOtherHolidays(): void } /** - * @throws ReflectionException + * @throws \ReflectionException * @throws \Exception */ public function testSources(): void diff --git a/tests/Spain/Catalonia/nationalCataloniaDayTest.php b/tests/Spain/Catalonia/nationalCataloniaDayTest.php index 6f1a8ad55..df2a1dce0 100644 --- a/tests/Spain/Catalonia/nationalCataloniaDayTest.php +++ b/tests/Spain/Catalonia/nationalCataloniaDayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Spain\Catalonia; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -38,7 +35,7 @@ class nationalCataloniaDayTest extends CataloniaBaseTestCase implements HolidayT /** * Tests the holiday defined in this test on or after establishment. * - * @throws Exception + * @throws \Exception */ public function testHolidayOnAfterEstablishment(): void { @@ -47,14 +44,14 @@ public function testHolidayOnAfterEstablishment(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-9-11", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-9-11", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests the holiday defined in this test before establishment. * - * @throws Exception + * @throws \Exception */ public function testHolidayBeforeEstablishment(): void { @@ -68,7 +65,7 @@ public function testHolidayBeforeEstablishment(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -86,7 +83,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Spain/Catalonia/stJohnsDayTest.php b/tests/Spain/Catalonia/stJohnsDayTest.php index 26109d08d..514e29a77 100644 --- a/tests/Spain/Catalonia/stJohnsDayTest.php +++ b/tests/Spain/Catalonia/stJohnsDayTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\Spain\Catalonia; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,8 +32,8 @@ class stJohnsDayTest extends CataloniaBaseTestCase implements HolidayTestCase * * @dataProvider HolidayDataProvider * - * @param int $year the year for which the holiday defined in this test needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which the holiday defined in this test needs to be tested + * @param \DateTime $expected the expected date */ public function testHoliday(int $year, \DateTimeInterface $expected): void { @@ -47,7 +45,7 @@ public function testHoliday(int $year, \DateTimeInterface $expected): void * * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function HolidayDataProvider(): array { @@ -57,7 +55,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -72,7 +70,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Spain/Ceuta/CeutaTest.php b/tests/Spain/Ceuta/CeutaTest.php index db8fc7f67..ad2bd5d94 100644 --- a/tests/Spain/Ceuta/CeutaTest.php +++ b/tests/Spain/Ceuta/CeutaTest.php @@ -14,7 +14,6 @@ namespace Yasumi\tests\Spain\Ceuta; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\ProviderTestCase; @@ -94,7 +93,7 @@ public function testOtherHolidays(): void } /** - * @throws ReflectionException + * @throws \ReflectionException * @throws \Exception */ public function testSources(): void diff --git a/tests/Spain/Ceuta/ceutaDayTest.php b/tests/Spain/Ceuta/ceutaDayTest.php index f02c89d76..5d9a3517c 100644 --- a/tests/Spain/Ceuta/ceutaDayTest.php +++ b/tests/Spain/Ceuta/ceutaDayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Spain\Ceuta; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -38,7 +35,7 @@ class ceutaDayTest extends CeutaBaseTestCase implements HolidayTestCase /** * Tests the holiday defined in this test on or after establishment. * - * @throws Exception + * @throws \Exception */ public function testHolidayOnAfterEstablishment(): void { @@ -47,14 +44,14 @@ public function testHolidayOnAfterEstablishment(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-9-2", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-9-2", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests the holiday defined in this test before establishment. * - * @throws Exception + * @throws \Exception */ public function testHolidayBeforeEstablishment(): void { @@ -68,7 +65,7 @@ public function testHolidayBeforeEstablishment(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -83,7 +80,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Spain/ChristmasTest.php b/tests/Spain/ChristmasTest.php index 49f0bd685..e30d0cbac 100644 --- a/tests/Spain/ChristmasTest.php +++ b/tests/Spain/ChristmasTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\Spain; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,8 +32,8 @@ class ChristmasTest extends SpainBaseTestCase implements HolidayTestCase * * @dataProvider HolidayDataProvider * - * @param int $year the year for which the holiday defined in this test needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which the holiday defined in this test needs to be tested + * @param \DateTime $expected the expected date */ public function testHoliday(int $year, \DateTimeInterface $expected): void { @@ -47,7 +45,7 @@ public function testHoliday(int $year, \DateTimeInterface $expected): void * * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function HolidayDataProvider(): array { @@ -57,7 +55,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -72,7 +70,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Spain/CommunityOfMadrid/CommunityOfMadridTest.php b/tests/Spain/CommunityOfMadrid/CommunityOfMadridTest.php index f246a0fff..2bab62e5e 100644 --- a/tests/Spain/CommunityOfMadrid/CommunityOfMadridTest.php +++ b/tests/Spain/CommunityOfMadrid/CommunityOfMadridTest.php @@ -14,7 +14,6 @@ namespace Yasumi\tests\Spain\CommunityOfMadrid; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\ProviderTestCase; @@ -96,7 +95,7 @@ public function testOtherHolidays(): void } /** - * @throws ReflectionException + * @throws \ReflectionException * @throws \Exception */ public function testSources(): void diff --git a/tests/Spain/CommunityOfMadrid/DosdeMayoUprisingDayTest.php b/tests/Spain/CommunityOfMadrid/DosdeMayoUprisingDayTest.php index 1fbb84d8f..03092bdf5 100644 --- a/tests/Spain/CommunityOfMadrid/DosdeMayoUprisingDayTest.php +++ b/tests/Spain/CommunityOfMadrid/DosdeMayoUprisingDayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Spain\CommunityOfMadrid; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -33,7 +30,7 @@ class DosdeMayoUprisingDayTest extends CommunityOfMadridBaseTestCase implements /** * Tests the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHoliday(): void { @@ -42,14 +39,14 @@ public function testHoliday(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-5-2", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-5-2", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -64,7 +61,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Spain/ConstitutionDayTest.php b/tests/Spain/ConstitutionDayTest.php index 224a8073a..80e22a405 100644 --- a/tests/Spain/ConstitutionDayTest.php +++ b/tests/Spain/ConstitutionDayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Spain; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -38,7 +35,7 @@ class ConstitutionDayTest extends SpainBaseTestCase implements HolidayTestCase /** * Tests the holiday defined in this test on or after establishment. * - * @throws Exception + * @throws \Exception */ public function testHolidayOnAfterEstablishment(): void { @@ -47,14 +44,14 @@ public function testHolidayOnAfterEstablishment(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-12-6", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-12-6", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests the holiday defined in this test before establishment. * - * @throws Exception + * @throws \Exception */ public function testHolidayBeforeEstablishment(): void { @@ -68,7 +65,7 @@ public function testHolidayBeforeEstablishment(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -83,7 +80,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Spain/EasterMondayTest.php b/tests/Spain/EasterMondayTest.php index bd6e8dc07..d7efe5f66 100644 --- a/tests/Spain/EasterMondayTest.php +++ b/tests/Spain/EasterMondayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Spain; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -39,7 +36,7 @@ class EasterMondayTest extends SpainBaseTestCase implements HolidayTestCase /** * Tests the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHoliday(): void { @@ -48,14 +45,14 @@ public function testHoliday(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-4-8", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-4-8", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -70,7 +67,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Spain/EpiphanyTest.php b/tests/Spain/EpiphanyTest.php index 6598de1fb..63154f4f9 100644 --- a/tests/Spain/EpiphanyTest.php +++ b/tests/Spain/EpiphanyTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\Spain; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,8 +32,8 @@ class EpiphanyTest extends SpainBaseTestCase implements HolidayTestCase * * @dataProvider HolidayDataProvider * - * @param int $year the year for which the holiday defined in this test needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which the holiday defined in this test needs to be tested + * @param \DateTime $expected the expected date */ public function testHoliday(int $year, \DateTimeInterface $expected): void { @@ -47,7 +45,7 @@ public function testHoliday(int $year, \DateTimeInterface $expected): void * * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function HolidayDataProvider(): array { @@ -57,7 +55,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -72,7 +70,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Spain/Extremadura/ExtremaduraDayTest.php b/tests/Spain/Extremadura/ExtremaduraDayTest.php index 3bd8f3525..5a3d06923 100644 --- a/tests/Spain/Extremadura/ExtremaduraDayTest.php +++ b/tests/Spain/Extremadura/ExtremaduraDayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Spain\Extremadura; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -38,7 +35,7 @@ class ExtremaduraDayTest extends ExtremaduraBaseTestCase implements HolidayTestC /** * Tests the holiday defined in this test on or after establishment. * - * @throws Exception + * @throws \Exception */ public function testHolidayOnAfterEstablishment(): void { @@ -47,14 +44,14 @@ public function testHolidayOnAfterEstablishment(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-9-8", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-9-8", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests the holiday defined in this test before establishment. * - * @throws Exception + * @throws \Exception */ public function testHolidayBeforeEstablishment(): void { @@ -68,7 +65,7 @@ public function testHolidayBeforeEstablishment(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -83,7 +80,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Spain/Extremadura/ExtremaduraTest.php b/tests/Spain/Extremadura/ExtremaduraTest.php index 494e93749..6959dc027 100644 --- a/tests/Spain/Extremadura/ExtremaduraTest.php +++ b/tests/Spain/Extremadura/ExtremaduraTest.php @@ -14,7 +14,6 @@ namespace Yasumi\tests\Spain\Extremadura; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\ProviderTestCase; @@ -94,7 +93,7 @@ public function testOtherHolidays(): void } /** - * @throws ReflectionException + * @throws \ReflectionException * @throws \Exception */ public function testSources(): void diff --git a/tests/Spain/Galicia/GaliciaTest.php b/tests/Spain/Galicia/GaliciaTest.php index 45113848e..c30df586d 100644 --- a/tests/Spain/Galicia/GaliciaTest.php +++ b/tests/Spain/Galicia/GaliciaTest.php @@ -14,7 +14,6 @@ namespace Yasumi\tests\Spain\Galicia; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\ProviderTestCase; @@ -96,7 +95,7 @@ public function testOtherHolidays(): void } /** - * @throws ReflectionException + * @throws \ReflectionException * @throws \Exception */ public function testSources(): void diff --git a/tests/Spain/Galicia/GalicianLiteratureDayTest.php b/tests/Spain/Galicia/GalicianLiteratureDayTest.php index f35fe8364..dec2ec24b 100644 --- a/tests/Spain/Galicia/GalicianLiteratureDayTest.php +++ b/tests/Spain/Galicia/GalicianLiteratureDayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Spain\Galicia; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -38,7 +35,7 @@ class GalicianLiteratureDayTest extends GaliciaBaseTestCase implements HolidayTe /** * Tests the holiday defined in this test on or after establishment. * - * @throws Exception + * @throws \Exception */ public function testHolidayOnAfterEstablishment(): void { @@ -47,14 +44,14 @@ public function testHolidayOnAfterEstablishment(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-5-17", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-5-17", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests the holiday defined in this test before establishment. * - * @throws Exception + * @throws \Exception */ public function testHolidayBeforeEstablishment(): void { @@ -68,7 +65,7 @@ public function testHolidayBeforeEstablishment(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -83,7 +80,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Spain/Galicia/stJamesDayTest.php b/tests/Spain/Galicia/stJamesDayTest.php index 3b753e87d..f0a92d89a 100644 --- a/tests/Spain/Galicia/stJamesDayTest.php +++ b/tests/Spain/Galicia/stJamesDayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Spain\Galicia; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -38,7 +35,7 @@ class stJamesDayTest extends GaliciaBaseTestCase implements HolidayTestCase /** * Tests the holiday defined in this test on or after establishment. * - * @throws Exception + * @throws \Exception */ public function testHolidayOnAfterEstablishment(): void { @@ -47,14 +44,14 @@ public function testHolidayOnAfterEstablishment(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-7-25", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-7-25", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests the holiday defined in this test before establishment. * - * @throws Exception + * @throws \Exception */ public function testHolidayBeforeEstablishment(): void { @@ -68,7 +65,7 @@ public function testHolidayBeforeEstablishment(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -83,7 +80,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Spain/GoodFridayTest.php b/tests/Spain/GoodFridayTest.php index 061b6adb0..9586050f5 100644 --- a/tests/Spain/GoodFridayTest.php +++ b/tests/Spain/GoodFridayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Spain; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -33,7 +30,7 @@ class GoodFridayTest extends SpainBaseTestCase implements HolidayTestCase /** * Tests the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHoliday(): void { @@ -42,14 +39,14 @@ public function testHoliday(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-4-9", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-4-9", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -64,7 +61,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Spain/ImmaculateConceptionTest.php b/tests/Spain/ImmaculateConceptionTest.php index 5c0d81a12..3c46aca72 100644 --- a/tests/Spain/ImmaculateConceptionTest.php +++ b/tests/Spain/ImmaculateConceptionTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\Spain; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,8 +32,8 @@ class ImmaculateConceptionTest extends SpainBaseTestCase implements HolidayTestC * * @dataProvider HolidayDataProvider * - * @param int $year the year for which the holiday defined in this test needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which the holiday defined in this test needs to be tested + * @param \DateTime $expected the expected date */ public function testHoliday(int $year, \DateTimeInterface $expected): void { @@ -47,7 +45,7 @@ public function testHoliday(int $year, \DateTimeInterface $expected): void * * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function HolidayDataProvider(): array { @@ -57,7 +55,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -72,7 +70,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Spain/InternationalWorkersDayTest.php b/tests/Spain/InternationalWorkersDayTest.php index 4c7085a18..53b4fd038 100644 --- a/tests/Spain/InternationalWorkersDayTest.php +++ b/tests/Spain/InternationalWorkersDayTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\Spain; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,8 +32,8 @@ class InternationalWorkersDayTest extends SpainBaseTestCase implements HolidayTe * * @dataProvider HolidayDataProvider * - * @param int $year the year for which the holiday defined in this test needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which the holiday defined in this test needs to be tested + * @param \DateTime $expected the expected date */ public function testHoliday(int $year, \DateTimeInterface $expected): void { @@ -47,7 +45,7 @@ public function testHoliday(int $year, \DateTimeInterface $expected): void * * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function HolidayDataProvider(): array { @@ -57,7 +55,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -72,7 +70,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Spain/LaRioja/LaRiojaDayTest.php b/tests/Spain/LaRioja/LaRiojaDayTest.php index aec5ff065..af5ce8268 100644 --- a/tests/Spain/LaRioja/LaRiojaDayTest.php +++ b/tests/Spain/LaRioja/LaRiojaDayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Spain\LaRioja; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -38,7 +35,7 @@ class LaRiojaDayTest extends LaRiojaBaseTestCase implements HolidayTestCase /** * Tests the holiday defined in this test on or after establishment. * - * @throws Exception + * @throws \Exception */ public function testHolidayOnAfterEstablishment(): void { @@ -47,14 +44,14 @@ public function testHolidayOnAfterEstablishment(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-6-9", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-6-9", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests the holiday defined in this test before establishment. * - * @throws Exception + * @throws \Exception */ public function testHolidayBeforeEstablishment(): void { @@ -68,7 +65,7 @@ public function testHolidayBeforeEstablishment(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -83,7 +80,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Spain/LaRioja/LaRiojaTest.php b/tests/Spain/LaRioja/LaRiojaTest.php index a58849595..67d5778a7 100644 --- a/tests/Spain/LaRioja/LaRiojaTest.php +++ b/tests/Spain/LaRioja/LaRiojaTest.php @@ -14,7 +14,6 @@ namespace Yasumi\tests\Spain\LaRioja; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\ProviderTestCase; @@ -94,7 +93,7 @@ public function testOtherHolidays(): void } /** - * @throws ReflectionException + * @throws \ReflectionException * @throws \Exception */ public function testSources(): void diff --git a/tests/Spain/MaundyThursdayTest.php b/tests/Spain/MaundyThursdayTest.php index 50c17e007..dce2ad2b4 100644 --- a/tests/Spain/MaundyThursdayTest.php +++ b/tests/Spain/MaundyThursdayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Spain; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -39,7 +36,7 @@ class MaundyThursdayTest extends SpainBaseTestCase implements HolidayTestCase /** * Tests the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHoliday(): void { @@ -48,14 +45,14 @@ public function testHoliday(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-4-7", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-4-7", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -70,7 +67,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Spain/Melilla/MelillaTest.php b/tests/Spain/Melilla/MelillaTest.php index ff0b17475..bc067cc17 100644 --- a/tests/Spain/Melilla/MelillaTest.php +++ b/tests/Spain/Melilla/MelillaTest.php @@ -14,7 +14,6 @@ namespace Yasumi\tests\Spain\Melilla; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\ProviderTestCase; @@ -94,7 +93,7 @@ public function testOtherHolidays(): void } /** - * @throws ReflectionException + * @throws \ReflectionException * @throws \Exception */ public function testSources(): void diff --git a/tests/Spain/NationalDayTest.php b/tests/Spain/NationalDayTest.php index a466e23a5..bdac3cc39 100644 --- a/tests/Spain/NationalDayTest.php +++ b/tests/Spain/NationalDayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Spain; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -38,7 +35,7 @@ class NationalDayTest extends SpainBaseTestCase implements HolidayTestCase /** * Tests the holiday defined in this test on or after establishment. * - * @throws Exception + * @throws \Exception */ public function testHolidayOnAfterEstablishment(): void { @@ -47,14 +44,14 @@ public function testHolidayOnAfterEstablishment(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-10-12", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-10-12", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests the holiday defined in this test before establishment. * - * @throws Exception + * @throws \Exception */ public function testHolidayBeforeEstablishment(): void { @@ -68,7 +65,7 @@ public function testHolidayBeforeEstablishment(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -83,7 +80,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Spain/Navarre/NavarreTest.php b/tests/Spain/Navarre/NavarreTest.php index 980e7634b..f59a86785 100644 --- a/tests/Spain/Navarre/NavarreTest.php +++ b/tests/Spain/Navarre/NavarreTest.php @@ -14,7 +14,6 @@ namespace Yasumi\tests\Spain\Navarre; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\ProviderTestCase; @@ -95,7 +94,7 @@ public function testOtherHolidays(): void } /** - * @throws ReflectionException + * @throws \ReflectionException * @throws \Exception */ public function testSources(): void diff --git a/tests/Spain/NewYearsDayTest.php b/tests/Spain/NewYearsDayTest.php index 8cd03eca2..9bf630264 100644 --- a/tests/Spain/NewYearsDayTest.php +++ b/tests/Spain/NewYearsDayTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\Spain; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,8 +32,8 @@ class NewYearsDayTest extends SpainBaseTestCase implements HolidayTestCase * * @dataProvider HolidayDataProvider * - * @param int $year the year for which the holiday defined in this test needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which the holiday defined in this test needs to be tested + * @param \DateTime $expected the expected date */ public function testHoliday(int $year, \DateTimeInterface $expected): void { @@ -47,7 +45,7 @@ public function testHoliday(int $year, \DateTimeInterface $expected): void * * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function HolidayDataProvider(): array { @@ -57,7 +55,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -72,7 +70,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Spain/RegionOfMurcia/RegionOfMurciaDayTest.php b/tests/Spain/RegionOfMurcia/RegionOfMurciaDayTest.php index a6e57311e..4758b384e 100644 --- a/tests/Spain/RegionOfMurcia/RegionOfMurciaDayTest.php +++ b/tests/Spain/RegionOfMurcia/RegionOfMurciaDayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Spain\RegionOfMurcia; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -38,7 +35,7 @@ class RegionOfMurciaDayTest extends RegionOfMurciaBaseTestCase implements Holida /** * Tests the holiday defined in this test on or after establishment. * - * @throws Exception + * @throws \Exception */ public function testHolidayOnAfterEstablishment(): void { @@ -47,14 +44,14 @@ public function testHolidayOnAfterEstablishment(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-6-9", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-6-9", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests the holiday defined in this test before establishment. * - * @throws Exception + * @throws \Exception */ public function testHolidayBeforeEstablishment(): void { @@ -68,7 +65,7 @@ public function testHolidayBeforeEstablishment(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -83,7 +80,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Spain/RegionOfMurcia/RegionOfMurciaTest.php b/tests/Spain/RegionOfMurcia/RegionOfMurciaTest.php index 8e0d5a411..6d59af7b4 100644 --- a/tests/Spain/RegionOfMurcia/RegionOfMurciaTest.php +++ b/tests/Spain/RegionOfMurcia/RegionOfMurciaTest.php @@ -14,7 +14,6 @@ namespace Yasumi\tests\Spain\RegionOfMurcia; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\ProviderTestCase; @@ -95,7 +94,7 @@ public function testOtherHolidays(): void } /** - * @throws ReflectionException + * @throws \ReflectionException * @throws \Exception */ public function testSources(): void diff --git a/tests/Spain/SpainTest.php b/tests/Spain/SpainTest.php index 891e184a2..8791f3667 100644 --- a/tests/Spain/SpainTest.php +++ b/tests/Spain/SpainTest.php @@ -14,7 +14,6 @@ namespace Yasumi\tests\Spain; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\ProviderTestCase; @@ -90,7 +89,7 @@ public function testOtherHolidays(): void } /** - * @throws ReflectionException + * @throws \ReflectionException * @throws \Exception */ public function testSources(): void diff --git a/tests/Spain/ValencianCommunity/ValencianCommunityDayTest.php b/tests/Spain/ValencianCommunity/ValencianCommunityDayTest.php index d5207e89c..3bf6c0f3d 100644 --- a/tests/Spain/ValencianCommunity/ValencianCommunityDayTest.php +++ b/tests/Spain/ValencianCommunity/ValencianCommunityDayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Spain\ValencianCommunity; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -38,7 +35,7 @@ class ValencianCommunityDayTest extends ValencianCommunityBaseTestCase implement /** * Tests the holiday defined in this test on or after establishment. * - * @throws Exception + * @throws \Exception */ public function testHolidayOnAfterEstablishment(): void { @@ -47,14 +44,14 @@ public function testHolidayOnAfterEstablishment(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-10-9", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-10-9", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests the holiday defined in this test before establishment. * - * @throws Exception + * @throws \Exception */ public function testHolidayBeforeEstablishment(): void { @@ -68,7 +65,7 @@ public function testHolidayBeforeEstablishment(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -83,7 +80,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Spain/ValencianCommunity/ValencianCommunityTest.php b/tests/Spain/ValencianCommunity/ValencianCommunityTest.php index d284ca657..4393c8d99 100644 --- a/tests/Spain/ValencianCommunity/ValencianCommunityTest.php +++ b/tests/Spain/ValencianCommunity/ValencianCommunityTest.php @@ -14,7 +14,6 @@ namespace Yasumi\tests\Spain\ValencianCommunity; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\ProviderTestCase; @@ -95,7 +94,7 @@ public function testOtherHolidays(): void } /** - * @throws ReflectionException + * @throws \ReflectionException * @throws \Exception */ public function testSources(): void diff --git a/tests/Spain/ValentinesDayTest.php b/tests/Spain/ValentinesDayTest.php index 4f70db12d..1e6270c8c 100644 --- a/tests/Spain/ValentinesDayTest.php +++ b/tests/Spain/ValentinesDayTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\Spain; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,8 +32,8 @@ class ValentinesDayTest extends SpainBaseTestCase implements HolidayTestCase * * @dataProvider HolidayDataProvider * - * @param int $year the year for which the holiday defined in this test needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which the holiday defined in this test needs to be tested + * @param \DateTime $expected the expected date */ public function testHoliday(int $year, \DateTimeInterface $expected): void { @@ -47,7 +45,7 @@ public function testHoliday(int $year, \DateTimeInterface $expected): void * * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function HolidayDataProvider(): array { @@ -57,7 +55,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -72,7 +70,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Spain/stJosephsDayTest.php b/tests/Spain/stJosephsDayTest.php index dba1418ac..3acaf6c72 100644 --- a/tests/Spain/stJosephsDayTest.php +++ b/tests/Spain/stJosephsDayTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\Spain; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -40,8 +38,8 @@ class stJosephsDayTest extends SpainBaseTestCase implements HolidayTestCase * * @dataProvider HolidayDataProvider * - * @param int $year the year for which the holiday defined in this test needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which the holiday defined in this test needs to be tested + * @param \DateTime $expected the expected date */ public function testHoliday(int $year, \DateTimeInterface $expected): void { @@ -53,7 +51,7 @@ public function testHoliday(int $year, \DateTimeInterface $expected): void * * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function HolidayDataProvider(): array { @@ -63,7 +61,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -78,7 +76,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Sweden/AllSaintsDayTest.php b/tests/Sweden/AllSaintsDayTest.php index 6ade5fa87..b04419fa3 100644 --- a/tests/Sweden/AllSaintsDayTest.php +++ b/tests/Sweden/AllSaintsDayTest.php @@ -14,10 +14,6 @@ namespace Yasumi\tests\Sweden; -use DateInterval; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -36,8 +32,8 @@ class AllSaintsDayTest extends SwedenBaseTestCase implements HolidayTestCase * * @dataProvider HolidayDataProvider * - * @param int $year the year for which the holiday defined in this test needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which the holiday defined in this test needs to be tested + * @param \DateTime $expected the expected date */ public function testHoliday(int $year, \DateTimeInterface $expected): void { @@ -49,7 +45,7 @@ public function testHoliday(int $year, \DateTimeInterface $expected): void * * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function HolidayDataProvider(): array { @@ -57,7 +53,7 @@ public function HolidayDataProvider(): array for ($y = 0; $y < 50; ++$y) { $year = $this->generateRandomYear(); - $date = new DateTime("$year-10-31", new DateTimeZone(self::TIMEZONE)); + $date = new \DateTime("$year-10-31", new \DateTimeZone(self::TIMEZONE)); // Check between 31 October and 6th of November the day that is a Saturday for ($d = 0; $d <= 7; ++$d) { @@ -65,7 +61,7 @@ public function HolidayDataProvider(): array $data[] = [$year, $date]; break; } - $date->add(new DateInterval('P1D')); + $date->add(new \DateInterval('P1D')); } } @@ -75,7 +71,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -90,7 +86,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Sweden/AllSaintsEveTest.php b/tests/Sweden/AllSaintsEveTest.php index 706451d14..36807a2d0 100644 --- a/tests/Sweden/AllSaintsEveTest.php +++ b/tests/Sweden/AllSaintsEveTest.php @@ -14,10 +14,6 @@ namespace Yasumi\tests\Sweden; -use DateInterval; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -36,8 +32,8 @@ class AllSaintsEveTest extends SwedenBaseTestCase implements HolidayTestCase * * @dataProvider HolidayDataProvider * - * @param int $year the year for which the holiday defined in this test needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which the holiday defined in this test needs to be tested + * @param \DateTime $expected the expected date */ public function testHoliday(int $year, \DateTimeInterface $expected): void { @@ -49,7 +45,7 @@ public function testHoliday(int $year, \DateTimeInterface $expected): void * * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function HolidayDataProvider(): array { @@ -57,7 +53,7 @@ public function HolidayDataProvider(): array for ($y = 0; $y < 50; ++$y) { $year = $this->generateRandomYear(); - $date = new DateTime("$year-10-30", new DateTimeZone(self::TIMEZONE)); + $date = new \DateTime("$year-10-30", new \DateTimeZone(self::TIMEZONE)); // Check between 30 October and 5th of November the day that is a Friday for ($d = 0; $d <= 7; ++$d) { @@ -65,7 +61,7 @@ public function HolidayDataProvider(): array $data[] = [$year, $date]; break; } - $date->add(new DateInterval('P1D')); + $date->add(new \DateInterval('P1D')); } } @@ -75,7 +71,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -90,7 +86,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Sweden/AscensionDayTest.php b/tests/Sweden/AscensionDayTest.php index 93a7bee3b..c753e0584 100644 --- a/tests/Sweden/AscensionDayTest.php +++ b/tests/Sweden/AscensionDayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Sweden; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -33,7 +30,7 @@ class AscensionDayTest extends SwedenBaseTestCase implements HolidayTestCase /** * Tests Ascension Day. * - * @throws Exception + * @throws \Exception */ public function testAscensionDay(): void { @@ -42,14 +39,14 @@ public function testAscensionDay(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-5-16", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-5-16", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests translated name of Ascension Day. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -64,7 +61,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Sweden/ChristmasDayTest.php b/tests/Sweden/ChristmasDayTest.php index 6e809a349..71765dca8 100644 --- a/tests/Sweden/ChristmasDayTest.php +++ b/tests/Sweden/ChristmasDayTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\Sweden; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,8 +32,8 @@ class ChristmasDayTest extends SwedenBaseTestCase implements HolidayTestCase * * @dataProvider HolidayDataProvider * - * @param int $year the year for which the holiday defined in this test needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which the holiday defined in this test needs to be tested + * @param \DateTime $expected the expected date */ public function testHoliday(int $year, \DateTimeInterface $expected): void { @@ -47,7 +45,7 @@ public function testHoliday(int $year, \DateTimeInterface $expected): void * * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function HolidayDataProvider(): array { @@ -57,7 +55,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -72,7 +70,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Sweden/ChristmasEveTest.php b/tests/Sweden/ChristmasEveTest.php index bda99a473..e6f1aa465 100644 --- a/tests/Sweden/ChristmasEveTest.php +++ b/tests/Sweden/ChristmasEveTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\Sweden; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,8 +32,8 @@ class ChristmasEveTest extends SwedenBaseTestCase implements HolidayTestCase * * @dataProvider HolidayDataProvider * - * @param int $year the year for which the holiday defined in this test needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which the holiday defined in this test needs to be tested + * @param \DateTime $expected the expected date */ public function testHoliday(int $year, \DateTimeInterface $expected): void { @@ -47,7 +45,7 @@ public function testHoliday(int $year, \DateTimeInterface $expected): void * * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function HolidayDataProvider(): array { @@ -57,7 +55,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -72,7 +70,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Sweden/EasterMondayTest.php b/tests/Sweden/EasterMondayTest.php index 01cf4fcd8..d612b5e8c 100644 --- a/tests/Sweden/EasterMondayTest.php +++ b/tests/Sweden/EasterMondayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Sweden; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -33,7 +30,7 @@ class EasterMondayTest extends SwedenBaseTestCase implements HolidayTestCase /** * Tests the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHoliday(): void { @@ -42,14 +39,14 @@ public function testHoliday(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-4-8", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-4-8", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -64,7 +61,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Sweden/EasterTest.php b/tests/Sweden/EasterTest.php index 4ac2ac7ce..7d6371786 100644 --- a/tests/Sweden/EasterTest.php +++ b/tests/Sweden/EasterTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Sweden; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -33,7 +30,7 @@ class EasterTest extends SwedenBaseTestCase implements HolidayTestCase /** * Tests the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHoliday(): void { @@ -42,14 +39,14 @@ public function testHoliday(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-4-4", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-4-4", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -64,7 +61,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Sweden/EpiphanyEveTest.php b/tests/Sweden/EpiphanyEveTest.php index b5b10fdd6..2739bc847 100644 --- a/tests/Sweden/EpiphanyEveTest.php +++ b/tests/Sweden/EpiphanyEveTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\Sweden; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,8 +32,8 @@ class EpiphanyEveTest extends SwedenBaseTestCase implements HolidayTestCase * * @dataProvider HolidayDataProvider * - * @param int $year the year for which the holiday defined in this test needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which the holiday defined in this test needs to be tested + * @param \DateTime $expected the expected date */ public function testHoliday(int $year, \DateTimeInterface $expected): void { @@ -47,7 +45,7 @@ public function testHoliday(int $year, \DateTimeInterface $expected): void * * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function HolidayDataProvider(): array { @@ -57,7 +55,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -72,7 +70,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Sweden/EpiphanyTest.php b/tests/Sweden/EpiphanyTest.php index 4432af1ad..2bbf28d54 100644 --- a/tests/Sweden/EpiphanyTest.php +++ b/tests/Sweden/EpiphanyTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\Sweden; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,8 +32,8 @@ class EpiphanyTest extends SwedenBaseTestCase implements HolidayTestCase * * @dataProvider HolidayDataProvider * - * @param int $year the year for which the holiday defined in this test needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which the holiday defined in this test needs to be tested + * @param \DateTime $expected the expected date */ public function testHoliday(int $year, \DateTimeInterface $expected): void { @@ -47,7 +45,7 @@ public function testHoliday(int $year, \DateTimeInterface $expected): void * * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function HolidayDataProvider(): array { @@ -57,7 +55,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -72,7 +70,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Sweden/GoodFridayTest.php b/tests/Sweden/GoodFridayTest.php index 29bb6c651..1a10e080f 100644 --- a/tests/Sweden/GoodFridayTest.php +++ b/tests/Sweden/GoodFridayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Sweden; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -33,7 +30,7 @@ class GoodFridayTest extends SwedenBaseTestCase implements HolidayTestCase /** * Tests the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHoliday(): void { @@ -42,14 +39,14 @@ public function testHoliday(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-3-25", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-3-25", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -64,7 +61,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Sweden/InternationalWorkersDayTest.php b/tests/Sweden/InternationalWorkersDayTest.php index f890e6e20..6cf0ad6fd 100644 --- a/tests/Sweden/InternationalWorkersDayTest.php +++ b/tests/Sweden/InternationalWorkersDayTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\Sweden; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,8 +32,8 @@ class InternationalWorkersDayTest extends SwedenBaseTestCase implements HolidayT * * @dataProvider InternationalWorkersDayDataProvider * - * @param int $year the year for which International Workers' Day needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which International Workers' Day needs to be tested + * @param \DateTime $expected the expected date */ public function testInternationalWorkersDay(int $year, \DateTimeInterface $expected): void { @@ -45,7 +43,7 @@ public function testInternationalWorkersDay(int $year, \DateTimeInterface $expec /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -60,7 +58,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { @@ -72,7 +70,7 @@ public function testHolidayType(): void * * @return array list of test dates for International Workers' Day * - * @throws Exception + * @throws \Exception */ public function InternationalWorkersDayDataProvider(): array { diff --git a/tests/Sweden/NationalDayTest.php b/tests/Sweden/NationalDayTest.php index 6be166472..797eb5f90 100644 --- a/tests/Sweden/NationalDayTest.php +++ b/tests/Sweden/NationalDayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Sweden; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -38,7 +35,7 @@ class NationalDayTest extends SwedenBaseTestCase implements HolidayTestCase /** * Tests the holiday defined in this test on or after establishment. * - * @throws Exception + * @throws \Exception */ public function testHolidayOnAfterEstablishment(): void { @@ -47,14 +44,14 @@ public function testHolidayOnAfterEstablishment(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-6-6", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-6-6", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests the holiday defined in this test before establishment. * - * @throws Exception + * @throws \Exception */ public function testHolidayBeforeEstablishment(): void { @@ -68,7 +65,7 @@ public function testHolidayBeforeEstablishment(): void /** * Tests the translated name of the holiday defined in this test on or after establishment. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -83,7 +80,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { @@ -98,7 +95,7 @@ public function testHolidayType(): void /** * Tests the translated name of the holiday defined in this test on or after establishment. * - * @throws Exception + * @throws \Exception */ public function testTranslationOnAfterNameChange(): void { diff --git a/tests/Sweden/NewYearsDayTest.php b/tests/Sweden/NewYearsDayTest.php index adec93cfa..5bd8a8a9c 100644 --- a/tests/Sweden/NewYearsDayTest.php +++ b/tests/Sweden/NewYearsDayTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\Sweden; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,8 +32,8 @@ class NewYearsDayTest extends SwedenBaseTestCase implements HolidayTestCase * * @dataProvider HolidayDataProvider * - * @param int $year the year for which the holiday defined in this test needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which the holiday defined in this test needs to be tested + * @param \DateTime $expected the expected date */ public function testHoliday(int $year, \DateTimeInterface $expected): void { @@ -47,7 +45,7 @@ public function testHoliday(int $year, \DateTimeInterface $expected): void * * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function HolidayDataProvider(): array { @@ -57,7 +55,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -72,7 +70,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Sweden/NewYearsEveTest.php b/tests/Sweden/NewYearsEveTest.php index aad3ab15d..b2c231b7c 100644 --- a/tests/Sweden/NewYearsEveTest.php +++ b/tests/Sweden/NewYearsEveTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\Sweden; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,8 +32,8 @@ class NewYearsEveTest extends SwedenBaseTestCase implements HolidayTestCase * * @dataProvider HolidayDataProvider * - * @param int $year the year for which the holiday defined in this test needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which the holiday defined in this test needs to be tested + * @param \DateTime $expected the expected date */ public function testHoliday(int $year, \DateTimeInterface $expected): void { @@ -47,7 +45,7 @@ public function testHoliday(int $year, \DateTimeInterface $expected): void * * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function HolidayDataProvider(): array { @@ -57,7 +55,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -72,7 +70,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Sweden/PentecostTest.php b/tests/Sweden/PentecostTest.php index bd8f13281..470253d44 100644 --- a/tests/Sweden/PentecostTest.php +++ b/tests/Sweden/PentecostTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Sweden; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -33,7 +30,7 @@ class PentecostTest extends SwedenBaseTestCase implements HolidayTestCase /** * Tests the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHoliday(): void { @@ -42,14 +39,14 @@ public function testHoliday(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-05-17", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-05-17", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -64,7 +61,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Sweden/SecondChristmasDayTest.php b/tests/Sweden/SecondChristmasDayTest.php index 18560239c..d26cb7102 100644 --- a/tests/Sweden/SecondChristmasDayTest.php +++ b/tests/Sweden/SecondChristmasDayTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\Sweden; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,8 +32,8 @@ class SecondChristmasDayTest extends SwedenBaseTestCase implements HolidayTestCa * * @dataProvider HolidayDataProvider * - * @param int $year the year for which the holiday defined in this test needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which the holiday defined in this test needs to be tested + * @param \DateTime $expected the expected date */ public function testHoliday(int $year, \DateTimeInterface $expected): void { @@ -47,7 +45,7 @@ public function testHoliday(int $year, \DateTimeInterface $expected): void * * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function HolidayDataProvider(): array { @@ -57,7 +55,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -72,7 +70,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Sweden/SwedenTest.php b/tests/Sweden/SwedenTest.php index bc688edaa..8de942718 100644 --- a/tests/Sweden/SwedenTest.php +++ b/tests/Sweden/SwedenTest.php @@ -14,7 +14,6 @@ namespace Yasumi\tests\Sweden; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\ProviderTestCase; @@ -100,7 +99,7 @@ public function testOtherHolidays(): void } /** - * @throws ReflectionException + * @throws \ReflectionException * @throws \Exception */ public function testSources(): void diff --git a/tests/Sweden/WalpurgisEveTest.php b/tests/Sweden/WalpurgisEveTest.php index b29b4ec80..50e5cb528 100644 --- a/tests/Sweden/WalpurgisEveTest.php +++ b/tests/Sweden/WalpurgisEveTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\Sweden; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,8 +32,8 @@ class WalpurgisEveTest extends SwedenBaseTestCase implements HolidayTestCase * * @dataProvider HolidayDataProvider * - * @param int $year the year for which the holiday defined in this test needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which the holiday defined in this test needs to be tested + * @param \DateTime $expected the expected date */ public function testHoliday(int $year, \DateTimeInterface $expected): void { @@ -47,7 +45,7 @@ public function testHoliday(int $year, \DateTimeInterface $expected): void * * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function HolidayDataProvider(): array { @@ -57,7 +55,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -72,7 +70,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Aargau/AargauTest.php b/tests/Switzerland/Aargau/AargauTest.php index e0bfab4b9..bd9236722 100644 --- a/tests/Switzerland/Aargau/AargauTest.php +++ b/tests/Switzerland/Aargau/AargauTest.php @@ -14,7 +14,6 @@ namespace Yasumi\tests\Switzerland\Aargau; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\ProviderTestCase; @@ -101,7 +100,7 @@ public function testOtherHolidays(): void } /** - * @throws ReflectionException + * @throws \ReflectionException * @throws \Exception */ public function testSources(): void diff --git a/tests/Switzerland/Aargau/AscensionDayTest.php b/tests/Switzerland/Aargau/AscensionDayTest.php index 552f92c76..5da94219f 100644 --- a/tests/Switzerland/Aargau/AscensionDayTest.php +++ b/tests/Switzerland/Aargau/AscensionDayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Switzerland\Aargau; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -33,7 +30,7 @@ class AscensionDayTest extends AargauBaseTestCase implements HolidayTestCase /** * Tests Ascension Day. * - * @throws Exception + * @throws \Exception */ public function testAscensionDay(): void { @@ -42,14 +39,14 @@ public function testAscensionDay(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-5-16", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-5-16", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests translated name of Ascension Day. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -64,7 +61,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Aargau/ChristmasDayTest.php b/tests/Switzerland/Aargau/ChristmasDayTest.php index b985c8642..47bc27557 100644 --- a/tests/Switzerland/Aargau/ChristmasDayTest.php +++ b/tests/Switzerland/Aargau/ChristmasDayTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\Switzerland\Aargau; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,8 +32,8 @@ class ChristmasDayTest extends AargauBaseTestCase implements HolidayTestCase * * @dataProvider ChristmasDayDataProvider * - * @param int $year the year for which Christmas Day needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which Christmas Day needs to be tested + * @param \DateTime $expected the expected date */ public function testChristmasDay(int $year, \DateTimeInterface $expected): void { @@ -47,7 +45,7 @@ public function testChristmasDay(int $year, \DateTimeInterface $expected): void * * @return array list of test dates for Christmas Day * - * @throws Exception + * @throws \Exception */ public function ChristmasDayDataProvider(): array { @@ -57,7 +55,7 @@ public function ChristmasDayDataProvider(): array /** * Tests translated name of Christmas Day. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -72,7 +70,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Aargau/GoodFridayTest.php b/tests/Switzerland/Aargau/GoodFridayTest.php index 405727beb..9d8b80ab7 100644 --- a/tests/Switzerland/Aargau/GoodFridayTest.php +++ b/tests/Switzerland/Aargau/GoodFridayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Switzerland\Aargau; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -33,7 +30,7 @@ class GoodFridayTest extends AargauBaseTestCase implements HolidayTestCase /** * Tests the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHoliday(): void { @@ -42,14 +39,14 @@ public function testHoliday(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-3-21", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-3-21", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -64,7 +61,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Aargau/NewYearsDayTest.php b/tests/Switzerland/Aargau/NewYearsDayTest.php index 3cb73a780..31f1d5bc2 100644 --- a/tests/Switzerland/Aargau/NewYearsDayTest.php +++ b/tests/Switzerland/Aargau/NewYearsDayTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\Switzerland\Aargau; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,8 +32,8 @@ class NewYearsDayTest extends AargauBaseTestCase implements HolidayTestCase * * @dataProvider NewYearsDayDataProvider * - * @param int $year the year for which New Years Day needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which New Years Day needs to be tested + * @param \DateTime $expected the expected date */ public function testNewYearsDay(int $year, \DateTimeInterface $expected): void { @@ -45,7 +43,7 @@ public function testNewYearsDay(int $year, \DateTimeInterface $expected): void /** * Tests translated name of New Years Day. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -60,7 +58,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { @@ -72,7 +70,7 @@ public function testHolidayType(): void * * @return array list of test dates for New Years Day * - * @throws Exception + * @throws \Exception */ public function NewYearsDayDataProvider(): array { diff --git a/tests/Switzerland/AppenzellAusserrhoden/AppenzellAusserrhodenTest.php b/tests/Switzerland/AppenzellAusserrhoden/AppenzellAusserrhodenTest.php index f556be1d9..9527a342c 100644 --- a/tests/Switzerland/AppenzellAusserrhoden/AppenzellAusserrhodenTest.php +++ b/tests/Switzerland/AppenzellAusserrhoden/AppenzellAusserrhodenTest.php @@ -14,7 +14,6 @@ namespace Yasumi\tests\Switzerland\AppenzellAusserrhoden; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\ProviderTestCase; @@ -104,7 +103,7 @@ public function testOtherHolidays(): void } /** - * @throws ReflectionException + * @throws \ReflectionException * @throws \Exception */ public function testSources(): void diff --git a/tests/Switzerland/AppenzellAusserrhoden/AscensionDayTest.php b/tests/Switzerland/AppenzellAusserrhoden/AscensionDayTest.php index c18542a83..e8c029692 100644 --- a/tests/Switzerland/AppenzellAusserrhoden/AscensionDayTest.php +++ b/tests/Switzerland/AppenzellAusserrhoden/AscensionDayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Switzerland\AppenzellAusserrhoden; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -33,7 +30,7 @@ class AscensionDayTest extends AppenzellAusserrhodenBaseTestCase implements Holi /** * Tests Ascension Day. * - * @throws Exception + * @throws \Exception */ public function testAscensionDay(): void { @@ -42,14 +39,14 @@ public function testAscensionDay(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-5-16", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-5-16", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests translated name of Ascension Day. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -64,7 +61,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/AppenzellAusserrhoden/ChristmasDayTest.php b/tests/Switzerland/AppenzellAusserrhoden/ChristmasDayTest.php index d9eae80a0..bb3e29303 100644 --- a/tests/Switzerland/AppenzellAusserrhoden/ChristmasDayTest.php +++ b/tests/Switzerland/AppenzellAusserrhoden/ChristmasDayTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\Switzerland\AppenzellAusserrhoden; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,8 +32,8 @@ class ChristmasDayTest extends AppenzellAusserrhodenBaseTestCase implements Holi * * @dataProvider ChristmasDayDataProvider * - * @param int $year the year for which Christmas Day needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which Christmas Day needs to be tested + * @param \DateTime $expected the expected date */ public function testChristmasDay(int $year, \DateTimeInterface $expected): void { @@ -47,7 +45,7 @@ public function testChristmasDay(int $year, \DateTimeInterface $expected): void * * @return array list of test dates for Christmas Day * - * @throws Exception + * @throws \Exception */ public function ChristmasDayDataProvider(): array { @@ -57,7 +55,7 @@ public function ChristmasDayDataProvider(): array /** * Tests translated name of Christmas Day. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -72,7 +70,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/AppenzellAusserrhoden/EasterMondayTest.php b/tests/Switzerland/AppenzellAusserrhoden/EasterMondayTest.php index 5e53dc321..3943ae77f 100644 --- a/tests/Switzerland/AppenzellAusserrhoden/EasterMondayTest.php +++ b/tests/Switzerland/AppenzellAusserrhoden/EasterMondayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Switzerland\AppenzellAusserrhoden; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -33,7 +30,7 @@ class EasterMondayTest extends AppenzellAusserrhodenBaseTestCase implements Holi /** * Tests Easter Monday. * - * @throws Exception + * @throws \Exception */ public function testEasterMonday(): void { @@ -42,14 +39,14 @@ public function testEasterMonday(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-3-28", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-3-28", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests translated name of Easter Monday. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -64,7 +61,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/AppenzellAusserrhoden/GoodFridayTest.php b/tests/Switzerland/AppenzellAusserrhoden/GoodFridayTest.php index 46cecf959..54f12ada9 100644 --- a/tests/Switzerland/AppenzellAusserrhoden/GoodFridayTest.php +++ b/tests/Switzerland/AppenzellAusserrhoden/GoodFridayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Switzerland\AppenzellAusserrhoden; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -33,7 +30,7 @@ class GoodFridayTest extends AppenzellAusserrhodenBaseTestCase implements Holida /** * Tests the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHoliday(): void { @@ -42,14 +39,14 @@ public function testHoliday(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-3-21", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-3-21", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -64,7 +61,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/AppenzellAusserrhoden/NewYearsDayTest.php b/tests/Switzerland/AppenzellAusserrhoden/NewYearsDayTest.php index 0b522d6f0..c241a657f 100644 --- a/tests/Switzerland/AppenzellAusserrhoden/NewYearsDayTest.php +++ b/tests/Switzerland/AppenzellAusserrhoden/NewYearsDayTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\Switzerland\AppenzellAusserrhoden; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,8 +32,8 @@ class NewYearsDayTest extends AppenzellAusserrhodenBaseTestCase implements Holid * * @dataProvider NewYearsDayDataProvider * - * @param int $year the year for which New Years Day needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which New Years Day needs to be tested + * @param \DateTime $expected the expected date */ public function testNewYearsDay(int $year, \DateTimeInterface $expected): void { @@ -45,7 +43,7 @@ public function testNewYearsDay(int $year, \DateTimeInterface $expected): void /** * Tests translated name of New Years Day. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -60,7 +58,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { @@ -72,7 +70,7 @@ public function testHolidayType(): void * * @return array list of test dates for New Years Day * - * @throws Exception + * @throws \Exception */ public function NewYearsDayDataProvider(): array { diff --git a/tests/Switzerland/AppenzellAusserrhoden/PentecostMondayTest.php b/tests/Switzerland/AppenzellAusserrhoden/PentecostMondayTest.php index 911f20286..4b9cf016e 100644 --- a/tests/Switzerland/AppenzellAusserrhoden/PentecostMondayTest.php +++ b/tests/Switzerland/AppenzellAusserrhoden/PentecostMondayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Switzerland\AppenzellAusserrhoden; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -33,7 +30,7 @@ class PentecostMondayTest extends AppenzellAusserrhodenBaseTestCase implements H /** * Tests Pentecost Monday. * - * @throws Exception + * @throws \Exception */ public function testPentecostMonday(): void { @@ -42,14 +39,14 @@ public function testPentecostMonday(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-5-30", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-5-30", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests translated name of Pentecost Monday. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -64,7 +61,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/AppenzellAusserrhoden/StStephensDayTest.php b/tests/Switzerland/AppenzellAusserrhoden/StStephensDayTest.php index 2e71b6fc9..9f07b380d 100644 --- a/tests/Switzerland/AppenzellAusserrhoden/StStephensDayTest.php +++ b/tests/Switzerland/AppenzellAusserrhoden/StStephensDayTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\Switzerland\AppenzellAusserrhoden; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,8 +32,8 @@ class StStephensDayTest extends AppenzellAusserrhodenBaseTestCase implements Hol * * @dataProvider HolidayDataProvider * - * @param int $year the year for which the holiday defined in this test needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which the holiday defined in this test needs to be tested + * @param \DateTime $expected the expected date */ public function testHoliday(int $year, \DateTimeInterface $expected): void { @@ -47,7 +45,7 @@ public function testHoliday(int $year, \DateTimeInterface $expected): void * * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function HolidayDataProvider(): array { @@ -57,7 +55,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -72,7 +70,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/AppenzellInnerrhoden/AllSaintsDayTest.php b/tests/Switzerland/AppenzellInnerrhoden/AllSaintsDayTest.php index e32fa7979..6e0ef111a 100644 --- a/tests/Switzerland/AppenzellInnerrhoden/AllSaintsDayTest.php +++ b/tests/Switzerland/AppenzellInnerrhoden/AllSaintsDayTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\Switzerland\AppenzellInnerrhoden; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,8 +32,8 @@ class AllSaintsDayTest extends AppenzellInnerrhodenBaseTestCase implements Holid * * @dataProvider AllSaintsDayDataProvider * - * @param int $year the year for which All Saints' Day needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which All Saints' Day needs to be tested + * @param \DateTime $expected the expected date */ public function testAllSaintsDay(int $year, \DateTimeInterface $expected): void { @@ -45,7 +43,7 @@ public function testAllSaintsDay(int $year, \DateTimeInterface $expected): void /** * Tests translated name of All Saints' Day. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -60,7 +58,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { @@ -72,7 +70,7 @@ public function testHolidayType(): void * * @return array list of test dates for All Saints' Day * - * @throws Exception + * @throws \Exception */ public function AllSaintsDayDataProvider(): array { diff --git a/tests/Switzerland/AppenzellInnerrhoden/AppenzellInnerrhodenTest.php b/tests/Switzerland/AppenzellInnerrhoden/AppenzellInnerrhodenTest.php index b56fb97b3..9143e4893 100644 --- a/tests/Switzerland/AppenzellInnerrhoden/AppenzellInnerrhodenTest.php +++ b/tests/Switzerland/AppenzellInnerrhoden/AppenzellInnerrhodenTest.php @@ -14,7 +14,6 @@ namespace Yasumi\tests\Switzerland\AppenzellInnerrhoden; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\ProviderTestCase; @@ -108,7 +107,7 @@ public function testOtherHolidays(): void } /** - * @throws ReflectionException + * @throws \ReflectionException * @throws \Exception */ public function testSources(): void diff --git a/tests/Switzerland/AppenzellInnerrhoden/AscensionDayTest.php b/tests/Switzerland/AppenzellInnerrhoden/AscensionDayTest.php index b092728ba..fc47c4f07 100644 --- a/tests/Switzerland/AppenzellInnerrhoden/AscensionDayTest.php +++ b/tests/Switzerland/AppenzellInnerrhoden/AscensionDayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Switzerland\AppenzellInnerrhoden; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -33,7 +30,7 @@ class AscensionDayTest extends AppenzellInnerrhodenBaseTestCase implements Holid /** * Tests Ascension Day. * - * @throws Exception + * @throws \Exception */ public function testAscensionDay(): void { @@ -42,14 +39,14 @@ public function testAscensionDay(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-5-16", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-5-16", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests translated name of Ascension Day. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -64,7 +61,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/AppenzellInnerrhoden/AssumptionOfMaryTest.php b/tests/Switzerland/AppenzellInnerrhoden/AssumptionOfMaryTest.php index 681b213da..c32b13e85 100644 --- a/tests/Switzerland/AppenzellInnerrhoden/AssumptionOfMaryTest.php +++ b/tests/Switzerland/AppenzellInnerrhoden/AssumptionOfMaryTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\Switzerland\AppenzellInnerrhoden; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,8 +32,8 @@ class AssumptionOfMaryTest extends AppenzellInnerrhodenBaseTestCase implements H * * @dataProvider AssumptionOfMaryDataProvider * - * @param int $year the year for which the day of the Assumption of Mary needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which the day of the Assumption of Mary needs to be tested + * @param \DateTime $expected the expected date */ public function testAssumptionOfMary(int $year, \DateTimeInterface $expected): void { @@ -45,7 +43,7 @@ public function testAssumptionOfMary(int $year, \DateTimeInterface $expected): v /** * Tests translated name of the day of the Assumption of Mary. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -60,7 +58,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { @@ -72,7 +70,7 @@ public function testHolidayType(): void * * @return array list of test dates for the day of the Assumption of Mary * - * @throws Exception + * @throws \Exception */ public function AssumptionOfMaryDataProvider(): array { diff --git a/tests/Switzerland/AppenzellInnerrhoden/ChristmasDayTest.php b/tests/Switzerland/AppenzellInnerrhoden/ChristmasDayTest.php index 913bed476..575524f85 100644 --- a/tests/Switzerland/AppenzellInnerrhoden/ChristmasDayTest.php +++ b/tests/Switzerland/AppenzellInnerrhoden/ChristmasDayTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\Switzerland\AppenzellInnerrhoden; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,8 +32,8 @@ class ChristmasDayTest extends AppenzellInnerrhodenBaseTestCase implements Holid * * @dataProvider ChristmasDayDataProvider * - * @param int $year the year for which Christmas Day needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which Christmas Day needs to be tested + * @param \DateTime $expected the expected date */ public function testChristmasDay(int $year, \DateTimeInterface $expected): void { @@ -47,7 +45,7 @@ public function testChristmasDay(int $year, \DateTimeInterface $expected): void * * @return array list of test dates for Christmas Day * - * @throws Exception + * @throws \Exception */ public function ChristmasDayDataProvider(): array { @@ -57,7 +55,7 @@ public function ChristmasDayDataProvider(): array /** * Tests translated name of Christmas Day. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -72,7 +70,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/AppenzellInnerrhoden/CorpusChristiTest.php b/tests/Switzerland/AppenzellInnerrhoden/CorpusChristiTest.php index 5e1f4290c..254cbef8c 100644 --- a/tests/Switzerland/AppenzellInnerrhoden/CorpusChristiTest.php +++ b/tests/Switzerland/AppenzellInnerrhoden/CorpusChristiTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\Switzerland\AppenzellInnerrhoden; -use DateInterval; -use Exception; use Yasumi\Holiday; use Yasumi\Provider\ChristianHolidays; use Yasumi\tests\HolidayTestCase; @@ -35,7 +33,7 @@ class CorpusChristiTest extends AppenzellInnerrhodenBaseTestCase implements Holi /** * Tests Corpus Christi. * - * @throws Exception + * @throws \Exception */ public function testCorpusChristi(): void { @@ -44,14 +42,14 @@ public function testCorpusChristi(): void self::REGION, self::HOLIDAY, $year, - $this->calculateEaster($year, self::TIMEZONE)->add(new DateInterval('P60D')) + $this->calculateEaster($year, self::TIMEZONE)->add(new \DateInterval('P60D')) ); } /** * Tests translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -66,7 +64,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/AppenzellInnerrhoden/EasterMondayTest.php b/tests/Switzerland/AppenzellInnerrhoden/EasterMondayTest.php index 5abe0ba1b..560bfa676 100644 --- a/tests/Switzerland/AppenzellInnerrhoden/EasterMondayTest.php +++ b/tests/Switzerland/AppenzellInnerrhoden/EasterMondayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Switzerland\AppenzellInnerrhoden; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -33,7 +30,7 @@ class EasterMondayTest extends AppenzellInnerrhodenBaseTestCase implements Holid /** * Tests Easter Monday. * - * @throws Exception + * @throws \Exception */ public function testEasterMonday(): void { @@ -42,14 +39,14 @@ public function testEasterMonday(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-3-28", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-3-28", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests translated name of Easter Monday. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -64,7 +61,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/AppenzellInnerrhoden/GoodFridayTest.php b/tests/Switzerland/AppenzellInnerrhoden/GoodFridayTest.php index 97be1b50b..344cd451c 100644 --- a/tests/Switzerland/AppenzellInnerrhoden/GoodFridayTest.php +++ b/tests/Switzerland/AppenzellInnerrhoden/GoodFridayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Switzerland\AppenzellInnerrhoden; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -33,7 +30,7 @@ class GoodFridayTest extends AppenzellInnerrhodenBaseTestCase implements Holiday /** * Tests the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHoliday(): void { @@ -42,14 +39,14 @@ public function testHoliday(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-3-21", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-3-21", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -64,7 +61,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/AppenzellInnerrhoden/ImmaculateConceptionTest.php b/tests/Switzerland/AppenzellInnerrhoden/ImmaculateConceptionTest.php index 44e9d09f7..121cfe942 100644 --- a/tests/Switzerland/AppenzellInnerrhoden/ImmaculateConceptionTest.php +++ b/tests/Switzerland/AppenzellInnerrhoden/ImmaculateConceptionTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\Switzerland\AppenzellInnerrhoden; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,8 +32,8 @@ class ImmaculateConceptionTest extends AppenzellInnerrhodenBaseTestCase implemen * * @dataProvider HolidayDataProvider * - * @param int $year the year for which the holiday defined in this test needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which the holiday defined in this test needs to be tested + * @param \DateTime $expected the expected date */ public function testHoliday(int $year, \DateTimeInterface $expected): void { @@ -47,7 +45,7 @@ public function testHoliday(int $year, \DateTimeInterface $expected): void * * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function HolidayDataProvider(): array { @@ -57,7 +55,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -72,7 +70,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/AppenzellInnerrhoden/NewYearsDayTest.php b/tests/Switzerland/AppenzellInnerrhoden/NewYearsDayTest.php index 41de674bc..8a49dba4a 100644 --- a/tests/Switzerland/AppenzellInnerrhoden/NewYearsDayTest.php +++ b/tests/Switzerland/AppenzellInnerrhoden/NewYearsDayTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\Switzerland\AppenzellInnerrhoden; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,8 +32,8 @@ class NewYearsDayTest extends AppenzellInnerrhodenBaseTestCase implements Holida * * @dataProvider NewYearsDayDataProvider * - * @param int $year the year for which New Years Day needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which New Years Day needs to be tested + * @param \DateTime $expected the expected date */ public function testNewYearsDay(int $year, \DateTimeInterface $expected): void { @@ -45,7 +43,7 @@ public function testNewYearsDay(int $year, \DateTimeInterface $expected): void /** * Tests translated name of New Years Day. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -60,7 +58,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { @@ -72,7 +70,7 @@ public function testHolidayType(): void * * @return array list of test dates for New Years Day * - * @throws Exception + * @throws \Exception */ public function NewYearsDayDataProvider(): array { diff --git a/tests/Switzerland/AppenzellInnerrhoden/PentecostMondayTest.php b/tests/Switzerland/AppenzellInnerrhoden/PentecostMondayTest.php index 823912e12..483fac591 100644 --- a/tests/Switzerland/AppenzellInnerrhoden/PentecostMondayTest.php +++ b/tests/Switzerland/AppenzellInnerrhoden/PentecostMondayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Switzerland\AppenzellInnerrhoden; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -33,7 +30,7 @@ class PentecostMondayTest extends AppenzellInnerrhodenBaseTestCase implements Ho /** * Tests Pentecost Monday. * - * @throws Exception + * @throws \Exception */ public function testPentecostMonday(): void { @@ -42,14 +39,14 @@ public function testPentecostMonday(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-5-30", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-5-30", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests translated name of Pentecost Monday. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -64,7 +61,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/AppenzellInnerrhoden/StStephensDayTest.php b/tests/Switzerland/AppenzellInnerrhoden/StStephensDayTest.php index 1607571e1..2d06b4ba8 100644 --- a/tests/Switzerland/AppenzellInnerrhoden/StStephensDayTest.php +++ b/tests/Switzerland/AppenzellInnerrhoden/StStephensDayTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\Switzerland\AppenzellInnerrhoden; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,8 +32,8 @@ class StStephensDayTest extends AppenzellInnerrhodenBaseTestCase implements Holi * * @dataProvider HolidayDataProvider * - * @param int $year the year for which the holiday defined in this test needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which the holiday defined in this test needs to be tested + * @param \DateTime $expected the expected date */ public function testHoliday(int $year, \DateTimeInterface $expected): void { @@ -47,7 +45,7 @@ public function testHoliday(int $year, \DateTimeInterface $expected): void * * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function HolidayDataProvider(): array { @@ -57,7 +55,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -72,7 +70,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/BaselLandschaft/AscensionDayTest.php b/tests/Switzerland/BaselLandschaft/AscensionDayTest.php index 6ec32e6f3..548857e19 100644 --- a/tests/Switzerland/BaselLandschaft/AscensionDayTest.php +++ b/tests/Switzerland/BaselLandschaft/AscensionDayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Switzerland\BaselLandschaft; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -33,7 +30,7 @@ class AscensionDayTest extends BaselLandschaftBaseTestCase implements HolidayTes /** * Tests Ascension Day. * - * @throws Exception + * @throws \Exception */ public function testAscensionDay(): void { @@ -42,14 +39,14 @@ public function testAscensionDay(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-5-16", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-5-16", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests translated name of Ascension Day. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -64,7 +61,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/BaselLandschaft/BaselLandschaftTest.php b/tests/Switzerland/BaselLandschaft/BaselLandschaftTest.php index 096f286e4..6ad2b63b8 100644 --- a/tests/Switzerland/BaselLandschaft/BaselLandschaftTest.php +++ b/tests/Switzerland/BaselLandschaft/BaselLandschaftTest.php @@ -14,7 +14,6 @@ namespace Yasumi\tests\Switzerland\BaselLandschaft; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\ProviderTestCase; @@ -105,7 +104,7 @@ public function testOtherHolidays(): void } /** - * @throws ReflectionException + * @throws \ReflectionException * @throws \Exception */ public function testSources(): void diff --git a/tests/Switzerland/BaselLandschaft/ChristmasDayTest.php b/tests/Switzerland/BaselLandschaft/ChristmasDayTest.php index 786a92ec1..302bea557 100644 --- a/tests/Switzerland/BaselLandschaft/ChristmasDayTest.php +++ b/tests/Switzerland/BaselLandschaft/ChristmasDayTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\Switzerland\BaselLandschaft; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,8 +32,8 @@ class ChristmasDayTest extends BaselLandschaftBaseTestCase implements HolidayTes * * @dataProvider ChristmasDayDataProvider * - * @param int $year the year for which Christmas Day needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which Christmas Day needs to be tested + * @param \DateTime $expected the expected date */ public function testChristmasDay(int $year, \DateTimeInterface $expected): void { @@ -47,7 +45,7 @@ public function testChristmasDay(int $year, \DateTimeInterface $expected): void * * @return array list of test dates for Christmas Day * - * @throws Exception + * @throws \Exception */ public function ChristmasDayDataProvider(): array { @@ -57,7 +55,7 @@ public function ChristmasDayDataProvider(): array /** * Tests translated name of Christmas Day. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -72,7 +70,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/BaselLandschaft/EasterMondayTest.php b/tests/Switzerland/BaselLandschaft/EasterMondayTest.php index ce78317cc..fb6f757d6 100644 --- a/tests/Switzerland/BaselLandschaft/EasterMondayTest.php +++ b/tests/Switzerland/BaselLandschaft/EasterMondayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Switzerland\BaselLandschaft; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -33,7 +30,7 @@ class EasterMondayTest extends BaselLandschaftBaseTestCase implements HolidayTes /** * Tests Easter Monday. * - * @throws Exception + * @throws \Exception */ public function testEasterMonday(): void { @@ -42,14 +39,14 @@ public function testEasterMonday(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-3-28", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-3-28", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests translated name of Easter Monday. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -64,7 +61,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/BaselLandschaft/GoodFridayTest.php b/tests/Switzerland/BaselLandschaft/GoodFridayTest.php index cd352aa16..0c9b40470 100644 --- a/tests/Switzerland/BaselLandschaft/GoodFridayTest.php +++ b/tests/Switzerland/BaselLandschaft/GoodFridayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Switzerland\BaselLandschaft; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -33,7 +30,7 @@ class GoodFridayTest extends BaselLandschaftBaseTestCase implements HolidayTestC /** * Tests the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHoliday(): void { @@ -42,14 +39,14 @@ public function testHoliday(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-3-21", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-3-21", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -64,7 +61,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/BaselLandschaft/NewYearsDayTest.php b/tests/Switzerland/BaselLandschaft/NewYearsDayTest.php index 65f689433..f75ec8723 100644 --- a/tests/Switzerland/BaselLandschaft/NewYearsDayTest.php +++ b/tests/Switzerland/BaselLandschaft/NewYearsDayTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\Switzerland\BaselLandschaft; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,8 +32,8 @@ class NewYearsDayTest extends BaselLandschaftBaseTestCase implements HolidayTest * * @dataProvider NewYearsDayDataProvider * - * @param int $year the year for which New Years Day needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which New Years Day needs to be tested + * @param \DateTime $expected the expected date */ public function testNewYearsDay(int $year, \DateTimeInterface $expected): void { @@ -45,7 +43,7 @@ public function testNewYearsDay(int $year, \DateTimeInterface $expected): void /** * Tests translated name of New Years Day. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -60,7 +58,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { @@ -72,7 +70,7 @@ public function testHolidayType(): void * * @return array list of test dates for New Years Day * - * @throws Exception + * @throws \Exception */ public function NewYearsDayDataProvider(): array { diff --git a/tests/Switzerland/BaselLandschaft/PentecostMondayTest.php b/tests/Switzerland/BaselLandschaft/PentecostMondayTest.php index 15cb63e86..b6bf74a2d 100644 --- a/tests/Switzerland/BaselLandschaft/PentecostMondayTest.php +++ b/tests/Switzerland/BaselLandschaft/PentecostMondayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Switzerland\BaselLandschaft; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -33,7 +30,7 @@ class PentecostMondayTest extends BaselLandschaftBaseTestCase implements Holiday /** * Tests Pentecost Monday. * - * @throws Exception + * @throws \Exception */ public function testPentecostMonday(): void { @@ -42,14 +39,14 @@ public function testPentecostMonday(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-5-30", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-5-30", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests translated name of Pentecost Monday. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -64,7 +61,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/BaselLandschaft/StStephensDayTest.php b/tests/Switzerland/BaselLandschaft/StStephensDayTest.php index 945fc24e7..15d8cdb88 100644 --- a/tests/Switzerland/BaselLandschaft/StStephensDayTest.php +++ b/tests/Switzerland/BaselLandschaft/StStephensDayTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\Switzerland\BaselLandschaft; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,8 +32,8 @@ class StStephensDayTest extends BaselLandschaftBaseTestCase implements HolidayTe * * @dataProvider HolidayDataProvider * - * @param int $year the year for which the holiday defined in this test needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which the holiday defined in this test needs to be tested + * @param \DateTime $expected the expected date */ public function testHoliday(int $year, \DateTimeInterface $expected): void { @@ -47,7 +45,7 @@ public function testHoliday(int $year, \DateTimeInterface $expected): void * * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function HolidayDataProvider(): array { @@ -57,7 +55,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -72,7 +70,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/BaselLandschaft/WorkersDayTest.php b/tests/Switzerland/BaselLandschaft/WorkersDayTest.php index 46844b970..30901ddab 100644 --- a/tests/Switzerland/BaselLandschaft/WorkersDayTest.php +++ b/tests/Switzerland/BaselLandschaft/WorkersDayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Switzerland\BaselLandschaft; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -38,11 +35,11 @@ class WorkersDayTest extends BaselLandschaftBaseTestCase implements HolidayTestC * @param int $year the year for which the holiday defined in this test needs to be tested * @param string $expected the expected date * - * @throws Exception + * @throws \Exception */ public function testHoliday(int $year, string $expected): void { - $date = new DateTime($expected, new DateTimeZone(self::TIMEZONE)); + $date = new \DateTime($expected, new \DateTimeZone(self::TIMEZONE)); $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $date); } @@ -51,7 +48,7 @@ public function testHoliday(int $year, string $expected): void * * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function HolidayDataProvider(): array { @@ -59,7 +56,7 @@ public function HolidayDataProvider(): array for ($y = 0; $y < 50; ++$y) { $year = $this->generateRandomYear(); - $date = new DateTime("$year-5-1", new DateTimeZone(self::TIMEZONE)); + $date = new \DateTime("$year-5-1", new \DateTimeZone(self::TIMEZONE)); $data[] = [$year, $date->format('Y-m-d')]; } @@ -69,7 +66,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -84,7 +81,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/BaselStadt/AscensionDayTest.php b/tests/Switzerland/BaselStadt/AscensionDayTest.php index 3c4e0dcba..1972c8caf 100644 --- a/tests/Switzerland/BaselStadt/AscensionDayTest.php +++ b/tests/Switzerland/BaselStadt/AscensionDayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Switzerland\BaselStadt; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -33,7 +30,7 @@ class AscensionDayTest extends BaselStadtBaseTestCase implements HolidayTestCase /** * Tests Ascension Day. * - * @throws Exception + * @throws \Exception */ public function testAscensionDay(): void { @@ -42,14 +39,14 @@ public function testAscensionDay(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-5-16", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-5-16", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests translated name of Ascension Day. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -64,7 +61,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/BaselStadt/BaselStadtTest.php b/tests/Switzerland/BaselStadt/BaselStadtTest.php index 15db71787..b82f31126 100644 --- a/tests/Switzerland/BaselStadt/BaselStadtTest.php +++ b/tests/Switzerland/BaselStadt/BaselStadtTest.php @@ -14,7 +14,6 @@ namespace Yasumi\tests\Switzerland\BaselStadt; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\ProviderTestCase; @@ -105,7 +104,7 @@ public function testOtherHolidays(): void } /** - * @throws ReflectionException + * @throws \ReflectionException * @throws \Exception */ public function testSources(): void diff --git a/tests/Switzerland/BaselStadt/ChristmasDayTest.php b/tests/Switzerland/BaselStadt/ChristmasDayTest.php index f455d94f5..684e97445 100644 --- a/tests/Switzerland/BaselStadt/ChristmasDayTest.php +++ b/tests/Switzerland/BaselStadt/ChristmasDayTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\Switzerland\BaselStadt; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,8 +32,8 @@ class ChristmasDayTest extends BaselStadtBaseTestCase implements HolidayTestCase * * @dataProvider ChristmasDayDataProvider * - * @param int $year the year for which Christmas Day needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which Christmas Day needs to be tested + * @param \DateTime $expected the expected date */ public function testChristmasDay(int $year, \DateTimeInterface $expected): void { @@ -47,7 +45,7 @@ public function testChristmasDay(int $year, \DateTimeInterface $expected): void * * @return array list of test dates for Christmas Day * - * @throws Exception + * @throws \Exception */ public function ChristmasDayDataProvider(): array { @@ -57,7 +55,7 @@ public function ChristmasDayDataProvider(): array /** * Tests translated name of Christmas Day. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -72,7 +70,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/BaselStadt/EasterMondayTest.php b/tests/Switzerland/BaselStadt/EasterMondayTest.php index c924c35bc..792643e83 100644 --- a/tests/Switzerland/BaselStadt/EasterMondayTest.php +++ b/tests/Switzerland/BaselStadt/EasterMondayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Switzerland\BaselStadt; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -33,7 +30,7 @@ class EasterMondayTest extends BaselStadtBaseTestCase implements HolidayTestCase /** * Tests Easter Monday. * - * @throws Exception + * @throws \Exception */ public function testEasterMonday(): void { @@ -42,14 +39,14 @@ public function testEasterMonday(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-3-28", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-3-28", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests translated name of Easter Monday. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -64,7 +61,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/BaselStadt/GoodFridayTest.php b/tests/Switzerland/BaselStadt/GoodFridayTest.php index 01453c993..8bababc4d 100644 --- a/tests/Switzerland/BaselStadt/GoodFridayTest.php +++ b/tests/Switzerland/BaselStadt/GoodFridayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Switzerland\BaselStadt; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -33,7 +30,7 @@ class GoodFridayTest extends BaselStadtBaseTestCase implements HolidayTestCase /** * Tests the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHoliday(): void { @@ -42,14 +39,14 @@ public function testHoliday(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-3-21", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-3-21", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -64,7 +61,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/BaselStadt/NewYearsDayTest.php b/tests/Switzerland/BaselStadt/NewYearsDayTest.php index a658b1fdc..e7c15768f 100644 --- a/tests/Switzerland/BaselStadt/NewYearsDayTest.php +++ b/tests/Switzerland/BaselStadt/NewYearsDayTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\Switzerland\BaselStadt; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,8 +32,8 @@ class NewYearsDayTest extends BaselStadtBaseTestCase implements HolidayTestCase * * @dataProvider NewYearsDayDataProvider * - * @param int $year the year for which New Years Day needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which New Years Day needs to be tested + * @param \DateTime $expected the expected date */ public function testNewYearsDay(int $year, \DateTimeInterface $expected): void { @@ -45,7 +43,7 @@ public function testNewYearsDay(int $year, \DateTimeInterface $expected): void /** * Tests translated name of New Years Day. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -60,7 +58,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { @@ -72,7 +70,7 @@ public function testHolidayType(): void * * @return array list of test dates for New Years Day * - * @throws Exception + * @throws \Exception */ public function NewYearsDayDataProvider(): array { diff --git a/tests/Switzerland/BaselStadt/PentecostMondayTest.php b/tests/Switzerland/BaselStadt/PentecostMondayTest.php index a56c0c32e..f06b078bf 100644 --- a/tests/Switzerland/BaselStadt/PentecostMondayTest.php +++ b/tests/Switzerland/BaselStadt/PentecostMondayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Switzerland\BaselStadt; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -33,7 +30,7 @@ class PentecostMondayTest extends BaselStadtBaseTestCase implements HolidayTestC /** * Tests Pentecost Monday. * - * @throws Exception + * @throws \Exception */ public function testPentecostMonday(): void { @@ -42,14 +39,14 @@ public function testPentecostMonday(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-5-30", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-5-30", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests translated name of Pentecost Monday. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -64,7 +61,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/BaselStadt/StStephensDayTest.php b/tests/Switzerland/BaselStadt/StStephensDayTest.php index 8ea498c17..5b6f402e4 100644 --- a/tests/Switzerland/BaselStadt/StStephensDayTest.php +++ b/tests/Switzerland/BaselStadt/StStephensDayTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\Switzerland\BaselStadt; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,8 +32,8 @@ class StStephensDayTest extends BaselStadtBaseTestCase implements HolidayTestCas * * @dataProvider HolidayDataProvider * - * @param int $year the year for which the holiday defined in this test needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which the holiday defined in this test needs to be tested + * @param \DateTime $expected the expected date */ public function testHoliday(int $year, \DateTimeInterface $expected): void { @@ -47,7 +45,7 @@ public function testHoliday(int $year, \DateTimeInterface $expected): void * * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function HolidayDataProvider(): array { @@ -57,7 +55,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -72,7 +70,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/BaselStadt/WorkersDayTest.php b/tests/Switzerland/BaselStadt/WorkersDayTest.php index 0eb1d1ff0..f5f60fc80 100644 --- a/tests/Switzerland/BaselStadt/WorkersDayTest.php +++ b/tests/Switzerland/BaselStadt/WorkersDayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Switzerland\BaselStadt; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -38,11 +35,11 @@ class WorkersDayTest extends BaselStadtBaseTestCase implements HolidayTestCase * @param int $year the year for which the holiday defined in this test needs to be tested * @param string $expected the expected date * - * @throws Exception + * @throws \Exception */ public function testHoliday(int $year, string $expected): void { - $date = new DateTime($expected, new DateTimeZone(self::TIMEZONE)); + $date = new \DateTime($expected, new \DateTimeZone(self::TIMEZONE)); $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $date); } @@ -51,7 +48,7 @@ public function testHoliday(int $year, string $expected): void * * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function HolidayDataProvider(): array { @@ -59,7 +56,7 @@ public function HolidayDataProvider(): array for ($y = 0; $y < 50; ++$y) { $year = $this->generateRandomYear(); - $date = new DateTime("$year-5-1", new DateTimeZone(self::TIMEZONE)); + $date = new \DateTime("$year-5-1", new \DateTimeZone(self::TIMEZONE)); $data[] = [$year, $date->format('Y-m-d')]; } @@ -69,7 +66,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -84,7 +81,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Bern/AscensionDayTest.php b/tests/Switzerland/Bern/AscensionDayTest.php index cde186594..9c5e55155 100644 --- a/tests/Switzerland/Bern/AscensionDayTest.php +++ b/tests/Switzerland/Bern/AscensionDayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Switzerland\Bern; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -33,7 +30,7 @@ class AscensionDayTest extends BernBaseTestCase implements HolidayTestCase /** * Tests Ascension Day. * - * @throws Exception + * @throws \Exception */ public function testAscensionDay(): void { @@ -42,14 +39,14 @@ public function testAscensionDay(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-5-16", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-5-16", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests translated name of Ascension Day. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -64,7 +61,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Bern/BerchtoldsTagTest.php b/tests/Switzerland/Bern/BerchtoldsTagTest.php index 4b302fbc4..e663c633c 100644 --- a/tests/Switzerland/Bern/BerchtoldsTagTest.php +++ b/tests/Switzerland/Bern/BerchtoldsTagTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Switzerland\Bern; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -33,12 +30,12 @@ class BerchtoldsTagTest extends BernBaseTestCase implements HolidayTestCase /** * Tests BerchtoldsTag. * - * @throws Exception + * @throws \Exception */ public function testBerchtoldsTag(): void { $year = $this->generateRandomYear(); - $date = new DateTime($year.'-01-02', new DateTimeZone(self::TIMEZONE)); + $date = new \DateTime($year.'-01-02', new \DateTimeZone(self::TIMEZONE)); $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $date); $this->assertHolidayType(self::REGION, self::HOLIDAY, $year, Holiday::TYPE_OTHER); @@ -47,7 +44,7 @@ public function testBerchtoldsTag(): void /** * Tests translated name of BerchtoldsTag. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -62,7 +59,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Bern/BernTest.php b/tests/Switzerland/Bern/BernTest.php index fb4ae83a2..b9943f75b 100644 --- a/tests/Switzerland/Bern/BernTest.php +++ b/tests/Switzerland/Bern/BernTest.php @@ -14,7 +14,6 @@ namespace Yasumi\tests\Switzerland\Bern; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\ProviderTestCase; @@ -105,7 +104,7 @@ public function testOtherHolidays(): void } /** - * @throws ReflectionException + * @throws \ReflectionException * @throws \Exception */ public function testSources(): void diff --git a/tests/Switzerland/Bern/ChristmasDayTest.php b/tests/Switzerland/Bern/ChristmasDayTest.php index ba5d92019..e399c1e09 100644 --- a/tests/Switzerland/Bern/ChristmasDayTest.php +++ b/tests/Switzerland/Bern/ChristmasDayTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\Switzerland\Bern; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,8 +32,8 @@ class ChristmasDayTest extends BernBaseTestCase implements HolidayTestCase * * @dataProvider ChristmasDayDataProvider * - * @param int $year the year for which Christmas Day needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which Christmas Day needs to be tested + * @param \DateTime $expected the expected date */ public function testChristmasDay(int $year, \DateTimeInterface $expected): void { @@ -47,7 +45,7 @@ public function testChristmasDay(int $year, \DateTimeInterface $expected): void * * @return array list of test dates for Christmas Day * - * @throws Exception + * @throws \Exception */ public function ChristmasDayDataProvider(): array { @@ -57,7 +55,7 @@ public function ChristmasDayDataProvider(): array /** * Tests translated name of Christmas Day. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -72,7 +70,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Bern/EasterMondayTest.php b/tests/Switzerland/Bern/EasterMondayTest.php index 4a080cdb7..0d3c5de1d 100644 --- a/tests/Switzerland/Bern/EasterMondayTest.php +++ b/tests/Switzerland/Bern/EasterMondayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Switzerland\Bern; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -33,7 +30,7 @@ class EasterMondayTest extends BernBaseTestCase implements HolidayTestCase /** * Tests Easter Monday. * - * @throws Exception + * @throws \Exception */ public function testEasterMonday(): void { @@ -42,14 +39,14 @@ public function testEasterMonday(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-3-28", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-3-28", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests translated name of Easter Monday. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -64,7 +61,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Bern/GoodFridayTest.php b/tests/Switzerland/Bern/GoodFridayTest.php index 0d03e3e39..220aff80e 100644 --- a/tests/Switzerland/Bern/GoodFridayTest.php +++ b/tests/Switzerland/Bern/GoodFridayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Switzerland\Bern; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -33,7 +30,7 @@ class GoodFridayTest extends BernBaseTestCase implements HolidayTestCase /** * Tests the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHoliday(): void { @@ -42,14 +39,14 @@ public function testHoliday(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-3-21", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-3-21", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -64,7 +61,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Bern/NewYearsDayTest.php b/tests/Switzerland/Bern/NewYearsDayTest.php index 59afad745..b6d14eddb 100644 --- a/tests/Switzerland/Bern/NewYearsDayTest.php +++ b/tests/Switzerland/Bern/NewYearsDayTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\Switzerland\Bern; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,8 +32,8 @@ class NewYearsDayTest extends BernBaseTestCase implements HolidayTestCase * * @dataProvider NewYearsDayDataProvider * - * @param int $year the year for which New Years Day needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which New Years Day needs to be tested + * @param \DateTime $expected the expected date */ public function testNewYearsDay(int $year, \DateTimeInterface $expected): void { @@ -45,7 +43,7 @@ public function testNewYearsDay(int $year, \DateTimeInterface $expected): void /** * Tests translated name of New Years Day. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -60,7 +58,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { @@ -72,7 +70,7 @@ public function testHolidayType(): void * * @return array list of test dates for New Years Day * - * @throws Exception + * @throws \Exception */ public function NewYearsDayDataProvider(): array { diff --git a/tests/Switzerland/Bern/PentecostMondayTest.php b/tests/Switzerland/Bern/PentecostMondayTest.php index 3ee459695..2a8b74d4b 100644 --- a/tests/Switzerland/Bern/PentecostMondayTest.php +++ b/tests/Switzerland/Bern/PentecostMondayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Switzerland\Bern; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -33,7 +30,7 @@ class PentecostMondayTest extends BernBaseTestCase implements HolidayTestCase /** * Tests Pentecost Monday. * - * @throws Exception + * @throws \Exception */ public function testPentecostMonday(): void { @@ -42,14 +39,14 @@ public function testPentecostMonday(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-5-30", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-5-30", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests translated name of Pentecost Monday. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -64,7 +61,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Bern/StStephensDayTest.php b/tests/Switzerland/Bern/StStephensDayTest.php index f6260d5e8..bea86fe4f 100644 --- a/tests/Switzerland/Bern/StStephensDayTest.php +++ b/tests/Switzerland/Bern/StStephensDayTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\Switzerland\Bern; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,8 +32,8 @@ class StStephensDayTest extends BernBaseTestCase implements HolidayTestCase * * @dataProvider HolidayDataProvider * - * @param int $year the year for which the holiday defined in this test needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which the holiday defined in this test needs to be tested + * @param \DateTime $expected the expected date */ public function testHoliday(int $year, \DateTimeInterface $expected): void { @@ -47,7 +45,7 @@ public function testHoliday(int $year, \DateTimeInterface $expected): void * * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function HolidayDataProvider(): array { @@ -57,7 +55,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -72,7 +70,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Fribourg/AllSaintsDayTest.php b/tests/Switzerland/Fribourg/AllSaintsDayTest.php index 9afeff288..4476cbbb3 100644 --- a/tests/Switzerland/Fribourg/AllSaintsDayTest.php +++ b/tests/Switzerland/Fribourg/AllSaintsDayTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\Switzerland\Fribourg; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,8 +32,8 @@ class AllSaintsDayTest extends FribourgBaseTestCase implements HolidayTestCase * * @dataProvider AllSaintsDayDataProvider * - * @param int $year the year for which All Saints' Day needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which All Saints' Day needs to be tested + * @param \DateTime $expected the expected date */ public function testAllSaintsDay(int $year, \DateTimeInterface $expected): void { @@ -45,7 +43,7 @@ public function testAllSaintsDay(int $year, \DateTimeInterface $expected): void /** * Tests translated name of All Saints' Day. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -60,7 +58,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { @@ -72,7 +70,7 @@ public function testHolidayType(): void * * @return array list of test dates for All Saints' Day * - * @throws Exception + * @throws \Exception */ public function AllSaintsDayDataProvider(): array { diff --git a/tests/Switzerland/Fribourg/AscensionDayTest.php b/tests/Switzerland/Fribourg/AscensionDayTest.php index 3278a8e5d..0e24c7930 100644 --- a/tests/Switzerland/Fribourg/AscensionDayTest.php +++ b/tests/Switzerland/Fribourg/AscensionDayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Switzerland\Fribourg; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -33,7 +30,7 @@ class AscensionDayTest extends FribourgBaseTestCase implements HolidayTestCase /** * Tests Ascension Day. * - * @throws Exception + * @throws \Exception */ public function testAscensionDay(): void { @@ -42,14 +39,14 @@ public function testAscensionDay(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-5-16", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-5-16", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests translated name of Ascension Day. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -64,7 +61,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Fribourg/AssumptionOfMaryTest.php b/tests/Switzerland/Fribourg/AssumptionOfMaryTest.php index 315c6c5dd..24c78586d 100644 --- a/tests/Switzerland/Fribourg/AssumptionOfMaryTest.php +++ b/tests/Switzerland/Fribourg/AssumptionOfMaryTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\Switzerland\Fribourg; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,8 +32,8 @@ class AssumptionOfMaryTest extends FribourgBaseTestCase implements HolidayTestCa * * @dataProvider AssumptionOfMaryDataProvider * - * @param int $year the year for which the day of the Assumption of Mary needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which the day of the Assumption of Mary needs to be tested + * @param \DateTime $expected the expected date */ public function testAssumptionOfMary(int $year, \DateTimeInterface $expected): void { @@ -45,7 +43,7 @@ public function testAssumptionOfMary(int $year, \DateTimeInterface $expected): v /** * Tests translated name of the day of the Assumption of Mary. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -60,7 +58,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { @@ -72,7 +70,7 @@ public function testHolidayType(): void * * @return array list of test dates for the day of the Assumption of Mary * - * @throws Exception + * @throws \Exception */ public function AssumptionOfMaryDataProvider(): array { diff --git a/tests/Switzerland/Fribourg/BerchtoldsTagTest.php b/tests/Switzerland/Fribourg/BerchtoldsTagTest.php index c19cb47b2..538b6e893 100644 --- a/tests/Switzerland/Fribourg/BerchtoldsTagTest.php +++ b/tests/Switzerland/Fribourg/BerchtoldsTagTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Switzerland\Fribourg; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -33,12 +30,12 @@ class BerchtoldsTagTest extends FribourgBaseTestCase implements HolidayTestCase /** * Tests BerchtoldsTag. * - * @throws Exception + * @throws \Exception */ public function testBerchtoldsTag(): void { $year = $this->generateRandomYear(); - $date = new DateTime($year.'-01-02', new DateTimeZone(self::TIMEZONE)); + $date = new \DateTime($year.'-01-02', new \DateTimeZone(self::TIMEZONE)); $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $date); $this->assertHolidayType(self::REGION, self::HOLIDAY, $year, Holiday::TYPE_OTHER); @@ -47,7 +44,7 @@ public function testBerchtoldsTag(): void /** * Tests translated name of BerchtoldsTag. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -62,7 +59,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Fribourg/ChristmasDayTest.php b/tests/Switzerland/Fribourg/ChristmasDayTest.php index 691634ffd..c4123be67 100644 --- a/tests/Switzerland/Fribourg/ChristmasDayTest.php +++ b/tests/Switzerland/Fribourg/ChristmasDayTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\Switzerland\Fribourg; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,8 +32,8 @@ class ChristmasDayTest extends FribourgBaseTestCase implements HolidayTestCase * * @dataProvider ChristmasDayDataProvider * - * @param int $year the year for which Christmas Day needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which Christmas Day needs to be tested + * @param \DateTime $expected the expected date */ public function testChristmasDay(int $year, \DateTimeInterface $expected): void { @@ -47,7 +45,7 @@ public function testChristmasDay(int $year, \DateTimeInterface $expected): void * * @return array list of test dates for Christmas Day * - * @throws Exception + * @throws \Exception */ public function ChristmasDayDataProvider(): array { @@ -57,7 +55,7 @@ public function ChristmasDayDataProvider(): array /** * Tests translated name of Christmas Day. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -72,7 +70,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Fribourg/CorpusChristiTest.php b/tests/Switzerland/Fribourg/CorpusChristiTest.php index 61e7fd979..981fb3600 100644 --- a/tests/Switzerland/Fribourg/CorpusChristiTest.php +++ b/tests/Switzerland/Fribourg/CorpusChristiTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\Switzerland\Fribourg; -use DateInterval; -use Exception; use Yasumi\Holiday; use Yasumi\Provider\ChristianHolidays; use Yasumi\tests\HolidayTestCase; @@ -35,7 +33,7 @@ class CorpusChristiTest extends FribourgBaseTestCase implements HolidayTestCase /** * Tests Corpus Christi. * - * @throws Exception + * @throws \Exception */ public function testCorpusChristi(): void { @@ -44,14 +42,14 @@ public function testCorpusChristi(): void self::REGION, self::HOLIDAY, $year, - $this->calculateEaster($year, self::TIMEZONE)->add(new DateInterval('P60D')) + $this->calculateEaster($year, self::TIMEZONE)->add(new \DateInterval('P60D')) ); } /** * Tests translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -66,7 +64,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Fribourg/December26thTest.php b/tests/Switzerland/Fribourg/December26thTest.php index ec6ccca35..5f2dae89e 100644 --- a/tests/Switzerland/Fribourg/December26thTest.php +++ b/tests/Switzerland/Fribourg/December26thTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Switzerland\Fribourg; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -33,7 +30,7 @@ class December26thTest extends FribourgBaseTestCase implements HolidayTestCase /** * Tests December 26th. * - * @throws Exception + * @throws \Exception */ public function testDecember26th(): void { @@ -42,14 +39,14 @@ public function testDecember26th(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-12-26", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-12-26", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests translated name of December 26th. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -64,7 +61,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Fribourg/EasterMondayTest.php b/tests/Switzerland/Fribourg/EasterMondayTest.php index b6c718054..037d75556 100644 --- a/tests/Switzerland/Fribourg/EasterMondayTest.php +++ b/tests/Switzerland/Fribourg/EasterMondayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Switzerland\Fribourg; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -33,7 +30,7 @@ class EasterMondayTest extends FribourgBaseTestCase implements HolidayTestCase /** * Tests Easter Monday. * - * @throws Exception + * @throws \Exception */ public function testEasterMonday(): void { @@ -42,14 +39,14 @@ public function testEasterMonday(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-3-28", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-3-28", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests translated name of Easter Monday. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -64,7 +61,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Fribourg/FribourgTest.php b/tests/Switzerland/Fribourg/FribourgTest.php index ff7095556..5d4eae8c6 100644 --- a/tests/Switzerland/Fribourg/FribourgTest.php +++ b/tests/Switzerland/Fribourg/FribourgTest.php @@ -14,7 +14,6 @@ namespace Yasumi\tests\Switzerland\Fribourg; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\ProviderTestCase; @@ -109,7 +108,7 @@ public function testOtherHolidays(): void } /** - * @throws ReflectionException + * @throws \ReflectionException * @throws \Exception */ public function testSources(): void diff --git a/tests/Switzerland/Fribourg/GoodFridayTest.php b/tests/Switzerland/Fribourg/GoodFridayTest.php index 922a6bc26..79e7b983e 100644 --- a/tests/Switzerland/Fribourg/GoodFridayTest.php +++ b/tests/Switzerland/Fribourg/GoodFridayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Switzerland\Fribourg; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -33,7 +30,7 @@ class GoodFridayTest extends FribourgBaseTestCase implements HolidayTestCase /** * Tests the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHoliday(): void { @@ -42,14 +39,14 @@ public function testHoliday(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-3-21", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-3-21", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -64,7 +61,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Fribourg/ImmaculateConceptionTest.php b/tests/Switzerland/Fribourg/ImmaculateConceptionTest.php index 174ef6b9c..d2b5b8e6a 100644 --- a/tests/Switzerland/Fribourg/ImmaculateConceptionTest.php +++ b/tests/Switzerland/Fribourg/ImmaculateConceptionTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\Switzerland\Fribourg; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,8 +32,8 @@ class ImmaculateConceptionTest extends FribourgBaseTestCase implements HolidayTe * * @dataProvider HolidayDataProvider * - * @param int $year the year for which the holiday defined in this test needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which the holiday defined in this test needs to be tested + * @param \DateTime $expected the expected date */ public function testHoliday(int $year, \DateTimeInterface $expected): void { @@ -47,7 +45,7 @@ public function testHoliday(int $year, \DateTimeInterface $expected): void * * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function HolidayDataProvider(): array { @@ -57,7 +55,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -72,7 +70,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Fribourg/NewYearsDayTest.php b/tests/Switzerland/Fribourg/NewYearsDayTest.php index 1c6bf751e..125d7e13d 100644 --- a/tests/Switzerland/Fribourg/NewYearsDayTest.php +++ b/tests/Switzerland/Fribourg/NewYearsDayTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\Switzerland\Fribourg; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,8 +32,8 @@ class NewYearsDayTest extends FribourgBaseTestCase implements HolidayTestCase * * @dataProvider NewYearsDayDataProvider * - * @param int $year the year for which New Years Day needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which New Years Day needs to be tested + * @param \DateTime $expected the expected date */ public function testNewYearsDay(int $year, \DateTimeInterface $expected): void { @@ -45,7 +43,7 @@ public function testNewYearsDay(int $year, \DateTimeInterface $expected): void /** * Tests translated name of New Years Day. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -60,7 +58,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { @@ -72,7 +70,7 @@ public function testHolidayType(): void * * @return array list of test dates for New Years Day * - * @throws Exception + * @throws \Exception */ public function NewYearsDayDataProvider(): array { diff --git a/tests/Switzerland/Fribourg/PentecostMondayTest.php b/tests/Switzerland/Fribourg/PentecostMondayTest.php index 2e489fe6a..1d82ceb17 100644 --- a/tests/Switzerland/Fribourg/PentecostMondayTest.php +++ b/tests/Switzerland/Fribourg/PentecostMondayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Switzerland\Fribourg; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -33,7 +30,7 @@ class PentecostMondayTest extends FribourgBaseTestCase implements HolidayTestCas /** * Tests Pentecost Monday. * - * @throws Exception + * @throws \Exception */ public function testPentecostMonday(): void { @@ -42,14 +39,14 @@ public function testPentecostMonday(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-5-30", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-5-30", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests translated name of Pentecost Monday. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -64,7 +61,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Geneva/AscensionDayTest.php b/tests/Switzerland/Geneva/AscensionDayTest.php index 7e50d76d0..59d9dbfde 100644 --- a/tests/Switzerland/Geneva/AscensionDayTest.php +++ b/tests/Switzerland/Geneva/AscensionDayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Switzerland\Geneva; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -33,7 +30,7 @@ class AscensionDayTest extends GenevaBaseTestCase implements HolidayTestCase /** * Tests Ascension Day. * - * @throws Exception + * @throws \Exception */ public function testAscensionDay(): void { @@ -42,14 +39,14 @@ public function testAscensionDay(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-5-16", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-5-16", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests translated name of Ascension Day. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -64,7 +61,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Geneva/ChristmasDayTest.php b/tests/Switzerland/Geneva/ChristmasDayTest.php index 6e077687f..615f96f8d 100644 --- a/tests/Switzerland/Geneva/ChristmasDayTest.php +++ b/tests/Switzerland/Geneva/ChristmasDayTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\Switzerland\Geneva; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,8 +32,8 @@ class ChristmasDayTest extends GenevaBaseTestCase implements HolidayTestCase * * @dataProvider ChristmasDayDataProvider * - * @param int $year the year for which Christmas Day needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which Christmas Day needs to be tested + * @param \DateTime $expected the expected date */ public function testChristmasDay(int $year, \DateTimeInterface $expected): void { @@ -47,7 +45,7 @@ public function testChristmasDay(int $year, \DateTimeInterface $expected): void * * @return array list of test dates for Christmas Day * - * @throws Exception + * @throws \Exception */ public function ChristmasDayDataProvider(): array { @@ -57,7 +55,7 @@ public function ChristmasDayDataProvider(): array /** * Tests translated name of Christmas Day. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -72,7 +70,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Geneva/EasterMondayTest.php b/tests/Switzerland/Geneva/EasterMondayTest.php index 98ec27e7d..f773d1028 100644 --- a/tests/Switzerland/Geneva/EasterMondayTest.php +++ b/tests/Switzerland/Geneva/EasterMondayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Switzerland\Geneva; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -33,7 +30,7 @@ class EasterMondayTest extends GenevaBaseTestCase implements HolidayTestCase /** * Tests Easter Monday. * - * @throws Exception + * @throws \Exception */ public function testEasterMonday(): void { @@ -42,14 +39,14 @@ public function testEasterMonday(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-3-28", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-3-28", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests translated name of Easter Monday. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -64,7 +61,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Geneva/GenevaTest.php b/tests/Switzerland/Geneva/GenevaTest.php index 3e9c0e1af..8ac0cb53d 100644 --- a/tests/Switzerland/Geneva/GenevaTest.php +++ b/tests/Switzerland/Geneva/GenevaTest.php @@ -14,7 +14,6 @@ namespace Yasumi\tests\Switzerland\Geneva; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\ProviderTestCase; @@ -118,7 +117,7 @@ public function testOtherHolidays(): void } /** - * @throws ReflectionException + * @throws \ReflectionException * @throws \Exception */ public function testSources(): void diff --git a/tests/Switzerland/Geneva/GoodFridayTest.php b/tests/Switzerland/Geneva/GoodFridayTest.php index 6463a4d51..e64f7a935 100644 --- a/tests/Switzerland/Geneva/GoodFridayTest.php +++ b/tests/Switzerland/Geneva/GoodFridayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Switzerland\Geneva; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -33,7 +30,7 @@ class GoodFridayTest extends GenevaBaseTestCase implements HolidayTestCase /** * Tests the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHoliday(): void { @@ -42,14 +39,14 @@ public function testHoliday(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-3-21", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-3-21", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -64,7 +61,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Geneva/JeuneGenevoisTest.php b/tests/Switzerland/Geneva/JeuneGenevoisTest.php index 0ba45a649..c5361c126 100644 --- a/tests/Switzerland/Geneva/JeuneGenevoisTest.php +++ b/tests/Switzerland/Geneva/JeuneGenevoisTest.php @@ -14,10 +14,6 @@ namespace Yasumi\tests\Switzerland\Geneva; -use DateInterval; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\Provider\Switzerland\Geneva; use Yasumi\tests\HolidayTestCase; @@ -35,15 +31,15 @@ class JeuneGenevoisTest extends GenevaBaseTestCase implements HolidayTestCase /** * Tests Jeune Genevois between 1870 and 1965. * - * @throws Exception + * @throws \Exception */ public function testJeuneGenevoisBetween1870And1965(): void { $year = $this->generateRandomYear(1870, 1965); // Find first Sunday of September - $date = new DateTime('First Sunday of '.$year.'-09', new DateTimeZone(self::TIMEZONE)); + $date = new \DateTime('First Sunday of '.$year.'-09', new \DateTimeZone(self::TIMEZONE)); // Go to next Thursday - $date->add(new DateInterval('P4D')); + $date->add(new \DateInterval('P4D')); $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $date); $this->assertHolidayType(self::REGION, self::HOLIDAY, $year, Holiday::TYPE_OBSERVANCE); @@ -52,15 +48,15 @@ public function testJeuneGenevoisBetween1870And1965(): void /** * Tests Jeune Genevois between 1840 and 1869. * - * @throws Exception + * @throws \Exception */ public function testJeuneGenevoisBetween1840And1869(): void { $year = $this->generateRandomYear(Geneva::JEUNE_GENEVOIS_ESTABLISHMENT_YEAR, 1869); // Find first Sunday of September - $date = new DateTime('First Sunday of '.$year.'-09', new DateTimeZone(self::TIMEZONE)); + $date = new \DateTime('First Sunday of '.$year.'-09', new \DateTimeZone(self::TIMEZONE)); // Go to next Thursday - $date->add(new DateInterval('P4D')); + $date->add(new \DateInterval('P4D')); $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $date); $this->assertHolidayType(self::REGION, self::HOLIDAY, $year, Holiday::TYPE_OTHER); @@ -69,7 +65,7 @@ public function testJeuneGenevoisBetween1840And1869(): void /** * Tests Jeune Genevois before 1840. * - * @throws Exception + * @throws \Exception */ public function testJeuneGenevoisBefore1840(): void { @@ -80,7 +76,7 @@ public function testJeuneGenevoisBefore1840(): void /** * Tests translated name of Jeune Genevois. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -95,7 +91,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Geneva/NewYearsDayTest.php b/tests/Switzerland/Geneva/NewYearsDayTest.php index e484d6dc9..fa8538e07 100644 --- a/tests/Switzerland/Geneva/NewYearsDayTest.php +++ b/tests/Switzerland/Geneva/NewYearsDayTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\Switzerland\Geneva; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,8 +32,8 @@ class NewYearsDayTest extends GenevaBaseTestCase implements HolidayTestCase * * @dataProvider NewYearsDayDataProvider * - * @param int $year the year for which New Years Day needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which New Years Day needs to be tested + * @param \DateTime $expected the expected date */ public function testNewYearsDay(int $year, \DateTimeInterface $expected): void { @@ -45,7 +43,7 @@ public function testNewYearsDay(int $year, \DateTimeInterface $expected): void /** * Tests translated name of New Years Day. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -60,7 +58,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { @@ -72,7 +70,7 @@ public function testHolidayType(): void * * @return array list of test dates for New Years Day * - * @throws Exception + * @throws \Exception */ public function NewYearsDayDataProvider(): array { diff --git a/tests/Switzerland/Geneva/PentecostMondayTest.php b/tests/Switzerland/Geneva/PentecostMondayTest.php index 6a547dcbd..70a7d8e56 100644 --- a/tests/Switzerland/Geneva/PentecostMondayTest.php +++ b/tests/Switzerland/Geneva/PentecostMondayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Switzerland\Geneva; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -33,7 +30,7 @@ class PentecostMondayTest extends GenevaBaseTestCase implements HolidayTestCase /** * Tests Pentecost Monday. * - * @throws Exception + * @throws \Exception */ public function testPentecostMonday(): void { @@ -42,14 +39,14 @@ public function testPentecostMonday(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-5-30", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-5-30", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests translated name of Pentecost Monday. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -64,7 +61,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Geneva/RestaurationGenevoiseTest.php b/tests/Switzerland/Geneva/RestaurationGenevoiseTest.php index 94a7c9950..57e13e19b 100644 --- a/tests/Switzerland/Geneva/RestaurationGenevoiseTest.php +++ b/tests/Switzerland/Geneva/RestaurationGenevoiseTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Switzerland\Geneva; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -33,7 +30,7 @@ class RestaurationGenevoiseTest extends GenevaBaseTestCase implements HolidayTes /** * Tests Restauration Genevoise. * - * @throws Exception + * @throws \Exception */ public function testRestaurationGenevoiseAfter1813(): void { @@ -43,14 +40,14 @@ public function testRestaurationGenevoiseAfter1813(): void self::REGION, self::HOLIDAY, $year, - new DateTime($year.'-12-31', new DateTimeZone(self::TIMEZONE)) + new \DateTime($year.'-12-31', new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests translated name of Restauration Genevoise. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -65,7 +62,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Glarus/AllSaintsDayTest.php b/tests/Switzerland/Glarus/AllSaintsDayTest.php index 6055f2dca..1ab6f5f5d 100644 --- a/tests/Switzerland/Glarus/AllSaintsDayTest.php +++ b/tests/Switzerland/Glarus/AllSaintsDayTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\Switzerland\Glarus; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,8 +32,8 @@ class AllSaintsDayTest extends GlarusBaseTestCase implements HolidayTestCase * * @dataProvider AllSaintsDayDataProvider * - * @param int $year the year for which All Saints' Day needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which All Saints' Day needs to be tested + * @param \DateTime $expected the expected date */ public function testAllSaintsDay(int $year, \DateTimeInterface $expected): void { @@ -45,7 +43,7 @@ public function testAllSaintsDay(int $year, \DateTimeInterface $expected): void /** * Tests translated name of All Saints' Day. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -60,7 +58,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { @@ -72,7 +70,7 @@ public function testHolidayType(): void * * @return array list of test dates for All Saints' Day * - * @throws Exception + * @throws \Exception */ public function AllSaintsDayDataProvider(): array { diff --git a/tests/Switzerland/Glarus/AscensionDayTest.php b/tests/Switzerland/Glarus/AscensionDayTest.php index cb679fe65..258ebcc38 100644 --- a/tests/Switzerland/Glarus/AscensionDayTest.php +++ b/tests/Switzerland/Glarus/AscensionDayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Switzerland\Glarus; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -33,7 +30,7 @@ class AscensionDayTest extends GlarusBaseTestCase implements HolidayTestCase /** * Tests Ascension Day. * - * @throws Exception + * @throws \Exception */ public function testAscensionDay(): void { @@ -42,14 +39,14 @@ public function testAscensionDay(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-5-16", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-5-16", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests translated name of Ascension Day. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -64,7 +61,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Glarus/BerchtoldsTagTest.php b/tests/Switzerland/Glarus/BerchtoldsTagTest.php index 65f547647..225f586f9 100644 --- a/tests/Switzerland/Glarus/BerchtoldsTagTest.php +++ b/tests/Switzerland/Glarus/BerchtoldsTagTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Switzerland\Glarus; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -33,12 +30,12 @@ class BerchtoldsTagTest extends GlarusBaseTestCase implements HolidayTestCase /** * Tests BerchtoldsTag. * - * @throws Exception + * @throws \Exception */ public function testBerchtoldsTag(): void { $year = $this->generateRandomYear(); - $date = new DateTime($year.'-01-02', new DateTimeZone(self::TIMEZONE)); + $date = new \DateTime($year.'-01-02', new \DateTimeZone(self::TIMEZONE)); $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $date); $this->assertHolidayType(self::REGION, self::HOLIDAY, $year, Holiday::TYPE_OTHER); @@ -47,7 +44,7 @@ public function testBerchtoldsTag(): void /** * Tests translated name of BerchtoldsTag. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -62,7 +59,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Glarus/ChristmasDayTest.php b/tests/Switzerland/Glarus/ChristmasDayTest.php index a44c1c8bd..87e710972 100644 --- a/tests/Switzerland/Glarus/ChristmasDayTest.php +++ b/tests/Switzerland/Glarus/ChristmasDayTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\Switzerland\Glarus; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,8 +32,8 @@ class ChristmasDayTest extends GlarusBaseTestCase implements HolidayTestCase * * @dataProvider ChristmasDayDataProvider * - * @param int $year the year for which Christmas Day needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which Christmas Day needs to be tested + * @param \DateTime $expected the expected date */ public function testChristmasDay(int $year, \DateTimeInterface $expected): void { @@ -47,7 +45,7 @@ public function testChristmasDay(int $year, \DateTimeInterface $expected): void * * @return array list of test dates for Christmas Day * - * @throws Exception + * @throws \Exception */ public function ChristmasDayDataProvider(): array { @@ -57,7 +55,7 @@ public function ChristmasDayDataProvider(): array /** * Tests translated name of Christmas Day. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -72,7 +70,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Glarus/EasterMondayTest.php b/tests/Switzerland/Glarus/EasterMondayTest.php index 01695bcad..1f38117e6 100644 --- a/tests/Switzerland/Glarus/EasterMondayTest.php +++ b/tests/Switzerland/Glarus/EasterMondayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Switzerland\Glarus; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -33,7 +30,7 @@ class EasterMondayTest extends GlarusBaseTestCase implements HolidayTestCase /** * Tests Easter Monday. * - * @throws Exception + * @throws \Exception */ public function testEasterMonday(): void { @@ -42,14 +39,14 @@ public function testEasterMonday(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-3-28", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-3-28", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests translated name of Easter Monday. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -64,7 +61,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Glarus/GlarusTest.php b/tests/Switzerland/Glarus/GlarusTest.php index f545a7b83..f7459c134 100644 --- a/tests/Switzerland/Glarus/GlarusTest.php +++ b/tests/Switzerland/Glarus/GlarusTest.php @@ -14,7 +14,6 @@ namespace Yasumi\tests\Switzerland\Glarus; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\ProviderTestCase; @@ -107,7 +106,7 @@ public function testOtherHolidays(): void } /** - * @throws ReflectionException + * @throws \ReflectionException * @throws \Exception */ public function testSources(): void diff --git a/tests/Switzerland/Glarus/GoodFridayTest.php b/tests/Switzerland/Glarus/GoodFridayTest.php index 46f25f2be..2e2bcc0f5 100644 --- a/tests/Switzerland/Glarus/GoodFridayTest.php +++ b/tests/Switzerland/Glarus/GoodFridayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Switzerland\Glarus; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -33,7 +30,7 @@ class GoodFridayTest extends GlarusBaseTestCase implements HolidayTestCase /** * Tests the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHoliday(): void { @@ -42,14 +39,14 @@ public function testHoliday(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-3-21", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-3-21", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -64,7 +61,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Glarus/NafelserFahrtTest.php b/tests/Switzerland/Glarus/NafelserFahrtTest.php index 27ce99a41..0da90fa92 100644 --- a/tests/Switzerland/Glarus/NafelserFahrtTest.php +++ b/tests/Switzerland/Glarus/NafelserFahrtTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Switzerland\Glarus; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -38,12 +35,12 @@ class NafelserFahrtTest extends GlarusBaseTestCase implements HolidayTestCase /** * Tests Näfelser Fahrt on or after 1389. * - * @throws Exception + * @throws \Exception */ public function testNafelserFahrtOnAfter1389(): void { $year = $this->generateRandomYear(self::ESTABLISHMENT_YEAR); - $date = new DateTime('First Thursday of '.$year.'-04', new DateTimeZone(self::TIMEZONE)); + $date = new \DateTime('First Thursday of '.$year.'-04', new \DateTimeZone(self::TIMEZONE)); $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $date); } @@ -51,7 +48,7 @@ public function testNafelserFahrtOnAfter1389(): void /** * Tests Näfelser Fahrt before 1389. * - * @throws Exception + * @throws \Exception */ public function testNafelserFahrtBefore1389(): void { @@ -62,7 +59,7 @@ public function testNafelserFahrtBefore1389(): void /** * Tests translated name of Näfelser Fahrt. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -77,7 +74,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Glarus/NewYearsDayTest.php b/tests/Switzerland/Glarus/NewYearsDayTest.php index 6de323d91..e330973fa 100644 --- a/tests/Switzerland/Glarus/NewYearsDayTest.php +++ b/tests/Switzerland/Glarus/NewYearsDayTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\Switzerland\Glarus; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,8 +32,8 @@ class NewYearsDayTest extends GlarusBaseTestCase implements HolidayTestCase * * @dataProvider NewYearsDayDataProvider * - * @param int $year the year for which New Years Day needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which New Years Day needs to be tested + * @param \DateTime $expected the expected date */ public function testNewYearsDay(int $year, \DateTimeInterface $expected): void { @@ -45,7 +43,7 @@ public function testNewYearsDay(int $year, \DateTimeInterface $expected): void /** * Tests translated name of New Years Day. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -60,7 +58,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { @@ -72,7 +70,7 @@ public function testHolidayType(): void * * @return array list of test dates for New Years Day * - * @throws Exception + * @throws \Exception */ public function NewYearsDayDataProvider(): array { diff --git a/tests/Switzerland/Glarus/PentecostMondayTest.php b/tests/Switzerland/Glarus/PentecostMondayTest.php index 65cedcd95..22c47b7b9 100644 --- a/tests/Switzerland/Glarus/PentecostMondayTest.php +++ b/tests/Switzerland/Glarus/PentecostMondayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Switzerland\Glarus; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -33,7 +30,7 @@ class PentecostMondayTest extends GlarusBaseTestCase implements HolidayTestCase /** * Tests Pentecost Monday. * - * @throws Exception + * @throws \Exception */ public function testPentecostMonday(): void { @@ -42,14 +39,14 @@ public function testPentecostMonday(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-5-30", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-5-30", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests translated name of Pentecost Monday. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -64,7 +61,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Glarus/StStephensDayTest.php b/tests/Switzerland/Glarus/StStephensDayTest.php index 413349877..c791a0549 100644 --- a/tests/Switzerland/Glarus/StStephensDayTest.php +++ b/tests/Switzerland/Glarus/StStephensDayTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\Switzerland\Glarus; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,8 +32,8 @@ class StStephensDayTest extends GlarusBaseTestCase implements HolidayTestCase * * @dataProvider HolidayDataProvider * - * @param int $year the year for which the holiday defined in this test needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which the holiday defined in this test needs to be tested + * @param \DateTime $expected the expected date */ public function testHoliday(int $year, \DateTimeInterface $expected): void { @@ -47,7 +45,7 @@ public function testHoliday(int $year, \DateTimeInterface $expected): void * * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function HolidayDataProvider(): array { @@ -57,7 +55,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -72,7 +70,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Grisons/AscensionDayTest.php b/tests/Switzerland/Grisons/AscensionDayTest.php index ef6d8e7c2..0ff310a4f 100644 --- a/tests/Switzerland/Grisons/AscensionDayTest.php +++ b/tests/Switzerland/Grisons/AscensionDayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Switzerland\Grisons; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -33,7 +30,7 @@ class AscensionDayTest extends GrisonsBaseTestCase implements HolidayTestCase /** * Tests Ascension Day. * - * @throws Exception + * @throws \Exception */ public function testAscensionDay(): void { @@ -42,14 +39,14 @@ public function testAscensionDay(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-5-16", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-5-16", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests translated name of Ascension Day. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -64,7 +61,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Grisons/ChristmasDayTest.php b/tests/Switzerland/Grisons/ChristmasDayTest.php index 2f03b5894..efc431f70 100644 --- a/tests/Switzerland/Grisons/ChristmasDayTest.php +++ b/tests/Switzerland/Grisons/ChristmasDayTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\Switzerland\Grisons; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,8 +32,8 @@ class ChristmasDayTest extends GrisonsBaseTestCase implements HolidayTestCase * * @dataProvider ChristmasDayDataProvider * - * @param int $year the year for which Christmas Day needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which Christmas Day needs to be tested + * @param \DateTime $expected the expected date */ public function testChristmasDay(int $year, \DateTimeInterface $expected): void { @@ -47,7 +45,7 @@ public function testChristmasDay(int $year, \DateTimeInterface $expected): void * * @return array list of test dates for Christmas Day * - * @throws Exception + * @throws \Exception */ public function ChristmasDayDataProvider(): array { @@ -57,7 +55,7 @@ public function ChristmasDayDataProvider(): array /** * Tests translated name of Christmas Day. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -72,7 +70,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Grisons/EasterMondayTest.php b/tests/Switzerland/Grisons/EasterMondayTest.php index 457fcded1..9ddd06adf 100644 --- a/tests/Switzerland/Grisons/EasterMondayTest.php +++ b/tests/Switzerland/Grisons/EasterMondayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Switzerland\Grisons; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -33,7 +30,7 @@ class EasterMondayTest extends GrisonsBaseTestCase implements HolidayTestCase /** * Tests Easter Monday. * - * @throws Exception + * @throws \Exception */ public function testEasterMonday(): void { @@ -42,14 +39,14 @@ public function testEasterMonday(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-3-28", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-3-28", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests translated name of Easter Monday. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -64,7 +61,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Grisons/GoodFridayTest.php b/tests/Switzerland/Grisons/GoodFridayTest.php index f4e46e512..a6e5f456d 100644 --- a/tests/Switzerland/Grisons/GoodFridayTest.php +++ b/tests/Switzerland/Grisons/GoodFridayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Switzerland\Grisons; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -33,7 +30,7 @@ class GoodFridayTest extends GrisonsBaseTestCase implements HolidayTestCase /** * Tests the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHoliday(): void { @@ -42,14 +39,14 @@ public function testHoliday(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-3-21", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-3-21", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -64,7 +61,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Grisons/GrisonsTest.php b/tests/Switzerland/Grisons/GrisonsTest.php index f9098036f..082153069 100644 --- a/tests/Switzerland/Grisons/GrisonsTest.php +++ b/tests/Switzerland/Grisons/GrisonsTest.php @@ -14,7 +14,6 @@ namespace Yasumi\tests\Switzerland\Grisons; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\ProviderTestCase; @@ -104,7 +103,7 @@ public function testOtherHolidays(): void } /** - * @throws ReflectionException + * @throws \ReflectionException * @throws \Exception */ public function testSources(): void diff --git a/tests/Switzerland/Grisons/NewYearsDayTest.php b/tests/Switzerland/Grisons/NewYearsDayTest.php index eecb9310b..653e299a1 100644 --- a/tests/Switzerland/Grisons/NewYearsDayTest.php +++ b/tests/Switzerland/Grisons/NewYearsDayTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\Switzerland\Grisons; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,8 +32,8 @@ class NewYearsDayTest extends GrisonsBaseTestCase implements HolidayTestCase * * @dataProvider NewYearsDayDataProvider * - * @param int $year the year for which New Years Day needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which New Years Day needs to be tested + * @param \DateTime $expected the expected date */ public function testNewYearsDay(int $year, \DateTimeInterface $expected): void { @@ -45,7 +43,7 @@ public function testNewYearsDay(int $year, \DateTimeInterface $expected): void /** * Tests translated name of New Years Day. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -60,7 +58,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { @@ -72,7 +70,7 @@ public function testHolidayType(): void * * @return array list of test dates for New Years Day * - * @throws Exception + * @throws \Exception */ public function NewYearsDayDataProvider(): array { diff --git a/tests/Switzerland/Grisons/PentecostMondayTest.php b/tests/Switzerland/Grisons/PentecostMondayTest.php index 61e3a33b2..44cfc77a3 100644 --- a/tests/Switzerland/Grisons/PentecostMondayTest.php +++ b/tests/Switzerland/Grisons/PentecostMondayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Switzerland\Grisons; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -33,7 +30,7 @@ class PentecostMondayTest extends GrisonsBaseTestCase implements HolidayTestCase /** * Tests Pentecost Monday. * - * @throws Exception + * @throws \Exception */ public function testPentecostMonday(): void { @@ -42,14 +39,14 @@ public function testPentecostMonday(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-5-30", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-5-30", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests translated name of Pentecost Monday. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -64,7 +61,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Grisons/StStephensDayTest.php b/tests/Switzerland/Grisons/StStephensDayTest.php index e2dddfaf8..8f955b6e8 100644 --- a/tests/Switzerland/Grisons/StStephensDayTest.php +++ b/tests/Switzerland/Grisons/StStephensDayTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\Switzerland\Grisons; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,8 +32,8 @@ class StStephensDayTest extends GrisonsBaseTestCase implements HolidayTestCase * * @dataProvider HolidayDataProvider * - * @param int $year the year for which the holiday defined in this test needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which the holiday defined in this test needs to be tested + * @param \DateTime $expected the expected date */ public function testHoliday(int $year, \DateTimeInterface $expected): void { @@ -47,7 +45,7 @@ public function testHoliday(int $year, \DateTimeInterface $expected): void * * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function HolidayDataProvider(): array { @@ -57,7 +55,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -72,7 +70,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Jura/AllSaintsDayTest.php b/tests/Switzerland/Jura/AllSaintsDayTest.php index 8c678ff60..77e6b84be 100644 --- a/tests/Switzerland/Jura/AllSaintsDayTest.php +++ b/tests/Switzerland/Jura/AllSaintsDayTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\Switzerland\Jura; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,8 +32,8 @@ class AllSaintsDayTest extends JuraBaseTestCase implements HolidayTestCase * * @dataProvider AllSaintsDayDataProvider * - * @param int $year the year for which All Saints' Day needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which All Saints' Day needs to be tested + * @param \DateTime $expected the expected date */ public function testAllSaintsDay(int $year, \DateTimeInterface $expected): void { @@ -45,7 +43,7 @@ public function testAllSaintsDay(int $year, \DateTimeInterface $expected): void /** * Tests translated name of All Saints' Day. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -60,7 +58,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { @@ -72,7 +70,7 @@ public function testHolidayType(): void * * @return array list of test dates for All Saints' Day * - * @throws Exception + * @throws \Exception */ public function AllSaintsDayDataProvider(): array { diff --git a/tests/Switzerland/Jura/AscensionDayTest.php b/tests/Switzerland/Jura/AscensionDayTest.php index dc6a7e892..2bfbfbf14 100644 --- a/tests/Switzerland/Jura/AscensionDayTest.php +++ b/tests/Switzerland/Jura/AscensionDayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Switzerland\Jura; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -33,7 +30,7 @@ class AscensionDayTest extends JuraBaseTestCase implements HolidayTestCase /** * Tests Ascension Day. * - * @throws Exception + * @throws \Exception */ public function testAscensionDay(): void { @@ -42,14 +39,14 @@ public function testAscensionDay(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-5-16", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-5-16", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests translated name of Ascension Day. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -64,7 +61,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Jura/AssumptionOfMaryTest.php b/tests/Switzerland/Jura/AssumptionOfMaryTest.php index efe5931e2..a111053ef 100644 --- a/tests/Switzerland/Jura/AssumptionOfMaryTest.php +++ b/tests/Switzerland/Jura/AssumptionOfMaryTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\Switzerland\Jura; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,8 +32,8 @@ class AssumptionOfMaryTest extends JuraBaseTestCase implements HolidayTestCase * * @dataProvider AssumptionOfMaryDataProvider * - * @param int $year the year for which the day of the Assumption of Mary needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which the day of the Assumption of Mary needs to be tested + * @param \DateTime $expected the expected date */ public function testAssumptionOfMary(int $year, \DateTimeInterface $expected): void { @@ -45,7 +43,7 @@ public function testAssumptionOfMary(int $year, \DateTimeInterface $expected): v /** * Tests translated name of the day of the Assumption of Mary. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -60,7 +58,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { @@ -72,7 +70,7 @@ public function testHolidayType(): void * * @return array list of test dates for the day of the Assumption of Mary * - * @throws Exception + * @throws \Exception */ public function AssumptionOfMaryDataProvider(): array { diff --git a/tests/Switzerland/Jura/BerchtoldsTagTest.php b/tests/Switzerland/Jura/BerchtoldsTagTest.php index 2d3c7c6a7..8e2fb57d4 100644 --- a/tests/Switzerland/Jura/BerchtoldsTagTest.php +++ b/tests/Switzerland/Jura/BerchtoldsTagTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Switzerland\Jura; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -33,12 +30,12 @@ class BerchtoldsTagTest extends JuraBaseTestCase implements HolidayTestCase /** * Tests BerchtoldsTag. * - * @throws Exception + * @throws \Exception */ public function testBerchtoldsTag(): void { $year = $this->generateRandomYear(); - $date = new DateTime($year.'-01-02', new DateTimeZone(self::TIMEZONE)); + $date = new \DateTime($year.'-01-02', new \DateTimeZone(self::TIMEZONE)); $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $date); $this->assertHolidayType(self::REGION, self::HOLIDAY, $year, Holiday::TYPE_OTHER); @@ -47,7 +44,7 @@ public function testBerchtoldsTag(): void /** * Tests translated name of BerchtoldsTag. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -62,7 +59,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Jura/BettagsMontagTest.php b/tests/Switzerland/Jura/BettagsMontagTest.php index b5d47655a..b87d850c5 100644 --- a/tests/Switzerland/Jura/BettagsMontagTest.php +++ b/tests/Switzerland/Jura/BettagsMontagTest.php @@ -14,10 +14,6 @@ namespace Yasumi\tests\Switzerland\Jura; -use DateInterval; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,16 +30,16 @@ class BettagsMontagTest extends JuraBaseTestCase implements HolidayTestCase /** * Tests Bettags Montag on or after 1832. * - * @throws Exception + * @throws \Exception */ public function testBettagsMontagOnAfter1832(): void { $year = $this->generateRandomYear(1832); // Find third Sunday of September - $date = new DateTime('Third Sunday of '.$year.'-09', new DateTimeZone(self::TIMEZONE)); + $date = new \DateTime('Third Sunday of '.$year.'-09', new \DateTimeZone(self::TIMEZONE)); // Go to next Thursday - $date->add(new DateInterval('P1D')); + $date->add(new \DateInterval('P1D')); $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $date); } @@ -51,7 +47,7 @@ public function testBettagsMontagOnAfter1832(): void /** * Tests Bettags Montag before 1832. * - * @throws Exception + * @throws \Exception */ public function testBettagsMontagBefore1832(): void { @@ -62,7 +58,7 @@ public function testBettagsMontagBefore1832(): void /** * Tests translated name of Bettags Montag. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -77,7 +73,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Jura/ChristmasDayTest.php b/tests/Switzerland/Jura/ChristmasDayTest.php index f81de2386..a52f14cad 100644 --- a/tests/Switzerland/Jura/ChristmasDayTest.php +++ b/tests/Switzerland/Jura/ChristmasDayTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\Switzerland\Jura; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,8 +32,8 @@ class ChristmasDayTest extends JuraBaseTestCase implements HolidayTestCase * * @dataProvider ChristmasDayDataProvider * - * @param int $year the year for which Christmas Day needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which Christmas Day needs to be tested + * @param \DateTime $expected the expected date */ public function testChristmasDay(int $year, \DateTimeInterface $expected): void { @@ -47,7 +45,7 @@ public function testChristmasDay(int $year, \DateTimeInterface $expected): void * * @return array list of test dates for Christmas Day * - * @throws Exception + * @throws \Exception */ public function ChristmasDayDataProvider(): array { @@ -57,7 +55,7 @@ public function ChristmasDayDataProvider(): array /** * Tests translated name of Christmas Day. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -72,7 +70,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Jura/CorpusChristiTest.php b/tests/Switzerland/Jura/CorpusChristiTest.php index 2275752de..014d1255e 100644 --- a/tests/Switzerland/Jura/CorpusChristiTest.php +++ b/tests/Switzerland/Jura/CorpusChristiTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\Switzerland\Jura; -use DateInterval; -use Exception; use Yasumi\Holiday; use Yasumi\Provider\ChristianHolidays; use Yasumi\tests\HolidayTestCase; @@ -35,7 +33,7 @@ class CorpusChristiTest extends JuraBaseTestCase implements HolidayTestCase /** * Tests Corpus Christi. * - * @throws Exception + * @throws \Exception */ public function testCorpusChristi(): void { @@ -44,14 +42,14 @@ public function testCorpusChristi(): void self::REGION, self::HOLIDAY, $year, - $this->calculateEaster($year, self::TIMEZONE)->add(new DateInterval('P60D')) + $this->calculateEaster($year, self::TIMEZONE)->add(new \DateInterval('P60D')) ); } /** * Tests translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -66,7 +64,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Jura/EasterMondayTest.php b/tests/Switzerland/Jura/EasterMondayTest.php index 6e227c418..66376f108 100644 --- a/tests/Switzerland/Jura/EasterMondayTest.php +++ b/tests/Switzerland/Jura/EasterMondayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Switzerland\Jura; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -33,7 +30,7 @@ class EasterMondayTest extends JuraBaseTestCase implements HolidayTestCase /** * Tests Easter Monday. * - * @throws Exception + * @throws \Exception */ public function testEasterMonday(): void { @@ -42,14 +39,14 @@ public function testEasterMonday(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-3-28", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-3-28", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests translated name of Easter Monday. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -64,7 +61,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Jura/EasterTest.php b/tests/Switzerland/Jura/EasterTest.php index 99b5eef91..006c6835a 100644 --- a/tests/Switzerland/Jura/EasterTest.php +++ b/tests/Switzerland/Jura/EasterTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Switzerland\Jura; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -33,7 +30,7 @@ class EasterTest extends JuraBaseTestCase implements HolidayTestCase /** * Tests the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHoliday(): void { @@ -42,14 +39,14 @@ public function testHoliday(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-4-12", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-4-12", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -64,7 +61,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Jura/GoodFridayTest.php b/tests/Switzerland/Jura/GoodFridayTest.php index 007849631..943256070 100644 --- a/tests/Switzerland/Jura/GoodFridayTest.php +++ b/tests/Switzerland/Jura/GoodFridayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Switzerland\Jura; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -33,7 +30,7 @@ class GoodFridayTest extends JuraBaseTestCase implements HolidayTestCase /** * Tests the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHoliday(): void { @@ -42,14 +39,14 @@ public function testHoliday(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-3-21", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-3-21", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -64,7 +61,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Jura/JuraTest.php b/tests/Switzerland/Jura/JuraTest.php index 92c329d10..ddb8e185a 100644 --- a/tests/Switzerland/Jura/JuraTest.php +++ b/tests/Switzerland/Jura/JuraTest.php @@ -14,7 +14,6 @@ namespace Yasumi\tests\Switzerland\Jura; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\ProviderTestCase; @@ -112,7 +111,7 @@ public function testOtherHolidays(): void } /** - * @throws ReflectionException + * @throws \ReflectionException * @throws \Exception */ public function testSources(): void diff --git a/tests/Switzerland/Jura/NewYearsDayTest.php b/tests/Switzerland/Jura/NewYearsDayTest.php index 3d22a0acb..79b79212a 100644 --- a/tests/Switzerland/Jura/NewYearsDayTest.php +++ b/tests/Switzerland/Jura/NewYearsDayTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\Switzerland\Jura; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,8 +32,8 @@ class NewYearsDayTest extends JuraBaseTestCase implements HolidayTestCase * * @dataProvider NewYearsDayDataProvider * - * @param int $year the year for which New Years Day needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which New Years Day needs to be tested + * @param \DateTime $expected the expected date */ public function testNewYearsDay(int $year, \DateTimeInterface $expected): void { @@ -45,7 +43,7 @@ public function testNewYearsDay(int $year, \DateTimeInterface $expected): void /** * Tests translated name of New Years Day. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -60,7 +58,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { @@ -72,7 +70,7 @@ public function testHolidayType(): void * * @return array list of test dates for New Years Day * - * @throws Exception + * @throws \Exception */ public function NewYearsDayDataProvider(): array { diff --git a/tests/Switzerland/Jura/PentecostMondayTest.php b/tests/Switzerland/Jura/PentecostMondayTest.php index 790dcf51b..cbb75b646 100644 --- a/tests/Switzerland/Jura/PentecostMondayTest.php +++ b/tests/Switzerland/Jura/PentecostMondayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Switzerland\Jura; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -33,7 +30,7 @@ class PentecostMondayTest extends JuraBaseTestCase implements HolidayTestCase /** * Tests Pentecost Monday. * - * @throws Exception + * @throws \Exception */ public function testPentecostMonday(): void { @@ -42,14 +39,14 @@ public function testPentecostMonday(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-5-30", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-5-30", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests translated name of Pentecost Monday. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -64,7 +61,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Jura/PentecostTest.php b/tests/Switzerland/Jura/PentecostTest.php index 82b49296d..f39a1bba5 100644 --- a/tests/Switzerland/Jura/PentecostTest.php +++ b/tests/Switzerland/Jura/PentecostTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Switzerland\Jura; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -33,7 +30,7 @@ class PentecostTest extends JuraBaseTestCase implements HolidayTestCase /** * Tests the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHoliday(): void { @@ -42,14 +39,14 @@ public function testHoliday(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-5-23", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-5-23", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -64,7 +61,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Jura/PlebisciteJurassienTest.php b/tests/Switzerland/Jura/PlebisciteJurassienTest.php index 1da9b798b..a75c4c921 100644 --- a/tests/Switzerland/Jura/PlebisciteJurassienTest.php +++ b/tests/Switzerland/Jura/PlebisciteJurassienTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Switzerland\Jura; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -38,7 +35,7 @@ class PlebisciteJurassienTest extends JuraBaseTestCase implements HolidayTestCas /** * Tests Plébiscite jurassien on or after 1975. * - * @throws Exception + * @throws \Exception */ public function testInstaurationRepubliqueOnAfter1975(): void { @@ -47,14 +44,14 @@ public function testInstaurationRepubliqueOnAfter1975(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-06-23", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-06-23", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests Plébiscite jurassien before 1975. * - * @throws Exception + * @throws \Exception */ public function testInstaurationRepubliqueBefore1975(): void { @@ -68,7 +65,7 @@ public function testInstaurationRepubliqueBefore1975(): void /** * Tests translated name of Plébiscite jurassien. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -83,7 +80,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Jura/WorkersDayTest.php b/tests/Switzerland/Jura/WorkersDayTest.php index ac2991b8b..8a3d6407e 100644 --- a/tests/Switzerland/Jura/WorkersDayTest.php +++ b/tests/Switzerland/Jura/WorkersDayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Switzerland\Jura; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -38,11 +35,11 @@ class WorkersDayTest extends JuraBaseTestCase implements HolidayTestCase * @param int $year the year for which the holiday defined in this test needs to be tested * @param string $expected the expected date * - * @throws Exception + * @throws \Exception */ public function testHoliday(int $year, string $expected): void { - $date = new DateTime($expected, new DateTimeZone(self::TIMEZONE)); + $date = new \DateTime($expected, new \DateTimeZone(self::TIMEZONE)); $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $date); } @@ -51,7 +48,7 @@ public function testHoliday(int $year, string $expected): void * * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function HolidayDataProvider(): array { @@ -59,7 +56,7 @@ public function HolidayDataProvider(): array for ($y = 0; $y < 50; ++$y) { $year = $this->generateRandomYear(); - $date = new DateTime("$year-5-1", new DateTimeZone(self::TIMEZONE)); + $date = new \DateTime("$year-5-1", new \DateTimeZone(self::TIMEZONE)); $data[] = [$year, $date->format('Y-m-d')]; } @@ -69,7 +66,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -84,7 +81,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Lucerne/AllSaintsDayTest.php b/tests/Switzerland/Lucerne/AllSaintsDayTest.php index d3f23ade5..2cf38b814 100644 --- a/tests/Switzerland/Lucerne/AllSaintsDayTest.php +++ b/tests/Switzerland/Lucerne/AllSaintsDayTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\Switzerland\Lucerne; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,8 +32,8 @@ class AllSaintsDayTest extends LucerneBaseTestCase implements HolidayTestCase * * @dataProvider AllSaintsDayDataProvider * - * @param int $year the year for which All Saints' Day needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which All Saints' Day needs to be tested + * @param \DateTime $expected the expected date */ public function testAllSaintsDay(int $year, \DateTimeInterface $expected): void { @@ -45,7 +43,7 @@ public function testAllSaintsDay(int $year, \DateTimeInterface $expected): void /** * Tests translated name of All Saints' Day. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -60,7 +58,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { @@ -72,7 +70,7 @@ public function testHolidayType(): void * * @return array list of test dates for All Saints' Day * - * @throws Exception + * @throws \Exception */ public function AllSaintsDayDataProvider(): array { diff --git a/tests/Switzerland/Lucerne/AscensionDayTest.php b/tests/Switzerland/Lucerne/AscensionDayTest.php index 6ab3eea6b..5b7572a82 100644 --- a/tests/Switzerland/Lucerne/AscensionDayTest.php +++ b/tests/Switzerland/Lucerne/AscensionDayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Switzerland\Lucerne; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -33,7 +30,7 @@ class AscensionDayTest extends LucerneBaseTestCase implements HolidayTestCase /** * Tests Ascension Day. * - * @throws Exception + * @throws \Exception */ public function testAscensionDay(): void { @@ -42,14 +39,14 @@ public function testAscensionDay(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-5-16", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-5-16", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests translated name of Ascension Day. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -64,7 +61,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Lucerne/AssumptionOfMaryTest.php b/tests/Switzerland/Lucerne/AssumptionOfMaryTest.php index b94a4ed2f..28b98f0a8 100644 --- a/tests/Switzerland/Lucerne/AssumptionOfMaryTest.php +++ b/tests/Switzerland/Lucerne/AssumptionOfMaryTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\Switzerland\Lucerne; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,8 +32,8 @@ class AssumptionOfMaryTest extends LucerneBaseTestCase implements HolidayTestCas * * @dataProvider AssumptionOfMaryDataProvider * - * @param int $year the year for which the day of the Assumption of Mary needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which the day of the Assumption of Mary needs to be tested + * @param \DateTime $expected the expected date */ public function testAssumptionOfMary(int $year, \DateTimeInterface $expected): void { @@ -45,7 +43,7 @@ public function testAssumptionOfMary(int $year, \DateTimeInterface $expected): v /** * Tests translated name of the day of the Assumption of Mary. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -60,7 +58,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { @@ -72,7 +70,7 @@ public function testHolidayType(): void * * @return array list of test dates for the day of the Assumption of Mary * - * @throws Exception + * @throws \Exception */ public function AssumptionOfMaryDataProvider(): array { diff --git a/tests/Switzerland/Lucerne/BerchtoldsTagTest.php b/tests/Switzerland/Lucerne/BerchtoldsTagTest.php index d92c078a5..ae32179f4 100644 --- a/tests/Switzerland/Lucerne/BerchtoldsTagTest.php +++ b/tests/Switzerland/Lucerne/BerchtoldsTagTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Switzerland\Lucerne; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -33,12 +30,12 @@ class BerchtoldsTagTest extends LucerneBaseTestCase implements HolidayTestCase /** * Tests BerchtoldsTag. * - * @throws Exception + * @throws \Exception */ public function testBerchtoldsTag(): void { $year = $this->generateRandomYear(); - $date = new DateTime($year.'-01-02', new DateTimeZone(self::TIMEZONE)); + $date = new \DateTime($year.'-01-02', new \DateTimeZone(self::TIMEZONE)); $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $date); $this->assertHolidayType(self::REGION, self::HOLIDAY, $year, Holiday::TYPE_OTHER); @@ -47,7 +44,7 @@ public function testBerchtoldsTag(): void /** * Tests translated name of BerchtoldsTag. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -62,7 +59,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Lucerne/ChristmasDayTest.php b/tests/Switzerland/Lucerne/ChristmasDayTest.php index 8bef33955..560adad8a 100644 --- a/tests/Switzerland/Lucerne/ChristmasDayTest.php +++ b/tests/Switzerland/Lucerne/ChristmasDayTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\Switzerland\Lucerne; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,8 +32,8 @@ class ChristmasDayTest extends LucerneBaseTestCase implements HolidayTestCase * * @dataProvider ChristmasDayDataProvider * - * @param int $year the year for which Christmas Day needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which Christmas Day needs to be tested + * @param \DateTime $expected the expected date */ public function testChristmasDay(int $year, \DateTimeInterface $expected): void { @@ -47,7 +45,7 @@ public function testChristmasDay(int $year, \DateTimeInterface $expected): void * * @return array list of test dates for Christmas Day * - * @throws Exception + * @throws \Exception */ public function ChristmasDayDataProvider(): array { @@ -57,7 +55,7 @@ public function ChristmasDayDataProvider(): array /** * Tests translated name of Christmas Day. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -72,7 +70,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Lucerne/CorpusChristiTest.php b/tests/Switzerland/Lucerne/CorpusChristiTest.php index 9abf07f8c..e092b5c07 100644 --- a/tests/Switzerland/Lucerne/CorpusChristiTest.php +++ b/tests/Switzerland/Lucerne/CorpusChristiTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\Switzerland\Lucerne; -use DateInterval; -use Exception; use Yasumi\Holiday; use Yasumi\Provider\ChristianHolidays; use Yasumi\tests\HolidayTestCase; @@ -35,7 +33,7 @@ class CorpusChristiTest extends LucerneBaseTestCase implements HolidayTestCase /** * Tests Corpus Christi. * - * @throws Exception + * @throws \Exception */ public function testCorpusChristi(): void { @@ -44,14 +42,14 @@ public function testCorpusChristi(): void self::REGION, self::HOLIDAY, $year, - $this->calculateEaster($year, self::TIMEZONE)->add(new DateInterval('P60D')) + $this->calculateEaster($year, self::TIMEZONE)->add(new \DateInterval('P60D')) ); } /** * Tests translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -66,7 +64,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Lucerne/EasterMondayTest.php b/tests/Switzerland/Lucerne/EasterMondayTest.php index 3eba31f36..8322a4392 100644 --- a/tests/Switzerland/Lucerne/EasterMondayTest.php +++ b/tests/Switzerland/Lucerne/EasterMondayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Switzerland\Lucerne; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -33,7 +30,7 @@ class EasterMondayTest extends LucerneBaseTestCase implements HolidayTestCase /** * Tests Easter Monday. * - * @throws Exception + * @throws \Exception */ public function testEasterMonday(): void { @@ -42,14 +39,14 @@ public function testEasterMonday(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-3-28", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-3-28", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests translated name of Easter Monday. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -64,7 +61,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Lucerne/GoodFridayTest.php b/tests/Switzerland/Lucerne/GoodFridayTest.php index 9b23bfda8..721a8ca14 100644 --- a/tests/Switzerland/Lucerne/GoodFridayTest.php +++ b/tests/Switzerland/Lucerne/GoodFridayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Switzerland\Lucerne; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -33,7 +30,7 @@ class GoodFridayTest extends LucerneBaseTestCase implements HolidayTestCase /** * Tests the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHoliday(): void { @@ -42,14 +39,14 @@ public function testHoliday(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-3-21", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-3-21", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -64,7 +61,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Lucerne/ImmaculateConceptionTest.php b/tests/Switzerland/Lucerne/ImmaculateConceptionTest.php index 6f17a77e8..18b2d49ce 100644 --- a/tests/Switzerland/Lucerne/ImmaculateConceptionTest.php +++ b/tests/Switzerland/Lucerne/ImmaculateConceptionTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\Switzerland\Lucerne; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,8 +32,8 @@ class ImmaculateConceptionTest extends LucerneBaseTestCase implements HolidayTes * * @dataProvider HolidayDataProvider * - * @param int $year the year for which the holiday defined in this test needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which the holiday defined in this test needs to be tested + * @param \DateTime $expected the expected date */ public function testHoliday(int $year, \DateTimeInterface $expected): void { @@ -47,7 +45,7 @@ public function testHoliday(int $year, \DateTimeInterface $expected): void * * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function HolidayDataProvider(): array { @@ -57,7 +55,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -72,7 +70,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Lucerne/LucerneTest.php b/tests/Switzerland/Lucerne/LucerneTest.php index f9b78d4cb..4dff39c80 100644 --- a/tests/Switzerland/Lucerne/LucerneTest.php +++ b/tests/Switzerland/Lucerne/LucerneTest.php @@ -14,7 +14,6 @@ namespace Yasumi\tests\Switzerland\Lucerne; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\ProviderTestCase; @@ -109,7 +108,7 @@ public function testOtherHolidays(): void } /** - * @throws ReflectionException + * @throws \ReflectionException * @throws \Exception */ public function testSources(): void diff --git a/tests/Switzerland/Lucerne/NewYearsDayTest.php b/tests/Switzerland/Lucerne/NewYearsDayTest.php index 55e8fd612..7b69cc6cc 100644 --- a/tests/Switzerland/Lucerne/NewYearsDayTest.php +++ b/tests/Switzerland/Lucerne/NewYearsDayTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\Switzerland\Lucerne; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,8 +32,8 @@ class NewYearsDayTest extends LucerneBaseTestCase implements HolidayTestCase * * @dataProvider NewYearsDayDataProvider * - * @param int $year the year for which New Years Day needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which New Years Day needs to be tested + * @param \DateTime $expected the expected date */ public function testNewYearsDay(int $year, \DateTimeInterface $expected): void { @@ -45,7 +43,7 @@ public function testNewYearsDay(int $year, \DateTimeInterface $expected): void /** * Tests translated name of New Years Day. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -60,7 +58,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { @@ -72,7 +70,7 @@ public function testHolidayType(): void * * @return array list of test dates for New Years Day * - * @throws Exception + * @throws \Exception */ public function NewYearsDayDataProvider(): array { diff --git a/tests/Switzerland/Lucerne/PentecostMondayTest.php b/tests/Switzerland/Lucerne/PentecostMondayTest.php index 14d3c2d78..71ab69c22 100644 --- a/tests/Switzerland/Lucerne/PentecostMondayTest.php +++ b/tests/Switzerland/Lucerne/PentecostMondayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Switzerland\Lucerne; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -33,7 +30,7 @@ class PentecostMondayTest extends LucerneBaseTestCase implements HolidayTestCase /** * Tests Pentecost Monday. * - * @throws Exception + * @throws \Exception */ public function testPentecostMonday(): void { @@ -42,14 +39,14 @@ public function testPentecostMonday(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-5-30", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-5-30", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests translated name of Pentecost Monday. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -64,7 +61,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Lucerne/StStephensDayTest.php b/tests/Switzerland/Lucerne/StStephensDayTest.php index a331953a0..153e352b3 100644 --- a/tests/Switzerland/Lucerne/StStephensDayTest.php +++ b/tests/Switzerland/Lucerne/StStephensDayTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\Switzerland\Lucerne; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,8 +32,8 @@ class StStephensDayTest extends LucerneBaseTestCase implements HolidayTestCase * * @dataProvider HolidayDataProvider * - * @param int $year the year for which the holiday defined in this test needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which the holiday defined in this test needs to be tested + * @param \DateTime $expected the expected date */ public function testHoliday(int $year, \DateTimeInterface $expected): void { @@ -47,7 +45,7 @@ public function testHoliday(int $year, \DateTimeInterface $expected): void * * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function HolidayDataProvider(): array { @@ -57,7 +55,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -72,7 +70,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Neuchatel/AscensionDayTest.php b/tests/Switzerland/Neuchatel/AscensionDayTest.php index 08d5d9364..5dfda0cae 100644 --- a/tests/Switzerland/Neuchatel/AscensionDayTest.php +++ b/tests/Switzerland/Neuchatel/AscensionDayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Switzerland\Neuchatel; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -33,7 +30,7 @@ class AscensionDayTest extends NeuchatelBaseTestCase implements HolidayTestCase /** * Tests Ascension Day. * - * @throws Exception + * @throws \Exception */ public function testAscensionDay(): void { @@ -42,14 +39,14 @@ public function testAscensionDay(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-5-16", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-5-16", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests translated name of Ascension Day. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -64,7 +61,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Neuchatel/BettagsMontagTest.php b/tests/Switzerland/Neuchatel/BettagsMontagTest.php index d0ab6cc20..3c4435cd3 100644 --- a/tests/Switzerland/Neuchatel/BettagsMontagTest.php +++ b/tests/Switzerland/Neuchatel/BettagsMontagTest.php @@ -14,10 +14,6 @@ namespace Yasumi\tests\Switzerland\Neuchatel; -use DateInterval; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,16 +30,16 @@ class BettagsMontagTest extends NeuchatelBaseTestCase implements HolidayTestCase /** * Tests Bettags Montag on or after 1832. * - * @throws Exception + * @throws \Exception */ public function testBettagsMontagOnAfter1832(): void { $year = $this->generateRandomYear(1832); // Find third Sunday of September - $date = new DateTime('Third Sunday of '.$year.'-09', new DateTimeZone(self::TIMEZONE)); + $date = new \DateTime('Third Sunday of '.$year.'-09', new \DateTimeZone(self::TIMEZONE)); // Go to next Thursday - $date->add(new DateInterval('P1D')); + $date->add(new \DateInterval('P1D')); $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $date); } @@ -51,7 +47,7 @@ public function testBettagsMontagOnAfter1832(): void /** * Tests Bettags Montag before 1832. * - * @throws Exception + * @throws \Exception */ public function testBettagsMontagBefore1832(): void { @@ -62,7 +58,7 @@ public function testBettagsMontagBefore1832(): void /** * Tests translated name of Bettags Montag. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -77,7 +73,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Neuchatel/ChristmasDayTest.php b/tests/Switzerland/Neuchatel/ChristmasDayTest.php index 8af9393d3..23a0944a3 100644 --- a/tests/Switzerland/Neuchatel/ChristmasDayTest.php +++ b/tests/Switzerland/Neuchatel/ChristmasDayTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\Switzerland\Neuchatel; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,8 +32,8 @@ class ChristmasDayTest extends NeuchatelBaseTestCase implements HolidayTestCase * * @dataProvider ChristmasDayDataProvider * - * @param int $year the year for which Christmas Day needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which Christmas Day needs to be tested + * @param \DateTime $expected the expected date */ public function testChristmasDay(int $year, \DateTimeInterface $expected): void { @@ -47,7 +45,7 @@ public function testChristmasDay(int $year, \DateTimeInterface $expected): void * * @return array list of test dates for Christmas Day * - * @throws Exception + * @throws \Exception */ public function ChristmasDayDataProvider(): array { @@ -57,7 +55,7 @@ public function ChristmasDayDataProvider(): array /** * Tests translated name of Christmas Day. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -72,7 +70,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Neuchatel/December26thTest.php b/tests/Switzerland/Neuchatel/December26thTest.php index 6fe797816..fbe193be4 100644 --- a/tests/Switzerland/Neuchatel/December26thTest.php +++ b/tests/Switzerland/Neuchatel/December26thTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Switzerland\Neuchatel; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -38,7 +35,7 @@ class December26thTest extends NeuchatelBaseTestCase implements HolidayTestCase /** * Tests December 26th. * - * @throws Exception + * @throws \Exception */ public function testDecember26th(): void { @@ -46,7 +43,7 @@ public function testDecember26th(): void self::REGION, self::HOLIDAY, self::OBSERVANCE_YEAR, - new DateTime(self::OBSERVANCE_YEAR.'-12-26', new DateTimeZone(self::TIMEZONE)) + new \DateTime(self::OBSERVANCE_YEAR.'-12-26', new \DateTimeZone(self::TIMEZONE)) ); $this->assertNotHoliday( self::REGION, diff --git a/tests/Switzerland/Neuchatel/EasterMondayTest.php b/tests/Switzerland/Neuchatel/EasterMondayTest.php index 8ad62dffc..81ca4ff84 100644 --- a/tests/Switzerland/Neuchatel/EasterMondayTest.php +++ b/tests/Switzerland/Neuchatel/EasterMondayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Switzerland\Neuchatel; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -33,7 +30,7 @@ class EasterMondayTest extends NeuchatelBaseTestCase implements HolidayTestCase /** * Tests Easter Monday. * - * @throws Exception + * @throws \Exception */ public function testEasterMonday(): void { @@ -42,14 +39,14 @@ public function testEasterMonday(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-3-28", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-3-28", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests translated name of Easter Monday. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -64,7 +61,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Neuchatel/GoodFridayTest.php b/tests/Switzerland/Neuchatel/GoodFridayTest.php index 80d39fad8..381772d22 100644 --- a/tests/Switzerland/Neuchatel/GoodFridayTest.php +++ b/tests/Switzerland/Neuchatel/GoodFridayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Switzerland\Neuchatel; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -33,7 +30,7 @@ class GoodFridayTest extends NeuchatelBaseTestCase implements HolidayTestCase /** * Tests the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHoliday(): void { @@ -42,14 +39,14 @@ public function testHoliday(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-3-21", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-3-21", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -64,7 +61,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Neuchatel/InstaurationRepubliqueTest.php b/tests/Switzerland/Neuchatel/InstaurationRepubliqueTest.php index 95e94fd3b..c9251640e 100644 --- a/tests/Switzerland/Neuchatel/InstaurationRepubliqueTest.php +++ b/tests/Switzerland/Neuchatel/InstaurationRepubliqueTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Switzerland\Neuchatel; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -38,7 +35,7 @@ class InstaurationRepubliqueTest extends NeuchatelBaseTestCase implements Holida /** * Tests Instauration de la République on or after 1849. * - * @throws Exception + * @throws \Exception */ public function testInstaurationRepubliqueOnAfter1849(): void { @@ -47,14 +44,14 @@ public function testInstaurationRepubliqueOnAfter1849(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-03-01", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-03-01", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests Instauration de la République before 1849. * - * @throws Exception + * @throws \Exception */ public function testInstaurationRepubliqueBefore1849(): void { @@ -68,7 +65,7 @@ public function testInstaurationRepubliqueBefore1849(): void /** * Tests translated name of Instauration de la République. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -83,7 +80,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Neuchatel/January2ndTest.php b/tests/Switzerland/Neuchatel/January2ndTest.php index 2c5ce1253..c77d1997f 100644 --- a/tests/Switzerland/Neuchatel/January2ndTest.php +++ b/tests/Switzerland/Neuchatel/January2ndTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Switzerland\Neuchatel; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -38,7 +35,7 @@ class January2ndTest extends NeuchatelBaseTestCase implements HolidayTestCase /** * Tests January 2nd. * - * @throws Exception + * @throws \Exception */ public function testJanuary2nd(): void { @@ -46,7 +43,7 @@ public function testJanuary2nd(): void self::REGION, self::HOLIDAY, self::OBSERVANCE_YEAR, - new DateTime(self::OBSERVANCE_YEAR.'-1-02', new DateTimeZone(self::TIMEZONE)) + new \DateTime(self::OBSERVANCE_YEAR.'-1-02', new \DateTimeZone(self::TIMEZONE)) ); $this->assertNotHoliday( self::REGION, diff --git a/tests/Switzerland/Neuchatel/NeuchatelTest.php b/tests/Switzerland/Neuchatel/NeuchatelTest.php index b01b82c46..b0e7ab9eb 100644 --- a/tests/Switzerland/Neuchatel/NeuchatelTest.php +++ b/tests/Switzerland/Neuchatel/NeuchatelTest.php @@ -14,7 +14,6 @@ namespace Yasumi\tests\Switzerland\Neuchatel; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\ProviderTestCase; @@ -106,7 +105,7 @@ public function testOtherHolidays(): void } /** - * @throws ReflectionException + * @throws \ReflectionException * @throws \Exception */ public function testSources(): void diff --git a/tests/Switzerland/Neuchatel/NewYearsDayTest.php b/tests/Switzerland/Neuchatel/NewYearsDayTest.php index c68dc509d..49b22e791 100644 --- a/tests/Switzerland/Neuchatel/NewYearsDayTest.php +++ b/tests/Switzerland/Neuchatel/NewYearsDayTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\Switzerland\Neuchatel; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,8 +32,8 @@ class NewYearsDayTest extends NeuchatelBaseTestCase implements HolidayTestCase * * @dataProvider NewYearsDayDataProvider * - * @param int $year the year for which New Years Day needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which New Years Day needs to be tested + * @param \DateTime $expected the expected date */ public function testNewYearsDay(int $year, \DateTimeInterface $expected): void { @@ -45,7 +43,7 @@ public function testNewYearsDay(int $year, \DateTimeInterface $expected): void /** * Tests translated name of New Years Day. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -60,7 +58,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { @@ -72,7 +70,7 @@ public function testHolidayType(): void * * @return array list of test dates for New Years Day * - * @throws Exception + * @throws \Exception */ public function NewYearsDayDataProvider(): array { diff --git a/tests/Switzerland/Neuchatel/PentecostMondayTest.php b/tests/Switzerland/Neuchatel/PentecostMondayTest.php index ed7b7f8de..8ad88ddcb 100644 --- a/tests/Switzerland/Neuchatel/PentecostMondayTest.php +++ b/tests/Switzerland/Neuchatel/PentecostMondayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Switzerland\Neuchatel; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -33,7 +30,7 @@ class PentecostMondayTest extends NeuchatelBaseTestCase implements HolidayTestCa /** * Tests Pentecost Monday. * - * @throws Exception + * @throws \Exception */ public function testPentecostMonday(): void { @@ -42,14 +39,14 @@ public function testPentecostMonday(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-5-30", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-5-30", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests translated name of Pentecost Monday. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -64,7 +61,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Neuchatel/WorkersDayTest.php b/tests/Switzerland/Neuchatel/WorkersDayTest.php index 55cd66f90..dfb01faec 100644 --- a/tests/Switzerland/Neuchatel/WorkersDayTest.php +++ b/tests/Switzerland/Neuchatel/WorkersDayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Switzerland\Neuchatel; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -38,11 +35,11 @@ class WorkersDayTest extends NeuchatelBaseTestCase implements HolidayTestCase * @param int $year the year for which the holiday defined in this test needs to be tested * @param string $expected the expected date * - * @throws Exception + * @throws \Exception */ public function testHoliday(int $year, string $expected): void { - $date = new DateTime($expected, new DateTimeZone(self::TIMEZONE)); + $date = new \DateTime($expected, new \DateTimeZone(self::TIMEZONE)); $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $date); } @@ -51,7 +48,7 @@ public function testHoliday(int $year, string $expected): void * * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function HolidayDataProvider(): array { @@ -59,7 +56,7 @@ public function HolidayDataProvider(): array for ($y = 0; $y < 50; ++$y) { $year = $this->generateRandomYear(); - $date = new DateTime("$year-5-1", new DateTimeZone(self::TIMEZONE)); + $date = new \DateTime("$year-5-1", new \DateTimeZone(self::TIMEZONE)); $data[] = [$year, $date->format('Y-m-d')]; } @@ -69,7 +66,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -84,7 +81,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Nidwalden/AllSaintsDayTest.php b/tests/Switzerland/Nidwalden/AllSaintsDayTest.php index edc49a934..a08f3f61e 100644 --- a/tests/Switzerland/Nidwalden/AllSaintsDayTest.php +++ b/tests/Switzerland/Nidwalden/AllSaintsDayTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\Switzerland\Nidwalden; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,8 +32,8 @@ class AllSaintsDayTest extends NidwaldenBaseTestCase implements HolidayTestCase * * @dataProvider AllSaintsDayDataProvider * - * @param int $year the year for which All Saints' Day needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which All Saints' Day needs to be tested + * @param \DateTime $expected the expected date */ public function testAllSaintsDay(int $year, \DateTimeInterface $expected): void { @@ -45,7 +43,7 @@ public function testAllSaintsDay(int $year, \DateTimeInterface $expected): void /** * Tests translated name of All Saints' Day. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -60,7 +58,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { @@ -72,7 +70,7 @@ public function testHolidayType(): void * * @return array list of test dates for All Saints' Day * - * @throws Exception + * @throws \Exception */ public function AllSaintsDayDataProvider(): array { diff --git a/tests/Switzerland/Nidwalden/AscensionDayTest.php b/tests/Switzerland/Nidwalden/AscensionDayTest.php index ab23f23a0..398ba70f2 100644 --- a/tests/Switzerland/Nidwalden/AscensionDayTest.php +++ b/tests/Switzerland/Nidwalden/AscensionDayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Switzerland\Nidwalden; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -33,7 +30,7 @@ class AscensionDayTest extends NidwaldenBaseTestCase implements HolidayTestCase /** * Tests Ascension Day. * - * @throws Exception + * @throws \Exception */ public function testAscensionDay(): void { @@ -42,14 +39,14 @@ public function testAscensionDay(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-5-16", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-5-16", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests translated name of Ascension Day. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -64,7 +61,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Nidwalden/AssumptionOfMaryTest.php b/tests/Switzerland/Nidwalden/AssumptionOfMaryTest.php index ec3950fb7..4806e1943 100644 --- a/tests/Switzerland/Nidwalden/AssumptionOfMaryTest.php +++ b/tests/Switzerland/Nidwalden/AssumptionOfMaryTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\Switzerland\Nidwalden; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,8 +32,8 @@ class AssumptionOfMaryTest extends NidwaldenBaseTestCase implements HolidayTestC * * @dataProvider AssumptionOfMaryDataProvider * - * @param int $year the year for which the day of the Assumption of Mary needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which the day of the Assumption of Mary needs to be tested + * @param \DateTime $expected the expected date */ public function testAssumptionOfMary(int $year, \DateTimeInterface $expected): void { @@ -45,7 +43,7 @@ public function testAssumptionOfMary(int $year, \DateTimeInterface $expected): v /** * Tests translated name of the day of the Assumption of Mary. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -60,7 +58,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { @@ -72,7 +70,7 @@ public function testHolidayType(): void * * @return array list of test dates for the day of the Assumption of Mary * - * @throws Exception + * @throws \Exception */ public function AssumptionOfMaryDataProvider(): array { diff --git a/tests/Switzerland/Nidwalden/ChristmasDayTest.php b/tests/Switzerland/Nidwalden/ChristmasDayTest.php index af9b9cca8..8981cad61 100644 --- a/tests/Switzerland/Nidwalden/ChristmasDayTest.php +++ b/tests/Switzerland/Nidwalden/ChristmasDayTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\Switzerland\Nidwalden; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,8 +32,8 @@ class ChristmasDayTest extends NidwaldenBaseTestCase implements HolidayTestCase * * @dataProvider ChristmasDayDataProvider * - * @param int $year the year for which Christmas Day needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which Christmas Day needs to be tested + * @param \DateTime $expected the expected date */ public function testChristmasDay(int $year, \DateTimeInterface $expected): void { @@ -47,7 +45,7 @@ public function testChristmasDay(int $year, \DateTimeInterface $expected): void * * @return array list of test dates for Christmas Day * - * @throws Exception + * @throws \Exception */ public function ChristmasDayDataProvider(): array { @@ -57,7 +55,7 @@ public function ChristmasDayDataProvider(): array /** * Tests translated name of Christmas Day. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -72,7 +70,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Nidwalden/CorpusChristiTest.php b/tests/Switzerland/Nidwalden/CorpusChristiTest.php index 77c6fa2f9..790e754b1 100644 --- a/tests/Switzerland/Nidwalden/CorpusChristiTest.php +++ b/tests/Switzerland/Nidwalden/CorpusChristiTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\Switzerland\Nidwalden; -use DateInterval; -use Exception; use Yasumi\Holiday; use Yasumi\Provider\ChristianHolidays; use Yasumi\tests\HolidayTestCase; @@ -35,7 +33,7 @@ class CorpusChristiTest extends NidwaldenBaseTestCase implements HolidayTestCase /** * Tests Corpus Christi. * - * @throws Exception + * @throws \Exception */ public function testCorpusChristi(): void { @@ -44,14 +42,14 @@ public function testCorpusChristi(): void self::REGION, self::HOLIDAY, $year, - $this->calculateEaster($year, self::TIMEZONE)->add(new DateInterval('P60D')) + $this->calculateEaster($year, self::TIMEZONE)->add(new \DateInterval('P60D')) ); } /** * Tests translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -66,7 +64,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Nidwalden/EasterMondayTest.php b/tests/Switzerland/Nidwalden/EasterMondayTest.php index d11aa845d..de72de15e 100644 --- a/tests/Switzerland/Nidwalden/EasterMondayTest.php +++ b/tests/Switzerland/Nidwalden/EasterMondayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Switzerland\Nidwalden; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -33,7 +30,7 @@ class EasterMondayTest extends NidwaldenBaseTestCase implements HolidayTestCase /** * Tests Easter Monday. * - * @throws Exception + * @throws \Exception */ public function testEasterMonday(): void { @@ -42,14 +39,14 @@ public function testEasterMonday(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-3-28", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-3-28", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests translated name of Easter Monday. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -64,7 +61,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Nidwalden/GoodFridayTest.php b/tests/Switzerland/Nidwalden/GoodFridayTest.php index b655dff09..eb585f89c 100644 --- a/tests/Switzerland/Nidwalden/GoodFridayTest.php +++ b/tests/Switzerland/Nidwalden/GoodFridayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Switzerland\Nidwalden; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -33,7 +30,7 @@ class GoodFridayTest extends NidwaldenBaseTestCase implements HolidayTestCase /** * Tests the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHoliday(): void { @@ -42,14 +39,14 @@ public function testHoliday(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-3-21", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-3-21", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -64,7 +61,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Nidwalden/ImmaculateConceptionTest.php b/tests/Switzerland/Nidwalden/ImmaculateConceptionTest.php index 7fe1ca63c..ce5257a4c 100644 --- a/tests/Switzerland/Nidwalden/ImmaculateConceptionTest.php +++ b/tests/Switzerland/Nidwalden/ImmaculateConceptionTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\Switzerland\Nidwalden; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,8 +32,8 @@ class ImmaculateConceptionTest extends NidwaldenBaseTestCase implements HolidayT * * @dataProvider HolidayDataProvider * - * @param int $year the year for which the holiday defined in this test needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which the holiday defined in this test needs to be tested + * @param \DateTime $expected the expected date */ public function testHoliday(int $year, \DateTimeInterface $expected): void { @@ -47,7 +45,7 @@ public function testHoliday(int $year, \DateTimeInterface $expected): void * * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function HolidayDataProvider(): array { @@ -57,7 +55,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -72,7 +70,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Nidwalden/NewYearsDayTest.php b/tests/Switzerland/Nidwalden/NewYearsDayTest.php index 4eab06436..2702bda1d 100644 --- a/tests/Switzerland/Nidwalden/NewYearsDayTest.php +++ b/tests/Switzerland/Nidwalden/NewYearsDayTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\Switzerland\Nidwalden; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,8 +32,8 @@ class NewYearsDayTest extends NidwaldenBaseTestCase implements HolidayTestCase * * @dataProvider NewYearsDayDataProvider * - * @param int $year the year for which New Years Day needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which New Years Day needs to be tested + * @param \DateTime $expected the expected date */ public function testNewYearsDay(int $year, \DateTimeInterface $expected): void { @@ -45,7 +43,7 @@ public function testNewYearsDay(int $year, \DateTimeInterface $expected): void /** * Tests translated name of New Years Day. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -60,7 +58,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { @@ -72,7 +70,7 @@ public function testHolidayType(): void * * @return array list of test dates for New Years Day * - * @throws Exception + * @throws \Exception */ public function NewYearsDayDataProvider(): array { diff --git a/tests/Switzerland/Nidwalden/NidwaldenTest.php b/tests/Switzerland/Nidwalden/NidwaldenTest.php index 303f06f77..549c511a8 100644 --- a/tests/Switzerland/Nidwalden/NidwaldenTest.php +++ b/tests/Switzerland/Nidwalden/NidwaldenTest.php @@ -14,7 +14,6 @@ namespace Yasumi\tests\Switzerland\Nidwalden; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\ProviderTestCase; @@ -109,7 +108,7 @@ public function testOtherHolidays(): void } /** - * @throws ReflectionException + * @throws \ReflectionException * @throws \Exception */ public function testSources(): void diff --git a/tests/Switzerland/Nidwalden/PentecostMondayTest.php b/tests/Switzerland/Nidwalden/PentecostMondayTest.php index adc57673e..c77bb85cf 100644 --- a/tests/Switzerland/Nidwalden/PentecostMondayTest.php +++ b/tests/Switzerland/Nidwalden/PentecostMondayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Switzerland\Nidwalden; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -33,7 +30,7 @@ class PentecostMondayTest extends NidwaldenBaseTestCase implements HolidayTestCa /** * Tests Pentecost Monday. * - * @throws Exception + * @throws \Exception */ public function testPentecostMonday(): void { @@ -42,14 +39,14 @@ public function testPentecostMonday(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-5-30", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-5-30", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests translated name of Pentecost Monday. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -64,7 +61,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Nidwalden/StJosephDayTest.php b/tests/Switzerland/Nidwalden/StJosephDayTest.php index 5eebb4a9f..61288b685 100644 --- a/tests/Switzerland/Nidwalden/StJosephDayTest.php +++ b/tests/Switzerland/Nidwalden/StJosephDayTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\Switzerland\Nidwalden; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\Provider\ChristianHolidays; use Yasumi\tests\HolidayTestCase; @@ -37,8 +35,8 @@ class StJosephDayTest extends NidwaldenBaseTestCase implements HolidayTestCase * * @dataProvider StJosephDayDataProvider * - * @param int $year the year for which St. Joseph's Day needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which St. Joseph's Day needs to be tested + * @param \DateTime $expected the expected date */ public function testStJosephDay(int $year, \DateTimeInterface $expected): void { @@ -50,7 +48,7 @@ public function testStJosephDay(int $year, \DateTimeInterface $expected): void * * @return array list of test dates for St. Joseph's Day * - * @throws Exception + * @throws \Exception */ public function StJosephDayDataProvider(): array { @@ -60,7 +58,7 @@ public function StJosephDayDataProvider(): array /** * Tests translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -75,7 +73,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Nidwalden/StStephensDayTest.php b/tests/Switzerland/Nidwalden/StStephensDayTest.php index 1aef71904..5626f398f 100644 --- a/tests/Switzerland/Nidwalden/StStephensDayTest.php +++ b/tests/Switzerland/Nidwalden/StStephensDayTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\Switzerland\Nidwalden; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,8 +32,8 @@ class StStephensDayTest extends NidwaldenBaseTestCase implements HolidayTestCase * * @dataProvider HolidayDataProvider * - * @param int $year the year for which the holiday defined in this test needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which the holiday defined in this test needs to be tested + * @param \DateTime $expected the expected date */ public function testHoliday(int $year, \DateTimeInterface $expected): void { @@ -47,7 +45,7 @@ public function testHoliday(int $year, \DateTimeInterface $expected): void * * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function HolidayDataProvider(): array { @@ -57,7 +55,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -72,7 +70,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Obwalden/AllSaintsDayTest.php b/tests/Switzerland/Obwalden/AllSaintsDayTest.php index 63cb9a530..7a9d2e2e5 100644 --- a/tests/Switzerland/Obwalden/AllSaintsDayTest.php +++ b/tests/Switzerland/Obwalden/AllSaintsDayTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\Switzerland\Obwalden; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,8 +32,8 @@ class AllSaintsDayTest extends ObwaldenBaseTestCase implements HolidayTestCase * * @dataProvider AllSaintsDayDataProvider * - * @param int $year the year for which All Saints' Day needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which All Saints' Day needs to be tested + * @param \DateTime $expected the expected date */ public function testAllSaintsDay(int $year, \DateTimeInterface $expected): void { @@ -45,7 +43,7 @@ public function testAllSaintsDay(int $year, \DateTimeInterface $expected): void /** * Tests translated name of All Saints' Day. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -60,7 +58,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { @@ -72,7 +70,7 @@ public function testHolidayType(): void * * @return array list of test dates for All Saints' Day * - * @throws Exception + * @throws \Exception */ public function AllSaintsDayDataProvider(): array { diff --git a/tests/Switzerland/Obwalden/AscensionDayTest.php b/tests/Switzerland/Obwalden/AscensionDayTest.php index b4ba96c35..6993c65a4 100644 --- a/tests/Switzerland/Obwalden/AscensionDayTest.php +++ b/tests/Switzerland/Obwalden/AscensionDayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Switzerland\Obwalden; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -33,7 +30,7 @@ class AscensionDayTest extends ObwaldenBaseTestCase implements HolidayTestCase /** * Tests Ascension Day. * - * @throws Exception + * @throws \Exception */ public function testAscensionDay(): void { @@ -42,14 +39,14 @@ public function testAscensionDay(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-5-16", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-5-16", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests translated name of Ascension Day. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -64,7 +61,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Obwalden/AssumptionOfMaryTest.php b/tests/Switzerland/Obwalden/AssumptionOfMaryTest.php index 149a8e4f2..c2f850c8b 100644 --- a/tests/Switzerland/Obwalden/AssumptionOfMaryTest.php +++ b/tests/Switzerland/Obwalden/AssumptionOfMaryTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\Switzerland\Obwalden; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,8 +32,8 @@ class AssumptionOfMaryTest extends ObwaldenBaseTestCase implements HolidayTestCa * * @dataProvider AssumptionOfMaryDataProvider * - * @param int $year the year for which the day of the Assumption of Mary needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which the day of the Assumption of Mary needs to be tested + * @param \DateTime $expected the expected date */ public function testAssumptionOfMary(int $year, \DateTimeInterface $expected): void { @@ -45,7 +43,7 @@ public function testAssumptionOfMary(int $year, \DateTimeInterface $expected): v /** * Tests translated name of the day of the Assumption of Mary. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -60,7 +58,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { @@ -72,7 +70,7 @@ public function testHolidayType(): void * * @return array list of test dates for the day of the Assumption of Mary * - * @throws Exception + * @throws \Exception */ public function AssumptionOfMaryDataProvider(): array { diff --git a/tests/Switzerland/Obwalden/BerchtoldsTagTest.php b/tests/Switzerland/Obwalden/BerchtoldsTagTest.php index c29fa8f09..84b2a3841 100644 --- a/tests/Switzerland/Obwalden/BerchtoldsTagTest.php +++ b/tests/Switzerland/Obwalden/BerchtoldsTagTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Switzerland\Obwalden; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -33,12 +30,12 @@ class BerchtoldsTagTest extends ObwaldenBaseTestCase implements HolidayTestCase /** * Tests BerchtoldsTag. * - * @throws Exception + * @throws \Exception */ public function testBerchtoldsTag(): void { $year = $this->generateRandomYear(); - $date = new DateTime($year.'-01-02', new DateTimeZone(self::TIMEZONE)); + $date = new \DateTime($year.'-01-02', new \DateTimeZone(self::TIMEZONE)); $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $date); $this->assertHolidayType(self::REGION, self::HOLIDAY, $year, Holiday::TYPE_OTHER); @@ -47,7 +44,7 @@ public function testBerchtoldsTag(): void /** * Tests translated name of BerchtoldsTag. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -62,7 +59,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Obwalden/BruderKlausenFestTest.php b/tests/Switzerland/Obwalden/BruderKlausenFestTest.php index bdb19f111..320d2d030 100644 --- a/tests/Switzerland/Obwalden/BruderKlausenFestTest.php +++ b/tests/Switzerland/Obwalden/BruderKlausenFestTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Switzerland\Obwalden; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -33,12 +30,12 @@ class BruderKlausenFestTest extends ObwaldenBaseTestCase implements HolidayTestC /** * Tests Bruder-Klausen-Fest on or after 1947. * - * @throws Exception + * @throws \Exception */ public function testBruderKlausenFestOnAfter1947(): void { $year = $this->generateRandomYear(1947); - $date = new DateTime($year.'-09-25', new DateTimeZone(self::TIMEZONE)); + $date = new \DateTime($year.'-09-25', new \DateTimeZone(self::TIMEZONE)); $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $date); $this->assertHolidayType(self::REGION, self::HOLIDAY, $year, Holiday::TYPE_OTHER); @@ -47,12 +44,12 @@ public function testBruderKlausenFestOnAfter1947(): void /** * Tests Bruder-Klausen-Fest between 1649 and 1946. * - * @throws Exception + * @throws \Exception */ public function testBruderKlausenFestBetween1649And1946(): void { $year = $this->generateRandomYear(1649, 1946); - $date = new DateTime($year.'-09-21', new DateTimeZone(self::TIMEZONE)); + $date = new \DateTime($year.'-09-21', new \DateTimeZone(self::TIMEZONE)); $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $date); $this->assertHolidayType(self::REGION, self::HOLIDAY, $year, Holiday::TYPE_OTHER); @@ -61,7 +58,7 @@ public function testBruderKlausenFestBetween1649And1946(): void /** * Tests Bruder-Klausen-Fest before 1648. * - * @throws Exception + * @throws \Exception */ public function testBruderKlausenFestBefore1648(): void { @@ -72,7 +69,7 @@ public function testBruderKlausenFestBefore1648(): void /** * Tests translated name of Bruder-Klausen-Fest. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -87,7 +84,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Obwalden/ChristmasDayTest.php b/tests/Switzerland/Obwalden/ChristmasDayTest.php index 55dacca6d..eaa5042bb 100644 --- a/tests/Switzerland/Obwalden/ChristmasDayTest.php +++ b/tests/Switzerland/Obwalden/ChristmasDayTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\Switzerland\Obwalden; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,8 +32,8 @@ class ChristmasDayTest extends ObwaldenBaseTestCase implements HolidayTestCase * * @dataProvider ChristmasDayDataProvider * - * @param int $year the year for which Christmas Day needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which Christmas Day needs to be tested + * @param \DateTime $expected the expected date */ public function testChristmasDay(int $year, \DateTimeInterface $expected): void { @@ -47,7 +45,7 @@ public function testChristmasDay(int $year, \DateTimeInterface $expected): void * * @return array list of test dates for Christmas Day * - * @throws Exception + * @throws \Exception */ public function ChristmasDayDataProvider(): array { @@ -57,7 +55,7 @@ public function ChristmasDayDataProvider(): array /** * Tests translated name of Christmas Day. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -72,7 +70,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Obwalden/CorpusChristiTest.php b/tests/Switzerland/Obwalden/CorpusChristiTest.php index 261ccac23..28052977a 100644 --- a/tests/Switzerland/Obwalden/CorpusChristiTest.php +++ b/tests/Switzerland/Obwalden/CorpusChristiTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\Switzerland\Obwalden; -use DateInterval; -use Exception; use Yasumi\Holiday; use Yasumi\Provider\ChristianHolidays; use Yasumi\tests\HolidayTestCase; @@ -35,7 +33,7 @@ class CorpusChristiTest extends ObwaldenBaseTestCase implements HolidayTestCase /** * Tests Corpus Christi. * - * @throws Exception + * @throws \Exception */ public function testCorpusChristi(): void { @@ -44,14 +42,14 @@ public function testCorpusChristi(): void self::REGION, self::HOLIDAY, $year, - $this->calculateEaster($year, self::TIMEZONE)->add(new DateInterval('P60D')) + $this->calculateEaster($year, self::TIMEZONE)->add(new \DateInterval('P60D')) ); } /** * Tests translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -66,7 +64,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Obwalden/EasterMondayTest.php b/tests/Switzerland/Obwalden/EasterMondayTest.php index d4798722e..51b4f7253 100644 --- a/tests/Switzerland/Obwalden/EasterMondayTest.php +++ b/tests/Switzerland/Obwalden/EasterMondayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Switzerland\Obwalden; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -33,7 +30,7 @@ class EasterMondayTest extends ObwaldenBaseTestCase implements HolidayTestCase /** * Tests Easter Monday. * - * @throws Exception + * @throws \Exception */ public function testEasterMonday(): void { @@ -42,14 +39,14 @@ public function testEasterMonday(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-3-28", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-3-28", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests translated name of Easter Monday. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -64,7 +61,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Obwalden/GoodFridayTest.php b/tests/Switzerland/Obwalden/GoodFridayTest.php index 7c9759c43..10db1930f 100644 --- a/tests/Switzerland/Obwalden/GoodFridayTest.php +++ b/tests/Switzerland/Obwalden/GoodFridayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Switzerland\Obwalden; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -33,7 +30,7 @@ class GoodFridayTest extends ObwaldenBaseTestCase implements HolidayTestCase /** * Tests the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHoliday(): void { @@ -42,14 +39,14 @@ public function testHoliday(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-3-21", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-3-21", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -64,7 +61,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Obwalden/ImmaculateConceptionTest.php b/tests/Switzerland/Obwalden/ImmaculateConceptionTest.php index 64e551ada..9500e8bc2 100644 --- a/tests/Switzerland/Obwalden/ImmaculateConceptionTest.php +++ b/tests/Switzerland/Obwalden/ImmaculateConceptionTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\Switzerland\Obwalden; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,8 +32,8 @@ class ImmaculateConceptionTest extends ObwaldenBaseTestCase implements HolidayTe * * @dataProvider HolidayDataProvider * - * @param int $year the year for which the holiday defined in this test needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which the holiday defined in this test needs to be tested + * @param \DateTime $expected the expected date */ public function testHoliday(int $year, \DateTimeInterface $expected): void { @@ -47,7 +45,7 @@ public function testHoliday(int $year, \DateTimeInterface $expected): void * * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function HolidayDataProvider(): array { @@ -57,7 +55,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -72,7 +70,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Obwalden/NewYearsDayTest.php b/tests/Switzerland/Obwalden/NewYearsDayTest.php index 940d834db..004426c85 100644 --- a/tests/Switzerland/Obwalden/NewYearsDayTest.php +++ b/tests/Switzerland/Obwalden/NewYearsDayTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\Switzerland\Obwalden; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,8 +32,8 @@ class NewYearsDayTest extends ObwaldenBaseTestCase implements HolidayTestCase * * @dataProvider NewYearsDayDataProvider * - * @param int $year the year for which New Years Day needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which New Years Day needs to be tested + * @param \DateTime $expected the expected date */ public function testNewYearsDay(int $year, \DateTimeInterface $expected): void { @@ -45,7 +43,7 @@ public function testNewYearsDay(int $year, \DateTimeInterface $expected): void /** * Tests translated name of New Years Day. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -60,7 +58,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { @@ -72,7 +70,7 @@ public function testHolidayType(): void * * @return array list of test dates for New Years Day * - * @throws Exception + * @throws \Exception */ public function NewYearsDayDataProvider(): array { diff --git a/tests/Switzerland/Obwalden/ObwaldenTest.php b/tests/Switzerland/Obwalden/ObwaldenTest.php index 764f41412..f52f0d31a 100644 --- a/tests/Switzerland/Obwalden/ObwaldenTest.php +++ b/tests/Switzerland/Obwalden/ObwaldenTest.php @@ -14,7 +14,6 @@ namespace Yasumi\tests\Switzerland\Obwalden; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\ProviderTestCase; @@ -110,7 +109,7 @@ public function testOtherHolidays(): void } /** - * @throws ReflectionException + * @throws \ReflectionException * @throws \Exception */ public function testSources(): void diff --git a/tests/Switzerland/Obwalden/PentecostMondayTest.php b/tests/Switzerland/Obwalden/PentecostMondayTest.php index f5a8af66d..24f50f4bb 100644 --- a/tests/Switzerland/Obwalden/PentecostMondayTest.php +++ b/tests/Switzerland/Obwalden/PentecostMondayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Switzerland\Obwalden; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -33,7 +30,7 @@ class PentecostMondayTest extends ObwaldenBaseTestCase implements HolidayTestCas /** * Tests Pentecost Monday. * - * @throws Exception + * @throws \Exception */ public function testPentecostMonday(): void { @@ -42,14 +39,14 @@ public function testPentecostMonday(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-5-30", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-5-30", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests translated name of Pentecost Monday. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -64,7 +61,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Obwalden/StStephensDayTest.php b/tests/Switzerland/Obwalden/StStephensDayTest.php index 3f8259ed2..7228cbd7b 100644 --- a/tests/Switzerland/Obwalden/StStephensDayTest.php +++ b/tests/Switzerland/Obwalden/StStephensDayTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\Switzerland\Obwalden; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,8 +32,8 @@ class StStephensDayTest extends ObwaldenBaseTestCase implements HolidayTestCase * * @dataProvider HolidayDataProvider * - * @param int $year the year for which the holiday defined in this test needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which the holiday defined in this test needs to be tested + * @param \DateTime $expected the expected date */ public function testHoliday(int $year, \DateTimeInterface $expected): void { @@ -47,7 +45,7 @@ public function testHoliday(int $year, \DateTimeInterface $expected): void * * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function HolidayDataProvider(): array { @@ -57,7 +55,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -72,7 +70,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Schaffhausen/AscensionDayTest.php b/tests/Switzerland/Schaffhausen/AscensionDayTest.php index eee06a1bd..381be092b 100644 --- a/tests/Switzerland/Schaffhausen/AscensionDayTest.php +++ b/tests/Switzerland/Schaffhausen/AscensionDayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Switzerland\Schaffhausen; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -33,7 +30,7 @@ class AscensionDayTest extends SchaffhausenBaseTestCase implements HolidayTestCa /** * Tests Ascension Day. * - * @throws Exception + * @throws \Exception */ public function testAscensionDay(): void { @@ -42,14 +39,14 @@ public function testAscensionDay(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-5-16", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-5-16", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests translated name of Ascension Day. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -64,7 +61,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Schaffhausen/BerchtoldsTagTest.php b/tests/Switzerland/Schaffhausen/BerchtoldsTagTest.php index 5b07a942c..7f2f229fe 100644 --- a/tests/Switzerland/Schaffhausen/BerchtoldsTagTest.php +++ b/tests/Switzerland/Schaffhausen/BerchtoldsTagTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Switzerland\Schaffhausen; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -33,12 +30,12 @@ class BerchtoldsTagTest extends SchaffhausenBaseTestCase implements HolidayTestC /** * Tests BerchtoldsTag. * - * @throws Exception + * @throws \Exception */ public function testBerchtoldsTag(): void { $year = $this->generateRandomYear(); - $date = new DateTime($year.'-01-02', new DateTimeZone(self::TIMEZONE)); + $date = new \DateTime($year.'-01-02', new \DateTimeZone(self::TIMEZONE)); $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $date); $this->assertHolidayType(self::REGION, self::HOLIDAY, $year, Holiday::TYPE_OTHER); @@ -47,7 +44,7 @@ public function testBerchtoldsTag(): void /** * Tests translated name of BerchtoldsTag. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -62,7 +59,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Schaffhausen/ChristmasDayTest.php b/tests/Switzerland/Schaffhausen/ChristmasDayTest.php index 39e6cb156..16771273f 100644 --- a/tests/Switzerland/Schaffhausen/ChristmasDayTest.php +++ b/tests/Switzerland/Schaffhausen/ChristmasDayTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\Switzerland\Schaffhausen; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,8 +32,8 @@ class ChristmasDayTest extends SchaffhausenBaseTestCase implements HolidayTestCa * * @dataProvider ChristmasDayDataProvider * - * @param int $year the year for which Christmas Day needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which Christmas Day needs to be tested + * @param \DateTime $expected the expected date */ public function testChristmasDay(int $year, \DateTimeInterface $expected): void { @@ -47,7 +45,7 @@ public function testChristmasDay(int $year, \DateTimeInterface $expected): void * * @return array list of test dates for Christmas Day * - * @throws Exception + * @throws \Exception */ public function ChristmasDayDataProvider(): array { @@ -57,7 +55,7 @@ public function ChristmasDayDataProvider(): array /** * Tests translated name of Christmas Day. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -72,7 +70,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Schaffhausen/EasterMondayTest.php b/tests/Switzerland/Schaffhausen/EasterMondayTest.php index 5e85be451..84b4bbd2d 100644 --- a/tests/Switzerland/Schaffhausen/EasterMondayTest.php +++ b/tests/Switzerland/Schaffhausen/EasterMondayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Switzerland\Schaffhausen; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -33,7 +30,7 @@ class EasterMondayTest extends SchaffhausenBaseTestCase implements HolidayTestCa /** * Tests Easter Monday. * - * @throws Exception + * @throws \Exception */ public function testEasterMonday(): void { @@ -42,14 +39,14 @@ public function testEasterMonday(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-3-28", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-3-28", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests translated name of Easter Monday. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -64,7 +61,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Schaffhausen/GoodFridayTest.php b/tests/Switzerland/Schaffhausen/GoodFridayTest.php index c46dc49a4..f58ebf913 100644 --- a/tests/Switzerland/Schaffhausen/GoodFridayTest.php +++ b/tests/Switzerland/Schaffhausen/GoodFridayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Switzerland\Schaffhausen; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -33,7 +30,7 @@ class GoodFridayTest extends SchaffhausenBaseTestCase implements HolidayTestCase /** * Tests the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHoliday(): void { @@ -42,14 +39,14 @@ public function testHoliday(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-3-21", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-3-21", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -64,7 +61,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Schaffhausen/NewYearsDayTest.php b/tests/Switzerland/Schaffhausen/NewYearsDayTest.php index a252328ce..5ae46d1aa 100644 --- a/tests/Switzerland/Schaffhausen/NewYearsDayTest.php +++ b/tests/Switzerland/Schaffhausen/NewYearsDayTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\Switzerland\Schaffhausen; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,8 +32,8 @@ class NewYearsDayTest extends SchaffhausenBaseTestCase implements HolidayTestCas * * @dataProvider NewYearsDayDataProvider * - * @param int $year the year for which New Years Day needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which New Years Day needs to be tested + * @param \DateTime $expected the expected date */ public function testNewYearsDay(int $year, \DateTimeInterface $expected): void { @@ -45,7 +43,7 @@ public function testNewYearsDay(int $year, \DateTimeInterface $expected): void /** * Tests translated name of New Years Day. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -60,7 +58,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { @@ -72,7 +70,7 @@ public function testHolidayType(): void * * @return array list of test dates for New Years Day * - * @throws Exception + * @throws \Exception */ public function NewYearsDayDataProvider(): array { diff --git a/tests/Switzerland/Schaffhausen/PentecostMondayTest.php b/tests/Switzerland/Schaffhausen/PentecostMondayTest.php index b3cce3e22..13bc35e35 100644 --- a/tests/Switzerland/Schaffhausen/PentecostMondayTest.php +++ b/tests/Switzerland/Schaffhausen/PentecostMondayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Switzerland\Schaffhausen; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -33,7 +30,7 @@ class PentecostMondayTest extends SchaffhausenBaseTestCase implements HolidayTes /** * Tests Pentecost Monday. * - * @throws Exception + * @throws \Exception */ public function testPentecostMonday(): void { @@ -42,14 +39,14 @@ public function testPentecostMonday(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-5-30", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-5-30", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests translated name of Pentecost Monday. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -64,7 +61,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Schaffhausen/SchaffhausenTest.php b/tests/Switzerland/Schaffhausen/SchaffhausenTest.php index b46aac95e..cb56c67b0 100644 --- a/tests/Switzerland/Schaffhausen/SchaffhausenTest.php +++ b/tests/Switzerland/Schaffhausen/SchaffhausenTest.php @@ -14,7 +14,6 @@ namespace Yasumi\tests\Switzerland\Schaffhausen; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\ProviderTestCase; @@ -106,7 +105,7 @@ public function testOtherHolidays(): void } /** - * @throws ReflectionException + * @throws \ReflectionException * @throws \Exception */ public function testSources(): void diff --git a/tests/Switzerland/Schaffhausen/StStephensDayTest.php b/tests/Switzerland/Schaffhausen/StStephensDayTest.php index bc6130368..1fdbf4e91 100644 --- a/tests/Switzerland/Schaffhausen/StStephensDayTest.php +++ b/tests/Switzerland/Schaffhausen/StStephensDayTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\Switzerland\Schaffhausen; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,8 +32,8 @@ class StStephensDayTest extends SchaffhausenBaseTestCase implements HolidayTestC * * @dataProvider HolidayDataProvider * - * @param int $year the year for which the holiday defined in this test needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which the holiday defined in this test needs to be tested + * @param \DateTime $expected the expected date */ public function testHoliday(int $year, \DateTimeInterface $expected): void { @@ -47,7 +45,7 @@ public function testHoliday(int $year, \DateTimeInterface $expected): void * * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function HolidayDataProvider(): array { @@ -57,7 +55,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -72,7 +70,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Schaffhausen/WorkersDayTest.php b/tests/Switzerland/Schaffhausen/WorkersDayTest.php index af78bacd2..b24d3e120 100644 --- a/tests/Switzerland/Schaffhausen/WorkersDayTest.php +++ b/tests/Switzerland/Schaffhausen/WorkersDayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Switzerland\Schaffhausen; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -38,11 +35,11 @@ class WorkersDayTest extends SchaffhausenBaseTestCase implements HolidayTestCase * @param int $year the year for which the holiday defined in this test needs to be tested * @param string $expected the expected date * - * @throws Exception + * @throws \Exception */ public function testHoliday(int $year, string $expected): void { - $date = new DateTime($expected, new DateTimeZone(self::TIMEZONE)); + $date = new \DateTime($expected, new \DateTimeZone(self::TIMEZONE)); $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $date); } @@ -51,7 +48,7 @@ public function testHoliday(int $year, string $expected): void * * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function HolidayDataProvider(): array { @@ -59,7 +56,7 @@ public function HolidayDataProvider(): array for ($y = 0; $y < 50; ++$y) { $year = $this->generateRandomYear(); - $date = new DateTime("$year-5-1", new DateTimeZone(self::TIMEZONE)); + $date = new \DateTime("$year-5-1", new \DateTimeZone(self::TIMEZONE)); $data[] = [$year, $date->format('Y-m-d')]; } @@ -69,7 +66,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -84,7 +81,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Schwyz/AllSaintsDayTest.php b/tests/Switzerland/Schwyz/AllSaintsDayTest.php index a6b4225f4..f1e7f4897 100644 --- a/tests/Switzerland/Schwyz/AllSaintsDayTest.php +++ b/tests/Switzerland/Schwyz/AllSaintsDayTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\Switzerland\Schwyz; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,8 +32,8 @@ class AllSaintsDayTest extends SchwyzBaseTestCase implements HolidayTestCase * * @dataProvider AllSaintsDayDataProvider * - * @param int $year the year for which All Saints' Day needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which All Saints' Day needs to be tested + * @param \DateTime $expected the expected date */ public function testAllSaintsDay(int $year, \DateTimeInterface $expected): void { @@ -45,7 +43,7 @@ public function testAllSaintsDay(int $year, \DateTimeInterface $expected): void /** * Tests translated name of All Saints' Day. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -60,7 +58,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { @@ -72,7 +70,7 @@ public function testHolidayType(): void * * @return array list of test dates for All Saints' Day * - * @throws Exception + * @throws \Exception */ public function AllSaintsDayDataProvider(): array { diff --git a/tests/Switzerland/Schwyz/AscensionDayTest.php b/tests/Switzerland/Schwyz/AscensionDayTest.php index 1735a4960..ea6b8554b 100644 --- a/tests/Switzerland/Schwyz/AscensionDayTest.php +++ b/tests/Switzerland/Schwyz/AscensionDayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Switzerland\Schwyz; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -33,7 +30,7 @@ class AscensionDayTest extends SchwyzBaseTestCase implements HolidayTestCase /** * Tests Ascension Day. * - * @throws Exception + * @throws \Exception */ public function testAscensionDay(): void { @@ -42,14 +39,14 @@ public function testAscensionDay(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-5-16", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-5-16", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests translated name of Ascension Day. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -64,7 +61,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Schwyz/AssumptionOfMaryTest.php b/tests/Switzerland/Schwyz/AssumptionOfMaryTest.php index 9e54a3d39..1e9a05a91 100644 --- a/tests/Switzerland/Schwyz/AssumptionOfMaryTest.php +++ b/tests/Switzerland/Schwyz/AssumptionOfMaryTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\Switzerland\Schwyz; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,8 +32,8 @@ class AssumptionOfMaryTest extends SchwyzBaseTestCase implements HolidayTestCase * * @dataProvider AssumptionOfMaryDataProvider * - * @param int $year the year for which the day of the Assumption of Mary needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which the day of the Assumption of Mary needs to be tested + * @param \DateTime $expected the expected date */ public function testAssumptionOfMary(int $year, \DateTimeInterface $expected): void { @@ -45,7 +43,7 @@ public function testAssumptionOfMary(int $year, \DateTimeInterface $expected): v /** * Tests translated name of the day of the Assumption of Mary. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -60,7 +58,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { @@ -72,7 +70,7 @@ public function testHolidayType(): void * * @return array list of test dates for the day of the Assumption of Mary * - * @throws Exception + * @throws \Exception */ public function AssumptionOfMaryDataProvider(): array { diff --git a/tests/Switzerland/Schwyz/ChristmasDayTest.php b/tests/Switzerland/Schwyz/ChristmasDayTest.php index fd3e33d95..5d7da3fa9 100644 --- a/tests/Switzerland/Schwyz/ChristmasDayTest.php +++ b/tests/Switzerland/Schwyz/ChristmasDayTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\Switzerland\Schwyz; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,8 +32,8 @@ class ChristmasDayTest extends SchwyzBaseTestCase implements HolidayTestCase * * @dataProvider ChristmasDayDataProvider * - * @param int $year the year for which Christmas Day needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which Christmas Day needs to be tested + * @param \DateTime $expected the expected date */ public function testChristmasDay(int $year, \DateTimeInterface $expected): void { @@ -47,7 +45,7 @@ public function testChristmasDay(int $year, \DateTimeInterface $expected): void * * @return array list of test dates for Christmas Day * - * @throws Exception + * @throws \Exception */ public function ChristmasDayDataProvider(): array { @@ -57,7 +55,7 @@ public function ChristmasDayDataProvider(): array /** * Tests translated name of Christmas Day. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -72,7 +70,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Schwyz/CorpusChristiTest.php b/tests/Switzerland/Schwyz/CorpusChristiTest.php index 65fa94b84..09e0b6ecf 100644 --- a/tests/Switzerland/Schwyz/CorpusChristiTest.php +++ b/tests/Switzerland/Schwyz/CorpusChristiTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\Switzerland\Schwyz; -use DateInterval; -use Exception; use Yasumi\Holiday; use Yasumi\Provider\ChristianHolidays; use Yasumi\tests\HolidayTestCase; @@ -35,7 +33,7 @@ class CorpusChristiTest extends SchwyzBaseTestCase implements HolidayTestCase /** * Tests Corpus Christi. * - * @throws Exception + * @throws \Exception */ public function testCorpusChristi(): void { @@ -44,14 +42,14 @@ public function testCorpusChristi(): void self::REGION, self::HOLIDAY, $year, - $this->calculateEaster($year, self::TIMEZONE)->add(new DateInterval('P60D')) + $this->calculateEaster($year, self::TIMEZONE)->add(new \DateInterval('P60D')) ); } /** * Tests translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -66,7 +64,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Schwyz/EasterMondayTest.php b/tests/Switzerland/Schwyz/EasterMondayTest.php index fef0231ff..9f58e3c22 100644 --- a/tests/Switzerland/Schwyz/EasterMondayTest.php +++ b/tests/Switzerland/Schwyz/EasterMondayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Switzerland\Schwyz; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -33,7 +30,7 @@ class EasterMondayTest extends SchwyzBaseTestCase implements HolidayTestCase /** * Tests Easter Monday. * - * @throws Exception + * @throws \Exception */ public function testEasterMonday(): void { @@ -42,14 +39,14 @@ public function testEasterMonday(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-3-28", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-3-28", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests translated name of Easter Monday. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -64,7 +61,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Schwyz/EpiphanyTest.php b/tests/Switzerland/Schwyz/EpiphanyTest.php index c47c66b30..fb51d29ec 100644 --- a/tests/Switzerland/Schwyz/EpiphanyTest.php +++ b/tests/Switzerland/Schwyz/EpiphanyTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\Switzerland\Schwyz; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,8 +32,8 @@ class EpiphanyTest extends SchwyzBaseTestCase implements HolidayTestCase * * @dataProvider HolidayDataProvider * - * @param int $year the year for which the holiday defined in this test needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which the holiday defined in this test needs to be tested + * @param \DateTime $expected the expected date */ public function testHoliday(int $year, \DateTimeInterface $expected): void { @@ -47,7 +45,7 @@ public function testHoliday(int $year, \DateTimeInterface $expected): void * * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function HolidayDataProvider(): array { @@ -57,7 +55,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -72,7 +70,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Schwyz/GoodFridayTest.php b/tests/Switzerland/Schwyz/GoodFridayTest.php index c869a1793..ee3162f07 100644 --- a/tests/Switzerland/Schwyz/GoodFridayTest.php +++ b/tests/Switzerland/Schwyz/GoodFridayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Switzerland\Schwyz; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -33,7 +30,7 @@ class GoodFridayTest extends SchwyzBaseTestCase implements HolidayTestCase /** * Tests the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHoliday(): void { @@ -42,14 +39,14 @@ public function testHoliday(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-3-21", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-3-21", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -64,7 +61,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Schwyz/ImmaculateConceptionTest.php b/tests/Switzerland/Schwyz/ImmaculateConceptionTest.php index 9c040d94b..c95a3e048 100644 --- a/tests/Switzerland/Schwyz/ImmaculateConceptionTest.php +++ b/tests/Switzerland/Schwyz/ImmaculateConceptionTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\Switzerland\Schwyz; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,8 +32,8 @@ class ImmaculateConceptionTest extends SchwyzBaseTestCase implements HolidayTest * * @dataProvider HolidayDataProvider * - * @param int $year the year for which the holiday defined in this test needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which the holiday defined in this test needs to be tested + * @param \DateTime $expected the expected date */ public function testHoliday(int $year, \DateTimeInterface $expected): void { @@ -47,7 +45,7 @@ public function testHoliday(int $year, \DateTimeInterface $expected): void * * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function HolidayDataProvider(): array { @@ -57,7 +55,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -72,7 +70,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Schwyz/NewYearsDayTest.php b/tests/Switzerland/Schwyz/NewYearsDayTest.php index 471689821..f15b8bd3e 100644 --- a/tests/Switzerland/Schwyz/NewYearsDayTest.php +++ b/tests/Switzerland/Schwyz/NewYearsDayTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\Switzerland\Schwyz; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,8 +32,8 @@ class NewYearsDayTest extends SchwyzBaseTestCase implements HolidayTestCase * * @dataProvider NewYearsDayDataProvider * - * @param int $year the year for which New Years Day needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which New Years Day needs to be tested + * @param \DateTime $expected the expected date */ public function testNewYearsDay(int $year, \DateTimeInterface $expected): void { @@ -45,7 +43,7 @@ public function testNewYearsDay(int $year, \DateTimeInterface $expected): void /** * Tests translated name of New Years Day. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -60,7 +58,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { @@ -72,7 +70,7 @@ public function testHolidayType(): void * * @return array list of test dates for New Years Day * - * @throws Exception + * @throws \Exception */ public function NewYearsDayDataProvider(): array { diff --git a/tests/Switzerland/Schwyz/PentecostMondayTest.php b/tests/Switzerland/Schwyz/PentecostMondayTest.php index d7ffd26ca..b6d8253ef 100644 --- a/tests/Switzerland/Schwyz/PentecostMondayTest.php +++ b/tests/Switzerland/Schwyz/PentecostMondayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Switzerland\Schwyz; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -33,7 +30,7 @@ class PentecostMondayTest extends SchwyzBaseTestCase implements HolidayTestCase /** * Tests Pentecost Monday. * - * @throws Exception + * @throws \Exception */ public function testPentecostMonday(): void { @@ -42,14 +39,14 @@ public function testPentecostMonday(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-5-30", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-5-30", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests translated name of Pentecost Monday. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -64,7 +61,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Schwyz/SchwyzTest.php b/tests/Switzerland/Schwyz/SchwyzTest.php index d1f9650ed..e4427d9de 100644 --- a/tests/Switzerland/Schwyz/SchwyzTest.php +++ b/tests/Switzerland/Schwyz/SchwyzTest.php @@ -14,7 +14,6 @@ namespace Yasumi\tests\Switzerland\Schwyz; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\ProviderTestCase; @@ -110,7 +109,7 @@ public function testOtherHolidays(): void } /** - * @throws ReflectionException + * @throws \ReflectionException * @throws \Exception */ public function testSources(): void diff --git a/tests/Switzerland/Schwyz/StJosephDayTest.php b/tests/Switzerland/Schwyz/StJosephDayTest.php index 81227c2fa..598a64aca 100644 --- a/tests/Switzerland/Schwyz/StJosephDayTest.php +++ b/tests/Switzerland/Schwyz/StJosephDayTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\Switzerland\Schwyz; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\Provider\ChristianHolidays; use Yasumi\tests\HolidayTestCase; @@ -37,8 +35,8 @@ class StJosephDayTest extends SchwyzBaseTestCase implements HolidayTestCase * * @dataProvider StJosephDayDataProvider * - * @param int $year the year for which St. Joseph's Day needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which St. Joseph's Day needs to be tested + * @param \DateTime $expected the expected date */ public function testStJosephDay(int $year, \DateTimeInterface $expected): void { @@ -50,7 +48,7 @@ public function testStJosephDay(int $year, \DateTimeInterface $expected): void * * @return array list of test dates for St. Joseph's Day * - * @throws Exception + * @throws \Exception */ public function StJosephDayDataProvider(): array { @@ -60,7 +58,7 @@ public function StJosephDayDataProvider(): array /** * Tests translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -75,7 +73,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Schwyz/StStephensDayTest.php b/tests/Switzerland/Schwyz/StStephensDayTest.php index a84c13c76..57ce5b5c6 100644 --- a/tests/Switzerland/Schwyz/StStephensDayTest.php +++ b/tests/Switzerland/Schwyz/StStephensDayTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\Switzerland\Schwyz; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,8 +32,8 @@ class StStephensDayTest extends SchwyzBaseTestCase implements HolidayTestCase * * @dataProvider HolidayDataProvider * - * @param int $year the year for which the holiday defined in this test needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which the holiday defined in this test needs to be tested + * @param \DateTime $expected the expected date */ public function testHoliday(int $year, \DateTimeInterface $expected): void { @@ -47,7 +45,7 @@ public function testHoliday(int $year, \DateTimeInterface $expected): void * * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function HolidayDataProvider(): array { @@ -57,7 +55,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -72,7 +70,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Solothurn/AscensionDayTest.php b/tests/Switzerland/Solothurn/AscensionDayTest.php index 2b4253fa5..1202c03f4 100644 --- a/tests/Switzerland/Solothurn/AscensionDayTest.php +++ b/tests/Switzerland/Solothurn/AscensionDayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Switzerland\Solothurn; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -33,7 +30,7 @@ class AscensionDayTest extends SolothurnBaseTestCase implements HolidayTestCase /** * Tests Ascension Day. * - * @throws Exception + * @throws \Exception */ public function testAscensionDay(): void { @@ -42,14 +39,14 @@ public function testAscensionDay(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-5-16", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-5-16", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests translated name of Ascension Day. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -64,7 +61,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Solothurn/BerchtoldsTagTest.php b/tests/Switzerland/Solothurn/BerchtoldsTagTest.php index 9b51471a4..3b69426aa 100644 --- a/tests/Switzerland/Solothurn/BerchtoldsTagTest.php +++ b/tests/Switzerland/Solothurn/BerchtoldsTagTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Switzerland\Solothurn; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -33,12 +30,12 @@ class BerchtoldsTagTest extends SolothurnBaseTestCase implements HolidayTestCase /** * Tests BerchtoldsTag. * - * @throws Exception + * @throws \Exception */ public function testBerchtoldsTag(): void { $year = $this->generateRandomYear(); - $date = new DateTime($year.'-01-02', new DateTimeZone(self::TIMEZONE)); + $date = new \DateTime($year.'-01-02', new \DateTimeZone(self::TIMEZONE)); $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $date); $this->assertHolidayType(self::REGION, self::HOLIDAY, $year, Holiday::TYPE_OTHER); @@ -47,7 +44,7 @@ public function testBerchtoldsTag(): void /** * Tests translated name of BerchtoldsTag. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -62,7 +59,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Solothurn/ChristmasDayTest.php b/tests/Switzerland/Solothurn/ChristmasDayTest.php index 4918274fe..268c49de7 100644 --- a/tests/Switzerland/Solothurn/ChristmasDayTest.php +++ b/tests/Switzerland/Solothurn/ChristmasDayTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\Switzerland\Solothurn; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,8 +32,8 @@ class ChristmasDayTest extends SolothurnBaseTestCase implements HolidayTestCase * * @dataProvider ChristmasDayDataProvider * - * @param int $year the year for which Christmas Day needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which Christmas Day needs to be tested + * @param \DateTime $expected the expected date */ public function testChristmasDay(int $year, \DateTimeInterface $expected): void { @@ -47,7 +45,7 @@ public function testChristmasDay(int $year, \DateTimeInterface $expected): void * * @return array list of test dates for Christmas Day * - * @throws Exception + * @throws \Exception */ public function ChristmasDayDataProvider(): array { @@ -57,7 +55,7 @@ public function ChristmasDayDataProvider(): array /** * Tests translated name of Christmas Day. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -72,7 +70,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Solothurn/GoodFridayTest.php b/tests/Switzerland/Solothurn/GoodFridayTest.php index 8b1361c31..a9c31fb7a 100644 --- a/tests/Switzerland/Solothurn/GoodFridayTest.php +++ b/tests/Switzerland/Solothurn/GoodFridayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Switzerland\Solothurn; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -33,7 +30,7 @@ class GoodFridayTest extends SolothurnBaseTestCase implements HolidayTestCase /** * Tests the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHoliday(): void { @@ -42,14 +39,14 @@ public function testHoliday(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-3-21", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-3-21", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -64,7 +61,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Solothurn/NewYearsDayTest.php b/tests/Switzerland/Solothurn/NewYearsDayTest.php index 3989e7799..47e4d754f 100644 --- a/tests/Switzerland/Solothurn/NewYearsDayTest.php +++ b/tests/Switzerland/Solothurn/NewYearsDayTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\Switzerland\Solothurn; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,8 +32,8 @@ class NewYearsDayTest extends SolothurnBaseTestCase implements HolidayTestCase * * @dataProvider NewYearsDayDataProvider * - * @param int $year the year for which New Years Day needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which New Years Day needs to be tested + * @param \DateTime $expected the expected date */ public function testNewYearsDay(int $year, \DateTimeInterface $expected): void { @@ -45,7 +43,7 @@ public function testNewYearsDay(int $year, \DateTimeInterface $expected): void /** * Tests translated name of New Years Day. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -60,7 +58,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { @@ -72,7 +70,7 @@ public function testHolidayType(): void * * @return array list of test dates for New Years Day * - * @throws Exception + * @throws \Exception */ public function NewYearsDayDataProvider(): array { diff --git a/tests/Switzerland/Solothurn/SolothurnTest.php b/tests/Switzerland/Solothurn/SolothurnTest.php index ce2c28dfc..20aa5454d 100644 --- a/tests/Switzerland/Solothurn/SolothurnTest.php +++ b/tests/Switzerland/Solothurn/SolothurnTest.php @@ -14,7 +14,6 @@ namespace Yasumi\tests\Switzerland\Solothurn; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\ProviderTestCase; @@ -103,7 +102,7 @@ public function testOtherHolidays(): void } /** - * @throws ReflectionException + * @throws \ReflectionException * @throws \Exception */ public function testSources(): void diff --git a/tests/Switzerland/StGallen/AllSaintsDayTest.php b/tests/Switzerland/StGallen/AllSaintsDayTest.php index 2c6f3a22b..77fa3ef56 100644 --- a/tests/Switzerland/StGallen/AllSaintsDayTest.php +++ b/tests/Switzerland/StGallen/AllSaintsDayTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\Switzerland\StGallen; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,8 +32,8 @@ class AllSaintsDayTest extends StGallenBaseTestCase implements HolidayTestCase * * @dataProvider AllSaintsDayDataProvider * - * @param int $year the year for which All Saints' Day needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which All Saints' Day needs to be tested + * @param \DateTime $expected the expected date */ public function testAllSaintsDay(int $year, \DateTimeInterface $expected): void { @@ -45,7 +43,7 @@ public function testAllSaintsDay(int $year, \DateTimeInterface $expected): void /** * Tests translated name of All Saints' Day. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -60,7 +58,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { @@ -72,7 +70,7 @@ public function testHolidayType(): void * * @return array list of test dates for All Saints' Day * - * @throws Exception + * @throws \Exception */ public function AllSaintsDayDataProvider(): array { diff --git a/tests/Switzerland/StGallen/AscensionDayTest.php b/tests/Switzerland/StGallen/AscensionDayTest.php index ac22c2588..3702e5912 100644 --- a/tests/Switzerland/StGallen/AscensionDayTest.php +++ b/tests/Switzerland/StGallen/AscensionDayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Switzerland\StGallen; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -33,7 +30,7 @@ class AscensionDayTest extends StGallenBaseTestCase implements HolidayTestCase /** * Tests Ascension Day. * - * @throws Exception + * @throws \Exception */ public function testAscensionDay(): void { @@ -42,14 +39,14 @@ public function testAscensionDay(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-5-16", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-5-16", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests translated name of Ascension Day. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -64,7 +61,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/StGallen/ChristmasDayTest.php b/tests/Switzerland/StGallen/ChristmasDayTest.php index 30f10cdb9..ba508e053 100644 --- a/tests/Switzerland/StGallen/ChristmasDayTest.php +++ b/tests/Switzerland/StGallen/ChristmasDayTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\Switzerland\StGallen; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,8 +32,8 @@ class ChristmasDayTest extends StGallenBaseTestCase implements HolidayTestCase * * @dataProvider ChristmasDayDataProvider * - * @param int $year the year for which Christmas Day needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which Christmas Day needs to be tested + * @param \DateTime $expected the expected date */ public function testChristmasDay(int $year, \DateTimeInterface $expected): void { @@ -47,7 +45,7 @@ public function testChristmasDay(int $year, \DateTimeInterface $expected): void * * @return array list of test dates for Christmas Day * - * @throws Exception + * @throws \Exception */ public function ChristmasDayDataProvider(): array { @@ -57,7 +55,7 @@ public function ChristmasDayDataProvider(): array /** * Tests translated name of Christmas Day. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -72,7 +70,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/StGallen/EasterMondayTest.php b/tests/Switzerland/StGallen/EasterMondayTest.php index 682cc2633..b6c44c132 100644 --- a/tests/Switzerland/StGallen/EasterMondayTest.php +++ b/tests/Switzerland/StGallen/EasterMondayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Switzerland\StGallen; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -33,7 +30,7 @@ class EasterMondayTest extends StGallenBaseTestCase implements HolidayTestCase /** * Tests Easter Monday. * - * @throws Exception + * @throws \Exception */ public function testEasterMonday(): void { @@ -42,14 +39,14 @@ public function testEasterMonday(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-3-28", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-3-28", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests translated name of Easter Monday. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -64,7 +61,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/StGallen/GoodFridayTest.php b/tests/Switzerland/StGallen/GoodFridayTest.php index dea1c7c96..8c5c4d5b6 100644 --- a/tests/Switzerland/StGallen/GoodFridayTest.php +++ b/tests/Switzerland/StGallen/GoodFridayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Switzerland\StGallen; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -33,7 +30,7 @@ class GoodFridayTest extends StGallenBaseTestCase implements HolidayTestCase /** * Tests the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHoliday(): void { @@ -42,14 +39,14 @@ public function testHoliday(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-3-21", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-3-21", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -64,7 +61,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/StGallen/NewYearsDayTest.php b/tests/Switzerland/StGallen/NewYearsDayTest.php index 4f204d789..4de3ca4e4 100644 --- a/tests/Switzerland/StGallen/NewYearsDayTest.php +++ b/tests/Switzerland/StGallen/NewYearsDayTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\Switzerland\StGallen; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,8 +32,8 @@ class NewYearsDayTest extends StGallenBaseTestCase implements HolidayTestCase * * @dataProvider NewYearsDayDataProvider * - * @param int $year the year for which New Years Day needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which New Years Day needs to be tested + * @param \DateTime $expected the expected date */ public function testNewYearsDay(int $year, \DateTimeInterface $expected): void { @@ -45,7 +43,7 @@ public function testNewYearsDay(int $year, \DateTimeInterface $expected): void /** * Tests translated name of New Years Day. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -60,7 +58,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { @@ -72,7 +70,7 @@ public function testHolidayType(): void * * @return array list of test dates for New Years Day * - * @throws Exception + * @throws \Exception */ public function NewYearsDayDataProvider(): array { diff --git a/tests/Switzerland/StGallen/PentecostMondayTest.php b/tests/Switzerland/StGallen/PentecostMondayTest.php index 972cc621c..f4172572e 100644 --- a/tests/Switzerland/StGallen/PentecostMondayTest.php +++ b/tests/Switzerland/StGallen/PentecostMondayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Switzerland\StGallen; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -33,7 +30,7 @@ class PentecostMondayTest extends StGallenBaseTestCase implements HolidayTestCas /** * Tests Pentecost Monday. * - * @throws Exception + * @throws \Exception */ public function testPentecostMonday(): void { @@ -42,14 +39,14 @@ public function testPentecostMonday(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-5-30", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-5-30", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests translated name of Pentecost Monday. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -64,7 +61,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/StGallen/StGallenTest.php b/tests/Switzerland/StGallen/StGallenTest.php index 23046de5c..b5fcb12f2 100644 --- a/tests/Switzerland/StGallen/StGallenTest.php +++ b/tests/Switzerland/StGallen/StGallenTest.php @@ -14,7 +14,6 @@ namespace Yasumi\tests\Switzerland\StGallen; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\ProviderTestCase; @@ -105,7 +104,7 @@ public function testOtherHolidays(): void } /** - * @throws ReflectionException + * @throws \ReflectionException * @throws \Exception */ public function testSources(): void diff --git a/tests/Switzerland/StGallen/StStephensDayTest.php b/tests/Switzerland/StGallen/StStephensDayTest.php index e8486d5aa..c56a87765 100644 --- a/tests/Switzerland/StGallen/StStephensDayTest.php +++ b/tests/Switzerland/StGallen/StStephensDayTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\Switzerland\StGallen; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,8 +32,8 @@ class StStephensDayTest extends StGallenBaseTestCase implements HolidayTestCase * * @dataProvider HolidayDataProvider * - * @param int $year the year for which the holiday defined in this test needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which the holiday defined in this test needs to be tested + * @param \DateTime $expected the expected date */ public function testHoliday(int $year, \DateTimeInterface $expected): void { @@ -47,7 +45,7 @@ public function testHoliday(int $year, \DateTimeInterface $expected): void * * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function HolidayDataProvider(): array { @@ -57,7 +55,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -72,7 +70,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/SwissNationalDayTest.php b/tests/Switzerland/SwissNationalDayTest.php index 579b38228..05b25d75b 100644 --- a/tests/Switzerland/SwissNationalDayTest.php +++ b/tests/Switzerland/SwissNationalDayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Switzerland; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -48,7 +45,7 @@ class SwissNationalDayTest extends SwitzerlandBaseTestCase implements HolidayTes /** * Tests National Day on or after 1994. * - * @throws Exception + * @throws \Exception */ public function testNationalDayOnAfter1994(): void { @@ -57,14 +54,14 @@ public function testNationalDayOnAfter1994(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-8-01", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-8-01", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests National Day on or after 1899 and before 1994. * - * @throws Exception + * @throws \Exception */ public function testNationalDayOnAfter1899(): void { @@ -73,7 +70,7 @@ public function testNationalDayOnAfter1899(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-8-01", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-8-01", new \DateTimeZone(self::TIMEZONE)) ); $this->assertHolidayType(self::REGION, self::HOLIDAY, $year, Holiday::TYPE_OBSERVANCE); } @@ -81,7 +78,7 @@ public function testNationalDayOnAfter1899(): void /** * Tests National Day on 1891. * - * @throws Exception + * @throws \Exception */ public function testNationalDayOn1891(): void { @@ -90,7 +87,7 @@ public function testNationalDayOn1891(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-8-01", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-8-01", new \DateTimeZone(self::TIMEZONE)) ); $this->assertHolidayType(self::REGION, self::HOLIDAY, $year, Holiday::TYPE_OBSERVANCE); } @@ -98,7 +95,7 @@ public function testNationalDayOn1891(): void /** * Tests National Day before 1891. * - * @throws Exception + * @throws \Exception */ public function testNationalDayBefore1891(): void { @@ -112,7 +109,7 @@ public function testNationalDayBefore1891(): void /** * Tests National Day between 1891 and 1899. * - * @throws Exception + * @throws \Exception */ public function testNationalDayBetween1891And1899(): void { @@ -123,7 +120,7 @@ public function testNationalDayBetween1891And1899(): void /** * Tests translated name of National Day. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -138,7 +135,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/SwitzerlandTest.php b/tests/Switzerland/SwitzerlandTest.php index 28bded230..c8cbc8ca9 100644 --- a/tests/Switzerland/SwitzerlandTest.php +++ b/tests/Switzerland/SwitzerlandTest.php @@ -14,7 +14,6 @@ namespace Yasumi\tests\Switzerland; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\ProviderTestCase; @@ -88,7 +87,7 @@ public function testOtherHolidays(): void } /** - * @throws ReflectionException + * @throws \ReflectionException * @throws \Exception */ public function testSources(): void diff --git a/tests/Switzerland/Thurgau/AscensionDayTest.php b/tests/Switzerland/Thurgau/AscensionDayTest.php index a0a90bb72..31b7bb9ea 100644 --- a/tests/Switzerland/Thurgau/AscensionDayTest.php +++ b/tests/Switzerland/Thurgau/AscensionDayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Switzerland\Thurgau; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -33,7 +30,7 @@ class AscensionDayTest extends ThurgauBaseTestCase implements HolidayTestCase /** * Tests Ascension Day. * - * @throws Exception + * @throws \Exception */ public function testAscensionDay(): void { @@ -42,14 +39,14 @@ public function testAscensionDay(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-5-16", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-5-16", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests translated name of Ascension Day. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -64,7 +61,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Thurgau/BerchtoldsTagTest.php b/tests/Switzerland/Thurgau/BerchtoldsTagTest.php index 23a138dcf..9c734b387 100644 --- a/tests/Switzerland/Thurgau/BerchtoldsTagTest.php +++ b/tests/Switzerland/Thurgau/BerchtoldsTagTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Switzerland\Thurgau; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -33,12 +30,12 @@ class BerchtoldsTagTest extends ThurgauBaseTestCase implements HolidayTestCase /** * Tests BerchtoldsTag. * - * @throws Exception + * @throws \Exception */ public function testBerchtoldsTag(): void { $year = $this->generateRandomYear(); - $date = new DateTime($year.'-01-02', new DateTimeZone(self::TIMEZONE)); + $date = new \DateTime($year.'-01-02', new \DateTimeZone(self::TIMEZONE)); $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $date); $this->assertHolidayType(self::REGION, self::HOLIDAY, $year, Holiday::TYPE_OTHER); @@ -47,7 +44,7 @@ public function testBerchtoldsTag(): void /** * Tests translated name of BerchtoldsTag. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -62,7 +59,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Thurgau/ChristmasDayTest.php b/tests/Switzerland/Thurgau/ChristmasDayTest.php index b8cab2e5a..04da2721c 100644 --- a/tests/Switzerland/Thurgau/ChristmasDayTest.php +++ b/tests/Switzerland/Thurgau/ChristmasDayTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\Switzerland\Thurgau; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,8 +32,8 @@ class ChristmasDayTest extends ThurgauBaseTestCase implements HolidayTestCase * * @dataProvider ChristmasDayDataProvider * - * @param int $year the year for which Christmas Day needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which Christmas Day needs to be tested + * @param \DateTime $expected the expected date */ public function testChristmasDay(int $year, \DateTimeInterface $expected): void { @@ -47,7 +45,7 @@ public function testChristmasDay(int $year, \DateTimeInterface $expected): void * * @return array list of test dates for Christmas Day * - * @throws Exception + * @throws \Exception */ public function ChristmasDayDataProvider(): array { @@ -57,7 +55,7 @@ public function ChristmasDayDataProvider(): array /** * Tests translated name of Christmas Day. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -72,7 +70,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Thurgau/EasterMondayTest.php b/tests/Switzerland/Thurgau/EasterMondayTest.php index bbfea0fcf..44cff9928 100644 --- a/tests/Switzerland/Thurgau/EasterMondayTest.php +++ b/tests/Switzerland/Thurgau/EasterMondayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Switzerland\Thurgau; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -33,7 +30,7 @@ class EasterMondayTest extends ThurgauBaseTestCase implements HolidayTestCase /** * Tests Easter Monday. * - * @throws Exception + * @throws \Exception */ public function testEasterMonday(): void { @@ -42,14 +39,14 @@ public function testEasterMonday(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-3-28", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-3-28", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests translated name of Easter Monday. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -64,7 +61,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Thurgau/GoodFridayTest.php b/tests/Switzerland/Thurgau/GoodFridayTest.php index 9729446c6..cc873291b 100644 --- a/tests/Switzerland/Thurgau/GoodFridayTest.php +++ b/tests/Switzerland/Thurgau/GoodFridayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Switzerland\Thurgau; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -33,7 +30,7 @@ class GoodFridayTest extends ThurgauBaseTestCase implements HolidayTestCase /** * Tests the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHoliday(): void { @@ -42,14 +39,14 @@ public function testHoliday(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-3-21", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-3-21", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -64,7 +61,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Thurgau/NewYearsDayTest.php b/tests/Switzerland/Thurgau/NewYearsDayTest.php index bf9879738..569a24b84 100644 --- a/tests/Switzerland/Thurgau/NewYearsDayTest.php +++ b/tests/Switzerland/Thurgau/NewYearsDayTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\Switzerland\Thurgau; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,8 +32,8 @@ class NewYearsDayTest extends ThurgauBaseTestCase implements HolidayTestCase * * @dataProvider NewYearsDayDataProvider * - * @param int $year the year for which New Years Day needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which New Years Day needs to be tested + * @param \DateTime $expected the expected date */ public function testNewYearsDay(int $year, \DateTimeInterface $expected): void { @@ -45,7 +43,7 @@ public function testNewYearsDay(int $year, \DateTimeInterface $expected): void /** * Tests translated name of New Years Day. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -60,7 +58,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { @@ -72,7 +70,7 @@ public function testHolidayType(): void * * @return array list of test dates for New Years Day * - * @throws Exception + * @throws \Exception */ public function NewYearsDayDataProvider(): array { diff --git a/tests/Switzerland/Thurgau/PentecostMondayTest.php b/tests/Switzerland/Thurgau/PentecostMondayTest.php index 344c9e7c1..20b04efc4 100644 --- a/tests/Switzerland/Thurgau/PentecostMondayTest.php +++ b/tests/Switzerland/Thurgau/PentecostMondayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Switzerland\Thurgau; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -33,7 +30,7 @@ class PentecostMondayTest extends ThurgauBaseTestCase implements HolidayTestCase /** * Tests Pentecost Monday. * - * @throws Exception + * @throws \Exception */ public function testPentecostMonday(): void { @@ -42,14 +39,14 @@ public function testPentecostMonday(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-5-30", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-5-30", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests translated name of Pentecost Monday. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -64,7 +61,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Thurgau/StStephensDayTest.php b/tests/Switzerland/Thurgau/StStephensDayTest.php index 287baed36..70dcba747 100644 --- a/tests/Switzerland/Thurgau/StStephensDayTest.php +++ b/tests/Switzerland/Thurgau/StStephensDayTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\Switzerland\Thurgau; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,8 +32,8 @@ class StStephensDayTest extends ThurgauBaseTestCase implements HolidayTestCase * * @dataProvider HolidayDataProvider * - * @param int $year the year for which the holiday defined in this test needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which the holiday defined in this test needs to be tested + * @param \DateTime $expected the expected date */ public function testHoliday(int $year, \DateTimeInterface $expected): void { @@ -47,7 +45,7 @@ public function testHoliday(int $year, \DateTimeInterface $expected): void * * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function HolidayDataProvider(): array { @@ -57,7 +55,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -72,7 +70,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Thurgau/ThurgauTest.php b/tests/Switzerland/Thurgau/ThurgauTest.php index 494a1999d..48539152f 100644 --- a/tests/Switzerland/Thurgau/ThurgauTest.php +++ b/tests/Switzerland/Thurgau/ThurgauTest.php @@ -14,7 +14,6 @@ namespace Yasumi\tests\Switzerland\Thurgau; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\ProviderTestCase; @@ -106,7 +105,7 @@ public function testOtherHolidays(): void } /** - * @throws ReflectionException + * @throws \ReflectionException * @throws \Exception */ public function testSources(): void diff --git a/tests/Switzerland/Thurgau/WorkersDayTest.php b/tests/Switzerland/Thurgau/WorkersDayTest.php index f65c71514..219d77b1a 100644 --- a/tests/Switzerland/Thurgau/WorkersDayTest.php +++ b/tests/Switzerland/Thurgau/WorkersDayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Switzerland\Thurgau; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -38,11 +35,11 @@ class WorkersDayTest extends ThurgauBaseTestCase implements HolidayTestCase * @param int $year the year for which the holiday defined in this test needs to be tested * @param string $expected the expected date * - * @throws Exception + * @throws \Exception */ public function testHoliday(int $year, string $expected): void { - $date = new DateTime($expected, new DateTimeZone(self::TIMEZONE)); + $date = new \DateTime($expected, new \DateTimeZone(self::TIMEZONE)); $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $date); } @@ -51,7 +48,7 @@ public function testHoliday(int $year, string $expected): void * * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function HolidayDataProvider(): array { @@ -59,7 +56,7 @@ public function HolidayDataProvider(): array for ($y = 0; $y < 50; ++$y) { $year = $this->generateRandomYear(); - $date = new DateTime("$year-5-1", new DateTimeZone(self::TIMEZONE)); + $date = new \DateTime("$year-5-1", new \DateTimeZone(self::TIMEZONE)); $data[] = [$year, $date->format('Y-m-d')]; } @@ -69,7 +66,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -84,7 +81,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Ticino/AllSaintsDayTest.php b/tests/Switzerland/Ticino/AllSaintsDayTest.php index 87977ce56..8e8dcef90 100644 --- a/tests/Switzerland/Ticino/AllSaintsDayTest.php +++ b/tests/Switzerland/Ticino/AllSaintsDayTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\Switzerland\Ticino; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,8 +32,8 @@ class AllSaintsDayTest extends TicinoBaseTestCase implements HolidayTestCase * * @dataProvider AllSaintsDayDataProvider * - * @param int $year the year for which All Saints' Day needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which All Saints' Day needs to be tested + * @param \DateTime $expected the expected date */ public function testAllSaintsDay(int $year, \DateTimeInterface $expected): void { @@ -45,7 +43,7 @@ public function testAllSaintsDay(int $year, \DateTimeInterface $expected): void /** * Tests translated name of All Saints' Day. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -60,7 +58,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { @@ -72,7 +70,7 @@ public function testHolidayType(): void * * @return array list of test dates for All Saints' Day * - * @throws Exception + * @throws \Exception */ public function AllSaintsDayDataProvider(): array { diff --git a/tests/Switzerland/Ticino/AscensionDayTest.php b/tests/Switzerland/Ticino/AscensionDayTest.php index 1867ea58d..1d78be1f6 100644 --- a/tests/Switzerland/Ticino/AscensionDayTest.php +++ b/tests/Switzerland/Ticino/AscensionDayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Switzerland\Ticino; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -33,7 +30,7 @@ class AscensionDayTest extends TicinoBaseTestCase implements HolidayTestCase /** * Tests Ascension Day. * - * @throws Exception + * @throws \Exception */ public function testAscensionDay(): void { @@ -42,14 +39,14 @@ public function testAscensionDay(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-5-16", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-5-16", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests translated name of Ascension Day. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -64,7 +61,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Ticino/AssumptionOfMaryTest.php b/tests/Switzerland/Ticino/AssumptionOfMaryTest.php index 81dacfa4e..265025b4e 100644 --- a/tests/Switzerland/Ticino/AssumptionOfMaryTest.php +++ b/tests/Switzerland/Ticino/AssumptionOfMaryTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\Switzerland\Ticino; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,8 +32,8 @@ class AssumptionOfMaryTest extends TicinoBaseTestCase implements HolidayTestCase * * @dataProvider AssumptionOfMaryDataProvider * - * @param int $year the year for which the day of the Assumption of Mary needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which the day of the Assumption of Mary needs to be tested + * @param \DateTime $expected the expected date */ public function testAssumptionOfMary(int $year, \DateTimeInterface $expected): void { @@ -45,7 +43,7 @@ public function testAssumptionOfMary(int $year, \DateTimeInterface $expected): v /** * Tests translated name of the day of the Assumption of Mary. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -60,7 +58,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { @@ -72,7 +70,7 @@ public function testHolidayType(): void * * @return array list of test dates for the day of the Assumption of Mary * - * @throws Exception + * @throws \Exception */ public function AssumptionOfMaryDataProvider(): array { diff --git a/tests/Switzerland/Ticino/ChristmasDayTest.php b/tests/Switzerland/Ticino/ChristmasDayTest.php index ef945d09f..cbd631065 100644 --- a/tests/Switzerland/Ticino/ChristmasDayTest.php +++ b/tests/Switzerland/Ticino/ChristmasDayTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\Switzerland\Ticino; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,8 +32,8 @@ class ChristmasDayTest extends TicinoBaseTestCase implements HolidayTestCase * * @dataProvider ChristmasDayDataProvider * - * @param int $year the year for which Christmas Day needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which Christmas Day needs to be tested + * @param \DateTime $expected the expected date */ public function testChristmasDay(int $year, \DateTimeInterface $expected): void { @@ -47,7 +45,7 @@ public function testChristmasDay(int $year, \DateTimeInterface $expected): void * * @return array list of test dates for Christmas Day * - * @throws Exception + * @throws \Exception */ public function ChristmasDayDataProvider(): array { @@ -57,7 +55,7 @@ public function ChristmasDayDataProvider(): array /** * Tests translated name of Christmas Day. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -72,7 +70,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Ticino/CorpusChristiTest.php b/tests/Switzerland/Ticino/CorpusChristiTest.php index d345a7a0d..a5a9f781d 100644 --- a/tests/Switzerland/Ticino/CorpusChristiTest.php +++ b/tests/Switzerland/Ticino/CorpusChristiTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\Switzerland\Ticino; -use DateInterval; -use Exception; use Yasumi\Holiday; use Yasumi\Provider\ChristianHolidays; use Yasumi\tests\HolidayTestCase; @@ -35,7 +33,7 @@ class CorpusChristiTest extends TicinoBaseTestCase implements HolidayTestCase /** * Tests Corpus Christi. * - * @throws Exception + * @throws \Exception */ public function testCorpusChristi(): void { @@ -44,14 +42,14 @@ public function testCorpusChristi(): void self::REGION, self::HOLIDAY, $year, - $this->calculateEaster($year, self::TIMEZONE)->add(new DateInterval('P60D')) + $this->calculateEaster($year, self::TIMEZONE)->add(new \DateInterval('P60D')) ); } /** * Tests translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -66,7 +64,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Ticino/EasterMondayTest.php b/tests/Switzerland/Ticino/EasterMondayTest.php index 9db726d3a..b224fbaba 100644 --- a/tests/Switzerland/Ticino/EasterMondayTest.php +++ b/tests/Switzerland/Ticino/EasterMondayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Switzerland\Ticino; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -33,7 +30,7 @@ class EasterMondayTest extends TicinoBaseTestCase implements HolidayTestCase /** * Tests Easter Monday. * - * @throws Exception + * @throws \Exception */ public function testEasterMonday(): void { @@ -42,14 +39,14 @@ public function testEasterMonday(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-3-28", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-3-28", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests translated name of Easter Monday. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -64,7 +61,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Ticino/EpiphanyTest.php b/tests/Switzerland/Ticino/EpiphanyTest.php index 3dcd58409..7c2b5e26b 100644 --- a/tests/Switzerland/Ticino/EpiphanyTest.php +++ b/tests/Switzerland/Ticino/EpiphanyTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\Switzerland\Ticino; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,8 +32,8 @@ class EpiphanyTest extends TicinoBaseTestCase implements HolidayTestCase * * @dataProvider HolidayDataProvider * - * @param int $year the year for which the holiday defined in this test needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which the holiday defined in this test needs to be tested + * @param \DateTime $expected the expected date */ public function testHoliday(int $year, \DateTimeInterface $expected): void { @@ -47,7 +45,7 @@ public function testHoliday(int $year, \DateTimeInterface $expected): void * * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function HolidayDataProvider(): array { @@ -57,7 +55,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -72,7 +70,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Ticino/ImmaculateConceptionTest.php b/tests/Switzerland/Ticino/ImmaculateConceptionTest.php index ad2cf3483..0a7ea8960 100644 --- a/tests/Switzerland/Ticino/ImmaculateConceptionTest.php +++ b/tests/Switzerland/Ticino/ImmaculateConceptionTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\Switzerland\Ticino; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,8 +32,8 @@ class ImmaculateConceptionTest extends TicinoBaseTestCase implements HolidayTest * * @dataProvider HolidayDataProvider * - * @param int $year the year for which the holiday defined in this test needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which the holiday defined in this test needs to be tested + * @param \DateTime $expected the expected date */ public function testHoliday(int $year, \DateTimeInterface $expected): void { @@ -47,7 +45,7 @@ public function testHoliday(int $year, \DateTimeInterface $expected): void * * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function HolidayDataProvider(): array { @@ -57,7 +55,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -72,7 +70,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Ticino/NewYearsDayTest.php b/tests/Switzerland/Ticino/NewYearsDayTest.php index 427b76e03..63a33d7e8 100644 --- a/tests/Switzerland/Ticino/NewYearsDayTest.php +++ b/tests/Switzerland/Ticino/NewYearsDayTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\Switzerland\Ticino; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,8 +32,8 @@ class NewYearsDayTest extends TicinoBaseTestCase implements HolidayTestCase * * @dataProvider NewYearsDayDataProvider * - * @param int $year the year for which New Years Day needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which New Years Day needs to be tested + * @param \DateTime $expected the expected date */ public function testNewYearsDay(int $year, \DateTimeInterface $expected): void { @@ -45,7 +43,7 @@ public function testNewYearsDay(int $year, \DateTimeInterface $expected): void /** * Tests translated name of New Years Day. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -60,7 +58,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { @@ -72,7 +70,7 @@ public function testHolidayType(): void * * @return array list of test dates for New Years Day * - * @throws Exception + * @throws \Exception */ public function NewYearsDayDataProvider(): array { diff --git a/tests/Switzerland/Ticino/PentecostMondayTest.php b/tests/Switzerland/Ticino/PentecostMondayTest.php index 90fd7b218..bb54703b8 100644 --- a/tests/Switzerland/Ticino/PentecostMondayTest.php +++ b/tests/Switzerland/Ticino/PentecostMondayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Switzerland\Ticino; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -33,7 +30,7 @@ class PentecostMondayTest extends TicinoBaseTestCase implements HolidayTestCase /** * Tests Pentecost Monday. * - * @throws Exception + * @throws \Exception */ public function testPentecostMonday(): void { @@ -42,14 +39,14 @@ public function testPentecostMonday(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-5-30", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-5-30", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests translated name of Pentecost Monday. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -64,7 +61,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Ticino/StJosephDayTest.php b/tests/Switzerland/Ticino/StJosephDayTest.php index 437637c4f..ce2f71190 100644 --- a/tests/Switzerland/Ticino/StJosephDayTest.php +++ b/tests/Switzerland/Ticino/StJosephDayTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\Switzerland\Ticino; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\Provider\ChristianHolidays; use Yasumi\tests\HolidayTestCase; @@ -37,8 +35,8 @@ class StJosephDayTest extends TicinoBaseTestCase implements HolidayTestCase * * @dataProvider StJosephDayDataProvider * - * @param int $year the year for which St. Joseph's Day needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which St. Joseph's Day needs to be tested + * @param \DateTime $expected the expected date */ public function testStJosephDay(int $year, \DateTimeInterface $expected): void { @@ -50,7 +48,7 @@ public function testStJosephDay(int $year, \DateTimeInterface $expected): void * * @return array list of test dates for St. Joseph's Day * - * @throws Exception + * @throws \Exception */ public function StJosephDayDataProvider(): array { @@ -60,7 +58,7 @@ public function StJosephDayDataProvider(): array /** * Tests translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -75,7 +73,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Ticino/StPeterPaulTest.php b/tests/Switzerland/Ticino/StPeterPaulTest.php index 3bbf91e79..5ad38982c 100644 --- a/tests/Switzerland/Ticino/StPeterPaulTest.php +++ b/tests/Switzerland/Ticino/StPeterPaulTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\Switzerland\Ticino; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,8 +32,8 @@ class StPeterPaulTest extends TicinoBaseTestCase implements HolidayTestCase * * @dataProvider StPeterPaulDataProvider * - * @param int $year the year for which Feast of Saints Peter and Paul needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which Feast of Saints Peter and Paul needs to be tested + * @param \DateTime $expected the expected date */ public function testStPeterPaul(int $year, \DateTimeInterface $expected): void { @@ -47,7 +45,7 @@ public function testStPeterPaul(int $year, \DateTimeInterface $expected): void * * @return array list of test dates for Feast of Saints Peter and Paul * - * @throws Exception + * @throws \Exception */ public function StPeterPaulDataProvider(): array { @@ -57,7 +55,7 @@ public function StPeterPaulDataProvider(): array /** * Tests translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -72,7 +70,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Ticino/StStephensDayTest.php b/tests/Switzerland/Ticino/StStephensDayTest.php index cf0a1208e..3568672bd 100644 --- a/tests/Switzerland/Ticino/StStephensDayTest.php +++ b/tests/Switzerland/Ticino/StStephensDayTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\Switzerland\Ticino; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,8 +32,8 @@ class StStephensDayTest extends TicinoBaseTestCase implements HolidayTestCase * * @dataProvider HolidayDataProvider * - * @param int $year the year for which the holiday defined in this test needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which the holiday defined in this test needs to be tested + * @param \DateTime $expected the expected date */ public function testHoliday(int $year, \DateTimeInterface $expected): void { @@ -47,7 +45,7 @@ public function testHoliday(int $year, \DateTimeInterface $expected): void * * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function HolidayDataProvider(): array { @@ -57,7 +55,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -72,7 +70,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Ticino/TicinoTest.php b/tests/Switzerland/Ticino/TicinoTest.php index 18f22380b..8efb46733 100644 --- a/tests/Switzerland/Ticino/TicinoTest.php +++ b/tests/Switzerland/Ticino/TicinoTest.php @@ -14,7 +14,6 @@ namespace Yasumi\tests\Switzerland\Ticino; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\ProviderTestCase; @@ -111,7 +110,7 @@ public function testOtherHolidays(): void } /** - * @throws ReflectionException + * @throws \ReflectionException * @throws \Exception */ public function testSources(): void diff --git a/tests/Switzerland/Ticino/WorkersDayTest.php b/tests/Switzerland/Ticino/WorkersDayTest.php index bba2bf48a..97dc71bdc 100644 --- a/tests/Switzerland/Ticino/WorkersDayTest.php +++ b/tests/Switzerland/Ticino/WorkersDayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Switzerland\Ticino; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -38,11 +35,11 @@ class WorkersDayTest extends TicinoBaseTestCase implements HolidayTestCase * @param int $year the year for which the holiday defined in this test needs to be tested * @param string $expected the expected date * - * @throws Exception + * @throws \Exception */ public function testHoliday(int $year, string $expected): void { - $date = new DateTime($expected, new DateTimeZone(self::TIMEZONE)); + $date = new \DateTime($expected, new \DateTimeZone(self::TIMEZONE)); $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $date); } @@ -51,7 +48,7 @@ public function testHoliday(int $year, string $expected): void * * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function HolidayDataProvider(): array { @@ -59,7 +56,7 @@ public function HolidayDataProvider(): array for ($y = 0; $y < 50; ++$y) { $year = $this->generateRandomYear(); - $date = new DateTime("$year-5-1", new DateTimeZone(self::TIMEZONE)); + $date = new \DateTime("$year-5-1", new \DateTimeZone(self::TIMEZONE)); $data[] = [$year, $date->format('Y-m-d')]; } @@ -69,7 +66,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -84,7 +81,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Uri/AllSaintsDayTest.php b/tests/Switzerland/Uri/AllSaintsDayTest.php index d16b2f67a..b9ed20d58 100644 --- a/tests/Switzerland/Uri/AllSaintsDayTest.php +++ b/tests/Switzerland/Uri/AllSaintsDayTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\Switzerland\Uri; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,8 +32,8 @@ class AllSaintsDayTest extends UriBaseTestCase implements HolidayTestCase * * @dataProvider AllSaintsDayDataProvider * - * @param int $year the year for which All Saints' Day needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which All Saints' Day needs to be tested + * @param \DateTime $expected the expected date */ public function testAllSaintsDay(int $year, \DateTimeInterface $expected): void { @@ -45,7 +43,7 @@ public function testAllSaintsDay(int $year, \DateTimeInterface $expected): void /** * Tests translated name of All Saints' Day. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -60,7 +58,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { @@ -72,7 +70,7 @@ public function testHolidayType(): void * * @return array list of test dates for All Saints' Day * - * @throws Exception + * @throws \Exception */ public function AllSaintsDayDataProvider(): array { diff --git a/tests/Switzerland/Uri/AscensionDayTest.php b/tests/Switzerland/Uri/AscensionDayTest.php index f9daafea8..645ef3a97 100644 --- a/tests/Switzerland/Uri/AscensionDayTest.php +++ b/tests/Switzerland/Uri/AscensionDayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Switzerland\Uri; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -33,7 +30,7 @@ class AscensionDayTest extends UriBaseTestCase implements HolidayTestCase /** * Tests Ascension Day. * - * @throws Exception + * @throws \Exception */ public function testAscensionDay(): void { @@ -42,14 +39,14 @@ public function testAscensionDay(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-5-16", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-5-16", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests translated name of Ascension Day. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -64,7 +61,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Uri/AssumptionOfMaryTest.php b/tests/Switzerland/Uri/AssumptionOfMaryTest.php index 48c6c6d1d..e2c32be69 100644 --- a/tests/Switzerland/Uri/AssumptionOfMaryTest.php +++ b/tests/Switzerland/Uri/AssumptionOfMaryTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\Switzerland\Uri; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,8 +32,8 @@ class AssumptionOfMaryTest extends UriBaseTestCase implements HolidayTestCase * * @dataProvider AssumptionOfMaryDataProvider * - * @param int $year the year for which the day of the Assumption of Mary needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which the day of the Assumption of Mary needs to be tested + * @param \DateTime $expected the expected date */ public function testAssumptionOfMary(int $year, \DateTimeInterface $expected): void { @@ -45,7 +43,7 @@ public function testAssumptionOfMary(int $year, \DateTimeInterface $expected): v /** * Tests translated name of the day of the Assumption of Mary. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -60,7 +58,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { @@ -72,7 +70,7 @@ public function testHolidayType(): void * * @return array list of test dates for the day of the Assumption of Mary * - * @throws Exception + * @throws \Exception */ public function AssumptionOfMaryDataProvider(): array { diff --git a/tests/Switzerland/Uri/ChristmasDayTest.php b/tests/Switzerland/Uri/ChristmasDayTest.php index 8620d24c6..d3e3a7e9a 100644 --- a/tests/Switzerland/Uri/ChristmasDayTest.php +++ b/tests/Switzerland/Uri/ChristmasDayTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\Switzerland\Uri; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,8 +32,8 @@ class ChristmasDayTest extends UriBaseTestCase implements HolidayTestCase * * @dataProvider ChristmasDayDataProvider * - * @param int $year the year for which Christmas Day needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which Christmas Day needs to be tested + * @param \DateTime $expected the expected date */ public function testChristmasDay(int $year, \DateTimeInterface $expected): void { @@ -47,7 +45,7 @@ public function testChristmasDay(int $year, \DateTimeInterface $expected): void * * @return array list of test dates for Christmas Day * - * @throws Exception + * @throws \Exception */ public function ChristmasDayDataProvider(): array { @@ -57,7 +55,7 @@ public function ChristmasDayDataProvider(): array /** * Tests translated name of Christmas Day. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -72,7 +70,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Uri/CorpusChristiTest.php b/tests/Switzerland/Uri/CorpusChristiTest.php index 95fba1201..97bdfb634 100644 --- a/tests/Switzerland/Uri/CorpusChristiTest.php +++ b/tests/Switzerland/Uri/CorpusChristiTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\Switzerland\Uri; -use DateInterval; -use Exception; use Yasumi\Holiday; use Yasumi\Provider\ChristianHolidays; use Yasumi\tests\HolidayTestCase; @@ -35,7 +33,7 @@ class CorpusChristiTest extends UriBaseTestCase implements HolidayTestCase /** * Tests Corpus Christi. * - * @throws Exception + * @throws \Exception */ public function testCorpusChristi(): void { @@ -44,14 +42,14 @@ public function testCorpusChristi(): void self::REGION, self::HOLIDAY, $year, - $this->calculateEaster($year, self::TIMEZONE)->add(new DateInterval('P60D')) + $this->calculateEaster($year, self::TIMEZONE)->add(new \DateInterval('P60D')) ); } /** * Tests translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -66,7 +64,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Uri/EasterMondayTest.php b/tests/Switzerland/Uri/EasterMondayTest.php index 24e14025f..3e699ea5a 100644 --- a/tests/Switzerland/Uri/EasterMondayTest.php +++ b/tests/Switzerland/Uri/EasterMondayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Switzerland\Uri; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -33,7 +30,7 @@ class EasterMondayTest extends UriBaseTestCase implements HolidayTestCase /** * Tests Easter Monday. * - * @throws Exception + * @throws \Exception */ public function testEasterMonday(): void { @@ -42,14 +39,14 @@ public function testEasterMonday(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-3-28", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-3-28", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests translated name of Easter Monday. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -64,7 +61,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Uri/EpiphanyTest.php b/tests/Switzerland/Uri/EpiphanyTest.php index 281897933..e2695c4d7 100644 --- a/tests/Switzerland/Uri/EpiphanyTest.php +++ b/tests/Switzerland/Uri/EpiphanyTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\Switzerland\Uri; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,8 +32,8 @@ class EpiphanyTest extends UriBaseTestCase implements HolidayTestCase * * @dataProvider HolidayDataProvider * - * @param int $year the year for which the holiday defined in this test needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which the holiday defined in this test needs to be tested + * @param \DateTime $expected the expected date */ public function testHoliday(int $year, \DateTimeInterface $expected): void { @@ -47,7 +45,7 @@ public function testHoliday(int $year, \DateTimeInterface $expected): void * * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function HolidayDataProvider(): array { @@ -57,7 +55,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -72,7 +70,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Uri/GoodFridayTest.php b/tests/Switzerland/Uri/GoodFridayTest.php index f27e9418b..a8650befd 100644 --- a/tests/Switzerland/Uri/GoodFridayTest.php +++ b/tests/Switzerland/Uri/GoodFridayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Switzerland\Uri; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -33,7 +30,7 @@ class GoodFridayTest extends UriBaseTestCase implements HolidayTestCase /** * Tests the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHoliday(): void { @@ -42,14 +39,14 @@ public function testHoliday(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-3-21", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-3-21", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -64,7 +61,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Uri/ImmaculateConceptionTest.php b/tests/Switzerland/Uri/ImmaculateConceptionTest.php index 8f4a6997a..0dad169fd 100644 --- a/tests/Switzerland/Uri/ImmaculateConceptionTest.php +++ b/tests/Switzerland/Uri/ImmaculateConceptionTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\Switzerland\Uri; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,8 +32,8 @@ class ImmaculateConceptionTest extends UriBaseTestCase implements HolidayTestCas * * @dataProvider HolidayDataProvider * - * @param int $year the year for which the holiday defined in this test needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which the holiday defined in this test needs to be tested + * @param \DateTime $expected the expected date */ public function testHoliday(int $year, \DateTimeInterface $expected): void { @@ -47,7 +45,7 @@ public function testHoliday(int $year, \DateTimeInterface $expected): void * * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function HolidayDataProvider(): array { @@ -57,7 +55,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -72,7 +70,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Uri/NewYearsDayTest.php b/tests/Switzerland/Uri/NewYearsDayTest.php index c4025783a..311a593cf 100644 --- a/tests/Switzerland/Uri/NewYearsDayTest.php +++ b/tests/Switzerland/Uri/NewYearsDayTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\Switzerland\Uri; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,8 +32,8 @@ class NewYearsDayTest extends UriBaseTestCase implements HolidayTestCase * * @dataProvider NewYearsDayDataProvider * - * @param int $year the year for which New Years Day needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which New Years Day needs to be tested + * @param \DateTime $expected the expected date */ public function testNewYearsDay(int $year, \DateTimeInterface $expected): void { @@ -45,7 +43,7 @@ public function testNewYearsDay(int $year, \DateTimeInterface $expected): void /** * Tests translated name of New Years Day. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -60,7 +58,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { @@ -72,7 +70,7 @@ public function testHolidayType(): void * * @return array list of test dates for New Years Day * - * @throws Exception + * @throws \Exception */ public function NewYearsDayDataProvider(): array { diff --git a/tests/Switzerland/Uri/PentecostMondayTest.php b/tests/Switzerland/Uri/PentecostMondayTest.php index 6203a26c4..14991ccbc 100644 --- a/tests/Switzerland/Uri/PentecostMondayTest.php +++ b/tests/Switzerland/Uri/PentecostMondayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Switzerland\Uri; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -33,7 +30,7 @@ class PentecostMondayTest extends UriBaseTestCase implements HolidayTestCase /** * Tests Pentecost Monday. * - * @throws Exception + * @throws \Exception */ public function testPentecostMonday(): void { @@ -42,14 +39,14 @@ public function testPentecostMonday(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-5-30", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-5-30", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests translated name of Pentecost Monday. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -64,7 +61,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Uri/StJosephDayTest.php b/tests/Switzerland/Uri/StJosephDayTest.php index 9709013ee..598dc3f6c 100644 --- a/tests/Switzerland/Uri/StJosephDayTest.php +++ b/tests/Switzerland/Uri/StJosephDayTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\Switzerland\Uri; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\Provider\ChristianHolidays; use Yasumi\tests\HolidayTestCase; @@ -37,8 +35,8 @@ class StJosephDayTest extends UriBaseTestCase implements HolidayTestCase * * @dataProvider StJosephDayDataProvider * - * @param int $year the year for which St. Joseph's Day needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which St. Joseph's Day needs to be tested + * @param \DateTime $expected the expected date */ public function testStJosephDay(int $year, \DateTimeInterface $expected): void { @@ -50,7 +48,7 @@ public function testStJosephDay(int $year, \DateTimeInterface $expected): void * * @return array list of test dates for St. Joseph's Day * - * @throws Exception + * @throws \Exception */ public function StJosephDayDataProvider(): array { @@ -60,7 +58,7 @@ public function StJosephDayDataProvider(): array /** * Tests translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -75,7 +73,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Uri/StStephensDayTest.php b/tests/Switzerland/Uri/StStephensDayTest.php index 5383310c3..2be6fb295 100644 --- a/tests/Switzerland/Uri/StStephensDayTest.php +++ b/tests/Switzerland/Uri/StStephensDayTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\Switzerland\Uri; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,8 +32,8 @@ class StStephensDayTest extends UriBaseTestCase implements HolidayTestCase * * @dataProvider HolidayDataProvider * - * @param int $year the year for which the holiday defined in this test needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which the holiday defined in this test needs to be tested + * @param \DateTime $expected the expected date */ public function testHoliday(int $year, \DateTimeInterface $expected): void { @@ -47,7 +45,7 @@ public function testHoliday(int $year, \DateTimeInterface $expected): void * * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function HolidayDataProvider(): array { @@ -57,7 +55,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -72,7 +70,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Uri/UriTest.php b/tests/Switzerland/Uri/UriTest.php index b6b9882f0..e8ad5678e 100644 --- a/tests/Switzerland/Uri/UriTest.php +++ b/tests/Switzerland/Uri/UriTest.php @@ -14,7 +14,6 @@ namespace Yasumi\tests\Switzerland\Uri; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\ProviderTestCase; @@ -110,7 +109,7 @@ public function testOtherHolidays(): void } /** - * @throws ReflectionException + * @throws \ReflectionException * @throws \Exception */ public function testSources(): void diff --git a/tests/Switzerland/Valais/AllSaintsDayTest.php b/tests/Switzerland/Valais/AllSaintsDayTest.php index ff38ba76c..3cf5678b4 100644 --- a/tests/Switzerland/Valais/AllSaintsDayTest.php +++ b/tests/Switzerland/Valais/AllSaintsDayTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\Switzerland\Valais; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,8 +32,8 @@ class AllSaintsDayTest extends ValaisBaseTestCase implements HolidayTestCase * * @dataProvider AllSaintsDayDataProvider * - * @param int $year the year for which All Saints' Day needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which All Saints' Day needs to be tested + * @param \DateTime $expected the expected date */ public function testAllSaintsDay(int $year, \DateTimeInterface $expected): void { @@ -45,7 +43,7 @@ public function testAllSaintsDay(int $year, \DateTimeInterface $expected): void /** * Tests translated name of All Saints' Day. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -60,7 +58,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { @@ -72,7 +70,7 @@ public function testHolidayType(): void * * @return array list of test dates for All Saints' Day * - * @throws Exception + * @throws \Exception */ public function AllSaintsDayDataProvider(): array { diff --git a/tests/Switzerland/Valais/AscensionDayTest.php b/tests/Switzerland/Valais/AscensionDayTest.php index 247a38047..14780a854 100644 --- a/tests/Switzerland/Valais/AscensionDayTest.php +++ b/tests/Switzerland/Valais/AscensionDayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Switzerland\Valais; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -33,7 +30,7 @@ class AscensionDayTest extends ValaisBaseTestCase implements HolidayTestCase /** * Tests Ascension Day. * - * @throws Exception + * @throws \Exception */ public function testAscensionDay(): void { @@ -42,14 +39,14 @@ public function testAscensionDay(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-5-16", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-5-16", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests translated name of Ascension Day. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -64,7 +61,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Valais/AssumptionOfMaryTest.php b/tests/Switzerland/Valais/AssumptionOfMaryTest.php index b576c673d..1c5dadb3f 100644 --- a/tests/Switzerland/Valais/AssumptionOfMaryTest.php +++ b/tests/Switzerland/Valais/AssumptionOfMaryTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\Switzerland\Valais; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,8 +32,8 @@ class AssumptionOfMaryTest extends ValaisBaseTestCase implements HolidayTestCase * * @dataProvider AssumptionOfMaryDataProvider * - * @param int $year the year for which the day of the Assumption of Mary needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which the day of the Assumption of Mary needs to be tested + * @param \DateTime $expected the expected date */ public function testAssumptionOfMary(int $year, \DateTimeInterface $expected): void { @@ -45,7 +43,7 @@ public function testAssumptionOfMary(int $year, \DateTimeInterface $expected): v /** * Tests translated name of the day of the Assumption of Mary. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -60,7 +58,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { @@ -72,7 +70,7 @@ public function testHolidayType(): void * * @return array list of test dates for the day of the Assumption of Mary * - * @throws Exception + * @throws \Exception */ public function AssumptionOfMaryDataProvider(): array { diff --git a/tests/Switzerland/Valais/ChristmasDayTest.php b/tests/Switzerland/Valais/ChristmasDayTest.php index 7311165e0..e3a28d195 100644 --- a/tests/Switzerland/Valais/ChristmasDayTest.php +++ b/tests/Switzerland/Valais/ChristmasDayTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\Switzerland\Valais; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,8 +32,8 @@ class ChristmasDayTest extends ValaisBaseTestCase implements HolidayTestCase * * @dataProvider ChristmasDayDataProvider * - * @param int $year the year for which Christmas Day needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which Christmas Day needs to be tested + * @param \DateTime $expected the expected date */ public function testChristmasDay(int $year, \DateTimeInterface $expected): void { @@ -47,7 +45,7 @@ public function testChristmasDay(int $year, \DateTimeInterface $expected): void * * @return array list of test dates for Christmas Day * - * @throws Exception + * @throws \Exception */ public function ChristmasDayDataProvider(): array { @@ -57,7 +55,7 @@ public function ChristmasDayDataProvider(): array /** * Tests translated name of Christmas Day. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -72,7 +70,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Valais/CorpusChristiTest.php b/tests/Switzerland/Valais/CorpusChristiTest.php index 84f2c7bdd..72a8b5010 100644 --- a/tests/Switzerland/Valais/CorpusChristiTest.php +++ b/tests/Switzerland/Valais/CorpusChristiTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\Switzerland\Valais; -use DateInterval; -use Exception; use Yasumi\Holiday; use Yasumi\Provider\ChristianHolidays; use Yasumi\tests\HolidayTestCase; @@ -35,7 +33,7 @@ class CorpusChristiTest extends ValaisBaseTestCase implements HolidayTestCase /** * Tests Corpus Christi. * - * @throws Exception + * @throws \Exception */ public function testCorpusChristi(): void { @@ -44,14 +42,14 @@ public function testCorpusChristi(): void self::REGION, self::HOLIDAY, $year, - $this->calculateEaster($year, self::TIMEZONE)->add(new DateInterval('P60D')) + $this->calculateEaster($year, self::TIMEZONE)->add(new \DateInterval('P60D')) ); } /** * Tests translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -66,7 +64,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Valais/ImmaculateConceptionTest.php b/tests/Switzerland/Valais/ImmaculateConceptionTest.php index e89881d83..6bc0dc16d 100644 --- a/tests/Switzerland/Valais/ImmaculateConceptionTest.php +++ b/tests/Switzerland/Valais/ImmaculateConceptionTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\Switzerland\Valais; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,8 +32,8 @@ class ImmaculateConceptionTest extends ValaisBaseTestCase implements HolidayTest * * @dataProvider HolidayDataProvider * - * @param int $year the year for which the holiday defined in this test needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which the holiday defined in this test needs to be tested + * @param \DateTime $expected the expected date */ public function testHoliday(int $year, \DateTimeInterface $expected): void { @@ -47,7 +45,7 @@ public function testHoliday(int $year, \DateTimeInterface $expected): void * * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function HolidayDataProvider(): array { @@ -57,7 +55,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -72,7 +70,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Valais/NewYearsDayTest.php b/tests/Switzerland/Valais/NewYearsDayTest.php index 4f79ba136..9c29308ea 100644 --- a/tests/Switzerland/Valais/NewYearsDayTest.php +++ b/tests/Switzerland/Valais/NewYearsDayTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\Switzerland\Valais; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,8 +32,8 @@ class NewYearsDayTest extends ValaisBaseTestCase implements HolidayTestCase * * @dataProvider NewYearsDayDataProvider * - * @param int $year the year for which New Years Day needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which New Years Day needs to be tested + * @param \DateTime $expected the expected date */ public function testNewYearsDay(int $year, \DateTimeInterface $expected): void { @@ -45,7 +43,7 @@ public function testNewYearsDay(int $year, \DateTimeInterface $expected): void /** * Tests translated name of New Years Day. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -60,7 +58,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { @@ -72,7 +70,7 @@ public function testHolidayType(): void * * @return array list of test dates for New Years Day * - * @throws Exception + * @throws \Exception */ public function NewYearsDayDataProvider(): array { diff --git a/tests/Switzerland/Valais/StJosephDayTest.php b/tests/Switzerland/Valais/StJosephDayTest.php index e995d181e..f3db4e19d 100644 --- a/tests/Switzerland/Valais/StJosephDayTest.php +++ b/tests/Switzerland/Valais/StJosephDayTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\Switzerland\Valais; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\Provider\ChristianHolidays; use Yasumi\tests\HolidayTestCase; @@ -37,8 +35,8 @@ class StJosephDayTest extends ValaisBaseTestCase implements HolidayTestCase * * @dataProvider StJosephDayDataProvider * - * @param int $year the year for which St. Joseph's Day needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which St. Joseph's Day needs to be tested + * @param \DateTime $expected the expected date */ public function testStJosephDay(int $year, \DateTimeInterface $expected): void { @@ -50,7 +48,7 @@ public function testStJosephDay(int $year, \DateTimeInterface $expected): void * * @return array list of test dates for St. Joseph's Day * - * @throws Exception + * @throws \Exception */ public function StJosephDayDataProvider(): array { @@ -60,7 +58,7 @@ public function StJosephDayDataProvider(): array /** * Tests translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -75,7 +73,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Valais/ValaisTest.php b/tests/Switzerland/Valais/ValaisTest.php index ff3f3bac8..1573a37c4 100644 --- a/tests/Switzerland/Valais/ValaisTest.php +++ b/tests/Switzerland/Valais/ValaisTest.php @@ -14,7 +14,6 @@ namespace Yasumi\tests\Switzerland\Valais; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\ProviderTestCase; @@ -105,7 +104,7 @@ public function testOtherHolidays(): void } /** - * @throws ReflectionException + * @throws \ReflectionException * @throws \Exception */ public function testSources(): void diff --git a/tests/Switzerland/Vaud/AscensionDayTest.php b/tests/Switzerland/Vaud/AscensionDayTest.php index 7a5d17893..8fb697909 100644 --- a/tests/Switzerland/Vaud/AscensionDayTest.php +++ b/tests/Switzerland/Vaud/AscensionDayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Switzerland\Vaud; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -33,7 +30,7 @@ class AscensionDayTest extends VaudBaseTestCase implements HolidayTestCase /** * Tests Ascension Day. * - * @throws Exception + * @throws \Exception */ public function testAscensionDay(): void { @@ -42,14 +39,14 @@ public function testAscensionDay(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-5-16", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-5-16", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests translated name of Ascension Day. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -64,7 +61,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Vaud/BerchtoldsTagTest.php b/tests/Switzerland/Vaud/BerchtoldsTagTest.php index d579d136a..cfa5744b0 100644 --- a/tests/Switzerland/Vaud/BerchtoldsTagTest.php +++ b/tests/Switzerland/Vaud/BerchtoldsTagTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Switzerland\Vaud; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -33,12 +30,12 @@ class BerchtoldsTagTest extends VaudBaseTestCase implements HolidayTestCase /** * Tests BerchtoldsTag. * - * @throws Exception + * @throws \Exception */ public function testBerchtoldsTag(): void { $year = $this->generateRandomYear(); - $date = new DateTime($year.'-01-02', new DateTimeZone(self::TIMEZONE)); + $date = new \DateTime($year.'-01-02', new \DateTimeZone(self::TIMEZONE)); $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $date); $this->assertHolidayType(self::REGION, self::HOLIDAY, $year, Holiday::TYPE_OTHER); @@ -47,7 +44,7 @@ public function testBerchtoldsTag(): void /** * Tests translated name of BerchtoldsTag. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -62,7 +59,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Vaud/BettagsMontagTest.php b/tests/Switzerland/Vaud/BettagsMontagTest.php index 191983a7b..e22522168 100644 --- a/tests/Switzerland/Vaud/BettagsMontagTest.php +++ b/tests/Switzerland/Vaud/BettagsMontagTest.php @@ -14,10 +14,6 @@ namespace Yasumi\tests\Switzerland\Vaud; -use DateInterval; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,16 +30,16 @@ class BettagsMontagTest extends VaudBaseTestCase implements HolidayTestCase /** * Tests Bettags Montag on or after 1832. * - * @throws Exception + * @throws \Exception */ public function testBettagsMontagOnAfter1832(): void { $year = $this->generateRandomYear(1832); // Find third Sunday of September - $date = new DateTime('Third Sunday of '.$year.'-09', new DateTimeZone(self::TIMEZONE)); + $date = new \DateTime('Third Sunday of '.$year.'-09', new \DateTimeZone(self::TIMEZONE)); // Go to next Thursday - $date->add(new DateInterval('P1D')); + $date->add(new \DateInterval('P1D')); $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $date); } @@ -51,7 +47,7 @@ public function testBettagsMontagOnAfter1832(): void /** * Tests Bettags Montag before 1832. * - * @throws Exception + * @throws \Exception */ public function testBettagsMontagBefore1832(): void { @@ -62,7 +58,7 @@ public function testBettagsMontagBefore1832(): void /** * Tests translated name of Bettags Montag. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -77,7 +73,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Vaud/ChristmasDayTest.php b/tests/Switzerland/Vaud/ChristmasDayTest.php index 60ab6252e..df3d93470 100644 --- a/tests/Switzerland/Vaud/ChristmasDayTest.php +++ b/tests/Switzerland/Vaud/ChristmasDayTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\Switzerland\Vaud; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,8 +32,8 @@ class ChristmasDayTest extends VaudBaseTestCase implements HolidayTestCase * * @dataProvider ChristmasDayDataProvider * - * @param int $year the year for which Christmas Day needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which Christmas Day needs to be tested + * @param \DateTime $expected the expected date */ public function testChristmasDay(int $year, \DateTimeInterface $expected): void { @@ -47,7 +45,7 @@ public function testChristmasDay(int $year, \DateTimeInterface $expected): void * * @return array list of test dates for Christmas Day * - * @throws Exception + * @throws \Exception */ public function ChristmasDayDataProvider(): array { @@ -57,7 +55,7 @@ public function ChristmasDayDataProvider(): array /** * Tests translated name of Christmas Day. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -72,7 +70,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Vaud/EasterMondayTest.php b/tests/Switzerland/Vaud/EasterMondayTest.php index 1c8296a26..1ab429fb2 100644 --- a/tests/Switzerland/Vaud/EasterMondayTest.php +++ b/tests/Switzerland/Vaud/EasterMondayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Switzerland\Vaud; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -33,7 +30,7 @@ class EasterMondayTest extends VaudBaseTestCase implements HolidayTestCase /** * Tests Easter Monday. * - * @throws Exception + * @throws \Exception */ public function testEasterMonday(): void { @@ -42,14 +39,14 @@ public function testEasterMonday(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-3-28", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-3-28", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests translated name of Easter Monday. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -64,7 +61,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Vaud/GoodFridayTest.php b/tests/Switzerland/Vaud/GoodFridayTest.php index a50740efd..c948afb3b 100644 --- a/tests/Switzerland/Vaud/GoodFridayTest.php +++ b/tests/Switzerland/Vaud/GoodFridayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Switzerland\Vaud; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -33,7 +30,7 @@ class GoodFridayTest extends VaudBaseTestCase implements HolidayTestCase /** * Tests the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHoliday(): void { @@ -42,14 +39,14 @@ public function testHoliday(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-3-21", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-3-21", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -64,7 +61,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Vaud/NewYearsDayTest.php b/tests/Switzerland/Vaud/NewYearsDayTest.php index 36bed24a8..3937d1db8 100644 --- a/tests/Switzerland/Vaud/NewYearsDayTest.php +++ b/tests/Switzerland/Vaud/NewYearsDayTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\Switzerland\Vaud; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,8 +32,8 @@ class NewYearsDayTest extends VaudBaseTestCase implements HolidayTestCase * * @dataProvider NewYearsDayDataProvider * - * @param int $year the year for which New Years Day needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which New Years Day needs to be tested + * @param \DateTime $expected the expected date */ public function testNewYearsDay(int $year, \DateTimeInterface $expected): void { @@ -45,7 +43,7 @@ public function testNewYearsDay(int $year, \DateTimeInterface $expected): void /** * Tests translated name of New Years Day. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -60,7 +58,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { @@ -72,7 +70,7 @@ public function testHolidayType(): void * * @return array list of test dates for New Years Day * - * @throws Exception + * @throws \Exception */ public function NewYearsDayDataProvider(): array { diff --git a/tests/Switzerland/Vaud/PentecostMondayTest.php b/tests/Switzerland/Vaud/PentecostMondayTest.php index ab5f4fbc6..27428422d 100644 --- a/tests/Switzerland/Vaud/PentecostMondayTest.php +++ b/tests/Switzerland/Vaud/PentecostMondayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Switzerland\Vaud; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -33,7 +30,7 @@ class PentecostMondayTest extends VaudBaseTestCase implements HolidayTestCase /** * Tests Pentecost Monday. * - * @throws Exception + * @throws \Exception */ public function testPentecostMonday(): void { @@ -42,14 +39,14 @@ public function testPentecostMonday(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-5-30", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-5-30", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests translated name of Pentecost Monday. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -64,7 +61,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Vaud/VaudTest.php b/tests/Switzerland/Vaud/VaudTest.php index c6a1f36bc..baae3f4d2 100644 --- a/tests/Switzerland/Vaud/VaudTest.php +++ b/tests/Switzerland/Vaud/VaudTest.php @@ -14,7 +14,6 @@ namespace Yasumi\tests\Switzerland\Vaud; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\ProviderTestCase; @@ -105,7 +104,7 @@ public function testOtherHolidays(): void } /** - * @throws ReflectionException + * @throws \ReflectionException * @throws \Exception */ public function testSources(): void diff --git a/tests/Switzerland/Zug/AllSaintsDayTest.php b/tests/Switzerland/Zug/AllSaintsDayTest.php index aa45782a0..c32706c95 100644 --- a/tests/Switzerland/Zug/AllSaintsDayTest.php +++ b/tests/Switzerland/Zug/AllSaintsDayTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\Switzerland\Zug; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,8 +32,8 @@ class AllSaintsDayTest extends ZugBaseTestCase implements HolidayTestCase * * @dataProvider AllSaintsDayDataProvider * - * @param int $year the year for which All Saints' Day needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which All Saints' Day needs to be tested + * @param \DateTime $expected the expected date */ public function testAllSaintsDay(int $year, \DateTimeInterface $expected): void { @@ -45,7 +43,7 @@ public function testAllSaintsDay(int $year, \DateTimeInterface $expected): void /** * Tests translated name of All Saints' Day. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -60,7 +58,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { @@ -72,7 +70,7 @@ public function testHolidayType(): void * * @return array list of test dates for All Saints' Day * - * @throws Exception + * @throws \Exception */ public function AllSaintsDayDataProvider(): array { diff --git a/tests/Switzerland/Zug/AscensionDayTest.php b/tests/Switzerland/Zug/AscensionDayTest.php index b302d214a..445ef4364 100644 --- a/tests/Switzerland/Zug/AscensionDayTest.php +++ b/tests/Switzerland/Zug/AscensionDayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Switzerland\Zug; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -33,7 +30,7 @@ class AscensionDayTest extends ZugBaseTestCase implements HolidayTestCase /** * Tests Ascension Day. * - * @throws Exception + * @throws \Exception */ public function testAscensionDay(): void { @@ -42,14 +39,14 @@ public function testAscensionDay(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-5-16", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-5-16", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests translated name of Ascension Day. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -64,7 +61,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Zug/AssumptionOfMaryTest.php b/tests/Switzerland/Zug/AssumptionOfMaryTest.php index 43607bdab..d68e0a2b0 100644 --- a/tests/Switzerland/Zug/AssumptionOfMaryTest.php +++ b/tests/Switzerland/Zug/AssumptionOfMaryTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\Switzerland\Zug; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,8 +32,8 @@ class AssumptionOfMaryTest extends ZugBaseTestCase implements HolidayTestCase * * @dataProvider AssumptionOfMaryDataProvider * - * @param int $year the year for which the day of the Assumption of Mary needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which the day of the Assumption of Mary needs to be tested + * @param \DateTime $expected the expected date */ public function testAssumptionOfMary(int $year, \DateTimeInterface $expected): void { @@ -45,7 +43,7 @@ public function testAssumptionOfMary(int $year, \DateTimeInterface $expected): v /** * Tests translated name of the day of the Assumption of Mary. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -60,7 +58,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { @@ -72,7 +70,7 @@ public function testHolidayType(): void * * @return array list of test dates for the day of the Assumption of Mary * - * @throws Exception + * @throws \Exception */ public function AssumptionOfMaryDataProvider(): array { diff --git a/tests/Switzerland/Zug/BerchtoldsTagTest.php b/tests/Switzerland/Zug/BerchtoldsTagTest.php index 6aa48e330..8faa53aa2 100644 --- a/tests/Switzerland/Zug/BerchtoldsTagTest.php +++ b/tests/Switzerland/Zug/BerchtoldsTagTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Switzerland\Zug; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -33,12 +30,12 @@ class BerchtoldsTagTest extends ZugBaseTestCase implements HolidayTestCase /** * Tests BerchtoldsTag. * - * @throws Exception + * @throws \Exception */ public function testBerchtoldsTag(): void { $year = $this->generateRandomYear(); - $date = new DateTime($year.'-01-02', new DateTimeZone(self::TIMEZONE)); + $date = new \DateTime($year.'-01-02', new \DateTimeZone(self::TIMEZONE)); $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $date); $this->assertHolidayType(self::REGION, self::HOLIDAY, $year, Holiday::TYPE_OTHER); @@ -47,7 +44,7 @@ public function testBerchtoldsTag(): void /** * Tests translated name of BerchtoldsTag. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -62,7 +59,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Zug/ChristmasDayTest.php b/tests/Switzerland/Zug/ChristmasDayTest.php index cea2de8e5..9f42d94c9 100644 --- a/tests/Switzerland/Zug/ChristmasDayTest.php +++ b/tests/Switzerland/Zug/ChristmasDayTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\Switzerland\Zug; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,8 +32,8 @@ class ChristmasDayTest extends ZugBaseTestCase implements HolidayTestCase * * @dataProvider ChristmasDayDataProvider * - * @param int $year the year for which Christmas Day needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which Christmas Day needs to be tested + * @param \DateTime $expected the expected date */ public function testChristmasDay(int $year, \DateTimeInterface $expected): void { @@ -47,7 +45,7 @@ public function testChristmasDay(int $year, \DateTimeInterface $expected): void * * @return array list of test dates for Christmas Day * - * @throws Exception + * @throws \Exception */ public function ChristmasDayDataProvider(): array { @@ -57,7 +55,7 @@ public function ChristmasDayDataProvider(): array /** * Tests translated name of Christmas Day. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -72,7 +70,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Zug/CorpusChristiTest.php b/tests/Switzerland/Zug/CorpusChristiTest.php index d1d83cb20..431ca5ee7 100644 --- a/tests/Switzerland/Zug/CorpusChristiTest.php +++ b/tests/Switzerland/Zug/CorpusChristiTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\Switzerland\Zug; -use DateInterval; -use Exception; use Yasumi\Holiday; use Yasumi\Provider\ChristianHolidays; use Yasumi\tests\HolidayTestCase; @@ -35,7 +33,7 @@ class CorpusChristiTest extends ZugBaseTestCase implements HolidayTestCase /** * Tests Corpus Christi. * - * @throws Exception + * @throws \Exception */ public function testCorpusChristi(): void { @@ -44,14 +42,14 @@ public function testCorpusChristi(): void self::REGION, self::HOLIDAY, $year, - $this->calculateEaster($year, self::TIMEZONE)->add(new DateInterval('P60D')) + $this->calculateEaster($year, self::TIMEZONE)->add(new \DateInterval('P60D')) ); } /** * Tests translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -66,7 +64,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Zug/EasterMondayTest.php b/tests/Switzerland/Zug/EasterMondayTest.php index 54dec7651..c54dbc134 100644 --- a/tests/Switzerland/Zug/EasterMondayTest.php +++ b/tests/Switzerland/Zug/EasterMondayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Switzerland\Zug; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -33,7 +30,7 @@ class EasterMondayTest extends ZugBaseTestCase implements HolidayTestCase /** * Tests Easter Monday. * - * @throws Exception + * @throws \Exception */ public function testEasterMonday(): void { @@ -42,14 +39,14 @@ public function testEasterMonday(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-3-28", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-3-28", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests translated name of Easter Monday. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -64,7 +61,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Zug/GoodFridayTest.php b/tests/Switzerland/Zug/GoodFridayTest.php index 908868ac9..c3c926831 100644 --- a/tests/Switzerland/Zug/GoodFridayTest.php +++ b/tests/Switzerland/Zug/GoodFridayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Switzerland\Zug; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -33,7 +30,7 @@ class GoodFridayTest extends ZugBaseTestCase implements HolidayTestCase /** * Tests the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHoliday(): void { @@ -42,14 +39,14 @@ public function testHoliday(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-3-21", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-3-21", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -64,7 +61,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Zug/ImmaculateConceptionTest.php b/tests/Switzerland/Zug/ImmaculateConceptionTest.php index 2002c2ce4..a276721c9 100644 --- a/tests/Switzerland/Zug/ImmaculateConceptionTest.php +++ b/tests/Switzerland/Zug/ImmaculateConceptionTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\Switzerland\Zug; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,8 +32,8 @@ class ImmaculateConceptionTest extends ZugBaseTestCase implements HolidayTestCas * * @dataProvider HolidayDataProvider * - * @param int $year the year for which the holiday defined in this test needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which the holiday defined in this test needs to be tested + * @param \DateTime $expected the expected date */ public function testHoliday(int $year, \DateTimeInterface $expected): void { @@ -47,7 +45,7 @@ public function testHoliday(int $year, \DateTimeInterface $expected): void * * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function HolidayDataProvider(): array { @@ -57,7 +55,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -72,7 +70,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Zug/NewYearsDayTest.php b/tests/Switzerland/Zug/NewYearsDayTest.php index 93d535b59..b18dcbcac 100644 --- a/tests/Switzerland/Zug/NewYearsDayTest.php +++ b/tests/Switzerland/Zug/NewYearsDayTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\Switzerland\Zug; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,8 +32,8 @@ class NewYearsDayTest extends ZugBaseTestCase implements HolidayTestCase * * @dataProvider NewYearsDayDataProvider * - * @param int $year the year for which New Years Day needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which New Years Day needs to be tested + * @param \DateTime $expected the expected date */ public function testNewYearsDay(int $year, \DateTimeInterface $expected): void { @@ -45,7 +43,7 @@ public function testNewYearsDay(int $year, \DateTimeInterface $expected): void /** * Tests translated name of New Years Day. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -60,7 +58,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { @@ -72,7 +70,7 @@ public function testHolidayType(): void * * @return array list of test dates for New Years Day * - * @throws Exception + * @throws \Exception */ public function NewYearsDayDataProvider(): array { diff --git a/tests/Switzerland/Zug/PentecostMondayTest.php b/tests/Switzerland/Zug/PentecostMondayTest.php index c096f9cc0..7339d610d 100644 --- a/tests/Switzerland/Zug/PentecostMondayTest.php +++ b/tests/Switzerland/Zug/PentecostMondayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Switzerland\Zug; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -33,7 +30,7 @@ class PentecostMondayTest extends ZugBaseTestCase implements HolidayTestCase /** * Tests Pentecost Monday. * - * @throws Exception + * @throws \Exception */ public function testPentecostMonday(): void { @@ -42,14 +39,14 @@ public function testPentecostMonday(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-5-30", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-5-30", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests translated name of Pentecost Monday. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -64,7 +61,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Zug/StStephensDayTest.php b/tests/Switzerland/Zug/StStephensDayTest.php index 6764c861d..5aa412a59 100644 --- a/tests/Switzerland/Zug/StStephensDayTest.php +++ b/tests/Switzerland/Zug/StStephensDayTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\Switzerland\Zug; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,8 +32,8 @@ class StStephensDayTest extends ZugBaseTestCase implements HolidayTestCase * * @dataProvider HolidayDataProvider * - * @param int $year the year for which the holiday defined in this test needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which the holiday defined in this test needs to be tested + * @param \DateTime $expected the expected date */ public function testHoliday(int $year, \DateTimeInterface $expected): void { @@ -47,7 +45,7 @@ public function testHoliday(int $year, \DateTimeInterface $expected): void * * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function HolidayDataProvider(): array { @@ -57,7 +55,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -72,7 +70,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Zug/ZugTest.php b/tests/Switzerland/Zug/ZugTest.php index a5c3822c9..d8bb99199 100644 --- a/tests/Switzerland/Zug/ZugTest.php +++ b/tests/Switzerland/Zug/ZugTest.php @@ -14,7 +14,6 @@ namespace Yasumi\tests\Switzerland\Zug; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\ProviderTestCase; @@ -109,7 +108,7 @@ public function testOtherHolidays(): void } /** - * @throws ReflectionException + * @throws \ReflectionException * @throws \Exception */ public function testSources(): void diff --git a/tests/Switzerland/Zurich/AscensionDayTest.php b/tests/Switzerland/Zurich/AscensionDayTest.php index 482052bb8..77346251a 100644 --- a/tests/Switzerland/Zurich/AscensionDayTest.php +++ b/tests/Switzerland/Zurich/AscensionDayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Switzerland\Zurich; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -33,7 +30,7 @@ class AscensionDayTest extends ZurichBaseTestCase implements HolidayTestCase /** * Tests Ascension Day. * - * @throws Exception + * @throws \Exception */ public function testAscensionDay(): void { @@ -42,14 +39,14 @@ public function testAscensionDay(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-5-16", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-5-16", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests translated name of Ascension Day. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -64,7 +61,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Zurich/ChristmasDayTest.php b/tests/Switzerland/Zurich/ChristmasDayTest.php index 32959b252..866663cb2 100644 --- a/tests/Switzerland/Zurich/ChristmasDayTest.php +++ b/tests/Switzerland/Zurich/ChristmasDayTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\Switzerland\Zurich; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,8 +32,8 @@ class ChristmasDayTest extends ZurichBaseTestCase implements HolidayTestCase * * @dataProvider ChristmasDayDataProvider * - * @param int $year the year for which Christmas Day needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which Christmas Day needs to be tested + * @param \DateTime $expected the expected date */ public function testChristmasDay(int $year, \DateTimeInterface $expected): void { @@ -47,7 +45,7 @@ public function testChristmasDay(int $year, \DateTimeInterface $expected): void * * @return array list of test dates for Christmas Day * - * @throws Exception + * @throws \Exception */ public function ChristmasDayDataProvider(): array { @@ -57,7 +55,7 @@ public function ChristmasDayDataProvider(): array /** * Tests translated name of Christmas Day. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -72,7 +70,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Zurich/EasterMondayTest.php b/tests/Switzerland/Zurich/EasterMondayTest.php index ef2d00989..98c9c7be5 100644 --- a/tests/Switzerland/Zurich/EasterMondayTest.php +++ b/tests/Switzerland/Zurich/EasterMondayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Switzerland\Zurich; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -33,7 +30,7 @@ class EasterMondayTest extends ZurichBaseTestCase implements HolidayTestCase /** * Tests Easter Monday. * - * @throws Exception + * @throws \Exception */ public function testEasterMonday(): void { @@ -42,14 +39,14 @@ public function testEasterMonday(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-3-28", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-3-28", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests translated name of Easter Monday. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -64,7 +61,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Zurich/GoodFridayTest.php b/tests/Switzerland/Zurich/GoodFridayTest.php index a599f9b93..c6accc4f4 100644 --- a/tests/Switzerland/Zurich/GoodFridayTest.php +++ b/tests/Switzerland/Zurich/GoodFridayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Switzerland\Zurich; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -33,7 +30,7 @@ class GoodFridayTest extends ZurichBaseTestCase implements HolidayTestCase /** * Tests the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHoliday(): void { @@ -42,14 +39,14 @@ public function testHoliday(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-3-21", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-3-21", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -64,7 +61,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Zurich/NewYearsDayTest.php b/tests/Switzerland/Zurich/NewYearsDayTest.php index 326b88c49..cf52b2513 100644 --- a/tests/Switzerland/Zurich/NewYearsDayTest.php +++ b/tests/Switzerland/Zurich/NewYearsDayTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\Switzerland\Zurich; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,8 +32,8 @@ class NewYearsDayTest extends ZurichBaseTestCase implements HolidayTestCase * * @dataProvider NewYearsDayDataProvider * - * @param int $year the year for which New Years Day needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which New Years Day needs to be tested + * @param \DateTime $expected the expected date */ public function testNewYearsDay(int $year, \DateTimeInterface $expected): void { @@ -45,7 +43,7 @@ public function testNewYearsDay(int $year, \DateTimeInterface $expected): void /** * Tests translated name of New Years Day. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -60,7 +58,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { @@ -72,7 +70,7 @@ public function testHolidayType(): void * * @return array list of test dates for New Years Day * - * @throws Exception + * @throws \Exception */ public function NewYearsDayDataProvider(): array { diff --git a/tests/Switzerland/Zurich/PentecostMondayTest.php b/tests/Switzerland/Zurich/PentecostMondayTest.php index 94c642bde..92794027c 100644 --- a/tests/Switzerland/Zurich/PentecostMondayTest.php +++ b/tests/Switzerland/Zurich/PentecostMondayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Switzerland\Zurich; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -33,7 +30,7 @@ class PentecostMondayTest extends ZurichBaseTestCase implements HolidayTestCase /** * Tests Pentecost Monday. * - * @throws Exception + * @throws \Exception */ public function testPentecostMonday(): void { @@ -42,14 +39,14 @@ public function testPentecostMonday(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-5-30", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-5-30", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests translated name of Pentecost Monday. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -64,7 +61,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Zurich/StStephensDayTest.php b/tests/Switzerland/Zurich/StStephensDayTest.php index f4182f665..b4ad729eb 100644 --- a/tests/Switzerland/Zurich/StStephensDayTest.php +++ b/tests/Switzerland/Zurich/StStephensDayTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\Switzerland\Zurich; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,8 +32,8 @@ class StStephensDayTest extends ZurichBaseTestCase implements HolidayTestCase * * @dataProvider HolidayDataProvider * - * @param int $year the year for which the holiday defined in this test needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which the holiday defined in this test needs to be tested + * @param \DateTime $expected the expected date */ public function testHoliday(int $year, \DateTimeInterface $expected): void { @@ -47,7 +45,7 @@ public function testHoliday(int $year, \DateTimeInterface $expected): void * * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function HolidayDataProvider(): array { @@ -57,7 +55,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -72,7 +70,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Zurich/WorkersDayTest.php b/tests/Switzerland/Zurich/WorkersDayTest.php index e858ad7b2..f79c56641 100644 --- a/tests/Switzerland/Zurich/WorkersDayTest.php +++ b/tests/Switzerland/Zurich/WorkersDayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Switzerland\Zurich; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -38,11 +35,11 @@ class WorkersDayTest extends ZurichBaseTestCase implements HolidayTestCase * @param int $year the year for which the holiday defined in this test needs to be tested * @param string $expected the expected date * - * @throws Exception + * @throws \Exception */ public function testHoliday(int $year, string $expected): void { - $date = new DateTime($expected, new DateTimeZone(self::TIMEZONE)); + $date = new \DateTime($expected, new \DateTimeZone(self::TIMEZONE)); $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $date); } @@ -51,7 +48,7 @@ public function testHoliday(int $year, string $expected): void * * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function HolidayDataProvider(): array { @@ -59,7 +56,7 @@ public function HolidayDataProvider(): array for ($y = 0; $y < 50; ++$y) { $year = $this->generateRandomYear(); - $date = new DateTime("$year-5-1", new DateTimeZone(self::TIMEZONE)); + $date = new \DateTime("$year-5-1", new \DateTimeZone(self::TIMEZONE)); $data[] = [$year, $date->format('Y-m-d')]; } @@ -69,7 +66,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -84,7 +81,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Switzerland/Zurich/ZurichTest.php b/tests/Switzerland/Zurich/ZurichTest.php index d0524262a..ea86d21d2 100644 --- a/tests/Switzerland/Zurich/ZurichTest.php +++ b/tests/Switzerland/Zurich/ZurichTest.php @@ -14,7 +14,6 @@ namespace Yasumi\tests\Switzerland\Zurich; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\ProviderTestCase; @@ -105,7 +104,7 @@ public function testOtherHolidays(): void } /** - * @throws ReflectionException + * @throws \ReflectionException * @throws \Exception */ public function testSources(): void diff --git a/tests/Turkey/LabourDayTest.php b/tests/Turkey/LabourDayTest.php index 10ec0fe34..3930e1097 100644 --- a/tests/Turkey/LabourDayTest.php +++ b/tests/Turkey/LabourDayTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\Turkey; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -26,8 +24,8 @@ class LabourDayTest extends TurkeyBaseTestCase implements HolidayTestCase /** * @dataProvider HolidayDataProvider * - * @param int $year the year for which the holiday defined in this test needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which the holiday defined in this test needs to be tested + * @param \DateTime $expected the expected date */ public function testHoliday(int $year, \DateTimeInterface $expected): void { @@ -35,7 +33,7 @@ public function testHoliday(int $year, \DateTimeInterface $expected): void } /** - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -48,7 +46,7 @@ public function testTranslation(): void } /** - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { @@ -63,7 +61,7 @@ public function testHolidayType(): void /** * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function HolidayDataProvider(): array { diff --git a/tests/Turkey/NewYearsDayTest.php b/tests/Turkey/NewYearsDayTest.php index 48424d29b..16c7b9b27 100644 --- a/tests/Turkey/NewYearsDayTest.php +++ b/tests/Turkey/NewYearsDayTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\Turkey; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -26,8 +24,8 @@ class NewYearsDayTest extends TurkeyBaseTestCase implements HolidayTestCase /** * @dataProvider HolidayDataProvider * - * @param int $year the year for which the holiday defined in this test needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which the holiday defined in this test needs to be tested + * @param \DateTime $expected the expected date */ public function testHoliday(int $year, \DateTimeInterface $expected): void { @@ -37,7 +35,7 @@ public function testHoliday(int $year, \DateTimeInterface $expected): void /** * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function HolidayDataProvider(): array { @@ -45,7 +43,7 @@ public function HolidayDataProvider(): array } /** - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -58,7 +56,7 @@ public function testTranslation(): void } /** - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Turkey/TurkeyTest.php b/tests/Turkey/TurkeyTest.php index 390b3a65f..1eabf8623 100644 --- a/tests/Turkey/TurkeyTest.php +++ b/tests/Turkey/TurkeyTest.php @@ -15,7 +15,6 @@ namespace Yasumi\tests\Turkey; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\ProviderTestCase; @@ -96,7 +95,7 @@ public function testOtherHolidays(): void } /** - * @throws ReflectionException + * @throws \ReflectionException * @throws \Exception */ public function testSources(): void diff --git a/tests/USA/ChristmasDayTest.php b/tests/USA/ChristmasDayTest.php index e3e00ee09..6fb2ced6e 100644 --- a/tests/USA/ChristmasDayTest.php +++ b/tests/USA/ChristmasDayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\USA; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -33,7 +30,7 @@ class ChristmasDayTest extends USABaseTestCase implements HolidayTestCase /** * Tests Christmas Day. Christmas Day is celebrated on December 25th. * - * @throws Exception + * @throws \Exception */ public function testChristmasDay(): void { @@ -42,14 +39,14 @@ public function testChristmasDay(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-12-25", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-12-25", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests Christmas Day substituted on Monday (when Christmas Day falls on Sunday). * - * @throws Exception + * @throws \Exception */ public function testChristmasDaySubstitutedMonday(): void { @@ -59,14 +56,14 @@ public function testChristmasDaySubstitutedMonday(): void self::REGION, 'substituteHoliday:christmasDay', $year, - new DateTime("$year-12-26", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-12-26", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests Christmas Day substituted on Monday (when Christmas Day falls on Saturday). * - * @throws Exception + * @throws \Exception */ public function testChristmasDaySubstitutedFriday(): void { @@ -76,14 +73,14 @@ public function testChristmasDaySubstitutedFriday(): void self::REGION, 'substituteHoliday:christmasDay', $year, - new DateTime("$year-12-24", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-12-24", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -98,7 +95,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/USA/ColumbusDayTest.php b/tests/USA/ColumbusDayTest.php index 3ce5c3b11..983f12ef9 100644 --- a/tests/USA/ColumbusDayTest.php +++ b/tests/USA/ColumbusDayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\USA; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -39,7 +36,7 @@ class ColumbusDayTest extends USABaseTestCase implements HolidayTestCase * Tests Columbus Day on or after 1970. Columbus Day was established in 1937 on October 12th, but has been fixed to * the second Monday in October since 1970. * - * @throws Exception + * @throws \Exception */ public function testColumbusDayOnAfter1970(): void { @@ -48,7 +45,7 @@ public function testColumbusDayOnAfter1970(): void self::REGION, self::HOLIDAY, $year, - new DateTime("second monday of october $year", new DateTimeZone(self::TIMEZONE)) + new \DateTime("second monday of october $year", new \DateTimeZone(self::TIMEZONE)) ); } @@ -56,7 +53,7 @@ public function testColumbusDayOnAfter1970(): void * Tests Columbus Day between 1937 and 1969. Columbus Day was established in 1937 on October 12th, but has been * fixed to the second Monday in October since 1970. * - * @throws Exception + * @throws \Exception */ public function testColumbusBetween1937And1969(): void { @@ -65,7 +62,7 @@ public function testColumbusBetween1937And1969(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-10-12", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-10-12", new \DateTimeZone(self::TIMEZONE)) ); } @@ -73,7 +70,7 @@ public function testColumbusBetween1937And1969(): void * Tests Columbus Day before 1937. Columbus Day was established in 1937 on October 12th, but has been fixed to * the second Monday in October since 1970. * - * @throws Exception + * @throws \Exception */ public function testColumbusDayBefore1937(): void { @@ -87,7 +84,7 @@ public function testColumbusDayBefore1937(): void /** * Tests translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -102,7 +99,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/USA/IndependenceDayTest.php b/tests/USA/IndependenceDayTest.php index 6b6dad10b..2bed9ae6b 100644 --- a/tests/USA/IndependenceDayTest.php +++ b/tests/USA/IndependenceDayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\USA; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -38,7 +35,7 @@ class IndependenceDayTest extends USABaseTestCase implements HolidayTestCase /** * Tests Independence Day on or after 1776. Independence Day is celebrated since 1776 on July 4th. * - * @throws Exception + * @throws \Exception */ public function testIndependenceDayOnAfter1776(): void { @@ -47,14 +44,14 @@ public function testIndependenceDayOnAfter1776(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-7-4", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-7-4", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests Independence Day on or after 1776 when substituted on Monday (when Independence Day falls on Sunday). * - * @throws Exception + * @throws \Exception */ public function testIndependenceDayOnAfter1776SubstitutedMonday(): void { @@ -63,14 +60,14 @@ public function testIndependenceDayOnAfter1776SubstitutedMonday(): void self::REGION, 'substituteHoliday:independenceDay', $year, - new DateTime("$year-7-5", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-7-5", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests Independence Day on or after 1776 when substituted on Friday (when Independence Day falls on Saturday). * - * @throws Exception + * @throws \Exception */ public function testIndependenceDayOnAfter1776SubstitutedFriday(): void { @@ -79,14 +76,14 @@ public function testIndependenceDayOnAfter1776SubstitutedFriday(): void self::REGION, 'substituteHoliday:independenceDay', $year, - new DateTime("$year-7-3", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-7-3", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests Independence Day before 1776. Independence Day is celebrated since 1776 on July 4th. * - * @throws Exception + * @throws \Exception */ public function testIndependenceDayBefore1776(): void { @@ -100,7 +97,7 @@ public function testIndependenceDayBefore1776(): void /** * Tests translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -115,7 +112,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/USA/JuneteenthTest.php b/tests/USA/JuneteenthTest.php index 7df2d81cd..740278dbc 100644 --- a/tests/USA/JuneteenthTest.php +++ b/tests/USA/JuneteenthTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\USA; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -38,7 +35,7 @@ class JuneteenthTest extends USABaseTestCase implements HolidayTestCase /** * Tests Juneteenth on or after 2021. Juneteenth is celebrated since 2021 on June 19th. * - * @throws Exception + * @throws \Exception */ public function testJuneteenthOnAfter2021(): void { @@ -47,14 +44,14 @@ public function testJuneteenthOnAfter2021(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-6-19", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-6-19", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests Juneteenth on or after 2021 when substituted on Monday (when Juneteenth falls on Sunday). * - * @throws Exception + * @throws \Exception */ public function testJuneteenthOnAfter2021SubstitutedMonday(): void { @@ -63,14 +60,14 @@ public function testJuneteenthOnAfter2021SubstitutedMonday(): void self::REGION, 'substituteHoliday:juneteenth', $year, - new DateTime("$year-6-20", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-6-20", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests Juneteenth on or after 2021 when substituted on Friday (when Juneteenth falls on Saturday). * - * @throws Exception + * @throws \Exception */ public function testJuneteenthOnAfter2021SubstitutedFriday(): void { @@ -79,14 +76,14 @@ public function testJuneteenthOnAfter2021SubstitutedFriday(): void self::REGION, 'substituteHoliday:juneteenth', $year, - new DateTime("$year-6-18", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-6-18", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests Juneteenth before 2021. Juneteenth is celebrated since 2021 on June 19th. * - * @throws Exception + * @throws \Exception */ public function testJuneteenthBefore2021(): void { @@ -100,7 +97,7 @@ public function testJuneteenthBefore2021(): void /** * Tests translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -115,7 +112,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/USA/LabourDayTest.php b/tests/USA/LabourDayTest.php index 5b4dad368..adf03c135 100644 --- a/tests/USA/LabourDayTest.php +++ b/tests/USA/LabourDayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\USA; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -38,7 +35,7 @@ class LabourDayTest extends USABaseTestCase implements HolidayTestCase /** * Tests Labour Day on or after 1887. Labour Day was established since 1887 on the first Monday of September. * - * @throws Exception + * @throws \Exception */ public function testLabourDayOnAfter1887(): void { @@ -47,14 +44,14 @@ public function testLabourDayOnAfter1887(): void self::REGION, self::HOLIDAY, $year, - new DateTime("first monday of september $year", new DateTimeZone(self::TIMEZONE)) + new \DateTime("first monday of september $year", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests Labour Day before 1887. Labour Day was established since 1887 on the first Monday of September. * - * @throws Exception + * @throws \Exception */ public function testLabourDayBefore1887(): void { @@ -68,7 +65,7 @@ public function testLabourDayBefore1887(): void /** * Tests translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -83,7 +80,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/USA/MartinLutherKingDayTest.php b/tests/USA/MartinLutherKingDayTest.php index fc9c4c18c..e19194c52 100644 --- a/tests/USA/MartinLutherKingDayTest.php +++ b/tests/USA/MartinLutherKingDayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\USA; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -39,7 +36,7 @@ class MartinLutherKingDayTest extends USABaseTestCase implements HolidayTestCase * Tests Dr. Martin Luther King Day on or after 1986. Dr. Martin Luther King Day was established since 1986 on the * third Monday of January. * - * @throws Exception + * @throws \Exception */ public function testMartinLutherKingDayOnAfter1986(): void { @@ -48,7 +45,7 @@ public function testMartinLutherKingDayOnAfter1986(): void self::REGION, self::HOLIDAY, $year, - new DateTime("third monday of january $year", new DateTimeZone(self::TIMEZONE)) + new \DateTime("third monday of january $year", new \DateTimeZone(self::TIMEZONE)) ); } @@ -56,7 +53,7 @@ public function testMartinLutherKingDayOnAfter1986(): void * Tests Dr. Martin Luther King Day before 1986. Dr. Martin Luther King Day was established since 1996 on the third * Monday of January. * - * @throws Exception + * @throws \Exception */ public function testMartinLutherKingDayBefore1986(): void { @@ -70,7 +67,7 @@ public function testMartinLutherKingDayBefore1986(): void /** * Tests translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -85,7 +82,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/USA/MemorialDayTest.php b/tests/USA/MemorialDayTest.php index 4d2011b51..a975eb64e 100644 --- a/tests/USA/MemorialDayTest.php +++ b/tests/USA/MemorialDayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\USA; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -39,7 +36,7 @@ class MemorialDayTest extends USABaseTestCase implements HolidayTestCase * Tests Memorial Day on or after 1968. Memorial Day was established since 1865 on May 30 and was changed in 1968 * to the last Monday in May. * - * @throws Exception + * @throws \Exception */ public function testMemorialDayOnAfter1968(): void { @@ -48,7 +45,7 @@ public function testMemorialDayOnAfter1968(): void self::REGION, self::HOLIDAY, $year, - new DateTime("last monday of may $year", new DateTimeZone(self::TIMEZONE)) + new \DateTime("last monday of may $year", new \DateTimeZone(self::TIMEZONE)) ); } @@ -56,7 +53,7 @@ public function testMemorialDayOnAfter1968(): void * Tests Memorial Day between 1865 and 1967. Memorial Day was established since 1865 on May 30 and was changed in * 1968 to the last Monday in May. * - * @throws Exception + * @throws \Exception */ public function testMemorialDayBetween1865And1967(): void { @@ -65,7 +62,7 @@ public function testMemorialDayBetween1865And1967(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-5-30", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-5-30", new \DateTimeZone(self::TIMEZONE)) ); } @@ -73,7 +70,7 @@ public function testMemorialDayBetween1865And1967(): void * Tests Memorial Day before 1865. Memorial Day was established since 1865 on May 30 and was changed in 1968 to the * last Monday in May. * - * @throws Exception + * @throws \Exception */ public function testMemorialDayBefore1865(): void { @@ -87,7 +84,7 @@ public function testMemorialDayBefore1865(): void /** * Tests translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -102,7 +99,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/USA/NewYearsDayTest.php b/tests/USA/NewYearsDayTest.php index 456a9b084..7ee398e13 100644 --- a/tests/USA/NewYearsDayTest.php +++ b/tests/USA/NewYearsDayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\USA; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -33,7 +30,7 @@ class NewYearsDayTest extends USABaseTestCase implements HolidayTestCase /** * Tests New Years Day. * - * @throws Exception + * @throws \Exception */ public function testNewYearsDay(): void { @@ -42,14 +39,14 @@ public function testNewYearsDay(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-1-1", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-1-1", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests New Years Day when substituted on Monday (when New Years Day falls on Sunday). * - * @throws Exception + * @throws \Exception */ public function testNewYearsDaySubstitutedMonday(): void { @@ -58,14 +55,14 @@ public function testNewYearsDaySubstitutedMonday(): void self::REGION, 'substituteHoliday:newYearsDay', $year, - new DateTime("$year-1-2", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-1-2", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests New Years Day when substituted on Friday (when New Years Day falls on Saturday). * - * @throws Exception + * @throws \Exception */ public function testNewYearsDaySubstitutedFriday(): void { @@ -75,14 +72,14 @@ public function testNewYearsDaySubstitutedFriday(): void self::REGION, 'substituteHoliday:newYearsDay', $year, - new DateTime("$subYear-12-31", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$subYear-12-31", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -97,7 +94,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/USA/ThanksgivingDayTest.php b/tests/USA/ThanksgivingDayTest.php index 47c7e8e60..14cac9c00 100644 --- a/tests/USA/ThanksgivingDayTest.php +++ b/tests/USA/ThanksgivingDayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\USA; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -39,7 +36,7 @@ class ThanksgivingDayTest extends USABaseTestCase implements HolidayTestCase * Tests Thanksgiving Day on or after 1863. Thanksgiving Day is celebrated since 1863 on the fourth Thursday * of November. * - * @throws Exception + * @throws \Exception */ public function testThanksgivingDayOnAfter1863(): void { @@ -48,7 +45,7 @@ public function testThanksgivingDayOnAfter1863(): void self::REGION, self::HOLIDAY, $year, - new DateTime("fourth thursday of november $year", new DateTimeZone(self::TIMEZONE)) + new \DateTime("fourth thursday of november $year", new \DateTimeZone(self::TIMEZONE)) ); } @@ -56,7 +53,7 @@ public function testThanksgivingDayOnAfter1863(): void * Tests Thanksgiving Day before 1863. ThanksgivingDay Day is celebrated since 1863 on the fourth Thursday * of November. * - * @throws Exception + * @throws \Exception */ public function testThanksgivingDayBefore1863(): void { @@ -70,7 +67,7 @@ public function testThanksgivingDayBefore1863(): void /** * Tests translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -85,7 +82,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/USA/USATest.php b/tests/USA/USATest.php index df8e01d9e..32bdfb943 100644 --- a/tests/USA/USATest.php +++ b/tests/USA/USATest.php @@ -14,7 +14,6 @@ namespace Yasumi\tests\USA; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\ProviderTestCase; @@ -96,7 +95,7 @@ public function testOtherHolidays(): void } /** - * @throws ReflectionException + * @throws \ReflectionException * @throws \Exception */ public function testSources(): void diff --git a/tests/USA/VeteransDayTest.php b/tests/USA/VeteransDayTest.php index b7a4bdb89..5b47270d6 100644 --- a/tests/USA/VeteransDayTest.php +++ b/tests/USA/VeteransDayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\USA; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Exception\MissingTranslationException; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -40,7 +37,7 @@ class VeteransDayTest extends USABaseTestCase implements HolidayTestCase /** * Tests Veterans Day on or after 1919. Veterans Day was established in 1919 on November 11. * - * @throws Exception + * @throws \Exception */ public function testVeteransDayOnAfter1919(): void { @@ -49,14 +46,14 @@ public function testVeteransDayOnAfter1919(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-11-11", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-11-11", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests Veterans Day on or after 1919 when substituted on Monday (when Veterans Day falls on Sunday). * - * @throws Exception + * @throws \Exception */ public function testVeteransDayOnAfter1919SubstitutedMonday(): void { @@ -65,14 +62,14 @@ public function testVeteransDayOnAfter1919SubstitutedMonday(): void self::REGION, 'substituteHoliday:veteransDay', $year, - new DateTime("$year-11-12", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-11-12", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests Veterans Day on or after 1919 when substituted on Friday (when Veterans Day falls on Saturday). * - * @throws Exception + * @throws \Exception */ public function testVeteransDayOnAfter1919SubstitutedFriday(): void { @@ -81,14 +78,14 @@ public function testVeteransDayOnAfter1919SubstitutedFriday(): void self::REGION, 'substituteHoliday:veteransDay', $year, - new DateTime("$year-11-10", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-11-10", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests Veterans Day before 1919. Veterans Day was established in 1919 on November 11. * - * @throws Exception + * @throws \Exception */ public function testVeteransDayBefore1919(): void { @@ -108,7 +105,7 @@ public function testVeteransDayNameBefore1954(): void { try { $year = $this->generateRandomYear(self::ESTABLISHMENT_YEAR, 1953); - } catch (Exception $e) { + } catch (\Exception $e) { } $holidays = Yasumi::create(self::REGION, $year); @@ -125,7 +122,7 @@ public function testVeteransDayNameAfter1954(): void { try { $year = $this->generateRandomYear(1954); - } catch (Exception $e) { + } catch (\Exception $e) { } $holidays = Yasumi::create(self::REGION, $year); @@ -136,7 +133,7 @@ public function testVeteransDayNameAfter1954(): void /** * Tests translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -151,7 +148,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/USA/WashingtonsBirthdayTest.php b/tests/USA/WashingtonsBirthdayTest.php index be5778f85..f2579e949 100644 --- a/tests/USA/WashingtonsBirthdayTest.php +++ b/tests/USA/WashingtonsBirthdayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\USA; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -39,7 +36,7 @@ class WashingtonsBirthdayTest extends USABaseTestCase implements HolidayTestCase * Tests Washington's Birthday on or after 1968. Washington's Birthday was established since 1879 on February 22 * and was changed in 1968 to the third Monday in February. * - * @throws Exception + * @throws \Exception */ public function testWashingtonsBirthdayOnAfter1968(): void { @@ -48,7 +45,7 @@ public function testWashingtonsBirthdayOnAfter1968(): void self::REGION, self::HOLIDAY, $year, - new DateTime("third monday of february $year", new DateTimeZone(self::TIMEZONE)) + new \DateTime("third monday of february $year", new \DateTimeZone(self::TIMEZONE)) ); } @@ -56,7 +53,7 @@ public function testWashingtonsBirthdayOnAfter1968(): void * Tests Washington's Birthday between 1879 and 1967. Washington's Birthday was established since 1879 on February * 22 and was changed in 1968 to the third Monday in February. * - * @throws Exception + * @throws \Exception */ public function testWashingtonsBirthdayBetween1879And1967(): void { @@ -65,7 +62,7 @@ public function testWashingtonsBirthdayBetween1879And1967(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-2-22", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-2-22", new \DateTimeZone(self::TIMEZONE)) ); } @@ -73,7 +70,7 @@ public function testWashingtonsBirthdayBetween1879And1967(): void * Tests Washington's Birthday before 1879. Washington's Birthday was established since 1879 on February 22 and was * changed in 1968 to the third Monday in February. * - * @throws Exception + * @throws \Exception */ public function testWashingtonsBirthdayBefore1879(): void { @@ -87,7 +84,7 @@ public function testWashingtonsBirthdayBefore1879(): void /** * Tests translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -102,7 +99,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Ukraine/CatholicChristmasDayTest.php b/tests/Ukraine/CatholicChristmasDayTest.php index b507a7b6f..7cf496149 100644 --- a/tests/Ukraine/CatholicChristmasDayTest.php +++ b/tests/Ukraine/CatholicChristmasDayTest.php @@ -15,8 +15,6 @@ namespace Yasumi\tests\Ukraine; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; use Yasumi\Yasumi; @@ -36,8 +34,8 @@ class CatholicChristmasDayTest extends UkraineBaseTestCase implements HolidayTes * * @dataProvider CatholicChristmasDayDataProvider * - * @param int $year the year for which International Workers' Day needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which International Workers' Day needs to be tested + * @param \DateTime $expected the expected date */ public function testCatholicChristmasDay(int $year, \DateTimeInterface $expected): void { @@ -47,7 +45,7 @@ public function testCatholicChristmasDay(int $year, \DateTimeInterface $expected /** * Tests Catholic Christmas Day before 2017. * - * @throws Exception + * @throws \Exception */ public function testNoCatholicChristmasDayBefore2017(): void { @@ -63,7 +61,7 @@ public function testNoCatholicChristmasDayBefore2017(): void /** * Tests translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -78,7 +76,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { @@ -90,7 +88,7 @@ public function testHolidayType(): void * * @return array list of test dates for Catholic Christmas Day * - * @throws Exception + * @throws \Exception */ public function CatholicChristmasDayDataProvider(): array { diff --git a/tests/Ukraine/ChristmasDayTest.php b/tests/Ukraine/ChristmasDayTest.php index 6dcc53276..6e83ed060 100644 --- a/tests/Ukraine/ChristmasDayTest.php +++ b/tests/Ukraine/ChristmasDayTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\Ukraine; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,8 +32,8 @@ class ChristmasDayTest extends UkraineBaseTestCase implements HolidayTestCase * * @dataProvider HolidayDataProvider * - * @param int $year the year for which Christmas Day needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which Christmas Day needs to be tested + * @param \DateTime $expected the expected date */ public function testChristmasDay(int $year, \DateTimeInterface $expected): void { @@ -47,7 +45,7 @@ public function testChristmasDay(int $year, \DateTimeInterface $expected): void * * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function HolidayDataProvider(): array { @@ -57,7 +55,7 @@ public function HolidayDataProvider(): array /** * Tests translated name of Christmas Day. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -72,7 +70,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Ukraine/ConstitutionDayTest.php b/tests/Ukraine/ConstitutionDayTest.php index 471bd9f53..c0289abe3 100644 --- a/tests/Ukraine/ConstitutionDayTest.php +++ b/tests/Ukraine/ConstitutionDayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Ukraine; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -31,7 +28,7 @@ class ConstitutionDayTest extends UkraineBaseTestCase implements HolidayTestCase public const HOLIDAY = 'constitutionDay'; /** - * @throws Exception + * @throws \Exception */ public function testHoliday(): void { @@ -40,7 +37,7 @@ public function testHoliday(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-06-28", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-06-28", new \DateTimeZone(self::TIMEZONE)) ); } diff --git a/tests/Ukraine/DefenderOfUkraineDayTest.php b/tests/Ukraine/DefenderOfUkraineDayTest.php index bb3725ddb..171e83500 100644 --- a/tests/Ukraine/DefenderOfUkraineDayTest.php +++ b/tests/Ukraine/DefenderOfUkraineDayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Ukraine; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -31,7 +28,7 @@ class DefenderOfUkraineDayTest extends UkraineBaseTestCase implements HolidayTes public const HOLIDAY = 'defenderOfUkraineDay'; /** - * @throws Exception + * @throws \Exception */ public function testHoliday(): void { @@ -40,7 +37,7 @@ public function testHoliday(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-10-14", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-10-14", new \DateTimeZone(self::TIMEZONE)) ); } diff --git a/tests/Ukraine/EasterTest.php b/tests/Ukraine/EasterTest.php index b5eefe709..1d0ea4980 100644 --- a/tests/Ukraine/EasterTest.php +++ b/tests/Ukraine/EasterTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Ukraine; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -33,7 +30,7 @@ class EasterTest extends UkraineBaseTestCase implements HolidayTestCase /** * Tests the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHoliday(): void { @@ -42,14 +39,14 @@ public function testHoliday(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-04-19", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-04-19", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -64,7 +61,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Ukraine/IndependenceDayTest.php b/tests/Ukraine/IndependenceDayTest.php index 55bacedea..2f7eabe8f 100644 --- a/tests/Ukraine/IndependenceDayTest.php +++ b/tests/Ukraine/IndependenceDayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Ukraine; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -31,7 +28,7 @@ class IndependenceDayTest extends UkraineBaseTestCase implements HolidayTestCase public const HOLIDAY = 'independenceDay'; /** - * @throws Exception + * @throws \Exception */ public function testHoliday(): void { @@ -40,7 +37,7 @@ public function testHoliday(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-08-24", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-08-24", new \DateTimeZone(self::TIMEZONE)) ); } diff --git a/tests/Ukraine/InternationalWomensDayTest.php b/tests/Ukraine/InternationalWomensDayTest.php index fbca0d04d..309be897c 100644 --- a/tests/Ukraine/InternationalWomensDayTest.php +++ b/tests/Ukraine/InternationalWomensDayTest.php @@ -14,7 +14,6 @@ namespace Yasumi\tests\Ukraine; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -41,7 +40,7 @@ public function testHoliday(int $year, \DateTimeInterface $expected): void * * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function HolidayDataProvider(): array { @@ -51,7 +50,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -66,7 +65,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Ukraine/InternationalWorkersDayTest.php b/tests/Ukraine/InternationalWorkersDayTest.php index 4ba8bfe19..e08954031 100644 --- a/tests/Ukraine/InternationalWorkersDayTest.php +++ b/tests/Ukraine/InternationalWorkersDayTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\Ukraine; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,8 +32,8 @@ class InternationalWorkersDayTest extends UkraineBaseTestCase implements Holiday * * @dataProvider InternationalWorkersDayDataProvider * - * @param int $year the year for which International Workers' Day needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which International Workers' Day needs to be tested + * @param \DateTime $expected the expected date */ public function testInternationalWorkersDay(int $year, \DateTimeInterface $expected): void { @@ -45,7 +43,7 @@ public function testInternationalWorkersDay(int $year, \DateTimeInterface $expec /** * Tests translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -60,7 +58,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { @@ -72,7 +70,7 @@ public function testHolidayType(): void * * @return array list of test dates for International Workers' Day * - * @throws Exception + * @throws \Exception */ public function InternationalWorkersDayDataProvider(): array { diff --git a/tests/Ukraine/NewYearsDayTest.php b/tests/Ukraine/NewYearsDayTest.php index 20fb1b25c..b601e3a74 100644 --- a/tests/Ukraine/NewYearsDayTest.php +++ b/tests/Ukraine/NewYearsDayTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\Ukraine; -use DateTime; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -34,8 +32,8 @@ class NewYearsDayTest extends UkraineBaseTestCase implements HolidayTestCase * * @dataProvider HolidayDataProvider * - * @param int $year the year for which the holiday defined in this test needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which the holiday defined in this test needs to be tested + * @param \DateTime $expected the expected date */ public function testHoliday(int $year, \DateTimeInterface $expected): void { @@ -47,7 +45,7 @@ public function testHoliday(int $year, \DateTimeInterface $expected): void * * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function HolidayDataProvider(): array { @@ -57,7 +55,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -72,7 +70,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Ukraine/PentecostTest.php b/tests/Ukraine/PentecostTest.php index 5a00d538c..97d6ae64f 100644 --- a/tests/Ukraine/PentecostTest.php +++ b/tests/Ukraine/PentecostTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Ukraine; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -33,7 +30,7 @@ class PentecostTest extends UkraineBaseTestCase implements HolidayTestCase /** * Tests the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHoliday(): void { @@ -42,14 +39,14 @@ public function testHoliday(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-06-07", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-06-07", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -64,7 +61,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/Ukraine/SecondInternationalWorkersDayTest.php b/tests/Ukraine/SecondInternationalWorkersDayTest.php index 1cc683821..b09e02037 100644 --- a/tests/Ukraine/SecondInternationalWorkersDayTest.php +++ b/tests/Ukraine/SecondInternationalWorkersDayTest.php @@ -15,7 +15,6 @@ namespace Yasumi\tests\Ukraine; -use DateTime; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; use Yasumi\Yasumi; @@ -35,8 +34,8 @@ class SecondInternationalWorkersDayTest extends UkraineBaseTestCase implements H * * @dataProvider SecondInternationalWorkersDayDataProvider * - * @param int $year the year for which International Workers' Day needs to be tested - * @param DateTime $expected the expected date + * @param int $year the year for which International Workers' Day needs to be tested + * @param \DateTime $expected the expected date */ public function testSecondInternationalWorkersDay(int $year, \DateTimeInterface $expected): void { diff --git a/tests/Ukraine/SubstitutedHolidayTest.php b/tests/Ukraine/SubstitutedHolidayTest.php index eb2ae3c57..c6c705ba4 100644 --- a/tests/Ukraine/SubstitutedHolidayTest.php +++ b/tests/Ukraine/SubstitutedHolidayTest.php @@ -15,10 +15,6 @@ namespace Yasumi\tests\Ukraine; -use DateTime; -use DateTimeZone; -use Exception; -use ReflectionException; use Yasumi\Holiday; use Yasumi\SubstituteHoliday; use Yasumi\tests\HolidayTestCase; @@ -32,8 +28,8 @@ class SubstitutedHolidayTest extends UkraineBaseTestCase implements HolidayTestC /** * Tests the substitution of holidays on saturday (weekend). * - * @throws Exception - * @throws ReflectionException + * @throws \Exception + * @throws \ReflectionException */ public function testSaturdaySubstitution(): void { @@ -45,8 +41,8 @@ public function testSaturdaySubstitution(): void self::REGION, $holiday, $year, - new DateTime("$year-05-09", new DateTimeZone(self::TIMEZONE)), - new DateTime("$year-05-11", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-05-09", new \DateTimeZone(self::TIMEZONE)), + new \DateTime("$year-05-11", new \DateTimeZone(self::TIMEZONE)) ); unset($year, $holiday); @@ -96,8 +92,8 @@ public function assertHolidayWithSubstitution( /** * Tests the substitution of holidays on sunday (weekend). * - * @throws Exception - * @throws ReflectionException + * @throws \Exception + * @throws \ReflectionException */ public function testSundaySubstitution(): void { @@ -109,8 +105,8 @@ public function testSundaySubstitution(): void self::REGION, $holiday, $year, - new DateTime("$year-06-28", new DateTimeZone(self::TIMEZONE)), - new DateTime("$year-06-29", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-06-28", new \DateTimeZone(self::TIMEZONE)), + new \DateTime("$year-06-29", new \DateTimeZone(self::TIMEZONE)) ); unset($year, $holiday); @@ -120,8 +116,8 @@ public function testSundaySubstitution(): void * Tests the substitution of new year (1. January) on a weekend. * Special: no substitution at new year (1. January) on a weekend. * - * @throws Exception - * @throws ReflectionException + * @throws \Exception + * @throws \ReflectionException */ public function testNewYearNoSubstitution(): void { @@ -133,7 +129,7 @@ public function testNewYearNoSubstitution(): void self::REGION, $holiday, $year, - new DateTime("$year-01-01", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-01-01", new \DateTimeZone(self::TIMEZONE)) ); unset($year, $holiday); @@ -143,8 +139,8 @@ public function testNewYearNoSubstitution(): void * Tests the substitution of Catholic Christmas Day (25. December) on a weekend. * Special: no substitution at Catholic Christmas Day (25. December) on a weekend. * - * @throws Exception - * @throws ReflectionException + * @throws \Exception + * @throws \ReflectionException */ public function testCatholicChristmasDayNoSubstitution(): void { @@ -156,7 +152,7 @@ public function testCatholicChristmasDayNoSubstitution(): void self::REGION, $holiday, $year, - new DateTime("$year-12-25", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-12-25", new \DateTimeZone(self::TIMEZONE)) ); unset($year, $holiday); diff --git a/tests/Ukraine/UkraineTest.php b/tests/Ukraine/UkraineTest.php index 6df25c7f9..6574a485f 100644 --- a/tests/Ukraine/UkraineTest.php +++ b/tests/Ukraine/UkraineTest.php @@ -15,7 +15,6 @@ namespace Yasumi\tests\Ukraine; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\ProviderTestCase; @@ -115,7 +114,7 @@ public function testOtherHolidays(): void } /** - * @throws ReflectionException + * @throws \ReflectionException * @throws \Exception */ public function testSources(): void diff --git a/tests/Ukraine/VictoryDayTest.php b/tests/Ukraine/VictoryDayTest.php index 942530533..d7c1a0d28 100644 --- a/tests/Ukraine/VictoryDayTest.php +++ b/tests/Ukraine/VictoryDayTest.php @@ -14,7 +14,6 @@ namespace Yasumi\tests\Ukraine; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -41,7 +40,7 @@ public function testHoliday(int $year, \DateTimeInterface $expected): void * * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function HolidayDataProvider(): array { @@ -51,7 +50,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -66,7 +65,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/UnitedKingdom/BoxingDayTest.php b/tests/UnitedKingdom/BoxingDayTest.php index 1c2015824..e7c9b4bd8 100644 --- a/tests/UnitedKingdom/BoxingDayTest.php +++ b/tests/UnitedKingdom/BoxingDayTest.php @@ -14,10 +14,6 @@ namespace Yasumi\tests\UnitedKingdom; -use DateInterval; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -39,15 +35,15 @@ class BoxingDayTest extends UnitedKingdomBaseTestCase implements HolidayTestCase * @param int $year the year for which the holiday defined in this test needs to be tested * @param string $expected the expected date * - * @throws Exception + * @throws \Exception */ public function testHoliday(int $year, string $expected): void { - $date = new DateTime($expected, new DateTimeZone(self::TIMEZONE)); + $date = new \DateTime($expected, new \DateTimeZone(self::TIMEZONE)); $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $date); if (\in_array((int) $date->format('w'), [0, 6], true)) { - $date->add(new DateInterval('P2D')); + $date->add(new \DateInterval('P2D')); $this->assertHoliday(self::REGION, 'substituteHoliday:'.self::HOLIDAY, $year, $date); $this->assertHolidayType(self::REGION, 'substituteHoliday:'.self::HOLIDAY, $year, Holiday::TYPE_BANK); } @@ -58,7 +54,7 @@ public function testHoliday(int $year, string $expected): void * * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function HolidayDataProvider(): array { @@ -66,7 +62,7 @@ public function HolidayDataProvider(): array for ($y = 0; $y < self::TEST_ITERATIONS; ++$y) { $year = $this->generateRandomYear(); - $date = new DateTime("$year-12-26", new DateTimeZone(self::TIMEZONE)); + $date = new \DateTime("$year-12-26", new \DateTimeZone(self::TIMEZONE)); $data[] = [$year, $date->format('Y-m-d')]; } @@ -77,7 +73,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -92,7 +88,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/UnitedKingdom/ChristmasDayTest.php b/tests/UnitedKingdom/ChristmasDayTest.php index 9c46a7d30..8de2b4509 100644 --- a/tests/UnitedKingdom/ChristmasDayTest.php +++ b/tests/UnitedKingdom/ChristmasDayTest.php @@ -14,10 +14,6 @@ namespace Yasumi\tests\UnitedKingdom; -use DateInterval; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -39,15 +35,15 @@ class ChristmasDayTest extends UnitedKingdomBaseTestCase implements HolidayTestC * @param int $year the year for which the holiday defined in this test needs to be tested * @param string $expected the expected date * - * @throws Exception + * @throws \Exception */ public function testHoliday(int $year, string $expected): void { - $date = new DateTime($expected, new DateTimeZone(self::TIMEZONE)); + $date = new \DateTime($expected, new \DateTimeZone(self::TIMEZONE)); $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $date); if (\in_array((int) $date->format('w'), [0, 6], true)) { - $date->add(new DateInterval('P2D')); + $date->add(new \DateInterval('P2D')); $this->assertHoliday(self::REGION, 'substituteHoliday:'.self::HOLIDAY, $year, $date); $this->assertHolidayType(self::REGION, 'substituteHoliday:'.self::HOLIDAY, $year, Holiday::TYPE_BANK); } @@ -58,7 +54,7 @@ public function testHoliday(int $year, string $expected): void * * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function HolidayDataProvider(): array { @@ -66,7 +62,7 @@ public function HolidayDataProvider(): array for ($y = 0; $y < self::TEST_ITERATIONS; ++$y) { $year = $this->generateRandomYear(); - $date = new DateTime("$year-12-25", new DateTimeZone(self::TIMEZONE)); + $date = new \DateTime("$year-12-25", new \DateTimeZone(self::TIMEZONE)); $data[] = [$year, $date->format('Y-m-d')]; } @@ -77,7 +73,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -92,7 +88,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/UnitedKingdom/EasterMondayTest.php b/tests/UnitedKingdom/EasterMondayTest.php index 3d8b181fd..75971f1e3 100644 --- a/tests/UnitedKingdom/EasterMondayTest.php +++ b/tests/UnitedKingdom/EasterMondayTest.php @@ -14,10 +14,6 @@ namespace Yasumi\tests\UnitedKingdom; -use DateInterval; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -39,7 +35,7 @@ class EasterMondayTest extends UnitedKingdomBaseTestCase implements HolidayTestC * @param int $year the year for which the holiday defined in this test needs to be tested * @param string $expected the expected date * - * @throws Exception + * @throws \Exception */ public function testHoliday(int $year, string $expected): void { @@ -47,7 +43,7 @@ public function testHoliday(int $year, string $expected): void self::REGION, self::HOLIDAY, $year, - new DateTime($expected, new DateTimeZone(self::TIMEZONE)) + new \DateTime($expected, new \DateTimeZone(self::TIMEZONE)) ); } @@ -56,7 +52,7 @@ public function testHoliday(int $year, string $expected): void * * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function HolidayDataProvider(): array { @@ -65,7 +61,7 @@ public function HolidayDataProvider(): array for ($y = 0; $y < 50; ++$y) { $year = $this->generateRandomYear(); $date = $this->calculateEaster($year, self::TIMEZONE); - $date->add(new DateInterval('P1D')); + $date->add(new \DateInterval('P1D')); $data[] = [$year, $date->format('Y-m-d')]; } @@ -76,7 +72,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -91,7 +87,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/UnitedKingdom/England/BoxingDayTest.php b/tests/UnitedKingdom/England/BoxingDayTest.php index 7b5216a22..59bc9c78d 100644 --- a/tests/UnitedKingdom/England/BoxingDayTest.php +++ b/tests/UnitedKingdom/England/BoxingDayTest.php @@ -14,10 +14,6 @@ namespace Yasumi\tests\UnitedKingdom\England; -use DateInterval; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -39,15 +35,15 @@ class BoxingDayTest extends EnglandBaseTestCase implements HolidayTestCase * @param int $year the year for which the holiday defined in this test needs to be tested * @param string $expected the expected date * - * @throws Exception + * @throws \Exception */ public function testHoliday(int $year, string $expected): void { - $date = new DateTime($expected, new DateTimeZone(self::TIMEZONE)); + $date = new \DateTime($expected, new \DateTimeZone(self::TIMEZONE)); $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $date); if (\in_array((int) $date->format('w'), [0, 6], true)) { - $date->add(new DateInterval('P2D')); + $date->add(new \DateInterval('P2D')); $this->assertHoliday(self::REGION, 'substituteHoliday:'.self::HOLIDAY, $year, $date); $this->assertHolidayType(self::REGION, 'substituteHoliday:'.self::HOLIDAY, $year, Holiday::TYPE_BANK); } @@ -58,7 +54,7 @@ public function testHoliday(int $year, string $expected): void * * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function HolidayDataProvider(): array { @@ -66,7 +62,7 @@ public function HolidayDataProvider(): array for ($y = 0; $y < self::TEST_ITERATIONS; ++$y) { $year = $this->generateRandomYear(); - $date = new DateTime("$year-12-26", new DateTimeZone(self::TIMEZONE)); + $date = new \DateTime("$year-12-26", new \DateTimeZone(self::TIMEZONE)); $data[] = [$year, $date->format('Y-m-d')]; } @@ -77,7 +73,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -92,7 +88,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/UnitedKingdom/England/ChristmasDayTest.php b/tests/UnitedKingdom/England/ChristmasDayTest.php index e292d6c70..d9b0a4a99 100644 --- a/tests/UnitedKingdom/England/ChristmasDayTest.php +++ b/tests/UnitedKingdom/England/ChristmasDayTest.php @@ -14,10 +14,6 @@ namespace Yasumi\tests\UnitedKingdom\England; -use DateInterval; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -39,15 +35,15 @@ class ChristmasDayTest extends EnglandBaseTestCase implements HolidayTestCase * @param int $year the year for which the holiday defined in this test needs to be tested * @param string $expected the expected date * - * @throws Exception + * @throws \Exception */ public function testHoliday(int $year, string $expected): void { - $date = new DateTime($expected, new DateTimeZone(self::TIMEZONE)); + $date = new \DateTime($expected, new \DateTimeZone(self::TIMEZONE)); $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $date); if (\in_array((int) $date->format('w'), [0, 6], true)) { - $date->add(new DateInterval('P2D')); + $date->add(new \DateInterval('P2D')); $this->assertHoliday(self::REGION, 'substituteHoliday:'.self::HOLIDAY, $year, $date); $this->assertHolidayType(self::REGION, 'substituteHoliday:'.self::HOLIDAY, $year, Holiday::TYPE_BANK); } @@ -58,7 +54,7 @@ public function testHoliday(int $year, string $expected): void * * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function HolidayDataProvider(): array { @@ -66,7 +62,7 @@ public function HolidayDataProvider(): array for ($y = 0; $y < self::TEST_ITERATIONS; ++$y) { $year = $this->generateRandomYear(); - $date = new DateTime("$year-12-25", new DateTimeZone(self::TIMEZONE)); + $date = new \DateTime("$year-12-25", new \DateTimeZone(self::TIMEZONE)); $data[] = [$year, $date->format('Y-m-d')]; } @@ -77,7 +73,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -92,7 +88,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/UnitedKingdom/England/EasterMondayTest.php b/tests/UnitedKingdom/England/EasterMondayTest.php index 44621dea9..10b342df7 100644 --- a/tests/UnitedKingdom/England/EasterMondayTest.php +++ b/tests/UnitedKingdom/England/EasterMondayTest.php @@ -14,10 +14,6 @@ namespace Yasumi\tests\UnitedKingdom\England; -use DateInterval; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -39,7 +35,7 @@ class EasterMondayTest extends EnglandBaseTestCase implements HolidayTestCase * @param int $year the year for which the holiday defined in this test needs to be tested * @param string $expected the expected date * - * @throws Exception + * @throws \Exception */ public function testHoliday(int $year, string $expected): void { @@ -47,7 +43,7 @@ public function testHoliday(int $year, string $expected): void self::REGION, self::HOLIDAY, $year, - new DateTime($expected, new DateTimeZone(self::TIMEZONE)) + new \DateTime($expected, new \DateTimeZone(self::TIMEZONE)) ); } @@ -56,7 +52,7 @@ public function testHoliday(int $year, string $expected): void * * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function HolidayDataProvider(): array { @@ -65,7 +61,7 @@ public function HolidayDataProvider(): array for ($y = 0; $y < 50; ++$y) { $year = $this->generateRandomYear(); $date = $this->calculateEaster($year, self::TIMEZONE); - $date->add(new DateInterval('P1D')); + $date->add(new \DateInterval('P1D')); $data[] = [$year, $date->format('Y-m-d')]; } @@ -76,7 +72,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -91,7 +87,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/UnitedKingdom/England/EnglandTest.php b/tests/UnitedKingdom/England/EnglandTest.php index 4c6a5794e..ab5ba6842 100644 --- a/tests/UnitedKingdom/England/EnglandTest.php +++ b/tests/UnitedKingdom/England/EnglandTest.php @@ -14,7 +14,6 @@ namespace Yasumi\tests\UnitedKingdom\England; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\ProviderTestCase; @@ -105,7 +104,7 @@ public function testOtherHolidays(): void } /** - * @throws ReflectionException + * @throws \ReflectionException * @throws \Exception */ public function testSources(): void diff --git a/tests/UnitedKingdom/England/GoodFridayTest.php b/tests/UnitedKingdom/England/GoodFridayTest.php index dbefe0c33..01ce23772 100644 --- a/tests/UnitedKingdom/England/GoodFridayTest.php +++ b/tests/UnitedKingdom/England/GoodFridayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\UnitedKingdom\England; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -33,7 +30,7 @@ class GoodFridayTest extends EnglandBaseTestCase implements HolidayTestCase /** * Tests the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHoliday(): void { @@ -42,14 +39,14 @@ public function testHoliday(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-3-30", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-3-30", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -64,7 +61,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/UnitedKingdom/England/MayDayBankHolidayTest.php b/tests/UnitedKingdom/England/MayDayBankHolidayTest.php index 8844c7daf..0da30b7b0 100644 --- a/tests/UnitedKingdom/England/MayDayBankHolidayTest.php +++ b/tests/UnitedKingdom/England/MayDayBankHolidayTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\UnitedKingdom\England; -use DateTime; -use DateTimeZone; use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -38,7 +36,7 @@ class MayDayBankHolidayTest extends EnglandBaseTestCase implements HolidayTestCa /** * Tests the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHoliday(): void { @@ -47,14 +45,14 @@ public function testHoliday(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-5-2", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-5-2", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests the holiday exception in 1995 and 2020. * - * @throws Exception + * @throws \Exception */ public function testHolidayExceptions(): void { @@ -62,21 +60,21 @@ public function testHolidayExceptions(): void self::REGION, self::HOLIDAY, 1995, - new DateTime('1995-5-8', new DateTimeZone(self::TIMEZONE)) + new \DateTime('1995-5-8', new \DateTimeZone(self::TIMEZONE)) ); $this->assertHoliday( self::REGION, self::HOLIDAY, 2020, - new DateTime('2020-5-8', new DateTimeZone(self::TIMEZONE)) + new \DateTime('2020-5-8', new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests the holiday defined in this test before establishment. * - * @throws Exception + * @throws \Exception */ public function testHolidayBeforeEstablishment(): void { @@ -90,7 +88,7 @@ public function testHolidayBeforeEstablishment(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -105,7 +103,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/UnitedKingdom/England/NewYearsDayTest.php b/tests/UnitedKingdom/England/NewYearsDayTest.php index c62264820..9fc456998 100644 --- a/tests/UnitedKingdom/England/NewYearsDayTest.php +++ b/tests/UnitedKingdom/England/NewYearsDayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\UnitedKingdom\England; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -48,7 +45,7 @@ class NewYearsDayTest extends EnglandBaseTestCase implements HolidayTestCase * @param int $year the year for which the holiday defined in this test needs to be tested * @param string $expected the expected date * - * @throws Exception + * @throws \Exception */ public function testHolidayOnAfterEstablishment(int $year, string $expected): void { @@ -56,14 +53,14 @@ public function testHolidayOnAfterEstablishment(int $year, string $expected): vo self::REGION, self::HOLIDAY, $year, - new DateTime($expected, new DateTimeZone(self::TIMEZONE)) + new \DateTime($expected, new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests the holiday defined in this test before establishment. * - * @throws Exception + * @throws \Exception */ public function testHolidayBeforeEstablishment(): void { @@ -77,7 +74,7 @@ public function testHolidayBeforeEstablishment(): void /** * Tests that the holiday defined in this test is of the type 'observance' before the year it was changed. * - * @throws Exception + * @throws \Exception */ public function testHolidayIsObservedTypeBeforeChange(): void { @@ -94,7 +91,7 @@ public function testHolidayIsObservedTypeBeforeChange(): void * * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function HolidayDataProvider(): array { @@ -104,7 +101,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -119,7 +116,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/UnitedKingdom/England/SpringBankHolidayTest.php b/tests/UnitedKingdom/England/SpringBankHolidayTest.php index 5bb5d6744..683802213 100644 --- a/tests/UnitedKingdom/England/SpringBankHolidayTest.php +++ b/tests/UnitedKingdom/England/SpringBankHolidayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\UnitedKingdom\England; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -38,7 +35,7 @@ class SpringBankHolidayTest extends EnglandBaseTestCase implements HolidayTestCa /** * Tests the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHoliday(): void { @@ -47,14 +44,14 @@ public function testHoliday(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-5-30", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-5-30", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests the holiday exceptions in 2002 and 2012. * - * @throws Exception + * @throws \Exception */ public function testHolidayException(): void { @@ -62,21 +59,21 @@ public function testHolidayException(): void self::REGION, self::HOLIDAY, 2002, - new DateTime('2002-6-4', new DateTimeZone(self::TIMEZONE)) + new \DateTime('2002-6-4', new \DateTimeZone(self::TIMEZONE)) ); $this->assertHoliday( self::REGION, self::HOLIDAY, 2012, - new DateTime('2012-6-4', new DateTimeZone(self::TIMEZONE)) + new \DateTime('2012-6-4', new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests the holiday defined in this test before establishment. * - * @throws Exception + * @throws \Exception */ public function testHolidayBeforeEstablishment(): void { @@ -90,7 +87,7 @@ public function testHolidayBeforeEstablishment(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -105,7 +102,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/UnitedKingdom/England/SummerBankHolidayTest.php b/tests/UnitedKingdom/England/SummerBankHolidayTest.php index f292efbd1..35fe626b1 100644 --- a/tests/UnitedKingdom/England/SummerBankHolidayTest.php +++ b/tests/UnitedKingdom/England/SummerBankHolidayTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\UnitedKingdom\England; -use DateTime; -use DateTimeZone; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -51,7 +49,7 @@ public function testHoliday(): void self::REGION, self::HOLIDAY, $year, - new DateTime("last monday of august $year", new DateTimeZone(self::TIMEZONE)) + new \DateTime("last monday of august $year", new \DateTimeZone(self::TIMEZONE)) ); } @@ -67,7 +65,7 @@ public function testHolidayBefore1965(): void self::REGION, self::HOLIDAY, $year, - new DateTime("first monday of august $year", new DateTimeZone(self::TIMEZONE)) + new \DateTime("first monday of august $year", new \DateTimeZone(self::TIMEZONE)) ); } @@ -82,37 +80,37 @@ public function testHolidayTrialPeriod(): void self::REGION, self::HOLIDAY, 1965, - new DateTime('1965-8-30', new DateTimeZone(self::TIMEZONE)) + new \DateTime('1965-8-30', new \DateTimeZone(self::TIMEZONE)) ); $this->assertHoliday( self::REGION, self::HOLIDAY, 1966, - new DateTime('1966-8-29', new DateTimeZone(self::TIMEZONE)) + new \DateTime('1966-8-29', new \DateTimeZone(self::TIMEZONE)) ); $this->assertHoliday( self::REGION, self::HOLIDAY, 1967, - new DateTime('1967-8-28', new DateTimeZone(self::TIMEZONE)) + new \DateTime('1967-8-28', new \DateTimeZone(self::TIMEZONE)) ); $this->assertHoliday( self::REGION, self::HOLIDAY, 1968, - new DateTime('1968-9-2', new DateTimeZone(self::TIMEZONE)) + new \DateTime('1968-9-2', new \DateTimeZone(self::TIMEZONE)) ); $this->assertHoliday( self::REGION, self::HOLIDAY, 1969, - new DateTime('1969-9-1', new DateTimeZone(self::TIMEZONE)) + new \DateTime('1969-9-1', new \DateTimeZone(self::TIMEZONE)) ); $this->assertHoliday( self::REGION, self::HOLIDAY, 1970, - new DateTime('1970-8-31', new DateTimeZone(self::TIMEZONE)) + new \DateTime('1970-8-31', new \DateTimeZone(self::TIMEZONE)) ); } diff --git a/tests/UnitedKingdom/GoodFridayTest.php b/tests/UnitedKingdom/GoodFridayTest.php index e1b6c2d66..52d9f9ec7 100644 --- a/tests/UnitedKingdom/GoodFridayTest.php +++ b/tests/UnitedKingdom/GoodFridayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\UnitedKingdom; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -33,7 +30,7 @@ class GoodFridayTest extends UnitedKingdomBaseTestCase implements HolidayTestCas /** * Tests the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHoliday(): void { @@ -42,14 +39,14 @@ public function testHoliday(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-3-30", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-3-30", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -64,7 +61,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/UnitedKingdom/MayDayBankHolidayTest.php b/tests/UnitedKingdom/MayDayBankHolidayTest.php index dd444a56d..7d6daf580 100644 --- a/tests/UnitedKingdom/MayDayBankHolidayTest.php +++ b/tests/UnitedKingdom/MayDayBankHolidayTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\UnitedKingdom; -use DateTime; -use DateTimeZone; use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -38,7 +36,7 @@ class MayDayBankHolidayTest extends UnitedKingdomBaseTestCase implements Holiday /** * Tests the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHoliday(): void { @@ -47,14 +45,14 @@ public function testHoliday(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-5-2", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-5-2", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests the holiday exception in 1995 and 2020. * - * @throws Exception + * @throws \Exception */ public function testHolidayExceptions(): void { @@ -62,21 +60,21 @@ public function testHolidayExceptions(): void self::REGION, self::HOLIDAY, 1995, - new DateTime('1995-5-8', new DateTimeZone(self::TIMEZONE)) + new \DateTime('1995-5-8', new \DateTimeZone(self::TIMEZONE)) ); $this->assertHoliday( self::REGION, self::HOLIDAY, 2020, - new DateTime('2020-5-8', new DateTimeZone(self::TIMEZONE)) + new \DateTime('2020-5-8', new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests the holiday defined in this test before establishment. * - * @throws Exception + * @throws \Exception */ public function testHolidayBeforeEstablishment(): void { @@ -90,7 +88,7 @@ public function testHolidayBeforeEstablishment(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -105,7 +103,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/UnitedKingdom/MotheringSundayTest.php b/tests/UnitedKingdom/MotheringSundayTest.php index 75db801ba..4accacac8 100644 --- a/tests/UnitedKingdom/MotheringSundayTest.php +++ b/tests/UnitedKingdom/MotheringSundayTest.php @@ -15,10 +15,6 @@ namespace Yasumi\tests\UnitedKingdom; -use DateInterval; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; use Yasumi\tests\UnitedKingdom\England\EnglandBaseTestCase; @@ -30,7 +26,7 @@ class MotheringSundayTest extends EnglandBaseTestCase implements HolidayTestCase /** * @dataProvider HolidayDataProvider * - * @throws Exception + * @throws \Exception */ public function testHoliday(int $year, string $expected): void { @@ -38,14 +34,14 @@ public function testHoliday(int $year, string $expected): void self::REGION, self::HOLIDAY, $year, - new DateTime($expected, new DateTimeZone(self::TIMEZONE)) + new \DateTime($expected, new \DateTimeZone(self::TIMEZONE)) ); } /** * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function HolidayDataProvider(): array { @@ -54,7 +50,7 @@ public function HolidayDataProvider(): array for ($y = 0; $y < 50; ++$y) { $year = $this->generateRandomYear(); $date = $this->calculateEaster($year, self::TIMEZONE); - $date->sub(new DateInterval('P3W')); + $date->sub(new \DateInterval('P3W')); $data[] = [$year, $date->format('Y-m-d')]; } @@ -67,7 +63,7 @@ public function HolidayDataProvider(): array } /** - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -80,7 +76,7 @@ public function testTranslation(): void } /** - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/UnitedKingdom/NewYearsDayTest.php b/tests/UnitedKingdom/NewYearsDayTest.php index 322de63bd..c7ae78b7a 100644 --- a/tests/UnitedKingdom/NewYearsDayTest.php +++ b/tests/UnitedKingdom/NewYearsDayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\UnitedKingdom; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -48,7 +45,7 @@ class NewYearsDayTest extends UnitedKingdomBaseTestCase implements HolidayTestCa * @param int $year the year for which the holiday defined in this test needs to be tested * @param string $expected the expected date * - * @throws Exception + * @throws \Exception */ public function testHolidayOnAfterEstablishment(int $year, string $expected): void { @@ -56,14 +53,14 @@ public function testHolidayOnAfterEstablishment(int $year, string $expected): vo self::REGION, self::HOLIDAY, $year, - new DateTime($expected, new DateTimeZone(self::TIMEZONE)) + new \DateTime($expected, new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests the holiday defined in this test before establishment. * - * @throws Exception + * @throws \Exception */ public function testHolidayBeforeEstablishment(): void { @@ -77,7 +74,7 @@ public function testHolidayBeforeEstablishment(): void /** * Tests that the holiday defined in this test is of the type 'observance' before the year it was changed. * - * @throws Exception + * @throws \Exception */ public function testHolidayIsObservedTypeBeforeChange(): void { @@ -94,7 +91,7 @@ public function testHolidayIsObservedTypeBeforeChange(): void * * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function HolidayDataProvider(): array { @@ -104,7 +101,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -119,7 +116,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/UnitedKingdom/NorthernIreland/BattleOfTheBoyneTest.php b/tests/UnitedKingdom/NorthernIreland/BattleOfTheBoyneTest.php index 6e7ebb871..38cd5db52 100644 --- a/tests/UnitedKingdom/NorthernIreland/BattleOfTheBoyneTest.php +++ b/tests/UnitedKingdom/NorthernIreland/BattleOfTheBoyneTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\UnitedKingdom\NorthernIreland; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -43,11 +40,11 @@ class BattleOfTheBoyneTest extends NorthernIrelandBaseTestCase implements Holida * @param int $year the year for which the holiday defined in this test needs to be tested * @param string $expected the expected date * - * @throws Exception + * @throws \Exception */ public function testHoliday(int $year, string $expected): void { - $date = new DateTime($expected, new DateTimeZone(self::TIMEZONE)); + $date = new \DateTime($expected, new \DateTimeZone(self::TIMEZONE)); $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $date); if (\in_array((int) $date->format('w'), [0, 6], true)) { @@ -59,7 +56,7 @@ public function testHoliday(int $year, string $expected): void /** * Tests the holiday defined in this test before establishment. * - * @throws Exception + * @throws \Exception */ public function testHolidayBeforeEstablishment(): void { @@ -75,7 +72,7 @@ public function testHolidayBeforeEstablishment(): void * * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function HolidayDataProvider(): array { @@ -83,7 +80,7 @@ public function HolidayDataProvider(): array for ($y = 0; $y < self::TEST_ITERATIONS; ++$y) { $year = $this->generateRandomYear(self::ESTABLISHMENT_YEAR); - $date = new DateTime("$year-7-12", new DateTimeZone(self::TIMEZONE)); + $date = new \DateTime("$year-7-12", new \DateTimeZone(self::TIMEZONE)); $data[] = [$year, $date->format('Y-m-d')]; } @@ -93,7 +90,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -108,7 +105,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/UnitedKingdom/NorthernIreland/BoxingDayTest.php b/tests/UnitedKingdom/NorthernIreland/BoxingDayTest.php index c878a95c9..ff9076939 100644 --- a/tests/UnitedKingdom/NorthernIreland/BoxingDayTest.php +++ b/tests/UnitedKingdom/NorthernIreland/BoxingDayTest.php @@ -14,10 +14,6 @@ namespace Yasumi\tests\UnitedKingdom\NorthernIreland; -use DateInterval; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -39,15 +35,15 @@ class BoxingDayTest extends NorthernIrelandBaseTestCase implements HolidayTestCa * @param int $year the year for which the holiday defined in this test needs to be tested * @param string $expected the expected date * - * @throws Exception + * @throws \Exception */ public function testHoliday(int $year, string $expected): void { - $date = new DateTime($expected, new DateTimeZone(self::TIMEZONE)); + $date = new \DateTime($expected, new \DateTimeZone(self::TIMEZONE)); $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $date); if (\in_array((int) $date->format('w'), [0, 6], true)) { - $date->add(new DateInterval('P2D')); + $date->add(new \DateInterval('P2D')); $this->assertHoliday(self::REGION, 'substituteHoliday:'.self::HOLIDAY, $year, $date); $this->assertHolidayType(self::REGION, 'substituteHoliday:'.self::HOLIDAY, $year, Holiday::TYPE_BANK); } @@ -58,7 +54,7 @@ public function testHoliday(int $year, string $expected): void * * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function HolidayDataProvider(): array { @@ -66,7 +62,7 @@ public function HolidayDataProvider(): array for ($y = 0; $y < self::TEST_ITERATIONS; ++$y) { $year = $this->generateRandomYear(); - $date = new DateTime("$year-12-26", new DateTimeZone(self::TIMEZONE)); + $date = new \DateTime("$year-12-26", new \DateTimeZone(self::TIMEZONE)); $data[] = [$year, $date->format('Y-m-d')]; } @@ -77,7 +73,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -92,7 +88,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/UnitedKingdom/NorthernIreland/ChristmasDayTest.php b/tests/UnitedKingdom/NorthernIreland/ChristmasDayTest.php index d850fdff8..3556f1697 100644 --- a/tests/UnitedKingdom/NorthernIreland/ChristmasDayTest.php +++ b/tests/UnitedKingdom/NorthernIreland/ChristmasDayTest.php @@ -14,10 +14,6 @@ namespace Yasumi\tests\UnitedKingdom\NorthernIreland; -use DateInterval; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -39,15 +35,15 @@ class ChristmasDayTest extends NorthernIrelandBaseTestCase implements HolidayTes * @param int $year the year for which the holiday defined in this test needs to be tested * @param string $expected the expected date * - * @throws Exception + * @throws \Exception */ public function testHoliday(int $year, string $expected): void { - $date = new DateTime($expected, new DateTimeZone(self::TIMEZONE)); + $date = new \DateTime($expected, new \DateTimeZone(self::TIMEZONE)); $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $date); if (\in_array((int) $date->format('w'), [0, 6], true)) { - $date->add(new DateInterval('P2D')); + $date->add(new \DateInterval('P2D')); $this->assertHoliday(self::REGION, 'substituteHoliday:'.self::HOLIDAY, $year, $date); $this->assertHolidayType(self::REGION, 'substituteHoliday:'.self::HOLIDAY, $year, Holiday::TYPE_BANK); } @@ -58,7 +54,7 @@ public function testHoliday(int $year, string $expected): void * * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function HolidayDataProvider(): array { @@ -66,7 +62,7 @@ public function HolidayDataProvider(): array for ($y = 0; $y < self::TEST_ITERATIONS; ++$y) { $year = $this->generateRandomYear(); - $date = new DateTime("$year-12-25", new DateTimeZone(self::TIMEZONE)); + $date = new \DateTime("$year-12-25", new \DateTimeZone(self::TIMEZONE)); $data[] = [$year, $date->format('Y-m-d')]; } @@ -77,7 +73,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -92,7 +88,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/UnitedKingdom/NorthernIreland/EasterMondayTest.php b/tests/UnitedKingdom/NorthernIreland/EasterMondayTest.php index 6b507e5b7..8ada41f3c 100644 --- a/tests/UnitedKingdom/NorthernIreland/EasterMondayTest.php +++ b/tests/UnitedKingdom/NorthernIreland/EasterMondayTest.php @@ -14,10 +14,6 @@ namespace Yasumi\tests\UnitedKingdom\NorthernIreland; -use DateInterval; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -39,7 +35,7 @@ class EasterMondayTest extends NorthernIrelandBaseTestCase implements HolidayTes * @param int $year the year for which the holiday defined in this test needs to be tested * @param string $expected the expected date * - * @throws Exception + * @throws \Exception */ public function testHoliday(int $year, string $expected): void { @@ -47,7 +43,7 @@ public function testHoliday(int $year, string $expected): void self::REGION, self::HOLIDAY, $year, - new DateTime($expected, new DateTimeZone(self::TIMEZONE)) + new \DateTime($expected, new \DateTimeZone(self::TIMEZONE)) ); } @@ -56,7 +52,7 @@ public function testHoliday(int $year, string $expected): void * * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function HolidayDataProvider(): array { @@ -65,7 +61,7 @@ public function HolidayDataProvider(): array for ($y = 0; $y < 50; ++$y) { $year = $this->generateRandomYear(); $date = $this->calculateEaster($year, self::TIMEZONE); - $date->add(new DateInterval('P1D')); + $date->add(new \DateInterval('P1D')); $data[] = [$year, $date->format('Y-m-d')]; } @@ -76,7 +72,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -91,7 +87,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/UnitedKingdom/NorthernIreland/GoodFridayTest.php b/tests/UnitedKingdom/NorthernIreland/GoodFridayTest.php index 48a9a20d2..26c707b3c 100644 --- a/tests/UnitedKingdom/NorthernIreland/GoodFridayTest.php +++ b/tests/UnitedKingdom/NorthernIreland/GoodFridayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\UnitedKingdom\NorthernIreland; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -33,7 +30,7 @@ class GoodFridayTest extends NorthernIrelandBaseTestCase implements HolidayTestC /** * Tests the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHoliday(): void { @@ -42,14 +39,14 @@ public function testHoliday(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-3-30", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-3-30", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -64,7 +61,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/UnitedKingdom/NorthernIreland/MayDayBankHolidayTest.php b/tests/UnitedKingdom/NorthernIreland/MayDayBankHolidayTest.php index d8005ad3d..bea891732 100644 --- a/tests/UnitedKingdom/NorthernIreland/MayDayBankHolidayTest.php +++ b/tests/UnitedKingdom/NorthernIreland/MayDayBankHolidayTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\UnitedKingdom\NorthernIreland; -use DateTime; -use DateTimeZone; use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -38,7 +36,7 @@ class MayDayBankHolidayTest extends NorthernIrelandBaseTestCase implements Holid /** * Tests the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHoliday(): void { @@ -47,14 +45,14 @@ public function testHoliday(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-5-2", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-5-2", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests the holiday exception in 1995 and 2020. * - * @throws Exception + * @throws \Exception */ public function testHolidayExceptions(): void { @@ -62,21 +60,21 @@ public function testHolidayExceptions(): void self::REGION, self::HOLIDAY, 1995, - new DateTime('1995-5-8', new DateTimeZone(self::TIMEZONE)) + new \DateTime('1995-5-8', new \DateTimeZone(self::TIMEZONE)) ); $this->assertHoliday( self::REGION, self::HOLIDAY, 2020, - new DateTime('2020-5-8', new DateTimeZone(self::TIMEZONE)) + new \DateTime('2020-5-8', new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests the holiday defined in this test before establishment. * - * @throws Exception + * @throws \Exception */ public function testHolidayBeforeEstablishment(): void { @@ -90,7 +88,7 @@ public function testHolidayBeforeEstablishment(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -105,7 +103,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/UnitedKingdom/NorthernIreland/NewYearsDayTest.php b/tests/UnitedKingdom/NorthernIreland/NewYearsDayTest.php index 3e2bae4c5..ec5e44341 100644 --- a/tests/UnitedKingdom/NorthernIreland/NewYearsDayTest.php +++ b/tests/UnitedKingdom/NorthernIreland/NewYearsDayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\UnitedKingdom\NorthernIreland; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -48,7 +45,7 @@ class NewYearsDayTest extends NorthernIrelandBaseTestCase implements HolidayTest * @param int $year the year for which the holiday defined in this test needs to be tested * @param string $expected the expected date * - * @throws Exception + * @throws \Exception */ public function testHolidayOnAfterEstablishment(int $year, string $expected): void { @@ -56,14 +53,14 @@ public function testHolidayOnAfterEstablishment(int $year, string $expected): vo self::REGION, self::HOLIDAY, $year, - new DateTime($expected, new DateTimeZone(self::TIMEZONE)) + new \DateTime($expected, new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests the holiday defined in this test before establishment. * - * @throws Exception + * @throws \Exception */ public function testHolidayBeforeEstablishment(): void { @@ -77,7 +74,7 @@ public function testHolidayBeforeEstablishment(): void /** * Tests that the holiday defined in this test is of the type 'observance' before the year it was changed. * - * @throws Exception + * @throws \Exception */ public function testHolidayIsObservedTypeBeforeChange(): void { @@ -94,7 +91,7 @@ public function testHolidayIsObservedTypeBeforeChange(): void * * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function HolidayDataProvider(): array { @@ -104,7 +101,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -119,7 +116,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/UnitedKingdom/NorthernIreland/NorthernIrelandTest.php b/tests/UnitedKingdom/NorthernIreland/NorthernIrelandTest.php index 44bb4fd1a..9a95c8bec 100644 --- a/tests/UnitedKingdom/NorthernIreland/NorthernIrelandTest.php +++ b/tests/UnitedKingdom/NorthernIreland/NorthernIrelandTest.php @@ -14,7 +14,6 @@ namespace Yasumi\tests\UnitedKingdom\NorthernIreland; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\ProviderTestCase; @@ -109,7 +108,7 @@ public function testOtherHolidays(): void } /** - * @throws ReflectionException + * @throws \ReflectionException * @throws \Exception */ public function testSources(): void diff --git a/tests/UnitedKingdom/NorthernIreland/SpringBankHolidayTest.php b/tests/UnitedKingdom/NorthernIreland/SpringBankHolidayTest.php index 1e52e9d81..e2c6487e3 100644 --- a/tests/UnitedKingdom/NorthernIreland/SpringBankHolidayTest.php +++ b/tests/UnitedKingdom/NorthernIreland/SpringBankHolidayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\UnitedKingdom\NorthernIreland; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -38,7 +35,7 @@ class SpringBankHolidayTest extends NorthernIrelandBaseTestCase implements Holid /** * Tests the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHoliday(): void { @@ -47,14 +44,14 @@ public function testHoliday(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-5-30", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-5-30", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests the holiday defined in this test before establishment. * - * @throws Exception + * @throws \Exception */ public function testHolidayBeforeEstablishment(): void { @@ -68,7 +65,7 @@ public function testHolidayBeforeEstablishment(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -83,7 +80,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/UnitedKingdom/NorthernIreland/StPatricksDayTest.php b/tests/UnitedKingdom/NorthernIreland/StPatricksDayTest.php index c104f7a83..7e2bc5f4a 100644 --- a/tests/UnitedKingdom/NorthernIreland/StPatricksDayTest.php +++ b/tests/UnitedKingdom/NorthernIreland/StPatricksDayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\UnitedKingdom\NorthernIreland; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -43,11 +40,11 @@ class StPatricksDayTest extends NorthernIrelandBaseTestCase implements HolidayTe * @param int $year the year for which the holiday defined in this test needs to be tested * @param string $expected the expected date * - * @throws Exception + * @throws \Exception */ public function testHoliday(int $year, string $expected): void { - $date = new DateTime($expected, new DateTimeZone(self::TIMEZONE)); + $date = new \DateTime($expected, new \DateTimeZone(self::TIMEZONE)); $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $date); if (\in_array((int) $date->format('w'), [0, 6], true)) { @@ -59,7 +56,7 @@ public function testHoliday(int $year, string $expected): void /** * Tests the holiday defined in this test before establishment. * - * @throws Exception + * @throws \Exception */ public function testHolidayBeforeEstablishment(): void { @@ -75,7 +72,7 @@ public function testHolidayBeforeEstablishment(): void * * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function HolidayDataProvider(): array { @@ -83,7 +80,7 @@ public function HolidayDataProvider(): array for ($y = 0; $y < self::TEST_ITERATIONS; ++$y) { $year = $this->generateRandomYear(self::ESTABLISHMENT_YEAR); - $date = new DateTime("$year-3-17", new DateTimeZone(self::TIMEZONE)); + $date = new \DateTime("$year-3-17", new \DateTimeZone(self::TIMEZONE)); $data[] = [$year, $date->format('Y-m-d')]; } @@ -93,7 +90,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -108,7 +105,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/UnitedKingdom/NorthernIreland/SummerBankHolidayTest.php b/tests/UnitedKingdom/NorthernIreland/SummerBankHolidayTest.php index 7528be410..0f7dbf747 100644 --- a/tests/UnitedKingdom/NorthernIreland/SummerBankHolidayTest.php +++ b/tests/UnitedKingdom/NorthernIreland/SummerBankHolidayTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\UnitedKingdom\NorthernIreland; -use DateTime; -use DateTimeZone; use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -43,7 +41,7 @@ class SummerBankHolidayTest extends NorthernIrelandBaseTestCase implements Holid /** * Tests the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHoliday(): void { @@ -52,14 +50,14 @@ public function testHoliday(): void self::REGION, self::HOLIDAY, $year, - new DateTime("last monday of august $year", new DateTimeZone(self::TIMEZONE)) + new \DateTime("last monday of august $year", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests the holiday exception in 2020. * - * @throws Exception + * @throws \Exception */ public function testHolidayBefore1965(): void { @@ -68,14 +66,14 @@ public function testHolidayBefore1965(): void self::REGION, self::HOLIDAY, $year, - new DateTime("first monday of august $year", new DateTimeZone(self::TIMEZONE)) + new \DateTime("first monday of august $year", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests the holiday during trial period in 1965-1970. * - * @throws Exception + * @throws \Exception */ public function testHolidayTrialPeriod(): void { @@ -83,44 +81,44 @@ public function testHolidayTrialPeriod(): void self::REGION, self::HOLIDAY, 1965, - new DateTime('1965-8-30', new DateTimeZone(self::TIMEZONE)) + new \DateTime('1965-8-30', new \DateTimeZone(self::TIMEZONE)) ); $this->assertHoliday( self::REGION, self::HOLIDAY, 1966, - new DateTime('1966-8-29', new DateTimeZone(self::TIMEZONE)) + new \DateTime('1966-8-29', new \DateTimeZone(self::TIMEZONE)) ); $this->assertHoliday( self::REGION, self::HOLIDAY, 1967, - new DateTime('1967-8-28', new DateTimeZone(self::TIMEZONE)) + new \DateTime('1967-8-28', new \DateTimeZone(self::TIMEZONE)) ); $this->assertHoliday( self::REGION, self::HOLIDAY, 1968, - new DateTime('1968-9-2', new DateTimeZone(self::TIMEZONE)) + new \DateTime('1968-9-2', new \DateTimeZone(self::TIMEZONE)) ); $this->assertHoliday( self::REGION, self::HOLIDAY, 1969, - new DateTime('1969-9-1', new DateTimeZone(self::TIMEZONE)) + new \DateTime('1969-9-1', new \DateTimeZone(self::TIMEZONE)) ); $this->assertHoliday( self::REGION, self::HOLIDAY, 1970, - new DateTime('1970-8-31', new DateTimeZone(self::TIMEZONE)) + new \DateTime('1970-8-31', new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests the holiday defined in this test before establishment. * - * @throws Exception + * @throws \Exception */ public function testHolidayBeforeEstablishment(): void { @@ -134,7 +132,7 @@ public function testHolidayBeforeEstablishment(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -149,7 +147,7 @@ public function testTranslation(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslationBeforeRename(): void { @@ -164,7 +162,7 @@ public function testTranslationBeforeRename(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/UnitedKingdom/PlatinumJubileeBankHolidayTest.php b/tests/UnitedKingdom/PlatinumJubileeBankHolidayTest.php index 2dd9bbbb7..9d744e46c 100644 --- a/tests/UnitedKingdom/PlatinumJubileeBankHolidayTest.php +++ b/tests/UnitedKingdom/PlatinumJubileeBankHolidayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\UnitedKingdom; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -43,7 +40,7 @@ class PlatinumJubileeBankHolidayTest extends UnitedKingdomBaseTestCase implement /** * Tests the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHoliday(): void { @@ -51,14 +48,14 @@ public function testHoliday(): void self::REGION, self::HOLIDAY, self::ACTIVE_YEAR, - new DateTime(self::ACTIVE_DATE, new DateTimeZone(self::TIMEZONE)) + new \DateTime(self::ACTIVE_DATE, new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests the holiday defined in this test before the year in which it occurred. * - * @throws Exception + * @throws \Exception */ public function testHolidayBeforeActive(): void { @@ -72,7 +69,7 @@ public function testHolidayBeforeActive(): void /** * Tests the holiday defined in this test after the year in which it occurred. * - * @throws Exception + * @throws \Exception */ public function testHolidayAfterActive(): void { diff --git a/tests/UnitedKingdom/QueenElizabethFuneralBankHolidayTest.php b/tests/UnitedKingdom/QueenElizabethFuneralBankHolidayTest.php index 7feb30bad..ebfcc8248 100644 --- a/tests/UnitedKingdom/QueenElizabethFuneralBankHolidayTest.php +++ b/tests/UnitedKingdom/QueenElizabethFuneralBankHolidayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\UnitedKingdom; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -43,7 +40,7 @@ class QueenElizabethFuneralBankHolidayTest extends UnitedKingdomBaseTestCase imp /** * Tests the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHoliday(): void { @@ -51,14 +48,14 @@ public function testHoliday(): void self::REGION, self::HOLIDAY, self::ACTIVE_YEAR, - new DateTime(self::ACTIVE_DATE, new DateTimeZone(self::TIMEZONE)) + new \DateTime(self::ACTIVE_DATE, new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests the holiday defined in this test before the year in which it occurred. * - * @throws Exception + * @throws \Exception */ public function testHolidayBeforeActive(): void { @@ -72,7 +69,7 @@ public function testHolidayBeforeActive(): void /** * Tests the holiday defined in this test after the year in which it occurred. * - * @throws Exception + * @throws \Exception */ public function testHolidayAfterActive(): void { diff --git a/tests/UnitedKingdom/Scotland/BoxingDayTest.php b/tests/UnitedKingdom/Scotland/BoxingDayTest.php index bc70ff8f2..44061c7e8 100644 --- a/tests/UnitedKingdom/Scotland/BoxingDayTest.php +++ b/tests/UnitedKingdom/Scotland/BoxingDayTest.php @@ -14,10 +14,6 @@ namespace Yasumi\tests\UnitedKingdom\Scotland; -use DateInterval; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -39,15 +35,15 @@ class BoxingDayTest extends ScotlandBaseTestCase implements HolidayTestCase * @param int $year the year for which the holiday defined in this test needs to be tested * @param string $expected the expected date * - * @throws Exception + * @throws \Exception */ public function testHoliday(int $year, string $expected): void { - $date = new DateTime($expected, new DateTimeZone(self::TIMEZONE)); + $date = new \DateTime($expected, new \DateTimeZone(self::TIMEZONE)); $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $date); if (\in_array((int) $date->format('w'), [0, 6], true)) { - $date->add(new DateInterval('P2D')); + $date->add(new \DateInterval('P2D')); $this->assertHoliday(self::REGION, 'substituteHoliday:'.self::HOLIDAY, $year, $date); $this->assertHolidayType(self::REGION, 'substituteHoliday:'.self::HOLIDAY, $year, Holiday::TYPE_BANK); } @@ -58,7 +54,7 @@ public function testHoliday(int $year, string $expected): void * * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function HolidayDataProvider(): array { @@ -66,7 +62,7 @@ public function HolidayDataProvider(): array for ($y = 0; $y < self::TEST_ITERATIONS; ++$y) { $year = $this->generateRandomYear(); - $date = new DateTime("$year-12-26", new DateTimeZone(self::TIMEZONE)); + $date = new \DateTime("$year-12-26", new \DateTimeZone(self::TIMEZONE)); $data[] = [$year, $date->format('Y-m-d')]; } @@ -77,7 +73,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -92,7 +88,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/UnitedKingdom/Scotland/ChristmasDayTest.php b/tests/UnitedKingdom/Scotland/ChristmasDayTest.php index 2b74cac48..c40282f28 100644 --- a/tests/UnitedKingdom/Scotland/ChristmasDayTest.php +++ b/tests/UnitedKingdom/Scotland/ChristmasDayTest.php @@ -14,10 +14,6 @@ namespace Yasumi\tests\UnitedKingdom\Scotland; -use DateInterval; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -39,15 +35,15 @@ class ChristmasDayTest extends ScotlandBaseTestCase implements HolidayTestCase * @param int $year the year for which the holiday defined in this test needs to be tested * @param string $expected the expected date * - * @throws Exception + * @throws \Exception */ public function testHoliday(int $year, string $expected): void { - $date = new DateTime($expected, new DateTimeZone(self::TIMEZONE)); + $date = new \DateTime($expected, new \DateTimeZone(self::TIMEZONE)); $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $date); if (\in_array((int) $date->format('w'), [0, 6], true)) { - $date->add(new DateInterval('P2D')); + $date->add(new \DateInterval('P2D')); $this->assertHoliday(self::REGION, 'substituteHoliday:'.self::HOLIDAY, $year, $date); $this->assertHolidayType(self::REGION, 'substituteHoliday:'.self::HOLIDAY, $year, Holiday::TYPE_BANK); } @@ -58,7 +54,7 @@ public function testHoliday(int $year, string $expected): void * * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function HolidayDataProvider(): array { @@ -66,7 +62,7 @@ public function HolidayDataProvider(): array for ($y = 0; $y < self::TEST_ITERATIONS; ++$y) { $year = $this->generateRandomYear(); - $date = new DateTime("$year-12-25", new DateTimeZone(self::TIMEZONE)); + $date = new \DateTime("$year-12-25", new \DateTimeZone(self::TIMEZONE)); $data[] = [$year, $date->format('Y-m-d')]; } @@ -77,7 +73,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -92,7 +88,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/UnitedKingdom/Scotland/GoodFridayTest.php b/tests/UnitedKingdom/Scotland/GoodFridayTest.php index af9c34112..08b7f4a6e 100644 --- a/tests/UnitedKingdom/Scotland/GoodFridayTest.php +++ b/tests/UnitedKingdom/Scotland/GoodFridayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\UnitedKingdom\Scotland; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -33,7 +30,7 @@ class GoodFridayTest extends ScotlandBaseTestCase implements HolidayTestCase /** * Tests the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHoliday(): void { @@ -42,14 +39,14 @@ public function testHoliday(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-3-30", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-3-30", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -64,7 +61,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/UnitedKingdom/Scotland/MayDayBankHolidayTest.php b/tests/UnitedKingdom/Scotland/MayDayBankHolidayTest.php index 6b58ed22d..69f2e5b94 100644 --- a/tests/UnitedKingdom/Scotland/MayDayBankHolidayTest.php +++ b/tests/UnitedKingdom/Scotland/MayDayBankHolidayTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\UnitedKingdom\Scotland; -use DateTime; -use DateTimeZone; use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -38,7 +36,7 @@ class MayDayBankHolidayTest extends ScotlandBaseTestCase implements HolidayTestC /** * Tests the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHoliday(): void { @@ -47,14 +45,14 @@ public function testHoliday(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-5-2", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-5-2", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests the holiday exception in 1995 and 2020. * - * @throws Exception + * @throws \Exception */ public function testHolidayExceptions(): void { @@ -62,21 +60,21 @@ public function testHolidayExceptions(): void self::REGION, self::HOLIDAY, 1995, - new DateTime('1995-5-8', new DateTimeZone(self::TIMEZONE)) + new \DateTime('1995-5-8', new \DateTimeZone(self::TIMEZONE)) ); $this->assertHoliday( self::REGION, self::HOLIDAY, 2020, - new DateTime('2020-5-8', new DateTimeZone(self::TIMEZONE)) + new \DateTime('2020-5-8', new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests the holiday defined in this test before establishment. * - * @throws Exception + * @throws \Exception */ public function testHolidayBeforeEstablishment(): void { @@ -90,7 +88,7 @@ public function testHolidayBeforeEstablishment(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -105,7 +103,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/UnitedKingdom/Scotland/NewYearsDayTest.php b/tests/UnitedKingdom/Scotland/NewYearsDayTest.php index 275e382f1..fe3c07370 100644 --- a/tests/UnitedKingdom/Scotland/NewYearsDayTest.php +++ b/tests/UnitedKingdom/Scotland/NewYearsDayTest.php @@ -14,10 +14,6 @@ namespace Yasumi\tests\UnitedKingdom\Scotland; -use DateInterval; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -49,15 +45,15 @@ class NewYearsDayTest extends ScotlandBaseTestCase implements HolidayTestCase * @param int $year the year for which the holiday defined in this test needs to be tested * @param string $expected the expected date * - * @throws Exception + * @throws \Exception */ public function testHolidayOnAfterEstablishment(int $year, string $expected): void { - $date = new DateTime($expected, new DateTimeZone(self::TIMEZONE)); + $date = new \DateTime($expected, new \DateTimeZone(self::TIMEZONE)); $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $date); if (\in_array((int) $date->format('w'), [0, 6], true)) { - $date->add(new DateInterval('P2D')); + $date->add(new \DateInterval('P2D')); $this->assertHoliday(self::REGION, 'substituteHoliday:'.self::HOLIDAY, $year, $date); } } @@ -65,7 +61,7 @@ public function testHolidayOnAfterEstablishment(int $year, string $expected): vo /** * Tests the holiday defined in this test before establishment. * - * @throws Exception + * @throws \Exception */ public function testHolidayBeforeEstablishment(): void { @@ -79,7 +75,7 @@ public function testHolidayBeforeEstablishment(): void /** * Tests that the holiday defined in this test is of the type 'observance' before the year it was changed. * - * @throws Exception + * @throws \Exception */ public function testHolidayIsObservedTypeBeforeChange(): void { @@ -96,7 +92,7 @@ public function testHolidayIsObservedTypeBeforeChange(): void * * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function HolidayDataProvider(): array { @@ -104,7 +100,7 @@ public function HolidayDataProvider(): array for ($y = 0; $y < self::TEST_ITERATIONS; ++$y) { $year = $this->generateRandomYear(self::ESTABLISHMENT_YEAR); - $date = new DateTime("$year-1-1", new DateTimeZone(self::TIMEZONE)); + $date = new \DateTime("$year-1-1", new \DateTimeZone(self::TIMEZONE)); $data[] = [$year, $date->format('Y-m-d')]; } @@ -114,7 +110,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -129,7 +125,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/UnitedKingdom/Scotland/ScotlandTest.php b/tests/UnitedKingdom/Scotland/ScotlandTest.php index 388c99661..71216ec38 100644 --- a/tests/UnitedKingdom/Scotland/ScotlandTest.php +++ b/tests/UnitedKingdom/Scotland/ScotlandTest.php @@ -14,7 +14,6 @@ namespace Yasumi\tests\UnitedKingdom\Scotland; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\ProviderTestCase; @@ -104,7 +103,7 @@ public function testOtherHolidays(): void } /** - * @throws ReflectionException + * @throws \ReflectionException * @throws \Exception */ public function testSources(): void diff --git a/tests/UnitedKingdom/Scotland/SecondNewYearsDayTest.php b/tests/UnitedKingdom/Scotland/SecondNewYearsDayTest.php index 9abfc0a8d..4597e6cad 100644 --- a/tests/UnitedKingdom/Scotland/SecondNewYearsDayTest.php +++ b/tests/UnitedKingdom/Scotland/SecondNewYearsDayTest.php @@ -14,10 +14,6 @@ namespace Yasumi\tests\UnitedKingdom\Scotland; -use DateInterval; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -49,15 +45,15 @@ class SecondNewYearsDayTest extends ScotlandBaseTestCase implements HolidayTestC * @param int $year the year for which the holiday defined in this test needs to be tested * @param string $expected the expected date * - * @throws Exception + * @throws \Exception */ public function testHolidayOnAfterEstablishment(int $year, string $expected): void { - $date = new DateTime($expected, new DateTimeZone(self::TIMEZONE)); + $date = new \DateTime($expected, new \DateTimeZone(self::TIMEZONE)); $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $date); if (\in_array((int) $date->format('w'), [0, 6], true)) { - $date->add(new DateInterval('P2D')); + $date->add(new \DateInterval('P2D')); $this->assertHoliday(self::REGION, 'substituteHoliday:'.self::HOLIDAY, $year, $date); } } @@ -65,7 +61,7 @@ public function testHolidayOnAfterEstablishment(int $year, string $expected): vo /** * Tests the holiday defined in this test before establishment. * - * @throws Exception + * @throws \Exception */ public function testHolidayBeforeEstablishment(): void { @@ -79,7 +75,7 @@ public function testHolidayBeforeEstablishment(): void /** * Tests that the holiday defined in this test is of the type 'observance' before the year it was changed. * - * @throws Exception + * @throws \Exception */ public function testHolidayIsObservedTypeBeforeChange(): void { @@ -96,7 +92,7 @@ public function testHolidayIsObservedTypeBeforeChange(): void * * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function HolidayDataProvider(): array { @@ -104,7 +100,7 @@ public function HolidayDataProvider(): array for ($y = 0; $y < self::TEST_ITERATIONS; ++$y) { $year = $this->generateRandomYear(self::ESTABLISHMENT_YEAR); - $date = new DateTime("$year-1-2", new DateTimeZone(self::TIMEZONE)); + $date = new \DateTime("$year-1-2", new \DateTimeZone(self::TIMEZONE)); $data[] = [$year, $date->format('Y-m-d')]; } @@ -114,7 +110,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -129,7 +125,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/UnitedKingdom/Scotland/SpringBankHolidayTest.php b/tests/UnitedKingdom/Scotland/SpringBankHolidayTest.php index 4c3a26747..2891cf972 100644 --- a/tests/UnitedKingdom/Scotland/SpringBankHolidayTest.php +++ b/tests/UnitedKingdom/Scotland/SpringBankHolidayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\UnitedKingdom\Scotland; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -38,7 +35,7 @@ class SpringBankHolidayTest extends ScotlandBaseTestCase implements HolidayTestC /** * Tests the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHoliday(): void { @@ -47,14 +44,14 @@ public function testHoliday(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-5-30", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-5-30", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests the holiday defined in this test before establishment. * - * @throws Exception + * @throws \Exception */ public function testHolidayBeforeEstablishment(): void { @@ -68,7 +65,7 @@ public function testHolidayBeforeEstablishment(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -83,7 +80,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/UnitedKingdom/Scotland/StAndrewsDayTest.php b/tests/UnitedKingdom/Scotland/StAndrewsDayTest.php index a5d5980b8..effd4702b 100644 --- a/tests/UnitedKingdom/Scotland/StAndrewsDayTest.php +++ b/tests/UnitedKingdom/Scotland/StAndrewsDayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\UnitedKingdom\Scotland; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -43,11 +40,11 @@ class StAndrewsDayTest extends ScotlandBaseTestCase implements HolidayTestCase * @param int $year the year for which the holiday defined in this test needs to be tested * @param string $expected the expected date * - * @throws Exception + * @throws \Exception */ public function testHoliday(int $year, string $expected): void { - $date = new DateTime($expected, new DateTimeZone(self::TIMEZONE)); + $date = new \DateTime($expected, new \DateTimeZone(self::TIMEZONE)); $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $date); if (\in_array((int) $date->format('w'), [0, 6], true)) { @@ -61,7 +58,7 @@ public function testHoliday(int $year, string $expected): void * * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function HolidayDataProvider(): array { @@ -69,7 +66,7 @@ public function HolidayDataProvider(): array for ($y = 0; $y < self::TEST_ITERATIONS; ++$y) { $year = $this->generateRandomYear(self::ESTABLISHMENT_YEAR); - $date = new DateTime("$year-11-30", new DateTimeZone(self::TIMEZONE)); + $date = new \DateTime("$year-11-30", new \DateTimeZone(self::TIMEZONE)); $data[] = [$year, $date->format('Y-m-d')]; } @@ -79,7 +76,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -94,7 +91,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/UnitedKingdom/Scotland/SummerBankHolidayTest.php b/tests/UnitedKingdom/Scotland/SummerBankHolidayTest.php index dc5823834..83de20654 100644 --- a/tests/UnitedKingdom/Scotland/SummerBankHolidayTest.php +++ b/tests/UnitedKingdom/Scotland/SummerBankHolidayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\UnitedKingdom\Scotland; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -38,7 +35,7 @@ class SummerBankHolidayTest extends ScotlandBaseTestCase implements HolidayTestC /** * Tests the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHoliday(): void { @@ -47,14 +44,14 @@ public function testHoliday(): void self::REGION, self::HOLIDAY, $year, - new DateTime("first monday of august $year", new DateTimeZone(self::TIMEZONE)) + new \DateTime("first monday of august $year", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests the holiday defined in this test before establishment. * - * @throws Exception + * @throws \Exception */ public function testHolidayBeforeEstablishment(): void { @@ -68,7 +65,7 @@ public function testHolidayBeforeEstablishment(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -83,7 +80,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/UnitedKingdom/SpringBankHolidayTest.php b/tests/UnitedKingdom/SpringBankHolidayTest.php index c969a4d37..77eca1bb7 100644 --- a/tests/UnitedKingdom/SpringBankHolidayTest.php +++ b/tests/UnitedKingdom/SpringBankHolidayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\UnitedKingdom; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -38,7 +35,7 @@ class SpringBankHolidayTest extends UnitedKingdomBaseTestCase implements Holiday /** * Tests the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHoliday(): void { @@ -47,14 +44,14 @@ public function testHoliday(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-5-30", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-5-30", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests the holiday exceptions in 2002, 2012 and 2022. * - * @throws Exception + * @throws \Exception */ public function testHolidayException(): void { @@ -62,28 +59,28 @@ public function testHolidayException(): void self::REGION, self::HOLIDAY, 2002, - new DateTime('2002-6-4', new DateTimeZone(self::TIMEZONE)) + new \DateTime('2002-6-4', new \DateTimeZone(self::TIMEZONE)) ); $this->assertHoliday( self::REGION, self::HOLIDAY, 2012, - new DateTime('2012-6-4', new DateTimeZone(self::TIMEZONE)) + new \DateTime('2012-6-4', new \DateTimeZone(self::TIMEZONE)) ); $this->assertHoliday( self::REGION, self::HOLIDAY, 2022, - new DateTime('2022-6-2', new DateTimeZone(self::TIMEZONE)) + new \DateTime('2022-6-2', new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests the holiday defined in this test before establishment. * - * @throws Exception + * @throws \Exception */ public function testHolidayBeforeEstablishment(): void { @@ -97,7 +94,7 @@ public function testHolidayBeforeEstablishment(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -112,7 +109,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/UnitedKingdom/SummerBankHolidayTest.php b/tests/UnitedKingdom/SummerBankHolidayTest.php index 7a5d6856b..6039fbc11 100644 --- a/tests/UnitedKingdom/SummerBankHolidayTest.php +++ b/tests/UnitedKingdom/SummerBankHolidayTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\UnitedKingdom; -use DateTime; -use DateTimeZone; use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -43,7 +41,7 @@ class SummerBankHolidayTest extends UnitedKingdomBaseTestCase implements Holiday /** * Tests the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHoliday(): void { @@ -52,14 +50,14 @@ public function testHoliday(): void self::REGION, self::HOLIDAY, $year, - new DateTime("last monday of august $year", new DateTimeZone(self::TIMEZONE)) + new \DateTime("last monday of august $year", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests the holiday exception in 2020. * - * @throws Exception + * @throws \Exception */ public function testHolidayBefore1965(): void { @@ -68,14 +66,14 @@ public function testHolidayBefore1965(): void self::REGION, self::HOLIDAY, $year, - new DateTime("first monday of august $year", new DateTimeZone(self::TIMEZONE)) + new \DateTime("first monday of august $year", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests the holiday during trial period in 1965-1970. * - * @throws Exception + * @throws \Exception */ public function testHolidayTrialPeriod(): void { @@ -83,44 +81,44 @@ public function testHolidayTrialPeriod(): void self::REGION, self::HOLIDAY, 1965, - new DateTime('1965-8-30', new DateTimeZone(self::TIMEZONE)) + new \DateTime('1965-8-30', new \DateTimeZone(self::TIMEZONE)) ); $this->assertHoliday( self::REGION, self::HOLIDAY, 1966, - new DateTime('1966-8-29', new DateTimeZone(self::TIMEZONE)) + new \DateTime('1966-8-29', new \DateTimeZone(self::TIMEZONE)) ); $this->assertHoliday( self::REGION, self::HOLIDAY, 1967, - new DateTime('1967-8-28', new DateTimeZone(self::TIMEZONE)) + new \DateTime('1967-8-28', new \DateTimeZone(self::TIMEZONE)) ); $this->assertHoliday( self::REGION, self::HOLIDAY, 1968, - new DateTime('1968-9-2', new DateTimeZone(self::TIMEZONE)) + new \DateTime('1968-9-2', new \DateTimeZone(self::TIMEZONE)) ); $this->assertHoliday( self::REGION, self::HOLIDAY, 1969, - new DateTime('1969-9-1', new DateTimeZone(self::TIMEZONE)) + new \DateTime('1969-9-1', new \DateTimeZone(self::TIMEZONE)) ); $this->assertHoliday( self::REGION, self::HOLIDAY, 1970, - new DateTime('1970-8-31', new DateTimeZone(self::TIMEZONE)) + new \DateTime('1970-8-31', new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests the holiday defined in this test before establishment. * - * @throws Exception + * @throws \Exception */ public function testHolidayBeforeEstablishment(): void { @@ -134,7 +132,7 @@ public function testHolidayBeforeEstablishment(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -149,7 +147,7 @@ public function testTranslation(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslationBeforeRename(): void { @@ -164,7 +162,7 @@ public function testTranslationBeforeRename(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/UnitedKingdom/UnitedKingdomTest.php b/tests/UnitedKingdom/UnitedKingdomTest.php index 5fcd2168b..23ac15862 100644 --- a/tests/UnitedKingdom/UnitedKingdomTest.php +++ b/tests/UnitedKingdom/UnitedKingdomTest.php @@ -14,7 +14,6 @@ namespace Yasumi\tests\UnitedKingdom; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\ProviderTestCase; @@ -105,7 +104,7 @@ public function testOtherHolidays(): void } /** - * @throws ReflectionException + * @throws \ReflectionException * @throws \Exception */ public function testSources(): void diff --git a/tests/UnitedKingdom/Wales/BoxingDayTest.php b/tests/UnitedKingdom/Wales/BoxingDayTest.php index b16cebac0..405e26c97 100644 --- a/tests/UnitedKingdom/Wales/BoxingDayTest.php +++ b/tests/UnitedKingdom/Wales/BoxingDayTest.php @@ -14,10 +14,6 @@ namespace Yasumi\tests\UnitedKingdom\Wales; -use DateInterval; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -39,15 +35,15 @@ class BoxingDayTest extends WalesBaseTestCase implements HolidayTestCase * @param int $year the year for which the holiday defined in this test needs to be tested * @param string $expected the expected date * - * @throws Exception + * @throws \Exception */ public function testHoliday(int $year, string $expected): void { - $date = new DateTime($expected, new DateTimeZone(self::TIMEZONE)); + $date = new \DateTime($expected, new \DateTimeZone(self::TIMEZONE)); $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $date); if (\in_array((int) $date->format('w'), [0, 6], true)) { - $date->add(new DateInterval('P2D')); + $date->add(new \DateInterval('P2D')); $this->assertHoliday(self::REGION, 'substituteHoliday:'.self::HOLIDAY, $year, $date); $this->assertHolidayType(self::REGION, 'substituteHoliday:'.self::HOLIDAY, $year, Holiday::TYPE_BANK); } @@ -58,7 +54,7 @@ public function testHoliday(int $year, string $expected): void * * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function HolidayDataProvider(): array { @@ -66,7 +62,7 @@ public function HolidayDataProvider(): array for ($y = 0; $y < self::TEST_ITERATIONS; ++$y) { $year = $this->generateRandomYear(); - $date = new DateTime("$year-12-26", new DateTimeZone(self::TIMEZONE)); + $date = new \DateTime("$year-12-26", new \DateTimeZone(self::TIMEZONE)); $data[] = [$year, $date->format('Y-m-d')]; } @@ -77,7 +73,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -92,7 +88,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/UnitedKingdom/Wales/ChristmasDayTest.php b/tests/UnitedKingdom/Wales/ChristmasDayTest.php index 27ab6f961..58743176f 100644 --- a/tests/UnitedKingdom/Wales/ChristmasDayTest.php +++ b/tests/UnitedKingdom/Wales/ChristmasDayTest.php @@ -14,10 +14,6 @@ namespace Yasumi\tests\UnitedKingdom\Wales; -use DateInterval; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -39,15 +35,15 @@ class ChristmasDayTest extends WalesBaseTestCase implements HolidayTestCase * @param int $year the year for which the holiday defined in this test needs to be tested * @param string $expected the expected date * - * @throws Exception + * @throws \Exception */ public function testHoliday(int $year, string $expected): void { - $date = new DateTime($expected, new DateTimeZone(self::TIMEZONE)); + $date = new \DateTime($expected, new \DateTimeZone(self::TIMEZONE)); $this->assertHoliday(self::REGION, self::HOLIDAY, $year, $date); if (\in_array((int) $date->format('w'), [0, 6], true)) { - $date->add(new DateInterval('P2D')); + $date->add(new \DateInterval('P2D')); $this->assertHoliday(self::REGION, 'substituteHoliday:'.self::HOLIDAY, $year, $date); $this->assertHolidayType(self::REGION, 'substituteHoliday:'.self::HOLIDAY, $year, Holiday::TYPE_BANK); } @@ -58,7 +54,7 @@ public function testHoliday(int $year, string $expected): void * * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function HolidayDataProvider(): array { @@ -66,7 +62,7 @@ public function HolidayDataProvider(): array for ($y = 0; $y < self::TEST_ITERATIONS; ++$y) { $year = $this->generateRandomYear(); - $date = new DateTime("$year-12-25", new DateTimeZone(self::TIMEZONE)); + $date = new \DateTime("$year-12-25", new \DateTimeZone(self::TIMEZONE)); $data[] = [$year, $date->format('Y-m-d')]; } @@ -77,7 +73,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -92,7 +88,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/UnitedKingdom/Wales/EasterMondayTest.php b/tests/UnitedKingdom/Wales/EasterMondayTest.php index a7c6fc014..b6becfe3c 100644 --- a/tests/UnitedKingdom/Wales/EasterMondayTest.php +++ b/tests/UnitedKingdom/Wales/EasterMondayTest.php @@ -14,10 +14,6 @@ namespace Yasumi\tests\UnitedKingdom\Wales; -use DateInterval; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -39,7 +35,7 @@ class EasterMondayTest extends WalesBaseTestCase implements HolidayTestCase * @param int $year the year for which the holiday defined in this test needs to be tested * @param string $expected the expected date * - * @throws Exception + * @throws \Exception */ public function testHoliday(int $year, string $expected): void { @@ -47,7 +43,7 @@ public function testHoliday(int $year, string $expected): void self::REGION, self::HOLIDAY, $year, - new DateTime($expected, new DateTimeZone(self::TIMEZONE)) + new \DateTime($expected, new \DateTimeZone(self::TIMEZONE)) ); } @@ -56,7 +52,7 @@ public function testHoliday(int $year, string $expected): void * * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function HolidayDataProvider(): array { @@ -65,7 +61,7 @@ public function HolidayDataProvider(): array for ($y = 0; $y < 50; ++$y) { $year = $this->generateRandomYear(); $date = $this->calculateEaster($year, self::TIMEZONE); - $date->add(new DateInterval('P1D')); + $date->add(new \DateInterval('P1D')); $data[] = [$year, $date->format('Y-m-d')]; } @@ -76,7 +72,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -91,7 +87,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/UnitedKingdom/Wales/GoodFridayTest.php b/tests/UnitedKingdom/Wales/GoodFridayTest.php index 6883ffc44..19cf75cee 100644 --- a/tests/UnitedKingdom/Wales/GoodFridayTest.php +++ b/tests/UnitedKingdom/Wales/GoodFridayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\UnitedKingdom\Wales; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -33,7 +30,7 @@ class GoodFridayTest extends WalesBaseTestCase implements HolidayTestCase /** * Tests the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHoliday(): void { @@ -42,14 +39,14 @@ public function testHoliday(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-3-30", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-3-30", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -64,7 +61,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/UnitedKingdom/Wales/MayDayBankHolidayTest.php b/tests/UnitedKingdom/Wales/MayDayBankHolidayTest.php index 7a4429788..da07f7616 100644 --- a/tests/UnitedKingdom/Wales/MayDayBankHolidayTest.php +++ b/tests/UnitedKingdom/Wales/MayDayBankHolidayTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\UnitedKingdom\Wales; -use DateTime; -use DateTimeZone; use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -38,7 +36,7 @@ class MayDayBankHolidayTest extends WalesBaseTestCase implements HolidayTestCase /** * Tests the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHoliday(): void { @@ -47,14 +45,14 @@ public function testHoliday(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-5-2", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-5-2", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests the holiday exception in 1995 and 2020. * - * @throws Exception + * @throws \Exception */ public function testHolidayExceptions(): void { @@ -62,21 +60,21 @@ public function testHolidayExceptions(): void self::REGION, self::HOLIDAY, 1995, - new DateTime('1995-5-8', new DateTimeZone(self::TIMEZONE)) + new \DateTime('1995-5-8', new \DateTimeZone(self::TIMEZONE)) ); $this->assertHoliday( self::REGION, self::HOLIDAY, 2020, - new DateTime('2020-5-8', new DateTimeZone(self::TIMEZONE)) + new \DateTime('2020-5-8', new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests the holiday defined in this test before establishment. * - * @throws Exception + * @throws \Exception */ public function testHolidayBeforeEstablishment(): void { @@ -90,7 +88,7 @@ public function testHolidayBeforeEstablishment(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -105,7 +103,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/UnitedKingdom/Wales/NewYearsDayTest.php b/tests/UnitedKingdom/Wales/NewYearsDayTest.php index a845eadbd..4a6eb1b6c 100644 --- a/tests/UnitedKingdom/Wales/NewYearsDayTest.php +++ b/tests/UnitedKingdom/Wales/NewYearsDayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\UnitedKingdom\Wales; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -48,7 +45,7 @@ class NewYearsDayTest extends WalesBaseTestCase implements HolidayTestCase * @param int $year the year for which the holiday defined in this test needs to be tested * @param string $expected the expected date * - * @throws Exception + * @throws \Exception */ public function testHolidayOnAfterEstablishment(int $year, string $expected): void { @@ -56,14 +53,14 @@ public function testHolidayOnAfterEstablishment(int $year, string $expected): vo self::REGION, self::HOLIDAY, $year, - new DateTime($expected, new DateTimeZone(self::TIMEZONE)) + new \DateTime($expected, new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests the holiday defined in this test before establishment. * - * @throws Exception + * @throws \Exception */ public function testHolidayBeforeEstablishment(): void { @@ -77,7 +74,7 @@ public function testHolidayBeforeEstablishment(): void /** * Tests that the holiday defined in this test is of the type 'observance' before the year it was changed. * - * @throws Exception + * @throws \Exception */ public function testHolidayIsObservedTypeBeforeChange(): void { @@ -94,7 +91,7 @@ public function testHolidayIsObservedTypeBeforeChange(): void * * @return array list of test dates for the holiday defined in this test * - * @throws Exception + * @throws \Exception */ public function HolidayDataProvider(): array { @@ -104,7 +101,7 @@ public function HolidayDataProvider(): array /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -119,7 +116,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/UnitedKingdom/Wales/SpringBankHolidayTest.php b/tests/UnitedKingdom/Wales/SpringBankHolidayTest.php index 0aebb0e3c..7c99ea73e 100644 --- a/tests/UnitedKingdom/Wales/SpringBankHolidayTest.php +++ b/tests/UnitedKingdom/Wales/SpringBankHolidayTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\UnitedKingdom\Wales; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -38,7 +35,7 @@ class SpringBankHolidayTest extends WalesBaseTestCase implements HolidayTestCase /** * Tests the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHoliday(): void { @@ -47,14 +44,14 @@ public function testHoliday(): void self::REGION, self::HOLIDAY, $year, - new DateTime("$year-5-30", new DateTimeZone(self::TIMEZONE)) + new \DateTime("$year-5-30", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests the holiday exceptions in 2002 and 2012. * - * @throws Exception + * @throws \Exception */ public function testHolidayException(): void { @@ -62,21 +59,21 @@ public function testHolidayException(): void self::REGION, self::HOLIDAY, 2002, - new DateTime('2002-6-4', new DateTimeZone(self::TIMEZONE)) + new \DateTime('2002-6-4', new \DateTimeZone(self::TIMEZONE)) ); $this->assertHoliday( self::REGION, self::HOLIDAY, 2012, - new DateTime('2012-6-4', new DateTimeZone(self::TIMEZONE)) + new \DateTime('2012-6-4', new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests the holiday defined in this test before establishment. * - * @throws Exception + * @throws \Exception */ public function testHolidayBeforeEstablishment(): void { @@ -90,7 +87,7 @@ public function testHolidayBeforeEstablishment(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -105,7 +102,7 @@ public function testTranslation(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/UnitedKingdom/Wales/SummerBankHolidayTest.php b/tests/UnitedKingdom/Wales/SummerBankHolidayTest.php index f874b675c..8fe174aa7 100644 --- a/tests/UnitedKingdom/Wales/SummerBankHolidayTest.php +++ b/tests/UnitedKingdom/Wales/SummerBankHolidayTest.php @@ -14,8 +14,6 @@ namespace Yasumi\tests\UnitedKingdom\Wales; -use DateTime; -use DateTimeZone; use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -43,7 +41,7 @@ class SummerBankHolidayTest extends WalesBaseTestCase implements HolidayTestCase /** * Tests the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHoliday(): void { @@ -52,14 +50,14 @@ public function testHoliday(): void self::REGION, self::HOLIDAY, $year, - new DateTime("last monday of august $year", new DateTimeZone(self::TIMEZONE)) + new \DateTime("last monday of august $year", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests the holiday exception in 2020. * - * @throws Exception + * @throws \Exception */ public function testHolidayBefore1965(): void { @@ -68,14 +66,14 @@ public function testHolidayBefore1965(): void self::REGION, self::HOLIDAY, $year, - new DateTime("first monday of august $year", new DateTimeZone(self::TIMEZONE)) + new \DateTime("first monday of august $year", new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests the holiday during trial period in 1965-1970. * - * @throws Exception + * @throws \Exception */ public function testHolidayTrialPeriod(): void { @@ -83,44 +81,44 @@ public function testHolidayTrialPeriod(): void self::REGION, self::HOLIDAY, 1965, - new DateTime('1965-8-30', new DateTimeZone(self::TIMEZONE)) + new \DateTime('1965-8-30', new \DateTimeZone(self::TIMEZONE)) ); $this->assertHoliday( self::REGION, self::HOLIDAY, 1966, - new DateTime('1966-8-29', new DateTimeZone(self::TIMEZONE)) + new \DateTime('1966-8-29', new \DateTimeZone(self::TIMEZONE)) ); $this->assertHoliday( self::REGION, self::HOLIDAY, 1967, - new DateTime('1967-8-28', new DateTimeZone(self::TIMEZONE)) + new \DateTime('1967-8-28', new \DateTimeZone(self::TIMEZONE)) ); $this->assertHoliday( self::REGION, self::HOLIDAY, 1968, - new DateTime('1968-9-2', new DateTimeZone(self::TIMEZONE)) + new \DateTime('1968-9-2', new \DateTimeZone(self::TIMEZONE)) ); $this->assertHoliday( self::REGION, self::HOLIDAY, 1969, - new DateTime('1969-9-1', new DateTimeZone(self::TIMEZONE)) + new \DateTime('1969-9-1', new \DateTimeZone(self::TIMEZONE)) ); $this->assertHoliday( self::REGION, self::HOLIDAY, 1970, - new DateTime('1970-8-31', new DateTimeZone(self::TIMEZONE)) + new \DateTime('1970-8-31', new \DateTimeZone(self::TIMEZONE)) ); } /** * Tests the holiday defined in this test before establishment. * - * @throws Exception + * @throws \Exception */ public function testHolidayBeforeEstablishment(): void { @@ -134,7 +132,7 @@ public function testHolidayBeforeEstablishment(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslation(): void { @@ -149,7 +147,7 @@ public function testTranslation(): void /** * Tests the translated name of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testTranslationBeforeRename(): void { @@ -164,7 +162,7 @@ public function testTranslationBeforeRename(): void /** * Tests type of the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHolidayType(): void { diff --git a/tests/UnitedKingdom/Wales/WalesTest.php b/tests/UnitedKingdom/Wales/WalesTest.php index 8f76e419b..d4e7b731c 100644 --- a/tests/UnitedKingdom/Wales/WalesTest.php +++ b/tests/UnitedKingdom/Wales/WalesTest.php @@ -14,7 +14,6 @@ namespace Yasumi\tests\UnitedKingdom\Wales; -use ReflectionException; use Yasumi\Holiday; use Yasumi\tests\ProviderTestCase; @@ -105,7 +104,7 @@ public function testOtherHolidays(): void } /** - * @throws ReflectionException + * @throws \ReflectionException * @throws \Exception */ public function testSources(): void diff --git a/tests/YasumiBase.php b/tests/YasumiBase.php index c1cac43fd..de9f68094 100644 --- a/tests/YasumiBase.php +++ b/tests/YasumiBase.php @@ -15,12 +15,7 @@ namespace Yasumi\tests; -use DateTime; -use DateTimeInterface; -use Exception; -use InvalidArgumentException; use PHPUnit\Framework\AssertionFailedError; -use RuntimeException; use Yasumi\Exception\InvalidDateException; use Yasumi\Exception\UnknownLocaleException; use Yasumi\Filters\BankHolidaysFilter; @@ -49,8 +44,8 @@ trait YasumiBase * @param string $type type of holiday. Use the following constants: TYPE_OFFICIAL, * TYPE_OBSERVANCE, TYPE_SEASON, TYPE_BANK or TYPE_OTHER. * - * @throws InvalidArgumentException - * @throws RuntimeException + * @throws \InvalidArgumentException + * @throws \RuntimeException * @throws UnknownLocaleException */ public function assertDefinedHolidays( @@ -88,22 +83,22 @@ public function assertDefinedHolidays( /** * Asserts expected date is a holiday for the given year and name. * - * @param string $provider holiday provider (i.e. country/state) for which the holiday need to be tested. - * @param string $key key of the holiday to be checked against - * @param int $year holiday calendar year - * @param DateTime $expected date to be checked against + * @param string $provider holiday provider (i.e. country/state) for which the holiday need to be tested. + * @param string $key key of the holiday to be checked against + * @param int $year holiday calendar year + * @param \DateTime $expected date to be checked against * * @throws UnknownLocaleException * @throws InvalidDateException - * @throws InvalidArgumentException - * @throws RuntimeException + * @throws \InvalidArgumentException + * @throws \RuntimeException * @throws AssertionFailedError */ public function assertHoliday( string $provider, string $key, int $year, - DateTimeInterface $expected + \DateTimeInterface $expected ): void { $holidays = Yasumi::create($provider, $year); $holiday = $holidays->getHoliday($key); @@ -116,22 +111,22 @@ public function assertHoliday( /** * Asserts the expected date is a substitute holiday for that given year and name. * - * @param string $provider the holiday provider (i.e. country/state) for which the holiday need to be tested. - * @param string $key key of the substituted holiday to be checked against - * @param int $year holiday calendar year - * @param DateTime $expected date to be checked against + * @param string $provider the holiday provider (i.e. country/state) for which the holiday need to be tested. + * @param string $key key of the substituted holiday to be checked against + * @param int $year holiday calendar year + * @param \DateTime $expected date to be checked against * * @throws UnknownLocaleException * @throws InvalidDateException - * @throws InvalidArgumentException - * @throws RuntimeException + * @throws \InvalidArgumentException + * @throws \RuntimeException * @throws AssertionFailedError */ public function assertSubstituteHoliday( string $provider, string $key, int $year, - DateTimeInterface $expected + \DateTimeInterface $expected ): void { $holidays = Yasumi::create($provider, $year); $holiday = $holidays->getHoliday('substituteHoliday:'.$key); @@ -148,8 +143,8 @@ public function assertSubstituteHoliday( * @param string $key key of the substituted holiday to be checked against * @param int $year holiday calendar year * - * @throws InvalidArgumentException - * @throws RuntimeException + * @throws \InvalidArgumentException + * @throws \RuntimeException * @throws UnknownLocaleException * @throws InvalidDateException * @throws AssertionFailedError @@ -173,8 +168,8 @@ public function assertNotSubstituteHoliday( * @param string $key key of the holiday to be checked against * @param int $year holiday calendar year * - * @throws InvalidArgumentException - * @throws RuntimeException + * @throws \InvalidArgumentException + * @throws \RuntimeException * @throws UnknownLocaleException * @throws InvalidDateException * @throws AssertionFailedError @@ -198,8 +193,8 @@ public function assertNotHoliday( * @param int $year holiday calendar year * @param array $translations translations to be checked against * - * @throws InvalidArgumentException - * @throws RuntimeException + * @throws \InvalidArgumentException + * @throws \RuntimeException * @throws UnknownLocaleException * @throws AssertionFailedError */ @@ -243,8 +238,8 @@ public function assertTranslatedHolidayName( * @param int $year holiday calendar year * @param string $type type to be checked against * - * @throws InvalidArgumentException - * @throws RuntimeException + * @throws \InvalidArgumentException + * @throws \RuntimeException * @throws AssertionFailedError * @throws UnknownLocaleException */ @@ -270,8 +265,8 @@ public function assertHolidayType( * @param string $expectedDayOfWeek expected week day (i.e. "Saturday", "Sunday", etc.). * * @throws AssertionFailedError - * @throws InvalidArgumentException - * @throws RuntimeException + * @throws \InvalidArgumentException + * @throws \RuntimeException * @throws UnknownLocaleException */ public function assertDayOfWeek( @@ -294,7 +289,7 @@ public function assertDayOfWeek( * @param string $provider holiday provider (i.e. country/state) for which the holiday need to be tested. * @param int $expectedSourceCount expected sources number * - * @throws Exception + * @throws \Exception */ public function assertSources(string $provider, int $expectedSourceCount): void { From e644874ce2872da1e0a21c7fa01028118715f445 Mon Sep 17 00:00:00 2001 From: Sacha Telgenhof Date: Tue, 27 Dec 2022 15:12:46 +0900 Subject: [PATCH 078/142] Altered version constraints so composer will update the appropriate version instead of a fixed one. Signed-off-by: Sacha Telgenhof --- composer.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/composer.json b/composer.json index a312116c8..613e55ec8 100644 --- a/composer.json +++ b/composer.json @@ -40,7 +40,7 @@ "ext-json": "*" }, "require-dev": { - "friendsofphp/php-cs-fixer": "v2.19 | v3.13", + "friendsofphp/php-cs-fixer": "^2.19 | ^3.13", "infection/infection": "^0.17 | ^0.26", "mikey179/vfsstream": "^1.6", "phan/phan": "^5.2", From 59aa2a785f1e2dab679de468fc8e208285529ab9 Mon Sep 17 00:00:00 2001 From: Sacha Telgenhof Date: Tue, 27 Dec 2022 15:51:59 +0900 Subject: [PATCH 079/142] Updated psalm to latest v4 release. Signed-off-by: Sacha Telgenhof --- composer.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/composer.json b/composer.json index 613e55ec8..4797e4277 100644 --- a/composer.json +++ b/composer.json @@ -46,7 +46,7 @@ "phan/phan": "^5.2", "phpstan/phpstan": "^1.4", "phpunit/phpunit": "^8.5 | ^9.5", - "vimeo/psalm": "^4.9" + "vimeo/psalm": "^4.30" }, "config": { "sort-packages": true, From d449a827d35ac41e1f7a030074ba8cbd945d3ee0 Mon Sep 17 00:00:00 2001 From: Sacha Telgenhof Date: Tue, 27 Dec 2022 17:17:13 +0900 Subject: [PATCH 080/142] Relocated swap function to base Daylight Saving Time class. Added additional years that aren't observed or deviated. Signed-off-by: Sacha Telgenhof --- tests/Denmark/DaylightSavingTime.php | 11 +++++++++++ tests/Denmark/SummerTimeTest.php | 5 +++++ tests/Denmark/WinterTimeTest.php | 11 ----------- 3 files changed, 16 insertions(+), 11 deletions(-) diff --git a/tests/Denmark/DaylightSavingTime.php b/tests/Denmark/DaylightSavingTime.php index af2317281..b774fdc81 100644 --- a/tests/Denmark/DaylightSavingTime.php +++ b/tests/Denmark/DaylightSavingTime.php @@ -36,4 +36,15 @@ public function __construct() parent::__construct(); } + + /* Swaps the observation from observed to unobserved for the given years */ + protected function swapObservation(array $years): void + { + foreach ($years as $y) { + $this->observedYears[] = $y; + if (false !== ($key = array_search($y, $this->unobservedYears, true))) { + unset($this->unobservedYears[(int) $key]); + } + } + } } diff --git a/tests/Denmark/SummerTimeTest.php b/tests/Denmark/SummerTimeTest.php index 6f814a14f..c0122df6d 100644 --- a/tests/Denmark/SummerTimeTest.php +++ b/tests/Denmark/SummerTimeTest.php @@ -53,11 +53,16 @@ public function __construct() // In version 2022f of the tz db, a correction for some years weere made for the summertime // transitions. See: https://github.com/eggert/tz/blob/2022f/europe if (1 === strcmp(\intltz_get_tz_data_version(), '2022f')) { + $this->swapObservation([1917, 1918, 1949]); + $this->deviantTransitions[1916] = '1916-04-30'; + $this->deviantTransitions[1917] = '1917-04-16'; + $this->deviantTransitions[1918] = '1918-04-15'; $this->deviantTransitions[1940] = '1940-04-01'; $this->deviantTransitions[1946] = '1946-04-14'; $this->deviantTransitions[1947] = '1947-04-06'; $this->deviantTransitions[1948] = '1948-04-18'; + $this->deviantTransitions[1949] = '1949-04-10'; } } diff --git a/tests/Denmark/WinterTimeTest.php b/tests/Denmark/WinterTimeTest.php index 6ec3f8884..654de6c70 100644 --- a/tests/Denmark/WinterTimeTest.php +++ b/tests/Denmark/WinterTimeTest.php @@ -121,15 +121,4 @@ public function testHolidayType(): void Holiday::TYPE_SEASON ); } - - /* Swaps the observation from observed to unobserved for the given years */ - private function swapObservation(array $years): void - { - foreach ($years as $y) { - $this->observedYears[] = $y; - if (false !== ($key = array_search($y, $this->unobservedYears, true))) { - unset($this->unobservedYears[(int) $key]); - } - } - } } From 1e26e5c2c71c2d8a4255137da7a35f9e75e92a7e Mon Sep 17 00:00:00 2001 From: Sacha Telgenhof Date: Tue, 27 Dec 2022 18:23:15 +0900 Subject: [PATCH 081/142] Changed links to GitHub workflow badges as the route pattern has been changed (See: https://github.com/badges/shields/issues/8671). Signed-off-by: Sacha Telgenhof --- README.md | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/README.md b/README.md index 66ab67363..b0a5f41c3 100644 --- a/README.md +++ b/README.md @@ -2,9 +2,9 @@ [![GitHub Release](https://img.shields.io/github/release/azuyalabs/yasumi.svg?style=flat-square)](https://github.com/azuyalabs/yasumi/releases) [![Total Downloads](https://img.shields.io/packagist/dt/azuyalabs/yasumi.svg?style=flat-square)](https://packagist.org/packages/azuyalabs/yasumi) -![Coding Standard](https://img.shields.io/github/workflow/status/azuyalabs/yasumi/Coding%20Standard?label=Coding%20Standard&style=flat-square) -![Static analysis](https://img.shields.io/github/workflow/status/azuyalabs/yasumi/Static%20analysis?label=Static%20analysis&style=flat-square) -![Testing](https://img.shields.io/github/workflow/status/azuyalabs/yasumi/Testing?label=Testing&style=flat-square) +![Coding Standard](https://img.shields.io/github/actions/workflow/status/azuyalabs/yasumi/coding-standard.yml?label=Coding%20Standard&style=flat-square) +![Static analysis](https://img.shields.io/github/actions/workflow/status/azuyalabs/yasumi/static-analysis.yml?label=Static%20analysis&style=flat-square) +![Testing](https://img.shields.io/github/actions/workflow/status/azuyalabs/yasumi/testing.yml?label=Testing&style=flat-square) [![Software License](https://img.shields.io/badge/license-MIT-brightgreen.svg?style=flat-square)](LICENSE) # Introduction From ca61eb105c7052ea3c52edca8166edd1750dd020 Mon Sep 17 00:00:00 2001 From: Anna Damm Date: Tue, 27 Dec 2022 10:29:11 +0100 Subject: [PATCH 082/142] [fix-296] make epiphany an official holiday in German states, fixes #296 (#297) Co-authored-by: Anna Damm --- src/Yasumi/Provider/Germany/BadenWurttemberg.php | 2 +- src/Yasumi/Provider/Germany/Bavaria.php | 2 +- src/Yasumi/Provider/Germany/SaxonyAnhalt.php | 3 +-- tests/Germany/BadenWurttemberg/BadenWurttembergTest.php | 3 ++- tests/Germany/BadenWurttemberg/EpiphanyTest.php | 2 +- tests/Germany/Bavaria/BavariaTest.php | 3 ++- tests/Germany/Bavaria/EpiphanyTest.php | 2 +- tests/Germany/SaxonyAnhalt/EpiphanyTest.php | 2 +- tests/Germany/SaxonyAnhalt/SaxonyAnhaltTest.php | 3 ++- 9 files changed, 12 insertions(+), 10 deletions(-) diff --git a/src/Yasumi/Provider/Germany/BadenWurttemberg.php b/src/Yasumi/Provider/Germany/BadenWurttemberg.php index 4f84b2897..1469ff882 100644 --- a/src/Yasumi/Provider/Germany/BadenWurttemberg.php +++ b/src/Yasumi/Provider/Germany/BadenWurttemberg.php @@ -49,7 +49,7 @@ public function initialize(): void parent::initialize(); // Add custom Christian holidays - $this->addHoliday($this->epiphany($this->year, $this->timezone, $this->locale, Holiday::TYPE_OTHER)); + $this->addHoliday($this->epiphany($this->year, $this->timezone, $this->locale)); $this->addHoliday($this->corpusChristi($this->year, $this->timezone, $this->locale, Holiday::TYPE_OFFICIAL)); $this->addHoliday($this->allSaintsDay($this->year, $this->timezone, $this->locale)); } diff --git a/src/Yasumi/Provider/Germany/Bavaria.php b/src/Yasumi/Provider/Germany/Bavaria.php index d043b918a..60e704bc2 100644 --- a/src/Yasumi/Provider/Germany/Bavaria.php +++ b/src/Yasumi/Provider/Germany/Bavaria.php @@ -48,7 +48,7 @@ public function initialize(): void parent::initialize(); // Add custom Christian holidays - $this->addHoliday($this->epiphany($this->year, $this->timezone, $this->locale, Holiday::TYPE_OTHER)); + $this->addHoliday($this->epiphany($this->year, $this->timezone, $this->locale)); $this->addHoliday($this->corpusChristi($this->year, $this->timezone, $this->locale, Holiday::TYPE_OFFICIAL)); $this->addHoliday($this->allSaintsDay($this->year, $this->timezone, $this->locale)); } diff --git a/src/Yasumi/Provider/Germany/SaxonyAnhalt.php b/src/Yasumi/Provider/Germany/SaxonyAnhalt.php index b79334166..0ed166df6 100644 --- a/src/Yasumi/Provider/Germany/SaxonyAnhalt.php +++ b/src/Yasumi/Provider/Germany/SaxonyAnhalt.php @@ -16,7 +16,6 @@ use Yasumi\Exception\InvalidDateException; use Yasumi\Exception\UnknownLocaleException; -use Yasumi\Holiday; use Yasumi\Provider\Germany; /** @@ -49,7 +48,7 @@ public function initialize(): void parent::initialize(); // Add custom Christian holidays - $this->addHoliday($this->epiphany($this->year, $this->timezone, $this->locale, Holiday::TYPE_OTHER)); + $this->addHoliday($this->epiphany($this->year, $this->timezone, $this->locale)); $this->calculateReformationDay(); } diff --git a/tests/Germany/BadenWurttemberg/BadenWurttembergTest.php b/tests/Germany/BadenWurttemberg/BadenWurttembergTest.php index 9d66930c7..c59dc3749 100644 --- a/tests/Germany/BadenWurttemberg/BadenWurttembergTest.php +++ b/tests/Germany/BadenWurttemberg/BadenWurttembergTest.php @@ -44,6 +44,7 @@ public function testOfficialHolidays(): void { $this->assertDefinedHolidays([ 'newYearsDay', + 'epiphany', 'goodFriday', 'easterMonday', 'internationalWorkersDay', @@ -87,7 +88,7 @@ public function testBankHolidays(): void public function testOtherHolidays(): void { $this->assertDefinedHolidays( - ['epiphany'], + [], self::REGION, $this->year, Holiday::TYPE_OTHER diff --git a/tests/Germany/BadenWurttemberg/EpiphanyTest.php b/tests/Germany/BadenWurttemberg/EpiphanyTest.php index 1793e204b..ed3a94610 100644 --- a/tests/Germany/BadenWurttemberg/EpiphanyTest.php +++ b/tests/Germany/BadenWurttemberg/EpiphanyTest.php @@ -74,6 +74,6 @@ public function testTranslation(): void */ public function testHolidayType(): void { - $this->assertHolidayType(self::REGION, self::HOLIDAY, $this->generateRandomYear(), Holiday::TYPE_OTHER); + $this->assertHolidayType(self::REGION, self::HOLIDAY, $this->generateRandomYear(), Holiday::TYPE_OFFICIAL); } } diff --git a/tests/Germany/Bavaria/BavariaTest.php b/tests/Germany/Bavaria/BavariaTest.php index de32705eb..213ad5025 100644 --- a/tests/Germany/Bavaria/BavariaTest.php +++ b/tests/Germany/Bavaria/BavariaTest.php @@ -44,6 +44,7 @@ public function testOfficialHolidays(): void { $this->assertDefinedHolidays([ 'newYearsDay', + 'epiphany', 'goodFriday', 'easterMonday', 'internationalWorkersDay', @@ -87,7 +88,7 @@ public function testBankHolidays(): void public function testOtherHolidays(): void { $this->assertDefinedHolidays( - ['epiphany'], + [], self::REGION, $this->year, Holiday::TYPE_OTHER diff --git a/tests/Germany/Bavaria/EpiphanyTest.php b/tests/Germany/Bavaria/EpiphanyTest.php index c3f909c0d..d9085e38c 100644 --- a/tests/Germany/Bavaria/EpiphanyTest.php +++ b/tests/Germany/Bavaria/EpiphanyTest.php @@ -74,6 +74,6 @@ public function testTranslation(): void */ public function testHolidayType(): void { - $this->assertHolidayType(self::REGION, self::HOLIDAY, $this->generateRandomYear(), Holiday::TYPE_OTHER); + $this->assertHolidayType(self::REGION, self::HOLIDAY, $this->generateRandomYear(), Holiday::TYPE_OFFICIAL); } } diff --git a/tests/Germany/SaxonyAnhalt/EpiphanyTest.php b/tests/Germany/SaxonyAnhalt/EpiphanyTest.php index 5af23f22a..a1ae96a95 100644 --- a/tests/Germany/SaxonyAnhalt/EpiphanyTest.php +++ b/tests/Germany/SaxonyAnhalt/EpiphanyTest.php @@ -74,6 +74,6 @@ public function testTranslation(): void */ public function testHolidayType(): void { - $this->assertHolidayType(self::REGION, self::HOLIDAY, $this->generateRandomYear(), Holiday::TYPE_OTHER); + $this->assertHolidayType(self::REGION, self::HOLIDAY, $this->generateRandomYear(), Holiday::TYPE_OFFICIAL); } } diff --git a/tests/Germany/SaxonyAnhalt/SaxonyAnhaltTest.php b/tests/Germany/SaxonyAnhalt/SaxonyAnhaltTest.php index 0662f0272..71c95be57 100644 --- a/tests/Germany/SaxonyAnhalt/SaxonyAnhaltTest.php +++ b/tests/Germany/SaxonyAnhalt/SaxonyAnhaltTest.php @@ -44,6 +44,7 @@ public function testOfficialHolidays(): void { $holidays = [ 'newYearsDay', + 'epiphany', 'goodFriday', 'easterMonday', 'internationalWorkersDay', @@ -93,7 +94,7 @@ public function testBankHolidays(): void */ public function testOtherHolidays(): void { - $this->assertDefinedHolidays(['epiphany'], self::REGION, $this->year, Holiday::TYPE_OTHER); + $this->assertDefinedHolidays([], self::REGION, $this->year, Holiday::TYPE_OTHER); } /** From 5c39dde098a817b22d3d331550c24e439562967a Mon Sep 17 00:00:00 2001 From: FuzzyWuzzyFraggle <113988045+FuzzyWuzzyFraggle@users.noreply.github.com> Date: Tue, 27 Dec 2022 21:57:22 +1100 Subject: [PATCH 083/142] Add National Day of Mourning for Australia (#288) * Add national Day of Mourning for Australia Co-authored-by: Kurt Ravn --- CHANGELOG.md | 1 + src/Yasumi/Provider/Australia.php | 29 +++++ tests/Australia/AustraliaTest.php | 10 +- .../AustralianCapitalTerritoryTest.php | 10 +- .../NationalDayOfMourningTest.php | 22 ++++ tests/Australia/NationalDayOfMourningTest.php | 111 ++++++++++++++++++ .../NationalDayOfMourningTest.php | 22 ++++ .../NewSouthWales/NewSouthWalesTest.php | 10 +- .../NationalDayOfMourningTest.php | 22 ++++ .../NorthernTerritoryTest.php | 10 +- .../Queensland/Brisbane/BrisbaneTest.php | 8 +- .../Brisbane/NationalDayOfMourningTest.php | 22 ++++ .../Queensland/NationalDayOfMourningTest.php | 22 ++++ tests/Australia/Queensland/QueenslandTest.php | 8 +- .../NationalDayOfMourningTest.php | 22 ++++ .../SouthAustralia/SouthAustraliaTest.php | 8 +- .../CentralNorth/CentralNorthTest.php | 8 +- .../NationalDayOfMourningTest.php | 22 ++++ .../FlindersIsland/FlindersIslandTest.php | 8 +- .../NationalDayOfMourningTest.php | 22 ++++ .../Tasmania/KingIsland/KingIslandTest.php | 8 +- .../KingIsland/NationalDayOfMourningTest.php | 22 ++++ .../Tasmania/NationalDayOfMourningTest.php | 22 ++++ .../Northeast/NationalDayOfMourningTest.php | 22 ++++ .../Tasmania/Northeast/NortheastTest.php | 8 +- .../CircularHead/CircularHeadTest.php | 8 +- .../NationalDayOfMourningTest.php | 22 ++++ .../Northwest/NationalDayOfMourningTest.php | 22 ++++ .../Tasmania/Northwest/NorthwestTest.php | 8 +- .../South/NationalDayOfMourningTest.php | 22 ++++ tests/Australia/Tasmania/South/SouthTest.php | 8 +- .../Southeast/NationalDayOfMourningTest.php | 22 ++++ .../South/Southeast/SoutheastTest.php | 8 +- tests/Australia/Tasmania/TasmaniaTest.php | 8 +- .../Victoria/NationalDayOfMourningTest.php | 22 ++++ tests/Australia/Victoria/VictoriaTest.php | 8 +- .../NationalDayOfMourningTest.php | 22 ++++ .../WesternAustralia/WesternAustraliaTest.php | 8 +- 38 files changed, 631 insertions(+), 36 deletions(-) create mode 100644 tests/Australia/AustralianCapitalTerritory/NationalDayOfMourningTest.php create mode 100644 tests/Australia/NationalDayOfMourningTest.php create mode 100644 tests/Australia/NewSouthWales/NationalDayOfMourningTest.php create mode 100644 tests/Australia/NorthernTerritory/NationalDayOfMourningTest.php create mode 100644 tests/Australia/Queensland/Brisbane/NationalDayOfMourningTest.php create mode 100644 tests/Australia/Queensland/NationalDayOfMourningTest.php create mode 100644 tests/Australia/SouthAustralia/NationalDayOfMourningTest.php create mode 100644 tests/Australia/Tasmania/CentralNorth/NationalDayOfMourningTest.php create mode 100644 tests/Australia/Tasmania/FlindersIsland/NationalDayOfMourningTest.php create mode 100644 tests/Australia/Tasmania/KingIsland/NationalDayOfMourningTest.php create mode 100644 tests/Australia/Tasmania/NationalDayOfMourningTest.php create mode 100644 tests/Australia/Tasmania/Northeast/NationalDayOfMourningTest.php create mode 100644 tests/Australia/Tasmania/Northwest/CircularHead/NationalDayOfMourningTest.php create mode 100644 tests/Australia/Tasmania/Northwest/NationalDayOfMourningTest.php create mode 100644 tests/Australia/Tasmania/South/NationalDayOfMourningTest.php create mode 100644 tests/Australia/Tasmania/South/Southeast/NationalDayOfMourningTest.php create mode 100644 tests/Australia/Victoria/NationalDayOfMourningTest.php create mode 100644 tests/Australia/WesternAustralia/NationalDayOfMourningTest.php diff --git a/CHANGELOG.md b/CHANGELOG.md index 5b32297a8..f22c5b9dc 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -12,6 +12,7 @@ to [Semantic Versioning](https://semver.org). - Added all examples as shown on the documentation site as a convenience to developers who like to have all information in a single place. - Added bank holiday for Queen Elizabeth II’s State Funeral on 19 September 2022 to United Kingdom +- Added Public Holiday National Day of Mourning (for Queen Elizabeth II) on 22 September 2022 to Australia ### Changed diff --git a/src/Yasumi/Provider/Australia.php b/src/Yasumi/Provider/Australia.php index 4494ae9ad..f717f2d21 100644 --- a/src/Yasumi/Provider/Australia.php +++ b/src/Yasumi/Provider/Australia.php @@ -47,6 +47,7 @@ public function initialize(): void $this->calculateNewYearHolidays(); $this->calculateAustraliaDay(); $this->calculateAnzacDay(); + $this->calculateNationalDayOfMourning(); // Add Christian holidays $this->addHoliday($this->goodFriday($this->year, $this->timezone, $this->locale)); @@ -202,6 +203,34 @@ private function calculateAnzacDay(): void } } + /** + * National Day of Mourning. + * + * An additional, once off, national public holiday was proclaimed on the 10th of September 2022, to be observed on the 22nd of September 2022, as a + * National day of mourning for the passing of Queen Elizabeth II + * + * @see https://www.pm.gov.au/media/commemorating-her-majesty-queen-elizabeth-ii + * @see https://www.timeanddate.com/holidays/australia/national-day-of-mourning + * + * @throws \InvalidArgumentException + * @throws UnknownLocaleException + * @throws \Exception + */ + private function calculateNationalDayOfMourning(): void + { + if (2022 !== $this->year) { + return; + } + + $this->addHoliday(new Holiday( + 'nationalDayOfMourning', + ['en' => 'National Day of Mourning'], + new DateTime("$this->year-9-22", DateTimeZoneFactory::getDateTimeZone($this->timezone)), + $this->locale, + Holiday::TYPE_OFFICIAL + )); + } + /** * Christmas Day / Boxing Day. * diff --git a/tests/Australia/AustraliaTest.php b/tests/Australia/AustraliaTest.php index 6717418ef..fd8edf95c 100644 --- a/tests/Australia/AustraliaTest.php +++ b/tests/Australia/AustraliaTest.php @@ -42,7 +42,7 @@ protected function setUp(): void */ public function testOfficialHolidays(): void { - $this->assertDefinedHolidays([ + $expectedHolidays = [ 'newYearsDay', 'goodFriday', 'easterMonday', @@ -50,7 +50,13 @@ public function testOfficialHolidays(): void 'secondChristmasDay', 'australiaDay', 'anzacDay', - ], $this->region, $this->year, Holiday::TYPE_OFFICIAL); + ]; + + if (2022 == $this->year) { + $expectedHolidays[] = 'nationalDayOfMourning'; + } + + $this->assertDefinedHolidays($expectedHolidays, $this->region, $this->year, Holiday::TYPE_OFFICIAL); } /** diff --git a/tests/Australia/AustralianCapitalTerritory/AustralianCapitalTerritoryTest.php b/tests/Australia/AustralianCapitalTerritory/AustralianCapitalTerritoryTest.php index f892b3802..db5cff015 100644 --- a/tests/Australia/AustralianCapitalTerritory/AustralianCapitalTerritoryTest.php +++ b/tests/Australia/AustralianCapitalTerritory/AustralianCapitalTerritoryTest.php @@ -42,7 +42,7 @@ protected function setUp(): void */ public function testOfficialHolidays(): void { - $this->assertDefinedHolidays([ + $expectedHolidays = [ 'newYearsDay', 'goodFriday', 'easterMonday', @@ -56,7 +56,13 @@ public function testOfficialHolidays(): void 'labourDay', 'canberraDay', 'reconciliationDay', - ], $this->region, $this->year, Holiday::TYPE_OFFICIAL); + ]; + + if (2022 == $this->year) { + $expectedHolidays[] = 'nationalDayOfMourning'; + } + + $this->assertDefinedHolidays($expectedHolidays, $this->region, $this->year, Holiday::TYPE_OFFICIAL); } /** diff --git a/tests/Australia/AustralianCapitalTerritory/NationalDayOfMourningTest.php b/tests/Australia/AustralianCapitalTerritory/NationalDayOfMourningTest.php new file mode 100644 index 000000000..68d57b5b5 --- /dev/null +++ b/tests/Australia/AustralianCapitalTerritory/NationalDayOfMourningTest.php @@ -0,0 +1,22 @@ + + */ + +namespace Yasumi\tests\Australia\AustralianCapitalTerritory; + +/** + * Class for testing National Day of Mourning in Australian Capital Territory (Australia).. + */ +class NationalDayOfMourningTest extends \Yasumi\tests\Australia\NationalDayOfMourningTest +{ +} diff --git a/tests/Australia/NationalDayOfMourningTest.php b/tests/Australia/NationalDayOfMourningTest.php new file mode 100644 index 000000000..1bbffce4b --- /dev/null +++ b/tests/Australia/NationalDayOfMourningTest.php @@ -0,0 +1,111 @@ + + */ + +namespace Yasumi\tests\Australia; + +use DateTime; +use DateTimeZone; +use Exception; +use Yasumi\Holiday; +use Yasumi\tests\HolidayTestCase; + +/** + * Class for testing National Day of Mourning in Australia. + */ +class NationalDayOfMourningTest extends AustraliaBaseTestCase implements HolidayTestCase +{ + /** + * The name of the holiday. + */ + public const HOLIDAY = 'nationalDayOfMourning'; + + /** + * The year in which the holiday was first established. + */ + public const ACTIVE_YEAR = 2022; + + /** + * The date on which the holiday occurred. + */ + public const ACTIVE_DATE = '2022-9-22'; + + /** + * Tests the holiday defined in this test. + * + * @throws Exception + */ + public function testHoliday(): void + { + $this->assertHoliday( + $this->region, + self::HOLIDAY, + self::ACTIVE_YEAR, + new DateTime(self::ACTIVE_DATE, new DateTimeZone($this->timezone)) + ); + } + + /** + * Tests the holiday defined in this test before the year in which it occurred. + * + * @throws Exception + */ + public function testHolidayBeforeActive(): void + { + $this->assertNotHoliday( + $this->region, + self::HOLIDAY, + $this->generateRandomYear(1000, self::ACTIVE_YEAR - 1) + ); + } + + /** + * Tests the holiday defined in this test after the year in which it occurred. + * + * @throws Exception + */ + public function testHolidayAfterActive(): void + { + $this->assertNotHoliday( + $this->region, + self::HOLIDAY, + $this->generateRandomYear(self::ACTIVE_YEAR + 1) + ); + } + + /** + * Tests the translated name of the holiday defined in this test. + */ + public function testTranslation(): void + { + $this->assertTranslatedHolidayName( + $this->region, + self::HOLIDAY, + self::ACTIVE_YEAR, + [self::LOCALE => 'National Day of Mourning'] + ); + } + + /** + * Tests type of the holiday defined in this test. + */ + public function testHolidayType(): void + { + $this->assertHolidayType( + $this->region, + self::HOLIDAY, + self::ACTIVE_YEAR, + Holiday::TYPE_OFFICIAL + ); + } +} diff --git a/tests/Australia/NewSouthWales/NationalDayOfMourningTest.php b/tests/Australia/NewSouthWales/NationalDayOfMourningTest.php new file mode 100644 index 000000000..3e657b683 --- /dev/null +++ b/tests/Australia/NewSouthWales/NationalDayOfMourningTest.php @@ -0,0 +1,22 @@ + + */ + +namespace Yasumi\tests\Australia\NewSouthWales; + +/** + * Class for testing National Day of Mourning in New South Wales (Australia).. + */ +class NationalDayOfMourningTest extends \Yasumi\tests\Australia\NationalDayOfMourningTest +{ +} diff --git a/tests/Australia/NewSouthWales/NewSouthWalesTest.php b/tests/Australia/NewSouthWales/NewSouthWalesTest.php index 85b790a86..132381933 100644 --- a/tests/Australia/NewSouthWales/NewSouthWalesTest.php +++ b/tests/Australia/NewSouthWales/NewSouthWalesTest.php @@ -42,7 +42,7 @@ protected function setUp(): void */ public function testOfficialHolidays(): void { - $this->assertDefinedHolidays([ + $holidays = [ 'newYearsDay', 'goodFriday', 'easterMonday', @@ -54,7 +54,13 @@ public function testOfficialHolidays(): void 'easterSaturday', 'queensBirthday', 'labourDay', - ], $this->region, $this->year, Holiday::TYPE_OFFICIAL); + ]; + + if (2022 == $this->year) { + $holidays[] = 'nationalDayOfMourning'; + } + + $this->assertDefinedHolidays($holidays, $this->region, $this->year, Holiday::TYPE_OFFICIAL); } /** diff --git a/tests/Australia/NorthernTerritory/NationalDayOfMourningTest.php b/tests/Australia/NorthernTerritory/NationalDayOfMourningTest.php new file mode 100644 index 000000000..3b5026b43 --- /dev/null +++ b/tests/Australia/NorthernTerritory/NationalDayOfMourningTest.php @@ -0,0 +1,22 @@ + + */ + +namespace Yasumi\tests\Australia\NorthernTerritory; + +/** + * Class for testing National Day of Mourning in Northern Territory (Australia).. + */ +class NationalDayOfMourningTest extends \Yasumi\tests\Australia\NationalDayOfMourningTest +{ +} diff --git a/tests/Australia/NorthernTerritory/NorthernTerritoryTest.php b/tests/Australia/NorthernTerritory/NorthernTerritoryTest.php index 86b91e69c..ffdcd9e57 100644 --- a/tests/Australia/NorthernTerritory/NorthernTerritoryTest.php +++ b/tests/Australia/NorthernTerritory/NorthernTerritoryTest.php @@ -42,7 +42,7 @@ protected function setUp(): void */ public function testOfficialHolidays(): void { - $this->assertDefinedHolidays([ + $expectedHolidays = [ 'newYearsDay', 'goodFriday', 'easterMonday', @@ -54,7 +54,13 @@ public function testOfficialHolidays(): void 'queensBirthday', 'mayDay', 'picnicDay', - ], $this->region, $this->year, Holiday::TYPE_OFFICIAL); + ]; + + if (2022 == $this->year) { + $expectedHolidays[] = 'nationalDayOfMourning'; + } + + $this->assertDefinedHolidays($expectedHolidays, $this->region, $this->year, Holiday::TYPE_OFFICIAL); } /** diff --git a/tests/Australia/Queensland/Brisbane/BrisbaneTest.php b/tests/Australia/Queensland/Brisbane/BrisbaneTest.php index dcfc4088d..3ae9abf1b 100644 --- a/tests/Australia/Queensland/Brisbane/BrisbaneTest.php +++ b/tests/Australia/Queensland/Brisbane/BrisbaneTest.php @@ -42,7 +42,7 @@ protected function setUp(): void */ public function testOfficialHolidays(): void { - $this->assertDefinedHolidays([ + $expectedHolidays = [ 'newYearsDay', 'goodFriday', 'easterMonday', @@ -53,7 +53,11 @@ public function testOfficialHolidays(): void 'queensBirthday', 'labourDay', 'peoplesDay', - ], $this->region, $this->year, Holiday::TYPE_OFFICIAL); + ]; + if (2022 == $this->year) { + $expectedHolidays[] = 'nationalDayOfMourning'; + } + $this->assertDefinedHolidays($expectedHolidays, $this->region, $this->year, Holiday::TYPE_OFFICIAL); } /** diff --git a/tests/Australia/Queensland/Brisbane/NationalDayOfMourningTest.php b/tests/Australia/Queensland/Brisbane/NationalDayOfMourningTest.php new file mode 100644 index 000000000..92994c361 --- /dev/null +++ b/tests/Australia/Queensland/Brisbane/NationalDayOfMourningTest.php @@ -0,0 +1,22 @@ + + */ + +namespace Yasumi\tests\Australia\Queensland\Brisbane; + +/** + * Class for testing National Day of Mourning in Brisbane (Australia).. + */ +class NationalDayOfMourningTest extends \Yasumi\tests\Australia\Queensland\NationalDayOfMourningTest +{ +} diff --git a/tests/Australia/Queensland/NationalDayOfMourningTest.php b/tests/Australia/Queensland/NationalDayOfMourningTest.php new file mode 100644 index 000000000..8e0c98e57 --- /dev/null +++ b/tests/Australia/Queensland/NationalDayOfMourningTest.php @@ -0,0 +1,22 @@ + + */ + +namespace Yasumi\tests\Australia\Queensland; + +/** + * Class for testing National Day of Mourning in Queensland (Australia).. + */ +class NationalDayOfMourningTest extends \Yasumi\tests\Australia\NationalDayOfMourningTest +{ +} diff --git a/tests/Australia/Queensland/QueenslandTest.php b/tests/Australia/Queensland/QueenslandTest.php index fd5a2a6ab..fd4df7f22 100644 --- a/tests/Australia/Queensland/QueenslandTest.php +++ b/tests/Australia/Queensland/QueenslandTest.php @@ -42,7 +42,7 @@ protected function setUp(): void */ public function testOfficialHolidays(): void { - $this->assertDefinedHolidays([ + $expectedHolidays = [ 'newYearsDay', 'goodFriday', 'easterMonday', @@ -52,7 +52,11 @@ public function testOfficialHolidays(): void 'anzacDay', 'queensBirthday', 'labourDay', - ], $this->region, $this->year, Holiday::TYPE_OFFICIAL); + ]; + if (2022 == $this->year) { + $expectedHolidays[] = 'nationalDayOfMourning'; + } + $this->assertDefinedHolidays($expectedHolidays, $this->region, $this->year, Holiday::TYPE_OFFICIAL); } /** diff --git a/tests/Australia/SouthAustralia/NationalDayOfMourningTest.php b/tests/Australia/SouthAustralia/NationalDayOfMourningTest.php new file mode 100644 index 000000000..2a5ca8ce5 --- /dev/null +++ b/tests/Australia/SouthAustralia/NationalDayOfMourningTest.php @@ -0,0 +1,22 @@ + + */ + +namespace Yasumi\tests\Australia\SouthAustralia; + +/** + * Class for testing National Day of Mourning in South Australia (Australia).. + */ +class NationalDayOfMourningTest extends \Yasumi\tests\Australia\NationalDayOfMourningTest +{ +} diff --git a/tests/Australia/SouthAustralia/SouthAustraliaTest.php b/tests/Australia/SouthAustralia/SouthAustraliaTest.php index e42e8b046..ef94641ac 100644 --- a/tests/Australia/SouthAustralia/SouthAustraliaTest.php +++ b/tests/Australia/SouthAustralia/SouthAustraliaTest.php @@ -42,7 +42,7 @@ protected function setUp(): void */ public function testOfficialHolidays(): void { - $this->assertDefinedHolidays([ + $expectedHolidays = [ 'newYearsDay', 'goodFriday', 'easterMonday', @@ -54,7 +54,11 @@ public function testOfficialHolidays(): void 'queensBirthday', 'labourDay', 'adelaideCup', - ], $this->region, $this->year, Holiday::TYPE_OFFICIAL); + ]; + if (2022 == $this->year) { + $expectedHolidays[] = 'nationalDayOfMourning'; + } + $this->assertDefinedHolidays($expectedHolidays, $this->region, $this->year, Holiday::TYPE_OFFICIAL); } /** diff --git a/tests/Australia/Tasmania/CentralNorth/CentralNorthTest.php b/tests/Australia/Tasmania/CentralNorth/CentralNorthTest.php index 533138c9c..342f54a73 100644 --- a/tests/Australia/Tasmania/CentralNorth/CentralNorthTest.php +++ b/tests/Australia/Tasmania/CentralNorth/CentralNorthTest.php @@ -42,7 +42,7 @@ protected function setUp(): void */ public function testOfficialHolidays(): void { - $this->assertDefinedHolidays([ + $expectedHolidays = [ 'newYearsDay', 'goodFriday', 'easterMonday', @@ -54,7 +54,11 @@ public function testOfficialHolidays(): void 'eightHourDay', 'recreationDay', 'devonportShow', - ], $this->region, $this->year, Holiday::TYPE_OFFICIAL); + ]; + if (2022 == $this->year) { + $expectedHolidays[] = 'nationalDayOfMourning'; + } + $this->assertDefinedHolidays($expectedHolidays, $this->region, $this->year, Holiday::TYPE_OFFICIAL); } /** diff --git a/tests/Australia/Tasmania/CentralNorth/NationalDayOfMourningTest.php b/tests/Australia/Tasmania/CentralNorth/NationalDayOfMourningTest.php new file mode 100644 index 000000000..96c6e4455 --- /dev/null +++ b/tests/Australia/Tasmania/CentralNorth/NationalDayOfMourningTest.php @@ -0,0 +1,22 @@ + + */ + +namespace Yasumi\tests\Australia\Tasmania\CentralNorth; + +/** + * Class for testing National Day of Mourning in central north Tasmania (Australia).. + */ +class NationalDayOfMourningTest extends \Yasumi\tests\Australia\Tasmania\NationalDayOfMourningTest +{ +} diff --git a/tests/Australia/Tasmania/FlindersIsland/FlindersIslandTest.php b/tests/Australia/Tasmania/FlindersIsland/FlindersIslandTest.php index 78f438b26..d2ef9122b 100644 --- a/tests/Australia/Tasmania/FlindersIsland/FlindersIslandTest.php +++ b/tests/Australia/Tasmania/FlindersIsland/FlindersIslandTest.php @@ -42,7 +42,7 @@ protected function setUp(): void */ public function testOfficialHolidays(): void { - $this->assertDefinedHolidays([ + $expectedHolidays = [ 'newYearsDay', 'goodFriday', 'easterMonday', @@ -54,7 +54,11 @@ public function testOfficialHolidays(): void 'eightHourDay', 'recreationDay', 'flindersIslandShow', - ], $this->region, $this->year, Holiday::TYPE_OFFICIAL); + ]; + if (2022 == $this->year) { + $expectedHolidays[] = 'nationalDayOfMourning'; + } + $this->assertDefinedHolidays($expectedHolidays, $this->region, $this->year, Holiday::TYPE_OFFICIAL); } /** diff --git a/tests/Australia/Tasmania/FlindersIsland/NationalDayOfMourningTest.php b/tests/Australia/Tasmania/FlindersIsland/NationalDayOfMourningTest.php new file mode 100644 index 000000000..b3be192b0 --- /dev/null +++ b/tests/Australia/Tasmania/FlindersIsland/NationalDayOfMourningTest.php @@ -0,0 +1,22 @@ + + */ + +namespace Yasumi\tests\Australia\Tasmania\FlindersIsland; + +/** + * Class for testing National Day of Mourning in Flinders Island (Australia).. + */ +class NationalDayOfMourningTest extends \Yasumi\tests\Australia\Tasmania\NationalDayOfMourningTest +{ +} diff --git a/tests/Australia/Tasmania/KingIsland/KingIslandTest.php b/tests/Australia/Tasmania/KingIsland/KingIslandTest.php index 2e9175a67..b5d8fcd72 100644 --- a/tests/Australia/Tasmania/KingIsland/KingIslandTest.php +++ b/tests/Australia/Tasmania/KingIsland/KingIslandTest.php @@ -42,7 +42,7 @@ protected function setUp(): void */ public function testOfficialHolidays(): void { - $this->assertDefinedHolidays([ + $expectedHolidays = [ 'newYearsDay', 'goodFriday', 'easterMonday', @@ -54,7 +54,11 @@ public function testOfficialHolidays(): void 'eightHourDay', 'recreationDay', 'kingIslandShow', - ], $this->region, $this->year, Holiday::TYPE_OFFICIAL); + ]; + if (2022 == $this->year) { + $expectedHolidays[] = 'nationalDayOfMourning'; + } + $this->assertDefinedHolidays($expectedHolidays, $this->region, $this->year, Holiday::TYPE_OFFICIAL); } /** diff --git a/tests/Australia/Tasmania/KingIsland/NationalDayOfMourningTest.php b/tests/Australia/Tasmania/KingIsland/NationalDayOfMourningTest.php new file mode 100644 index 000000000..8f68e4ae9 --- /dev/null +++ b/tests/Australia/Tasmania/KingIsland/NationalDayOfMourningTest.php @@ -0,0 +1,22 @@ + + */ + +namespace Yasumi\tests\Australia\Tasmania\KingIsland; + +/** + * Class for testing National Day of Mourning in King Island (Australia).. + */ +class NationalDayOfMourningTest extends \Yasumi\tests\Australia\Tasmania\NationalDayOfMourningTest +{ +} diff --git a/tests/Australia/Tasmania/NationalDayOfMourningTest.php b/tests/Australia/Tasmania/NationalDayOfMourningTest.php new file mode 100644 index 000000000..f2a4892ab --- /dev/null +++ b/tests/Australia/Tasmania/NationalDayOfMourningTest.php @@ -0,0 +1,22 @@ + + */ + +namespace Yasumi\tests\Australia\Tasmania; + +/** + * Class for testing National Day of Mourning in Tasmania (Australia).. + */ +class NationalDayOfMourningTest extends \Yasumi\tests\Australia\NationalDayOfMourningTest +{ +} diff --git a/tests/Australia/Tasmania/Northeast/NationalDayOfMourningTest.php b/tests/Australia/Tasmania/Northeast/NationalDayOfMourningTest.php new file mode 100644 index 000000000..c0536189c --- /dev/null +++ b/tests/Australia/Tasmania/Northeast/NationalDayOfMourningTest.php @@ -0,0 +1,22 @@ + + */ + +namespace Yasumi\tests\Australia\Tasmania\Northeast; + +/** + * Class for testing National Day of Mourning in northeastern Tasmania (Australia).. + */ +class NationalDayOfMourningTest extends \Yasumi\tests\Australia\Tasmania\NationalDayOfMourningTest +{ +} diff --git a/tests/Australia/Tasmania/Northeast/NortheastTest.php b/tests/Australia/Tasmania/Northeast/NortheastTest.php index 50c96a6ca..acd2fe776 100644 --- a/tests/Australia/Tasmania/Northeast/NortheastTest.php +++ b/tests/Australia/Tasmania/Northeast/NortheastTest.php @@ -42,7 +42,7 @@ protected function setUp(): void */ public function testOfficialHolidays(): void { - $this->assertDefinedHolidays([ + $expectedHolidays = [ 'newYearsDay', 'goodFriday', 'easterMonday', @@ -54,7 +54,11 @@ public function testOfficialHolidays(): void 'eightHourDay', 'recreationDay', 'launcestonShow', - ], $this->region, $this->year, Holiday::TYPE_OFFICIAL); + ]; + if (2022 == $this->year) { + $expectedHolidays[] = 'nationalDayOfMourning'; + } + $this->assertDefinedHolidays($expectedHolidays, $this->region, $this->year, Holiday::TYPE_OFFICIAL); } /** diff --git a/tests/Australia/Tasmania/Northwest/CircularHead/CircularHeadTest.php b/tests/Australia/Tasmania/Northwest/CircularHead/CircularHeadTest.php index 4c2d1d13d..713b544ea 100644 --- a/tests/Australia/Tasmania/Northwest/CircularHead/CircularHeadTest.php +++ b/tests/Australia/Tasmania/Northwest/CircularHead/CircularHeadTest.php @@ -41,7 +41,7 @@ protected function setUp(): void */ public function testOfficialHolidays(): void { - $this->assertDefinedHolidays([ + $expectedHolidays = [ 'newYearsDay', 'goodFriday', 'easterMonday', @@ -54,6 +54,10 @@ public function testOfficialHolidays(): void 'recreationDay', 'burnieShow', 'agfest', - ], $this->region, $this->year, Holiday::TYPE_OFFICIAL); + ]; + if (2022 == $this->year) { + $expectedHolidays[] = 'nationalDayOfMourning'; + } + $this->assertDefinedHolidays($expectedHolidays, $this->region, $this->year, Holiday::TYPE_OFFICIAL); } } diff --git a/tests/Australia/Tasmania/Northwest/CircularHead/NationalDayOfMourningTest.php b/tests/Australia/Tasmania/Northwest/CircularHead/NationalDayOfMourningTest.php new file mode 100644 index 000000000..6f7f919bb --- /dev/null +++ b/tests/Australia/Tasmania/Northwest/CircularHead/NationalDayOfMourningTest.php @@ -0,0 +1,22 @@ + + */ + +namespace Yasumi\tests\Australia\Tasmania\Northwest\CircularHead; + +/** + * Class for testing National Day of Mourning in Circular Head (Australia).. + */ +class NationalDayOfMourningTest extends \Yasumi\tests\Australia\Tasmania\Northwest\NationalDayOfMourningTest +{ +} diff --git a/tests/Australia/Tasmania/Northwest/NationalDayOfMourningTest.php b/tests/Australia/Tasmania/Northwest/NationalDayOfMourningTest.php new file mode 100644 index 000000000..4f29fe33c --- /dev/null +++ b/tests/Australia/Tasmania/Northwest/NationalDayOfMourningTest.php @@ -0,0 +1,22 @@ + + */ + +namespace Yasumi\tests\Australia\Tasmania\Northwest; + +/** + * Class for testing National Day of Mourning in northwestern Tasmania (Australia).. + */ +class NationalDayOfMourningTest extends \Yasumi\tests\Australia\Tasmania\NationalDayOfMourningTest +{ +} diff --git a/tests/Australia/Tasmania/Northwest/NorthwestTest.php b/tests/Australia/Tasmania/Northwest/NorthwestTest.php index d23c9e3b2..6e78273f5 100644 --- a/tests/Australia/Tasmania/Northwest/NorthwestTest.php +++ b/tests/Australia/Tasmania/Northwest/NorthwestTest.php @@ -42,7 +42,7 @@ protected function setUp(): void */ public function testOfficialHolidays(): void { - $this->assertDefinedHolidays([ + $expectedHolidays = [ 'newYearsDay', 'goodFriday', 'easterMonday', @@ -54,7 +54,11 @@ public function testOfficialHolidays(): void 'eightHourDay', 'recreationDay', 'burnieShow', - ], $this->region, $this->year, Holiday::TYPE_OFFICIAL); + ]; + if (2022 == $this->year) { + $expectedHolidays[] = 'nationalDayOfMourning'; + } + $this->assertDefinedHolidays($expectedHolidays, $this->region, $this->year, Holiday::TYPE_OFFICIAL); } /** diff --git a/tests/Australia/Tasmania/South/NationalDayOfMourningTest.php b/tests/Australia/Tasmania/South/NationalDayOfMourningTest.php new file mode 100644 index 000000000..d967d135e --- /dev/null +++ b/tests/Australia/Tasmania/South/NationalDayOfMourningTest.php @@ -0,0 +1,22 @@ + + */ + +namespace Yasumi\tests\Australia\Tasmania\South; + +/** + * Class for testing National Day of Mourning in southern Tasmania (Australia).. + */ +class NationalDayOfMourningTest extends \Yasumi\tests\Australia\Tasmania\NationalDayOfMourningTest +{ +} diff --git a/tests/Australia/Tasmania/South/SouthTest.php b/tests/Australia/Tasmania/South/SouthTest.php index a113a66b0..5c52b9880 100644 --- a/tests/Australia/Tasmania/South/SouthTest.php +++ b/tests/Australia/Tasmania/South/SouthTest.php @@ -42,7 +42,7 @@ protected function setUp(): void */ public function testOfficialHolidays(): void { - $this->assertDefinedHolidays([ + $expectedHolidays = [ 'newYearsDay', 'goodFriday', 'easterMonday', @@ -54,7 +54,11 @@ public function testOfficialHolidays(): void 'eightHourDay', 'recreationDay', 'hobartShow', - ], $this->region, $this->year, Holiday::TYPE_OFFICIAL); + ]; + if (2022 == $this->year) { + $expectedHolidays[] = 'nationalDayOfMourning'; + } + $this->assertDefinedHolidays($expectedHolidays, $this->region, $this->year, Holiday::TYPE_OFFICIAL); } /** diff --git a/tests/Australia/Tasmania/South/Southeast/NationalDayOfMourningTest.php b/tests/Australia/Tasmania/South/Southeast/NationalDayOfMourningTest.php new file mode 100644 index 000000000..1ccfaac0e --- /dev/null +++ b/tests/Australia/Tasmania/South/Southeast/NationalDayOfMourningTest.php @@ -0,0 +1,22 @@ + + */ + +namespace Yasumi\tests\Australia\Tasmania\South\Southeast; + +/** + * Class for testing National Day of Mourning in southeastern Tasmania (Australia).. + */ +class NationalDayOfMourningTest extends \Yasumi\tests\Australia\Tasmania\South\NationalDayOfMourningTest +{ +} diff --git a/tests/Australia/Tasmania/South/Southeast/SoutheastTest.php b/tests/Australia/Tasmania/South/Southeast/SoutheastTest.php index abc999e9a..430dfdac9 100644 --- a/tests/Australia/Tasmania/South/Southeast/SoutheastTest.php +++ b/tests/Australia/Tasmania/South/Southeast/SoutheastTest.php @@ -41,7 +41,7 @@ protected function setUp(): void */ public function testOfficialHolidays(): void { - $this->assertDefinedHolidays([ + $expectedHolidays = [ 'newYearsDay', 'goodFriday', 'easterMonday', @@ -53,6 +53,10 @@ public function testOfficialHolidays(): void 'eightHourDay', 'hobartShow', 'hobartRegatta', - ], $this->region, $this->year, Holiday::TYPE_OFFICIAL); + ]; + if (2022 == $this->year) { + $expectedHolidays[] = 'nationalDayOfMourning'; + } + $this->assertDefinedHolidays($expectedHolidays, $this->region, $this->year, Holiday::TYPE_OFFICIAL); } } diff --git a/tests/Australia/Tasmania/TasmaniaTest.php b/tests/Australia/Tasmania/TasmaniaTest.php index 15eb83217..9699a3843 100644 --- a/tests/Australia/Tasmania/TasmaniaTest.php +++ b/tests/Australia/Tasmania/TasmaniaTest.php @@ -42,7 +42,7 @@ protected function setUp(): void */ public function testOfficialHolidays(): void { - $this->assertDefinedHolidays([ + $expectedHolidays = [ 'newYearsDay', 'goodFriday', 'easterMonday', @@ -53,7 +53,11 @@ public function testOfficialHolidays(): void 'queensBirthday', 'eightHourDay', 'recreationDay', - ], $this->region, $this->year, Holiday::TYPE_OFFICIAL); + ]; + if (2022 == $this->year) { + $expectedHolidays[] = 'nationalDayOfMourning'; + } + $this->assertDefinedHolidays($expectedHolidays, $this->region, $this->year, Holiday::TYPE_OFFICIAL); } /** diff --git a/tests/Australia/Victoria/NationalDayOfMourningTest.php b/tests/Australia/Victoria/NationalDayOfMourningTest.php new file mode 100644 index 000000000..f41ddd1d3 --- /dev/null +++ b/tests/Australia/Victoria/NationalDayOfMourningTest.php @@ -0,0 +1,22 @@ + + */ + +namespace Yasumi\tests\Australia\Victoria; + +/** + * Class for testing National Day of Mourning in Victoria (Australia).. + */ +class NationalDayOfMourningTest extends \Yasumi\tests\Australia\NationalDayOfMourningTest +{ +} diff --git a/tests/Australia/Victoria/VictoriaTest.php b/tests/Australia/Victoria/VictoriaTest.php index bdc4a752f..0f2290f0e 100644 --- a/tests/Australia/Victoria/VictoriaTest.php +++ b/tests/Australia/Victoria/VictoriaTest.php @@ -42,7 +42,7 @@ protected function setUp(): void */ public function testOfficialHolidays(): void { - $this->assertDefinedHolidays([ + $expectedHolidays = [ 'newYearsDay', 'goodFriday', 'easterMonday', @@ -56,7 +56,11 @@ public function testOfficialHolidays(): void 'labourDay', 'aflGrandFinalFriday', 'melbourneCup', - ], $this->region, $this->year, Holiday::TYPE_OFFICIAL); + ]; + if (2022 == $this->year) { + $expectedHolidays[] = 'nationalDayOfMourning'; + } + $this->assertDefinedHolidays($expectedHolidays, $this->region, $this->year, Holiday::TYPE_OFFICIAL); } /** diff --git a/tests/Australia/WesternAustralia/NationalDayOfMourningTest.php b/tests/Australia/WesternAustralia/NationalDayOfMourningTest.php new file mode 100644 index 000000000..38fdba9d6 --- /dev/null +++ b/tests/Australia/WesternAustralia/NationalDayOfMourningTest.php @@ -0,0 +1,22 @@ + + */ + +namespace Yasumi\tests\Australia\WesternAustralia; + +/** + * Class for testing National Day of Mourning in Western Australia (Australia).. + */ +class NationalDayOfMourningTest extends \Yasumi\tests\Australia\NationalDayOfMourningTest +{ +} diff --git a/tests/Australia/WesternAustralia/WesternAustraliaTest.php b/tests/Australia/WesternAustralia/WesternAustraliaTest.php index 7ccce6489..853a3b594 100644 --- a/tests/Australia/WesternAustralia/WesternAustraliaTest.php +++ b/tests/Australia/WesternAustralia/WesternAustraliaTest.php @@ -42,7 +42,7 @@ protected function setUp(): void */ public function testOfficialHolidays(): void { - $this->assertDefinedHolidays([ + $expectedHolidays = [ 'newYearsDay', 'goodFriday', 'easterMonday', @@ -53,7 +53,11 @@ public function testOfficialHolidays(): void 'queensBirthday', 'labourDay', 'westernAustraliaDay', - ], $this->region, $this->year, Holiday::TYPE_OFFICIAL); + ]; + if (2022 == $this->year) { + $expectedHolidays[] = 'nationalDayOfMourning'; + } + $this->assertDefinedHolidays($expectedHolidays, $this->region, $this->year, Holiday::TYPE_OFFICIAL); } /** From 766676d74d8e5e4d43387a99f6979e92a5308744 Mon Sep 17 00:00:00 2001 From: Sacha Telgenhof Date: Tue, 27 Dec 2022 20:06:20 +0900 Subject: [PATCH 084/142] Fixed DateTime classes to be called from the global namespace. Signed-off-by: Sacha Telgenhof --- src/Yasumi/Provider/Australia.php | 2 +- tests/Australia/NationalDayOfMourningTest.php | 11 ++++------- 2 files changed, 5 insertions(+), 8 deletions(-) diff --git a/src/Yasumi/Provider/Australia.php b/src/Yasumi/Provider/Australia.php index f717f2d21..6035e20ce 100644 --- a/src/Yasumi/Provider/Australia.php +++ b/src/Yasumi/Provider/Australia.php @@ -225,7 +225,7 @@ private function calculateNationalDayOfMourning(): void $this->addHoliday(new Holiday( 'nationalDayOfMourning', ['en' => 'National Day of Mourning'], - new DateTime("$this->year-9-22", DateTimeZoneFactory::getDateTimeZone($this->timezone)), + new \DateTime("$this->year-9-22", DateTimeZoneFactory::getDateTimeZone($this->timezone)), $this->locale, Holiday::TYPE_OFFICIAL )); diff --git a/tests/Australia/NationalDayOfMourningTest.php b/tests/Australia/NationalDayOfMourningTest.php index 1bbffce4b..594f71ba9 100644 --- a/tests/Australia/NationalDayOfMourningTest.php +++ b/tests/Australia/NationalDayOfMourningTest.php @@ -14,9 +14,6 @@ namespace Yasumi\tests\Australia; -use DateTime; -use DateTimeZone; -use Exception; use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; @@ -43,7 +40,7 @@ class NationalDayOfMourningTest extends AustraliaBaseTestCase implements Holiday /** * Tests the holiday defined in this test. * - * @throws Exception + * @throws \Exception */ public function testHoliday(): void { @@ -51,14 +48,14 @@ public function testHoliday(): void $this->region, self::HOLIDAY, self::ACTIVE_YEAR, - new DateTime(self::ACTIVE_DATE, new DateTimeZone($this->timezone)) + new \DateTime(self::ACTIVE_DATE, new \DateTimeZone($this->timezone)) ); } /** * Tests the holiday defined in this test before the year in which it occurred. * - * @throws Exception + * @throws \Exception */ public function testHolidayBeforeActive(): void { @@ -72,7 +69,7 @@ public function testHolidayBeforeActive(): void /** * Tests the holiday defined in this test after the year in which it occurred. * - * @throws Exception + * @throws \Exception */ public function testHolidayAfterActive(): void { From 0d8d0613eb7acb8c7e1d27837932cf7006920f98 Mon Sep 17 00:00:00 2001 From: Alex Date: Tue, 27 Dec 2022 12:41:21 +0100 Subject: [PATCH 085/142] Switched from getShortName to getName for reflection class (#292) Co-authored-by: Alexander Bachmann --- CHANGELOG.md | 3 +++ src/Yasumi/Provider/AbstractProvider.php | 2 +- 2 files changed, 4 insertions(+), 1 deletion(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index f22c5b9dc..870c0561b 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -31,6 +31,9 @@ to [Semantic Versioning](https://semver.org). statistic analysers. - Included the data type for test methods that return an array. - Liberation day for the Netherlands is only an official holiday every 5 years [\#280](https://github.com/azuyalabs/yasumi/pull/280). +- Switched from `getShortName()` to `getName()` for the ReflectionClass created by the method `anotherTime()` in the `AbstractProvider`.\ + Using `getShortName` could result in a `ProviderNotFoundException` for some custom holiday providers, since the namespace is not fully qualified.\ + This happened, if you would create a custom holiday provider in your own project's namespace implementing the `next()` or `previous()` method from the `AbstractProvider`. ### Deprecated diff --git a/src/Yasumi/Provider/AbstractProvider.php b/src/Yasumi/Provider/AbstractProvider.php index 538059e34..741596d47 100644 --- a/src/Yasumi/Provider/AbstractProvider.php +++ b/src/Yasumi/Provider/AbstractProvider.php @@ -332,6 +332,6 @@ private function anotherTime(int $year, string $key): ?Holiday // Get calling class name $hReflectionClass = new \ReflectionClass(\get_class($this)); - return Yasumi::create($hReflectionClass->getShortName(), $year, $this->locale)->getHoliday($key); + return Yasumi::create($hReflectionClass->getName(), $year, $this->locale)->getHoliday($key); } } From 0a81bb484bb6d413de16519177e5478f668ec04c Mon Sep 17 00:00:00 2001 From: Sacha Telgenhof Date: Tue, 27 Dec 2022 21:40:31 +0900 Subject: [PATCH 086/142] Renamed SummerTime test to be consistent with the same of Denmark. Simplified the tests for summertime. Signed-off-by: Sacha Telgenhof --- .../{SummertimeTest.php => SummerTimeTest.php} | 18 ++++++++---------- 1 file changed, 8 insertions(+), 10 deletions(-) rename tests/Netherlands/{SummertimeTest.php => SummerTimeTest.php} (80%) diff --git a/tests/Netherlands/SummertimeTest.php b/tests/Netherlands/SummerTimeTest.php similarity index 80% rename from tests/Netherlands/SummertimeTest.php rename to tests/Netherlands/SummerTimeTest.php index b1404af9f..8f52ceb49 100644 --- a/tests/Netherlands/SummertimeTest.php +++ b/tests/Netherlands/SummerTimeTest.php @@ -20,7 +20,7 @@ /** * Class for testing Summertime in the Netherlands. */ -final class SummertimeTest extends DaylightSavingTime +final class SummerTimeTest extends DaylightSavingTime { /** The name of the holiday */ public const HOLIDAY = 'summerTime'; @@ -44,20 +44,18 @@ public function testSummertime(): void { $this->assertNotHoliday(self::REGION, self::HOLIDAY, $this->randomYearFromArray($this->unobservedYears)); - $year = $this->generateRandomYear(1977, 1980); - $this->assertHoliday( - self::REGION, - self::HOLIDAY, - $year, - new \DateTime("first sunday of april $year", new \DateTimeZone(self::TIMEZONE)) - ); + $year = $this->randomYearFromArray($this->observedYears); + $expected = "first sunday of april $year"; + + if ($year >= 1981) { + $expected = "last sunday of march $year"; + } - $year = $this->generateRandomYear(1981, 2037); $this->assertHoliday( self::REGION, self::HOLIDAY, $year, - new \DateTime("last sunday of march $year", new \DateTimeZone(self::TIMEZONE)) + new \DateTime($expected, new \DateTimeZone(self::TIMEZONE)) ); } From a81952d35030f2675543236d85e4db60c5f655d0 Mon Sep 17 00:00:00 2001 From: Tyler Shuster Date: Tue, 27 Dec 2022 16:12:41 -0800 Subject: [PATCH 087/142] Update Juneteenth with observed dates (#282) Co-authored-by: Sacha Telgenhof --- src/Yasumi/Provider/USA.php | 29 ++++++++++++++++++++++++++--- tests/USA/JuneteenthTest.php | 8 ++++---- 2 files changed, 30 insertions(+), 7 deletions(-) diff --git a/src/Yasumi/Provider/USA.php b/src/Yasumi/Provider/USA.php index f291630ef..10d1c511e 100644 --- a/src/Yasumi/Provider/USA.php +++ b/src/Yasumi/Provider/USA.php @@ -159,9 +159,32 @@ private function calculateMemorialDay(): void private function calculateJuneteenth(): void { if ($this->year >= 2021) { - $this->addHoliday(new Holiday('juneteenth', [ - 'en' => 'Juneteenth', - ], new \DateTime("$this->year-6-19", DateTimeZoneFactory::getDateTimeZone($this->timezone)), $this->locale)); + $date = new DateTime("$this->year-6-19", DateTimeZoneFactory::getDateTimeZone($this->timezone)); + $label = 'Juneteenth'; + + $holiday = new Holiday('juneteenth', [ + 'en' => $label, + ], $date, $this->locale); + $this->addHoliday($holiday); + + $day_of_week = (int) $date->format('w'); + + if (0 === $day_of_week || 6 === $day_of_week) { + $date = clone $holiday; + if (0 === $day_of_week) { + $date->modify('next monday'); + } elseif (6 === $day_of_week) { + $date->modify('previous friday'); + } + $this->addHoliday(new SubstituteHoliday( + $holiday, + [ + 'en' => $label.' (observed)', + ], + $date, + $this->locale + )); + } } } diff --git a/tests/USA/JuneteenthTest.php b/tests/USA/JuneteenthTest.php index 740278dbc..fde4c0df3 100644 --- a/tests/USA/JuneteenthTest.php +++ b/tests/USA/JuneteenthTest.php @@ -56,9 +56,9 @@ public function testJuneteenthOnAfter2021(): void public function testJuneteenthOnAfter2021SubstitutedMonday(): void { $year = 2022; - $this->assertHoliday( + $this->assertSubstituteHoliday( self::REGION, - 'substituteHoliday:juneteenth', + self::HOLIDAY, $year, new \DateTime("$year-6-20", new \DateTimeZone(self::TIMEZONE)) ); @@ -72,9 +72,9 @@ public function testJuneteenthOnAfter2021SubstitutedMonday(): void public function testJuneteenthOnAfter2021SubstitutedFriday(): void { $year = 2021; - $this->assertHoliday( + $this->assertSubstituteHoliday( self::REGION, - 'substituteHoliday:juneteenth', + self::HOLIDAY, $year, new \DateTime("$year-6-18", new \DateTimeZone(self::TIMEZONE)) ); From 0c65c1ac171d2f5e23de391777308c2d5c0ebeb2 Mon Sep 17 00:00:00 2001 From: Sacha Telgenhof Date: Wed, 28 Dec 2022 09:21:46 +0900 Subject: [PATCH 088/142] Fixed DateTime class use to be called from the global namespace. Signed-off-by: Sacha Telgenhof --- src/Yasumi/Provider/USA.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/Yasumi/Provider/USA.php b/src/Yasumi/Provider/USA.php index 10d1c511e..c3dd9d080 100644 --- a/src/Yasumi/Provider/USA.php +++ b/src/Yasumi/Provider/USA.php @@ -159,7 +159,7 @@ private function calculateMemorialDay(): void private function calculateJuneteenth(): void { if ($this->year >= 2021) { - $date = new DateTime("$this->year-6-19", DateTimeZoneFactory::getDateTimeZone($this->timezone)); + $date = new \DateTime("$this->year-6-19", DateTimeZoneFactory::getDateTimeZone($this->timezone)); $label = 'Juneteenth'; $holiday = new Holiday('juneteenth', [ From eae2c0e93cb955dd67d4f80be0fcabf666854592 Mon Sep 17 00:00:00 2001 From: Sacha Telgenhof Date: Wed, 28 Dec 2022 09:40:01 +0900 Subject: [PATCH 089/142] Removed redundant condition. Signed-off-by: Sacha Telgenhof --- src/Yasumi/Provider/USA.php | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/src/Yasumi/Provider/USA.php b/src/Yasumi/Provider/USA.php index c3dd9d080..470e7c21e 100644 --- a/src/Yasumi/Provider/USA.php +++ b/src/Yasumi/Provider/USA.php @@ -171,11 +171,12 @@ private function calculateJuneteenth(): void if (0 === $day_of_week || 6 === $day_of_week) { $date = clone $holiday; + $date->modify('previous friday'); + if (0 === $day_of_week) { $date->modify('next monday'); - } elseif (6 === $day_of_week) { - $date->modify('previous friday'); } + $this->addHoliday(new SubstituteHoliday( $holiday, [ From 111c2e6931b50d758923ca883aebbc15d83d29f4 Mon Sep 17 00:00:00 2001 From: Sacha Telgenhof Date: Wed, 28 Dec 2022 11:37:50 +0900 Subject: [PATCH 090/142] Added additional years that have the transition changed in tz version 2022f. In version 2022f of the tz db, corrections for some years were made for the summertime transitions. Signed-off-by: Sacha Telgenhof --- tests/Netherlands/DaylightSavingTime.php | 11 ++++ tests/Netherlands/SummerTimeTest.php | 66 +++++++++++++++++++++++- 2 files changed, 76 insertions(+), 1 deletion(-) diff --git a/tests/Netherlands/DaylightSavingTime.php b/tests/Netherlands/DaylightSavingTime.php index a9f552509..b194382d5 100644 --- a/tests/Netherlands/DaylightSavingTime.php +++ b/tests/Netherlands/DaylightSavingTime.php @@ -36,4 +36,15 @@ public function __construct() parent::__construct(); } + + /* Swaps the observation from observed to unobserved for the given years */ + protected function swapObservation(array $years): void + { + foreach ($years as $y) { + $this->observedYears[] = $y; + if (false !== ($key = array_search($y, $this->unobservedYears, true))) { + unset($this->unobservedYears[(int) $key]); + } + } + } } diff --git a/tests/Netherlands/SummerTimeTest.php b/tests/Netherlands/SummerTimeTest.php index 8f52ceb49..18cec4954 100644 --- a/tests/Netherlands/SummerTimeTest.php +++ b/tests/Netherlands/SummerTimeTest.php @@ -25,14 +25,66 @@ final class SummerTimeTest extends DaylightSavingTime /** The name of the holiday */ public const HOLIDAY = 'summerTime'; + /* List of transition dates that deviate from the known/defined rules. + * PHP derives the transition dates from the tz database which are + * different for some years */ + private array $deviantTransitions = [ + 1916 => '1916-04-30', + 1917 => '1917-04-16', + 1919 => '1919-04-07', + 1918 => '1918-04-01', + 1920 => '1920-04-05', + 1921 => '1921-04-04', + 1922 => '1922-03-26', + 1923 => '1923-06-01', + 1924 => '1924-03-30', + 1925 => '1925-06-05', + 1932 => '1932-05-22', + 1937 => '1937-05-22', + 1943 => '1943-03-29', + 1944 => '1944-04-03', + 1945 => '1945-04-02', + ]; + public function __construct() { parent::__construct(); - // no summertime defined for 1942 + // No summertime defined for 1942 if (false !== ($key = array_search(1942, $this->observedYears, true))) { unset($this->observedYears[(int) $key]); } + + // In version 2022f of the tz db, a correction for some years weere made for the summertime + // transitions. See: https://github.com/eggert/tz/blob/2022f/europe + if (1 === strcmp(\intltz_get_tz_data_version(), '2022f')) { + $this->swapObservation([1946]); + + $this->deviantTransitions[1918] = '1918-04-15'; + $this->deviantTransitions[1919] = '1919-03-01'; + $this->deviantTransitions[1920] = '1920-02-14'; + $this->deviantTransitions[1921] = '1921-03-14'; + $this->deviantTransitions[1922] = '1922-03-25'; + $this->deviantTransitions[1923] = '1923-04-21'; + $this->deviantTransitions[1924] = '1924-03-29'; + $this->deviantTransitions[1925] = '1925-04-04'; + $this->deviantTransitions[1926] = '1926-04-17'; + $this->deviantTransitions[1927] = '1927-04-09'; + $this->deviantTransitions[1928] = '1928-04-14'; + $this->deviantTransitions[1929] = '1929-04-21'; + $this->deviantTransitions[1931] = '1931-04-19'; + $this->deviantTransitions[1930] = '1930-04-13'; + $this->deviantTransitions[1932] = '1932-04-03'; + $this->deviantTransitions[1933] = '1933-03-26'; + $this->deviantTransitions[1934] = '1934-04-08'; + $this->deviantTransitions[1935] = '1935-03-31'; + $this->deviantTransitions[1936] = '1936-04-19'; + $this->deviantTransitions[1937] = '1937-04-04'; + $this->deviantTransitions[1938] = '1938-03-27'; + $this->deviantTransitions[1939] = '1939-04-16'; + $this->deviantTransitions[1940] = '1940-02-25'; + $this->deviantTransitions[1946] = '1946-05-19'; + } } /** @@ -47,10 +99,22 @@ public function testSummertime(): void $year = $this->randomYearFromArray($this->observedYears); $expected = "first sunday of april $year"; + if ($year >= 1923) { + $expected = "may 15th $year"; + } + + if ($year >= 1943) { + $expected = "first sunday of april $year"; + } + if ($year >= 1981) { $expected = "last sunday of march $year"; } + if (array_key_exists($year, $this->deviantTransitions)) { + $expected = $this->deviantTransitions[$year]; + } + $this->assertHoliday( self::REGION, self::HOLIDAY, From 790f320b3264836767bb85e130ab762e02043156 Mon Sep 17 00:00:00 2001 From: Sacha Telgenhof Date: Wed, 28 Dec 2022 11:48:50 +0900 Subject: [PATCH 091/142] Renamed WinterTime test to be consistent with the same tests of Denmark. Simplified some of the tests for wintertime. Signed-off-by: Sacha Telgenhof --- ...{WintertimeTest.php => WinterTimeTest.php} | 32 +++++++++++++------ 1 file changed, 22 insertions(+), 10 deletions(-) rename tests/Netherlands/{WintertimeTest.php => WinterTimeTest.php} (69%) diff --git a/tests/Netherlands/WintertimeTest.php b/tests/Netherlands/WinterTimeTest.php similarity index 69% rename from tests/Netherlands/WintertimeTest.php rename to tests/Netherlands/WinterTimeTest.php index f1704116f..5920727cd 100644 --- a/tests/Netherlands/WintertimeTest.php +++ b/tests/Netherlands/WinterTimeTest.php @@ -1,6 +1,7 @@ observedYears, true))) { unset($this->observedYears[(int) $key]); } + + // In version 2022f of the tz db, a correction for some years weere made for the wintertime + // transitions. See: https://github.com/eggert/tz/blob/2022f/europe + if (1 === strcmp(\intltz_get_tz_data_version(), '2022f')) { + $this->swapObservation([1946]); + } } /** @@ -42,21 +49,26 @@ public function __construct() public function testWintertime(): void { $this->assertNotHoliday(self::REGION, self::HOLIDAY, $this->randomYearFromArray($this->unobservedYears)); + $year = $this->randomYearFromArray($this->observedYears); + $expected = "last sunday of september $year"; - $year = $this->generateRandomYear(1979, 1995); - $this->assertHoliday( - self::REGION, - self::HOLIDAY, - $year, - new \DateTime("last sunday of september $year", new \DateTimeZone(self::TIMEZONE)) - ); + if ($year >= 1922) { + $expected = "first sunday of october $year"; + } + + if ($year >= 1977) { + $expected = "last sunday of september $year"; + } + + if ($year >= 1996) { + $expected = "last sunday of october $year"; + } - $year = $this->generateRandomYear(1996, 2037); $this->assertHoliday( self::REGION, self::HOLIDAY, $year, - new \DateTime("last sunday of october $year", new \DateTimeZone(self::TIMEZONE)) + new \DateTime($expected, new \DateTimeZone(self::TIMEZONE)) ); } From 1e18c59202a93b120834530eefcca7064775b311 Mon Sep 17 00:00:00 2001 From: Sacha Telgenhof Date: Wed, 28 Dec 2022 12:20:53 +0900 Subject: [PATCH 092/142] Added additional years that have the transition changed in tz version 2022f. In version 2022f of the tz db, corrections for some years were made for the wintertime transitions. Signed-off-by: Sacha Telgenhof --- tests/Netherlands/WinterTimeTest.php | 39 ++++++++++++++++++++++++++-- 1 file changed, 37 insertions(+), 2 deletions(-) diff --git a/tests/Netherlands/WinterTimeTest.php b/tests/Netherlands/WinterTimeTest.php index 5920727cd..bc838d1b2 100644 --- a/tests/Netherlands/WinterTimeTest.php +++ b/tests/Netherlands/WinterTimeTest.php @@ -25,11 +25,27 @@ final class WinterTimeTest extends DaylightSavingTime /** The name of the holiday */ public const HOLIDAY = 'winterTime'; + /* List of transition dates that deviate from the known/defined rules. + * PHP derives the transition dates from the tz database which are + * different for some years */ + private array $deviantTransitions = [ + 1916 => '1916-09-30', + 1917 => '1917-09-17', + 1922 => '1922-10-08', + 1933 => '1933-10-08', + 1939 => '1939-10-08', + 1942 => '1942-11-02', + 1943 => '1943-10-04', + 1944 => '1944-10-02', + 1945 => '1945-09-16', + 1978 => '1978-10-01', + ]; + public function __construct() { parent::__construct(); - // no wintertime defined for 1940 + // No wintertime defined for 1940 if (false !== ($key = array_search(1940, $this->observedYears, true))) { unset($this->observedYears[(int) $key]); } @@ -38,6 +54,20 @@ public function __construct() // transitions. See: https://github.com/eggert/tz/blob/2022f/europe if (1 === strcmp(\intltz_get_tz_data_version(), '2022f')) { $this->swapObservation([1946]); + + $this->deviantTransitions[1918] = '1918-09-16'; + $this->deviantTransitions[1919] = '1919-10-04'; + $this->deviantTransitions[1920] = '1920-10-23'; + $this->deviantTransitions[1921] = '1921-10-25'; + $this->deviantTransitions[1922] = '1922-10-07'; + $this->deviantTransitions[1923] = '1923-10-06'; + $this->deviantTransitions[1924] = '1924-10-04'; + $this->deviantTransitions[1925] = '1925-10-03'; + $this->deviantTransitions[1926] = '1926-10-02'; + $this->deviantTransitions[1927] = '1927-10-01'; + $this->deviantTransitions[1939] = '1939-11-19'; + $this->deviantTransitions[1944] = '1944-09-17'; + $this->deviantTransitions[1946] = '1946-10-07'; } } @@ -49,8 +79,9 @@ public function __construct() public function testWintertime(): void { $this->assertNotHoliday(self::REGION, self::HOLIDAY, $this->randomYearFromArray($this->unobservedYears)); + $year = $this->randomYearFromArray($this->observedYears); - $expected = "last sunday of september $year"; + $expected = "last monday of september $year"; if ($year >= 1922) { $expected = "first sunday of october $year"; @@ -64,6 +95,10 @@ public function testWintertime(): void $expected = "last sunday of october $year"; } + if (array_key_exists($year, $this->deviantTransitions)) { + $expected = $this->deviantTransitions[$year]; + } + $this->assertHoliday( self::REGION, self::HOLIDAY, From d57cc01bdda56a72497d615fbffb03595379d5e3 Mon Sep 17 00:00:00 2001 From: Sacha Telgenhof Date: Wed, 28 Dec 2022 12:24:17 +0900 Subject: [PATCH 093/142] Adjusted transition year check to be inline with the Wintertime conditions. Signed-off-by: Sacha Telgenhof --- tests/Netherlands/SummerTimeTest.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tests/Netherlands/SummerTimeTest.php b/tests/Netherlands/SummerTimeTest.php index 18cec4954..250ae1d4a 100644 --- a/tests/Netherlands/SummerTimeTest.php +++ b/tests/Netherlands/SummerTimeTest.php @@ -99,7 +99,7 @@ public function testSummertime(): void $year = $this->randomYearFromArray($this->observedYears); $expected = "first sunday of april $year"; - if ($year >= 1923) { + if ($year >= 1922) { $expected = "may 15th $year"; } From 0c49a1612fe541debeb9effa39ef7f9cd814b558 Mon Sep 17 00:00:00 2001 From: Sacha Telgenhof Date: Wed, 28 Dec 2022 14:05:41 +0900 Subject: [PATCH 094/142] Added rector rule to refactor code to use early returns (replacing compound conditions). Made code changes follow this new rule. Signed-off-by: Sacha Telgenhof --- rector.php | 1 + src/Yasumi/Provider/AbstractProvider.php | 6 ++- src/Yasumi/Provider/Croatia.php | 16 ++++-- src/Yasumi/Provider/SouthKorea.php | 60 +++++++++++++-------- src/Yasumi/Provider/Spain/BasqueCountry.php | 20 ++++--- src/Yasumi/Translations.php | 13 +++-- src/Yasumi/Yasumi.php | 11 +++- tests/NewZealand/AnzacDayTest.php | 10 +++- tests/NewZealand/WaitangiDayTest.php | 10 +++- 9 files changed, 104 insertions(+), 43 deletions(-) diff --git a/rector.php b/rector.php index b445a189c..0d94d4b15 100644 --- a/rector.php +++ b/rector.php @@ -20,6 +20,7 @@ SetList::PHP_74, SetList::CODE_QUALITY, SetList::TYPE_DECLARATION_STRICT, + SetList::EARLY_RETURN, SetList::DEAD_CODE, ]); }; diff --git a/src/Yasumi/Provider/AbstractProvider.php b/src/Yasumi/Provider/AbstractProvider.php index 741596d47..c596166aa 100644 --- a/src/Yasumi/Provider/AbstractProvider.php +++ b/src/Yasumi/Provider/AbstractProvider.php @@ -129,7 +129,11 @@ public function removeHoliday(string $key): void /** {@inheritdoc} */ public function isWorkingDay(\DateTimeInterface $date): bool { - return !$this->isHoliday($date) && !$this->isWeekendDay($date); + if ($this->isHoliday($date)) { + return false; + } + + return !$this->isWeekendDay($date); } /** {@inheritdoc} */ diff --git a/src/Yasumi/Provider/Croatia.php b/src/Yasumi/Provider/Croatia.php index 64465d76b..d1716239b 100644 --- a/src/Yasumi/Provider/Croatia.php +++ b/src/Yasumi/Provider/Croatia.php @@ -145,12 +145,18 @@ private function calculateHomelandThanksgivingDay(): void */ private function calculateIndependenceDay(): void { - if ($this->year >= 1991 && $this->year < 2020) { - $this->addHoliday(new Holiday('independenceDay', [ - 'en' => 'Independence Day', - 'hr' => 'Dan neovisnosti', - ], new \DateTime("$this->year-10-8", DateTimeZoneFactory::getDateTimeZone($this->timezone)), $this->locale)); + if ($this->year < 1991) { + return; } + + if ($this->year >= 2020) { + return; + } + + $this->addHoliday(new Holiday('independenceDay', [ + 'en' => 'Independence Day', + 'hr' => 'Dan neovisnosti', + ], new \DateTime("$this->year-10-8", DateTimeZoneFactory::getDateTimeZone($this->timezone)), $this->locale)); } /** diff --git a/src/Yasumi/Provider/SouthKorea.php b/src/Yasumi/Provider/SouthKorea.php index 7f8869763..51ea4f257 100644 --- a/src/Yasumi/Provider/SouthKorea.php +++ b/src/Yasumi/Provider/SouthKorea.php @@ -238,14 +238,20 @@ private function calculateSeollal(): void */ private function calculateBuddhasBirthday(): void { - if ($this->year >= 1975 && isset(self::LUNAR_HOLIDAY['buddhasBirthday'][$this->year])) { - $this->addHoliday(new Holiday( - 'buddhasBirthday', - ['en' => 'Buddha’s Birthday', 'ko' => '부처님오신날'], - new \DateTime(self::LUNAR_HOLIDAY['buddhasBirthday'][$this->year], DateTimeZoneFactory::getDateTimeZone($this->timezone)), - $this->locale - )); + if ($this->year < 1975) { + return; } + + if (!isset(self::LUNAR_HOLIDAY['buddhasBirthday'][$this->year])) { + return; + } + + $this->addHoliday(new Holiday( + 'buddhasBirthday', + ['en' => 'Buddha’s Birthday', 'ko' => '부처님오신날'], + new \DateTime(self::LUNAR_HOLIDAY['buddhasBirthday'][$this->year], DateTimeZoneFactory::getDateTimeZone($this->timezone)), + $this->locale + )); } /** @@ -380,14 +386,20 @@ private function calculateMemorialDay(): void */ private function calculateConstitutionDay(): void { - if ($this->year >= 1949 && $this->year < 2008) { - $this->addHoliday(new Holiday( - 'constitutionDay', - ['en' => 'Constitution Day', 'ko' => '제헌절'], - new \DateTime("$this->year-7-17", DateTimeZoneFactory::getDateTimeZone($this->timezone)), - $this->locale - )); + if ($this->year < 1949) { + return; + } + + if ($this->year >= 2008) { + return; } + + $this->addHoliday(new Holiday( + 'constitutionDay', + ['en' => 'Constitution Day', 'ko' => '제헌절'], + new \DateTime("$this->year-7-17", DateTimeZoneFactory::getDateTimeZone($this->timezone)), + $this->locale + )); } /** @@ -418,14 +430,20 @@ private function calculateLiberationDay(): void */ private function calculateArmedForcesDay(): void { - if ($this->year >= 1956 && $this->year <= 1990) { - $this->addHoliday(new Holiday( - 'armedForcesDay', - ['en' => 'Armed Forces Day', 'ko' => '국군의 날'], - new \DateTime("$this->year-10-1", DateTimeZoneFactory::getDateTimeZone($this->timezone)), - $this->locale - )); + if ($this->year < 1956) { + return; + } + + if ($this->year > 1990) { + return; } + + $this->addHoliday(new Holiday( + 'armedForcesDay', + ['en' => 'Armed Forces Day', 'ko' => '국군의 날'], + new \DateTime("$this->year-10-1", DateTimeZoneFactory::getDateTimeZone($this->timezone)), + $this->locale + )); } /** diff --git a/src/Yasumi/Provider/Spain/BasqueCountry.php b/src/Yasumi/Provider/Spain/BasqueCountry.php index 955811f7a..7870d866e 100644 --- a/src/Yasumi/Provider/Spain/BasqueCountry.php +++ b/src/Yasumi/Provider/Spain/BasqueCountry.php @@ -78,13 +78,19 @@ public function initialize(): void */ private function calculateBasqueCountryDay(): void { - if ($this->year >= 2011 && $this->year <= 2013) { - $this->addHoliday(new Holiday( - 'basqueCountryDay', - ['es' => 'Euskadi Eguna'], - new \DateTime("$this->year-10-25", DateTimeZoneFactory::getDateTimeZone($this->timezone)), - $this->locale - )); + if ($this->year < 2011) { + return; } + + if ($this->year > 2013) { + return; + } + + $this->addHoliday(new Holiday( + 'basqueCountryDay', + ['es' => 'Euskadi Eguna'], + new \DateTime("$this->year-10-25", DateTimeZoneFactory::getDateTimeZone($this->timezone)), + $this->locale + )); } } diff --git a/src/Yasumi/Translations.php b/src/Yasumi/Translations.php index 6230f199e..d03eb546d 100644 --- a/src/Yasumi/Translations.php +++ b/src/Yasumi/Translations.php @@ -60,7 +60,11 @@ public function loadTranslations(string $directoryPath): void $extension = 'php'; foreach (new \DirectoryIterator($directoryPath) as $file) { - if ($file->isDot() || $file->isDir()) { + if ($file->isDot()) { + continue; + } + + if ($file->isDir()) { continue; } @@ -113,8 +117,11 @@ public function addTranslation(string $key, string $locale, string $translation) */ public function getTranslation(string $key, string $locale): ?string { - if (!\array_key_exists($key, $this->translations) - || !\array_key_exists($locale, $this->translations[$key])) { + if (!\array_key_exists($key, $this->translations)) { + return null; + } + + if (!\array_key_exists($locale, $this->translations[$key])) { return null; } diff --git a/src/Yasumi/Yasumi.php b/src/Yasumi/Yasumi.php index a68e30bea..e3778d8d6 100644 --- a/src/Yasumi/Yasumi.php +++ b/src/Yasumi/Yasumi.php @@ -221,14 +221,21 @@ public static function getProviders(): array ), \RecursiveIteratorIterator::SELF_FIRST); foreach ($filesIterator as $file) { - if ($file->isDir() || 'php' !== $file->getExtension() || \in_array( + if ($file->isDir()) { + continue; + } + + if ('php' !== $file->getExtension()) { + continue; + } + + if (\in_array( $file->getBasename('.php'), self::$ignoredProvider, true )) { continue; } - $quotedDs = preg_quote(DIRECTORY_SEPARATOR, ''); $provider = preg_replace("#^.+{$quotedDs}Provider$quotedDs(.+)\\.php$#", '$1', $file->getPathName()); diff --git a/tests/NewZealand/AnzacDayTest.php b/tests/NewZealand/AnzacDayTest.php index d9cf97cf5..6ff2d0be8 100644 --- a/tests/NewZealand/AnzacDayTest.php +++ b/tests/NewZealand/AnzacDayTest.php @@ -71,9 +71,15 @@ public function HolidayDataProvider(): array { return $this->generateRandomDatesWithModifier(4, 25, function ($year, \DateTime $date): void { // in 2015 some policy was introduced to make sure this holiday was celebrated during the working week. - if ($year >= 2015 && $this->isWeekend($date)) { - $date->modify('next monday'); + if ($year < 2015) { + return; } + + if (!$this->isWeekend($date)) { + return; + } + + $date->modify('next monday'); }, 100, self::ESTABLISHMENT_YEAR, self::TIMEZONE); } diff --git a/tests/NewZealand/WaitangiDayTest.php b/tests/NewZealand/WaitangiDayTest.php index 4db3a70ac..08f87682a 100644 --- a/tests/NewZealand/WaitangiDayTest.php +++ b/tests/NewZealand/WaitangiDayTest.php @@ -101,9 +101,15 @@ public function HolidayDataProvider(): array { return $this->generateRandomDatesWithModifier(2, 06, function ($year, \DateTime $date): void { // in 2015 some policy was introduced to make sure this holiday was celebrated during the working week. - if ($year >= 2015 && $this->isWeekend($date)) { - $date->modify('next monday'); + if ($year < 2015) { + return; } + + if (!$this->isWeekend($date)) { + return; + } + + $date->modify('next monday'); }, 100, self::ESTABLISHMENT_YEAR, self::TIMEZONE); } } From 50f4eefc372c923b74e175d4ba616df28cf83644 Mon Sep 17 00:00:00 2001 From: Sacha Telgenhof Date: Wed, 28 Dec 2022 14:20:46 +0900 Subject: [PATCH 095/142] Simplified some checks on empty arrays. Signed-off-by: Sacha Telgenhof --- src/Yasumi/Holiday.php | 2 +- src/Yasumi/Yasumi.php | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/src/Yasumi/Holiday.php b/src/Yasumi/Holiday.php index f65e705f9..f7d9fda44 100644 --- a/src/Yasumi/Holiday.php +++ b/src/Yasumi/Holiday.php @@ -115,7 +115,7 @@ public function __construct( } // Load internal locales variable - if (empty(self::$locales)) { + if ([] === self::$locales) { self::$locales = Yasumi::getAvailableLocales(); } diff --git a/src/Yasumi/Yasumi.php b/src/Yasumi/Yasumi.php index e3778d8d6..6dbc6ff42 100644 --- a/src/Yasumi/Yasumi.php +++ b/src/Yasumi/Yasumi.php @@ -137,7 +137,7 @@ public static function create(string $class, int $year = self::YEAR_LOWER_BOUND, } // Load internal locales variable - if (empty(self::$locales)) { + if ([] === self::$locales) { self::$locales = self::getAvailableLocales(); } From b2c178f58b586e0bc349d941d1dc87f2f628a955 Mon Sep 17 00:00:00 2001 From: Sacha Telgenhof Date: Wed, 28 Dec 2022 18:15:11 +0900 Subject: [PATCH 096/142] Replaced deprecated strict type rule. Updated annotations with missing possible null value. Signed-off-by: Sacha Telgenhof --- rector.php | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/rector.php b/rector.php index 0d94d4b15..45f0106d5 100644 --- a/rector.php +++ b/rector.php @@ -17,10 +17,10 @@ // sets of rules $rectorConfig->sets([ - SetList::PHP_74, SetList::CODE_QUALITY, - SetList::TYPE_DECLARATION_STRICT, - SetList::EARLY_RETURN, SetList::DEAD_CODE, + SetList::EARLY_RETURN, + SetList::PHP_74, + SetList::TYPE_DECLARATION, ]); }; From 5cf555c8eb06a4bcf3618e75191847026a6ecd12 Mon Sep 17 00:00:00 2001 From: Sacha Telgenhof Date: Wed, 28 Dec 2022 18:17:39 +0900 Subject: [PATCH 097/142] Updated annotations with missing possible null value. Code style formatting. Signed-off-by: Sacha Telgenhof --- src/Yasumi/Provider/DateTimeZoneFactory.php | 2 +- tests/Ukraine/SubstitutedHolidayTest.php | 10 +++++----- 2 files changed, 6 insertions(+), 6 deletions(-) diff --git a/src/Yasumi/Provider/DateTimeZoneFactory.php b/src/Yasumi/Provider/DateTimeZoneFactory.php index 9aead9d21..823b1309f 100644 --- a/src/Yasumi/Provider/DateTimeZoneFactory.php +++ b/src/Yasumi/Provider/DateTimeZoneFactory.php @@ -21,7 +21,7 @@ */ final class DateTimeZoneFactory { - /** @var array */ + /** @var array|null */ private static ?array $dateTimeZones = null; public static function getDateTimeZone(string $timezone): \DateTimeZone diff --git a/tests/Ukraine/SubstitutedHolidayTest.php b/tests/Ukraine/SubstitutedHolidayTest.php index c6c705ba4..6ba9c6846 100644 --- a/tests/Ukraine/SubstitutedHolidayTest.php +++ b/tests/Ukraine/SubstitutedHolidayTest.php @@ -51,11 +51,11 @@ public function testSaturdaySubstitution(): void /** * Asserts that the expected date is indeed a holiday for that given year and name. * - * @param string $provider the holiday provider (i.e. country/state) for which the holiday need to be tested - * @param string $key string the key of the holiday to be checked against - * @param int $year holiday calendar year - * @param \DateTimeInterface $expectedOfficial the official date to be checked against - * @param \DateTimeImmutable $expectedSubstitution the substituted date to be checked against + * @param string $provider the holiday provider (i.e. country/state) for which the holiday need to be tested + * @param string $key string the key of the holiday to be checked against + * @param int $year holiday calendar year + * @param \DateTimeInterface $expectedOfficial the official date to be checked against + * @param \DateTimeImmutable|null $expectedSubstitution the substituted date to be checked against */ public function assertHolidayWithSubstitution( string $provider, From f1c8855a9373e8137a5840dcc48a7eb7f6aca2e8 Mon Sep 17 00:00:00 2001 From: Sacha Telgenhof Date: Wed, 28 Dec 2022 21:09:18 +0900 Subject: [PATCH 098/142] In Japan, Marine Day was rescheduled to July 23 as the 2020 Tokyo Olypmics took place. The rescheduled Marine Day for 2021 was included, but not the original rescheduled day for 2020. Signed-off-by: Sacha Telgenhof --- CHANGELOG.md | 2 ++ src/Yasumi/Provider/Japan.php | 38 +++++++++++++++++++++-------------- tests/Japan/MarineDayTest.php | 34 +++++++++++++++++++++---------- 3 files changed, 48 insertions(+), 26 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 870c0561b..f0b762462 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -13,6 +13,8 @@ to [Semantic Versioning](https://semver.org). information in a single place. - Added bank holiday for Queen Elizabeth II’s State Funeral on 19 September 2022 to United Kingdom - Added Public Holiday National Day of Mourning (for Queen Elizabeth II) on 22 September 2022 to Australia +- In Japan, Marine Day was rescheduled to July 23 as the 2020 Tokyo Olypmics took place. The rescheduled Marine + Day for 2021 was included, but not the original rescheduled day for 2020. ### Changed diff --git a/src/Yasumi/Provider/Japan.php b/src/Yasumi/Provider/Japan.php index 1261a073f..e23d3f6fe 100644 --- a/src/Yasumi/Provider/Japan.php +++ b/src/Yasumi/Provider/Japan.php @@ -373,24 +373,32 @@ private function calculateGreeneryDay(): void */ private function calculateMarineDay(): void { - $date = null; - if (2021 === $this->year) { - // For Olympic 2021 Tokyo (rescheduled due to the COVID-19 pandemic) - $date = new \DateTime("$this->year-7-22", DateTimeZoneFactory::getDateTimeZone($this->timezone)); - } elseif ($this->year >= 2003) { - $date = new \DateTime("third monday of july $this->year", DateTimeZoneFactory::getDateTimeZone($this->timezone)); - } elseif ($this->year >= 1996) { - $date = new \DateTime("$this->year-7-20", DateTimeZoneFactory::getDateTimeZone($this->timezone)); + if (1996 > $this->year) { + return; } - if ($date instanceof \DateTimeInterface) { - $this->addHoliday(new Holiday( - 'marineDay', - ['en' => 'Marine Day', 'ja' => '海の日'], - $date, - $this->locale - )); + $date = "$this->year-7-20"; + + if ($this->year >= 2003) { + $date = "third monday of july $this->year"; + } + + if (2020 === $this->year) { + // For the 2020 Tokyo Olympics, Marine Day was rescheduled. + $date = "$this->year-7-23"; } + + if (2021 === $this->year) { + // Due to the COVID-19 pandemic, the 2020 Tokyo Olympics were rescheduled and hence Marine Day as well. + $date = "$this->year-7-22"; + } + + $this->addHoliday(new Holiday( + 'marineDay', + ['en' => 'Marine Day', 'ja' => '海の日'], + new \DateTime($date, DateTimeZoneFactory::getDateTimeZone($this->timezone)), + $this->locale + )); } /** diff --git a/tests/Japan/MarineDayTest.php b/tests/Japan/MarineDayTest.php index e200b5e51..d6617b8e3 100644 --- a/tests/Japan/MarineDayTest.php +++ b/tests/Japan/MarineDayTest.php @@ -17,24 +17,36 @@ use Yasumi\Holiday; use Yasumi\tests\HolidayTestCase; -/** - * Class for testing Marine Day in Japan. - */ -class MarineDayTest extends JapanBaseTestCase implements HolidayTestCase +final class MarineDayTest extends JapanBaseTestCase implements HolidayTestCase { - /** - * The name of the holiday. - */ public const HOLIDAY = 'marineDay'; + // The year in which the holiday was first established. + public const ESTABLISHMENT_YEAR = 1996; + /** - * The year in which the holiday was first established. + * Tests Marine Day in 2020. Marine Day in 2020 is July 23th for rescheduled Olympic Games after COVID-19. + * + * @see https://en.wikipedia.org/wiki/Marine_Day + * + * @throws \Exception */ - public const ESTABLISHMENT_YEAR = 1996; + public function testMarineDayIn2020(): void + { + $year = 2020; + $this->assertHoliday( + self::REGION, + self::HOLIDAY, + $year, + new \DateTime("$year-7-23", new \DateTimeZone(self::TIMEZONE)) + ); + } /** * Tests Marine Day in 2021. Marine Day in 2021 is July 22th for rescheduled Olympic Games after COVID-19. * + * @see https://en.wikipedia.org/wiki/Marine_Day + * * @throws \Exception */ public function testMarineDayIn2021(): void @@ -58,8 +70,8 @@ public function testMarineDayOnAfter2003(): void { $year = $this->generateRandomYear(2004); - if (2021 === $year) { - $this->testMarineDayIn2021(); + if (in_array($year, [2020, 2021])) { + return; } $this->assertHoliday( From d13248c449bdaf983af24e67af3ebfcd3f821e36 Mon Sep 17 00:00:00 2001 From: Sacha Telgenhof Date: Thu, 29 Dec 2022 16:57:31 +0900 Subject: [PATCH 099/142] Removed redundant type check as the date parameter is type-hinted. Signed-off-by: Sacha Telgenhof --- src/Yasumi/Yasumi.php | 6 ------ 1 file changed, 6 deletions(-) diff --git a/src/Yasumi/Yasumi.php b/src/Yasumi/Yasumi.php index 6dbc6ff42..710b4d915 100644 --- a/src/Yasumi/Yasumi.php +++ b/src/Yasumi/Yasumi.php @@ -81,9 +81,6 @@ public static function nextWorkingDay( while ($workingDays > 0) { $date = $date->add(new \DateInterval('P1D')); - if (!$date instanceof \DateTimeInterface) { - throw new \RuntimeException('unable to perform addition'); - } if (!$provider instanceof ProviderInterface) { $provider = self::create($class, (int) $date->format('Y')); @@ -281,9 +278,6 @@ public static function prevWorkingDay( while ($workingDays > 0) { $date = $date->sub(new \DateInterval('P1D')); - if (!$date instanceof \DateTimeInterface) { - throw new \RuntimeException('unable to perform subtraction'); - } if (!$provider instanceof ProviderInterface) { $provider = self::create($class, (int) $date->format('Y')); From 737b53f533598b366e5786ed59404450985ee604 Mon Sep 17 00:00:00 2001 From: Sacha Telgenhof Date: Thu, 29 Dec 2022 22:00:38 +0900 Subject: [PATCH 100/142] Exclude the examples from analysis. Signed-off-by: Sacha Telgenhof --- .phan/config.php | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/.phan/config.php b/.phan/config.php index dceda84d5..242a55d5c 100644 --- a/.phan/config.php +++ b/.phan/config.php @@ -291,7 +291,8 @@ // should be added to the `directory_list` as well as // to `exclude_analysis_directory_list`. 'exclude_analysis_directory_list' => [ - 'vendor/', + 'vendor/', + 'examples/' ], // Enable this to enable checks of require/include statements referring to valid paths. From 670f6ae073360fa07753887909325c46467ab28d Mon Sep 17 00:00:00 2001 From: Sacha Telgenhof Date: Sun, 1 Jan 2023 13:59:30 +0900 Subject: [PATCH 101/142] Updated copyright year. Signed-off-by: Sacha Telgenhof --- .php-cs-fixer.php | 2 +- LICENSE | 2 +- phpunit.xml.dist | 2 +- psalm.xml.dist | 2 +- src/Yasumi/Exception/Exception.php | 2 +- src/Yasumi/Exception/InvalidDateException.php | 2 +- src/Yasumi/Exception/InvalidYearException.php | 2 +- src/Yasumi/Exception/MissingTranslationException.php | 2 +- src/Yasumi/Exception/ProviderNotFoundException.php | 2 +- src/Yasumi/Exception/UnknownLocaleException.php | 2 +- src/Yasumi/Filters/AbstractFilter.php | 2 +- src/Yasumi/Filters/BankHolidaysFilter.php | 2 +- src/Yasumi/Filters/BetweenFilter.php | 2 +- src/Yasumi/Filters/ObservedHolidaysFilter.php | 2 +- src/Yasumi/Filters/OfficialHolidaysFilter.php | 2 +- src/Yasumi/Filters/OnFilter.php | 2 +- src/Yasumi/Filters/OtherHolidaysFilter.php | 2 +- src/Yasumi/Filters/SeasonalHolidaysFilter.php | 2 +- src/Yasumi/Holiday.php | 2 +- src/Yasumi/Provider/AbstractProvider.php | 2 +- src/Yasumi/Provider/Argentina.php | 2 +- src/Yasumi/Provider/Australia.php | 2 +- src/Yasumi/Provider/Australia/AustralianCapitalTerritory.php | 2 +- src/Yasumi/Provider/Australia/NewSouthWales.php | 2 +- src/Yasumi/Provider/Australia/NorthernTerritory.php | 2 +- src/Yasumi/Provider/Australia/Queensland.php | 2 +- src/Yasumi/Provider/Australia/Queensland/Brisbane.php | 2 +- src/Yasumi/Provider/Australia/SouthAustralia.php | 2 +- src/Yasumi/Provider/Australia/Tasmania.php | 2 +- src/Yasumi/Provider/Australia/Tasmania/CentralNorth.php | 2 +- src/Yasumi/Provider/Australia/Tasmania/FlindersIsland.php | 2 +- src/Yasumi/Provider/Australia/Tasmania/KingIsland.php | 2 +- src/Yasumi/Provider/Australia/Tasmania/Northeast.php | 2 +- src/Yasumi/Provider/Australia/Tasmania/Northwest.php | 2 +- .../Provider/Australia/Tasmania/Northwest/CircularHead.php | 2 +- src/Yasumi/Provider/Australia/Tasmania/South.php | 2 +- src/Yasumi/Provider/Australia/Tasmania/South/Southeast.php | 2 +- src/Yasumi/Provider/Australia/Victoria.php | 2 +- src/Yasumi/Provider/Australia/WesternAustralia.php | 2 +- src/Yasumi/Provider/Austria.php | 2 +- src/Yasumi/Provider/Austria/Burgenland.php | 2 +- src/Yasumi/Provider/Austria/Carinthia.php | 2 +- src/Yasumi/Provider/Austria/LowerAustria.php | 2 +- src/Yasumi/Provider/Austria/Salzburg.php | 2 +- src/Yasumi/Provider/Austria/Styria.php | 2 +- src/Yasumi/Provider/Austria/Tyrol.php | 2 +- src/Yasumi/Provider/Austria/UpperAustria.php | 2 +- src/Yasumi/Provider/Austria/Vienna.php | 2 +- src/Yasumi/Provider/Austria/Vorarlberg.php | 2 +- src/Yasumi/Provider/Belgium.php | 2 +- src/Yasumi/Provider/Bosnia.php | 2 +- src/Yasumi/Provider/Brazil.php | 2 +- src/Yasumi/Provider/Canada.php | 2 +- src/Yasumi/Provider/Canada/Alberta.php | 2 +- src/Yasumi/Provider/Canada/BritishColumbia.php | 2 +- src/Yasumi/Provider/Canada/Manitoba.php | 2 +- src/Yasumi/Provider/Canada/NewBrunswick.php | 2 +- src/Yasumi/Provider/Canada/NewfoundlandAndLabrador.php | 2 +- src/Yasumi/Provider/Canada/NorthwestTerritories.php | 2 +- src/Yasumi/Provider/Canada/NovaScotia.php | 2 +- src/Yasumi/Provider/Canada/Nunavut.php | 2 +- src/Yasumi/Provider/Canada/Ontario.php | 2 +- src/Yasumi/Provider/Canada/PrinceEdwardIsland.php | 2 +- src/Yasumi/Provider/Canada/Quebec.php | 2 +- src/Yasumi/Provider/Canada/Saskatchewan.php | 2 +- src/Yasumi/Provider/Canada/Yukon.php | 2 +- src/Yasumi/Provider/ChristianHolidays.php | 2 +- src/Yasumi/Provider/CommonHolidays.php | 2 +- src/Yasumi/Provider/Croatia.php | 2 +- src/Yasumi/Provider/CzechRepublic.php | 2 +- src/Yasumi/Provider/DateTimeZoneFactory.php | 2 +- src/Yasumi/Provider/Denmark.php | 2 +- src/Yasumi/Provider/Estonia.php | 2 +- src/Yasumi/Provider/Finland.php | 2 +- src/Yasumi/Provider/France.php | 2 +- src/Yasumi/Provider/France/BasRhin.php | 2 +- src/Yasumi/Provider/France/HautRhin.php | 2 +- src/Yasumi/Provider/France/Moselle.php | 2 +- src/Yasumi/Provider/Georgia.php | 2 +- src/Yasumi/Provider/Germany.php | 2 +- src/Yasumi/Provider/Germany/BadenWurttemberg.php | 2 +- src/Yasumi/Provider/Germany/Bavaria.php | 2 +- src/Yasumi/Provider/Germany/Berlin.php | 2 +- src/Yasumi/Provider/Germany/Brandenburg.php | 2 +- src/Yasumi/Provider/Germany/Bremen.php | 2 +- src/Yasumi/Provider/Germany/Hamburg.php | 2 +- src/Yasumi/Provider/Germany/Hesse.php | 2 +- src/Yasumi/Provider/Germany/LowerSaxony.php | 2 +- src/Yasumi/Provider/Germany/MecklenburgWesternPomerania.php | 2 +- src/Yasumi/Provider/Germany/NorthRhineWestphalia.php | 2 +- src/Yasumi/Provider/Germany/RhinelandPalatinate.php | 2 +- src/Yasumi/Provider/Germany/Saarland.php | 2 +- src/Yasumi/Provider/Germany/Saxony.php | 2 +- src/Yasumi/Provider/Germany/SaxonyAnhalt.php | 2 +- src/Yasumi/Provider/Germany/SchleswigHolstein.php | 2 +- src/Yasumi/Provider/Germany/Thuringia.php | 2 +- src/Yasumi/Provider/Greece.php | 2 +- src/Yasumi/Provider/Hungary.php | 2 +- src/Yasumi/Provider/Ireland.php | 2 +- src/Yasumi/Provider/Italy.php | 2 +- src/Yasumi/Provider/Japan.php | 2 +- src/Yasumi/Provider/Latvia.php | 2 +- src/Yasumi/Provider/Lithuania.php | 2 +- src/Yasumi/Provider/Luxembourg.php | 2 +- src/Yasumi/Provider/Netherlands.php | 2 +- src/Yasumi/Provider/NewZealand.php | 2 +- src/Yasumi/Provider/Norway.php | 2 +- src/Yasumi/Provider/Poland.php | 2 +- src/Yasumi/Provider/Portugal.php | 2 +- src/Yasumi/Provider/Romania.php | 2 +- src/Yasumi/Provider/Russia.php | 2 +- src/Yasumi/Provider/Slovakia.php | 2 +- src/Yasumi/Provider/SouthAfrica.php | 2 +- src/Yasumi/Provider/SouthKorea.php | 2 +- src/Yasumi/Provider/Spain.php | 2 +- src/Yasumi/Provider/Spain/Andalusia.php | 2 +- src/Yasumi/Provider/Spain/Aragon.php | 2 +- src/Yasumi/Provider/Spain/Asturias.php | 2 +- src/Yasumi/Provider/Spain/BalearicIslands.php | 2 +- src/Yasumi/Provider/Spain/BasqueCountry.php | 2 +- src/Yasumi/Provider/Spain/CanaryIslands.php | 2 +- src/Yasumi/Provider/Spain/Cantabria.php | 2 +- src/Yasumi/Provider/Spain/CastileAndLeon.php | 2 +- src/Yasumi/Provider/Spain/CastillaLaMancha.php | 2 +- src/Yasumi/Provider/Spain/Catalonia.php | 2 +- src/Yasumi/Provider/Spain/Ceuta.php | 2 +- src/Yasumi/Provider/Spain/CommunityOfMadrid.php | 2 +- src/Yasumi/Provider/Spain/Extremadura.php | 2 +- src/Yasumi/Provider/Spain/Galicia.php | 2 +- src/Yasumi/Provider/Spain/LaRioja.php | 2 +- src/Yasumi/Provider/Spain/Melilla.php | 2 +- src/Yasumi/Provider/Spain/Navarre.php | 2 +- src/Yasumi/Provider/Spain/RegionOfMurcia.php | 2 +- src/Yasumi/Provider/Spain/ValencianCommunity.php | 2 +- src/Yasumi/Provider/Sweden.php | 2 +- src/Yasumi/Provider/Switzerland.php | 2 +- src/Yasumi/Provider/Switzerland/Aargau.php | 2 +- src/Yasumi/Provider/Switzerland/AppenzellAusserrhoden.php | 2 +- src/Yasumi/Provider/Switzerland/AppenzellInnerrhoden.php | 2 +- src/Yasumi/Provider/Switzerland/BaselLandschaft.php | 2 +- src/Yasumi/Provider/Switzerland/BaselStadt.php | 2 +- src/Yasumi/Provider/Switzerland/Bern.php | 2 +- src/Yasumi/Provider/Switzerland/Fribourg.php | 2 +- src/Yasumi/Provider/Switzerland/Geneva.php | 2 +- src/Yasumi/Provider/Switzerland/Glarus.php | 2 +- src/Yasumi/Provider/Switzerland/Grisons.php | 2 +- src/Yasumi/Provider/Switzerland/Jura.php | 2 +- src/Yasumi/Provider/Switzerland/Lucerne.php | 2 +- src/Yasumi/Provider/Switzerland/Neuchatel.php | 2 +- src/Yasumi/Provider/Switzerland/Nidwalden.php | 2 +- src/Yasumi/Provider/Switzerland/Obwalden.php | 2 +- src/Yasumi/Provider/Switzerland/Schaffhausen.php | 2 +- src/Yasumi/Provider/Switzerland/Schwyz.php | 2 +- src/Yasumi/Provider/Switzerland/Solothurn.php | 2 +- src/Yasumi/Provider/Switzerland/StGallen.php | 2 +- src/Yasumi/Provider/Switzerland/Thurgau.php | 2 +- src/Yasumi/Provider/Switzerland/Ticino.php | 2 +- src/Yasumi/Provider/Switzerland/Uri.php | 2 +- src/Yasumi/Provider/Switzerland/Valais.php | 2 +- src/Yasumi/Provider/Switzerland/Vaud.php | 2 +- src/Yasumi/Provider/Switzerland/Zug.php | 2 +- src/Yasumi/Provider/Switzerland/Zurich.php | 2 +- src/Yasumi/Provider/Turkey.php | 2 +- src/Yasumi/Provider/USA.php | 2 +- src/Yasumi/Provider/Ukraine.php | 2 +- src/Yasumi/Provider/UnitedKingdom.php | 2 +- src/Yasumi/Provider/UnitedKingdom/England.php | 2 +- src/Yasumi/Provider/UnitedKingdom/NorthernIreland.php | 2 +- src/Yasumi/Provider/UnitedKingdom/Scotland.php | 2 +- src/Yasumi/Provider/UnitedKingdom/Wales.php | 2 +- src/Yasumi/ProviderInterface.php | 2 +- src/Yasumi/SubstituteHoliday.php | 2 +- src/Yasumi/Translations.php | 2 +- src/Yasumi/TranslationsInterface.php | 2 +- src/Yasumi/Yasumi.php | 2 +- src/Yasumi/data/locales.php | 2 +- src/Yasumi/data/translations/allSaintsDay.php | 2 +- src/Yasumi/data/translations/allSaintsEve.php | 2 +- src/Yasumi/data/translations/allSoulsDay.php | 2 +- src/Yasumi/data/translations/annunciation.php | 2 +- src/Yasumi/data/translations/anzacDay.php | 2 +- src/Yasumi/data/translations/armisticeDay.php | 2 +- src/Yasumi/data/translations/ascensionDay.php | 2 +- src/Yasumi/data/translations/ashWednesday.php | 2 +- src/Yasumi/data/translations/assumptionOfMary.php | 2 +- src/Yasumi/data/translations/australiaDay.php | 2 +- src/Yasumi/data/translations/canadaDay.php | 2 +- src/Yasumi/data/translations/carnationRevolutionDay.php | 2 +- src/Yasumi/data/translations/christmasDay.php | 2 +- src/Yasumi/data/translations/christmasEve.php | 2 +- src/Yasumi/data/translations/civicHoliday.php | 2 +- src/Yasumi/data/translations/corpusChristi.php | 2 +- src/Yasumi/data/translations/dayAfterNewYearsDay.php | 2 +- src/Yasumi/data/translations/dayOfLiberation.php | 2 +- src/Yasumi/data/translations/dayOfReformation.php | 2 +- src/Yasumi/data/translations/discoveryDay.php | 2 +- src/Yasumi/data/translations/easter.php | 2 +- src/Yasumi/data/translations/easterMonday.php | 2 +- src/Yasumi/data/translations/epiphany.php | 2 +- src/Yasumi/data/translations/epiphanyEve.php | 2 +- src/Yasumi/data/translations/familyDay.php | 2 +- src/Yasumi/data/translations/fathersDay.php | 2 +- src/Yasumi/data/translations/goldCupParadeDay.php | 2 +- src/Yasumi/data/translations/goodFriday.php | 2 +- src/Yasumi/data/translations/heritageDay.php | 2 +- src/Yasumi/data/translations/immaculateConception.php | 2 +- src/Yasumi/data/translations/internationalWomensDay.php | 2 +- src/Yasumi/data/translations/internationalWorkersDay.php | 2 +- src/Yasumi/data/translations/islanderDay.php | 2 +- src/Yasumi/data/translations/labourDay.php | 2 +- src/Yasumi/data/translations/louisRielDay.php | 2 +- src/Yasumi/data/translations/maundyThursday.php | 2 +- src/Yasumi/data/translations/mothersDay.php | 2 +- src/Yasumi/data/translations/natalHoliday.php | 2 +- src/Yasumi/data/translations/nationalIndigenousPeoplesDay.php | 2 +- src/Yasumi/data/translations/nationalPatriotsDay.php | 2 +- src/Yasumi/data/translations/newYearsDay.php | 2 +- src/Yasumi/data/translations/newYearsEve.php | 2 +- src/Yasumi/data/translations/novaScotiaHeritageDay.php | 2 +- src/Yasumi/data/translations/orangemensDay.php | 2 +- src/Yasumi/data/translations/pentecost.php | 2 +- src/Yasumi/data/translations/pentecostMonday.php | 2 +- src/Yasumi/data/translations/plebisciteDay.php | 2 +- src/Yasumi/data/translations/portugalDay.php | 2 +- src/Yasumi/data/translations/portugueseRepublicDay.php | 2 +- src/Yasumi/data/translations/queensBirthday.php | 2 +- src/Yasumi/data/translations/reformationDay.php | 2 +- src/Yasumi/data/translations/remembranceDay.php | 2 +- src/Yasumi/data/translations/restorationOfIndepence.php | 2 +- src/Yasumi/data/translations/saintJeanBaptisteDay.php | 2 +- src/Yasumi/data/translations/saskatchewanDay.php | 2 +- src/Yasumi/data/translations/secondChristmasDay.php | 2 +- src/Yasumi/data/translations/secondNewYearsDay.php | 2 +- src/Yasumi/data/translations/stAndrewsDay.php | 2 +- src/Yasumi/data/translations/stDavidsDay.php | 2 +- src/Yasumi/data/translations/stFloriansDay.php | 2 +- src/Yasumi/data/translations/stGeorgesDay.php | 2 +- src/Yasumi/data/translations/stJohnsDay.php | 2 +- src/Yasumi/data/translations/stJohnsEve.php | 2 +- src/Yasumi/data/translations/stJosephsDay.php | 2 +- src/Yasumi/data/translations/stLeopoldsDay.php | 2 +- src/Yasumi/data/translations/stMartinsDay.php | 2 +- src/Yasumi/data/translations/stRupertsDay.php | 2 +- src/Yasumi/data/translations/stStephensDay.php | 2 +- src/Yasumi/data/translations/substituteHoliday.php | 2 +- src/Yasumi/data/translations/summerTime.php | 2 +- src/Yasumi/data/translations/terryFoxDay.php | 2 +- src/Yasumi/data/translations/thanksgivingDay.php | 2 +- src/Yasumi/data/translations/truthAndReconciliationDay.php | 2 +- src/Yasumi/data/translations/valentinesDay.php | 2 +- src/Yasumi/data/translations/victoriaDay.php | 2 +- src/Yasumi/data/translations/victoryInEuropeDay.php | 2 +- src/Yasumi/data/translations/waitangiDay.php | 2 +- src/Yasumi/data/translations/walpurgisEve.php | 2 +- src/Yasumi/data/translations/winterTime.php | 2 +- src/Yasumi/data/translations/worldAnimalDay.php | 2 +- src/Yasumi/data/translations/yukonHeritageDay.php | 2 +- tests/Argentina/ArgentinaBaseTestCase.php | 2 +- tests/Argentina/ArgentinaTest.php | 2 +- tests/Argentina/CarnavalMondayTest.php | 2 +- tests/Argentina/CarnavalTuesdayTest.php | 2 +- tests/Argentina/ChristmasDayTest.php | 2 +- tests/Argentina/EasterTest.php | 2 +- tests/Argentina/FlagDayTest.php | 2 +- tests/Argentina/GeneralJoseSanMartinDayTest.php | 2 +- tests/Argentina/GeneralMartinMigueldeGuemesDayTest.php | 2 +- tests/Argentina/GoodFridayTest.php | 2 +- tests/Argentina/ImmaculateConceptionDayTest.php | 2 +- tests/Argentina/IndependenceDayTest.php | 2 +- tests/Argentina/InternationalWorkersDayTest.php | 2 +- tests/Argentina/MalvinasDayTest.php | 2 +- tests/Argentina/MayRevolutionTest.php | 2 +- tests/Argentina/NationalSovereigntyDayTest.php | 2 +- tests/Argentina/NewYearsDayTest.php | 2 +- tests/Argentina/RaceDayTest.php | 2 +- tests/Argentina/RemembranceDayTest.php | 2 +- tests/Australia/AnzacDayTest.php | 2 +- tests/Australia/AustraliaBaseTestCase.php | 2 +- tests/Australia/AustraliaDayTest.php | 2 +- tests/Australia/AustraliaTest.php | 2 +- tests/Australia/AustralianCapitalTerritory/AnzacDayTest.php | 2 +- tests/Australia/AustralianCapitalTerritory/AustraliaDayTest.php | 2 +- .../AustralianCapitalTerritoryBaseTestCase.php | 2 +- .../AustralianCapitalTerritoryTest.php | 2 +- tests/Australia/AustralianCapitalTerritory/BoxingDayTest.php | 2 +- tests/Australia/AustralianCapitalTerritory/CanberraDayTest.php | 2 +- tests/Australia/AustralianCapitalTerritory/ChristmasDayTest.php | 2 +- tests/Australia/AustralianCapitalTerritory/EasterMondayTest.php | 2 +- .../Australia/AustralianCapitalTerritory/EasterSaturdayTest.php | 2 +- tests/Australia/AustralianCapitalTerritory/EasterSundayTest.php | 2 +- tests/Australia/AustralianCapitalTerritory/GoodFridayTest.php | 2 +- tests/Australia/AustralianCapitalTerritory/LabourDayTest.php | 2 +- .../AustralianCapitalTerritory/NationalDayOfMourningTest.php | 2 +- tests/Australia/AustralianCapitalTerritory/NewYearsDayTest.php | 2 +- .../Australia/AustralianCapitalTerritory/QueensBirthdayTest.php | 2 +- .../AustralianCapitalTerritory/ReconciliationDayTest.php | 2 +- tests/Australia/BoxingDayTest.php | 2 +- tests/Australia/ChristmasDayTest.php | 2 +- tests/Australia/EasterMondayTest.php | 2 +- tests/Australia/GoodFridayTest.php | 2 +- tests/Australia/NationalDayOfMourningTest.php | 2 +- tests/Australia/NewSouthWales/AnzacDayTest.php | 2 +- tests/Australia/NewSouthWales/AustraliaDayTest.php | 2 +- tests/Australia/NewSouthWales/BankHolidayTest.php | 2 +- tests/Australia/NewSouthWales/BoxingDayTest.php | 2 +- tests/Australia/NewSouthWales/ChristmasDayTest.php | 2 +- tests/Australia/NewSouthWales/EasterMondayTest.php | 2 +- tests/Australia/NewSouthWales/EasterSaturdayTest.php | 2 +- tests/Australia/NewSouthWales/EasterSundayTest.php | 2 +- tests/Australia/NewSouthWales/GoodFridayTest.php | 2 +- tests/Australia/NewSouthWales/LabourDayTest.php | 2 +- tests/Australia/NewSouthWales/NationalDayOfMourningTest.php | 2 +- tests/Australia/NewSouthWales/NewSouthWalesBaseTestCase.php | 2 +- tests/Australia/NewSouthWales/NewSouthWalesTest.php | 2 +- tests/Australia/NewSouthWales/NewYearsDayTest.php | 2 +- tests/Australia/NewSouthWales/QueensBirthdayTest.php | 2 +- tests/Australia/NewYearsDayTest.php | 2 +- tests/Australia/NorthernTerritory/AnzacDayTest.php | 2 +- tests/Australia/NorthernTerritory/AustraliaDayTest.php | 2 +- tests/Australia/NorthernTerritory/BoxingDayTest.php | 2 +- tests/Australia/NorthernTerritory/ChristmasDayTest.php | 2 +- tests/Australia/NorthernTerritory/EasterMondayTest.php | 2 +- tests/Australia/NorthernTerritory/EasterSaturdayTest.php | 2 +- tests/Australia/NorthernTerritory/GoodFridayTest.php | 2 +- tests/Australia/NorthernTerritory/MayDayTest.php | 2 +- tests/Australia/NorthernTerritory/NationalDayOfMourningTest.php | 2 +- tests/Australia/NorthernTerritory/NewYearsDayTest.php | 2 +- .../NorthernTerritory/NorthernTerritoryBaseTestCase.php | 2 +- tests/Australia/NorthernTerritory/NorthernTerritoryTest.php | 2 +- tests/Australia/NorthernTerritory/PicnicDayTest.php | 2 +- tests/Australia/NorthernTerritory/QueensBirthdayTest.php | 2 +- tests/Australia/Queensland/AnzacDayTest.php | 2 +- tests/Australia/Queensland/AustraliaDayTest.php | 2 +- tests/Australia/Queensland/BoxingDayTest.php | 2 +- tests/Australia/Queensland/Brisbane/AnzacDayTest.php | 2 +- tests/Australia/Queensland/Brisbane/AustraliaDayTest.php | 2 +- tests/Australia/Queensland/Brisbane/BoxingDayTest.php | 2 +- tests/Australia/Queensland/Brisbane/BrisbaneBaseTestCase.php | 2 +- tests/Australia/Queensland/Brisbane/BrisbaneTest.php | 2 +- tests/Australia/Queensland/Brisbane/ChristmasDayTest.php | 2 +- tests/Australia/Queensland/Brisbane/EasterMondayTest.php | 2 +- tests/Australia/Queensland/Brisbane/GoodFridayTest.php | 2 +- tests/Australia/Queensland/Brisbane/LabourDayTest.php | 2 +- .../Australia/Queensland/Brisbane/NationalDayOfMourningTest.php | 2 +- tests/Australia/Queensland/Brisbane/NewYearsDayTest.php | 2 +- tests/Australia/Queensland/Brisbane/PeoplesDayTest.php | 2 +- tests/Australia/Queensland/Brisbane/QueensBirthdayTest.php | 2 +- tests/Australia/Queensland/ChristmasDayTest.php | 2 +- tests/Australia/Queensland/EasterMondayTest.php | 2 +- tests/Australia/Queensland/GoodFridayTest.php | 2 +- tests/Australia/Queensland/LabourDayTest.php | 2 +- tests/Australia/Queensland/NationalDayOfMourningTest.php | 2 +- tests/Australia/Queensland/NewYearsDayTest.php | 2 +- tests/Australia/Queensland/QueensBirthdayTest.php | 2 +- tests/Australia/Queensland/QueenslandBaseTestCase.php | 2 +- tests/Australia/Queensland/QueenslandTest.php | 2 +- tests/Australia/SouthAustralia/AdelaideCupDayTest.php | 2 +- tests/Australia/SouthAustralia/AnzacDayTest.php | 2 +- tests/Australia/SouthAustralia/AustraliaDayTest.php | 2 +- tests/Australia/SouthAustralia/ChristmasDayTest.php | 2 +- tests/Australia/SouthAustralia/EasterMondayTest.php | 2 +- tests/Australia/SouthAustralia/EasterSaturdayTest.php | 2 +- tests/Australia/SouthAustralia/GoodFridayTest.php | 2 +- tests/Australia/SouthAustralia/LabourDayTest.php | 2 +- tests/Australia/SouthAustralia/NationalDayOfMourningTest.php | 2 +- tests/Australia/SouthAustralia/NewYearsDayTest.php | 2 +- tests/Australia/SouthAustralia/ProclamationDayTest.php | 2 +- tests/Australia/SouthAustralia/QueensBirthdayTest.php | 2 +- tests/Australia/SouthAustralia/SouthAustraliaBaseTestCase.php | 2 +- tests/Australia/SouthAustralia/SouthAustraliaTest.php | 2 +- tests/Australia/Tasmania/AnzacDayTest.php | 2 +- tests/Australia/Tasmania/AustraliaDayTest.php | 2 +- tests/Australia/Tasmania/BoxingDayTest.php | 2 +- tests/Australia/Tasmania/CentralNorth/AnzacDayTest.php | 2 +- tests/Australia/Tasmania/CentralNorth/AustraliaDayTest.php | 2 +- tests/Australia/Tasmania/CentralNorth/BoxingDayTest.php | 2 +- .../Tasmania/CentralNorth/CentralNorthBaseTestCase.php | 2 +- tests/Australia/Tasmania/CentralNorth/CentralNorthTest.php | 2 +- tests/Australia/Tasmania/CentralNorth/ChristmasDayTest.php | 2 +- tests/Australia/Tasmania/CentralNorth/DevonportShowTest.php | 2 +- tests/Australia/Tasmania/CentralNorth/EasterMondayTest.php | 2 +- tests/Australia/Tasmania/CentralNorth/EightHourDayTest.php | 2 +- tests/Australia/Tasmania/CentralNorth/GoodFridayTest.php | 2 +- .../Tasmania/CentralNorth/NationalDayOfMourningTest.php | 2 +- tests/Australia/Tasmania/CentralNorth/NewYearsDayTest.php | 2 +- tests/Australia/Tasmania/CentralNorth/QueensBirthdayTest.php | 2 +- tests/Australia/Tasmania/CentralNorth/RecreationDayTest.php | 2 +- tests/Australia/Tasmania/ChristmasDayTest.php | 2 +- tests/Australia/Tasmania/EasterMondayTest.php | 2 +- tests/Australia/Tasmania/EightHourDayTest.php | 2 +- tests/Australia/Tasmania/FlindersIsland/AnzacDayTest.php | 2 +- tests/Australia/Tasmania/FlindersIsland/AustraliaDayTest.php | 2 +- tests/Australia/Tasmania/FlindersIsland/BoxingDayTest.php | 2 +- tests/Australia/Tasmania/FlindersIsland/ChristmasDayTest.php | 2 +- tests/Australia/Tasmania/FlindersIsland/EasterMondayTest.php | 2 +- tests/Australia/Tasmania/FlindersIsland/EightHourDayTest.php | 2 +- .../Tasmania/FlindersIsland/FlindersIslandBaseTestCase.php | 2 +- .../Tasmania/FlindersIsland/FlindersIslandShowTest.php | 2 +- tests/Australia/Tasmania/FlindersIsland/FlindersIslandTest.php | 2 +- tests/Australia/Tasmania/FlindersIsland/GoodFridayTest.php | 2 +- .../Tasmania/FlindersIsland/NationalDayOfMourningTest.php | 2 +- tests/Australia/Tasmania/FlindersIsland/NewYearsDayTest.php | 2 +- tests/Australia/Tasmania/FlindersIsland/QueensBirthdayTest.php | 2 +- tests/Australia/Tasmania/FlindersIsland/RecreationDayTest.php | 2 +- tests/Australia/Tasmania/GoodFridayTest.php | 2 +- tests/Australia/Tasmania/KingIsland/AnzacDayTest.php | 2 +- tests/Australia/Tasmania/KingIsland/AustraliaDayTest.php | 2 +- tests/Australia/Tasmania/KingIsland/BoxingDayTest.php | 2 +- tests/Australia/Tasmania/KingIsland/ChristmasDayTest.php | 2 +- tests/Australia/Tasmania/KingIsland/EasterMondayTest.php | 2 +- tests/Australia/Tasmania/KingIsland/EightHourDayTest.php | 2 +- tests/Australia/Tasmania/KingIsland/GoodFridayTest.php | 2 +- tests/Australia/Tasmania/KingIsland/KingIslandBaseTestCase.php | 2 +- tests/Australia/Tasmania/KingIsland/KingIslandShowTest.php | 2 +- tests/Australia/Tasmania/KingIsland/KingIslandTest.php | 2 +- .../Australia/Tasmania/KingIsland/NationalDayOfMourningTest.php | 2 +- tests/Australia/Tasmania/KingIsland/NewYearsDayTest.php | 2 +- tests/Australia/Tasmania/KingIsland/QueensBirthdayTest.php | 2 +- tests/Australia/Tasmania/KingIsland/RecreationDayTest.php | 2 +- tests/Australia/Tasmania/NationalDayOfMourningTest.php | 2 +- tests/Australia/Tasmania/NewYearsDayTest.php | 2 +- tests/Australia/Tasmania/Northeast/AnzacDayTest.php | 2 +- tests/Australia/Tasmania/Northeast/AustraliaDayTest.php | 2 +- tests/Australia/Tasmania/Northeast/BoxingDayTest.php | 2 +- tests/Australia/Tasmania/Northeast/ChristmasDayTest.php | 2 +- tests/Australia/Tasmania/Northeast/EasterMondayTest.php | 2 +- tests/Australia/Tasmania/Northeast/EightHourDayTest.php | 2 +- tests/Australia/Tasmania/Northeast/GoodFridayTest.php | 2 +- tests/Australia/Tasmania/Northeast/LauncestonShowTest.php | 2 +- .../Australia/Tasmania/Northeast/NationalDayOfMourningTest.php | 2 +- tests/Australia/Tasmania/Northeast/NewYearsDayTest.php | 2 +- tests/Australia/Tasmania/Northeast/NortheastBaseTestCase.php | 2 +- tests/Australia/Tasmania/Northeast/NortheastTest.php | 2 +- tests/Australia/Tasmania/Northeast/QueensBirthdayTest.php | 2 +- tests/Australia/Tasmania/Northeast/RecreationDayTest.php | 2 +- tests/Australia/Tasmania/Northwest/AnzacDayTest.php | 2 +- tests/Australia/Tasmania/Northwest/AustraliaDayTest.php | 2 +- tests/Australia/Tasmania/Northwest/BoxingDayTest.php | 2 +- tests/Australia/Tasmania/Northwest/BurnieShowTest.php | 2 +- tests/Australia/Tasmania/Northwest/ChristmasDayTest.php | 2 +- tests/Australia/Tasmania/Northwest/CircularHead/AGFESTTest.php | 2 +- .../Australia/Tasmania/Northwest/CircularHead/AnzacDayTest.php | 2 +- .../Tasmania/Northwest/CircularHead/AustraliaDayTest.php | 2 +- .../Australia/Tasmania/Northwest/CircularHead/BoxingDayTest.php | 2 +- .../Tasmania/Northwest/CircularHead/BurnieShowTest.php | 2 +- .../Tasmania/Northwest/CircularHead/ChristmasDayTest.php | 2 +- .../Northwest/CircularHead/CircularHeadBaseTestCase.php | 2 +- .../Tasmania/Northwest/CircularHead/CircularHeadTest.php | 2 +- .../Tasmania/Northwest/CircularHead/EasterMondayTest.php | 2 +- .../Tasmania/Northwest/CircularHead/EightHourDayTest.php | 2 +- .../Tasmania/Northwest/CircularHead/GoodFridayTest.php | 2 +- .../Northwest/CircularHead/NationalDayOfMourningTest.php | 2 +- .../Tasmania/Northwest/CircularHead/NewYearsDayTest.php | 2 +- .../Tasmania/Northwest/CircularHead/QueensBirthdayTest.php | 2 +- .../Tasmania/Northwest/CircularHead/RecreationDayTest.php | 2 +- tests/Australia/Tasmania/Northwest/EasterMondayTest.php | 2 +- tests/Australia/Tasmania/Northwest/EightHourDayTest.php | 2 +- tests/Australia/Tasmania/Northwest/GoodFridayTest.php | 2 +- .../Australia/Tasmania/Northwest/NationalDayOfMourningTest.php | 2 +- tests/Australia/Tasmania/Northwest/NewYearsDayTest.php | 2 +- tests/Australia/Tasmania/Northwest/NorthwestBaseTestCase.php | 2 +- tests/Australia/Tasmania/Northwest/NorthwestTest.php | 2 +- tests/Australia/Tasmania/Northwest/QueensBirthdayTest.php | 2 +- tests/Australia/Tasmania/Northwest/RecreationDayTest.php | 2 +- tests/Australia/Tasmania/QueensBirthdayTest.php | 2 +- tests/Australia/Tasmania/RecreationDayTest.php | 2 +- tests/Australia/Tasmania/South/AnzacDayTest.php | 2 +- tests/Australia/Tasmania/South/AustraliaDayTest.php | 2 +- tests/Australia/Tasmania/South/BoxingDayTest.php | 2 +- tests/Australia/Tasmania/South/ChristmasDayTest.php | 2 +- tests/Australia/Tasmania/South/EasterMondayTest.php | 2 +- tests/Australia/Tasmania/South/EightHourDayTest.php | 2 +- tests/Australia/Tasmania/South/GoodFridayTest.php | 2 +- tests/Australia/Tasmania/South/HobartShowTest.php | 2 +- tests/Australia/Tasmania/South/NationalDayOfMourningTest.php | 2 +- tests/Australia/Tasmania/South/NewYearsDayTest.php | 2 +- tests/Australia/Tasmania/South/QueensBirthdayTest.php | 2 +- tests/Australia/Tasmania/South/RecreationDayTest.php | 2 +- tests/Australia/Tasmania/South/SouthBaseTestCase.php | 2 +- tests/Australia/Tasmania/South/SouthTest.php | 2 +- tests/Australia/Tasmania/South/Southeast/AnzacDayTest.php | 2 +- tests/Australia/Tasmania/South/Southeast/AustraliaDayTest.php | 2 +- tests/Australia/Tasmania/South/Southeast/BoxingDayTest.php | 2 +- tests/Australia/Tasmania/South/Southeast/ChristmasDayTest.php | 2 +- tests/Australia/Tasmania/South/Southeast/EasterMondayTest.php | 2 +- tests/Australia/Tasmania/South/Southeast/EightHourDayTest.php | 2 +- tests/Australia/Tasmania/South/Southeast/GoodFridayTest.php | 2 +- tests/Australia/Tasmania/South/Southeast/HobartRegattaTest.php | 2 +- tests/Australia/Tasmania/South/Southeast/HobartShowTest.php | 2 +- .../Tasmania/South/Southeast/NationalDayOfMourningTest.php | 2 +- tests/Australia/Tasmania/South/Southeast/NewYearsDayTest.php | 2 +- tests/Australia/Tasmania/South/Southeast/QueensBirthdayTest.php | 2 +- .../Tasmania/South/Southeast/SoutheastBaseTestCase.php | 2 +- tests/Australia/Tasmania/South/Southeast/SoutheastTest.php | 2 +- tests/Australia/Tasmania/TasmaniaBaseTestCase.php | 2 +- tests/Australia/Tasmania/TasmaniaTest.php | 2 +- tests/Australia/Victoria/AFLGrandFinalFridayTest.php | 2 +- tests/Australia/Victoria/AnzacDayTest.php | 2 +- tests/Australia/Victoria/AustraliaDayTest.php | 2 +- tests/Australia/Victoria/BoxingDayTest.php | 2 +- tests/Australia/Victoria/ChristmasDayTest.php | 2 +- tests/Australia/Victoria/EasterMondayTest.php | 2 +- tests/Australia/Victoria/EasterSaturdayTest.php | 2 +- tests/Australia/Victoria/EasterSundayTest.php | 2 +- tests/Australia/Victoria/GoodFridayTest.php | 2 +- tests/Australia/Victoria/LabourDayTest.php | 2 +- tests/Australia/Victoria/MelbourneCupDayTest.php | 2 +- tests/Australia/Victoria/NationalDayOfMourningTest.php | 2 +- tests/Australia/Victoria/NewYearsDayTest.php | 2 +- tests/Australia/Victoria/QueensBirthdayTest.php | 2 +- tests/Australia/Victoria/VictoriaBaseTestCase.php | 2 +- tests/Australia/Victoria/VictoriaTest.php | 2 +- tests/Australia/WesternAustralia/AnzacDayTest.php | 2 +- tests/Australia/WesternAustralia/AustraliaDayTest.php | 2 +- tests/Australia/WesternAustralia/BoxingDayTest.php | 2 +- tests/Australia/WesternAustralia/ChristmasDayTest.php | 2 +- tests/Australia/WesternAustralia/EasterMondayTest.php | 2 +- tests/Australia/WesternAustralia/GoodFridayTest.php | 2 +- tests/Australia/WesternAustralia/LabourDayTest.php | 2 +- tests/Australia/WesternAustralia/NationalDayOfMourningTest.php | 2 +- tests/Australia/WesternAustralia/NewYearsDayTest.php | 2 +- tests/Australia/WesternAustralia/QueensBirthdayTest.php | 2 +- .../Australia/WesternAustralia/WesternAustraliaBaseTestCase.php | 2 +- tests/Australia/WesternAustralia/WesternAustraliaDayTest.php | 2 +- tests/Australia/WesternAustralia/WesternAustraliaTest.php | 2 +- tests/Austria/AllSaintsDayTest.php | 2 +- tests/Austria/AscensionDayTest.php | 2 +- tests/Austria/AssumptionOfMaryTest.php | 2 +- tests/Austria/AustriaBaseTestCase.php | 2 +- tests/Austria/AustriaTest.php | 2 +- tests/Austria/Burgenland/BurgenlandBaseTestCase.php | 2 +- tests/Austria/Burgenland/BurgenlandTest.php | 2 +- tests/Austria/Burgenland/stMartinsDayTest.php | 2 +- tests/Austria/Carinthia/CarinthiaBaseTestCase.php | 2 +- tests/Austria/Carinthia/CarinthiaTest.php | 2 +- tests/Austria/Carinthia/PlebisciteDayTest.php | 2 +- tests/Austria/Carinthia/StJosephsDayTest.php | 2 +- tests/Austria/ChristmasTest.php | 2 +- tests/Austria/CorpusChristiTest.php | 2 +- tests/Austria/EasterMondayTest.php | 2 +- tests/Austria/EasterTest.php | 2 +- tests/Austria/EpiphanyTest.php | 2 +- tests/Austria/ImmaculateConceptionTest.php | 2 +- tests/Austria/InternationalWorkersDayTest.php | 2 +- tests/Austria/LowerAustria/LowerAustriaBaseTestCase.php | 2 +- tests/Austria/LowerAustria/LowerAustriaTest.php | 2 +- tests/Austria/LowerAustria/StLeopoldsDayTest.php | 2 +- tests/Austria/NationalDayTest.php | 2 +- tests/Austria/NewYearsDayTest.php | 2 +- tests/Austria/PentecostMondayTest.php | 2 +- tests/Austria/PentecostTest.php | 2 +- tests/Austria/Salzburg/SalzburgBaseTestCase.php | 2 +- tests/Austria/Salzburg/SalzburgTest.php | 2 +- tests/Austria/Salzburg/StRupertsDayTest.php | 2 +- tests/Austria/SecondChristmasDayTest.php | 2 +- tests/Austria/Styria/StJosephsDayTest.php | 2 +- tests/Austria/Styria/StyriaBaseTestCase.php | 2 +- tests/Austria/Styria/StyriaTest.php | 2 +- tests/Austria/Tyrol/StJosephsDayTest.php | 2 +- tests/Austria/Tyrol/TyrolBaseTestCase.php | 2 +- tests/Austria/Tyrol/TyrolTest.php | 2 +- tests/Austria/UpperAustria/StFloriansDayTest.php | 2 +- tests/Austria/UpperAustria/UpperAustriaBaseTestCase.php | 2 +- tests/Austria/UpperAustria/UpperAustriaTest.php | 2 +- tests/Austria/Vienna/StLeopoldsDayTest.php | 2 +- tests/Austria/Vienna/ViennaBaseTestCase.php | 2 +- tests/Austria/Vienna/ViennaTest.php | 2 +- tests/Austria/Vorarlberg/StJosephsDayTest.php | 2 +- tests/Austria/Vorarlberg/VorarlbergBaseTestCase.php | 2 +- tests/Austria/Vorarlberg/VorarlbergTest.php | 2 +- tests/Base/HolidayBetweenFilterTest.php | 2 +- tests/Base/HolidayFiltersTest.php | 2 +- tests/Base/HolidayOnFilterTest.php | 2 +- tests/Base/HolidayTest.php | 2 +- tests/Base/SubstituteHolidayTest.php | 2 +- tests/Base/TranslationsTest.php | 2 +- tests/Base/TypographyTest.php | 2 +- tests/Base/WeekendTest.php | 2 +- tests/Base/YasumiExternalProvider.php | 2 +- tests/Base/YasumiTest.php | 2 +- tests/Base/YasumiWorkdayTest.php | 2 +- tests/Belgium/AllSaintsDayTest.php | 2 +- tests/Belgium/ArmisticeDayTest.php | 2 +- tests/Belgium/AscensionDayTest.php | 2 +- tests/Belgium/AssumptionOfMaryTest.php | 2 +- tests/Belgium/BelgiumBaseTestCase.php | 2 +- tests/Belgium/BelgiumTest.php | 2 +- tests/Belgium/ChristmasTest.php | 2 +- tests/Belgium/EasterMondayTest.php | 2 +- tests/Belgium/EasterTest.php | 2 +- tests/Belgium/InternationalWorkersDayTest.php | 2 +- tests/Belgium/NationalDayTest.php | 2 +- tests/Belgium/NewYearsDayTest.php | 2 +- tests/Belgium/PentecostTest.php | 2 +- tests/Belgium/pentecostMondayTest.php | 2 +- tests/Bosnia/BosniaBaseTestCase.php | 2 +- tests/Bosnia/BosniaTest.php | 2 +- tests/Bosnia/ChristmasDayTest.php | 2 +- tests/Bosnia/DayAfterNewYearsDay.php | 2 +- tests/Bosnia/EasterTest.php | 2 +- tests/Bosnia/IndependenceDayTest.php | 2 +- tests/Bosnia/InternationalWorkersDayTest.php | 2 +- tests/Bosnia/NewYearsDayTest.php | 2 +- tests/Bosnia/OrthodoxChristmasDay.php | 2 +- tests/Bosnia/SecondLabourDay.php | 2 +- tests/Bosnia/StatehoodDayTest.php | 2 +- tests/Brazil/AllSoulsDayTest.php | 2 +- tests/Brazil/AshWednesdayTest.php | 2 +- tests/Brazil/BrazilBaseTestCase.php | 2 +- tests/Brazil/BrazilTest.php | 2 +- tests/Brazil/CarnavalMondayTest.php | 2 +- tests/Brazil/CarnavalTuesdayTest.php | 2 +- tests/Brazil/ChristmasDayTest.php | 2 +- tests/Brazil/CorpusChristiTest.php | 2 +- tests/Brazil/EasterTest.php | 2 +- tests/Brazil/GoodFridayTest.php | 2 +- tests/Brazil/IndependenceDayTest.php | 2 +- tests/Brazil/InternationalWorkersDayTest.php | 2 +- tests/Brazil/NewYearsDayTest.php | 2 +- tests/Brazil/OurLadyOfAparecidaDayTest.php | 2 +- tests/Brazil/ProclamationOfRepublicDayTest.php | 2 +- tests/Brazil/TiradentesDayTest.php | 2 +- tests/Canada/Alberta/AlbertaBaseTestCase.php | 2 +- tests/Canada/Alberta/AlbertaTest.php | 2 +- tests/Canada/BritishColumbia/BritishColumbiaBaseTestCase.php | 2 +- tests/Canada/BritishColumbia/BritishColumbiaTest.php | 2 +- tests/Canada/CanadaBaseTestCase.php | 2 +- tests/Canada/CanadaDayTest.php | 2 +- tests/Canada/CanadaTest.php | 2 +- tests/Canada/ChristmasDayTest.php | 2 +- tests/Canada/LabourDayTest.php | 2 +- tests/Canada/Manitoba/ManitobaBaseTestCase.php | 2 +- tests/Canada/Manitoba/ManitobaTest.php | 2 +- tests/Canada/NewBrunswick/NewBrunswickBaseTestCase.php | 2 +- tests/Canada/NewBrunswick/NewBrunswickTest.php | 2 +- tests/Canada/NewYearsDayTest.php | 2 +- .../NewfoundlandAndLabradorBaseTestCase.php | 2 +- .../NewfoundlandAndLabrador/NewfoundlandAndLabradorTest.php | 2 +- .../NorthwestTerritories/NorthwestTerritoriesBaseTestCase.php | 2 +- tests/Canada/NorthwestTerritories/NorthwestTerritoriesTest.php | 2 +- tests/Canada/NovaScotia/NovaScotiaBaseTestCase.php | 2 +- tests/Canada/NovaScotia/NovaScotiaTest.php | 2 +- tests/Canada/Nunavut/NunavutBaseTestCase.php | 2 +- tests/Canada/Nunavut/NunavutTest.php | 2 +- tests/Canada/Ontario/OntarioBaseTestCase.php | 2 +- tests/Canada/Ontario/OntarioTest.php | 2 +- .../PrinceEdwardIsland/PrinceEdwardIslandBaseTestCase.php | 2 +- tests/Canada/PrinceEdwardIsland/PrinceEdwardIslandTest.php | 2 +- tests/Canada/Quebec/QuebecBaseTestCase.php | 2 +- tests/Canada/Quebec/QuebecTest.php | 2 +- tests/Canada/RemembranceDayTest.php | 2 +- tests/Canada/Saskatchewan/SaskatchewanBaseTestCase.php | 2 +- tests/Canada/Saskatchewan/SaskatchewanTest.php | 2 +- tests/Canada/ThanksgivingDayTest.php | 2 +- tests/Canada/TruthAndReconciliationDayTest.php | 2 +- tests/Canada/Yukon/YukonBaseTestCase.php | 2 +- tests/Canada/Yukon/YukonTest.php | 2 +- tests/Croatia/AllSaintsDayTest.php | 2 +- tests/Croatia/AntifascistStruggleDayTest.php | 2 +- tests/Croatia/AssumptionOfMaryTest.php | 2 +- tests/Croatia/ChristmasDayTest.php | 2 +- tests/Croatia/CorpusChristiTest.php | 2 +- tests/Croatia/CroatiaBaseTestCase.php | 2 +- tests/Croatia/CroatiaTest.php | 2 +- tests/Croatia/EasterMondayTest.php | 2 +- tests/Croatia/EasterTest.php | 2 +- tests/Croatia/EpiphanyTest.php | 2 +- tests/Croatia/HomelandThanksgivingDayTest.php | 2 +- tests/Croatia/IndependenceDayTest.php | 2 +- tests/Croatia/InternationalWorkersDayTest.php | 2 +- tests/Croatia/NewYearsDayTest.php | 2 +- tests/Croatia/RemembranceDayTest.php | 2 +- tests/Croatia/StStephensDayTest.php | 2 +- tests/Croatia/StatehoodDayTest.php | 2 +- tests/CzechRepublic/ChristmasDayTest.php | 2 +- tests/CzechRepublic/ChristmasEveTest.php | 2 +- tests/CzechRepublic/CzechRepublicBaseTestCase.php | 2 +- tests/CzechRepublic/CzechRepublicTest.php | 2 +- tests/CzechRepublic/CzechStateHoodDayTest.php | 2 +- tests/CzechRepublic/EasterMondayTest.php | 2 +- tests/CzechRepublic/GoodFridayTest.php | 2 +- tests/CzechRepublic/IndependentCzechoslovakStateDayTest.php | 2 +- tests/CzechRepublic/InternationalWorkersDayTest.php | 2 +- tests/CzechRepublic/JanHusDayTest.php | 2 +- tests/CzechRepublic/NewYearsDayTest.php | 2 +- tests/CzechRepublic/RenewalOfIndependentCzechStateDayTest.php | 2 +- tests/CzechRepublic/SaintsCyrilAndMethodiusDayTest.php | 2 +- tests/CzechRepublic/SecondChristmasDayTest.php | 2 +- tests/CzechRepublic/StruggleForFreedomAndDemocracyDayTest.php | 2 +- tests/CzechRepublic/VictoryInEuropeDayTest.php | 2 +- tests/Denmark/AscensionDayTest.php | 2 +- tests/Denmark/ChristmasDayTest.php | 2 +- tests/Denmark/ChristmasEveTest.php | 2 +- tests/Denmark/ConstitutionDayTest.php | 2 +- tests/Denmark/DaylightSavingTime.php | 2 +- tests/Denmark/DenmarkBaseTestCase.php | 2 +- tests/Denmark/DenmarkTest.php | 2 +- tests/Denmark/EasterMondayTest.php | 2 +- tests/Denmark/EasterTest.php | 2 +- tests/Denmark/GoodFridayTest.php | 2 +- tests/Denmark/GreatPrayerDayTest.php | 2 +- tests/Denmark/InternationalWorkersDayTest.php | 2 +- tests/Denmark/MaundyThursdayTest.php | 2 +- tests/Denmark/NewYearsDayTest.php | 2 +- tests/Denmark/NewYearsEveTest.php | 2 +- tests/Denmark/PentecostMondayTest.php | 2 +- tests/Denmark/PentecostTest.php | 2 +- tests/Denmark/SecondChristmasDayTest.php | 2 +- tests/Denmark/SummerTimeTest.php | 2 +- tests/Denmark/WinterTimeTest.php | 2 +- tests/Estonia/ChristmasDayTest.php | 2 +- tests/Estonia/ChristmasEveDayTest.php | 2 +- tests/Estonia/EasterDayTest.php | 2 +- tests/Estonia/EstoniaBaseTestCase.php | 2 +- tests/Estonia/EstoniaTest.php | 2 +- tests/Estonia/GoodFridayDayTest.php | 2 +- tests/Estonia/IndependenceDayTest.php | 2 +- tests/Estonia/InternationalWorkersDayTest.php | 2 +- tests/Estonia/NewYearsDayTest.php | 2 +- tests/Estonia/PentecostTest.php | 2 +- tests/Estonia/RestorationOfIndependenceDayTest.php | 2 +- tests/Estonia/SecondChristmasDayTest.php | 2 +- tests/Estonia/StJohnsDayTest.php | 2 +- tests/Estonia/VictoryDayTest.php | 2 +- tests/Finland/AllSaintsDayTest.php | 2 +- tests/Finland/AscensionDayTest.php | 2 +- tests/Finland/ChristmasDayTest.php | 2 +- tests/Finland/EasterMondayTest.php | 2 +- tests/Finland/EasterTest.php | 2 +- tests/Finland/EpiphanyTest.php | 2 +- tests/Finland/FinlandBaseTestCase.php | 2 +- tests/Finland/FinlandTest.php | 2 +- tests/Finland/GoodFridayTest.php | 2 +- tests/Finland/IndependenceDayTest.php | 2 +- tests/Finland/InternationalWorkersDayTest.php | 2 +- tests/Finland/NewYearsDayTest.php | 2 +- tests/Finland/PentecostTest.php | 2 +- tests/Finland/SecondChristmasDayTest.php | 2 +- tests/Finland/stJohnsDayTest.php | 2 +- tests/France/AllSaintsDayTest.php | 2 +- tests/France/ArmisticeDayTest.php | 2 +- tests/France/AscensionDayTest.php | 2 +- tests/France/AssumptionOfMaryTest.php | 2 +- tests/France/BasRhin/BasRhinBaseTestCase.php | 2 +- tests/France/BasRhin/BasRhinTest.php | 2 +- tests/France/BasRhin/GoodFridayTest.php | 2 +- tests/France/BasRhin/stStephensDayTest.php | 2 +- tests/France/BastilleDayTest.php | 2 +- tests/France/ChristmasDayTest.php | 2 +- tests/France/EasterMondayTest.php | 2 +- tests/France/FranceBaseTestCase.php | 2 +- tests/France/FranceTest.php | 2 +- tests/France/HautRhin/GoodFridayTest.php | 2 +- tests/France/HautRhin/HautRhinBaseTestCase.php | 2 +- tests/France/HautRhin/HautRhinTest.php | 2 +- tests/France/HautRhin/stStephensDayTest.php | 2 +- tests/France/InternationalWorkersDayTest.php | 2 +- tests/France/Moselle/GoodFridayTest.php | 2 +- tests/France/Moselle/MoselleBaseTestCase.php | 2 +- tests/France/Moselle/MoselleTest.php | 2 +- tests/France/Moselle/stStephensDayTest.php | 2 +- tests/France/NewYearsDayTest.php | 2 +- tests/France/PentecostMondayTest.php | 2 +- tests/France/VictoryInEuropeDayTest.php | 2 +- tests/Georgia/GeorgiaBaseTestCase.php | 2 +- tests/Georgia/GeorgiaTest.php | 2 +- tests/Georgia/IndependenceDayTest.php | 2 +- tests/Georgia/InternationalWomensDayTest.php | 2 +- tests/Georgia/MtskhetobaDayTest.php | 2 +- tests/Georgia/NewYearsDayTest.php | 2 +- tests/Georgia/OrthodoxChristmasDayTest.php | 2 +- tests/Georgia/OrthodoxEpiphanyDayTest.php | 2 +- tests/Georgia/SecondNewYearDayTest.php | 2 +- tests/Georgia/StAndrewsDayTest.php | 2 +- tests/Georgia/StGeorgesDayTest.php | 2 +- tests/Georgia/StMarysDayTest.php | 2 +- tests/Georgia/UnityDayTest.php | 2 +- tests/Georgia/VictoryDayTest.php | 2 +- tests/Germany/AscensionDayTest.php | 2 +- tests/Germany/BadenWurttemberg/AllSaintsDayTest.php | 2 +- tests/Germany/BadenWurttemberg/BadenWurttembergBaseTestCase.php | 2 +- tests/Germany/BadenWurttemberg/BadenWurttembergTest.php | 2 +- tests/Germany/BadenWurttemberg/CorpusChristiTest.php | 2 +- tests/Germany/BadenWurttemberg/EpiphanyTest.php | 2 +- tests/Germany/BadenWurttemberg/GermanUnityDayTest.php | 2 +- tests/Germany/BadenWurttemberg/ReformationDay2017Test.php | 2 +- tests/Germany/Bavaria/AllSaintsDayTest.php | 2 +- tests/Germany/Bavaria/BavariaBaseTestCase.php | 2 +- tests/Germany/Bavaria/BavariaTest.php | 2 +- tests/Germany/Bavaria/CorpusChristiTest.php | 2 +- tests/Germany/Bavaria/EpiphanyTest.php | 2 +- tests/Germany/Bavaria/GermanUnityDayTest.php | 2 +- tests/Germany/Bavaria/ReformationDay2017Test.php | 2 +- tests/Germany/Berlin/BerlinBaseTestCase.php | 2 +- tests/Germany/Berlin/BerlinTest.php | 2 +- tests/Germany/Berlin/DayOfLiberation2020Test.php | 2 +- tests/Germany/Berlin/GermanUnityDayTest.php | 2 +- tests/Germany/Berlin/InternationalWomensDay2019Test.php | 2 +- tests/Germany/Berlin/ReformationDay2017Test.php | 2 +- tests/Germany/Brandenburg/BrandenburgBaseTestCase.php | 2 +- tests/Germany/Brandenburg/BrandenburgTest.php | 2 +- tests/Germany/Brandenburg/GermanUnityDayTest.php | 2 +- tests/Germany/Brandenburg/ReformationDayTest.php | 2 +- tests/Germany/Bremen/BremenBaseTestCase.php | 2 +- tests/Germany/Bremen/BremenTest.php | 2 +- tests/Germany/Bremen/GermanUnityDayTest.php | 2 +- tests/Germany/Bremen/ReformationDay2017Test.php | 2 +- tests/Germany/Bremen/ReformationDayTest.php | 2 +- tests/Germany/ChristmasTest.php | 2 +- tests/Germany/EasterMondayTest.php | 2 +- tests/Germany/GermanUnityDayTest.php | 2 +- tests/Germany/GermanyBaseTestCase.php | 2 +- tests/Germany/GermanyTest.php | 2 +- tests/Germany/GoodFridayTest.php | 2 +- tests/Germany/Hamburg/DayOfReformationTest.php | 2 +- tests/Germany/Hamburg/GermanUnityDay.php | 2 +- tests/Germany/Hamburg/HamburgBaseTestCase.php | 2 +- tests/Germany/Hamburg/HamburgTest.php | 2 +- tests/Germany/Hamburg/ReformationDay2017Test.php | 2 +- tests/Germany/Hesse/CorpusChristiTest.php | 2 +- tests/Germany/Hesse/GermanUnityDayTest.php | 2 +- tests/Germany/Hesse/HesseBaseTestCase.php | 2 +- tests/Germany/Hesse/HesseTest.php | 2 +- tests/Germany/Hesse/ReformationDay2017Test.php | 2 +- tests/Germany/InternationalWorkersDayTest.php | 2 +- tests/Germany/LowerSaxony/GermanUnityDayTest.php | 2 +- tests/Germany/LowerSaxony/LowerSaxonyBaseTestCase.php | 2 +- tests/Germany/LowerSaxony/LowerSaxonyTest.php | 2 +- tests/Germany/LowerSaxony/ReformationDay2017Test.php | 2 +- tests/Germany/LowerSaxony/ReformationDayTest.php | 2 +- .../Germany/MecklenburgWesternPomerania/GermanUnityDayTest.php | 2 +- .../MecklenburgWesternPomeraniaBaseTestCase.php | 2 +- .../MecklenburgWesternPomeraniaTest.php | 2 +- .../Germany/MecklenburgWesternPomerania/ReformationDayTest.php | 2 +- tests/Germany/NewYearsDayTest.php | 2 +- tests/Germany/NewYearsEveTest.php | 2 +- tests/Germany/NorthRhineWestphalia/AllSaintsDayTest.php | 2 +- tests/Germany/NorthRhineWestphalia/CorpusChristiTest.php | 2 +- tests/Germany/NorthRhineWestphalia/GermanUnityDayTest.php | 2 +- .../NorthRhineWestphalia/NorthRhineWestphaliaBaseTestCase.php | 2 +- tests/Germany/NorthRhineWestphalia/NorthRhineWestphaliaTest.php | 2 +- tests/Germany/NorthRhineWestphalia/ReformationDay2017Test.php | 2 +- tests/Germany/PentecostMondayTest.php | 2 +- tests/Germany/PentecostTest.php | 2 +- tests/Germany/ReformationDay2017Test.php | 2 +- tests/Germany/RhinelandPalatinate/AllSaintsDayTest.php | 2 +- tests/Germany/RhinelandPalatinate/CorpusChristiTest.php | 2 +- tests/Germany/RhinelandPalatinate/GermanUnityDayTest.php | 2 +- tests/Germany/RhinelandPalatinate/ReformationDay2017Test.php | 2 +- .../RhinelandPalatinate/RhinelandPalatinateBaseTestCase.php | 2 +- tests/Germany/RhinelandPalatinate/RhinelandPalatinateTest.php | 2 +- tests/Germany/Saarland/AllSaintsDayTest.php | 2 +- tests/Germany/Saarland/AssumptionOfMaryTest.php | 2 +- tests/Germany/Saarland/CorpusChristiTest.php | 2 +- tests/Germany/Saarland/GermanUnityDayTest.php | 2 +- tests/Germany/Saarland/ReformationDay2017Test.php | 2 +- tests/Germany/Saarland/SaarlandBaseTestCase.php | 2 +- tests/Germany/Saarland/SaarlandTest.php | 2 +- tests/Germany/Saxony/GermanUnityDayTest.php | 2 +- tests/Germany/Saxony/ReformationDayTest.php | 2 +- tests/Germany/Saxony/RepentanceAndPrayerDayTest.php | 2 +- tests/Germany/Saxony/SaxonyBaseTestCase.php | 2 +- tests/Germany/Saxony/SaxonyTest.php | 2 +- tests/Germany/SaxonyAnhalt/EpiphanyTest.php | 2 +- tests/Germany/SaxonyAnhalt/GermanUnityDayTest.php | 2 +- tests/Germany/SaxonyAnhalt/ReformationDayTest.php | 2 +- tests/Germany/SaxonyAnhalt/SaxonyAnhaltBaseTestCase.php | 2 +- tests/Germany/SaxonyAnhalt/SaxonyAnhaltTest.php | 2 +- tests/Germany/SchleswigHolstein/GermanUnityDayTest.php | 2 +- tests/Germany/SchleswigHolstein/ReformationDay2017Test.php | 2 +- tests/Germany/SchleswigHolstein/ReformationDayTest.php | 2 +- .../Germany/SchleswigHolstein/SchleswigHolsteinBaseTestCase.php | 2 +- tests/Germany/SchleswigHolstein/SchleswigHolsteinTest.php | 2 +- tests/Germany/SecondChristmasDayTest.php | 2 +- tests/Germany/Thuringia/GermanUnityDayTest.php | 2 +- tests/Germany/Thuringia/ReformationDayTest.php | 2 +- tests/Germany/Thuringia/ThuringiaBaseTestCase.php | 2 +- tests/Germany/Thuringia/ThuringiaTest.php | 2 +- tests/Germany/Thuringia/WorldChildrensDayTest.php | 2 +- tests/Greece/AnnunciationTest.php | 2 +- tests/Greece/AscensionDayTest.php | 2 +- tests/Greece/AssumptionOfMaryTest.php | 2 +- tests/Greece/ChristmasDayTest.php | 2 +- tests/Greece/CleanMondayTest.php | 2 +- tests/Greece/EasterMondayTest.php | 2 +- tests/Greece/EasterTest.php | 2 +- tests/Greece/EpiphanyTest.php | 2 +- tests/Greece/GreeceBaseTestCase.php | 2 +- tests/Greece/GreeceTest.php | 2 +- tests/Greece/IndepencenceDayTest.php | 2 +- tests/Greece/InternationalWorkersDayTest.php | 2 +- tests/Greece/NewYearsDayTest.php | 2 +- tests/Greece/OhiDayTest.php | 2 +- tests/Greece/PentecostMondayTest.php | 2 +- tests/Greece/PentecostTest.php | 2 +- tests/Greece/PolytechnioTest.php | 2 +- tests/Greece/ThreeHolyHierarchsTest.php | 2 +- tests/Greece/goodFridayTest.php | 2 +- tests/HolidayTestCase.php | 2 +- tests/Hungary/AllSaintsDayTest.php | 2 +- tests/Hungary/ChristmasTest.php | 2 +- tests/Hungary/EasterMondayTest.php | 2 +- tests/Hungary/EasterTest.php | 2 +- tests/Hungary/HungaryBaseTestCase.php | 2 +- tests/Hungary/HungaryTest.php | 2 +- tests/Hungary/InternationalWorkersDayTest.php | 2 +- tests/Hungary/MemorialDay1848Test.php | 2 +- tests/Hungary/MemorialDay1956Test.php | 2 +- tests/Hungary/NewYearsDayTest.php | 2 +- tests/Hungary/PentecostMondayTest.php | 2 +- tests/Hungary/PentecostTest.php | 2 +- tests/Hungary/SecondChristmasDayTest.php | 2 +- tests/Hungary/StateFoundationDayTest.php | 2 +- tests/Ireland/AugustHolidayTest.php | 2 +- tests/Ireland/ChristmasDayTest.php | 2 +- tests/Ireland/EasterMondayTest.php | 2 +- tests/Ireland/EasterTest.php | 2 +- tests/Ireland/GoodFridayTest.php | 2 +- tests/Ireland/IrelandBaseTestCase.php | 2 +- tests/Ireland/IrelandTest.php | 2 +- tests/Ireland/JuneHolidayTest.php | 2 +- tests/Ireland/MayDayTest.php | 2 +- tests/Ireland/NewYearsDayTest.php | 2 +- tests/Ireland/OctoberHolidayTest.php | 2 +- tests/Ireland/PentecostTest.php | 2 +- tests/Ireland/StPatricksDayTest.php | 2 +- tests/Ireland/StStephensDayTest.php | 2 +- tests/Ireland/pentecostMondayTest.php | 2 +- tests/Italy/AllSaintsDayTest.php | 2 +- tests/Italy/AssumptionOfMaryTest.php | 2 +- tests/Italy/ChristmasTest.php | 2 +- tests/Italy/EasterMondayTest.php | 2 +- tests/Italy/EasterTest.php | 2 +- tests/Italy/EpiphanyTest.php | 2 +- tests/Italy/ImmaculateConceptionTest.php | 2 +- tests/Italy/InternationalWorkersDayTest.php | 2 +- tests/Italy/ItalyBaseTestCase.php | 2 +- tests/Italy/ItalyTest.php | 2 +- tests/Italy/LiberationDayTest.php | 2 +- tests/Italy/NewYearsDayTest.php | 2 +- tests/Italy/RepublicDayTest.php | 2 +- tests/Italy/stStephensDayTest.php | 2 +- tests/Japan/AutumnalEquinoxDayTest.php | 2 +- tests/Japan/ChildrensDayTest.php | 2 +- tests/Japan/ComingOfAgeDayTest.php | 2 +- tests/Japan/ConstitutionMemorialDayTest.php | 2 +- tests/Japan/CoronationDayTest.php | 2 +- tests/Japan/CultureDayTest.php | 2 +- tests/Japan/EmperorsBirthdayTest.php | 2 +- tests/Japan/EnthronementProclamationCeremonyTest.php | 2 +- tests/Japan/GreeneryDayTest.php | 2 +- tests/Japan/JapanBaseTestCase.php | 2 +- tests/Japan/JapanTest.php | 2 +- tests/Japan/LabourThanksgivingDayTest.php | 2 +- tests/Japan/MarineDayTest.php | 2 +- tests/Japan/MountainDayTest.php | 2 +- tests/Japan/NationalFoundationDayTest.php | 2 +- tests/Japan/NewYearsDayTest.php | 2 +- tests/Japan/PublicBridgeDayTest.php | 2 +- tests/Japan/RespectForTheAgedDayTest.php | 2 +- tests/Japan/ShowaDayTest.php | 2 +- tests/Japan/SportsDayTest.php | 2 +- tests/Japan/VernalEquinoxDayTest.php | 2 +- tests/Latvia/ChristmasDayTest.php | 2 +- tests/Latvia/ChristmasEveDayTest.php | 2 +- tests/Latvia/EasterDayTest.php | 2 +- tests/Latvia/EasterMondayDayTest.php | 2 +- tests/Latvia/GoodFridayDayTest.php | 2 +- tests/Latvia/InternationalWorkersDayTest.php | 2 +- tests/Latvia/LatviaBaseTestCase.php | 2 +- tests/Latvia/LatviaTest.php | 2 +- tests/Latvia/MidsummerEveDayTest.php | 2 +- tests/Latvia/NewYearsDayTest.php | 2 +- tests/Latvia/NewYearsEveDayTest.php | 2 +- tests/Latvia/ProclamationOfTheRepublicOfLatviaDayTest.php | 2 +- tests/Latvia/RestorationOfIndependenceDayTest.php | 2 +- tests/Latvia/SecondChristmasDayTest.php | 2 +- tests/Latvia/StJohnsDayTest.php | 2 +- tests/Lithuania/AllSaintsDayTest.php | 2 +- tests/Lithuania/AllSoulsDayTest.php | 2 +- tests/Lithuania/AssumptionOfMaryDayTest.php | 2 +- tests/Lithuania/ChristmasDayTest.php | 2 +- tests/Lithuania/ChristmasEveDayTest.php | 2 +- tests/Lithuania/EasterDayTest.php | 2 +- tests/Lithuania/EasterMondayDayTest.php | 2 +- tests/Lithuania/InternationalWorkersDayTest.php | 2 +- tests/Lithuania/LithuaniaBaseTestCase.php | 2 +- tests/Lithuania/LithuaniaTest.php | 2 +- tests/Lithuania/NewYearsDayTest.php | 2 +- tests/Lithuania/RestorationOfIndependenceOfLithuaniaDayTest.php | 2 +- tests/Lithuania/RestorationOfTheStateOfLithuaniaDayTest.php | 2 +- tests/Lithuania/SecondChristmasDayTest.php | 2 +- tests/Lithuania/StJohnsDayTest.php | 2 +- tests/Lithuania/StatehoodDayTest.php | 2 +- tests/Luxembourg/AllSaintsDayTest.php | 2 +- tests/Luxembourg/AscensionDayTest.php | 2 +- tests/Luxembourg/AssumptionOfMaryTest.php | 2 +- tests/Luxembourg/ChristmasDayTest.php | 2 +- tests/Luxembourg/EasterMondayTest.php | 2 +- tests/Luxembourg/EuropeDayTest.php | 2 +- tests/Luxembourg/InternationalWorkersDayTest.php | 2 +- tests/Luxembourg/LuxembourgBaseTestCase.php | 2 +- tests/Luxembourg/LuxembourgTest.php | 2 +- tests/Luxembourg/NationalDayTest.php | 2 +- tests/Luxembourg/NewYearsDayTest.php | 2 +- tests/Luxembourg/PentecostMondayTest.php | 2 +- tests/Luxembourg/SecondChristmasDayTest.php | 2 +- tests/Netherlands/AscensionDayTest.php | 2 +- tests/Netherlands/AshWednesdayTest.php | 2 +- tests/Netherlands/ChristmasDayTest.php | 2 +- tests/Netherlands/CommemorationDayTest.php | 2 +- tests/Netherlands/DaylightSavingTime.php | 2 +- tests/Netherlands/EasterMondayTest.php | 2 +- tests/Netherlands/EasterTest.php | 2 +- tests/Netherlands/EpiphanyTest.php | 2 +- tests/Netherlands/FathersDayTest.php | 2 +- tests/Netherlands/GoodFridayTest.php | 2 +- tests/Netherlands/HalloweenTest.php | 2 +- tests/Netherlands/InternationalWorkersDayTest.php | 2 +- tests/Netherlands/KingsDayTest.php | 2 +- tests/Netherlands/LiberationDayTest.php | 2 +- tests/Netherlands/MothersDayTest.php | 2 +- tests/Netherlands/NetherlandsBaseTestCase.php | 2 +- tests/Netherlands/NetherlandsTest.php | 2 +- tests/Netherlands/NewYearsDayTest.php | 2 +- tests/Netherlands/PentecostTest.php | 2 +- tests/Netherlands/QueensDayTest.php | 2 +- tests/Netherlands/SummerTimeTest.php | 2 +- tests/Netherlands/ValentinesDayTest.php | 2 +- tests/Netherlands/WinterTimeTest.php | 2 +- tests/Netherlands/WorldAnimalDayTest.php | 2 +- tests/Netherlands/carnivalDayTest.php | 2 +- tests/Netherlands/pentecostMondayTest.php | 2 +- tests/Netherlands/princesDayTest.php | 2 +- tests/Netherlands/secondCarnivalDay.php | 2 +- tests/Netherlands/secondChristmasdayTest.php | 2 +- tests/Netherlands/stMartinsDayTest.php | 2 +- tests/Netherlands/stNicholasDayTest.php | 2 +- tests/Netherlands/thirdCarnivalDay.php | 2 +- tests/NewZealand/AnzacDayTest.php | 2 +- tests/NewZealand/BoxingDayTest.php | 2 +- tests/NewZealand/ChristmasDayTest.php | 2 +- tests/NewZealand/DayAfterNewYearsDayTest.php | 2 +- tests/NewZealand/EasterMondayTest.php | 2 +- tests/NewZealand/GoodFridayTest.php | 2 +- tests/NewZealand/LabourDayTest.php | 2 +- tests/NewZealand/NewYearsDayTest.php | 2 +- tests/NewZealand/NewZealandBaseTestCase.php | 2 +- tests/NewZealand/NewZealandTest.php | 2 +- tests/NewZealand/QueensBirthdayTest.php | 2 +- tests/NewZealand/WaitangiDayTest.php | 2 +- tests/Norway/AscensionDayTest.php | 2 +- tests/Norway/ChristmasDayTest.php | 2 +- tests/Norway/ConstitutionDayTest.php | 2 +- tests/Norway/EasterMondayTest.php | 2 +- tests/Norway/EasterTest.php | 2 +- tests/Norway/GoodFridayTest.php | 2 +- tests/Norway/InternationalWorkersDayTest.php | 2 +- tests/Norway/MaundyThursdayTest.php | 2 +- tests/Norway/NewYearsDayTest.php | 2 +- tests/Norway/NorwayBaseTestCase.php | 2 +- tests/Norway/NorwayTest.php | 2 +- tests/Norway/PentecostMondayTest.php | 2 +- tests/Norway/PentecostTest.php | 2 +- tests/Norway/SecondChristmasDayTest.php | 2 +- tests/Poland/AllSaintsDayTest.php | 2 +- tests/Poland/AssumptionOfMaryTest.php | 2 +- tests/Poland/ChristmasTest.php | 2 +- tests/Poland/ConstitutionDayTest.php | 2 +- tests/Poland/CorpusChristiTest.php | 2 +- tests/Poland/EasterMondayTest.php | 2 +- tests/Poland/EasterTest.php | 2 +- tests/Poland/EpiphanyTest.php | 2 +- tests/Poland/IndependenceDayTest.php | 2 +- tests/Poland/InternationalWorkersDayTest.php | 2 +- tests/Poland/NewYearsDayTest.php | 2 +- tests/Poland/PentecostTest.php | 2 +- tests/Poland/PolandBaseTestCase.php | 2 +- tests/Poland/PolandTest.php | 2 +- tests/Poland/SecondChristmasDayTest.php | 2 +- tests/Portugal/AllSaintsDayTest.php | 2 +- tests/Portugal/AssumptionOfMaryTest.php | 2 +- tests/Portugal/CarnationRevolutionDayTest.php | 2 +- tests/Portugal/ChristmasTest.php | 2 +- tests/Portugal/CorpusChristiTest.php | 2 +- tests/Portugal/EasterTest.php | 2 +- tests/Portugal/GoodFridayTest.php | 2 +- tests/Portugal/ImmaculateConceptionTest.php | 2 +- tests/Portugal/InternationalWorkersDayTest.php | 2 +- tests/Portugal/NewYearsDayTest.php | 2 +- tests/Portugal/PortugalBaseTestCase.php | 2 +- tests/Portugal/PortugalDayTest.php | 2 +- tests/Portugal/PortugalTest.php | 2 +- tests/Portugal/PortugueseRepublicDayTest.php | 2 +- tests/Portugal/RestorationOfIndependenceTest.php | 2 +- tests/ProviderTestCase.php | 2 +- tests/Randomizer.php | 2 +- tests/Romania/AssumptionOfMaryTest.php | 2 +- tests/Romania/ChildrensDayTest.php | 2 +- tests/Romania/ChristmasDayTest.php | 2 +- tests/Romania/ConstantinBrancusiDayTest.php | 2 +- tests/Romania/DayAfterNewYearsDayTest.php | 2 +- tests/Romania/EasterMondayTest.php | 2 +- tests/Romania/EasterTest.php | 2 +- tests/Romania/InternationalWorkersDayTest.php | 2 +- tests/Romania/NationalDayTest.php | 2 +- tests/Romania/NewYearsDayTest.php | 2 +- tests/Romania/PentecostMondayTest.php | 2 +- tests/Romania/PentecostTest.php | 2 +- tests/Romania/RomaniaBaseTestCase.php | 2 +- tests/Romania/RomaniaTest.php | 2 +- tests/Romania/SecondChristmasDayTest.php | 2 +- tests/Romania/StAndrewsDayTest.php | 2 +- tests/Romania/UnitedPrincipalitiesDayTest.php | 2 +- tests/Russia/DefenceOfTheFatherlandDayTest.php | 2 +- tests/Russia/InternationalWomensDayTest.php | 2 +- tests/Russia/NewYearHolidaysDay2Test.php | 2 +- tests/Russia/NewYearHolidaysDay3Test.php | 2 +- tests/Russia/NewYearHolidaysDay4Test.php | 2 +- tests/Russia/NewYearHolidaysDay5Test.php | 2 +- tests/Russia/NewYearHolidaysDay6Test.php | 2 +- tests/Russia/NewYearHolidaysDay8Test.php | 2 +- tests/Russia/NewYearsDayTest.php | 2 +- tests/Russia/OrthodoxChristmasDayTest.php | 2 +- tests/Russia/RussiaBaseTestCase.php | 2 +- tests/Russia/RussiaDayTest.php | 2 +- tests/Russia/RussiaTest.php | 2 +- tests/Russia/SpringAndLabourDayTest.php | 2 +- tests/Russia/UnityDayTest.php | 2 +- tests/Russia/VictoryDayTest.php | 2 +- tests/Slovakia/AllSaintsDayTest.php | 2 +- tests/Slovakia/ChristmasDayTest.php | 2 +- tests/Slovakia/ChristmasEveTest.php | 2 +- tests/Slovakia/EasterMondayTest.php | 2 +- tests/Slovakia/EpiphanyTest.php | 2 +- tests/Slovakia/GoodFridayTest.php | 2 +- tests/Slovakia/InternationalWorkersDayTest.php | 2 +- tests/Slovakia/OurLadyOfSorrowsDayTest.php | 2 +- tests/Slovakia/SaintsCyrilAndMethodiusDayTest.php | 2 +- tests/Slovakia/SecondChristmasDayTest.php | 2 +- tests/Slovakia/SlovakConstitutionDayTest.php | 2 +- tests/Slovakia/SlovakIndependeceDayTest.php | 2 +- tests/Slovakia/SlovakNationalUprisingDayTest.php | 2 +- tests/Slovakia/SlovakiaBaseTestCase.php | 2 +- tests/Slovakia/SlovakiaTest.php | 2 +- tests/Slovakia/StruggleForFreedomAndDemocracyDayTest.php | 2 +- tests/Slovakia/VictoryInEuropeDayTest.php | 2 +- tests/SouthAfrica/ChristmasDayTest.php | 2 +- tests/SouthAfrica/FamilyDayTest.php | 2 +- tests/SouthAfrica/FreedomDayTest.php | 2 +- tests/SouthAfrica/GoodFridayTest.php | 2 +- tests/SouthAfrica/HeritageDayTest.php | 2 +- tests/SouthAfrica/HumanRightsDayTest.php | 2 +- tests/SouthAfrica/MunicipalElections2016DayTest.php | 2 +- tests/SouthAfrica/NationalWomensDayTest.php | 2 +- tests/SouthAfrica/NewYearsDayTest.php | 2 +- tests/SouthAfrica/ReconciliationDayTest.php | 2 +- tests/SouthAfrica/SecondChristmasDayTest.php | 2 +- tests/SouthAfrica/SouthAfricaBaseTestCase.php | 2 +- tests/SouthAfrica/SouthAfricaTest.php | 2 +- tests/SouthAfrica/SubstituteDayOfGoodwillTest.php | 2 +- tests/SouthAfrica/WorkersDayTest.php | 2 +- tests/SouthAfrica/YouthDayTest.php | 2 +- tests/SouthKorea/ArborDayTest.php | 2 +- tests/SouthKorea/ArmedForcesDayTest.php | 2 +- tests/SouthKorea/BuddhasBirthdayTest.php | 2 +- tests/SouthKorea/ChildrensDayTest.php | 2 +- tests/SouthKorea/ChristmasDayTest.php | 2 +- tests/SouthKorea/ChuseokTest.php | 2 +- tests/SouthKorea/ConstitutionDayTest.php | 2 +- tests/SouthKorea/GaecheonjeolTest.php | 2 +- tests/SouthKorea/HangulDayTest.php | 2 +- tests/SouthKorea/IndependenceMovementDayTest.php | 2 +- tests/SouthKorea/LiberationDayTest.php | 2 +- tests/SouthKorea/MemorialDayTest.php | 2 +- tests/SouthKorea/NewYearsDayTest.php | 2 +- tests/SouthKorea/SeollalTest.php | 2 +- tests/SouthKorea/SouthKoreaBaseTestCase.php | 2 +- tests/SouthKorea/SouthKoreaTest.php | 2 +- tests/Spain/AllSaintsDayTest.php | 2 +- tests/Spain/Andalusia/AndalusiaBaseTestCase.php | 2 +- tests/Spain/Andalusia/AndalusiaDayTest.php | 2 +- tests/Spain/Andalusia/AndalusiaTest.php | 2 +- tests/Spain/Aragon/AragonBaseTestCase.php | 2 +- tests/Spain/Aragon/AragonTest.php | 2 +- tests/Spain/Aragon/StGeorgesDayTest.php | 2 +- tests/Spain/AssumptionOfMaryTest.php | 2 +- tests/Spain/Asturias/AsturiasBaseTestCase.php | 2 +- tests/Spain/Asturias/AsturiasDayTest.php | 2 +- tests/Spain/Asturias/AsturiasTest.php | 2 +- tests/Spain/BalearicIslands/BalearicIslandsBaseTestCase.php | 2 +- tests/Spain/BalearicIslands/BalearicIslandsDayTest.php | 2 +- tests/Spain/BalearicIslands/BalearicIslandsTest.php | 2 +- tests/Spain/BasqueCountry/BasqueCountryBaseTestCase.php | 2 +- tests/Spain/BasqueCountry/BasqueCountryDayTest.php | 2 +- tests/Spain/BasqueCountry/BasqueCountryTest.php | 2 +- tests/Spain/CanaryIslands/CanaryIslandsBaseTestCase.php | 2 +- tests/Spain/CanaryIslands/CanaryIslandsDayTest.php | 2 +- tests/Spain/CanaryIslands/CanaryIslandsTest.php | 2 +- tests/Spain/Cantabria/CantabriaBaseTestCase.php | 2 +- tests/Spain/Cantabria/CantabriaDayTest.php | 2 +- tests/Spain/Cantabria/CantabriaTest.php | 2 +- tests/Spain/CastileAndLeon/CastileAndLeonBaseTestCase.php | 2 +- tests/Spain/CastileAndLeon/CastileAndLeonDayTest.php | 2 +- tests/Spain/CastileAndLeon/CastileAndLeonTest.php | 2 +- tests/Spain/CastillaLaMancha/CastillaLaManchaBaseTestCase.php | 2 +- tests/Spain/CastillaLaMancha/CastillaLaManchaDayTest.php | 2 +- tests/Spain/CastillaLaMancha/CastillaLaManchaTest.php | 2 +- tests/Spain/Catalonia/CataloniaBaseTestCase.php | 2 +- tests/Spain/Catalonia/CataloniaTest.php | 2 +- tests/Spain/Catalonia/nationalCataloniaDayTest.php | 2 +- tests/Spain/Catalonia/stJohnsDayTest.php | 2 +- tests/Spain/Ceuta/CeutaBaseTestCase.php | 2 +- tests/Spain/Ceuta/CeutaTest.php | 2 +- tests/Spain/Ceuta/ceutaDayTest.php | 2 +- tests/Spain/ChristmasTest.php | 2 +- tests/Spain/CommunityOfMadrid/CommunityOfMadridBaseTestCase.php | 2 +- tests/Spain/CommunityOfMadrid/CommunityOfMadridTest.php | 2 +- tests/Spain/CommunityOfMadrid/DosdeMayoUprisingDayTest.php | 2 +- tests/Spain/ConstitutionDayTest.php | 2 +- tests/Spain/EasterMondayTest.php | 2 +- tests/Spain/EpiphanyTest.php | 2 +- tests/Spain/Extremadura/ExtremaduraBaseTestCase.php | 2 +- tests/Spain/Extremadura/ExtremaduraDayTest.php | 2 +- tests/Spain/Extremadura/ExtremaduraTest.php | 2 +- tests/Spain/Galicia/GaliciaBaseTestCase.php | 2 +- tests/Spain/Galicia/GaliciaTest.php | 2 +- tests/Spain/Galicia/GalicianLiteratureDayTest.php | 2 +- tests/Spain/Galicia/stJamesDayTest.php | 2 +- tests/Spain/GoodFridayTest.php | 2 +- tests/Spain/ImmaculateConceptionTest.php | 2 +- tests/Spain/InternationalWorkersDayTest.php | 2 +- tests/Spain/LaRioja/LaRiojaBaseTestCase.php | 2 +- tests/Spain/LaRioja/LaRiojaDayTest.php | 2 +- tests/Spain/LaRioja/LaRiojaTest.php | 2 +- tests/Spain/MaundyThursdayTest.php | 2 +- tests/Spain/Melilla/MelillaBaseTestCase.php | 2 +- tests/Spain/Melilla/MelillaTest.php | 2 +- tests/Spain/NationalDayTest.php | 2 +- tests/Spain/Navarre/NavarreBaseTestCase.php | 2 +- tests/Spain/Navarre/NavarreTest.php | 2 +- tests/Spain/NewYearsDayTest.php | 2 +- tests/Spain/RegionOfMurcia/RegionOfMurciaBaseTestCase.php | 2 +- tests/Spain/RegionOfMurcia/RegionOfMurciaDayTest.php | 2 +- tests/Spain/RegionOfMurcia/RegionOfMurciaTest.php | 2 +- tests/Spain/SpainBaseTestCase.php | 2 +- tests/Spain/SpainTest.php | 2 +- .../Spain/ValencianCommunity/ValencianCommunityBaseTestCase.php | 2 +- tests/Spain/ValencianCommunity/ValencianCommunityDayTest.php | 2 +- tests/Spain/ValencianCommunity/ValencianCommunityTest.php | 2 +- tests/Spain/ValentinesDayTest.php | 2 +- tests/Spain/stJosephsDayTest.php | 2 +- tests/Sweden/AllSaintsDayTest.php | 2 +- tests/Sweden/AllSaintsEveTest.php | 2 +- tests/Sweden/AscensionDayTest.php | 2 +- tests/Sweden/ChristmasDayTest.php | 2 +- tests/Sweden/ChristmasEveTest.php | 2 +- tests/Sweden/EasterMondayTest.php | 2 +- tests/Sweden/EasterTest.php | 2 +- tests/Sweden/EpiphanyEveTest.php | 2 +- tests/Sweden/EpiphanyTest.php | 2 +- tests/Sweden/GoodFridayTest.php | 2 +- tests/Sweden/InternationalWorkersDayTest.php | 2 +- tests/Sweden/NationalDayTest.php | 2 +- tests/Sweden/NewYearsDayTest.php | 2 +- tests/Sweden/NewYearsEveTest.php | 2 +- tests/Sweden/PentecostTest.php | 2 +- tests/Sweden/SecondChristmasDayTest.php | 2 +- tests/Sweden/StJohnsDayTest.php | 2 +- tests/Sweden/StJohnsEveTest.php | 2 +- tests/Sweden/SwedenBaseTestCase.php | 2 +- tests/Sweden/SwedenTest.php | 2 +- tests/Sweden/WalpurgisEveTest.php | 2 +- tests/Switzerland/Aargau/AargauBaseTestCase.php | 2 +- tests/Switzerland/Aargau/AargauTest.php | 2 +- tests/Switzerland/Aargau/AscensionDayTest.php | 2 +- tests/Switzerland/Aargau/ChristmasDayTest.php | 2 +- tests/Switzerland/Aargau/GoodFridayTest.php | 2 +- tests/Switzerland/Aargau/NewYearsDayTest.php | 2 +- .../AppenzellAusserrhoden/AppenzellAusserrhodenBaseTestCase.php | 2 +- .../AppenzellAusserrhoden/AppenzellAusserrhodenTest.php | 2 +- tests/Switzerland/AppenzellAusserrhoden/AscensionDayTest.php | 2 +- tests/Switzerland/AppenzellAusserrhoden/ChristmasDayTest.php | 2 +- tests/Switzerland/AppenzellAusserrhoden/EasterMondayTest.php | 2 +- tests/Switzerland/AppenzellAusserrhoden/GoodFridayTest.php | 2 +- tests/Switzerland/AppenzellAusserrhoden/NewYearsDayTest.php | 2 +- tests/Switzerland/AppenzellAusserrhoden/PentecostMondayTest.php | 2 +- tests/Switzerland/AppenzellAusserrhoden/StStephensDayTest.php | 2 +- tests/Switzerland/AppenzellInnerrhoden/AllSaintsDayTest.php | 2 +- .../AppenzellInnerrhoden/AppenzellInnerrhodenBaseTestCase.php | 2 +- .../AppenzellInnerrhoden/AppenzellInnerrhodenTest.php | 2 +- tests/Switzerland/AppenzellInnerrhoden/AscensionDayTest.php | 2 +- tests/Switzerland/AppenzellInnerrhoden/AssumptionOfMaryTest.php | 2 +- tests/Switzerland/AppenzellInnerrhoden/ChristmasDayTest.php | 2 +- tests/Switzerland/AppenzellInnerrhoden/CorpusChristiTest.php | 2 +- tests/Switzerland/AppenzellInnerrhoden/EasterMondayTest.php | 2 +- tests/Switzerland/AppenzellInnerrhoden/GoodFridayTest.php | 2 +- .../AppenzellInnerrhoden/ImmaculateConceptionTest.php | 2 +- tests/Switzerland/AppenzellInnerrhoden/NewYearsDayTest.php | 2 +- tests/Switzerland/AppenzellInnerrhoden/PentecostMondayTest.php | 2 +- tests/Switzerland/AppenzellInnerrhoden/StStephensDayTest.php | 2 +- tests/Switzerland/BaselLandschaft/AscensionDayTest.php | 2 +- .../Switzerland/BaselLandschaft/BaselLandschaftBaseTestCase.php | 2 +- tests/Switzerland/BaselLandschaft/BaselLandschaftTest.php | 2 +- tests/Switzerland/BaselLandschaft/ChristmasDayTest.php | 2 +- tests/Switzerland/BaselLandschaft/EasterMondayTest.php | 2 +- tests/Switzerland/BaselLandschaft/GoodFridayTest.php | 2 +- tests/Switzerland/BaselLandschaft/NewYearsDayTest.php | 2 +- tests/Switzerland/BaselLandschaft/PentecostMondayTest.php | 2 +- tests/Switzerland/BaselLandschaft/StStephensDayTest.php | 2 +- tests/Switzerland/BaselLandschaft/WorkersDayTest.php | 2 +- tests/Switzerland/BaselStadt/AscensionDayTest.php | 2 +- tests/Switzerland/BaselStadt/BaselStadtBaseTestCase.php | 2 +- tests/Switzerland/BaselStadt/BaselStadtTest.php | 2 +- tests/Switzerland/BaselStadt/ChristmasDayTest.php | 2 +- tests/Switzerland/BaselStadt/EasterMondayTest.php | 2 +- tests/Switzerland/BaselStadt/GoodFridayTest.php | 2 +- tests/Switzerland/BaselStadt/NewYearsDayTest.php | 2 +- tests/Switzerland/BaselStadt/PentecostMondayTest.php | 2 +- tests/Switzerland/BaselStadt/StStephensDayTest.php | 2 +- tests/Switzerland/BaselStadt/WorkersDayTest.php | 2 +- tests/Switzerland/Bern/AscensionDayTest.php | 2 +- tests/Switzerland/Bern/BerchtoldsTagTest.php | 2 +- tests/Switzerland/Bern/BernBaseTestCase.php | 2 +- tests/Switzerland/Bern/BernTest.php | 2 +- tests/Switzerland/Bern/ChristmasDayTest.php | 2 +- tests/Switzerland/Bern/EasterMondayTest.php | 2 +- tests/Switzerland/Bern/GoodFridayTest.php | 2 +- tests/Switzerland/Bern/NewYearsDayTest.php | 2 +- tests/Switzerland/Bern/PentecostMondayTest.php | 2 +- tests/Switzerland/Bern/StStephensDayTest.php | 2 +- tests/Switzerland/Fribourg/AllSaintsDayTest.php | 2 +- tests/Switzerland/Fribourg/AscensionDayTest.php | 2 +- tests/Switzerland/Fribourg/AssumptionOfMaryTest.php | 2 +- tests/Switzerland/Fribourg/BerchtoldsTagTest.php | 2 +- tests/Switzerland/Fribourg/ChristmasDayTest.php | 2 +- tests/Switzerland/Fribourg/CorpusChristiTest.php | 2 +- tests/Switzerland/Fribourg/December26thTest.php | 2 +- tests/Switzerland/Fribourg/EasterMondayTest.php | 2 +- tests/Switzerland/Fribourg/FribourgBaseTestCase.php | 2 +- tests/Switzerland/Fribourg/FribourgTest.php | 2 +- tests/Switzerland/Fribourg/GoodFridayTest.php | 2 +- tests/Switzerland/Fribourg/ImmaculateConceptionTest.php | 2 +- tests/Switzerland/Fribourg/NewYearsDayTest.php | 2 +- tests/Switzerland/Fribourg/PentecostMondayTest.php | 2 +- tests/Switzerland/Geneva/AscensionDayTest.php | 2 +- tests/Switzerland/Geneva/ChristmasDayTest.php | 2 +- tests/Switzerland/Geneva/EasterMondayTest.php | 2 +- tests/Switzerland/Geneva/GenevaBaseTestCase.php | 2 +- tests/Switzerland/Geneva/GenevaTest.php | 2 +- tests/Switzerland/Geneva/GoodFridayTest.php | 2 +- tests/Switzerland/Geneva/JeuneGenevoisTest.php | 2 +- tests/Switzerland/Geneva/NewYearsDayTest.php | 2 +- tests/Switzerland/Geneva/PentecostMondayTest.php | 2 +- tests/Switzerland/Geneva/RestaurationGenevoiseTest.php | 2 +- tests/Switzerland/Glarus/AllSaintsDayTest.php | 2 +- tests/Switzerland/Glarus/AscensionDayTest.php | 2 +- tests/Switzerland/Glarus/BerchtoldsTagTest.php | 2 +- tests/Switzerland/Glarus/ChristmasDayTest.php | 2 +- tests/Switzerland/Glarus/EasterMondayTest.php | 2 +- tests/Switzerland/Glarus/GlarusBaseTestCase.php | 2 +- tests/Switzerland/Glarus/GlarusTest.php | 2 +- tests/Switzerland/Glarus/GoodFridayTest.php | 2 +- tests/Switzerland/Glarus/NafelserFahrtTest.php | 2 +- tests/Switzerland/Glarus/NewYearsDayTest.php | 2 +- tests/Switzerland/Glarus/PentecostMondayTest.php | 2 +- tests/Switzerland/Glarus/StStephensDayTest.php | 2 +- tests/Switzerland/Grisons/AscensionDayTest.php | 2 +- tests/Switzerland/Grisons/ChristmasDayTest.php | 2 +- tests/Switzerland/Grisons/EasterMondayTest.php | 2 +- tests/Switzerland/Grisons/GoodFridayTest.php | 2 +- tests/Switzerland/Grisons/GrisonsBaseTestCase.php | 2 +- tests/Switzerland/Grisons/GrisonsTest.php | 2 +- tests/Switzerland/Grisons/NewYearsDayTest.php | 2 +- tests/Switzerland/Grisons/PentecostMondayTest.php | 2 +- tests/Switzerland/Grisons/StStephensDayTest.php | 2 +- tests/Switzerland/Jura/AllSaintsDayTest.php | 2 +- tests/Switzerland/Jura/AscensionDayTest.php | 2 +- tests/Switzerland/Jura/AssumptionOfMaryTest.php | 2 +- tests/Switzerland/Jura/BerchtoldsTagTest.php | 2 +- tests/Switzerland/Jura/BettagsMontagTest.php | 2 +- tests/Switzerland/Jura/ChristmasDayTest.php | 2 +- tests/Switzerland/Jura/CorpusChristiTest.php | 2 +- tests/Switzerland/Jura/EasterMondayTest.php | 2 +- tests/Switzerland/Jura/EasterTest.php | 2 +- tests/Switzerland/Jura/GoodFridayTest.php | 2 +- tests/Switzerland/Jura/JuraBaseTestCase.php | 2 +- tests/Switzerland/Jura/JuraTest.php | 2 +- tests/Switzerland/Jura/NewYearsDayTest.php | 2 +- tests/Switzerland/Jura/PentecostMondayTest.php | 2 +- tests/Switzerland/Jura/PentecostTest.php | 2 +- tests/Switzerland/Jura/PlebisciteJurassienTest.php | 2 +- tests/Switzerland/Jura/WorkersDayTest.php | 2 +- tests/Switzerland/Lucerne/AllSaintsDayTest.php | 2 +- tests/Switzerland/Lucerne/AscensionDayTest.php | 2 +- tests/Switzerland/Lucerne/AssumptionOfMaryTest.php | 2 +- tests/Switzerland/Lucerne/BerchtoldsTagTest.php | 2 +- tests/Switzerland/Lucerne/ChristmasDayTest.php | 2 +- tests/Switzerland/Lucerne/CorpusChristiTest.php | 2 +- tests/Switzerland/Lucerne/EasterMondayTest.php | 2 +- tests/Switzerland/Lucerne/GoodFridayTest.php | 2 +- tests/Switzerland/Lucerne/ImmaculateConceptionTest.php | 2 +- tests/Switzerland/Lucerne/LucerneBaseTestCase.php | 2 +- tests/Switzerland/Lucerne/LucerneTest.php | 2 +- tests/Switzerland/Lucerne/NewYearsDayTest.php | 2 +- tests/Switzerland/Lucerne/PentecostMondayTest.php | 2 +- tests/Switzerland/Lucerne/StStephensDayTest.php | 2 +- tests/Switzerland/Neuchatel/AscensionDayTest.php | 2 +- tests/Switzerland/Neuchatel/BettagsMontagTest.php | 2 +- tests/Switzerland/Neuchatel/ChristmasDayTest.php | 2 +- tests/Switzerland/Neuchatel/December26thTest.php | 2 +- tests/Switzerland/Neuchatel/EasterMondayTest.php | 2 +- tests/Switzerland/Neuchatel/GoodFridayTest.php | 2 +- tests/Switzerland/Neuchatel/InstaurationRepubliqueTest.php | 2 +- tests/Switzerland/Neuchatel/January2ndTest.php | 2 +- tests/Switzerland/Neuchatel/NeuchatelBaseTestCase.php | 2 +- tests/Switzerland/Neuchatel/NeuchatelTest.php | 2 +- tests/Switzerland/Neuchatel/NewYearsDayTest.php | 2 +- tests/Switzerland/Neuchatel/PentecostMondayTest.php | 2 +- tests/Switzerland/Neuchatel/WorkersDayTest.php | 2 +- tests/Switzerland/Nidwalden/AllSaintsDayTest.php | 2 +- tests/Switzerland/Nidwalden/AscensionDayTest.php | 2 +- tests/Switzerland/Nidwalden/AssumptionOfMaryTest.php | 2 +- tests/Switzerland/Nidwalden/ChristmasDayTest.php | 2 +- tests/Switzerland/Nidwalden/CorpusChristiTest.php | 2 +- tests/Switzerland/Nidwalden/EasterMondayTest.php | 2 +- tests/Switzerland/Nidwalden/GoodFridayTest.php | 2 +- tests/Switzerland/Nidwalden/ImmaculateConceptionTest.php | 2 +- tests/Switzerland/Nidwalden/NewYearsDayTest.php | 2 +- tests/Switzerland/Nidwalden/NidwaldenBaseTestCase.php | 2 +- tests/Switzerland/Nidwalden/NidwaldenTest.php | 2 +- tests/Switzerland/Nidwalden/PentecostMondayTest.php | 2 +- tests/Switzerland/Nidwalden/StJosephDayTest.php | 2 +- tests/Switzerland/Nidwalden/StStephensDayTest.php | 2 +- tests/Switzerland/Obwalden/AllSaintsDayTest.php | 2 +- tests/Switzerland/Obwalden/AscensionDayTest.php | 2 +- tests/Switzerland/Obwalden/AssumptionOfMaryTest.php | 2 +- tests/Switzerland/Obwalden/BerchtoldsTagTest.php | 2 +- tests/Switzerland/Obwalden/BruderKlausenFestTest.php | 2 +- tests/Switzerland/Obwalden/ChristmasDayTest.php | 2 +- tests/Switzerland/Obwalden/CorpusChristiTest.php | 2 +- tests/Switzerland/Obwalden/EasterMondayTest.php | 2 +- tests/Switzerland/Obwalden/GoodFridayTest.php | 2 +- tests/Switzerland/Obwalden/ImmaculateConceptionTest.php | 2 +- tests/Switzerland/Obwalden/NewYearsDayTest.php | 2 +- tests/Switzerland/Obwalden/ObwaldenBaseTestCase.php | 2 +- tests/Switzerland/Obwalden/ObwaldenTest.php | 2 +- tests/Switzerland/Obwalden/PentecostMondayTest.php | 2 +- tests/Switzerland/Obwalden/StStephensDayTest.php | 2 +- tests/Switzerland/Schaffhausen/AscensionDayTest.php | 2 +- tests/Switzerland/Schaffhausen/BerchtoldsTagTest.php | 2 +- tests/Switzerland/Schaffhausen/ChristmasDayTest.php | 2 +- tests/Switzerland/Schaffhausen/EasterMondayTest.php | 2 +- tests/Switzerland/Schaffhausen/GoodFridayTest.php | 2 +- tests/Switzerland/Schaffhausen/NewYearsDayTest.php | 2 +- tests/Switzerland/Schaffhausen/PentecostMondayTest.php | 2 +- tests/Switzerland/Schaffhausen/SchaffhausenBaseTestCase.php | 2 +- tests/Switzerland/Schaffhausen/SchaffhausenTest.php | 2 +- tests/Switzerland/Schaffhausen/StStephensDayTest.php | 2 +- tests/Switzerland/Schaffhausen/WorkersDayTest.php | 2 +- tests/Switzerland/Schwyz/AllSaintsDayTest.php | 2 +- tests/Switzerland/Schwyz/AscensionDayTest.php | 2 +- tests/Switzerland/Schwyz/AssumptionOfMaryTest.php | 2 +- tests/Switzerland/Schwyz/ChristmasDayTest.php | 2 +- tests/Switzerland/Schwyz/CorpusChristiTest.php | 2 +- tests/Switzerland/Schwyz/EasterMondayTest.php | 2 +- tests/Switzerland/Schwyz/EpiphanyTest.php | 2 +- tests/Switzerland/Schwyz/GoodFridayTest.php | 2 +- tests/Switzerland/Schwyz/ImmaculateConceptionTest.php | 2 +- tests/Switzerland/Schwyz/NewYearsDayTest.php | 2 +- tests/Switzerland/Schwyz/PentecostMondayTest.php | 2 +- tests/Switzerland/Schwyz/SchwyzBaseTestCase.php | 2 +- tests/Switzerland/Schwyz/SchwyzTest.php | 2 +- tests/Switzerland/Schwyz/StJosephDayTest.php | 2 +- tests/Switzerland/Schwyz/StStephensDayTest.php | 2 +- tests/Switzerland/Solothurn/AscensionDayTest.php | 2 +- tests/Switzerland/Solothurn/BerchtoldsTagTest.php | 2 +- tests/Switzerland/Solothurn/ChristmasDayTest.php | 2 +- tests/Switzerland/Solothurn/GoodFridayTest.php | 2 +- tests/Switzerland/Solothurn/NewYearsDayTest.php | 2 +- tests/Switzerland/Solothurn/SolothurnBaseTestCase.php | 2 +- tests/Switzerland/Solothurn/SolothurnTest.php | 2 +- tests/Switzerland/StGallen/AllSaintsDayTest.php | 2 +- tests/Switzerland/StGallen/AscensionDayTest.php | 2 +- tests/Switzerland/StGallen/ChristmasDayTest.php | 2 +- tests/Switzerland/StGallen/EasterMondayTest.php | 2 +- tests/Switzerland/StGallen/GoodFridayTest.php | 2 +- tests/Switzerland/StGallen/NewYearsDayTest.php | 2 +- tests/Switzerland/StGallen/PentecostMondayTest.php | 2 +- tests/Switzerland/StGallen/StGallenBaseTestCase.php | 2 +- tests/Switzerland/StGallen/StGallenTest.php | 2 +- tests/Switzerland/StGallen/StStephensDayTest.php | 2 +- tests/Switzerland/SwissNationalDayTest.php | 2 +- tests/Switzerland/SwitzerlandBaseTestCase.php | 2 +- tests/Switzerland/SwitzerlandTest.php | 2 +- tests/Switzerland/Thurgau/AscensionDayTest.php | 2 +- tests/Switzerland/Thurgau/BerchtoldsTagTest.php | 2 +- tests/Switzerland/Thurgau/ChristmasDayTest.php | 2 +- tests/Switzerland/Thurgau/EasterMondayTest.php | 2 +- tests/Switzerland/Thurgau/GoodFridayTest.php | 2 +- tests/Switzerland/Thurgau/NewYearsDayTest.php | 2 +- tests/Switzerland/Thurgau/PentecostMondayTest.php | 2 +- tests/Switzerland/Thurgau/StStephensDayTest.php | 2 +- tests/Switzerland/Thurgau/ThurgauBaseTestCase.php | 2 +- tests/Switzerland/Thurgau/ThurgauTest.php | 2 +- tests/Switzerland/Thurgau/WorkersDayTest.php | 2 +- tests/Switzerland/Ticino/AllSaintsDayTest.php | 2 +- tests/Switzerland/Ticino/AscensionDayTest.php | 2 +- tests/Switzerland/Ticino/AssumptionOfMaryTest.php | 2 +- tests/Switzerland/Ticino/ChristmasDayTest.php | 2 +- tests/Switzerland/Ticino/CorpusChristiTest.php | 2 +- tests/Switzerland/Ticino/EasterMondayTest.php | 2 +- tests/Switzerland/Ticino/EpiphanyTest.php | 2 +- tests/Switzerland/Ticino/ImmaculateConceptionTest.php | 2 +- tests/Switzerland/Ticino/NewYearsDayTest.php | 2 +- tests/Switzerland/Ticino/PentecostMondayTest.php | 2 +- tests/Switzerland/Ticino/StJosephDayTest.php | 2 +- tests/Switzerland/Ticino/StPeterPaulTest.php | 2 +- tests/Switzerland/Ticino/StStephensDayTest.php | 2 +- tests/Switzerland/Ticino/TicinoBaseTestCase.php | 2 +- tests/Switzerland/Ticino/TicinoTest.php | 2 +- tests/Switzerland/Ticino/WorkersDayTest.php | 2 +- tests/Switzerland/Uri/AllSaintsDayTest.php | 2 +- tests/Switzerland/Uri/AscensionDayTest.php | 2 +- tests/Switzerland/Uri/AssumptionOfMaryTest.php | 2 +- tests/Switzerland/Uri/ChristmasDayTest.php | 2 +- tests/Switzerland/Uri/CorpusChristiTest.php | 2 +- tests/Switzerland/Uri/EasterMondayTest.php | 2 +- tests/Switzerland/Uri/EpiphanyTest.php | 2 +- tests/Switzerland/Uri/GoodFridayTest.php | 2 +- tests/Switzerland/Uri/ImmaculateConceptionTest.php | 2 +- tests/Switzerland/Uri/NewYearsDayTest.php | 2 +- tests/Switzerland/Uri/PentecostMondayTest.php | 2 +- tests/Switzerland/Uri/StJosephDayTest.php | 2 +- tests/Switzerland/Uri/StStephensDayTest.php | 2 +- tests/Switzerland/Uri/UriBaseTestCase.php | 2 +- tests/Switzerland/Uri/UriTest.php | 2 +- tests/Switzerland/Valais/AllSaintsDayTest.php | 2 +- tests/Switzerland/Valais/AscensionDayTest.php | 2 +- tests/Switzerland/Valais/AssumptionOfMaryTest.php | 2 +- tests/Switzerland/Valais/ChristmasDayTest.php | 2 +- tests/Switzerland/Valais/CorpusChristiTest.php | 2 +- tests/Switzerland/Valais/ImmaculateConceptionTest.php | 2 +- tests/Switzerland/Valais/NewYearsDayTest.php | 2 +- tests/Switzerland/Valais/StJosephDayTest.php | 2 +- tests/Switzerland/Valais/ValaisBaseTestCase.php | 2 +- tests/Switzerland/Valais/ValaisTest.php | 2 +- tests/Switzerland/Vaud/AscensionDayTest.php | 2 +- tests/Switzerland/Vaud/BerchtoldsTagTest.php | 2 +- tests/Switzerland/Vaud/BettagsMontagTest.php | 2 +- tests/Switzerland/Vaud/ChristmasDayTest.php | 2 +- tests/Switzerland/Vaud/EasterMondayTest.php | 2 +- tests/Switzerland/Vaud/GoodFridayTest.php | 2 +- tests/Switzerland/Vaud/NewYearsDayTest.php | 2 +- tests/Switzerland/Vaud/PentecostMondayTest.php | 2 +- tests/Switzerland/Vaud/VaudBaseTestCase.php | 2 +- tests/Switzerland/Vaud/VaudTest.php | 2 +- tests/Switzerland/Zug/AllSaintsDayTest.php | 2 +- tests/Switzerland/Zug/AscensionDayTest.php | 2 +- tests/Switzerland/Zug/AssumptionOfMaryTest.php | 2 +- tests/Switzerland/Zug/BerchtoldsTagTest.php | 2 +- tests/Switzerland/Zug/ChristmasDayTest.php | 2 +- tests/Switzerland/Zug/CorpusChristiTest.php | 2 +- tests/Switzerland/Zug/EasterMondayTest.php | 2 +- tests/Switzerland/Zug/GoodFridayTest.php | 2 +- tests/Switzerland/Zug/ImmaculateConceptionTest.php | 2 +- tests/Switzerland/Zug/NewYearsDayTest.php | 2 +- tests/Switzerland/Zug/PentecostMondayTest.php | 2 +- tests/Switzerland/Zug/StStephensDayTest.php | 2 +- tests/Switzerland/Zug/ZugBaseTestCase.php | 2 +- tests/Switzerland/Zug/ZugTest.php | 2 +- tests/Switzerland/Zurich/AscensionDayTest.php | 2 +- tests/Switzerland/Zurich/ChristmasDayTest.php | 2 +- tests/Switzerland/Zurich/EasterMondayTest.php | 2 +- tests/Switzerland/Zurich/GoodFridayTest.php | 2 +- tests/Switzerland/Zurich/NewYearsDayTest.php | 2 +- tests/Switzerland/Zurich/PentecostMondayTest.php | 2 +- tests/Switzerland/Zurich/StStephensDayTest.php | 2 +- tests/Switzerland/Zurich/WorkersDayTest.php | 2 +- tests/Switzerland/Zurich/ZurichBaseTestCase.php | 2 +- tests/Switzerland/Zurich/ZurichTest.php | 2 +- tests/Turkey/CommemorationOfAtaturkTest.php | 2 +- tests/Turkey/DemocracyDayTest.php | 2 +- tests/Turkey/LabourDayTest.php | 2 +- tests/Turkey/NationalSovereigntyDayTest.php | 2 +- tests/Turkey/NewYearsDayTest.php | 2 +- tests/Turkey/RepublicDayTest.php | 2 +- tests/Turkey/TurkeyBaseTestCase.php | 2 +- tests/Turkey/TurkeyTest.php | 2 +- tests/Turkey/VictoryDayTest.php | 2 +- tests/USA/ChristmasDayTest.php | 2 +- tests/USA/ColumbusDayTest.php | 2 +- tests/USA/IndependenceDayTest.php | 2 +- tests/USA/JuneteenthTest.php | 2 +- tests/USA/LabourDayTest.php | 2 +- tests/USA/MartinLutherKingDayTest.php | 2 +- tests/USA/MemorialDayTest.php | 2 +- tests/USA/NewYearsDayTest.php | 2 +- tests/USA/ThanksgivingDayTest.php | 2 +- tests/USA/USABaseTestCase.php | 2 +- tests/USA/USATest.php | 2 +- tests/USA/VeteransDayTest.php | 2 +- tests/USA/WashingtonsBirthdayTest.php | 2 +- tests/Ukraine/CatholicChristmasDayTest.php | 2 +- tests/Ukraine/ChristmasDayTest.php | 2 +- tests/Ukraine/ConstitutionDayTest.php | 2 +- tests/Ukraine/DefenderOfUkraineDayTest.php | 2 +- tests/Ukraine/EasterTest.php | 2 +- tests/Ukraine/IndependenceDayTest.php | 2 +- tests/Ukraine/InternationalWomensDayTest.php | 2 +- tests/Ukraine/InternationalWorkersDayTest.php | 2 +- tests/Ukraine/NewYearsDayTest.php | 2 +- tests/Ukraine/PentecostTest.php | 2 +- tests/Ukraine/SecondInternationalWorkersDayTest.php | 2 +- tests/Ukraine/SubstitutedHolidayTest.php | 2 +- tests/Ukraine/UkraineBaseTestCase.php | 2 +- tests/Ukraine/UkraineTest.php | 2 +- tests/Ukraine/VictoryDayTest.php | 2 +- tests/UnitedKingdom/BoxingDayTest.php | 2 +- tests/UnitedKingdom/ChristmasDayTest.php | 2 +- tests/UnitedKingdom/EasterMondayTest.php | 2 +- tests/UnitedKingdom/England/BoxingDayTest.php | 2 +- tests/UnitedKingdom/England/ChristmasDayTest.php | 2 +- tests/UnitedKingdom/England/EasterMondayTest.php | 2 +- tests/UnitedKingdom/England/EnglandBaseTestCase.php | 2 +- tests/UnitedKingdom/England/EnglandTest.php | 2 +- tests/UnitedKingdom/England/GoodFridayTest.php | 2 +- tests/UnitedKingdom/England/MayDayBankHolidayTest.php | 2 +- tests/UnitedKingdom/England/NewYearsDayTest.php | 2 +- tests/UnitedKingdom/England/SpringBankHolidayTest.php | 2 +- tests/UnitedKingdom/England/SummerBankHolidayTest.php | 2 +- tests/UnitedKingdom/GoodFridayTest.php | 2 +- tests/UnitedKingdom/MayDayBankHolidayTest.php | 2 +- tests/UnitedKingdom/MotheringSundayTest.php | 2 +- tests/UnitedKingdom/NewYearsDayTest.php | 2 +- tests/UnitedKingdom/NorthernIreland/BattleOfTheBoyneTest.php | 2 +- tests/UnitedKingdom/NorthernIreland/BoxingDayTest.php | 2 +- tests/UnitedKingdom/NorthernIreland/ChristmasDayTest.php | 2 +- tests/UnitedKingdom/NorthernIreland/EasterMondayTest.php | 2 +- tests/UnitedKingdom/NorthernIreland/GoodFridayTest.php | 2 +- tests/UnitedKingdom/NorthernIreland/MayDayBankHolidayTest.php | 2 +- tests/UnitedKingdom/NorthernIreland/NewYearsDayTest.php | 2 +- .../NorthernIreland/NorthernIrelandBaseTestCase.php | 2 +- tests/UnitedKingdom/NorthernIreland/NorthernIrelandTest.php | 2 +- tests/UnitedKingdom/NorthernIreland/SpringBankHolidayTest.php | 2 +- tests/UnitedKingdom/NorthernIreland/StPatricksDayTest.php | 2 +- tests/UnitedKingdom/NorthernIreland/SummerBankHolidayTest.php | 2 +- tests/UnitedKingdom/PlatinumJubileeBankHolidayTest.php | 2 +- tests/UnitedKingdom/QueenElizabethFuneralBankHolidayTest.php | 2 +- tests/UnitedKingdom/Scotland/BoxingDayTest.php | 2 +- tests/UnitedKingdom/Scotland/ChristmasDayTest.php | 2 +- tests/UnitedKingdom/Scotland/GoodFridayTest.php | 2 +- tests/UnitedKingdom/Scotland/MayDayBankHolidayTest.php | 2 +- tests/UnitedKingdom/Scotland/NewYearsDayTest.php | 2 +- tests/UnitedKingdom/Scotland/ScotlandBaseTestCase.php | 2 +- tests/UnitedKingdom/Scotland/ScotlandTest.php | 2 +- tests/UnitedKingdom/Scotland/SecondNewYearsDayTest.php | 2 +- tests/UnitedKingdom/Scotland/SpringBankHolidayTest.php | 2 +- tests/UnitedKingdom/Scotland/StAndrewsDayTest.php | 2 +- tests/UnitedKingdom/Scotland/SummerBankHolidayTest.php | 2 +- tests/UnitedKingdom/SpringBankHolidayTest.php | 2 +- tests/UnitedKingdom/SummerBankHolidayTest.php | 2 +- tests/UnitedKingdom/UnitedKingdomBaseTestCase.php | 2 +- tests/UnitedKingdom/UnitedKingdomTest.php | 2 +- tests/UnitedKingdom/Wales/BoxingDayTest.php | 2 +- tests/UnitedKingdom/Wales/ChristmasDayTest.php | 2 +- tests/UnitedKingdom/Wales/EasterMondayTest.php | 2 +- tests/UnitedKingdom/Wales/GoodFridayTest.php | 2 +- tests/UnitedKingdom/Wales/MayDayBankHolidayTest.php | 2 +- tests/UnitedKingdom/Wales/NewYearsDayTest.php | 2 +- tests/UnitedKingdom/Wales/SpringBankHolidayTest.php | 2 +- tests/UnitedKingdom/Wales/SummerBankHolidayTest.php | 2 +- tests/UnitedKingdom/Wales/WalesBaseTestCase.php | 2 +- tests/UnitedKingdom/Wales/WalesTest.php | 2 +- tests/YasumiBase.php | 2 +- 1675 files changed, 1675 insertions(+), 1675 deletions(-) diff --git a/.php-cs-fixer.php b/.php-cs-fixer.php index 633b53776..9d590d894 100644 --- a/.php-cs-fixer.php +++ b/.php-cs-fixer.php @@ -3,7 +3,7 @@ /** * This file is part of the Yasumi package. * - * Copyright (c) 2015 - 2022 AzuyaLabs + * Copyright (c) 2015 - 2023 AzuyaLabs * * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. diff --git a/LICENSE b/LICENSE index cd30fd146..5276fcb26 100644 --- a/LICENSE +++ b/LICENSE @@ -1,6 +1,6 @@ The MIT License (MIT) -Copyright (c) 2015 - 2022 AzuyaLabs +Copyright (c) 2015 - 2023 AzuyaLabs Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal diff --git a/phpunit.xml.dist b/phpunit.xml.dist index c7356f333..ba4a53739 100644 --- a/phpunit.xml.dist +++ b/phpunit.xml.dist @@ -2,7 +2,7 @@