Sha256: 7c0653a796e8637466a1331826ce49d2a0e06bedaa21bd98718671ef5bda85ed

Contents?: true

Size: 861 Bytes

Versions: 18

Compression:

Stored size: 861 Bytes

Contents

ENV["TEST"] = "1"
ENV["AWS_EC2_ENV"] = "test"
ENV["AWS_EC2_ROOT"] = "spec/fixtures/demo_project"
# Ensures aws api never called. Fixture home folder does not contain ~/.aws/credentails
ENV['HOME'] = "spec/fixtures/home"

# CodeClimate test coverage: https://docs.codeclimate.com/docs/configuring-test-coverage
# require 'simplecov'
# SimpleCov.start

require "pp"
require "byebug"
root = File.expand_path("../", File.dirname(__FILE__))
require "#{root}/lib/aws-ec2"

module Helper
  def execute(cmd)
    puts "Running: #{cmd}" if show_command?
    out = `#{cmd}`
    puts out if show_command?
    out
  end

  # Added SHOW_COMMAND because DEBUG is also used by other libraries like
  # bundler and it shows its internal debugging logging also.
  def show_command?
    ENV['DEBUG'] || ENV['SHOW_COMMAND']
  end
end

RSpec.configure do |c|
  c.include Helper
end

Version data entries

18 entries across 18 versions & 1 rubygems

Version Path
aws-ec2-1.4.9 spec/spec_helper.rb
aws-ec2-1.4.8 spec/spec_helper.rb
aws-ec2-1.4.7 spec/spec_helper.rb
aws-ec2-1.4.6 spec/spec_helper.rb
aws-ec2-1.4.5 spec/spec_helper.rb
aws-ec2-1.4.4 spec/spec_helper.rb
aws-ec2-1.4.3 spec/spec_helper.rb
aws-ec2-1.4.2 spec/spec_helper.rb
aws-ec2-1.4.1 spec/spec_helper.rb
aws-ec2-1.4.0 spec/spec_helper.rb
aws-ec2-1.3.2 spec/spec_helper.rb
aws-ec2-1.3.1 spec/spec_helper.rb
aws-ec2-1.3.0 spec/spec_helper.rb
aws-ec2-1.2.2 spec/spec_helper.rb
aws-ec2-1.2.1 spec/spec_helper.rb
aws-ec2-1.2.0 spec/spec_helper.rb
aws-ec2-1.1.0 spec/spec_helper.rb
aws-ec2-1.0.0 spec/spec_helper.rb