Sha256: e40822800343edfccd420b887c9c7069eb735da4f36a0aca716fdf3f0d505e40

Contents?: true

Size: 425 Bytes

Versions: 2

Compression:

Stored size: 425 Bytes

Contents

module FakeResolverConfigHooks
  def setup
    super
    @test_resolver_config_dir = Pathname('/tmp/landrush_fake_resolver')
    Landrush::ResolverConfig.instance_variable_set(
      "@config_dir",
      @test_resolver_config_dir
    )
  end

  def teardown
    super
    if @test_resolver_config_dir.exist?
      @test_resolver_config_dir.rmtree
    end
  end
end

class MiniTest::Spec
  include FakeResolverConfigHooks
end

Version data entries

2 entries across 2 versions & 1 rubygems

Version Path
landrush-0.8.0 test/support/fake_resolver_config.rb
landrush-0.7.1 test/support/fake_resolver_config.rb