function moveNext(AssessmentTestSession $session, array &$average)
{
    $start = microtime();
    $session->moveNext();
    if (is_null($average) === false) {
        spentTime($start, microtime(), $average);
    }
}
 /**
  * Ask the test session to move to next RouteItem in the Route sequence.
  *
  * If $allowTimeout is set to true, the very next RouteItem in the Route sequence will bet set
  * as the current RouteItem, whether or not it is timed out or not.
  *
  * On the other hand, if $allowTimeout is set to false, the next RouteItem in the Route sequence
  * which is not timed out will be set as the current RouteItem. If there is no more following RouteItems
  * that are not timed out in the Route sequence, the test session ends gracefully.
  *
  * @param boolean $allowTimeout If set to true, the next RouteItem in the Route sequence does not have to respect the timeLimits in force. Default value is false.
  * @throws AssessmentTestSessionException If the test session is not running or an issue occurs during the transition (e.g. branching, preConditions, ...).
  * @qtism-test-interaction
  * @qtism-test-duration-update
  */
 public function moveNext($allowTimeout = false)
 {
     $sessionMemento = $this->getSessionMemento();
     parent::moveNext($allowTimeout);
     $this->triggerEventChange($sessionMemento);
 }