Sha256: 1250429d928f3284713831fc3faba3681ce436665247df93e137b148cb6836a5

Contents?: true

Size: 944 Bytes

Versions: 9

Compression:

Stored size: 944 Bytes

Contents

Encoding.default_external = Encoding::UTF_8

$LOAD_PATH.unshift(File.join(File.dirname(__FILE__), '..', 'lib'))
$LOAD_PATH.unshift(File.dirname(__FILE__))

# Configure simplecov gem (must be here at top of file)
require 'coveralls'
Coveralls.wear! do
  add_filter 'spec' # Don't include RSpec stuff
  add_group 'Types', 'lib/attributor/types'
end

require 'rspec'
require 'rspec/its'
require 'rspec/collection_matchers'

require 'attributor'
require 'pry'

# Requires supporting files with custom matchers and macros, etc,
# in ./support/ and its subdirectories.
Dir["#{File.dirname(__FILE__)}/support/**/*.rb"].each { |f| require f }

RSpec.configure do |config|
  config.around(:each) do |example|
    example.run
  end
end

RSpec::Matchers.define :be_in_family do |expected|
  match do |actual|
    actual.family == expected
  end
end

RSpec::Matchers.define :be_subclass_of do |expected|
  match do |actual|
    actual < expected
  end
end

Version data entries

9 entries across 9 versions & 1 rubygems

Version Path
attributor-8.0 spec/spec_helper.rb
attributor-7.1 spec/spec_helper.rb
attributor-7.0 spec/spec_helper.rb
attributor-6.5 spec/spec_helper.rb
attributor-6.4 spec/spec_helper.rb
attributor-6.3 spec/spec_helper.rb
attributor-6.2 spec/spec_helper.rb
attributor-6.1 spec/spec_helper.rb
attributor-6.0 spec/spec_helper.rb