@@ -711,32 +711,20 @@ public function someFunction()
711711
712712 public function testCanAddTraitWithString ()
713713 {
714- if (version_compare (PHP_VERSION , '5.4 ' , 'lt ' )) {
715- $ this ->markTestSkipped ('This test requires PHP version 5.4+ ' );
716- }
717-
718714 $ classGenerator = new ClassGenerator ();
719715 $ classGenerator ->addTrait ('myTrait ' );
720716 $ this ->assertTrue ($ classGenerator ->hasTrait ('myTrait ' ));
721717 }
722718
723719 public function testCanAddTraitWithArray ()
724720 {
725- if (version_compare (PHP_VERSION , '5.4 ' , 'lt ' )) {
726- $ this ->markTestSkipped ('This test requires PHP version 5.4+ ' );
727- }
728-
729721 $ classGenerator = new ClassGenerator ();
730722 $ classGenerator ->addTrait (['traitName ' => 'myTrait ' ]);
731723 $ this ->assertTrue ($ classGenerator ->hasTrait ('myTrait ' ));
732724 }
733725
734726 public function testCanRemoveTrait ()
735727 {
736- if (version_compare (PHP_VERSION , '5.4 ' , 'lt ' )) {
737- $ this ->markTestSkipped ('This test requires PHP version 5.4+ ' );
738- }
739-
740728 $ classGenerator = new ClassGenerator ();
741729 $ classGenerator ->addTrait (['traitName ' => 'myTrait ' ]);
742730 $ this ->assertTrue ($ classGenerator ->hasTrait ('myTrait ' ));
@@ -746,10 +734,6 @@ public function testCanRemoveTrait()
746734
747735 public function testCanGetTraitsMethod ()
748736 {
749- if (version_compare (PHP_VERSION , '5.4 ' , 'lt ' )) {
750- $ this ->markTestSkipped ('This test requires PHP version 5.4+ ' );
751- }
752-
753737 $ classGenerator = new ClassGenerator ();
754738 $ classGenerator ->addTraits (['myTrait ' , 'hisTrait ' ]);
755739
@@ -760,10 +744,6 @@ public function testCanGetTraitsMethod()
760744
761745 public function testCanAddTraitAliasWithString ()
762746 {
763- if (version_compare (PHP_VERSION , '5.4 ' , 'lt ' )) {
764- $ this ->markTestSkipped ('This test requires PHP version 5.4+ ' );
765- }
766-
767747 $ classGenerator = new ClassGenerator ();
768748
769749 $ classGenerator ->addTrait ('myTrait ' );
@@ -777,10 +757,6 @@ public function testCanAddTraitAliasWithString()
777757
778758 public function testCanAddTraitAliasWithArray ()
779759 {
780- if (version_compare (PHP_VERSION , '5.4 ' , 'lt ' )) {
781- $ this ->markTestSkipped ('This test requires PHP version 5.4+ ' );
782- }
783-
784760 $ classGenerator = new ClassGenerator ();
785761
786762 $ classGenerator ->addTrait ('myTrait ' );
@@ -797,10 +773,6 @@ public function testCanAddTraitAliasWithArray()
797773
798774 public function testAddTraitAliasExceptionInvalidMethodFormat ()
799775 {
800- if (version_compare (PHP_VERSION , '5.4 ' , 'lt ' )) {
801- $ this ->markTestSkipped ('This test requires PHP version 5.4+ ' );
802- }
803-
804776 $ classGenerator = new ClassGenerator ();
805777
806778 $ this ->setExpectedException (
@@ -814,10 +786,6 @@ public function testAddTraitAliasExceptionInvalidMethodFormat()
814786
815787 public function testAddTraitAliasExceptionInvalidMethodTraitDoesNotExist ()
816788 {
817- if (version_compare (PHP_VERSION , '5.4 ' , 'lt ' )) {
818- $ this ->markTestSkipped ('This test requires PHP version 5.4+ ' );
819- }
820-
821789 $ classGenerator = new ClassGenerator ();
822790
823791 $ this ->setExpectedException (
@@ -831,10 +799,6 @@ public function testAddTraitAliasExceptionInvalidMethodTraitDoesNotExist()
831799
832800 public function testAddTraitAliasExceptionMethodAlreadyExists ()
833801 {
834- if (version_compare (PHP_VERSION , '5.4 ' , 'lt ' )) {
835- $ this ->markTestSkipped ('This test requires PHP version 5.4+ ' );
836- }
837-
838802 $ classGenerator = new ClassGenerator ();
839803
840804 $ this ->setExpectedException (
@@ -849,10 +813,6 @@ public function testAddTraitAliasExceptionMethodAlreadyExists()
849813
850814 public function testAddTraitAliasExceptionInvalidVisibilityValue ()
851815 {
852- if (version_compare (PHP_VERSION , '5.4 ' , 'lt ' )) {
853- $ this ->markTestSkipped ('This test requires PHP version 5.4+ ' );
854- }
855-
856816 $ classGenerator = new ClassGenerator ();
857817
858818 $ this ->setExpectedException (
@@ -867,10 +827,6 @@ public function testAddTraitAliasExceptionInvalidVisibilityValue()
867827
868828 public function testAddTraitAliasExceptionInvalidAliasArgument ()
869829 {
870- if (version_compare (PHP_VERSION , '5.4 ' , 'lt ' )) {
871- $ this ->markTestSkipped ('This test requires PHP version 5.4+ ' );
872- }
873-
874830 $ classGenerator = new ClassGenerator ();
875831
876832 $ this ->setExpectedException (
@@ -884,10 +840,6 @@ public function testAddTraitAliasExceptionInvalidAliasArgument()
884840
885841 public function testCanAddTraitOverride ()
886842 {
887- if (version_compare (PHP_VERSION , '5.4 ' , 'lt ' )) {
888- $ this ->markTestSkipped ('This test requires PHP version 5.4+ ' );
889- }
890-
891843 $ classGenerator = new ClassGenerator ();
892844 $ classGenerator ->addTraits (['myTrait ' , 'histTrait ' ]);
893845 $ classGenerator ->addTraitOverride ('myTrait::foo ' , 'hisTrait ' );
@@ -900,10 +852,6 @@ public function testCanAddTraitOverride()
900852
901853 public function testCanAddMultipleTraitOverrides ()
902854 {
903- if (version_compare (PHP_VERSION , '5.4 ' , 'lt ' )) {
904- $ this ->markTestSkipped ('This test requires PHP version 5.4+ ' );
905- }
906-
907855 $ classGenerator = new ClassGenerator ();
908856 $ classGenerator ->addTraits (['myTrait ' , 'histTrait ' , 'thatTrait ' ]);
909857 $ classGenerator ->addTraitOverride ('myTrait::foo ' , ['hisTrait ' , 'thatTrait ' ]);
@@ -915,10 +863,6 @@ public function testCanAddMultipleTraitOverrides()
915863
916864 public function testAddTraitOverrideExceptionInvalidMethodFormat ()
917865 {
918- if (version_compare (PHP_VERSION , '5.4 ' , 'lt ' )) {
919- $ this ->markTestSkipped ('This test requires PHP version 5.4+ ' );
920- }
921-
922866 $ classGenerator = new ClassGenerator ();
923867
924868 $ this ->setExpectedException (
@@ -932,10 +876,6 @@ public function testAddTraitOverrideExceptionInvalidMethodFormat()
932876
933877 public function testAddTraitOverrideExceptionInvalidMethodTraitDoesNotExist ()
934878 {
935- if (version_compare (PHP_VERSION , '5.4 ' , 'lt ' )) {
936- $ this ->markTestSkipped ('This test requires PHP version 5.4+ ' );
937- }
938-
939879 $ classGenerator = new ClassGenerator ();
940880
941881 $ this ->setExpectedException (
@@ -949,10 +889,6 @@ public function testAddTraitOverrideExceptionInvalidMethodTraitDoesNotExist()
949889
950890 public function testAddTraitOverrideExceptionInvalidTraitName ()
951891 {
952- if (version_compare (PHP_VERSION , '5.4 ' , 'lt ' )) {
953- $ this ->markTestSkipped ('This test requires PHP version 5.4+ ' );
954- }
955-
956892 $ classGenerator = new ClassGenerator ();
957893
958894 $ this ->setExpectedException (
@@ -966,10 +902,6 @@ public function testAddTraitOverrideExceptionInvalidTraitName()
966902
967903 public function testAddTraitOverrideExceptionInvalidTraitToReplaceArgument ()
968904 {
969- if (version_compare (PHP_VERSION , '5.4 ' , 'lt ' )) {
970- $ this ->markTestSkipped ('This test requires PHP version 5.4+ ' );
971- }
972-
973905 $ classGenerator = new ClassGenerator ();
974906
975907 $ this ->setExpectedException (
@@ -983,10 +915,6 @@ public function testAddTraitOverrideExceptionInvalidTraitToReplaceArgument()
983915
984916 public function testAddTraitOverrideExceptionInvalidMethodArgInArray ()
985917 {
986- if (version_compare (PHP_VERSION , '5.4 ' , 'lt ' )) {
987- $ this ->markTestSkipped ('This test requires PHP version 5.4+ ' );
988- }
989-
990918 $ classGenerator = new ClassGenerator ();
991919
992920 $ this ->setExpectedException (
@@ -1000,10 +928,6 @@ public function testAddTraitOverrideExceptionInvalidMethodArgInArray()
1000928
1001929 public function testCanRemoveTraitOverride ()
1002930 {
1003- if (version_compare (PHP_VERSION , '5.4 ' , 'lt ' )) {
1004- $ this ->markTestSkipped ('This test requires PHP version 5.4+ ' );
1005- }
1006-
1007931 $ classGenerator = new ClassGenerator ();
1008932 $ classGenerator ->addTraits (['myTrait ' , 'histTrait ' , 'thatTrait ' ]);
1009933 $ classGenerator ->addTraitOverride ('myTrait::foo ' , ['hisTrait ' , 'thatTrait ' ]);
@@ -1020,10 +944,6 @@ public function testCanRemoveTraitOverride()
1020944
1021945 public function testCanRemoveAllTraitOverrides ()
1022946 {
1023- if (version_compare (PHP_VERSION , '5.4 ' , 'lt ' )) {
1024- $ this ->markTestSkipped ('This test requires PHP version 5.4+ ' );
1025- }
1026-
1027947 $ classGenerator = new ClassGenerator ();
1028948 $ classGenerator ->addTraits (['myTrait ' , 'histTrait ' , 'thatTrait ' ]);
1029949 $ classGenerator ->addTraitOverride ('myTrait::foo ' , ['hisTrait ' , 'thatTrait ' ]);
@@ -1042,10 +962,6 @@ public function testCanRemoveAllTraitOverrides()
1042962 */
1043963 public function testUseTraitGeneration ()
1044964 {
1045- if (version_compare (PHP_VERSION , '5.4 ' , 'lt ' )) {
1046- $ this ->markTestSkipped ('This test requires PHP version 5.4+ ' );
1047- }
1048-
1049965 $ classGenerator = new ClassGenerator ();
1050966 $ classGenerator ->setName ('myClass ' );
1051967 $ classGenerator ->addTrait ('myTrait ' );
@@ -1070,10 +986,6 @@ class myClass
1070986 */
1071987 public function testTraitGenerationWithAliasesAndOverrides ()
1072988 {
1073- if (version_compare (PHP_VERSION , '5.4 ' , 'lt ' )) {
1074- $ this ->markTestSkipped ('This test requires PHP version 5.4+ ' );
1075- }
1076-
1077989 $ classGenerator = new ClassGenerator ();
1078990 $ classGenerator ->setName ('myClass ' );
1079991 $ classGenerator ->addTrait ('myTrait ' );
0 commit comments