Sha256: 2b5ba9af0de7a836ccbef807c7c7bf25db8c558abd23fc5dd39c017b6fa535b9
Contents?: true
Size: 1.33 KB
Versions: 3
Compression:
Stored size: 1.33 KB
Contents
lib_path = File.expand_path(File.dirname(__FILE__) + "/../lib") $LOAD_PATH.unshift lib_path unless $LOAD_PATH.include?(lib_path) require 'rubygems' begin gem "spicycode-micronaut", ">= 0.2.2" rescue LoadError => e puts "\nERROR - This version of micronaut-rails requires micronaut 0.2.2 or higher." puts "gem install spicycode-micronaut --version 0.2.2" puts exit(1) end require 'action_controller' require 'micronaut' require 'micronaut-rails' gem :mocha module Micronaut module Matchers def fail raise_error(::Micronaut::Expectations::ExpectationNotMetError) end def fail_with(message) raise_error(::Micronaut::Expectations::ExpectationNotMetError, message) end end end def remove_last_describe_from_world Micronaut.world.behaviours.pop end class DummyFormatter < Micronaut::Formatters::BaseTextFormatter; end def dummy_reporter DummyFormatter.new({}, StringIO.new) end def use_color? !ENV.has_key?('TM_MODE') end # allow including links to lighthouse tickets in examples, for regression tests, pending features, etc. def ticket(number) %[http://relevance.lighthouseapp.com/projects/22819-micronaut/tickets/#{number}] end Micronaut.configure do |config| config.mock_with :mocha config.color_enabled = use_color? config.formatter = :documentation config.filter_run :focused => true end
Version data entries
3 entries across 3 versions & 1 rubygems
Version | Path |
---|---|
spicycode-micronaut-rails-0.2.7 | examples/example_helper.rb |
spicycode-micronaut-rails-0.3.0 | examples/example_helper.rb |
spicycode-micronaut-rails-0.3.1 | examples/example_helper.rb |