From a793bc500cf5f4c00fb37e15688b7dc6ade1e1a3 Mon Sep 17 00:00:00 2001 From: Markus Reiter Date: Wed, 10 Jun 2020 16:39:03 +0200 Subject: [PATCH 01/25] Fix failing appcast check. --- Library/Homebrew/cask/audit.rb | 14 +++++++++----- 1 file changed, 9 insertions(+), 5 deletions(-) diff --git a/Library/Homebrew/cask/audit.rb b/Library/Homebrew/cask/audit.rb index 441509bc38..1556296c32 100644 --- a/Library/Homebrew/cask/audit.rb +++ b/Library/Homebrew/cask/audit.rb @@ -310,10 +310,16 @@ module Cask return if cask.appcast.must_contain == :no_check appcast_stanza = cask.appcast.to_s - appcast_contents, = curl_output("--compressed", "--user-agent", HOMEBREW_USER_AGENT_FAKE_SAFARI, "--location", - "--globoff", "--max-time", "5", appcast_stanza) + appcast_contents, = begin + curl_output("--compressed", "--user-agent", HOMEBREW_USER_AGENT_FAKE_SAFARI, "--location", + "--globoff", "--max-time", "5", appcast_stanza) + rescue + add_error "appcast at URL '#{appcast_stanza}' offline or looping" + return + end + version_stanza = cask.version.to_s - adjusted_version_stanza = if cask.appcast.configuration.blank? + adjusted_version_stanza = if cask.appcast.must_contain.blank? version_stanza.match(/^[[:alnum:].]+/)[0] else cask.appcast.must_contain @@ -322,8 +328,6 @@ module Cask add_warning "appcast at URL '#{appcast_stanza}' does not contain"\ " the version number '#{adjusted_version_stanza}':\n#{appcast_contents}" - rescue - add_error "appcast at URL '#{appcast_stanza}' offline or looping" end def check_github_repository From 179e9e8d5a7cca330124a8e58989fc9b894221a4 Mon Sep 17 00:00:00 2001 From: "dependabot-preview[bot]" <27856297+dependabot-preview[bot]@users.noreply.github.com> Date: Wed, 10 Jun 2020 16:53:44 +0000 Subject: [PATCH 02/25] build(deps): bump parallel_tests in /Library/Homebrew Bumps [parallel_tests](https://github.com/grosser/parallel_tests) from 2.32.0 to 3.0.0. - [Release notes](https://github.com/grosser/parallel_tests/releases) - [Commits](https://github.com/grosser/parallel_tests/compare/v2.32.0...v3.0.0) Signed-off-by: dependabot-preview[bot] --- Library/Homebrew/Gemfile.lock | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Library/Homebrew/Gemfile.lock b/Library/Homebrew/Gemfile.lock index 420e9940c4..0ce3a4ee43 100644 --- a/Library/Homebrew/Gemfile.lock +++ b/Library/Homebrew/Gemfile.lock @@ -49,7 +49,7 @@ GEM mini_portile2 (~> 2.4.0) ntlm-http (0.1.1) parallel (1.19.1) - parallel_tests (2.32.0) + parallel_tests (3.0.0) parallel parser (2.7.1.3) ast (~> 2.4.0) From 1f8ebf5d20f81aea87b95710a2841134dbfa4a32 Mon Sep 17 00:00:00 2001 From: Michka Popoff Date: Sat, 6 Jun 2020 12:31:13 +0200 Subject: [PATCH 03/25] resource: allow on_os blocks --- Library/Homebrew/extend/os/linux/resource.rb | 9 +++++++++ Library/Homebrew/extend/os/mac/resource.rb | 9 +++++++++ Library/Homebrew/extend/os/resource.rb | 7 +++++++ Library/Homebrew/formula.rb | 4 ++-- Library/Homebrew/resource.rb | 14 ++++++++++++++ .../Homebrew/test/os/linux/formula_spec.rb | 19 +++++++++++++++++++ Library/Homebrew/test/os/mac/formula_spec.rb | 19 +++++++++++++++++++ 7 files changed, 79 insertions(+), 2 deletions(-) create mode 100644 Library/Homebrew/extend/os/linux/resource.rb create mode 100644 Library/Homebrew/extend/os/mac/resource.rb create mode 100644 Library/Homebrew/extend/os/resource.rb diff --git a/Library/Homebrew/extend/os/linux/resource.rb b/Library/Homebrew/extend/os/linux/resource.rb new file mode 100644 index 0000000000..a5af426c05 --- /dev/null +++ b/Library/Homebrew/extend/os/linux/resource.rb @@ -0,0 +1,9 @@ +# frozen_string_literal: true + +class Resource + undef on_linux + + def on_linux(&_block) + yield + end +end diff --git a/Library/Homebrew/extend/os/mac/resource.rb b/Library/Homebrew/extend/os/mac/resource.rb new file mode 100644 index 0000000000..2c53218564 --- /dev/null +++ b/Library/Homebrew/extend/os/mac/resource.rb @@ -0,0 +1,9 @@ +# frozen_string_literal: true + +class Resource + undef on_macos + + def on_macos(&_block) + yield + end +end diff --git a/Library/Homebrew/extend/os/resource.rb b/Library/Homebrew/extend/os/resource.rb new file mode 100644 index 0000000000..9ad337890c --- /dev/null +++ b/Library/Homebrew/extend/os/resource.rb @@ -0,0 +1,7 @@ +# frozen_string_literal: true + +if OS.mac? + require "extend/os/mac/resource" +elsif OS.linux? + require "extend/os/linux/resource" +end diff --git a/Library/Homebrew/formula.rb b/Library/Homebrew/formula.rb index 2a37b445dc..90448c1549 100644 --- a/Library/Homebrew/formula.rb +++ b/Library/Homebrew/formula.rb @@ -2474,13 +2474,13 @@ class Formula specs.each { |spec| spec.uses_from_macos(dep, bounds) } end - # Block executed only executed on macOS. No-op on Linux. + # Block only executed on macOS. No-op on Linux. #
on_macos do
     #   depends_on "mac_only_dep"
     # end
def on_macos(&_block); end - # Block executed only executed on Linux. No-op on macOS. + # Block only executed on Linux. No-op on macOS. #
on_linux do
     #   depends_on "linux_only_dep"
     # end
diff --git a/Library/Homebrew/resource.rb b/Library/Homebrew/resource.rb index 9053ac8b4d..4b00e4ea3a 100644 --- a/Library/Homebrew/resource.rb +++ b/Library/Homebrew/resource.rb @@ -178,6 +178,18 @@ class Resource patches << p end + # Block only executed on macOS. No-op on Linux. + #
on_macos do
+  #   url "mac_only_url"
+  # end
+ def on_macos(&_block); end + + # Block only executed on Linux. No-op on macOS. + #
on_linux do
+  #   url "linux_only_url"
+  # end
+ def on_linux(&_block); end + protected def mktemp(prefix) @@ -252,3 +264,5 @@ class ResourceStageContext "<#{self.class}: resource=#{resource} staging=#{staging}>" end end + +require "extend/os/resource" diff --git a/Library/Homebrew/test/os/linux/formula_spec.rb b/Library/Homebrew/test/os/linux/formula_spec.rb index cd79ce48ba..1bb963731b 100644 --- a/Library/Homebrew/test/os/linux/formula_spec.rb +++ b/Library/Homebrew/test/os/linux/formula_spec.rb @@ -110,4 +110,23 @@ describe Formula do expect(f.patchlist.second.url).to eq("patch_linux") end end + + describe "#on_linux" do + it "uses on_linux within a resource block" do + f = formula do + homepage "https://brew.sh" + + url "https://brew.sh/test-0.1.tbz" + sha256 TEST_SHA256 + + resource "test_resource" do + on_linux do + url "on_linux" + end + end + end + expect(f.resources.length).to eq(1) + expect(f.resources.first.url).to eq("on_linux") + end + end end diff --git a/Library/Homebrew/test/os/mac/formula_spec.rb b/Library/Homebrew/test/os/mac/formula_spec.rb index c966aef3d0..c885e916a7 100644 --- a/Library/Homebrew/test/os/mac/formula_spec.rb +++ b/Library/Homebrew/test/os/mac/formula_spec.rb @@ -117,4 +117,23 @@ describe Formula do expect(f.patchlist.second.url).to eq("patch_macos") end end + + describe "#on_macos" do + it "uses on_macos within a resource block" do + f = formula do + homepage "https://brew.sh" + + url "https://brew.sh/test-0.1.tbz" + sha256 TEST_SHA256 + + resource "test_resource" do + on_macos do + url "resource_macos" + end + end + end + expect(f.resources.length).to eq(1) + expect(f.resources.first.url).to eq("resource_macos") + end + end end From 2a50ef045fdb6a56a018853f70ef0a0d36a153a7 Mon Sep 17 00:00:00 2001 From: Michka Popoff Date: Mon, 8 Jun 2020 17:04:54 +0200 Subject: [PATCH 04/25] on_os blocks: remove url tests This is not allowed by the style audit, and we do not want to allow different source url's depending on the os. --- .../Homebrew/test/os/linux/formula_spec.rb | 20 ------------------- Library/Homebrew/test/os/mac/formula_spec.rb | 20 ------------------- 2 files changed, 40 deletions(-) diff --git a/Library/Homebrew/test/os/linux/formula_spec.rb b/Library/Homebrew/test/os/linux/formula_spec.rb index 1bb963731b..b8469e4efb 100644 --- a/Library/Homebrew/test/os/linux/formula_spec.rb +++ b/Library/Homebrew/test/os/linux/formula_spec.rb @@ -33,26 +33,6 @@ describe Formula do end end - describe "#on_linux" do - it "defines an url on Linux only" do - f = formula do - homepage "https://brew.sh" - - on_macos do - url "https://brew.sh/test-macos-0.1.tbz" - sha256 TEST_SHA256 - end - - on_linux do - url "https://brew.sh/test-linux-0.1.tbz" - sha256 TEST_SHA256 - end - end - - expect(f.stable.url).to eq("https://brew.sh/test-linux-0.1.tbz") - end - end - describe "#on_linux" do it "adds a dependency on Linux only" do f = formula do diff --git a/Library/Homebrew/test/os/mac/formula_spec.rb b/Library/Homebrew/test/os/mac/formula_spec.rb index c885e916a7..39510761fe 100644 --- a/Library/Homebrew/test/os/mac/formula_spec.rb +++ b/Library/Homebrew/test/os/mac/formula_spec.rb @@ -40,26 +40,6 @@ describe Formula do end end - describe "#on_macos" do - it "defines an url on macos only" do - f = formula do - homepage "https://brew.sh" - - on_macos do - url "https://brew.sh/test-macos-0.1.tbz" - sha256 TEST_SHA256 - end - - on_linux do - url "https://brew.sh/test-linux-0.1.tbz" - sha256 TEST_SHA256 - end - end - - expect(f.stable.url).to eq("https://brew.sh/test-macos-0.1.tbz") - end - end - describe "#on_macos" do it "adds a dependency on macos only" do f = formula do From 3ad900993768c078d5722d4e438f29c09de2355c Mon Sep 17 00:00:00 2001 From: Michka Popoff Date: Mon, 8 Jun 2020 23:23:42 +0200 Subject: [PATCH 05/25] on_os block: test support for patches --- Library/Homebrew/test/os/linux/formula_spec.rb | 16 ++++------------ Library/Homebrew/test/os/mac/formula_spec.rb | 18 +++++------------- 2 files changed, 9 insertions(+), 25 deletions(-) diff --git a/Library/Homebrew/test/os/linux/formula_spec.rb b/Library/Homebrew/test/os/linux/formula_spec.rb index b8469e4efb..159a0838ba 100644 --- a/Library/Homebrew/test/os/linux/formula_spec.rb +++ b/Library/Homebrew/test/os/linux/formula_spec.rb @@ -67,27 +67,19 @@ describe Formula do sha256 TEST_SHA256 patch do - url "patch_both" - end - - on_macos do - patch do + on_macos do url "patch_macos" end - end - on_linux do - patch do + on_linux do url "patch_linux" end end end - expect(f.patchlist.length).to eq(2) + expect(f.patchlist.length).to eq(1) expect(f.patchlist.first.strip).to eq(:p1) - expect(f.patchlist.first.url).to eq("patch_both") - expect(f.patchlist.second.strip).to eq(:p1) - expect(f.patchlist.second.url).to eq("patch_linux") + expect(f.patchlist.first.url).to eq("patch_linux") end end diff --git a/Library/Homebrew/test/os/mac/formula_spec.rb b/Library/Homebrew/test/os/mac/formula_spec.rb index 39510761fe..4fb4400c7f 100644 --- a/Library/Homebrew/test/os/mac/formula_spec.rb +++ b/Library/Homebrew/test/os/mac/formula_spec.rb @@ -66,7 +66,7 @@ describe Formula do end describe "#on_macos" do - it "adds a patch on macos only" do + it "adds a patch on Mac only" do f = formula do homepage "https://brew.sh" @@ -74,27 +74,19 @@ describe Formula do sha256 TEST_SHA256 patch do - url "patch_both" - end - - on_macos do - patch do + on_macos do url "patch_macos" end - end - on_linux do - patch do + on_linux do url "patch_linux" end end end - expect(f.patchlist.length).to eq(2) + expect(f.patchlist.length).to eq(1) expect(f.patchlist.first.strip).to eq(:p1) - expect(f.patchlist.first.url).to eq("patch_both") - expect(f.patchlist.second.strip).to eq(:p1) - expect(f.patchlist.second.url).to eq("patch_macos") + expect(f.patchlist.first.url).to eq("patch_macos") end end From 0c1cf592b744286bc3c1bce7a1ab1d9ca4464bda Mon Sep 17 00:00:00 2001 From: Misty De Meo Date: Thu, 4 Jun 2020 20:17:28 -0700 Subject: [PATCH 06/25] Bump minimum OS to Yosemite --- Library/Homebrew/brew.sh | 13 ++----------- Library/Homebrew/cmd/vendor-install.sh | 12 ++++++------ Library/Homebrew/vendor/portable-ruby-version | 2 +- 3 files changed, 9 insertions(+), 18 deletions(-) diff --git a/Library/Homebrew/brew.sh b/Library/Homebrew/brew.sh index 092b68a802..1c43a8f181 100644 --- a/Library/Homebrew/brew.sh +++ b/Library/Homebrew/brew.sh @@ -133,8 +133,8 @@ then # shellcheck disable=SC2086,SC2183 printf -v HOMEBREW_MACOS_VERSION_NUMERIC "%02d%02d%02d" ${HOMEBREW_MACOS_VERSION//./ } - # Refuse to run on pre-Mavericks - if [[ "$HOMEBREW_MACOS_VERSION_NUMERIC" -lt "100900" ]] + # Refuse to run on pre-Yosemite + if [[ "$HOMEBREW_MACOS_VERSION_NUMERIC" -lt "101000" ]] then printf "ERROR: Your version of macOS (%s) is too old to run Homebrew!\\n" "$HOMEBREW_MACOS_VERSION" >&2 if [[ "$HOMEBREW_MACOS_VERSION_NUMERIC" -lt "100700" ]] @@ -144,15 +144,6 @@ then printf "\\n" >&2 fi - # The system Curl is too old for some modern HTTPS certificates on - # older macOS versions. - # - if [[ "$HOMEBREW_MACOS_VERSION_NUMERIC" -lt "101000" ]] - then - HOMEBREW_SYSTEM_CURL_TOO_OLD="1" - HOMEBREW_FORCE_BREWED_CURL="1" - fi - # The system Git on macOS versions before Sierra is too old for some Homebrew functionality we rely on. HOMEBREW_MINIMUM_GIT_VERSION="2.14.3" if [[ "$HOMEBREW_MACOS_VERSION_NUMERIC" -lt "101200" ]] diff --git a/Library/Homebrew/cmd/vendor-install.sh b/Library/Homebrew/cmd/vendor-install.sh index 20e3432989..9b48d95f9b 100644 --- a/Library/Homebrew/cmd/vendor-install.sh +++ b/Library/Homebrew/cmd/vendor-install.sh @@ -17,17 +17,17 @@ if [[ -n "$HOMEBREW_MACOS" ]] then if [[ "$HOMEBREW_PROCESSOR" = "Intel" ]] then - ruby_URL="$HOMEBREW_BOTTLE_DOMAIN/bottles-portable-ruby/portable-ruby-2.6.3.mavericks.bottle.tar.gz" - ruby_URL2="https://github.com/Homebrew/homebrew-portable-ruby/releases/download/2.6.3/portable-ruby-2.6.3.mavericks.bottle.tar.gz" - ruby_SHA="ab81211a2052ccaa6d050741c433b728d0641523d8742eef23a5b450811e5104" + ruby_URL="$HOMEBREW_BOTTLE_DOMAIN/bottles-portable-ruby/portable-ruby-2.6.3_1.yosemite.bottle.tar.gz" + ruby_URL2="https://github.com/Homebrew/homebrew-portable-ruby/releases/download/2.6.3_1/portable-ruby-2.6.3_1.yosemite.bottle.tar.gz" + ruby_SHA="be48eade040e13e0e572300ba59cf43d5750f53a4f35d2051966a0194e3c0ab2" fi elif [[ -n "$HOMEBREW_LINUX" ]] then case "$HOMEBREW_PROCESSOR" in x86_64) - ruby_URL="$HOMEBREW_BOTTLE_DOMAIN/bottles-portable-ruby/portable-ruby-2.6.3.x86_64_linux.bottle.tar.gz" - ruby_URL2="https://github.com/Homebrew/homebrew-portable-ruby/releases/download/2.6.3/portable-ruby-2.6.3.x86_64_linux.bottle.tar.gz" - ruby_SHA="e8c9b6d3dc5f40844e07b4b694897b8b7cb5a7dab1013b3b8712a22868f98c98" + ruby_URL="$HOMEBREW_BOTTLE_DOMAIN/bottles-portable-ruby/portable-ruby-2.6.3_1.x86_64_linux.bottle.tar.gz" + ruby_URL2="https://github.com/Homebrew/homebrew-portable-ruby/releases/download/2.6.3_1/portable-ruby-2.6.3_1.x86_64_linux.bottle.tar.gz" + ruby_SHA="f5731ca80497c31ab1171ece4102e2104d9b6cd31aa7b35926e80829d4b0ce29" ;; aarch64) ruby_URL="$HOMEBREW_BOTTLE_DOMAIN/bottles-portable-ruby/portable-ruby-2.6.3.aarch64_linux.bottle.tar.gz" diff --git a/Library/Homebrew/vendor/portable-ruby-version b/Library/Homebrew/vendor/portable-ruby-version index ec1cf33c3f..1a8cd98428 100644 --- a/Library/Homebrew/vendor/portable-ruby-version +++ b/Library/Homebrew/vendor/portable-ruby-version @@ -1 +1 @@ -2.6.3 +2.6.3_1 From f4ff5a22f8c1dd6ea3543c6ef049c38517541f1b Mon Sep 17 00:00:00 2001 From: Misty De Meo Date: Mon, 8 Jun 2020 17:44:22 -0700 Subject: [PATCH 07/25] vendor-install: remove ARM --- Library/Homebrew/cmd/vendor-install.sh | 10 ---------- 1 file changed, 10 deletions(-) diff --git a/Library/Homebrew/cmd/vendor-install.sh b/Library/Homebrew/cmd/vendor-install.sh index 9b48d95f9b..14ec32e68d 100644 --- a/Library/Homebrew/cmd/vendor-install.sh +++ b/Library/Homebrew/cmd/vendor-install.sh @@ -29,16 +29,6 @@ then ruby_URL2="https://github.com/Homebrew/homebrew-portable-ruby/releases/download/2.6.3_1/portable-ruby-2.6.3_1.x86_64_linux.bottle.tar.gz" ruby_SHA="f5731ca80497c31ab1171ece4102e2104d9b6cd31aa7b35926e80829d4b0ce29" ;; - aarch64) - ruby_URL="$HOMEBREW_BOTTLE_DOMAIN/bottles-portable-ruby/portable-ruby-2.6.3.aarch64_linux.bottle.tar.gz" - ruby_URL2="https://github.com/Homebrew/homebrew-portable-ruby/releases/download/2.6.3/portable-ruby-2.6.3.aarch64_linux.bottle.tar.gz" - ruby_SHA="c0b08e2835897af74948508a004d30380b8bcf14264e0dcce194e2c199fb1e35" - ;; - armv[67]*) - ruby_URL="$HOMEBREW_BOTTLE_DOMAIN/bottles-portable-ruby/portable-ruby-2.6.3.armv6_linux.bottle.tar.gz" - ruby_URL2="https://github.com/Homebrew/homebrew-portable-ruby/releases/download/2.6.3/portable-ruby-2.6.3.armv6_linux.bottle.tar.gz" - ruby_SHA="78e36e4671fd08790bfbfda4408d559341c9872bf48a4f6eab78157a3bf3efa6" - ;; esac fi From a7b02a666512ecfd0bad11d25be047ea7558b6a0 Mon Sep 17 00:00:00 2001 From: "dependabot-preview[bot]" <27856297+dependabot-preview[bot]@users.noreply.github.com> Date: Thu, 11 Jun 2020 05:35:24 +0000 Subject: [PATCH 08/25] build(deps): bump ast from 2.4.0 to 2.4.1 in /Library/Homebrew Bumps [ast](https://github.com/whitequark/ast) from 2.4.0 to 2.4.1. - [Release notes](https://github.com/whitequark/ast/releases) - [Changelog](https://github.com/whitequark/ast/blob/master/CHANGELOG.md) - [Commits](https://github.com/whitequark/ast/compare/v2.4.0...v2.4.1) Signed-off-by: dependabot-preview[bot] --- Library/Homebrew/Gemfile.lock | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Library/Homebrew/Gemfile.lock b/Library/Homebrew/Gemfile.lock index 420e9940c4..e5cad32029 100644 --- a/Library/Homebrew/Gemfile.lock +++ b/Library/Homebrew/Gemfile.lock @@ -7,7 +7,7 @@ GEM minitest (~> 5.1) tzinfo (~> 1.1) zeitwerk (~> 2.2, >= 2.2.2) - ast (2.4.0) + ast (2.4.1) byebug (11.1.3) concurrent-ruby (1.1.6) connection_pool (2.2.3) From 536726799d24afb704d420f772a8f9b60150fa32 Mon Sep 17 00:00:00 2001 From: vidusheeamoli Date: Thu, 11 Jun 2020 10:18:54 +0530 Subject: [PATCH 09/25] Gemfile: add sorbet and sorbet-runtime bundler/setup: add sorbet and sorbet-runtime --- .gitignore | 4 +++- Library/Homebrew/Gemfile | 2 ++ Library/Homebrew/Gemfile.lock | 6 ++++++ Library/Homebrew/vendor/bundle/bundler/setup.rb | 2 ++ 4 files changed, 13 insertions(+), 1 deletion(-) diff --git a/.gitignore b/.gitignore index 45de01f3f3..c10b081c15 100644 --- a/.gitignore +++ b/.gitignore @@ -82,6 +82,7 @@ # Ignore dependencies we don't wish to vendor **/vendor/bundle/ruby/*/gems/ast-*/ **/vendor/bundle/ruby/*/gems/bundler-*/ +**/vendor/bundle/ruby/*/gems/byebug-*/ **/vendor/bundle/ruby/*/gems/coderay-*/ **/vendor/bundle/ruby/*/gems/connection_pool-*/ **/vendor/bundle/ruby/*/gems/coveralls-*/ @@ -127,6 +128,8 @@ **/vendor/bundle/ruby/*/gems/simplecov-*/ **/vendor/bundle/ruby/*/gems/simplecov-cobertura-*/ **/vendor/bundle/ruby/*/gems/simplecov-html-*/ +**/vendor/bundle/ruby/*/gems/sorbet-*/ +**/vendor/bundle/ruby/*/gems/sorbet-runtime-*/ **/vendor/bundle/ruby/*/gems/term-ansicolor-*/ **/vendor/bundle/ruby/*/gems/thor-*/ **/vendor/bundle/ruby/*/gems/tins-*/ @@ -134,7 +137,6 @@ **/vendor/bundle/ruby/*/gems/unf-*/ **/vendor/bundle/ruby/*/gems/unicode-display_width-*/ **/vendor/bundle/ruby/*/gems/webrobots-*/ -**/vendor/bundle/ruby/*/gems/byebug-*/ # Ignore `bin` contents (again). /bin diff --git a/Library/Homebrew/Gemfile b/Library/Homebrew/Gemfile index 2c28f3de29..77afd2fa27 100644 --- a/Library/Homebrew/Gemfile +++ b/Library/Homebrew/Gemfile @@ -13,6 +13,8 @@ gem "rspec-retry", require: false gem "rspec-wait", require: false gem "rubocop" gem "simplecov", require: false +gem "sorbet" +gem "sorbet-runtime" # vendored gems gem "activesupport" diff --git a/Library/Homebrew/Gemfile.lock b/Library/Homebrew/Gemfile.lock index 420e9940c4..ee286d7b5e 100644 --- a/Library/Homebrew/Gemfile.lock +++ b/Library/Homebrew/Gemfile.lock @@ -104,6 +104,10 @@ GEM json (>= 1.8, < 3) simplecov-html (~> 0.10.0) simplecov-html (0.10.2) + sorbet (0.5.5742) + sorbet-static (= 0.5.5742) + sorbet-runtime (0.5.5742) + sorbet-static (0.5.5742-universal-darwin-14) sync (0.5.0) term-ansicolor (1.7.1) tins (~> 1.0) @@ -141,6 +145,8 @@ DEPENDENCIES rubocop-rspec ruby-macho simplecov + sorbet + sorbet-runtime BUNDLED WITH 1.17.2 diff --git a/Library/Homebrew/vendor/bundle/bundler/setup.rb b/Library/Homebrew/vendor/bundle/bundler/setup.rb index 3c4002ea48..16705b7f79 100644 --- a/Library/Homebrew/vendor/bundle/bundler/setup.rb +++ b/Library/Homebrew/vendor/bundle/bundler/setup.rb @@ -20,6 +20,8 @@ $:.unshift "#{path}/../#{ruby_engine}/#{ruby_version}/gems/json-2.3.0/lib" $:.unshift "#{path}/../#{ruby_engine}/#{ruby_version}/gems/docile-1.3.2/lib" $:.unshift "#{path}/../#{ruby_engine}/#{ruby_version}/gems/simplecov-html-0.10.2/lib" $:.unshift "#{path}/../#{ruby_engine}/#{ruby_version}/gems/simplecov-0.16.1/lib" +$:.unshift "#{path}/../#{ruby_engine}/#{ruby_version}/gems/sorbet-0.5.5742" +$:.unshift "#{path}/../#{ruby_engine}/#{ruby_version}/gems/sorbet-runtime-0.5.5742/lib" $:.unshift "#{path}/../../../../../../../../Library/Ruby/Gems/2.6.0/gems/sync-0.5.0/lib" $:.unshift "#{path}/../#{ruby_engine}/#{ruby_version}/gems/tins-1.25.0/lib" $:.unshift "#{path}/../#{ruby_engine}/#{ruby_version}/gems/term-ansicolor-1.7.1/lib" From 2b93177237f96238b7ca37a36acd036f568d5bfa Mon Sep 17 00:00:00 2001 From: "dependabot-preview[bot]" <27856297+dependabot-preview[bot]@users.noreply.github.com> Date: Thu, 11 Jun 2020 10:46:54 +0000 Subject: [PATCH 10/25] build(deps): bump rubocop-rspec in /Library/Homebrew Bumps [rubocop-rspec](https://github.com/rubocop-hq/rubocop-rspec) from 1.39.0 to 1.40.0. - [Release notes](https://github.com/rubocop-hq/rubocop-rspec/releases) - [Changelog](https://github.com/rubocop-hq/rubocop-rspec/blob/master/CHANGELOG.md) - [Commits](https://github.com/rubocop-hq/rubocop-rspec/compare/v1.39.0...v1.40.0) Signed-off-by: dependabot-preview[bot] --- Library/Homebrew/Gemfile.lock | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Library/Homebrew/Gemfile.lock b/Library/Homebrew/Gemfile.lock index e2f74fb37b..ab77ab5f47 100644 --- a/Library/Homebrew/Gemfile.lock +++ b/Library/Homebrew/Gemfile.lock @@ -95,7 +95,7 @@ GEM parser (>= 2.7.0.1) rubocop-performance (1.6.1) rubocop (>= 0.71.0) - rubocop-rspec (1.39.0) + rubocop-rspec (1.40.0) rubocop (>= 0.68.1) ruby-macho (2.2.0) ruby-progressbar (1.10.1) From 5ef55d9637499178f03dbc7604934d2cc95c453d Mon Sep 17 00:00:00 2001 From: vidusheeamoli Date: Thu, 11 Jun 2020 16:46:05 +0530 Subject: [PATCH 11/25] homebrew-sorbet env --- Library/Homebrew/Gemfile | 6 ++++-- Library/Homebrew/Gemfile.lock | 6 ------ Library/Homebrew/vendor/bundle/bundler/setup.rb | 2 -- 3 files changed, 4 insertions(+), 10 deletions(-) diff --git a/Library/Homebrew/Gemfile b/Library/Homebrew/Gemfile index 77afd2fa27..7335e0ffc4 100644 --- a/Library/Homebrew/Gemfile +++ b/Library/Homebrew/Gemfile @@ -13,8 +13,10 @@ gem "rspec-retry", require: false gem "rspec-wait", require: false gem "rubocop" gem "simplecov", require: false -gem "sorbet" -gem "sorbet-runtime" +if ENV["HOMEBREW_SORBET"] + gem "sorbet" + gem "sorbet-runtime" +end # vendored gems gem "activesupport" diff --git a/Library/Homebrew/Gemfile.lock b/Library/Homebrew/Gemfile.lock index ee286d7b5e..420e9940c4 100644 --- a/Library/Homebrew/Gemfile.lock +++ b/Library/Homebrew/Gemfile.lock @@ -104,10 +104,6 @@ GEM json (>= 1.8, < 3) simplecov-html (~> 0.10.0) simplecov-html (0.10.2) - sorbet (0.5.5742) - sorbet-static (= 0.5.5742) - sorbet-runtime (0.5.5742) - sorbet-static (0.5.5742-universal-darwin-14) sync (0.5.0) term-ansicolor (1.7.1) tins (~> 1.0) @@ -145,8 +141,6 @@ DEPENDENCIES rubocop-rspec ruby-macho simplecov - sorbet - sorbet-runtime BUNDLED WITH 1.17.2 diff --git a/Library/Homebrew/vendor/bundle/bundler/setup.rb b/Library/Homebrew/vendor/bundle/bundler/setup.rb index 16705b7f79..3c4002ea48 100644 --- a/Library/Homebrew/vendor/bundle/bundler/setup.rb +++ b/Library/Homebrew/vendor/bundle/bundler/setup.rb @@ -20,8 +20,6 @@ $:.unshift "#{path}/../#{ruby_engine}/#{ruby_version}/gems/json-2.3.0/lib" $:.unshift "#{path}/../#{ruby_engine}/#{ruby_version}/gems/docile-1.3.2/lib" $:.unshift "#{path}/../#{ruby_engine}/#{ruby_version}/gems/simplecov-html-0.10.2/lib" $:.unshift "#{path}/../#{ruby_engine}/#{ruby_version}/gems/simplecov-0.16.1/lib" -$:.unshift "#{path}/../#{ruby_engine}/#{ruby_version}/gems/sorbet-0.5.5742" -$:.unshift "#{path}/../#{ruby_engine}/#{ruby_version}/gems/sorbet-runtime-0.5.5742/lib" $:.unshift "#{path}/../../../../../../../../Library/Ruby/Gems/2.6.0/gems/sync-0.5.0/lib" $:.unshift "#{path}/../#{ruby_engine}/#{ruby_version}/gems/tins-1.25.0/lib" $:.unshift "#{path}/../#{ruby_engine}/#{ruby_version}/gems/term-ansicolor-1.7.1/lib" From 390c3e269fe198d0fcbeec031140728d585f58ef Mon Sep 17 00:00:00 2001 From: Mike McQuaid Date: Thu, 11 Jun 2020 12:57:57 +0100 Subject: [PATCH 12/25] brew vendor-gems: commit updates. --- .../Homebrew/vendor/bundle/bundler/setup.rb | 10 +- .../config/default.yml | 154 ++++++++++++++++-- .../lib/rubocop-rspec.rb | 1 + .../rubocop/cop/rspec/align_left_let_brace.rb | 0 .../cop/rspec/align_right_let_brace.rb | 0 .../lib/rubocop/cop/rspec/any_instance.rb | 0 .../lib/rubocop/cop/rspec/around_block.rb | 0 .../lib/rubocop/cop/rspec/be.rb | 0 .../lib/rubocop/cop/rspec/be_eql.rb | 0 .../lib/rubocop/cop/rspec/before_after_all.rb | 0 .../capybara/current_path_expectation.rb | 0 .../cop/rspec/capybara/feature_methods.rb | 0 .../cop/rspec/capybara/visibility_matcher.rb | 37 +++-- .../lib/rubocop/cop/rspec/context_method.rb | 0 .../lib/rubocop/cop/rspec/context_wording.rb | 0 .../lib/rubocop/cop/rspec/cop.rb | 36 +--- .../lib/rubocop/cop/rspec/describe_class.rb | 0 .../lib/rubocop/cop/rspec/describe_method.rb | 0 .../lib/rubocop/cop/rspec/describe_symbol.rb | 0 .../lib/rubocop/cop/rspec/described_class.rb | 0 .../rspec/described_class_module_wrapping.rb | 0 .../lib/rubocop/cop/rspec/dialect.rb | 0 .../rubocop/cop/rspec/empty_example_group.rb | 0 .../lib/rubocop/cop/rspec/empty_hook.rb | 0 .../cop/rspec/empty_line_after_example.rb | 0 .../rspec/empty_line_after_example_group.rb | 0 .../cop/rspec/empty_line_after_final_let.rb | 0 .../cop/rspec/empty_line_after_hook.rb | 0 .../cop/rspec/empty_line_after_subject.rb | 0 .../lib/rubocop/cop/rspec/example_length.rb | 0 .../cop/rspec/example_without_description.rb | 0 .../lib/rubocop/cop/rspec/example_wording.rb | 0 .../lib/rubocop/cop/rspec/expect_actual.rb | 0 .../lib/rubocop/cop/rspec/expect_change.rb | 0 .../lib/rubocop/cop/rspec/expect_in_hook.rb | 0 .../lib/rubocop/cop/rspec/expect_output.rb | 0 .../attribute_defined_statically.rb | 0 .../cop/rspec/factory_bot/create_list.rb | 0 .../rspec/factory_bot/factory_class_name.rb | 0 .../lib/rubocop/cop/rspec/file_path.rb | 32 +++- .../lib/rubocop/cop/rspec/focus.rb | 0 .../lib/rubocop/cop/rspec/hook_argument.rb | 0 .../cop/rspec/hooks_before_examples.rb | 0 .../cop/rspec/implicit_block_expectation.rb | 0 .../lib/rubocop/cop/rspec/implicit_expect.rb | 0 .../lib/rubocop/cop/rspec/implicit_subject.rb | 0 .../lib/rubocop/cop/rspec/instance_spy.rb | 0 .../rubocop/cop/rspec/instance_variable.rb | 0 .../cop/rspec/invalid_predicate_matcher.rb | 0 .../lib/rubocop/cop/rspec/it_behaves_like.rb | 0 .../rubocop/cop/rspec/iterated_expectation.rb | 0 .../lib/rubocop/cop/rspec/leading_subject.rb | 0 .../cop/rspec/leaky_constant_declaration.rb | 0 .../rubocop/cop/rspec/let_before_examples.rb | 0 .../lib/rubocop/cop/rspec/let_setup.rb | 0 .../lib/rubocop/cop/rspec/message_chain.rb | 0 .../rubocop/cop/rspec/message_expectation.rb | 0 .../lib/rubocop/cop/rspec/message_spies.rb | 0 .../rspec/missing_example_group_argument.rb | 0 .../rubocop/cop/rspec/multiple_describes.rb | 0 .../cop/rspec/multiple_expectations.rb | 0 .../rubocop/cop/rspec/multiple_subjects.rb | 0 .../lib/rubocop/cop/rspec/named_subject.rb | 0 .../lib/rubocop/cop/rspec/nested_groups.rb | 0 .../lib/rubocop/cop/rspec/not_to_not.rb | 0 .../rubocop/cop/rspec/overwriting_setup.rb | 0 .../lib/rubocop/cop/rspec/pending.rb | 0 .../rubocop/cop/rspec/predicate_matcher.rb | 0 .../rubocop/cop/rspec/rails/http_status.rb | 2 + .../lib/rubocop/cop/rspec/receive_counts.rb | 0 .../lib/rubocop/cop/rspec/receive_never.rb | 0 .../rubocop/cop/rspec/repeated_description.rb | 0 .../lib/rubocop/cop/rspec/repeated_example.rb | 0 .../cop/rspec/repeated_example_group_body.rb | 12 +- .../repeated_example_group_description.rb | 0 .../lib/rubocop/cop/rspec/return_from_stub.rb | 0 .../lib/rubocop/cop/rspec/scattered_let.rb | 0 .../lib/rubocop/cop/rspec/scattered_setup.rb | 0 .../lib/rubocop/cop/rspec/shared_context.rb | 0 .../lib/rubocop/cop/rspec/shared_examples.rb | 1 + .../rspec/single_argument_message_chain.rb | 0 .../lib/rubocop/cop/rspec/subject_stub.rb | 78 ++++----- .../cop/rspec/unspecified_exception.rb | 0 .../rubocop/cop/rspec/variable_definition.rb | 56 +++++++ .../lib/rubocop/cop/rspec/variable_name.rb | 47 ++++++ .../lib/rubocop/cop/rspec/verified_doubles.rb | 0 .../lib/rubocop/cop/rspec/void_expect.rb | 0 .../lib/rubocop/cop/rspec/yield.rb | 0 .../lib/rubocop/cop/rspec_cops.rb | 2 + .../lib/rubocop/rspec.rb | 0 .../lib/rubocop/rspec/align_let_brace.rb | 0 .../rubocop/rspec/blank_line_separation.rb | 0 .../lib/rubocop/rspec/concept.rb | 0 .../lib/rubocop/rspec/config_formatter.rb | 0 .../lib/rubocop/rspec/corrector/move_node.rb | 0 .../rubocop/rspec/description_extractor.rb | 8 +- .../lib/rubocop/rspec/example.rb | 0 .../lib/rubocop/rspec/example_group.rb | 0 .../lib/rubocop/rspec/factory_bot.rb | 0 .../lib/rubocop/rspec/final_end_location.rb | 0 .../lib/rubocop/rspec/hook.rb | 0 .../lib/rubocop/rspec/inject.rb | 0 .../lib/rubocop/rspec/language.rb | 0 .../rubocop/rspec/language/node_pattern.rb | 0 .../lib/rubocop/rspec/node.rb | 0 .../lib/rubocop/rspec/top_level_describe.rb | 0 .../lib/rubocop/rspec/variable.rb | 16 ++ .../lib/rubocop/rspec/version.rb | 2 +- .../lib/rubocop/rspec/wording.rb | 0 109 files changed, 371 insertions(+), 123 deletions(-) rename Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/{rubocop-rspec-1.39.0 => rubocop-rspec-1.40.0}/config/default.yml (86%) rename Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/{rubocop-rspec-1.39.0 => rubocop-rspec-1.40.0}/lib/rubocop-rspec.rb (97%) rename Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/{rubocop-rspec-1.39.0 => rubocop-rspec-1.40.0}/lib/rubocop/cop/rspec/align_left_let_brace.rb (100%) rename Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/{rubocop-rspec-1.39.0 => rubocop-rspec-1.40.0}/lib/rubocop/cop/rspec/align_right_let_brace.rb (100%) rename Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/{rubocop-rspec-1.39.0 => rubocop-rspec-1.40.0}/lib/rubocop/cop/rspec/any_instance.rb (100%) rename Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/{rubocop-rspec-1.39.0 => rubocop-rspec-1.40.0}/lib/rubocop/cop/rspec/around_block.rb (100%) rename Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/{rubocop-rspec-1.39.0 => rubocop-rspec-1.40.0}/lib/rubocop/cop/rspec/be.rb (100%) rename Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/{rubocop-rspec-1.39.0 => rubocop-rspec-1.40.0}/lib/rubocop/cop/rspec/be_eql.rb (100%) rename Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/{rubocop-rspec-1.39.0 => rubocop-rspec-1.40.0}/lib/rubocop/cop/rspec/before_after_all.rb (100%) rename Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/{rubocop-rspec-1.39.0 => rubocop-rspec-1.40.0}/lib/rubocop/cop/rspec/capybara/current_path_expectation.rb (100%) rename Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/{rubocop-rspec-1.39.0 => rubocop-rspec-1.40.0}/lib/rubocop/cop/rspec/capybara/feature_methods.rb (100%) rename Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/{rubocop-rspec-1.39.0 => rubocop-rspec-1.40.0}/lib/rubocop/cop/rspec/capybara/visibility_matcher.rb (61%) rename Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/{rubocop-rspec-1.39.0 => rubocop-rspec-1.40.0}/lib/rubocop/cop/rspec/context_method.rb (100%) rename Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/{rubocop-rspec-1.39.0 => rubocop-rspec-1.40.0}/lib/rubocop/cop/rspec/context_wording.rb (100%) rename Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/{rubocop-rspec-1.39.0 => rubocop-rspec-1.40.0}/lib/rubocop/cop/rspec/cop.rb (68%) rename Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/{rubocop-rspec-1.39.0 => rubocop-rspec-1.40.0}/lib/rubocop/cop/rspec/describe_class.rb (100%) rename Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/{rubocop-rspec-1.39.0 => rubocop-rspec-1.40.0}/lib/rubocop/cop/rspec/describe_method.rb (100%) rename Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/{rubocop-rspec-1.39.0 => rubocop-rspec-1.40.0}/lib/rubocop/cop/rspec/describe_symbol.rb (100%) rename Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/{rubocop-rspec-1.39.0 => rubocop-rspec-1.40.0}/lib/rubocop/cop/rspec/described_class.rb (100%) rename Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/{rubocop-rspec-1.39.0 => rubocop-rspec-1.40.0}/lib/rubocop/cop/rspec/described_class_module_wrapping.rb (100%) rename Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/{rubocop-rspec-1.39.0 => rubocop-rspec-1.40.0}/lib/rubocop/cop/rspec/dialect.rb (100%) rename Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/{rubocop-rspec-1.39.0 => rubocop-rspec-1.40.0}/lib/rubocop/cop/rspec/empty_example_group.rb (100%) rename Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/{rubocop-rspec-1.39.0 => rubocop-rspec-1.40.0}/lib/rubocop/cop/rspec/empty_hook.rb (100%) rename Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/{rubocop-rspec-1.39.0 => rubocop-rspec-1.40.0}/lib/rubocop/cop/rspec/empty_line_after_example.rb (100%) rename Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/{rubocop-rspec-1.39.0 => rubocop-rspec-1.40.0}/lib/rubocop/cop/rspec/empty_line_after_example_group.rb (100%) rename Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/{rubocop-rspec-1.39.0 => rubocop-rspec-1.40.0}/lib/rubocop/cop/rspec/empty_line_after_final_let.rb (100%) rename Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/{rubocop-rspec-1.39.0 => rubocop-rspec-1.40.0}/lib/rubocop/cop/rspec/empty_line_after_hook.rb (100%) rename Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/{rubocop-rspec-1.39.0 => rubocop-rspec-1.40.0}/lib/rubocop/cop/rspec/empty_line_after_subject.rb (100%) rename Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/{rubocop-rspec-1.39.0 => rubocop-rspec-1.40.0}/lib/rubocop/cop/rspec/example_length.rb (100%) rename Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/{rubocop-rspec-1.39.0 => rubocop-rspec-1.40.0}/lib/rubocop/cop/rspec/example_without_description.rb (100%) rename Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/{rubocop-rspec-1.39.0 => rubocop-rspec-1.40.0}/lib/rubocop/cop/rspec/example_wording.rb (100%) rename Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/{rubocop-rspec-1.39.0 => rubocop-rspec-1.40.0}/lib/rubocop/cop/rspec/expect_actual.rb (100%) rename Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/{rubocop-rspec-1.39.0 => rubocop-rspec-1.40.0}/lib/rubocop/cop/rspec/expect_change.rb (100%) rename Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/{rubocop-rspec-1.39.0 => rubocop-rspec-1.40.0}/lib/rubocop/cop/rspec/expect_in_hook.rb (100%) rename Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/{rubocop-rspec-1.39.0 => rubocop-rspec-1.40.0}/lib/rubocop/cop/rspec/expect_output.rb (100%) rename Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/{rubocop-rspec-1.39.0 => rubocop-rspec-1.40.0}/lib/rubocop/cop/rspec/factory_bot/attribute_defined_statically.rb (100%) rename Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/{rubocop-rspec-1.39.0 => rubocop-rspec-1.40.0}/lib/rubocop/cop/rspec/factory_bot/create_list.rb (100%) rename Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/{rubocop-rspec-1.39.0 => rubocop-rspec-1.40.0}/lib/rubocop/cop/rspec/factory_bot/factory_class_name.rb (100%) rename Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/{rubocop-rspec-1.39.0 => rubocop-rspec-1.40.0}/lib/rubocop/cop/rspec/file_path.rb (74%) rename Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/{rubocop-rspec-1.39.0 => rubocop-rspec-1.40.0}/lib/rubocop/cop/rspec/focus.rb (100%) rename Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/{rubocop-rspec-1.39.0 => rubocop-rspec-1.40.0}/lib/rubocop/cop/rspec/hook_argument.rb (100%) rename Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/{rubocop-rspec-1.39.0 => rubocop-rspec-1.40.0}/lib/rubocop/cop/rspec/hooks_before_examples.rb (100%) rename Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/{rubocop-rspec-1.39.0 => rubocop-rspec-1.40.0}/lib/rubocop/cop/rspec/implicit_block_expectation.rb (100%) rename Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/{rubocop-rspec-1.39.0 => rubocop-rspec-1.40.0}/lib/rubocop/cop/rspec/implicit_expect.rb (100%) rename Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/{rubocop-rspec-1.39.0 => rubocop-rspec-1.40.0}/lib/rubocop/cop/rspec/implicit_subject.rb (100%) rename Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/{rubocop-rspec-1.39.0 => rubocop-rspec-1.40.0}/lib/rubocop/cop/rspec/instance_spy.rb (100%) rename Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/{rubocop-rspec-1.39.0 => rubocop-rspec-1.40.0}/lib/rubocop/cop/rspec/instance_variable.rb (100%) rename Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/{rubocop-rspec-1.39.0 => rubocop-rspec-1.40.0}/lib/rubocop/cop/rspec/invalid_predicate_matcher.rb (100%) rename Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/{rubocop-rspec-1.39.0 => rubocop-rspec-1.40.0}/lib/rubocop/cop/rspec/it_behaves_like.rb (100%) rename Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/{rubocop-rspec-1.39.0 => rubocop-rspec-1.40.0}/lib/rubocop/cop/rspec/iterated_expectation.rb (100%) rename Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/{rubocop-rspec-1.39.0 => rubocop-rspec-1.40.0}/lib/rubocop/cop/rspec/leading_subject.rb (100%) rename Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/{rubocop-rspec-1.39.0 => rubocop-rspec-1.40.0}/lib/rubocop/cop/rspec/leaky_constant_declaration.rb (100%) rename Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/{rubocop-rspec-1.39.0 => rubocop-rspec-1.40.0}/lib/rubocop/cop/rspec/let_before_examples.rb (100%) rename Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/{rubocop-rspec-1.39.0 => rubocop-rspec-1.40.0}/lib/rubocop/cop/rspec/let_setup.rb (100%) rename Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/{rubocop-rspec-1.39.0 => rubocop-rspec-1.40.0}/lib/rubocop/cop/rspec/message_chain.rb (100%) rename Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/{rubocop-rspec-1.39.0 => rubocop-rspec-1.40.0}/lib/rubocop/cop/rspec/message_expectation.rb (100%) rename Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/{rubocop-rspec-1.39.0 => rubocop-rspec-1.40.0}/lib/rubocop/cop/rspec/message_spies.rb (100%) rename Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/{rubocop-rspec-1.39.0 => rubocop-rspec-1.40.0}/lib/rubocop/cop/rspec/missing_example_group_argument.rb (100%) rename Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/{rubocop-rspec-1.39.0 => rubocop-rspec-1.40.0}/lib/rubocop/cop/rspec/multiple_describes.rb (100%) rename Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/{rubocop-rspec-1.39.0 => rubocop-rspec-1.40.0}/lib/rubocop/cop/rspec/multiple_expectations.rb (100%) rename Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/{rubocop-rspec-1.39.0 => rubocop-rspec-1.40.0}/lib/rubocop/cop/rspec/multiple_subjects.rb (100%) rename Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/{rubocop-rspec-1.39.0 => rubocop-rspec-1.40.0}/lib/rubocop/cop/rspec/named_subject.rb (100%) rename Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/{rubocop-rspec-1.39.0 => rubocop-rspec-1.40.0}/lib/rubocop/cop/rspec/nested_groups.rb (100%) rename Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/{rubocop-rspec-1.39.0 => rubocop-rspec-1.40.0}/lib/rubocop/cop/rspec/not_to_not.rb (100%) rename Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/{rubocop-rspec-1.39.0 => rubocop-rspec-1.40.0}/lib/rubocop/cop/rspec/overwriting_setup.rb (100%) rename Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/{rubocop-rspec-1.39.0 => rubocop-rspec-1.40.0}/lib/rubocop/cop/rspec/pending.rb (100%) rename Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/{rubocop-rspec-1.39.0 => rubocop-rspec-1.40.0}/lib/rubocop/cop/rspec/predicate_matcher.rb (100%) rename Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/{rubocop-rspec-1.39.0 => rubocop-rspec-1.40.0}/lib/rubocop/cop/rspec/rails/http_status.rb (99%) rename Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/{rubocop-rspec-1.39.0 => rubocop-rspec-1.40.0}/lib/rubocop/cop/rspec/receive_counts.rb (100%) rename Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/{rubocop-rspec-1.39.0 => rubocop-rspec-1.40.0}/lib/rubocop/cop/rspec/receive_never.rb (100%) rename Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/{rubocop-rspec-1.39.0 => rubocop-rspec-1.40.0}/lib/rubocop/cop/rspec/repeated_description.rb (100%) rename Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/{rubocop-rspec-1.39.0 => rubocop-rspec-1.40.0}/lib/rubocop/cop/rspec/repeated_example.rb (100%) rename Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/{rubocop-rspec-1.39.0 => rubocop-rspec-1.40.0}/lib/rubocop/cop/rspec/repeated_example_group_body.rb (86%) rename Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/{rubocop-rspec-1.39.0 => rubocop-rspec-1.40.0}/lib/rubocop/cop/rspec/repeated_example_group_description.rb (100%) rename Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/{rubocop-rspec-1.39.0 => rubocop-rspec-1.40.0}/lib/rubocop/cop/rspec/return_from_stub.rb (100%) rename Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/{rubocop-rspec-1.39.0 => rubocop-rspec-1.40.0}/lib/rubocop/cop/rspec/scattered_let.rb (100%) rename Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/{rubocop-rspec-1.39.0 => rubocop-rspec-1.40.0}/lib/rubocop/cop/rspec/scattered_setup.rb (100%) rename Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/{rubocop-rspec-1.39.0 => rubocop-rspec-1.40.0}/lib/rubocop/cop/rspec/shared_context.rb (100%) rename Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/{rubocop-rspec-1.39.0 => rubocop-rspec-1.40.0}/lib/rubocop/cop/rspec/shared_examples.rb (99%) rename Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/{rubocop-rspec-1.39.0 => rubocop-rspec-1.40.0}/lib/rubocop/cop/rspec/single_argument_message_chain.rb (100%) rename Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/{rubocop-rspec-1.39.0 => rubocop-rspec-1.40.0}/lib/rubocop/cop/rspec/subject_stub.rb (57%) rename Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/{rubocop-rspec-1.39.0 => rubocop-rspec-1.40.0}/lib/rubocop/cop/rspec/unspecified_exception.rb (100%) create mode 100644 Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.40.0/lib/rubocop/cop/rspec/variable_definition.rb create mode 100644 Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.40.0/lib/rubocop/cop/rspec/variable_name.rb rename Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/{rubocop-rspec-1.39.0 => rubocop-rspec-1.40.0}/lib/rubocop/cop/rspec/verified_doubles.rb (100%) rename Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/{rubocop-rspec-1.39.0 => rubocop-rspec-1.40.0}/lib/rubocop/cop/rspec/void_expect.rb (100%) rename Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/{rubocop-rspec-1.39.0 => rubocop-rspec-1.40.0}/lib/rubocop/cop/rspec/yield.rb (100%) rename Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/{rubocop-rspec-1.39.0 => rubocop-rspec-1.40.0}/lib/rubocop/cop/rspec_cops.rb (97%) rename Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/{rubocop-rspec-1.39.0 => rubocop-rspec-1.40.0}/lib/rubocop/rspec.rb (100%) rename Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/{rubocop-rspec-1.39.0 => rubocop-rspec-1.40.0}/lib/rubocop/rspec/align_let_brace.rb (100%) rename Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/{rubocop-rspec-1.39.0 => rubocop-rspec-1.40.0}/lib/rubocop/rspec/blank_line_separation.rb (100%) rename Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/{rubocop-rspec-1.39.0 => rubocop-rspec-1.40.0}/lib/rubocop/rspec/concept.rb (100%) rename Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/{rubocop-rspec-1.39.0 => rubocop-rspec-1.40.0}/lib/rubocop/rspec/config_formatter.rb (100%) rename Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/{rubocop-rspec-1.39.0 => rubocop-rspec-1.40.0}/lib/rubocop/rspec/corrector/move_node.rb (100%) rename Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/{rubocop-rspec-1.39.0 => rubocop-rspec-1.40.0}/lib/rubocop/rspec/description_extractor.rb (80%) rename Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/{rubocop-rspec-1.39.0 => rubocop-rspec-1.40.0}/lib/rubocop/rspec/example.rb (100%) rename Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/{rubocop-rspec-1.39.0 => rubocop-rspec-1.40.0}/lib/rubocop/rspec/example_group.rb (100%) rename Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/{rubocop-rspec-1.39.0 => rubocop-rspec-1.40.0}/lib/rubocop/rspec/factory_bot.rb (100%) rename Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/{rubocop-rspec-1.39.0 => rubocop-rspec-1.40.0}/lib/rubocop/rspec/final_end_location.rb (100%) rename Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/{rubocop-rspec-1.39.0 => rubocop-rspec-1.40.0}/lib/rubocop/rspec/hook.rb (100%) rename Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/{rubocop-rspec-1.39.0 => rubocop-rspec-1.40.0}/lib/rubocop/rspec/inject.rb (100%) rename Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/{rubocop-rspec-1.39.0 => rubocop-rspec-1.40.0}/lib/rubocop/rspec/language.rb (100%) rename Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/{rubocop-rspec-1.39.0 => rubocop-rspec-1.40.0}/lib/rubocop/rspec/language/node_pattern.rb (100%) rename Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/{rubocop-rspec-1.39.0 => rubocop-rspec-1.40.0}/lib/rubocop/rspec/node.rb (100%) rename Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/{rubocop-rspec-1.39.0 => rubocop-rspec-1.40.0}/lib/rubocop/rspec/top_level_describe.rb (100%) create mode 100644 Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.40.0/lib/rubocop/rspec/variable.rb rename Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/{rubocop-rspec-1.39.0 => rubocop-rspec-1.40.0}/lib/rubocop/rspec/version.rb (86%) rename Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/{rubocop-rspec-1.39.0 => rubocop-rspec-1.40.0}/lib/rubocop/rspec/wording.rb (100%) diff --git a/Library/Homebrew/vendor/bundle/bundler/setup.rb b/Library/Homebrew/vendor/bundle/bundler/setup.rb index 3c4002ea48..d027866a4d 100644 --- a/Library/Homebrew/vendor/bundle/bundler/setup.rb +++ b/Library/Homebrew/vendor/bundle/bundler/setup.rb @@ -10,7 +10,7 @@ $:.unshift "#{path}/../#{ruby_engine}/#{ruby_version}/gems/thread_safe-0.3.6/lib $:.unshift "#{path}/../#{ruby_engine}/#{ruby_version}/gems/tzinfo-1.2.7/lib" $:.unshift "#{path}/../#{ruby_engine}/#{ruby_version}/gems/zeitwerk-2.3.0/lib" $:.unshift "#{path}/../#{ruby_engine}/#{ruby_version}/gems/activesupport-6.0.3.1/lib" -$:.unshift "#{path}/../#{ruby_engine}/#{ruby_version}/gems/ast-2.4.0/lib" +$:.unshift "#{path}/../#{ruby_engine}/#{ruby_version}/gems/ast-2.4.1/lib" $:.unshift "#{path}/" $:.unshift "#{path}/../#{ruby_engine}/#{ruby_version}/extensions/universal-darwin-19/2.6.0/byebug-11.1.3" $:.unshift "#{path}/../#{ruby_engine}/#{ruby_version}/gems/byebug-11.1.3/lib" @@ -45,13 +45,13 @@ $:.unshift "#{path}/../#{ruby_engine}/#{ruby_version}/gems/webrobots-0.1.2/lib" $:.unshift "#{path}/../#{ruby_engine}/#{ruby_version}/gems/mechanize-2.7.6/lib" $:.unshift "#{path}/../#{ruby_engine}/#{ruby_version}/gems/mustache-1.1.1/lib" $:.unshift "#{path}/../#{ruby_engine}/#{ruby_version}/gems/parallel-1.19.1/lib" -$:.unshift "#{path}/../#{ruby_engine}/#{ruby_version}/gems/parallel_tests-2.32.0/lib" +$:.unshift "#{path}/../#{ruby_engine}/#{ruby_version}/gems/parallel_tests-3.0.0/lib" $:.unshift "#{path}/../#{ruby_engine}/#{ruby_version}/gems/parser-2.7.1.3/lib" $:.unshift "#{path}/../#{ruby_engine}/#{ruby_version}/gems/plist-3.5.0/lib" $:.unshift "#{path}/../#{ruby_engine}/#{ruby_version}/gems/rainbow-3.0.0/lib" $:.unshift "#{path}/../#{ruby_engine}/#{ruby_version}/extensions/universal-darwin-19/2.6.0/rdiscount-2.2.0.1" $:.unshift "#{path}/../#{ruby_engine}/#{ruby_version}/gems/rdiscount-2.2.0.1/lib" -$:.unshift "#{path}/../#{ruby_engine}/#{ruby_version}/gems/regexp_parser-1.7.0/lib" +$:.unshift "#{path}/../#{ruby_engine}/#{ruby_version}/gems/regexp_parser-1.7.1/lib" $:.unshift "#{path}/../#{ruby_engine}/#{ruby_version}/gems/rexml-3.2.4/lib" $:.unshift "#{path}/../#{ruby_engine}/#{ruby_version}/gems/ronn-0.7.3/lib" $:.unshift "#{path}/../#{ruby_engine}/#{ruby_version}/gems/rspec-support-3.9.3/lib" @@ -65,7 +65,7 @@ $:.unshift "#{path}/../#{ruby_engine}/#{ruby_version}/gems/rspec-wait-0.0.9/lib" $:.unshift "#{path}/../#{ruby_engine}/#{ruby_version}/gems/rubocop-ast-0.0.3/lib" $:.unshift "#{path}/../#{ruby_engine}/#{ruby_version}/gems/ruby-progressbar-1.10.1/lib" $:.unshift "#{path}/../#{ruby_engine}/#{ruby_version}/gems/unicode-display_width-1.7.0/lib" -$:.unshift "#{path}/../#{ruby_engine}/#{ruby_version}/gems/rubocop-0.85.0/lib" +$:.unshift "#{path}/../#{ruby_engine}/#{ruby_version}/gems/rubocop-0.85.1/lib" $:.unshift "#{path}/../#{ruby_engine}/#{ruby_version}/gems/rubocop-performance-1.6.1/lib" -$:.unshift "#{path}/../#{ruby_engine}/#{ruby_version}/gems/rubocop-rspec-1.39.0/lib" +$:.unshift "#{path}/../#{ruby_engine}/#{ruby_version}/gems/rubocop-rspec-1.40.0/lib" $:.unshift "#{path}/../#{ruby_engine}/#{ruby_version}/gems/ruby-macho-2.2.0/lib" diff --git a/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.39.0/config/default.yml b/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.40.0/config/default.yml similarity index 86% rename from Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.39.0/config/default.yml rename to Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.40.0/config/default.yml index 566d5bd56f..bd689553f5 100644 --- a/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.39.0/config/default.yml +++ b/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.40.0/config/default.yml @@ -13,31 +13,37 @@ AllCops: RSpec/AlignLeftLetBrace: Description: Checks that left braces for adjacent single line lets are aligned. Enabled: false + VersionAdded: '1.16' StyleGuide: https://www.rubydoc.info/gems/rubocop-rspec/RuboCop/Cop/RSpec/AlignLeftLetBrace RSpec/AlignRightLetBrace: Description: Checks that right braces for adjacent single line lets are aligned. Enabled: false + VersionAdded: '1.16' StyleGuide: https://www.rubydoc.info/gems/rubocop-rspec/RuboCop/Cop/RSpec/AlignRightLetBrace RSpec/AnyInstance: Description: Check that instances are not being stubbed globally. Enabled: true + VersionAdded: '1.4' StyleGuide: https://www.rubydoc.info/gems/rubocop-rspec/RuboCop/Cop/RSpec/AnyInstance RSpec/AroundBlock: Description: Checks that around blocks actually run the test. Enabled: true + VersionAdded: '1.11' StyleGuide: https://www.rubydoc.info/gems/rubocop-rspec/RuboCop/Cop/RSpec/AroundBlock RSpec/Be: Description: Check for expectations where `be` is used without argument. Enabled: true + VersionAdded: '1.25' StyleGuide: https://www.rubydoc.info/gems/rubocop-rspec/RuboCop/Cop/RSpec/Be RSpec/BeEql: Description: Check for expectations where `be(...)` can replace `eql(...)`. Enabled: true + VersionAdded: '1.7' StyleGuide: https://www.rubydoc.info/gems/rubocop-rspec/RuboCop/Cop/RSpec/BeEql RSpec/BeforeAfterAll: @@ -47,11 +53,13 @@ RSpec/BeforeAfterAll: - spec/spec_helper.rb - spec/rails_helper.rb - spec/support/**/*.rb + VersionAdded: '1.12' StyleGuide: https://www.rubydoc.info/gems/rubocop-rspec/RuboCop/Cop/RSpec/BeforeAfterAll RSpec/ContextMethod: Description: "`context` should not be used for specifying methods." Enabled: true + VersionAdded: '1.36' StyleGuide: https://www.rubydoc.info/gems/rubocop-rspec/RuboCop/Cop/RSpec/ContextMethod RSpec/ContextWording: @@ -61,86 +69,103 @@ RSpec/ContextWording: - when - with - without + VersionAdded: '1.20' + VersionChanged: 1.20.1 StyleGuide: https://www.rubydoc.info/gems/rubocop-rspec/RuboCop/Cop/RSpec/ContextWording RSpec/DescribeClass: Description: Check that the first argument to the top level describe is a constant. Enabled: true + VersionAdded: '1.0' StyleGuide: https://www.rubydoc.info/gems/rubocop-rspec/RuboCop/Cop/RSpec/DescribeClass RSpec/DescribeMethod: Description: Checks that the second argument to `describe` specifies a method. Enabled: true + VersionAdded: '1.0' StyleGuide: https://www.rubydoc.info/gems/rubocop-rspec/RuboCop/Cop/RSpec/DescribeMethod RSpec/DescribeSymbol: Description: Avoid describing symbols. Enabled: true + VersionAdded: '1.15' StyleGuide: https://www.rubydoc.info/gems/rubocop-rspec/RuboCop/Cop/RSpec/DescribeSymbol RSpec/DescribedClass: Description: Checks that tests use `described_class`. - SkipBlocks: false Enabled: true + SkipBlocks: false EnforcedStyle: described_class SupportedStyles: - described_class - explicit + SafeAutoCorrect: false + VersionAdded: '1.0' + VersionChanged: '1.11' StyleGuide: https://www.rubydoc.info/gems/rubocop-rspec/RuboCop/Cop/RSpec/DescribedClass RSpec/DescribedClassModuleWrapping: Description: Avoid opening modules and defining specs within them. Enabled: false + VersionAdded: '1.37' StyleGuide: https://www.rubydoc.info/gems/rubocop-rspec/RuboCop/Cop/RSpec/DescribedClassModuleWrapping RSpec/Dialect: Description: This cop enforces custom RSpec dialects. Enabled: false PreferredMethods: {} + VersionAdded: '1.33' StyleGuide: https://www.rubydoc.info/gems/rubocop-rspec/RuboCop/Cop/RSpec/Dialect RSpec/EmptyExampleGroup: Description: Checks if an example group does not include any tests. Enabled: true CustomIncludeMethods: [] + VersionAdded: '1.7' StyleGuide: https://www.rubydoc.info/gems/rubocop-rspec/RuboCop/Cop/RSpec/EmptyExampleGroup RSpec/EmptyHook: Description: Checks for empty before and after hooks. Enabled: true - VersionAdded: 1.39.0 + VersionAdded: '1.39' StyleGuide: https://www.rubydoc.info/gems/rubocop-rspec/RuboCop/Cop/RSpec/EmptyHook RSpec/EmptyLineAfterExample: Description: Checks if there is an empty line after example blocks. Enabled: true AllowConsecutiveOneLiners: true + VersionAdded: '1.36' StyleGuide: https://www.rubydoc.info/gems/rubocop-rspec/RuboCop/Cop/RSpec/EmptyLineAfterExample RSpec/EmptyLineAfterExampleGroup: Description: Checks if there is an empty line after example group blocks. Enabled: true + VersionAdded: '1.27' StyleGuide: https://www.rubydoc.info/gems/rubocop-rspec/RuboCop/Cop/RSpec/EmptyLineAfterExampleGroup RSpec/EmptyLineAfterFinalLet: Description: Checks if there is an empty line after the last let block. Enabled: true + VersionAdded: '1.14' StyleGuide: https://www.rubydoc.info/gems/rubocop-rspec/RuboCop/Cop/RSpec/EmptyLineAfterFinalLet RSpec/EmptyLineAfterHook: Description: Checks if there is an empty line after hook blocks. Enabled: true + VersionAdded: '1.27' StyleGuide: https://www.rubydoc.info/gems/rubocop-rspec/RuboCop/Cop/RSpec/EmptyLineAfterHook RSpec/EmptyLineAfterSubject: Description: Checks if there is an empty line after subject block. Enabled: true + VersionAdded: '1.14' StyleGuide: https://www.rubydoc.info/gems/rubocop-rspec/RuboCop/Cop/RSpec/EmptyLineAfterSubject RSpec/ExampleLength: Description: Checks for long examples. Enabled: true Max: 5 + VersionAdded: '1.5' StyleGuide: https://www.rubydoc.info/gems/rubocop-rspec/RuboCop/Cop/RSpec/ExampleLength RSpec/ExampleWithoutDescription: @@ -151,6 +176,7 @@ RSpec/ExampleWithoutDescription: - always_allow - single_line_only - disallow + VersionAdded: '1.22' StyleGuide: https://www.rubydoc.info/gems/rubocop-rspec/RuboCop/Cop/RSpec/ExampleWithoutDescription RSpec/ExampleWording: @@ -162,6 +188,8 @@ RSpec/ExampleWording: have: has HAVE: HAS IgnoredWords: [] + VersionAdded: '1.0' + VersionChanged: '1.2' StyleGuide: https://www.rubydoc.info/gems/rubocop-rspec/RuboCop/Cop/RSpec/ExampleWording RSpec/ExpectActual: @@ -169,6 +197,7 @@ RSpec/ExpectActual: Enabled: true Exclude: - spec/routing/**/* + VersionAdded: '1.7' StyleGuide: https://www.rubydoc.info/gems/rubocop-rspec/RuboCop/Cop/RSpec/ExpectActual RSpec/ExpectChange: @@ -178,30 +207,37 @@ RSpec/ExpectChange: SupportedStyles: - method_call - block + VersionAdded: '1.22' StyleGuide: https://www.rubydoc.info/gems/rubocop-rspec/RuboCop/Cop/RSpec/ExpectChange RSpec/ExpectInHook: - Enabled: true Description: Do not use `expect` in hooks such as `before`. + Enabled: true + VersionAdded: '1.16' StyleGuide: https://www.rubydoc.info/gems/rubocop-rspec/RuboCop/Cop/RSpec/ExpectInHook RSpec/ExpectOutput: Description: Checks for opportunities to use `expect { ... }.to output`. Enabled: true + VersionAdded: '1.10' StyleGuide: https://www.rubydoc.info/gems/rubocop-rspec/RuboCop/Cop/RSpec/ExpectOutput RSpec/FilePath: - Description: Checks that spec file paths are consistent with the test subject. + Description: Checks that spec file paths are consistent and well-formed. Enabled: true CustomTransform: RuboCop: rubocop RSpec: rspec IgnoreMethods: false + SpecSuffixOnly: false + VersionAdded: '1.2' + VersionChanged: '1.40' StyleGuide: https://www.rubydoc.info/gems/rubocop-rspec/RuboCop/Cop/RSpec/FilePath RSpec/Focus: Description: Checks if examples are focused. Enabled: true + VersionAdded: '1.5' StyleGuide: https://www.rubydoc.info/gems/rubocop-rspec/RuboCop/Cop/RSpec/Focus RSpec/HookArgument: @@ -212,16 +248,19 @@ RSpec/HookArgument: - implicit - each - example + VersionAdded: '1.7' StyleGuide: https://www.rubydoc.info/gems/rubocop-rspec/RuboCop/Cop/RSpec/HookArgument RSpec/HooksBeforeExamples: - Enabled: true Description: Checks for before/around/after hooks that come after an example. + Enabled: true + VersionAdded: '1.29' StyleGuide: https://www.rubydoc.info/gems/rubocop-rspec/RuboCop/Cop/RSpec/HooksBeforeExamples RSpec/ImplicitBlockExpectation: Description: Check that implicit block expectation syntax is not used. Enabled: true + VersionAdded: '1.35' StyleGuide: https://www.rubydoc.info/gems/rubocop-rspec/RuboCop/Cop/RSpec/ImplicitBlockExpectation RSpec/ImplicitExpect: @@ -231,32 +270,39 @@ RSpec/ImplicitExpect: SupportedStyles: - is_expected - should + VersionAdded: '1.8' StyleGuide: https://www.rubydoc.info/gems/rubocop-rspec/RuboCop/Cop/RSpec/ImplicitExpect RSpec/ImplicitSubject: - Enabled: true Description: Checks for usage of implicit subject (`is_expected` / `should`). + Enabled: true EnforcedStyle: single_line_only SupportedStyles: - single_line_only - single_statement_only - disallow + VersionAdded: '1.29' + VersionChanged: '1.30' StyleGuide: https://www.rubydoc.info/gems/rubocop-rspec/RuboCop/Cop/RSpec/ImplicitSubject RSpec/InstanceSpy: Description: Checks for `instance_double` used with `have_received`. Enabled: true + VersionAdded: '1.12' StyleGuide: https://www.rubydoc.info/gems/rubocop-rspec/RuboCop/Cop/RSpec/InstanceSpy RSpec/InstanceVariable: Description: Checks for instance variable usage in specs. - AssignmentOnly: false Enabled: true + AssignmentOnly: false + VersionAdded: '1.0' + VersionChanged: '1.7' StyleGuide: https://www.rubydoc.info/gems/rubocop-rspec/RuboCop/Cop/RSpec/InstanceVariable RSpec/InvalidPredicateMatcher: Description: Checks invalid usage for predicate matcher. Enabled: true + VersionAdded: '1.16' StyleGuide: https://www.rubydoc.info/gems/rubocop-rspec/RuboCop/Cop/RSpec/InvalidPredicateMatcher RSpec/ItBehavesLike: @@ -266,36 +312,45 @@ RSpec/ItBehavesLike: SupportedStyles: - it_behaves_like - it_should_behave_like + VersionAdded: '1.13' StyleGuide: https://www.rubydoc.info/gems/rubocop-rspec/RuboCop/Cop/RSpec/ItBehavesLike RSpec/IteratedExpectation: Description: Check that `all` matcher is used instead of iterating over an array. Enabled: true + VersionAdded: '1.14' StyleGuide: https://www.rubydoc.info/gems/rubocop-rspec/RuboCop/Cop/RSpec/IteratedExpectation RSpec/LeadingSubject: Description: Enforce that subject is the first definition in the test. Enabled: true + VersionAdded: '1.7' + VersionChanged: '1.14' StyleGuide: https://www.rubydoc.info/gems/rubocop-rspec/RuboCop/Cop/RSpec/LeadingSubject RSpec/LeakyConstantDeclaration: Description: Checks that no class, module, or constant is declared. Enabled: true + VersionAdded: '1.35' StyleGuide: https://www.rubydoc.info/gems/rubocop-rspec/RuboCop/Cop/RSpec/LeakyConstantDeclaration RSpec/LetBeforeExamples: Description: Checks for `let` definitions that come after an example. Enabled: true + VersionAdded: '1.16' + VersionChanged: '1.22' StyleGuide: https://www.rubydoc.info/gems/rubocop-rspec/RuboCop/Cop/RSpec/LetBeforeExamples RSpec/LetSetup: Description: Checks unreferenced `let!` calls being used for test setup. Enabled: true + VersionAdded: '1.7' StyleGuide: https://www.rubydoc.info/gems/rubocop-rspec/RuboCop/Cop/RSpec/LetSetup RSpec/MessageChain: Description: Check that chains of messages are not being stubbed. Enabled: true + VersionAdded: '1.7' StyleGuide: https://www.rubydoc.info/gems/rubocop-rspec/RuboCop/Cop/RSpec/MessageChain RSpec/MessageExpectation: @@ -305,6 +360,8 @@ RSpec/MessageExpectation: SupportedStyles: - allow - expect + VersionAdded: '1.7' + VersionChanged: '1.8' StyleGuide: https://www.rubydoc.info/gems/rubocop-rspec/RuboCop/Cop/RSpec/MessageExpectation RSpec/MessageSpies: @@ -314,58 +371,70 @@ RSpec/MessageSpies: SupportedStyles: - have_received - receive + VersionAdded: '1.9' StyleGuide: https://www.rubydoc.info/gems/rubocop-rspec/RuboCop/Cop/RSpec/MessageSpies RSpec/MissingExampleGroupArgument: Description: Checks that the first argument to an example group is not empty. Enabled: true + VersionAdded: '1.28' StyleGuide: https://www.rubydoc.info/gems/rubocop-rspec/RuboCop/Cop/RSpec/MissingExampleGroupArgument RSpec/MultipleDescribes: Description: Checks for multiple top level describes. Enabled: true + VersionAdded: '1.0' StyleGuide: https://www.rubydoc.info/gems/rubocop-rspec/RuboCop/Cop/RSpec/MultipleDescribes RSpec/MultipleExpectations: Description: Checks if examples contain too many `expect` calls. Enabled: true Max: 1 + VersionAdded: '1.7' + VersionChanged: '1.21' StyleGuide: https://www.rubydoc.info/gems/rubocop-rspec/RuboCop/Cop/RSpec/MultipleExpectations RSpec/MultipleSubjects: Description: Checks if an example group defines `subject` multiple times. Enabled: true + VersionAdded: '1.16' StyleGuide: https://www.rubydoc.info/gems/rubocop-rspec/RuboCop/Cop/RSpec/MultipleSubjects RSpec/NamedSubject: Description: Checks for explicitly referenced test subjects. Enabled: true IgnoreSharedExamples: true + VersionAdded: 1.5.3 StyleGuide: https://www.rubydoc.info/gems/rubocop-rspec/RuboCop/Cop/RSpec/NamedSubject RSpec/NestedGroups: Description: Checks for nested example groups. Enabled: true Max: 3 + VersionAdded: '1.7' + VersionChanged: '1.10' StyleGuide: https://www.rubydoc.info/gems/rubocop-rspec/RuboCop/Cop/RSpec/NestedGroups RSpec/NotToNot: Description: Checks for consistent method usage for negating expectations. + Enabled: true EnforcedStyle: not_to SupportedStyles: - not_to - to_not - Enabled: true + VersionAdded: '1.4' StyleGuide: https://www.rubydoc.info/gems/rubocop-rspec/RuboCop/Cop/RSpec/NotToNot RSpec/OverwritingSetup: - Enabled: true Description: Checks if there is a let/subject that overwrites an existing one. + Enabled: true + VersionAdded: '1.14' StyleGuide: https://www.rubydoc.info/gems/rubocop-rspec/RuboCop/Cop/RSpec/OverwritingSetup RSpec/Pending: - Enabled: false Description: Checks for any pending or skipped examples. + Enabled: false + VersionAdded: '1.25' StyleGuide: https://www.rubydoc.info/gems/rubocop-rspec/RuboCop/Cop/RSpec/Pending RSpec/PredicateMatcher: @@ -377,109 +446,154 @@ RSpec/PredicateMatcher: SupportedStyles: - inflected - explicit + SafeAutoCorrect: false + VersionAdded: '1.16' StyleGuide: https://www.rubydoc.info/gems/rubocop-rspec/RuboCop/Cop/RSpec/PredicateMatcher RSpec/ReceiveCounts: - Enabled: true Description: Check for `once` and `twice` receive counts matchers usage. + Enabled: true + VersionAdded: '1.26' StyleGuide: https://www.rubydoc.info/gems/rubocop-rspec/RuboCop/Cop/RSpec/ReceiveCounts RSpec/ReceiveNever: - Enabled: true Description: Prefer `not_to receive(...)` over `receive(...).never`. + Enabled: true + VersionAdded: '1.28' StyleGuide: https://www.rubydoc.info/gems/rubocop-rspec/RuboCop/Cop/RSpec/ReceiveNever RSpec/RepeatedDescription: - Enabled: true Description: Check for repeated description strings in example groups. + Enabled: true + VersionAdded: '1.9' StyleGuide: https://www.rubydoc.info/gems/rubocop-rspec/RuboCop/Cop/RSpec/RepeatedDescription RSpec/RepeatedExample: - Enabled: true Description: Check for repeated examples within example groups. + Enabled: true + VersionAdded: '1.10' StyleGuide: https://www.rubydoc.info/gems/rubocop-rspec/RuboCop/Cop/RSpec/RepeatedExample RSpec/RepeatedExampleGroupBody: - Enabled: true Description: Check for repeated describe and context block body. + Enabled: true + VersionAdded: '1.38' StyleGuide: https://www.rubydoc.info/gems/rubocop-rspec/RuboCop/Cop/RSpec/RepeatedExampleGroupBody RSpec/RepeatedExampleGroupDescription: - Enabled: true Description: Check for repeated example group descriptions. + Enabled: true + VersionAdded: '1.38' StyleGuide: https://www.rubydoc.info/gems/rubocop-rspec/RuboCop/Cop/RSpec/RepeatedExampleGroupDescription RSpec/ReturnFromStub: - Enabled: true Description: Checks for consistent style of stub's return setting. + Enabled: true EnforcedStyle: and_return SupportedStyles: - and_return - block + VersionAdded: '1.16' + VersionChanged: '1.22' StyleGuide: https://www.rubydoc.info/gems/rubocop-rspec/RuboCop/Cop/RSpec/ReturnFromStub RSpec/ScatteredLet: Description: Checks for let scattered across the example group. Enabled: true - StyleGuide: https://www.rubydoc.info/gems/rubocop-rspec/RuboCop/Cop/RSpec/ScatteredLet + VersionAdded: '1.14' VersionChanged: '1.39' + StyleGuide: https://www.rubydoc.info/gems/rubocop-rspec/RuboCop/Cop/RSpec/ScatteredLet RSpec/ScatteredSetup: Description: Checks for setup scattered across multiple hooks in an example group. Enabled: true + VersionAdded: '1.10' StyleGuide: https://www.rubydoc.info/gems/rubocop-rspec/RuboCop/Cop/RSpec/ScatteredSetup RSpec/SharedContext: Description: Checks for proper shared_context and shared_examples usage. Enabled: true + VersionAdded: '1.13' StyleGuide: https://www.rubydoc.info/gems/rubocop-rspec/RuboCop/Cop/RSpec/SharedContext RSpec/SharedExamples: Description: Enforces use of string to titleize shared examples. Enabled: true + VersionAdded: '1.25' StyleGuide: https://www.rubydoc.info/gems/rubocop-rspec/RuboCop/Cop/RSpec/SharedExamples RSpec/SingleArgumentMessageChain: Description: Checks that chains of messages contain more than one element. Enabled: true + VersionAdded: '1.9' + VersionChanged: '1.10' StyleGuide: https://www.rubydoc.info/gems/rubocop-rspec/RuboCop/Cop/RSpec/SingleArgumentMessageChain RSpec/SubjectStub: Description: Checks for stubbed test subjects. Enabled: true + VersionAdded: '1.7' StyleGuide: https://www.rubydoc.info/gems/rubocop-rspec/RuboCop/Cop/RSpec/SubjectStub RSpec/UnspecifiedException: Description: Checks for a specified error in checking raised errors. Enabled: true + VersionAdded: '1.30' StyleGuide: https://www.rubydoc.info/gems/rubocop-rspec/RuboCop/Cop/RSpec/UnspecifiedException +RSpec/VariableDefinition: + Description: Checks that memoized helpers names are symbols or strings. + Enabled: true + EnforcedStyle: symbols + SupportedStyles: + - symbols + - strings + VersionAdded: '1.40' + StyleGuide: https://www.rubydoc.info/gems/rubocop-rspec/RuboCop/Cop/RSpec/VariableDefinition + +RSpec/VariableName: + Description: Checks that memoized helper names use the configured style. + Enabled: true + EnforcedStyle: snake_case + SupportedStyles: + - snake_case + - camelCase + VersionAdded: '1.40' + StyleGuide: https://www.rubydoc.info/gems/rubocop-rspec/RuboCop/Cop/RSpec/VariableName + RSpec/VerifiedDoubles: Description: Prefer using verifying doubles over normal doubles. Enabled: true IgnoreNameless: true IgnoreSymbolicNames: false + VersionAdded: 1.2.1 + VersionChanged: '1.5' StyleGuide: https://www.rubydoc.info/gems/rubocop-rspec/RuboCop/Cop/RSpec/VerifiedDoubles RSpec/VoidExpect: Description: This cop checks void `expect()`. Enabled: true + VersionAdded: '1.16' StyleGuide: https://www.rubydoc.info/gems/rubocop-rspec/RuboCop/Cop/RSpec/VoidExpect RSpec/Yield: Description: This cop checks for calling a block within a stub. Enabled: true + VersionAdded: '1.32' StyleGuide: https://www.rubydoc.info/gems/rubocop-rspec/RuboCop/Cop/RSpec/Yield Capybara/CurrentPathExpectation: Description: Checks that no expectations are set on Capybara's `current_path`. Enabled: true + VersionAdded: '1.18' StyleGuide: https://www.rubydoc.info/gems/rubocop-rspec/RuboCop/Cop/RSpec/Capybara/CurrentPathExpectation Capybara/FeatureMethods: Description: Checks for consistent method usage in feature specs. Enabled: true EnabledMethods: [] + VersionAdded: '1.17' + VersionChanged: '1.25' StyleGuide: https://www.rubydoc.info/gems/rubocop-rspec/RuboCop/Cop/RSpec/Capybara/FeatureMethods Capybara/VisibilityMatcher: @@ -491,6 +605,7 @@ Capybara/VisibilityMatcher: FactoryBot/AttributeDefinedStatically: Description: Always declare attribute values as blocks. Enabled: true + VersionAdded: '1.28' StyleGuide: https://www.rubydoc.info/gems/rubocop-rspec/RuboCop/Cop/RSpec/FactoryBot/AttributeDefinedStatically FactoryBot/CreateList: @@ -500,11 +615,13 @@ FactoryBot/CreateList: SupportedStyles: - create_list - n_times + VersionAdded: '1.25' StyleGuide: https://www.rubydoc.info/gems/rubocop-rspec/RuboCop/Cop/RSpec/FactoryBot/CreateList FactoryBot/FactoryClassName: Description: Use string value when setting the class attribute explicitly. Enabled: true + VersionAdded: '1.37' StyleGuide: https://www.rubydoc.info/gems/rubocop-rspec/RuboCop/Cop/RSpec/FactoryBot/FactoryClassName Rails/HttpStatus: @@ -514,4 +631,5 @@ Rails/HttpStatus: SupportedStyles: - numeric - symbolic + VersionAdded: '1.23' StyleGuide: https://www.rubydoc.info/gems/rubocop-rspec/RuboCop/Cop/RSpec/Rails/HttpStatus diff --git a/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.39.0/lib/rubocop-rspec.rb b/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.40.0/lib/rubocop-rspec.rb similarity index 97% rename from Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.39.0/lib/rubocop-rspec.rb rename to Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.40.0/lib/rubocop-rspec.rb index 9aa56c6f28..cf9231dd8f 100644 --- a/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.39.0/lib/rubocop-rspec.rb +++ b/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.40.0/lib/rubocop-rspec.rb @@ -17,6 +17,7 @@ require_relative 'rubocop/rspec/concept' require_relative 'rubocop/rspec/example_group' require_relative 'rubocop/rspec/example' require_relative 'rubocop/rspec/hook' +require_relative 'rubocop/rspec/variable' require_relative 'rubocop/cop/rspec/cop' require_relative 'rubocop/rspec/align_let_brace' require_relative 'rubocop/rspec/factory_bot' diff --git a/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.39.0/lib/rubocop/cop/rspec/align_left_let_brace.rb b/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.40.0/lib/rubocop/cop/rspec/align_left_let_brace.rb similarity index 100% rename from Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.39.0/lib/rubocop/cop/rspec/align_left_let_brace.rb rename to Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.40.0/lib/rubocop/cop/rspec/align_left_let_brace.rb diff --git a/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.39.0/lib/rubocop/cop/rspec/align_right_let_brace.rb b/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.40.0/lib/rubocop/cop/rspec/align_right_let_brace.rb similarity index 100% rename from Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.39.0/lib/rubocop/cop/rspec/align_right_let_brace.rb rename to Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.40.0/lib/rubocop/cop/rspec/align_right_let_brace.rb diff --git a/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.39.0/lib/rubocop/cop/rspec/any_instance.rb b/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.40.0/lib/rubocop/cop/rspec/any_instance.rb similarity index 100% rename from Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.39.0/lib/rubocop/cop/rspec/any_instance.rb rename to Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.40.0/lib/rubocop/cop/rspec/any_instance.rb diff --git a/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.39.0/lib/rubocop/cop/rspec/around_block.rb b/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.40.0/lib/rubocop/cop/rspec/around_block.rb similarity index 100% rename from Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.39.0/lib/rubocop/cop/rspec/around_block.rb rename to Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.40.0/lib/rubocop/cop/rspec/around_block.rb diff --git a/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.39.0/lib/rubocop/cop/rspec/be.rb b/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.40.0/lib/rubocop/cop/rspec/be.rb similarity index 100% rename from Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.39.0/lib/rubocop/cop/rspec/be.rb rename to Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.40.0/lib/rubocop/cop/rspec/be.rb diff --git a/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.39.0/lib/rubocop/cop/rspec/be_eql.rb b/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.40.0/lib/rubocop/cop/rspec/be_eql.rb similarity index 100% rename from Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.39.0/lib/rubocop/cop/rspec/be_eql.rb rename to Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.40.0/lib/rubocop/cop/rspec/be_eql.rb diff --git a/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.39.0/lib/rubocop/cop/rspec/before_after_all.rb b/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.40.0/lib/rubocop/cop/rspec/before_after_all.rb similarity index 100% rename from Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.39.0/lib/rubocop/cop/rspec/before_after_all.rb rename to Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.40.0/lib/rubocop/cop/rspec/before_after_all.rb diff --git a/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.39.0/lib/rubocop/cop/rspec/capybara/current_path_expectation.rb b/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.40.0/lib/rubocop/cop/rspec/capybara/current_path_expectation.rb similarity index 100% rename from Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.39.0/lib/rubocop/cop/rspec/capybara/current_path_expectation.rb rename to Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.40.0/lib/rubocop/cop/rspec/capybara/current_path_expectation.rb diff --git a/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.39.0/lib/rubocop/cop/rspec/capybara/feature_methods.rb b/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.40.0/lib/rubocop/cop/rspec/capybara/feature_methods.rb similarity index 100% rename from Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.39.0/lib/rubocop/cop/rspec/capybara/feature_methods.rb rename to Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.40.0/lib/rubocop/cop/rspec/capybara/feature_methods.rb diff --git a/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.39.0/lib/rubocop/cop/rspec/capybara/visibility_matcher.rb b/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.40.0/lib/rubocop/cop/rspec/capybara/visibility_matcher.rb similarity index 61% rename from Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.39.0/lib/rubocop/cop/rspec/capybara/visibility_matcher.rb rename to Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.40.0/lib/rubocop/cop/rspec/capybara/visibility_matcher.rb index 35f4579e12..4e23c12c9c 100644 --- a/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.39.0/lib/rubocop/cop/rspec/capybara/visibility_matcher.rb +++ b/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.40.0/lib/rubocop/cop/rspec/capybara/visibility_matcher.rb @@ -18,35 +18,50 @@ module RuboCop # # # bad # expect(page).to have_selector('.foo', visible: false) - # - # # bad - # expect(page).to have_selector('.foo', visible: true) - # - # # good - # expect(page).to have_selector('.foo', visible: :all) - # - # # good - # expect(page).to have_selector('.foo', visible: :hidden) + # expect(page).to have_css('.foo', visible: true) + # expect(page).to have_link('my link', visible: false) # # # good # expect(page).to have_selector('.foo', visible: :visible) + # expect(page).to have_css('.foo', visible: :all) + # expect(page).to have_link('my link', visible: :hidden) # class VisibilityMatcher < Cop MSG_FALSE = 'Use `:all` or `:hidden` instead of `false`.' MSG_TRUE = 'Use `:visible` instead of `true`.' + CAPYBARA_MATCHER_METHODS = %i[ + have_selector + have_css + have_xpath + have_link + have_button + have_field + have_select + have_table + have_checked_field + have_unchecked_field + have_text + have_content + ].freeze def_node_matcher :visible_true?, <<~PATTERN - (send nil? :have_selector ... (hash <$(pair (sym :visible) true) ...>)) + (send nil? #capybara_matcher? ... (hash <$(pair (sym :visible) true) ...>)) PATTERN def_node_matcher :visible_false?, <<~PATTERN - (send nil? :have_selector ... (hash <$(pair (sym :visible) false) ...>)) + (send nil? #capybara_matcher? ... (hash <$(pair (sym :visible) false) ...>)) PATTERN def on_send(node) visible_false?(node) { |arg| add_offense(arg, message: MSG_FALSE) } visible_true?(node) { |arg| add_offense(arg, message: MSG_TRUE) } end + + private + + def capybara_matcher?(method_name) + CAPYBARA_MATCHER_METHODS.include? method_name + end end end end diff --git a/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.39.0/lib/rubocop/cop/rspec/context_method.rb b/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.40.0/lib/rubocop/cop/rspec/context_method.rb similarity index 100% rename from Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.39.0/lib/rubocop/cop/rspec/context_method.rb rename to Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.40.0/lib/rubocop/cop/rspec/context_method.rb diff --git a/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.39.0/lib/rubocop/cop/rspec/context_wording.rb b/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.40.0/lib/rubocop/cop/rspec/context_wording.rb similarity index 100% rename from Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.39.0/lib/rubocop/cop/rspec/context_wording.rb rename to Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.40.0/lib/rubocop/cop/rspec/context_wording.rb diff --git a/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.39.0/lib/rubocop/cop/rspec/cop.rb b/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.40.0/lib/rubocop/cop/rspec/cop.rb similarity index 68% rename from Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.39.0/lib/rubocop/cop/rspec/cop.rb rename to Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.40.0/lib/rubocop/cop/rspec/cop.rb index fa8e304279..1c8cf00861 100644 --- a/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.39.0/lib/rubocop/cop/rspec/cop.rb +++ b/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.40.0/lib/rubocop/cop/rspec/cop.rb @@ -2,28 +2,8 @@ module RuboCop module Cop - WorkaroundCop = Cop.dup - - # Clone of the the normal RuboCop::Cop::Cop class so we can rewrite - # the inherited method without breaking functionality - class WorkaroundCop - # Remove the Cop.inherited method to be a noop. Our RSpec::Cop - # class will invoke the inherited hook instead - class << self - undef inherited - def inherited(*) end - end - - # Special case `Module#<` so that the rspec support rubocop exports - # is compatible with our subclass - def self.<(other) - other.equal?(RuboCop::Cop::Cop) || super - end - end - private_constant(:WorkaroundCop) - module RSpec - # @abstract parent class to rspec cops + # @abstract parent class to RSpec cops # # The criteria for whether rubocop-rspec analyzes a certain ruby file # is configured via `AllCops/RSpec`. For example, if you want to @@ -31,13 +11,13 @@ module RuboCop # then you could add this to your configuration: # # @example configuring analyzed paths - # - # AllCops: - # RSpec: - # Patterns: - # - '_test.rb$' - # - '(?:^|/)test/' - class Cop < WorkaroundCop + # # .rubocop.yml + # # AllCops: + # # RSpec: + # # Patterns: + # # - '_test.rb$' + # # - '(?:^|/)test/' + class Cop < ::RuboCop::Cop::Cop include RuboCop::RSpec::Language include RuboCop::RSpec::Language::NodePattern diff --git a/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.39.0/lib/rubocop/cop/rspec/describe_class.rb b/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.40.0/lib/rubocop/cop/rspec/describe_class.rb similarity index 100% rename from Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.39.0/lib/rubocop/cop/rspec/describe_class.rb rename to Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.40.0/lib/rubocop/cop/rspec/describe_class.rb diff --git a/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.39.0/lib/rubocop/cop/rspec/describe_method.rb b/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.40.0/lib/rubocop/cop/rspec/describe_method.rb similarity index 100% rename from Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.39.0/lib/rubocop/cop/rspec/describe_method.rb rename to Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.40.0/lib/rubocop/cop/rspec/describe_method.rb diff --git a/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.39.0/lib/rubocop/cop/rspec/describe_symbol.rb b/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.40.0/lib/rubocop/cop/rspec/describe_symbol.rb similarity index 100% rename from Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.39.0/lib/rubocop/cop/rspec/describe_symbol.rb rename to Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.40.0/lib/rubocop/cop/rspec/describe_symbol.rb diff --git a/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.39.0/lib/rubocop/cop/rspec/described_class.rb b/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.40.0/lib/rubocop/cop/rspec/described_class.rb similarity index 100% rename from Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.39.0/lib/rubocop/cop/rspec/described_class.rb rename to Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.40.0/lib/rubocop/cop/rspec/described_class.rb diff --git a/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.39.0/lib/rubocop/cop/rspec/described_class_module_wrapping.rb b/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.40.0/lib/rubocop/cop/rspec/described_class_module_wrapping.rb similarity index 100% rename from Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.39.0/lib/rubocop/cop/rspec/described_class_module_wrapping.rb rename to Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.40.0/lib/rubocop/cop/rspec/described_class_module_wrapping.rb diff --git a/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.39.0/lib/rubocop/cop/rspec/dialect.rb b/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.40.0/lib/rubocop/cop/rspec/dialect.rb similarity index 100% rename from Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.39.0/lib/rubocop/cop/rspec/dialect.rb rename to Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.40.0/lib/rubocop/cop/rspec/dialect.rb diff --git a/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.39.0/lib/rubocop/cop/rspec/empty_example_group.rb b/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.40.0/lib/rubocop/cop/rspec/empty_example_group.rb similarity index 100% rename from Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.39.0/lib/rubocop/cop/rspec/empty_example_group.rb rename to Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.40.0/lib/rubocop/cop/rspec/empty_example_group.rb diff --git a/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.39.0/lib/rubocop/cop/rspec/empty_hook.rb b/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.40.0/lib/rubocop/cop/rspec/empty_hook.rb similarity index 100% rename from Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.39.0/lib/rubocop/cop/rspec/empty_hook.rb rename to Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.40.0/lib/rubocop/cop/rspec/empty_hook.rb diff --git a/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.39.0/lib/rubocop/cop/rspec/empty_line_after_example.rb b/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.40.0/lib/rubocop/cop/rspec/empty_line_after_example.rb similarity index 100% rename from Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.39.0/lib/rubocop/cop/rspec/empty_line_after_example.rb rename to Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.40.0/lib/rubocop/cop/rspec/empty_line_after_example.rb diff --git a/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.39.0/lib/rubocop/cop/rspec/empty_line_after_example_group.rb b/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.40.0/lib/rubocop/cop/rspec/empty_line_after_example_group.rb similarity index 100% rename from Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.39.0/lib/rubocop/cop/rspec/empty_line_after_example_group.rb rename to Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.40.0/lib/rubocop/cop/rspec/empty_line_after_example_group.rb diff --git a/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.39.0/lib/rubocop/cop/rspec/empty_line_after_final_let.rb b/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.40.0/lib/rubocop/cop/rspec/empty_line_after_final_let.rb similarity index 100% rename from Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.39.0/lib/rubocop/cop/rspec/empty_line_after_final_let.rb rename to Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.40.0/lib/rubocop/cop/rspec/empty_line_after_final_let.rb diff --git a/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.39.0/lib/rubocop/cop/rspec/empty_line_after_hook.rb b/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.40.0/lib/rubocop/cop/rspec/empty_line_after_hook.rb similarity index 100% rename from Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.39.0/lib/rubocop/cop/rspec/empty_line_after_hook.rb rename to Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.40.0/lib/rubocop/cop/rspec/empty_line_after_hook.rb diff --git a/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.39.0/lib/rubocop/cop/rspec/empty_line_after_subject.rb b/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.40.0/lib/rubocop/cop/rspec/empty_line_after_subject.rb similarity index 100% rename from Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.39.0/lib/rubocop/cop/rspec/empty_line_after_subject.rb rename to Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.40.0/lib/rubocop/cop/rspec/empty_line_after_subject.rb diff --git a/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.39.0/lib/rubocop/cop/rspec/example_length.rb b/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.40.0/lib/rubocop/cop/rspec/example_length.rb similarity index 100% rename from Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.39.0/lib/rubocop/cop/rspec/example_length.rb rename to Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.40.0/lib/rubocop/cop/rspec/example_length.rb diff --git a/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.39.0/lib/rubocop/cop/rspec/example_without_description.rb b/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.40.0/lib/rubocop/cop/rspec/example_without_description.rb similarity index 100% rename from Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.39.0/lib/rubocop/cop/rspec/example_without_description.rb rename to Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.40.0/lib/rubocop/cop/rspec/example_without_description.rb diff --git a/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.39.0/lib/rubocop/cop/rspec/example_wording.rb b/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.40.0/lib/rubocop/cop/rspec/example_wording.rb similarity index 100% rename from Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.39.0/lib/rubocop/cop/rspec/example_wording.rb rename to Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.40.0/lib/rubocop/cop/rspec/example_wording.rb diff --git a/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.39.0/lib/rubocop/cop/rspec/expect_actual.rb b/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.40.0/lib/rubocop/cop/rspec/expect_actual.rb similarity index 100% rename from Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.39.0/lib/rubocop/cop/rspec/expect_actual.rb rename to Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.40.0/lib/rubocop/cop/rspec/expect_actual.rb diff --git a/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.39.0/lib/rubocop/cop/rspec/expect_change.rb b/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.40.0/lib/rubocop/cop/rspec/expect_change.rb similarity index 100% rename from Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.39.0/lib/rubocop/cop/rspec/expect_change.rb rename to Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.40.0/lib/rubocop/cop/rspec/expect_change.rb diff --git a/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.39.0/lib/rubocop/cop/rspec/expect_in_hook.rb b/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.40.0/lib/rubocop/cop/rspec/expect_in_hook.rb similarity index 100% rename from Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.39.0/lib/rubocop/cop/rspec/expect_in_hook.rb rename to Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.40.0/lib/rubocop/cop/rspec/expect_in_hook.rb diff --git a/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.39.0/lib/rubocop/cop/rspec/expect_output.rb b/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.40.0/lib/rubocop/cop/rspec/expect_output.rb similarity index 100% rename from Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.39.0/lib/rubocop/cop/rspec/expect_output.rb rename to Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.40.0/lib/rubocop/cop/rspec/expect_output.rb diff --git a/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.39.0/lib/rubocop/cop/rspec/factory_bot/attribute_defined_statically.rb b/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.40.0/lib/rubocop/cop/rspec/factory_bot/attribute_defined_statically.rb similarity index 100% rename from Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.39.0/lib/rubocop/cop/rspec/factory_bot/attribute_defined_statically.rb rename to Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.40.0/lib/rubocop/cop/rspec/factory_bot/attribute_defined_statically.rb diff --git a/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.39.0/lib/rubocop/cop/rspec/factory_bot/create_list.rb b/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.40.0/lib/rubocop/cop/rspec/factory_bot/create_list.rb similarity index 100% rename from Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.39.0/lib/rubocop/cop/rspec/factory_bot/create_list.rb rename to Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.40.0/lib/rubocop/cop/rspec/factory_bot/create_list.rb diff --git a/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.39.0/lib/rubocop/cop/rspec/factory_bot/factory_class_name.rb b/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.40.0/lib/rubocop/cop/rspec/factory_bot/factory_class_name.rb similarity index 100% rename from Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.39.0/lib/rubocop/cop/rspec/factory_bot/factory_class_name.rb rename to Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.40.0/lib/rubocop/cop/rspec/factory_bot/factory_class_name.rb diff --git a/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.39.0/lib/rubocop/cop/rspec/file_path.rb b/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.40.0/lib/rubocop/cop/rspec/file_path.rb similarity index 74% rename from Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.39.0/lib/rubocop/cop/rspec/file_path.rb rename to Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.40.0/lib/rubocop/cop/rspec/file_path.rb index e368424ef9..4407c871be 100644 --- a/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.39.0/lib/rubocop/cop/rspec/file_path.rb +++ b/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.40.0/lib/rubocop/cop/rspec/file_path.rb @@ -3,10 +3,11 @@ module RuboCop module Cop module RSpec - # Checks that spec file paths are consistent with the test subject. + # Checks that spec file paths are consistent and well-formed. # - # Checks the path of the spec file and enforces that it reflects the - # described class/module and its optionally called out method. + # By default, this checks that spec file paths are consistent with the + # test subject and and enforces that it reflects the described + # class/module and its optionally called out method. # # With the configuration option `IgnoreMethods` the called out method will # be ignored when determining the enforced path. @@ -15,6 +16,10 @@ module RuboCop # be specified that should not as usual be transformed from CamelCase to # snake_case (e.g. 'RuboCop' => 'rubocop' ). # + # With the configuration option `SpecSuffixOnly` test files will only + # be checked to ensure they end in '_spec.rb'. This option disables + # checking for consistency in the test subject or test methods. + # # @example # # bad # whatever_spec.rb # describe MyClass @@ -41,6 +46,16 @@ module RuboCop # # good # my_class_spec.rb # describe MyClass, '#method' # + # @example when configuration is `SpecSuffixOnly: true` + # # good + # whatever_spec.rb # describe MyClass + # + # # good + # my_class_spec.rb # describe MyClass + # + # # good + # my_class_spec.rb # describe MyClass, '#method' + # class FilePath < Cop include RuboCop::RSpec::TopLevelDescribe @@ -70,9 +85,15 @@ module RuboCop end def glob_for((described_class, method_name)) + return glob_for_spec_suffix_only? if spec_suffix_only? + "#{expected_path(described_class)}#{name_glob(method_name)}*_spec.rb" end + def glob_for_spec_suffix_only? + '*_spec.rb' + end + def name_glob(name) return unless name&.str_type? @@ -105,12 +126,17 @@ module RuboCop def filename_ends_with?(glob) filename = RuboCop::PathUtil.relative_path(processed_source.buffer.name) + .gsub('../', '') File.fnmatch?("*#{glob}", filename) end def relevant_rubocop_rspec_file?(_file) true end + + def spec_suffix_only? + cop_config['SpecSuffixOnly'] + end end end end diff --git a/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.39.0/lib/rubocop/cop/rspec/focus.rb b/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.40.0/lib/rubocop/cop/rspec/focus.rb similarity index 100% rename from Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.39.0/lib/rubocop/cop/rspec/focus.rb rename to Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.40.0/lib/rubocop/cop/rspec/focus.rb diff --git a/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.39.0/lib/rubocop/cop/rspec/hook_argument.rb b/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.40.0/lib/rubocop/cop/rspec/hook_argument.rb similarity index 100% rename from Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.39.0/lib/rubocop/cop/rspec/hook_argument.rb rename to Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.40.0/lib/rubocop/cop/rspec/hook_argument.rb diff --git a/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.39.0/lib/rubocop/cop/rspec/hooks_before_examples.rb b/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.40.0/lib/rubocop/cop/rspec/hooks_before_examples.rb similarity index 100% rename from Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.39.0/lib/rubocop/cop/rspec/hooks_before_examples.rb rename to Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.40.0/lib/rubocop/cop/rspec/hooks_before_examples.rb diff --git a/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.39.0/lib/rubocop/cop/rspec/implicit_block_expectation.rb b/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.40.0/lib/rubocop/cop/rspec/implicit_block_expectation.rb similarity index 100% rename from Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.39.0/lib/rubocop/cop/rspec/implicit_block_expectation.rb rename to Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.40.0/lib/rubocop/cop/rspec/implicit_block_expectation.rb diff --git a/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.39.0/lib/rubocop/cop/rspec/implicit_expect.rb b/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.40.0/lib/rubocop/cop/rspec/implicit_expect.rb similarity index 100% rename from Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.39.0/lib/rubocop/cop/rspec/implicit_expect.rb rename to Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.40.0/lib/rubocop/cop/rspec/implicit_expect.rb diff --git a/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.39.0/lib/rubocop/cop/rspec/implicit_subject.rb b/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.40.0/lib/rubocop/cop/rspec/implicit_subject.rb similarity index 100% rename from Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.39.0/lib/rubocop/cop/rspec/implicit_subject.rb rename to Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.40.0/lib/rubocop/cop/rspec/implicit_subject.rb diff --git a/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.39.0/lib/rubocop/cop/rspec/instance_spy.rb b/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.40.0/lib/rubocop/cop/rspec/instance_spy.rb similarity index 100% rename from Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.39.0/lib/rubocop/cop/rspec/instance_spy.rb rename to Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.40.0/lib/rubocop/cop/rspec/instance_spy.rb diff --git a/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.39.0/lib/rubocop/cop/rspec/instance_variable.rb b/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.40.0/lib/rubocop/cop/rspec/instance_variable.rb similarity index 100% rename from Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.39.0/lib/rubocop/cop/rspec/instance_variable.rb rename to Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.40.0/lib/rubocop/cop/rspec/instance_variable.rb diff --git a/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.39.0/lib/rubocop/cop/rspec/invalid_predicate_matcher.rb b/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.40.0/lib/rubocop/cop/rspec/invalid_predicate_matcher.rb similarity index 100% rename from Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.39.0/lib/rubocop/cop/rspec/invalid_predicate_matcher.rb rename to Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.40.0/lib/rubocop/cop/rspec/invalid_predicate_matcher.rb diff --git a/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.39.0/lib/rubocop/cop/rspec/it_behaves_like.rb b/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.40.0/lib/rubocop/cop/rspec/it_behaves_like.rb similarity index 100% rename from Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.39.0/lib/rubocop/cop/rspec/it_behaves_like.rb rename to Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.40.0/lib/rubocop/cop/rspec/it_behaves_like.rb diff --git a/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.39.0/lib/rubocop/cop/rspec/iterated_expectation.rb b/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.40.0/lib/rubocop/cop/rspec/iterated_expectation.rb similarity index 100% rename from Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.39.0/lib/rubocop/cop/rspec/iterated_expectation.rb rename to Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.40.0/lib/rubocop/cop/rspec/iterated_expectation.rb diff --git a/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.39.0/lib/rubocop/cop/rspec/leading_subject.rb b/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.40.0/lib/rubocop/cop/rspec/leading_subject.rb similarity index 100% rename from Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.39.0/lib/rubocop/cop/rspec/leading_subject.rb rename to Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.40.0/lib/rubocop/cop/rspec/leading_subject.rb diff --git a/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.39.0/lib/rubocop/cop/rspec/leaky_constant_declaration.rb b/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.40.0/lib/rubocop/cop/rspec/leaky_constant_declaration.rb similarity index 100% rename from Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.39.0/lib/rubocop/cop/rspec/leaky_constant_declaration.rb rename to Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.40.0/lib/rubocop/cop/rspec/leaky_constant_declaration.rb diff --git a/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.39.0/lib/rubocop/cop/rspec/let_before_examples.rb b/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.40.0/lib/rubocop/cop/rspec/let_before_examples.rb similarity index 100% rename from Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.39.0/lib/rubocop/cop/rspec/let_before_examples.rb rename to Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.40.0/lib/rubocop/cop/rspec/let_before_examples.rb diff --git a/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.39.0/lib/rubocop/cop/rspec/let_setup.rb b/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.40.0/lib/rubocop/cop/rspec/let_setup.rb similarity index 100% rename from Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.39.0/lib/rubocop/cop/rspec/let_setup.rb rename to Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.40.0/lib/rubocop/cop/rspec/let_setup.rb diff --git a/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.39.0/lib/rubocop/cop/rspec/message_chain.rb b/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.40.0/lib/rubocop/cop/rspec/message_chain.rb similarity index 100% rename from Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.39.0/lib/rubocop/cop/rspec/message_chain.rb rename to Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.40.0/lib/rubocop/cop/rspec/message_chain.rb diff --git a/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.39.0/lib/rubocop/cop/rspec/message_expectation.rb b/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.40.0/lib/rubocop/cop/rspec/message_expectation.rb similarity index 100% rename from Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.39.0/lib/rubocop/cop/rspec/message_expectation.rb rename to Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.40.0/lib/rubocop/cop/rspec/message_expectation.rb diff --git a/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.39.0/lib/rubocop/cop/rspec/message_spies.rb b/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.40.0/lib/rubocop/cop/rspec/message_spies.rb similarity index 100% rename from Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.39.0/lib/rubocop/cop/rspec/message_spies.rb rename to Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.40.0/lib/rubocop/cop/rspec/message_spies.rb diff --git a/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.39.0/lib/rubocop/cop/rspec/missing_example_group_argument.rb b/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.40.0/lib/rubocop/cop/rspec/missing_example_group_argument.rb similarity index 100% rename from Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.39.0/lib/rubocop/cop/rspec/missing_example_group_argument.rb rename to Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.40.0/lib/rubocop/cop/rspec/missing_example_group_argument.rb diff --git a/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.39.0/lib/rubocop/cop/rspec/multiple_describes.rb b/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.40.0/lib/rubocop/cop/rspec/multiple_describes.rb similarity index 100% rename from Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.39.0/lib/rubocop/cop/rspec/multiple_describes.rb rename to Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.40.0/lib/rubocop/cop/rspec/multiple_describes.rb diff --git a/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.39.0/lib/rubocop/cop/rspec/multiple_expectations.rb b/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.40.0/lib/rubocop/cop/rspec/multiple_expectations.rb similarity index 100% rename from Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.39.0/lib/rubocop/cop/rspec/multiple_expectations.rb rename to Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.40.0/lib/rubocop/cop/rspec/multiple_expectations.rb diff --git a/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.39.0/lib/rubocop/cop/rspec/multiple_subjects.rb b/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.40.0/lib/rubocop/cop/rspec/multiple_subjects.rb similarity index 100% rename from Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.39.0/lib/rubocop/cop/rspec/multiple_subjects.rb rename to Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.40.0/lib/rubocop/cop/rspec/multiple_subjects.rb diff --git a/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.39.0/lib/rubocop/cop/rspec/named_subject.rb b/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.40.0/lib/rubocop/cop/rspec/named_subject.rb similarity index 100% rename from Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.39.0/lib/rubocop/cop/rspec/named_subject.rb rename to Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.40.0/lib/rubocop/cop/rspec/named_subject.rb diff --git a/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.39.0/lib/rubocop/cop/rspec/nested_groups.rb b/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.40.0/lib/rubocop/cop/rspec/nested_groups.rb similarity index 100% rename from Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.39.0/lib/rubocop/cop/rspec/nested_groups.rb rename to Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.40.0/lib/rubocop/cop/rspec/nested_groups.rb diff --git a/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.39.0/lib/rubocop/cop/rspec/not_to_not.rb b/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.40.0/lib/rubocop/cop/rspec/not_to_not.rb similarity index 100% rename from Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.39.0/lib/rubocop/cop/rspec/not_to_not.rb rename to Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.40.0/lib/rubocop/cop/rspec/not_to_not.rb diff --git a/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.39.0/lib/rubocop/cop/rspec/overwriting_setup.rb b/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.40.0/lib/rubocop/cop/rspec/overwriting_setup.rb similarity index 100% rename from Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.39.0/lib/rubocop/cop/rspec/overwriting_setup.rb rename to Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.40.0/lib/rubocop/cop/rspec/overwriting_setup.rb diff --git a/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.39.0/lib/rubocop/cop/rspec/pending.rb b/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.40.0/lib/rubocop/cop/rspec/pending.rb similarity index 100% rename from Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.39.0/lib/rubocop/cop/rspec/pending.rb rename to Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.40.0/lib/rubocop/cop/rspec/pending.rb diff --git a/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.39.0/lib/rubocop/cop/rspec/predicate_matcher.rb b/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.40.0/lib/rubocop/cop/rspec/predicate_matcher.rb similarity index 100% rename from Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.39.0/lib/rubocop/cop/rspec/predicate_matcher.rb rename to Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.40.0/lib/rubocop/cop/rspec/predicate_matcher.rb diff --git a/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.39.0/lib/rubocop/cop/rspec/rails/http_status.rb b/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.40.0/lib/rubocop/cop/rspec/rails/http_status.rb similarity index 99% rename from Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.39.0/lib/rubocop/cop/rspec/rails/http_status.rb rename to Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.40.0/lib/rubocop/cop/rspec/rails/http_status.rb index fae03385ca..32a4dbd1e3 100644 --- a/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.39.0/lib/rubocop/cop/rspec/rails/http_status.rb +++ b/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.40.0/lib/rubocop/cop/rspec/rails/http_status.rb @@ -70,6 +70,7 @@ module RuboCop 'to describe HTTP status code.' attr_reader :node + def initialize(node) @node = node end @@ -110,6 +111,7 @@ module RuboCop ALLOWED_STATUSES = %i[error success missing redirect].freeze attr_reader :node + def initialize(node) @node = node end diff --git a/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.39.0/lib/rubocop/cop/rspec/receive_counts.rb b/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.40.0/lib/rubocop/cop/rspec/receive_counts.rb similarity index 100% rename from Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.39.0/lib/rubocop/cop/rspec/receive_counts.rb rename to Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.40.0/lib/rubocop/cop/rspec/receive_counts.rb diff --git a/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.39.0/lib/rubocop/cop/rspec/receive_never.rb b/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.40.0/lib/rubocop/cop/rspec/receive_never.rb similarity index 100% rename from Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.39.0/lib/rubocop/cop/rspec/receive_never.rb rename to Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.40.0/lib/rubocop/cop/rspec/receive_never.rb diff --git a/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.39.0/lib/rubocop/cop/rspec/repeated_description.rb b/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.40.0/lib/rubocop/cop/rspec/repeated_description.rb similarity index 100% rename from Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.39.0/lib/rubocop/cop/rspec/repeated_description.rb rename to Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.40.0/lib/rubocop/cop/rspec/repeated_description.rb diff --git a/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.39.0/lib/rubocop/cop/rspec/repeated_example.rb b/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.40.0/lib/rubocop/cop/rspec/repeated_example.rb similarity index 100% rename from Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.39.0/lib/rubocop/cop/rspec/repeated_example.rb rename to Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.40.0/lib/rubocop/cop/rspec/repeated_example.rb diff --git a/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.39.0/lib/rubocop/cop/rspec/repeated_example_group_body.rb b/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.40.0/lib/rubocop/cop/rspec/repeated_example_group_body.rb similarity index 86% rename from Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.39.0/lib/rubocop/cop/rspec/repeated_example_group_body.rb rename to Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.40.0/lib/rubocop/cop/rspec/repeated_example_group_body.rb index ab55a509fa..0670df5545 100644 --- a/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.39.0/lib/rubocop/cop/rspec/repeated_example_group_body.rb +++ b/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.40.0/lib/rubocop/cop/rspec/repeated_example_group_body.rb @@ -34,6 +34,15 @@ module RuboCop # it { cool_predicate } # end # + # # good + # context Array do + # it { is_expected.to respond_to :each } + # end + # + # context Hash do + # it { is_expected.to respond_to :each } + # end + # class RepeatedExampleGroupBody < Cop MSG = 'Repeated %s block body on line(s) %s' @@ -43,6 +52,7 @@ module RuboCop def_node_matcher :metadata, '(block (send _ _ _ $...) ...)' def_node_matcher :body, '(block _ args $...)' + def_node_matcher :const_arg, '(block (send _ _ $const ...) ...)' def_node_matcher :skip_or_pending?, <<-PATTERN (block <(send nil? {:skip :pending}) ...>) @@ -75,7 +85,7 @@ module RuboCop end def signature_keys(group) - [metadata(group), body(group)] + [metadata(group), body(group), const_arg(group)] end def message(group, repeats) diff --git a/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.39.0/lib/rubocop/cop/rspec/repeated_example_group_description.rb b/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.40.0/lib/rubocop/cop/rspec/repeated_example_group_description.rb similarity index 100% rename from Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.39.0/lib/rubocop/cop/rspec/repeated_example_group_description.rb rename to Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.40.0/lib/rubocop/cop/rspec/repeated_example_group_description.rb diff --git a/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.39.0/lib/rubocop/cop/rspec/return_from_stub.rb b/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.40.0/lib/rubocop/cop/rspec/return_from_stub.rb similarity index 100% rename from Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.39.0/lib/rubocop/cop/rspec/return_from_stub.rb rename to Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.40.0/lib/rubocop/cop/rspec/return_from_stub.rb diff --git a/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.39.0/lib/rubocop/cop/rspec/scattered_let.rb b/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.40.0/lib/rubocop/cop/rspec/scattered_let.rb similarity index 100% rename from Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.39.0/lib/rubocop/cop/rspec/scattered_let.rb rename to Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.40.0/lib/rubocop/cop/rspec/scattered_let.rb diff --git a/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.39.0/lib/rubocop/cop/rspec/scattered_setup.rb b/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.40.0/lib/rubocop/cop/rspec/scattered_setup.rb similarity index 100% rename from Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.39.0/lib/rubocop/cop/rspec/scattered_setup.rb rename to Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.40.0/lib/rubocop/cop/rspec/scattered_setup.rb diff --git a/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.39.0/lib/rubocop/cop/rspec/shared_context.rb b/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.40.0/lib/rubocop/cop/rspec/shared_context.rb similarity index 100% rename from Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.39.0/lib/rubocop/cop/rspec/shared_context.rb rename to Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.40.0/lib/rubocop/cop/rspec/shared_context.rb diff --git a/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.39.0/lib/rubocop/cop/rspec/shared_examples.rb b/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.40.0/lib/rubocop/cop/rspec/shared_examples.rb similarity index 99% rename from Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.39.0/lib/rubocop/cop/rspec/shared_examples.rb rename to Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.40.0/lib/rubocop/cop/rspec/shared_examples.rb index 5395d1b849..522168a6f8 100644 --- a/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.39.0/lib/rubocop/cop/rspec/shared_examples.rb +++ b/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.40.0/lib/rubocop/cop/rspec/shared_examples.rb @@ -47,6 +47,7 @@ module RuboCop 'to titleize shared examples.' attr_reader :node + def initialize(node) @node = node end diff --git a/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.39.0/lib/rubocop/cop/rspec/single_argument_message_chain.rb b/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.40.0/lib/rubocop/cop/rspec/single_argument_message_chain.rb similarity index 100% rename from Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.39.0/lib/rubocop/cop/rspec/single_argument_message_chain.rb rename to Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.40.0/lib/rubocop/cop/rspec/single_argument_message_chain.rb diff --git a/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.39.0/lib/rubocop/cop/rspec/subject_stub.rb b/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.40.0/lib/rubocop/cop/rspec/subject_stub.rb similarity index 57% rename from Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.39.0/lib/rubocop/cop/rspec/subject_stub.rb rename to Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.40.0/lib/rubocop/cop/rspec/subject_stub.rb index 7454a32a68..9c8b3f3921 100644 --- a/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.39.0/lib/rubocop/cop/rspec/subject_stub.rb +++ b/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.40.0/lib/rubocop/cop/rspec/subject_stub.rb @@ -1,5 +1,7 @@ # frozen_string_literal: true +require 'set' + module RuboCop module Cop module RSpec @@ -75,70 +77,46 @@ module RuboCop def on_block(node) return unless example_group?(node) + return if (processed_example_groups & node.ancestors).any? - find_subject_stub(node) do |stub| + processed_example_groups << node + @explicit_subjects = find_all_explicit_subjects(node) + + find_subject_expectations(node) do |stub| add_offense(stub) end end private - # Find subjects within tree and then find (send) nodes for that subject - # - # @param node [RuboCop::Node] example group - # - # @yield [RuboCop::Node] message expectations for subject - def find_subject_stub(node, &block) - find_subject(node) do |subject_name, context| - find_subject_expectation(context, subject_name, &block) + def processed_example_groups + @processed_example_groups ||= Set.new + end + + def find_all_explicit_subjects(node) + node.each_descendant(:block).with_object({}) do |child, h| + name = subject(child) + next unless name + + outer_example_group = child.each_ancestor.find do |a| + example_group?(a) + end + + h[outer_example_group] ||= [] + h[outer_example_group] << name end end - # Find a subject message expectation - # - # @param node [RuboCop::Node] - # @param subject_name [Symbol] name of subject - # - # @yield [RuboCop::Node] message expectation - def find_subject_expectation(node, subject_name, &block) - # Do not search node if it is an example group with its own subject. - return if example_group?(node) && redefines_subject?(node) + def find_subject_expectations(node, subject_names = [], &block) + subject_names = @explicit_subjects[node] if @explicit_subjects[node] - # Yield the current node if it is a message expectation. - yield(node) if message_expectation?(node, subject_name) - - # Recurse through node's children looking for a message expectation. - node.each_child_node do |child| - find_subject_expectation(child, subject_name, &block) + expectation_detected = (subject_names + [:subject]).any? do |name| + message_expectation?(node, name) end - end - - # Check if node's children contain a subject definition - # - # @param node [RuboCop::Node] - # - # @return [Boolean] - def redefines_subject?(node) - node.each_child_node.any? do |child| - subject(child) || redefines_subject?(child) - end - end - - # Find a subject definition - # - # @param node [RuboCop::Node] - # @param parent [RuboCop::Node,nil] - # - # @yieldparam subject_name [Symbol] name of subject being defined - # @yieldparam parent [RuboCop::Node] parent of subject definition - def find_subject(node, parent: nil, &block) - # An implicit subject is defined by RSpec when no subject is declared - subject_name = subject(node) || :subject - - yield(subject_name, parent) if parent + return yield(node) if expectation_detected node.each_child_node do |child| - find_subject(child, parent: node, &block) + find_subject_expectations(child, subject_names, &block) end end end diff --git a/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.39.0/lib/rubocop/cop/rspec/unspecified_exception.rb b/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.40.0/lib/rubocop/cop/rspec/unspecified_exception.rb similarity index 100% rename from Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.39.0/lib/rubocop/cop/rspec/unspecified_exception.rb rename to Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.40.0/lib/rubocop/cop/rspec/unspecified_exception.rb diff --git a/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.40.0/lib/rubocop/cop/rspec/variable_definition.rb b/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.40.0/lib/rubocop/cop/rspec/variable_definition.rb new file mode 100644 index 0000000000..5981d07e4f --- /dev/null +++ b/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-rspec-1.40.0/lib/rubocop/cop/rspec/variable_definition.rb @@ -0,0 +1,56 @@ +# frozen_string_literal: true + +module RuboCop + module Cop + module RSpec + # Checks that memoized helpers names are symbols or strings. + # + # @example EnforcedStyle: symbols (default) + # # bad + # let('user_name') { 'Adam' } + # subject('user') { create_user } + # + # # good + # let(:user_name) { 'Adam' } + # subject(:user) { create_user } + # + # @example EnforcedStyle: strings + # # bad + # let(:user_name) { 'Adam' } + # subject(:user) { create_user } + # + # # good + # let('user_name') { 'Adam' } + # subject('user') { create_user } + class VariableDefinition < Cop + include ConfigurableEnforcedStyle + include RuboCop::RSpec::Variable + + MSG = 'Use %