2017 © Pedro Peláez
 

library mocking-method-invoker

Any methods invoker for Mock object.

image

feedtailor/mocking-method-invoker

Any methods invoker for Mock object.

  • Tuesday, August 5, 2014
  • by feedtailor
  • Repository
  • 6 Watchers
  • 0 Stars
  • 110 Installations
  • PHP
  • 1 Dependents
  • 0 Suggesters
  • 0 Forks
  • 0 Open issues
  • 2 Versions
  • 0 % Grown

The README.md

mocking-method-invoker

Any methods invoker for Mock object., (*1)

Build Status, (*2)

Install

Add feedtailor/mocking-method-invoker as a dependency in your project's composer.json file., (*3)

{
  "require": {
    "feedtailor/mocking-method-invoker": "dev-master"
  }
}

Example

use Feedtailor\Mocking\MethodInvoker;

class ExampleClass
{
    protected function add($a, $b)
    {
        return $a + $b;
    }
}

$obj = new ExampleClass();

$result = MethodInvoker::create($obj)->invoke("getFoo", array(40, 2)) // got 42.

Methods

$invoker = new MethodInvoker($obj);

$invoker = MethodInvoker::create($obj);

Create a new MethodInvoker instance., (*4)

$invoker->invoke($name, $args);

invoke the $name method with $args array arguments., (*5)

License

Licensed under the MIT License., (*6)

The Versions

05/08 2014

dev-master

9999999-dev https://github.com/feedtailor/mocking-method-invoker

Any methods invoker for Mock object.

  Sources   Download

MIT

The Requires

  • php >=5.3.3

 

The Development Requires

05/08 2014

0.1.0

0.1.0.0 https://github.com/feedtailor/mocking-method-invoker

Any methods invoker for Mock object.

  Sources   Download

MIT

The Requires

  • php >=5.3.3

 

The Development Requires