Kanboard now requires PHP >= 7.2 since other versions are deprecated
This commit is contained in:
@@ -13,31 +13,31 @@ class RpcFormatValidatorTest extends PHPUnit_Framework_TestCase
|
||||
|
||||
public function testWithNoVersion()
|
||||
{
|
||||
$this->setExpectedException('\JsonRPC\Exception\InvalidJsonRpcFormatException');
|
||||
$this->expectException('\JsonRPC\Exception\InvalidJsonRpcFormatException');
|
||||
RpcFormatValidator::validate(array('method' => 'foobar'));
|
||||
}
|
||||
|
||||
public function testWithNoMethod()
|
||||
{
|
||||
$this->setExpectedException('\JsonRPC\Exception\InvalidJsonRpcFormatException');
|
||||
$this->expectException('\JsonRPC\Exception\InvalidJsonRpcFormatException');
|
||||
RpcFormatValidator::validate(array('jsonrpc' => '2.0'));
|
||||
}
|
||||
|
||||
public function testWithMethodNotString()
|
||||
{
|
||||
$this->setExpectedException('\JsonRPC\Exception\InvalidJsonRpcFormatException');
|
||||
$this->expectException('\JsonRPC\Exception\InvalidJsonRpcFormatException');
|
||||
RpcFormatValidator::validate(array('jsonrpc' => '2.0', 'method' => array()));
|
||||
}
|
||||
|
||||
public function testWithBadVersion()
|
||||
{
|
||||
$this->setExpectedException('\JsonRPC\Exception\InvalidJsonRpcFormatException');
|
||||
$this->expectException('\JsonRPC\Exception\InvalidJsonRpcFormatException');
|
||||
RpcFormatValidator::validate(array('jsonrpc' => '1.0', 'method' => 'abc'));
|
||||
}
|
||||
|
||||
public function testWithBadParams()
|
||||
{
|
||||
$this->setExpectedException('\JsonRPC\Exception\InvalidJsonRpcFormatException');
|
||||
$this->expectException('\JsonRPC\Exception\InvalidJsonRpcFormatException');
|
||||
RpcFormatValidator::validate(array('jsonrpc' => '2.0', 'method' => 'abc', 'params' => 'foobar'));
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user