test/test_helper.rb in propono-2.0.0.rc2 vs test/test_helper.rb in propono-2.0.0.rc3

- old
+ new

@@ -12,30 +12,25 @@ class Minitest::Test def setup end def propono_config - return @propono_config if @propono_config + @propono_config ||= Propono::Configuration.new.tap do |c| + c.access_key = "test-access-key" + c.secret_key = "test-secret-key" + c.queue_region = "us-east-1" + c.application_name = "MyApp" + c.queue_suffix = "" - @propono_config = Propono::Configuration.new - @propono_config.access_key = "test-access-key" - @propono_config.secret_key = "test-secret-key" - @propono_config.queue_region = "us-east-1" - @propono_config.application_name = "MyApp" - @propono_config.queue_suffix = "" - - @propono_config.logger.stubs(:debug) - @propono_config.logger.stubs(:info) - @propono_config.logger.stubs(:error) - - @propono_config + c.logger.stubs(:debug) + c.logger.stubs(:info) + c.logger.stubs(:error) + end end def aws_client - return @aws_client if @aws_client - - @aws_client = Propono::AwsClient.new(mock) - @aws_client.stubs(:sns_client) - @aws_client.stubs(:sqs_client) - @aws_client + @aws_client ||= Propono::AwsClient.new(mock).tap do |c| + c.stubs(:sns_client) + c.stubs(:sqs_client) + end end end