Skip to content

Commit 2fe0caa

Browse files
Merge branch '2.8' into 3.2
* 2.8: Refactored other PHPUnit method calls to work with namespaced PHPUnit 6 Further refactorings to PHPUnit namespaces resolve parameters in definition classes
2 parents 6d1ee31 + 8827db0 commit 2fe0caa

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

Tests/CookieTest.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -85,7 +85,7 @@ public function testFromStringWithUrl()
8585

8686
public function testFromStringThrowsAnExceptionIfCookieIsNotValid()
8787
{
88-
$this->setExpectedException('InvalidArgumentException');
88+
$this->{method_exists($this, $_ = 'expectException') ? $_ : 'setExpectedException'}('InvalidArgumentException');
8989
Cookie::fromString('foo');
9090
}
9191

@@ -98,7 +98,7 @@ public function testFromStringIgnoresInvalidExpiresDate()
9898

9999
public function testFromStringThrowsAnExceptionIfUrlIsNotValid()
100100
{
101-
$this->setExpectedException('InvalidArgumentException');
101+
$this->{method_exists($this, $_ = 'expectException') ? $_ : 'setExpectedException'}('InvalidArgumentException');
102102
Cookie::fromString('foo=bar', 'foobar');
103103
}
104104

0 commit comments

Comments
 (0)