/** * Calls an assertion function. * * @return boolean true */ public function __call($func, $args) { $this->_assertions_ran[] = $func; if ($this->_failed && SKIP_TESTS_ON_FAILURE) { Output::instance()->assertion($this, $func, $args, null); return false; } else { try { $call = Assertions::instance()->call_assertion($func, $args, $this); } catch (\BadMethodCallException $e) { $call = null; Output::instance()->unknown_assertion($this, $func, $args, Assertions::instance()); } if ($call !== true) { $this->_failed = true; } Output::instance()->assertion($this, $func, $args, $call); } // Add call to results $this->_assertion_results[] = [$call, $func, $args, debug_backtrace(DEBUG_BACKTRACE_IGNORE_ARGS)]; return $call; }