Add multitenancy with apartment
Co-Authored-By: Javi Martín <javim@elretirao.net>
This commit is contained in:
committed by
Javi Martín
parent
fcd8466ddf
commit
382abb3666
@@ -65,3 +65,14 @@ Capybara.enable_aria_label = true
|
||||
Capybara.disable_animation = true
|
||||
|
||||
OmniAuth.config.test_mode = true
|
||||
|
||||
def with_subdomain(subdomain, &block)
|
||||
app_host = Capybara.app_host
|
||||
|
||||
begin
|
||||
Capybara.app_host = "http://#{subdomain}.lvh.me"
|
||||
block.call
|
||||
ensure
|
||||
Capybara.app_host = app_host
|
||||
end
|
||||
end
|
||||
|
||||
Reference in New Issue
Block a user