Sha256: 92564af8a3dfc7e74d2e16457dffcd7fd2012fb7b82c75367cf29c2d551d615b
Contents?: true
Size: 1 KB
Versions: 1
Compression:
Stored size: 1 KB
Contents
require File.dirname(__FILE__) + '/helper' require 'capistrano/configuration' require 'airbrake/capistrano' class CapistranoTest < Test::Unit::TestCase def setup super reset_config @configuration = Capistrano::Configuration.new Airbrake::Capistrano.load_into(@configuration) @configuration.dry_run = true end should "define deploy:notify_airbrake task" do assert_not_nil @configuration.find_task('airbrake:notify') end should "log when calling deploy:notify_airbrake task" do @configuration.set(:current_revision, '084505b1c0e0bcf1526e673bb6ac99fbcb18aecc') @configuration.set(:repository, 'repository') io = StringIO.new logger = Capistrano::Logger.new(:output => io) logger.level = Capistrano::Logger::MAX_LEVEL @configuration.logger = logger @configuration.find_and_execute_task('airbrake:notify') assert io.string.include?('** Notifying Airbrake of Deploy') assert io.string.include?('** Airbrake Notification Complete') end end
Version data entries
1 entries across 1 versions & 1 rubygems
Version | Path |
---|---|
airbrake-3.0.3 | test/capistrano_test.rb |