Ejemplo n.º 1
0
 public function testCanAccessRawDataFromRequest()
 {
     stream_wrapper_unregister("php");
     stream_wrapper_register("php", PhpStreamMock::class);
     file_put_contents('php://input', 'Unit-Test');
     $postRequest = new PostRequest(RequestInfo::fromEnv(), [], []);
     $command = new TestDomainCommand($postRequest);
     $this->assertEquals('Unit-Test', $command->getBody());
     stream_wrapper_restore("php");
 }