Sha256: a23fdb165e16bbc1b9d1d08fdedb3c1d9c05c2da9674e838840fd96f08546939

Contents?: true

Size: 778 Bytes

Versions: 11

Compression:

Stored size: 778 Bytes

Contents

require 'spec_helper'
require 'tmpdir'
require 'fileutils'

describe HighFive::Thor::Tasks::Initialization do 
  before :each do
    @original_dir = Dir.pwd
    @project_root = Dir.mktmpdir("hi5")
    Dir.chdir @project_root
  end

  after :each do
    Dir.chdir @original_dir
    FileUtils.rm_rf @project_root
  end

  it "should create high_five.rb in the config directory" do
    ::HighFive::Thor::Tasks::Initialization.start(["init"])
    Dir.exists?(File.join(@project_root, "config")).should be_true
    File.exists?(File.join(@project_root, "config", "high_five.rb")).should be_true
    Dir.exists?(File.join(@project_root, "config", "high_five")).should be_true
    File.exists?(File.join(@project_root, "config", "high_five", "app-common.js")).should be_true
  end

end

Version data entries

11 entries across 11 versions & 1 rubygems

Version Path
high_five-0.2.10 spec/init_spec.rb
high_five-0.2.9 spec/init_spec.rb
high_five-0.2.8 spec/init_spec.rb
high_five-0.2.7 spec/init_spec.rb
high_five-0.2.6 spec/init_spec.rb
high_five-0.2.5 spec/init_spec.rb
high_five-0.2.4 spec/init_spec.rb
high_five-0.2.3 spec/init_spec.rb
high_five-0.2.2 spec/init_spec.rb
high_five-0.2.1 spec/init_spec.rb
high_five-0.2.0 spec/init_spec.rb