Sha256: bb850e2d637db5f68a0e5dea3250726e8d7733a5e53ae73e55abd221cd5382a5

Contents?: true

Size: 991 Bytes

Versions: 18

Compression:

Stored size: 991 Bytes

Contents

# encoding: utf-8

require_relative "../spec_helper"

load "nake/tasks.rb"
@result = STDOUT.capture { Task["-T"].call }

describe "Default tasks" do
  describe "-H" do
    before(:each) do
      load "nake/tasks.rb"
    end

    it "should be available as a -H or --help" do
      Task["-H"].should eql(Task["--help"])
    end

    it "should print a message about using -T and exit" do
      -> { Task["-H"].call }.should raise_error(SystemExit, /-T/)
    end
  end

  describe "-T" do
    before(:each) do
      load "nake/tasks.rb"
      task(:release, :build, :tag)
      @result = STDOUT.capture { Task["-T"].call }
    end

    it "should list all available tasks" do
      @result.should match("release")
    end

    it "should show description if there is any"

    it "should list dependencies if some are available"

    it "should list aliases"

    it "should not show hidden tasks" do
      @result.should_not match("-H")
    end
  end

  describe "-i" do
    # TODO
  end
end

Version data entries

18 entries across 18 versions & 2 rubygems

Version Path
nake-0.1.1 spec/nake/tasks_spec.rb
nake-0.1 spec/nake/tasks_spec.rb
nake-0.0.9.5 spec/nake/tasks_spec.rb
nake-0.0.9.4 spec/nake/tasks_spec.rb
nake-0.0.9.3 spec/nake/tasks_spec.rb
nake-0.0.9.2 spec/nake/tasks_spec.rb
nake-0.0.9.pre spec/nake/tasks_spec.rb
do_riak-0.10.1.pre gems/gems/nake-0.0.8/spec/nake/tasks_spec.rb
nake-0.0.8.pre spec/nake/tasks_spec.rb
nake-0.0.8 spec/nake/tasks_spec.rb
nake-0.0.7 spec/nake/tasks_spec.rb
nake-0.0.6 spec/nake/tasks_spec.rb
nake-0.0.5 spec/nake/tasks_spec.rb
nake-0.0.3 spec/nake/tasks_spec.rb
nake-0.0.3.pre spec/nake/tasks_spec.rb
nake-0.0.2 spec/nake/tasks_spec.rb
nake-0.0.2.pre spec/nake/tasks_spec.rb
nake-0.0.1 spec/nake/tasks_spec.rb