PROJECT_ROOT = File.expand_path(File.join(File.dirname(__FILE__), "..")).freeze GUARD = ENV["GUARD"] # Gem dependencies require 'lstrip-on-steroids' require 'fakefs/spec_helpers' # Project dependencies require 'bitcoin/rspec/argument_matchers' RSpec.configure do |config| config.filter_run(focus: true) config.filter_run_excluding(adapter: :slow) if GUARD == "fast" config.run_all_when_everything_filtered = true config.mock_with(:rspec) config.include(Bitcoin::RSpec::ArgumentMatchers) end module SpecHelperObjectExtensions def contract(name, &block) shared_examples_for(name, &block) end end include SpecHelperObjectExtensions RSpec.configure do |config| config.alias_it_should_behave_like_to(:it_satisfies_contract, 'satisfies contract:') end