public function testApiFail_CallsModelMethod()
{
$test = $this->getTest();
$ex = new Exception();
$params = ['param' => 'value'];
$model = $test->getMock(RuntimeModel::class, [], [], '', false);
$model->expects($test->once())->method('fail')->with($ex, $params);
$runtime = $this->createRuntime();
$test->setProtectedProperty($runtime, 'model', $model);
$runtime->fail($ex, $params);
}