@@ -64,8 +64,8 @@ namespace :test do
6464 command = "bundle check || bundle install && bundle exec rake #{ spec_task } "
6565 command += "'[#{ spec_arguments } ]'" if spec_arguments
6666
67- total_executors = Datadog :: DATADOG_ENV . key? ( 'CIRCLE_NODE_TOTAL' ) ? Datadog :: DATADOG_ENV [ 'CIRCLE_NODE_TOTAL' ] . to_i : nil
68- current_executor = Datadog :: DATADOG_ENV . key? ( 'CIRCLE_NODE_INDEX' ) ? Datadog :: DATADOG_ENV [ 'CIRCLE_NODE_INDEX' ] . to_i : nil
67+ total_executors = ENV . key? ( 'CIRCLE_NODE_TOTAL' ) ? ENV [ 'CIRCLE_NODE_TOTAL' ] . to_i : nil
68+ current_executor = ENV . key? ( 'CIRCLE_NODE_INDEX' ) ? ENV [ 'CIRCLE_NODE_INDEX' ] . to_i : nil
6969
7070 if total_executors && current_executor && total_executors > 1
7171 @execution_count ||= 0
@@ -467,11 +467,11 @@ namespace :coverage do
467467 task :report do
468468 require 'simplecov'
469469
470- resultset_files = Dir [ "#{ Datadog :: DATADOG_ENV . fetch ( "COVERAGE_DIR" , "coverage" ) } /.resultset.json" ] +
471- Dir [ "#{ Datadog :: DATADOG_ENV . fetch ( "COVERAGE_DIR" , "coverage" ) } /versions/**/.resultset.json" ]
470+ resultset_files = Dir [ "#{ ENV . fetch ( "COVERAGE_DIR" , "coverage" ) } /.resultset.json" ] +
471+ Dir [ "#{ ENV . fetch ( "COVERAGE_DIR" , "coverage" ) } /versions/**/.resultset.json" ]
472472
473473 SimpleCov . collate resultset_files do
474- coverage_dir "#{ Datadog :: DATADOG_ENV . fetch ( "COVERAGE_DIR" , "coverage" ) } /report"
474+ coverage_dir "#{ ENV . fetch ( "COVERAGE_DIR" , "coverage" ) } /report"
475475 formatter SimpleCov ::Formatter ::HTMLFormatter
476476 end
477477 end
@@ -481,11 +481,11 @@ namespace :coverage do
481481 require 'simplecov'
482482 require_relative 'spec/support/simplecov_fix'
483483
484- versions = Dir [ "#{ Datadog :: DATADOG_ENV . fetch ( "COVERAGE_DIR" , "coverage" ) } /versions/*" ] . map { |f | File . basename ( f ) }
484+ versions = Dir [ "#{ ENV . fetch ( "COVERAGE_DIR" , "coverage" ) } /versions/*" ] . map { |f | File . basename ( f ) }
485485 versions . map do |version |
486486 puts "Generating report for: #{ version } "
487- SimpleCov . collate Dir [ "#{ Datadog :: DATADOG_ENV . fetch ( "COVERAGE_DIR" , "coverage" ) } /versions/#{ version } /**/.resultset.json" ] do
488- coverage_dir "#{ Datadog :: DATADOG_ENV . fetch ( "COVERAGE_DIR" , "coverage" ) } /report/versions/#{ version } "
487+ SimpleCov . collate Dir [ "#{ ENV . fetch ( "COVERAGE_DIR" , "coverage" ) } /versions/#{ version } /**/.resultset.json" ] do
488+ coverage_dir "#{ ENV . fetch ( "COVERAGE_DIR" , "coverage" ) } /report/versions/#{ version } "
489489 formatter SimpleCov ::Formatter ::HTMLFormatter
490490 end
491491 end
0 commit comments