Sha256: 2f2c3ffee228c8a4115ec9af2a1bdf1a13c47186b8e4ecfcc117723cf0ce3f4c

Contents?: true

Size: 1 KB

Versions: 4

Compression:

Stored size: 1 KB

Contents

require 'spec_helper'
require 'rake_context'

require 'rubygems/tasks/scm/status'

describe Gem::Tasks::SCM::Status do
  describe "#status" do
    context "git" do
      include_context "rake"

      it "should run `git status --untracked-files=no`" do
        subject.project.stub!(:scm).and_return(:git)

        subject.should_receive(:run).with(
          'git', 'status', '--untracked-files=no'
        )

        subject.status
      end
    end

    context "hg" do
      include_context "rake"

      it "should run `hg status --quiet`" do
        subject.project.stub!(:scm).and_return(:hg)

        subject.should_receive(:run).with(
          'hg', 'status', '--quiet'
        )

        subject.status
      end
    end

    context "svn" do
      include_context "rake"

      it "should run `svn status --quiet`" do
        subject.project.stub!(:scm).and_return(:svn)

        subject.should_receive(:run).with(
          'svn', 'status', '--quiet'
        )

        subject.status
      end
    end
  end
end

Version data entries

4 entries across 4 versions & 1 rubygems

Version Path
rubygems-tasks-0.2.4 spec/scm/status_spec.rb
rubygems-tasks-0.2.3 spec/scm/status_spec.rb
rubygems-tasks-0.2.2 spec/scm/status_spec.rb
rubygems-tasks-0.2.1 spec/scm/status_spec.rb