Skip to content

Instantly share code, notes, and snippets.

@olivierlacan
Last active February 28, 2023 14:35
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save olivierlacan/73b8a4bb0f229005da8d to your computer and use it in GitHub Desktop.
Save olivierlacan/73b8a4bb0f229005da8d to your computer and use it in GitHub Desktop.
Climate Control RSpec support helper
# in spec/support/climate_control.rb
module ClimateControlHelper
def with_modified_env(options, &block)
ClimateControl.modify(options, &block)
end
end
RSpec.configure do |config|
config.include(ClimateControlHelper)
end
@olivierlacan
Copy link
Author

@henrik
Copy link

henrik commented Feb 28, 2023

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment