CakeDC\Users\Test\TestCase\Controller\Traits\BaseTraitTest::_mockRequestPost PHP Метод

_mockRequestPost() защищенный Метод

mock Request for POST, is and allow methods
protected _mockRequestPost ( mixed $with = 'post' ) : void
$with mixed used in with
Результат void
    protected function _mockRequestPost($with = 'post')
    {
        $this->Trait->request = $this->getMockBuilder('Cake\\Network\\Request')->setMethods(['is', 'data', 'allow'])->getMock();
        $this->Trait->request->expects($this->any())->method('is')->with($with)->will($this->returnValue(true));
    }