module Test::Unit::RunCount

Public Class Methods

have_run?() click to toggle source
# File lib/test/unit.rb, line 15
def self.have_run?
  @@run_count.nonzero?
end
run_once() { || ... } click to toggle source
# File lib/test/unit.rb, line 24
def run_once
  return if have_run?
  return if $! # don't run if there was an exception
  yield
end

Public Instance Methods

run(*) click to toggle source
Calls superclass method
# File lib/test/unit.rb, line 19
def run(*)
  @@run_count += 1
  super
end

Private Instance Methods

run_once() { || ... } click to toggle source
# File lib/test/unit.rb, line 24
def run_once
  return if have_run?
  return if $! # don't run if there was an exception
  yield
end