public function testProtectedApiClose_ClosesSocket()
{
$aware = $this->createAware();
$component = $this->createComponent();
$server = $this->createServer($aware, $component);
$code = 300;
$conn = $this->getMock(NetworkConnectionInterface::class, [], [], '', false);
$conn->expects($this->once())->method('send')->with($this->isInstanceOf(HttpResponseInterface::class));
$conn->expects($this->once())->method('close');
$this->callProtectedMethod($server, 'close', [$conn, $code]);
}