Sha256: e7714d831edf0e9c0d70417e04acd69b6b359061de2efef37a791383d61513ad

Contents?: true

Size: 924 Bytes

Versions: 2

Compression:

Stored size: 924 Bytes

Contents

require 'spec_helper'

module HerokuSan
  module Deploy
    describe Base do
      let(:stage) { Factory::Stage.build('test', {"app" => "awesomeapp", "deploy" => 'HerokuSan::Deploy::Base'}) }
      
      it "calls push" do
        subject = described_class.new(stage)
        stage.should_receive(:push).with(nil, nil)
        subject.deploy
      end
      
      it "calls push(sha)" do
        subject = described_class.new(stage, 'sha')
        stage.should_receive(:push).with('sha', nil)
        subject.deploy
      end
      
      it "calls push(nil, :force)" do
        subject = described_class.new(stage, nil, :force)
        stage.should_receive(:push).with(nil, :force)
        subject.deploy
      end

      it "calls push(sha, :force)" do
        subject = described_class.new(stage, 'sha', :force)
        stage.should_receive(:push).with('sha', :force)
        subject.deploy
      end
    end
  end
end

Version data entries

2 entries across 2 versions & 1 rubygems

Version Path
heroku_san-4.3.2 spec/heroku_san/deploy/base_spec.rb
heroku_san-4.3.1 spec/heroku_san/deploy/base_spec.rb