Sha256: 411d18bffd3ad8ef03cf37b55d7c6df85717451bc2d5c2d9555833fb6e5d69a8

Contents?: true

Size: 999 Bytes

Versions: 1

Compression:

Stored size: 999 Bytes

Contents

require 'rubygems' if defined? Gem
 
libdir = File.join(File.dirname(__FILE__), '..', 'lib')
$LOAD_PATH.unshift libdir unless $LOAD_PATH.include?(libdir)
 
require 'test/unit'
require 'shoulda'

require 'rudy'


puts Rudy.banner("THIS IS RUBY #{RUBY_VERSION}")

# +should_stop+ should the test be stopped?
# +str+ The message to print when +should_stop+ is true
def stop_test(should_stop, str)
  return unless should_stop
  str ||= "Test stopped for unknown reason"
  abort str.color(:red).bright
end
def xstop_test(*args, &ignore)
  #puts %Q(Skipping stop_test: %s "%s") % [args.last.color(:blue), args.first.color(:blue).bright]
end

def skip(msg)
  puts "%s (%s)" % ["SKIP".color(:blue).bright, msg]
  :skip # this doesn't do anything, but I would like it to!
end

def xshould(*args, &ignore)
  puts %Q(Skipping test: %s "%s") % [@name.color(:blue), args.first.color(:blue).bright]
end
def xcontext(*args, &ignore)
  puts %q(Skipping context: "%s") % (@name || args.first).color(:blue).bright
end

Version data entries

1 entries across 1 versions & 1 rubygems

Version Path
solutious-rudy-0.5.0 test/helper.rb