summaryrefslogtreecommitdiff
path: root/features/steps
diff options
context:
space:
mode:
authorDmitriy Zaporozhets <dmitriy.zaporozhets@gmail.com>2015-03-09 14:25:14 -0700
committerDmitriy Zaporozhets <dmitriy.zaporozhets@gmail.com>2015-03-09 14:25:14 -0700
commitb8d73315f5e094906111ab16607b5fa2685d2ea8 (patch)
tree59accab7de0cd0cf97e1ac0f25f1eb5cc0eb5009 /features/steps
parentd36ee3190aa1fb8c1238967a3049d5b8271c9030 (diff)
downloadgitlab-ce-b8d73315f5e094906111ab16607b5fa2685d2ea8.tar.gz
Add tests for starred projects page
Diffstat (limited to 'features/steps')
-rw-r--r--features/steps/dashboard/starred_projects.rb15
-rw-r--r--features/steps/shared/paths.rb4
2 files changed, 19 insertions, 0 deletions
diff --git a/features/steps/dashboard/starred_projects.rb b/features/steps/dashboard/starred_projects.rb
new file mode 100644
index 00000000000..b9ad2f13e29
--- /dev/null
+++ b/features/steps/dashboard/starred_projects.rb
@@ -0,0 +1,15 @@
+class Spinach::Features::DashboardStarredProjects < Spinach::FeatureSteps
+ include SharedAuthentication
+ include SharedPaths
+ include SharedProject
+
+ step 'I starred project "Community"' do
+ current_user.toggle_star(Project.find_by(name: 'Community'))
+ end
+
+ step 'I should not see project "Shop"' do
+ within 'aside' do
+ page.should_not have_content('Shop')
+ end
+ end
+end
diff --git a/features/steps/shared/paths.rb b/features/steps/shared/paths.rb
index db6417bf951..bb6c336d7cd 100644
--- a/features/steps/shared/paths.rb
+++ b/features/steps/shared/paths.rb
@@ -95,6 +95,10 @@ module SharedPaths
current_path.should == dashboard_groups_path
end
+ step 'I visit dashboard starred projects page' do
+ visit starred_dashboard_projects_path
+ end
+
# ----------------------------------------
# Profile
# ----------------------------------------