diff --git a/CHANGELOG.md b/CHANGELOG.md index a1d1c8c..7b49269 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,5 +1,7 @@ ## HEAD (unreleased) +- Replace some references in tests with foobar style code (https://github.com/zombocom/dead_end/pull/38) + ## 1.0.1 - Fix performance issue when evaluating multiple block combinations (https://github.com/zombocom/dead_end/pull/35) diff --git a/spec/fixtures/routes.txt.rb b/spec/fixtures/routes.txt.rb index c4c7a16..8673382 100644 --- a/spec/fixtures/routes.txt.rb +++ b/spec/fixtures/routes.txt.rb @@ -113,8 +113,8 @@ namespace :admin do resource :session - match "/out_of_office(*path)", via: :all, to: redirect { |_params, req| - uri = URI(req.path.gsub("out_of_office", "in_office")) + match "/foobar(*path)", via: :all, to: redirect { |_params, req| + uri = URI(req.path.gsub("foobar", "foobaz")) uri.query = req.query_string.presence uri.to_s } diff --git a/spec/perf/perf_spec.rb b/spec/perf/perf_spec.rb index ffdc956..fe6daf8 100644 --- a/spec/perf/perf_spec.rb +++ b/spec/perf/perf_spec.rb @@ -22,7 +22,7 @@ module DeadEnd 107 constraints -> { Rails.application.config.non_production } do 111 end ❯ 113 namespace :admin do - ❯ 116 match "/out_of_office(*path)", via: :all, to: redirect { |_params, req| + ❯ 116 match "/foobar(*path)", via: :all, to: redirect { |_params, req| ❯ 120 } 121 end EOM diff --git a/spec/unit/code_search_spec.rb b/spec/unit/code_search_spec.rb index c6c69a8..6e1fac1 100644 --- a/spec/unit/code_search_spec.rb +++ b/spec/unit/code_search_spec.rb @@ -45,19 +45,19 @@ class Foo it "handles no spaces between blocks" do search = CodeSearch.new(<<~'EOM') require "rails_helper" - RSpec.describe TelehealthAppointment, type: :model do - describe "#participants_state" do - context "timezones workaround" do - it "should receive a time in UTC format and return the time with the"\ - "office's UTC offset substracted from it" do + RSpec.describe Foo, type: :model do + describe "#bar" do + context "context" do + it "foos the bar with a foo and then bazes the foo with a bar to"\ + "fooify the barred bar" do travel_to DateTime.new(2020, 10, 1, 10, 0, 0) do - office = build(:office) + foo = build(:foo) end end end end - describe "#past?" do - context "more than 15 min have passed since appointment start time" do + describe "#baz?" do + context "baz has barred the foo" do it "returns true" do # <== HERE end end @@ -71,8 +71,8 @@ class Foo it "handles no spaces between blocks" do search = CodeSearch.new(<<~EOM) - context "timezones workaround" do - it "should receive a time in UTC format and return the time with the" do + context "foo bar" do + it "bars the foo" do travel_to DateTime.new(2020, 10, 1, 10, 0, 0) do end end