Sha256: 3452acd64d830113b3cda7ac9d1739db6ddd0d451612065cb38a17cc9924696c

Contents?: true

Size: 613 Bytes

Versions: 6

Compression:

Stored size: 613 Bytes

Contents

module M
  module Runners
    class TestUnit < Base
      def suites
        if Test::Unit::TestCase.respond_to?(:test_suites)
          Test::Unit::TestCase.test_suites
        else
          Test::Unit::TestCase::DESCENDANTS
        end
      end

      def run(test_arguments)
        Test::Unit::AutoRunner.run(false, nil, test_arguments)
      end

      def test_methods(suite_class)
        if suite_class.respond_to?(:test_methods)
          suite_class.test_methods
        else
          suite_class.public_instance_methods(true).grep(/^test/).map { |m| m.to_s }
        end
      end
    end
  end
end

Version data entries

6 entries across 6 versions & 1 rubygems

Version Path
m-1.6.1 lib/m/runners/test_unit.rb
m-1.6.0 lib/m/runners/test_unit.rb
m-1.5.1 lib/m/runners/test_unit.rb
m-1.5.0 lib/m/runners/test_unit.rb
m-1.4.2 lib/m/runners/test_unit.rb
m-1.4.0 lib/m/runners/test_unit.rb