summaryrefslogtreecommitdiff
path: root/spec/features/dashboard/activity_spec.rb
diff options
context:
space:
mode:
Diffstat (limited to 'spec/features/dashboard/activity_spec.rb')
-rw-r--r--spec/features/dashboard/activity_spec.rb134
1 files changed, 67 insertions, 67 deletions
diff --git a/spec/features/dashboard/activity_spec.rb b/spec/features/dashboard/activity_spec.rb
index bf91dc121d8..7dd25b59886 100644
--- a/spec/features/dashboard/activity_spec.rb
+++ b/spec/features/dashboard/activity_spec.rb
@@ -1,13 +1,13 @@
-require 'spec_helper'
+require "spec_helper"
-describe 'Dashboard > Activity' do
+describe "Dashboard > Activity" do
let(:user) { create(:user) }
before do
sign_in(user)
end
- context 'rss' do
+ context "rss" do
before do
visit activity_dashboard_path
end
@@ -16,7 +16,7 @@ describe 'Dashboard > Activity' do
it_behaves_like "an autodiscoverable RSS feed with current_user's feed token"
end
- context 'event filters', :js do
+ context "event filters", :js do
let(:project) { create(:project, :repository) }
let(:merge_request) do
@@ -24,17 +24,17 @@ describe 'Dashboard > Activity' do
end
let(:note) { create(:note, project: project, noteable: merge_request) }
- let(:milestone) { create(:milestone, :active, project: project, title: '1.0') }
+ let(:milestone) { create(:milestone, :active, project: project, title: "1.0") }
let!(:push_event) do
event = create(:push_event, project: project, author: user)
create(:push_event_payload,
- event: event,
- action: :created,
- commit_to: '0220c11b9a3e6c69dc8fd35321254ca9a7b98f7e',
- ref: 'new_design',
- commit_count: 1)
+ event: event,
+ action: :created,
+ commit_to: "0220c11b9a3e6c69dc8fd35321254ca9a7b98f7e",
+ ref: "new_design",
+ commit_count: 1)
event
end
@@ -66,95 +66,95 @@ describe 'Dashboard > Activity' do
wait_for_requests
end
- it 'user should see all events' do
- within '.content_list' do
- expect(page).to have_content('pushed new branch')
- expect(page).to have_content('joined')
- expect(page).to have_content('accepted')
- expect(page).to have_content('closed')
- expect(page).to have_content('commented on')
- expect(page).to have_content('closed milestone')
+ it "user should see all events" do
+ within ".content_list" do
+ expect(page).to have_content("pushed new branch")
+ expect(page).to have_content("joined")
+ expect(page).to have_content("accepted")
+ expect(page).to have_content("closed")
+ expect(page).to have_content("commented on")
+ expect(page).to have_content("closed milestone")
end
end
- it 'user should see only pushed events' do
- click_link('Push events')
+ it "user should see only pushed events" do
+ click_link("Push events")
wait_for_requests
- within '.content_list' do
- expect(page).to have_content('pushed new branch')
- expect(page).not_to have_content('joined')
- expect(page).not_to have_content('accepted')
- expect(page).not_to have_content('closed')
- expect(page).not_to have_content('commented on')
+ within ".content_list" do
+ expect(page).to have_content("pushed new branch")
+ expect(page).not_to have_content("joined")
+ expect(page).not_to have_content("accepted")
+ expect(page).not_to have_content("closed")
+ expect(page).not_to have_content("commented on")
end
end
- it 'user should see only merged events' do
- click_link('Merge events')
+ it "user should see only merged events" do
+ click_link("Merge events")
wait_for_requests
- within '.content_list' do
- expect(page).not_to have_content('pushed new branch')
- expect(page).not_to have_content('joined')
- expect(page).to have_content('accepted')
- expect(page).not_to have_content('closed')
- expect(page).not_to have_content('commented on')
+ within ".content_list" do
+ expect(page).not_to have_content("pushed new branch")
+ expect(page).not_to have_content("joined")
+ expect(page).to have_content("accepted")
+ expect(page).not_to have_content("closed")
+ expect(page).not_to have_content("commented on")
end
end
- it 'user should see only issues events' do
- click_link('Issue events')
+ it "user should see only issues events" do
+ click_link("Issue events")
wait_for_requests
- within '.content_list' do
- expect(page).not_to have_content('pushed new branch')
- expect(page).not_to have_content('joined')
- expect(page).not_to have_content('accepted')
- expect(page).to have_content('closed')
- expect(page).not_to have_content('commented on')
- expect(page).to have_content('closed milestone')
+ within ".content_list" do
+ expect(page).not_to have_content("pushed new branch")
+ expect(page).not_to have_content("joined")
+ expect(page).not_to have_content("accepted")
+ expect(page).to have_content("closed")
+ expect(page).not_to have_content("commented on")
+ expect(page).to have_content("closed milestone")
end
end
- it 'user should see only comments events' do
- click_link('Comments')
+ it "user should see only comments events" do
+ click_link("Comments")
wait_for_requests
- within '.content_list' do
- expect(page).not_to have_content('pushed new branch')
- expect(page).not_to have_content('joined')
- expect(page).not_to have_content('accepted')
- expect(page).not_to have_content('closed')
- expect(page).to have_content('commented on')
+ within ".content_list" do
+ expect(page).not_to have_content("pushed new branch")
+ expect(page).not_to have_content("joined")
+ expect(page).not_to have_content("accepted")
+ expect(page).not_to have_content("closed")
+ expect(page).to have_content("commented on")
end
end
- it 'user should see only joined events' do
- click_link('Team')
+ it "user should see only joined events" do
+ click_link("Team")
wait_for_requests
- within '.content_list' do
- expect(page).not_to have_content('pushed new branch')
- expect(page).to have_content('joined')
- expect(page).not_to have_content('accepted')
- expect(page).not_to have_content('closed')
- expect(page).not_to have_content('commented on')
+ within ".content_list" do
+ expect(page).not_to have_content("pushed new branch")
+ expect(page).to have_content("joined")
+ expect(page).not_to have_content("accepted")
+ expect(page).not_to have_content("closed")
+ expect(page).not_to have_content("commented on")
end
end
- it 'user see selected event after page reloading' do
- click_link('Push events')
+ it "user see selected event after page reloading" do
+ click_link("Push events")
wait_for_requests
visit activity_dashboard_path
wait_for_requests
- within '.content_list' do
- expect(page).to have_content('pushed new branch')
- expect(page).not_to have_content('joined')
- expect(page).not_to have_content('accepted')
- expect(page).not_to have_content('closed')
- expect(page).not_to have_content('commented on')
+ within ".content_list" do
+ expect(page).to have_content("pushed new branch")
+ expect(page).not_to have_content("joined")
+ expect(page).not_to have_content("accepted")
+ expect(page).not_to have_content("closed")
+ expect(page).not_to have_content("commented on")
end
end
end