Sha256: 1a125cd55793f7903ebce6350620a4d8e75b742d9f71f7c8d100b7fc8bd6b68d

Contents?: true

Size: 746 Bytes

Versions: 7

Compression:

Stored size: 746 Bytes

Contents

require 'awestruct/config'
require 'spec_helper'
require 'awestruct/config'

describe Awestruct::Config do

  it "should accept a list of files in .awestruct_ignore to ignore on site generation" do
    site_dir = File.join(File.dirname(__FILE__), 'test-data')
    config = Awestruct::Config.new(site_dir)
    config.ignore.should == ["Rakefile", "Gemfile"]
  end

  it "should handle an empty .awestruct_ignore file without barfing" do
    site_dir = File.join(File.dirname(__FILE__), 'test-data')
    config_file = File.join(site_dir, ".awestruct_ignore")
    File.open(config_file, "w")
    config = Awestruct::Config.new(site_dir)
    config.ignore.should == []
    File.open(config_file, "w") { |f| f.write("Rakefile\nGemfile\n") }
  end

end

Version data entries

7 entries across 7 versions & 1 rubygems

Version Path
awestruct-0.5.3 spec/config_spec.rb
awestruct-0.5.2.1 spec/config_spec.rb
awestruct-0.5.2 spec/config_spec.rb
awestruct-0.5.1 spec/config_spec.rb
awestruct-0.5.1a spec/config_spec.rb
awestruct-0.5.0 spec/config_spec.rb
awestruct-0.5.0.cr spec/config_spec.rb