Sha256: e5a3dc67e685c91b33c324047ac29ab7e3e4fbff0fac63b6294cde194ad5577f

Contents?: true

Size: 675 Bytes

Versions: 21

Compression:

Stored size: 675 Bytes

Contents

require 'spec_helper'

describe Berkshelf::Chef::Cookbook::Chefignore do
  describe '.find_relative_to' do
    let(:path) { tmp_path.join('chefignore-test') }
    before(:each) { FileUtils.mkdir_p(path) }

    it "finds a chefignore file in a 'cookbooks' directory relative to the given path" do
      FileUtils.touch(path.join('chefignore'))
      Berkshelf::Chef::Cookbook::Chefignore.find_relative_to(path)
    end

    it 'finds a chefignore file relative to the given path' do
      FileUtils.mkdir_p(path.join('cookbooks'))
      FileUtils.touch(path.join('cookbooks', 'chefignore'))
      Berkshelf::Chef::Cookbook::Chefignore.find_relative_to(path)
    end
  end
end

Version data entries

21 entries across 21 versions & 1 rubygems

Version Path
berkshelf-2.0.18 spec/unit/berkshelf/chef/cookbook/chefignore_spec.rb
berkshelf-2.0.17 spec/unit/berkshelf/chef/cookbook/chefignore_spec.rb
berkshelf-2.0.16 spec/unit/berkshelf/chef/cookbook/chefignore_spec.rb
berkshelf-2.0.15 spec/unit/berkshelf/chef/cookbook/chefignore_spec.rb
berkshelf-2.0.14 spec/unit/berkshelf/chef/cookbook/chefignore_spec.rb
berkshelf-2.0.13 spec/unit/berkshelf/chef/cookbook/chefignore_spec.rb
berkshelf-2.0.12 spec/unit/berkshelf/chef/cookbook/chefignore_spec.rb
berkshelf-2.0.11 spec/unit/berkshelf/chef/cookbook/chefignore_spec.rb
berkshelf-2.0.10 spec/unit/berkshelf/chef/cookbook/chefignore_spec.rb
berkshelf-2.0.9 spec/unit/berkshelf/chef/cookbook/chefignore_spec.rb
berkshelf-2.0.8 spec/unit/berkshelf/chef/cookbook/chefignore_spec.rb
berkshelf-3.0.0.beta2 spec/unit/berkshelf/chef/cookbook/chefignore_spec.rb
berkshelf-3.0.0.beta1 spec/unit/berkshelf/chef/cookbook/chefignore_spec.rb
berkshelf-2.0.7 spec/unit/berkshelf/chef/cookbook/chefignore_spec.rb
berkshelf-2.0.6 spec/unit/berkshelf/chef/cookbook/chefignore_spec.rb
berkshelf-2.0.5 spec/unit/berkshelf/chef/cookbook/chefignore_spec.rb
berkshelf-2.0.4 spec/unit/berkshelf/chef/cookbook/chefignore_spec.rb
berkshelf-2.0.3 spec/unit/berkshelf/chef/cookbook/chefignore_spec.rb
berkshelf-2.0.1 spec/unit/berkshelf/chef/cookbook/chefignore_spec.rb
berkshelf-2.0.0 spec/unit/berkshelf/chef/cookbook/chefignore_spec.rb