Welcome to mirror list, hosted at ThFree Co, Russian Federation.

gitlab.com/gitlab-org/gitlab-foss.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
Diffstat (limited to 'spec/support/matchers/access_matchers.rb')
-rw-r--r--spec/support/matchers/access_matchers.rb4
1 files changed, 2 insertions, 2 deletions
diff --git a/spec/support/matchers/access_matchers.rb b/spec/support/matchers/access_matchers.rb
index c9ff777f604..cf97e66fcba 100644
--- a/spec/support/matchers/access_matchers.rb
+++ b/spec/support/matchers/access_matchers.rb
@@ -52,7 +52,7 @@ module AccessMatchers
emulate_user(user, @membership)
visit(url)
- status_code == 200 && current_path != new_user_session_path
+ status_code == 200 && !current_path.in?([new_user_session_path, new_admin_session_path])
end
chain :of do |membership|
@@ -67,7 +67,7 @@ module AccessMatchers
emulate_user(user, @membership)
visit(url)
- [401, 404].include?(status_code) || current_path == new_user_session_path
+ [401, 404].include?(status_code) || current_path.in?([new_user_session_path, new_admin_session_path])
end
chain :of do |membership|