Sha256: 39859edd3ef5f9447417d4fcd2848459d90200d3895b8acfc66eeae87d7a186c

Contents?: true

Size: 1.31 KB

Versions: 3

Compression:

Stored size: 1.31 KB

Contents

# frozen_string_literal: true

require './test/multiverse/lib/multiverse/bundler_patch'

test_folders = Dir.glob('test/new_relic/*').select { |f| File.directory?(f) }
test_folders += Dir.glob('test/new_relic/**/*').select { |f| File.directory?(f) }

rake_lib_path = Bundler.with_unbundled_env { `bundle exec gem which rake`.chomp.gsub('lib/rake.rb', 'lib') }
ruby_options = %(-w -I"#{rake_lib_path}" "#{rake_lib_path}/rake/rake_test_loader.rb")

guard_options = {
  spring: "bundle exec ruby #{ruby_options} ",
  test_folders: ['test/new_relic'] + test_folders,
  all_after_pass: false,
  all_on_start: false
}

guard :minitest, guard_options do
  watch(%r{^lib/(.+)\.rb$}) { |m| "test/#{m[1]}_test.rb" }
  watch(%r{^test/.+_test\.rb$})
  watch(%r{^test/rum/.*}) { 'test/new_relic/rack/browser_monitoring_test.rb' }
  watch(%r{^test/fixtures/cross_agent_tests/distributed_tracing/(.+).json}) { |m| "test/new_relic/agent/distributed_tracing/#{m[1]}_cross_agent_test.rb" }
  watch('test/test_helper.rb') { 'test/new_relic' }
  watch('test/agent_helper.rb') { 'test/new_relic' }
  watch('lib/new_relic/agent/configuration/default_source.rb') { 'test/new_relic/agent/configuration/orphan_configuration_test.rb' }
  watch(%r{^lib/new_relic/agent/transaction/(.+).rb}) { |m| "test/new_relic/agent/distributed_tracing/#{m[1]}_cross_agent_test.rb" }
end

Version data entries

3 entries across 3 versions & 1 rubygems

Version Path
newrelic_rpm-9.2.2 Guardfile
newrelic_rpm-9.2.1 Guardfile
newrelic_rpm-9.2.0 Guardfile