Kanboard now requires PHP >= 7.2 since other versions are deprecated
This commit is contained in:
@@ -17,7 +17,7 @@ class ResponseParserTest extends PHPUnit_Framework_TestCase
|
||||
|
||||
public function testWithBadJsonFormat()
|
||||
{
|
||||
$this->setExpectedException('\JsonRPC\Exception\InvalidJsonFormatException');
|
||||
$this->expectException('\JsonRPC\Exception\InvalidJsonFormatException');
|
||||
|
||||
ResponseParser::create()
|
||||
->withPayload('foobar')
|
||||
@@ -26,7 +26,7 @@ class ResponseParserTest extends PHPUnit_Framework_TestCase
|
||||
|
||||
public function testWithBadProcedure()
|
||||
{
|
||||
$this->setExpectedException('BadFunctionCallException');
|
||||
$this->expectException('BadFunctionCallException');
|
||||
|
||||
ResponseParser::create()
|
||||
->withPayload(json_decode('{"jsonrpc": "2.0", "error": {"code": -32601, "message": "Method not found"}, "id": "1"}', true))
|
||||
@@ -35,7 +35,7 @@ class ResponseParserTest extends PHPUnit_Framework_TestCase
|
||||
|
||||
public function testWithInvalidArgs()
|
||||
{
|
||||
$this->setExpectedException('InvalidArgumentException');
|
||||
$this->expectException('InvalidArgumentException');
|
||||
|
||||
ResponseParser::create()
|
||||
->withPayload(json_decode('{"jsonrpc": "2.0", "error": {"code": -32602, "message": "Invalid params"}, "id": "1"}', true))
|
||||
@@ -44,7 +44,7 @@ class ResponseParserTest extends PHPUnit_Framework_TestCase
|
||||
|
||||
public function testWithInvalidRequest()
|
||||
{
|
||||
$this->setExpectedException('\JsonRPC\Exception\InvalidJsonRpcFormatException');
|
||||
$this->expectException('\JsonRPC\Exception\InvalidJsonRpcFormatException');
|
||||
|
||||
ResponseParser::create()
|
||||
->withPayload(json_decode('{"jsonrpc": "2.0", "error": {"code": -32600, "message": "Invalid Request"}, "id": null}', true))
|
||||
@@ -53,7 +53,7 @@ class ResponseParserTest extends PHPUnit_Framework_TestCase
|
||||
|
||||
public function testWithParseError()
|
||||
{
|
||||
$this->setExpectedException('\JsonRPC\Exception\InvalidJsonFormatException');
|
||||
$this->expectException('\JsonRPC\Exception\InvalidJsonFormatException');
|
||||
|
||||
ResponseParser::create()
|
||||
->withPayload(json_decode('{"jsonrpc": "2.0", "error": {"code": -32700, "message": "Parse error"}, "id": null}', true))
|
||||
@@ -62,7 +62,7 @@ class ResponseParserTest extends PHPUnit_Framework_TestCase
|
||||
|
||||
public function testWithOtherError()
|
||||
{
|
||||
$this->setExpectedException('\JsonRPC\Exception\ResponseException');
|
||||
$this->expectException('\JsonRPC\Exception\ResponseException');
|
||||
|
||||
ResponseParser::create()
|
||||
->withPayload(json_decode('{"jsonrpc": "2.0", "error": {"code": 42, "message": "Something", "data": "foobar"}, "id": null}', true))
|
||||
@@ -91,7 +91,7 @@ class ResponseParserTest extends PHPUnit_Framework_TestCase
|
||||
{"jsonrpc": "2.0", "error": {"code": -32602, "message": "Invalid params"}, "id": "1"}
|
||||
]';
|
||||
|
||||
$this->setExpectedException('InvalidArgumentException');
|
||||
$this->expectException('InvalidArgumentException');
|
||||
|
||||
ResponseParser::create()
|
||||
->withPayload(json_decode($payload, true))
|
||||
|
||||
Reference in New Issue
Block a user