Sha256: 6748336f072e95732135ed33a50b39bd11fdd3018040c0e0a75c1528490fd618

Contents?: true

Size: 1.34 KB

Versions: 79

Compression:

Stored size: 1.34 KB

Contents

Shindo.tests("Fog::AWS[:beanstalk] | versions", ['aws', 'beanstalk']) do

  pending if Fog.mocking?

  @beanstalk = Fog::AWS[:beanstalk]

  @application_name = uniq_id('fog-test-app')
  @version_name = uniq_id('fog-test-version')

  @version_description = 'A nice description'

  @application = @beanstalk.applications.create({:name => @application_name})

  params = {
      :application_name => @application_name,
      :label => @version_name,
      :description => @version_description
  }

  collection = @beanstalk.versions

  tests('success') do

    tests("#new(#{params.inspect})").succeeds do
      pending if Fog.mocking?
      collection.new(params)
    end

    tests("#create(#{params.inspect})").succeeds do
      pending if Fog.mocking?
      @instance = collection.create(params)
    end

    tests("#all").succeeds do
      pending if Fog.mocking?
      collection.all
    end

    tests("#get(#{@application_name}, #{@version_name})").succeeds do
      pending if Fog.mocking?
      collection.get(@application_name, @version_name)
    end

    if !Fog.mocking?
      @instance.destroy
    end
  end

  tests('failure') do

    tests("#get(#{@application_name}, #{@version_name})").returns(nil) do
      pending if Fog.mocking?
      collection.get(@application_name, @version_name)
    end

  end

  # delete application
  @application.destroy
end

Version data entries

79 entries across 77 versions & 6 rubygems

Version Path
vagrant-packet-0.1.1 vendor/bundle/ruby/2.4.0/gems/fog-aws-2.0.1/tests/models/beanstalk/versions_tests.rb
vagrant-packet-0.1.1 vendor/bundle/ruby/2.5.0/gems/fog-aws-2.0.1/tests/models/beanstalk/versions_tests.rb
fog-aws-3.0.0 tests/models/beanstalk/versions_tests.rb
fog-aws-2.0.1 tests/models/beanstalk/versions_tests.rb
fog-aws-2.0.0 tests/models/beanstalk/versions_tests.rb
fog-aws-1.4.1 tests/models/beanstalk/versions_tests.rb
fog-aws-1.4.0 tests/models/beanstalk/versions_tests.rb
fog-aws-1.3.0 tests/models/beanstalk/versions_tests.rb
fog-aws-1.2.1 tests/models/beanstalk/versions_tests.rb
fog-aws-1.2.0 tests/models/beanstalk/versions_tests.rb
fog-aws-1.1.0 tests/models/beanstalk/versions_tests.rb
fog-aws-1.0.0 tests/models/beanstalk/versions_tests.rb
fog-aws-0.13.0 tests/models/beanstalk/versions_tests.rb
fog-aws-0.12.0 tests/models/beanstalk/versions_tests.rb
fog-aws-0.11.0 tests/models/beanstalk/versions_tests.rb
fog-aws-0.10.0 tests/models/beanstalk/versions_tests.rb
fog-aws-0.9.4 tests/models/beanstalk/versions_tests.rb
fog-aws-0.9.3 tests/models/beanstalk/versions_tests.rb
fog-aws-0.9.2 tests/models/beanstalk/versions_tests.rb
fog-aws-0.9.1 tests/models/beanstalk/versions_tests.rb