function getEventCount(target, type) {
  return events[target] && events[target][type] || 0;
}
Returns the number of times test objects dispatched events of the given
type since the global counter was last reset.
@param {Control} target Event target.
@param {string} type Event type.
@return {number} Number of events of this type.