Sha256: e04ce0112751a611e6abc82a2671b49e8d3497f84f7ca2121dfa66f4bf1a814c

Contents?: true

Size: 950 Bytes

Versions: 84

Compression:

Stored size: 950 Bytes

Contents

require 'spec_helper'
require 'dpl/provider/appfog'

describe DPL::Provider::Appfog do
  subject :provider do
    described_class.new(DummyContext.new, :email => 'blah@foo.com', :password => 'bar')
  end

  describe :check_auth do
    example do
      provider.context.should_receive(:shell).with("af login --email=blah@foo.com --password=bar")
      provider.check_auth
    end
  end

  describe :needs_key? do
    example do
      provider.needs_key?.should == false
    end
  end

  describe :push_app do
    example "Without :app" do
      provider.context.should_receive(:shell).with("af update dpl")
      provider.context.should_receive(:shell).with("af logout")
      provider.push_app
    end
    example "With :app" do
      provider.options.update(:app => 'test')
      provider.context.should_receive(:shell).with("af update test")
      provider.context.should_receive(:shell).with("af logout")
      provider.push_app
    end
  end
end

Version data entries

84 entries across 84 versions & 1 rubygems

Version Path
dpl-1.5.2.travis.240.2 spec/provider/appfog_spec.rb
dpl-1.5.2.travis.226.2 spec/provider/appfog_spec.rb
dpl-1.5.2.travis.220.2 spec/provider/appfog_spec.rb
dpl-1.5.2.travis.218.2 spec/provider/appfog_spec.rb
dpl-1.5.2.travis.217.2 spec/provider/appfog_spec.rb
dpl-1.5.2.travis.216.2 spec/provider/appfog_spec.rb
dpl-1.5.2.travis.211.2 spec/provider/appfog_spec.rb
dpl-1.5.2.travis.208.2 spec/provider/appfog_spec.rb
dpl-1.5.2.travis.206.2 spec/provider/appfog_spec.rb
dpl-1.5.2.travis.201.2 spec/provider/appfog_spec.rb
dpl-1.5.2.travis.200.2 spec/provider/appfog_spec.rb
dpl-1.5.2.travis.197.2 spec/provider/appfog_spec.rb
dpl-1.5.2.travis.196.2 spec/provider/appfog_spec.rb
dpl-1.5.2.travis.194.2 spec/provider/appfog_spec.rb
dpl-1.5.2.travis.193.2 spec/provider/appfog_spec.rb
dpl-1.5.2.travis.190.2 spec/provider/appfog_spec.rb
dpl-1.5.2.travis.188.2 spec/provider/appfog_spec.rb
dpl-1.5.2.travis.187.2 spec/provider/appfog_spec.rb
dpl-1.5.2.travis.184.2 spec/provider/appfog_spec.rb
dpl-1.5.2.travis.183.2 spec/provider/appfog_spec.rb