for testing and deploying your application
for finding and fixing issues
for empowering human code reviews
<?php
/*
* This file is part of the rafrsr/lib-array2object package.
*
* (c) Rafael SR <https://github.com/rafrsr>
* For the full copyright and license information, please view the LICENSE
* file that was distributed with this source code.
*/
namespace Rafrsr\LibArray2Object\Tests\Parser;
use Rafrsr\LibArray2Object\Parser\CallableParser;
class CallableParserTest extends ParserTester
{
public function buildParser()
return new CallableParser(
function ($value, $type, \ReflectionProperty $property, $object) {
$type
This check looks from parameters that have been defined for a function or method, but which are not used in the method body.
$property
$object
return ($value === 'success') ? true : false;
}
);
public function getTypes()
return ['\DateTime', 'DateTime'];
public function getParseValueMap()
return [
'success' => true,
'fail' => false,
];
This check looks from parameters that have been defined for a function or method, but which are not used in the method body.