File tree 2 files changed +21
-1
lines changed
2 files changed +21
-1
lines changed Original file line number Diff line number Diff line change 6
6
- 5.5
7
7
- 5.6
8
8
- 7.0
9
+ - 7.1
9
10
- hhvm
10
11
branches :
11
12
except :
Original file line number Diff line number Diff line change @@ -74,10 +74,29 @@ public function testExceptionOnMissingCommandID()
74
74
* argument is missing, PHP emits an E_WARNING.
75
75
*
76
76
* @group disconnected
77
- * @expectedException \PHPUnit_Framework_Error_Warning
78
77
*/
79
78
public function testPHPWarningOnMissingCommandIDWithStaticCreate ()
80
79
{
80
+ if (version_compare (PHP_VERSION , "7.1 " , '> ' )) {
81
+ $ this ->markTestSkipped ('only for PHP < 7.1 ' );
82
+ }
83
+ $ this ->setExpectedException ('PHPUnit_Framework_Error_Warning ' );
84
+ RawCommand::create ();
85
+ }
86
+
87
+ /**
88
+ * The signature of RawCommand::create() requires one argument which is the
89
+ * ID of the command (other arguments are fetched dinamically). If the first
90
+ * argument is missing, PHP 7.1 throw an exception
91
+ *
92
+ * @group disconnected
93
+ */
94
+ public function testPHPWarningOnMissingCommandIDWithStaticCreate71 ()
95
+ {
96
+ if (version_compare (PHP_VERSION , "7.1 " , '< ' )) {
97
+ $ this ->markTestSkipped ('only for PHP > 7.1 ' );
98
+ }
99
+ $ this ->setExpectedException ('ArgumentCountError ' );
81
100
RawCommand::create ();
82
101
}
83
102
You can’t perform that action at this time.
0 commit comments