Ejemplo n.º 1
0
 /**
  * Output parameter method call test
  *
  * @return void
  */
 public function testOutParameterMethodCall()
 {
     $method = MethodRegistry::get('CalcTwice', ['method' => 'CALC.TWICE']);
     $request = $method->newRequest(['A' => 5]);
     $this->assertTrue($request->isNew());
     $this->assertTrue($method->execute($request));
     $this->assertFalse($request->isNew());
     $this->assertEquals($request->get('B'), 10);
     $this->assertEquals($request[':result'], 'OK');
     $this->assertEquals($request->result(), 'OK');
 }
 /**
  * Test the get() method.
  *
  * @return void
  */
 public function testGet()
 {
     $locator = $this->_setMockLocator();
     $locator->expects($this->once())->method('get')->with('Test', []);
     MethodRegistry::get('Test', []);
 }