Sha256: c27130c5e1e5a95f40139e6846c1acd10b228b3881cec687d8d33d73f77ad8d0

Contents?: true

Size: 710 Bytes

Versions: 19

Compression:

Stored size: 710 Bytes

Contents

require 'test_helper'

class CITest < Minitest::Test

  def test_ci_create_app_with_stack
    Hatchet::GitApp.new("rails5_ruby_schema_format").run_ci do |test_run|
      assert_match "Ruby buildpack tests completed successfully", test_run.output
      assert_equal :succeeded, test_run.status
    end
  end

  def test_error_with_bad_app
    error = assert_raise(Hatchet::FailedTestError) do
      Hatchet::GitApp.new("rails5_ci_fails_no_database").run_ci {}
    end

    assert_match "PG::ConnectionBad: could not connect to server" ,error.message

    Hatchet::GitApp.new("rails5_ci_fails_no_database", allow_failure: true).run_ci do |test_run|
      assert_equal :errored, test_run.status
    end
  end
end

Version data entries

19 entries across 19 versions & 1 rubygems

Version Path
heroku_hatchet-4.0.12 test/hatchet/ci_test.rb
heroku_hatchet-4.0.11 test/hatchet/ci_test.rb
heroku_hatchet-4.0.10 test/hatchet/ci_test.rb
heroku_hatchet-4.0.9 test/hatchet/ci_test.rb
heroku_hatchet-4.0.8 test/hatchet/ci_test.rb
heroku_hatchet-4.0.7 test/hatchet/ci_test.rb
heroku_hatchet-4.0.6 test/hatchet/ci_test.rb
heroku_hatchet-4.0.5 test/hatchet/ci_test.rb
heroku_hatchet-4.0.4 test/hatchet/ci_test.rb
heroku_hatchet-4.0.3 test/hatchet/ci_test.rb
heroku_hatchet-4.0.2 test/hatchet/ci_test.rb
heroku_hatchet-4.0.1 test/hatchet/ci_test.rb
heroku_hatchet-4.0.0 test/hatchet/ci_test.rb
heroku_hatchet-3.1.1 test/hatchet/ci_test.rb
heroku_hatchet-3.1.0 test/hatchet/ci_test.rb
heroku_hatchet-3.0.6 test/hatchet/ci_test.rb
heroku_hatchet-3.0.5 test/hatchet/ci_test.rb
heroku_hatchet-3.0.4 test/hatchet/ci_test.rb
heroku_hatchet-3.0.3 test/hatchet/ci_test.rb