public function testCanHintToApiProblemToRenderStackTrace() { $exception = new \Exception('exception message', 500); $apiProblem = new ApiProblem(500, $exception); $model = new ApiProblemModel(); $model->setApiProblem($apiProblem); $this->renderer->setDisplayExceptions(true); $test = $this->renderer->render($model); $test = json_decode($test, true); $this->assertArrayHasKey('trace', $test); $this->assertInternalType('array', $test['trace']); $this->assertGreaterThanOrEqual(1, count($test['trace'])); }