class SeleniumTestSuite def initialize(name, *arguments) tests = [] arguments.each do |argument| case argument when Class then tests.concat argument.suite.tests else tests << argument end end @@tests[name] = tests end class << self def names @@tests.keys.sort end def clear @@tests = {} end def [](name) @@tests[name] end end end