Sha256: 1651ff6640afa40eb06af1fc72d5fce6fb9fc000491a5c1ed8960573f658b4bc

Contents?: true

Size: 1.01 KB

Versions: 3

Compression:

Stored size: 1.01 KB

Contents

require 'spec_helper'

feature 'Heroku' do
  scenario 'Suspend a project with --heroku=true' do
    run_suspenders('--heroku=true')

    expect(FakeHeroku).to have_gem_included(project_path, 'rails_12factor')
    expect(FakeHeroku).to have_created_app_for('staging')
    expect(FakeHeroku).to have_created_app_for('production')
    expect(FakeHeroku).to have_configured_vars('staging', 'SECRET_KEY_BASE')
    expect(FakeHeroku).to have_configured_vars('production', 'SECRET_KEY_BASE')

    bin_setup = IO.read("#{project_path}/bin/setup")
    app_name = SuspendersTestHelpers::APP_NAME

    expect(bin_setup).to include("heroku join --app #{app_name}-staging")
    expect(bin_setup).to include("heroku join --app #{app_name}-production")

    bin_deploy = IO.read("#{project_path}/bin/deploy")

    expect(bin_deploy).to include("heroku run rake db:migrate")

    readme = IO.read("#{project_path}/README.md")

    expect(readme).to include("./bin/deploy staging")
    expect(readme).to include("./bin/deploy production")
  end
end

Version data entries

3 entries across 3 versions & 1 rubygems

Version Path
welaika-suspenders-2.3.0 spec/features/heroku_spec.rb
welaika-suspenders-2.2.1 spec/features/heroku_spec.rb
welaika-suspenders-2.2.0 spec/features/heroku_spec.rb