diff --git a/rspec-core/.rubocop_rspec_base.yml b/rspec-core/.rubocop_rspec_base.yml index 852893b2a..a98671e06 100644 --- a/rspec-core/.rubocop_rspec_base.yml +++ b/rspec-core/.rubocop_rspec_base.yml @@ -1,4 +1,4 @@ -# This file was generated on 2020-01-23T22:37:16+03:00 from the rspec-dev repo. +# This file was generated on 2020-04-03T18:53:21+03:00 from the rspec-dev repo. # DO NOT modify it by hand as your changes will get lost the next time it is generated. # This file contains defaults for RSpec projects. Individual projects diff --git a/rspec-core/.travis.yml b/rspec-core/.travis.yml index 41253a3ef..8fdc4348b 100644 --- a/rspec-core/.travis.yml +++ b/rspec-core/.travis.yml @@ -1,4 +1,4 @@ -# This file was generated on 2020-01-23T22:37:16+03:00 from the rspec-dev repo. +# This file was generated on 2020-04-03T18:53:21+03:00 from the rspec-dev repo. # DO NOT modify it by hand as your changes will get lost the next time it is generated. # In order to install old Rubies, we need to use old Ubuntu distibution. @@ -22,10 +22,10 @@ rvm: - 2.1 - 2.2.10 - 2.3.8 - - 2.4.9 - - 2.5.7 - - 2.6.5 - - 2.7.0 + - 2.4.10 + - 2.5.8 + - 2.6.6 + - 2.7.1 - ruby-head - ree - rbx-3 diff --git a/rspec-core/Gemfile b/rspec-core/Gemfile index 22e791c05..b781ec5cd 100644 --- a/rspec-core/Gemfile +++ b/rspec-core/Gemfile @@ -12,12 +12,12 @@ branch = File.read(File.expand_path("../maintenance-branch", __FILE__)).chomp end end -if RUBY_VERSION >= '2.0.0' - gem 'rake', '>= 10.0.0' -elsif RUBY_VERSION >= '1.9.3' +if RUBY_VERSION < '1.9.3' + gem 'rake', '< 11.0.0' # rake 11 requires Ruby 1.9.3 or later +elsif RUBY_VERSION < '2.0.0' gem 'rake', '< 12.0.0' # rake 12 requires Ruby 2.0.0 or later else - gem 'rake', '< 11.0.0' # rake 11 requires Ruby 1.9.3 or later + gem 'rake', '> 12.3.2' end gem 'yard', '~> 0.9.24', :require => false diff --git a/rspec-core/appveyor.yml b/rspec-core/appveyor.yml index d5eb832c7..496e42152 100644 --- a/rspec-core/appveyor.yml +++ b/rspec-core/appveyor.yml @@ -1,4 +1,4 @@ -# This file was generated on 2020-01-23T22:37:16+03:00 from the rspec-dev repo. +# This file was generated on 2020-04-03T18:53:21+03:00 from the rspec-dev repo. # DO NOT modify it by hand as your changes will get lost the next time it is generated. version: "{build}" diff --git a/rspec-core/script/clone_all_rspec_repos b/rspec-core/script/clone_all_rspec_repos index bd137b3a7..9a741818c 100755 --- a/rspec-core/script/clone_all_rspec_repos +++ b/rspec-core/script/clone_all_rspec_repos @@ -1,5 +1,5 @@ #!/bin/bash -# This file was generated on 2020-01-23T22:37:16+03:00 from the rspec-dev repo. +# This file was generated on 2020-04-03T18:53:21+03:00 from the rspec-dev repo. # DO NOT modify it by hand as your changes will get lost the next time it is generated. set -e diff --git a/rspec-core/script/functions.sh b/rspec-core/script/functions.sh index 545a18b86..713b9fb2e 100644 --- a/rspec-core/script/functions.sh +++ b/rspec-core/script/functions.sh @@ -1,4 +1,4 @@ -# This file was generated on 2020-01-23T22:37:16+03:00 from the rspec-dev repo. +# This file was generated on 2020-04-03T18:53:21+03:00 from the rspec-dev repo. # DO NOT modify it by hand as your changes will get lost the next time it is generated. SCRIPT_DIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )" @@ -187,7 +187,6 @@ function run_all_spec_suites { fold "rspec-core specs" run_spec_suite_for "rspec-core" fold "rspec-expectations specs" run_spec_suite_for "rspec-expectations" fold "rspec-mocks specs" run_spec_suite_for "rspec-mocks" - if rspec_rails_compatible; then fold "rspec-rails specs" run_spec_suite_for "rspec-rails" fi diff --git a/rspec-core/script/predicate_functions.sh b/rspec-core/script/predicate_functions.sh index 17516df41..b733b725b 100644 --- a/rspec-core/script/predicate_functions.sh +++ b/rspec-core/script/predicate_functions.sh @@ -1,4 +1,4 @@ -# This file was generated on 2020-01-23T22:37:16+03:00 from the rspec-dev repo. +# This file was generated on 2020-04-03T18:53:21+03:00 from the rspec-dev repo. # DO NOT modify it by hand as your changes will get lost the next time it is generated. function is_mri { @@ -73,18 +73,6 @@ function is_ruby_25_plus { fi } -function is_mri_27 { - if is_mri; then - if ruby -e "exit(RUBY_VERSION.to_f == 2.7)"; then - return 0 - else - return 1 - fi - else - return 1 - fi -} - function rspec_rails_compatible { if is_ruby_25_plus; then return 0 @@ -109,11 +97,7 @@ function additional_specs_available { function documentation_enforced { if [ -x ./bin/yard ]; then if is_mri_2plus; then - if is_mri_27; then - return 1 - else - return 0 - fi + return 0 else return 1 fi diff --git a/rspec-core/script/run_build b/rspec-core/script/run_build index f1b755274..b5958fb8f 100755 --- a/rspec-core/script/run_build +++ b/rspec-core/script/run_build @@ -1,5 +1,5 @@ #!/bin/bash -# This file was generated on 2020-01-23T22:37:16+03:00 from the rspec-dev repo. +# This file was generated on 2020-04-03T18:53:21+03:00 from the rspec-dev repo. # DO NOT modify it by hand as your changes will get lost the next time it is generated. set -e diff --git a/rspec-core/script/travis_functions.sh b/rspec-core/script/travis_functions.sh index 9574746a3..725c1184c 100644 --- a/rspec-core/script/travis_functions.sh +++ b/rspec-core/script/travis_functions.sh @@ -1,4 +1,4 @@ -# This file was generated on 2020-01-23T22:37:16+03:00 from the rspec-dev repo. +# This file was generated on 2020-04-03T18:53:21+03:00 from the rspec-dev repo. # DO NOT modify it by hand as your changes will get lost the next time it is generated. # Taken from: diff --git a/rspec-core/script/update_rubygems_and_install_bundler b/rspec-core/script/update_rubygems_and_install_bundler index b569ac0aa..4ceb930cd 100755 --- a/rspec-core/script/update_rubygems_and_install_bundler +++ b/rspec-core/script/update_rubygems_and_install_bundler @@ -1,5 +1,5 @@ #!/bin/bash -# This file was generated on 2020-01-23T22:37:16+03:00 from the rspec-dev repo. +# This file was generated on 2020-04-03T18:53:21+03:00 from the rspec-dev repo. # DO NOT modify it by hand as your changes will get lost the next time it is generated. set -e diff --git a/rspec-core/spec/rspec/core/example_spec.rb b/rspec-core/spec/rspec/core/example_spec.rb index 81a7cec4a..325efe91f 100644 --- a/rspec-core/spec/rspec/core/example_spec.rb +++ b/rspec-core/spec/rspec/core/example_spec.rb @@ -443,7 +443,9 @@ def assert(val) context 'memory leaks, see GH-321, GH-1921' do def self.reliable_gc - 0 != GC.method(:start).arity # older Rubies don't give us options to ensure a full GC + # older Rubies don't give us options to ensure a full GC + # TruffleRuby GC.start arity matches but GC.disable and GC.enable are mock implementations + 0 != GC.method(:start).arity && !(defined?(RUBY_ENGINE) && RUBY_ENGINE == "truffleruby") end def expect_gc(opts) diff --git a/rspec-core/spec/rspec/core/rake_task_spec.rb b/rspec-core/spec/rspec/core/rake_task_spec.rb index 576b8637d..a1168b6de 100644 --- a/rspec-core/spec/rspec/core/rake_task_spec.rb +++ b/rspec-core/spec/rspec/core/rake_task_spec.rb @@ -170,7 +170,7 @@ def silence_output(&block) expect { task.with_clean_environment = true - task.ruby_opts = '-e "puts \"Environment: #{ENV.keys}\""' + task.ruby_opts = '-e "puts \"Environment: #{ENV.keys.sort.inspect}\""' task.run_task false }.to avoid_outputting.to_stderr.and output(essential_shell_variables).to_stdout_from_any_process end diff --git a/rspec-core/spec/support/helper_methods.rb b/rspec-core/spec/support/helper_methods.rb index 1ed3d7934..c4a7027b8 100644 --- a/rspec-core/spec/support/helper_methods.rb +++ b/rspec-core/spec/support/helper_methods.rb @@ -15,8 +15,9 @@ def ignoring_warnings end # In Ruby 2.7 taint was removed and has no effect, whilst SAFE warns that it - # has no effect and will become a normal varible in 3.0. - if RUBY_VERSION >= '2.7' + # has no effect and will become a normal varible in 3.0. Other engines do not + # implement SAFE. + if RUBY_VERSION >= '2.7' || (defined?(RUBY_ENGINE) && RUBY_ENGINE != "ruby") def with_safe_set_to_level_that_triggers_security_errors yield end