Sha256: c4c0d992bfe8e2a4c54646e0906ddf00888f53af1ad7eb09182927e015a6f028

Contents?: true

Size: 770 Bytes

Versions: 9

Compression:

Stored size: 770 Bytes

Contents

module Test #:nodoc:
  module Unit #:nodoc:
    class TestCase
      # Runs tests with blueprints support
      def run_with_blueprints(result, &progress_block)
        Blueprints.setup(self)
        run_without_blueprints(result, &progress_block)
        Blueprints.teardown
      end

      # Enables blueprints in test/unit. Is automatically added if <tt>Spec</tt> is not defined at loading time.
      # You might need to require it manually in certain case (eg. using both rspec and test/unit).
      # Accepts options hash. For supported options please check Blueprints.load.
      def self.enable_blueprints(options = {})
        include Blueprints::Helper
        Blueprints.load(options)
        alias_method_chain :run, :blueprints
      end
    end
  end
end

Version data entries

9 entries across 9 versions & 1 rubygems

Version Path
blueprints-0.6.3 lib/blueprints/extensions/test_unit.rb
blueprints-0.6.2 lib/blueprints/extensions/test_unit.rb
blueprints-0.6.1 lib/blueprints/extensions/test_unit.rb
blueprints-0.6.0 lib/blueprints/extensions/test_unit.rb
blueprints-0.5.1 lib/blueprints/extensions/test_unit.rb
blueprints-0.5.0 lib/blueprints/extensions/test_unit.rb
blueprints-0.4.2 lib/blueprints/extensions/test_unit.rb
blueprints-0.4.1 lib/blueprints/extensions/test_unit.rb
blueprints-0.4.0 lib/blueprints/extensions/test_unit.rb