Nelmio\Alice\Faker\Provider\AliceProvider::identity PHP Method

identity() public static method

Returns whatever is passed to it. This allows you among other things to use a PHP expression while still benefiting from variable replacement.
public static identity ( mixed $expression ) : mixed
$expression mixed
return mixed
    public static function identity($expression)
    {
        return $expression;
    }

Usage Example

Example #1
0
 public function testIdentityReturnsTheValueUnchanged()
 {
     $value = $expected = 'foo';
     $actual = AliceProvider::identity($value);
     $this->assertEquals($expected, $actual);
 }
AliceProvider