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:
authorVitaliy @blackst0ne Klachkov <blackst0ne.ru@gmail.com>2017-09-22 06:29:19 +0300
committerVitaliy @blackst0ne Klachkov <blackst0ne.ru@gmail.com>2017-09-22 06:29:19 +0300
commit0ed3d8a07b997651df5f2b18b11bb1e0cb1c74de (patch)
tree26944f4126c74644dc4f1aa772bc5745b0d1b94f /spec/support/matchers
parent92173ac55cd921a65ce137e238ed8bc4474aaccb (diff)
Replace the 'project/shortcuts.feature' spinach test with an rspec analog
Diffstat (limited to 'spec/support/matchers')
-rw-r--r--spec/support/matchers/navigation_matcher.rb6
1 files changed, 6 insertions, 0 deletions
diff --git a/spec/support/matchers/navigation_matcher.rb b/spec/support/matchers/navigation_matcher.rb
index 5b6d9c1a4df..63f59b9654c 100644
--- a/spec/support/matchers/navigation_matcher.rb
+++ b/spec/support/matchers/navigation_matcher.rb
@@ -4,3 +4,9 @@ RSpec::Matchers.define :have_active_navigation do |expected|
expect(page.find('.sidebar-top-level-items > li.active')).to have_content(expected)
end
end
+
+RSpec::Matchers.define :have_active_sub_navigation do |expected|
+ match do |page|
+ expect(page.find('.sidebar-sub-level-items > li.active:not(.fly-out-top-item)')).to have_content(expected)
+ end
+end