Peridot\Core\Test::executeTest PHP Method

executeTest() protected method

Attempt to execute setup functions and run the test definition
protected executeTest ( Peridot\Core\TestResult $result )
$result Peridot\Core\TestResult
    protected function executeTest(TestResult $result)
    {
        $action = ['passTest', $this];
        $handler = $this->handleErrors($result, $action);
        try {
            $this->runSetup();
            call_user_func_array($this->getDefinition(), $this->getDefinitionArguments());
        } catch (Throwable $e) {
            $this->failIfPassing($action, $e);
        } catch (Exception $e) {
            $this->failIfPassing($action, $e);
        }
        $this->runTearDown($result, $action);
        $this->restoreErrorHandler($handler);
    }