Sha256: 3783d13673bad675f7ebcf3b9c3dea591c37755fe5303028a2476c5f32123fd1

Contents?: true

Size: 746 Bytes

Versions: 1

Compression:

Stored size: 746 Bytes

Contents

require File.join(File.dirname(__FILE__), 'support', 'spec_helper')
require 'rake/renametask'
require 'tasklib_patch'

describe Albacore::RenameTask, "when running" do
	before :all do
		task = Albacore::RenameTask.new() do |t|
			@yielded_object = t
		end
		task.extend(TasklibPatch)
		Rake::Task[:rename].invoke
	end
	
	it "should yield the rename api" do
		@yielded_object.kind_of?(Albacore::RenameTask).should be_true
	end
end

describe Albacore::RenameTask, "when execution fails" do
	before :all do
		@task = Albacore::RenameTask.new(:failingtask)
		@task.extend(TasklibPatch)
		@task.fail
		Rake::Task["failingtask"].invoke
	end
	
	it "should fail the rake task" do
		@task.task_failed.should == true
	end
end

Version data entries

1 entries across 1 versions & 1 rubygems

Version Path
albacore-0.0.7 spec/renametask_spec.rb