… of many things …

… of many things … header image 4

Entries from January 2006

Test

January 17th, 2006 · No Comments

This is a test of posting by sending email.

Jason Rogers
“I am crucified with Christ: nevertheless I live; yet not I,
but Christ liveth in me: and the life which I now live in
the flesh I live by the faith of the Son of God, who loved
me, and gave himself for me.”
Galatians 2:20

[Read more →]

Tags: Uncategorized

Creating Test Suites In Ruby

January 6th, 2006 · No Comments

The following is one way to create a suite of tests automatically in Ruby. There are probably better ways, but this works for me.
PLAIN TEXT
RUBY:

require 'test/unit'

require 'test/unit/testsuite'

require 'test/unit/ui/gtk2/testrunner'

require 'test/unit/ui/console/testrunner'

 

class AllTests

  TESTS = Array.new

end

 

class Class

  def inherited(arg)

    if arg <Test::Unit::TestCase

      AllTests::TESTS <<arg

    end

  end

end

 

Dir.glob('*test.rb').each {|f|

  require f

}

 

class AllTests

  def self.suite

    [...]

[Read more →]

Tags: Software · Ruby