Sha256: 225dc1b17526f22f0d03031422eac1dce8967df57ab71e7a2ba9b646e25cfe52

Contents?: true

Size: 694 Bytes

Versions: 21

Compression:

Stored size: 694 Bytes

Contents

require File.dirname(__FILE__) + '/spec_helper'

describe "the git deploy strategy" do
  subject do
    EY::Strategies::Git.new(:repo => File.expand_path("../fixtures/gitrepo/.git", __FILE__),
                            :repository_cache => File.expand_path("../fixtures/gitrepo", __FILE__),
                            :ref => "master"
                            )
  end

  before { subject.checkout }

  it "#checkout returns true for branches that exist" do
    subject.opts[:ref] = "somebranch"
    subject.checkout.should be_true
  end

  it "#checkout returns false for branches that do not exist" do
    subject.opts[:ref] = "notabranch"
    subject.checkout.should be_false
  end
end

Version data entries

21 entries across 21 versions & 2 rubygems

Version Path
ey-deploy-0.8.2 spec/git_strategy_spec.rb