Sha256: b52ae4ed5aa6971cce5ff9f33888b383aa36fba0d6506bb8fa73231dee5a7fe2

Contents?: true

Size: 771 Bytes

Versions: 11

Compression:

Stored size: 771 Bytes

Contents

require 'pact/consumer'
require 'pact/consumer/spec_hooks'
require 'pact/consumer/rspec/full_example_description'

module Pact
  module Consumer
    module RSpec
      include Pact::Consumer::ConsumerContractBuilders
    end
  end
end

hooks = Pact::Consumer::SpecHooks.new


RSpec.configure do |config|
  config.include Pact::Consumer::RSpec, :pact => true

  config.before :all, :pact => true do
    hooks.before_all
  end

  config.before :each, :pact => true do | example |
    hooks.before_each Pact::Consumer::RSpec::FullExampleDescription.new(example).to_s
  end

  config.after :each, :pact => true do | example |
    hooks.after_each Pact::Consumer::RSpec::FullExampleDescription.new(example).to_s
  end

  config.after :suite do
    hooks.after_suite
  end
end

Version data entries

11 entries across 11 versions & 1 rubygems

Version Path
pact-1.0.39 lib/pact/consumer/rspec.rb
pact-1.1.0.rc2 lib/pact/consumer/rspec.rb
pact-1.0.38 lib/pact/consumer/rspec.rb
pact-1.1.0.rc1 lib/pact/consumer/rspec.rb
pact-1.0.37 lib/pact/consumer/rspec.rb
pact-1.0.36 lib/pact/consumer/rspec.rb
pact-1.0.35 lib/pact/consumer/rspec.rb
pact-1.0.34 lib/pact/consumer/rspec.rb
pact-1.0.33 lib/pact/consumer/rspec.rb
pact-1.0.32 lib/pact/consumer/rspec.rb
pact-1.0.31 lib/pact/consumer/rspec.rb