Commit d593c98fcbd34789068a72c9386f69a152107139
1 parent
1355ede4
Exists in
spb-stable
and in
2 other branches
Delete wall notes tests
Signed-off-by: Dmitriy Zaporozhets <dmitriy.zaporozhets@gmail.com>
Showing
12 changed files
with
0 additions
and
155 deletions
Show diff stats
features/project/active_tab.feature
| ... | ... | @@ -35,11 +35,6 @@ Feature: Project active tab |
| 35 | 35 | Then the active main tab should be Merge Requests |
| 36 | 36 | And no other main tabs should be active |
| 37 | 37 | |
| 38 | - Scenario: On Project Wall | |
| 39 | - Given I visit my project's wall page | |
| 40 | - Then the active main tab should be Wall | |
| 41 | - And no other main tabs should be active | |
| 42 | - | |
| 43 | 38 | Scenario: On Project Wiki |
| 44 | 39 | Given I visit my project's wiki page |
| 45 | 40 | Then the active main tab should be Wiki | ... | ... |
features/project/wall.feature
| ... | ... | @@ -1,16 +0,0 @@ |
| 1 | -Feature: Project Wall | |
| 2 | - In order to use Project Wall | |
| 3 | - A user should be able to read and write messages | |
| 4 | - | |
| 5 | - Background: | |
| 6 | - Given I sign in as a user | |
| 7 | - And I own project "Shop" | |
| 8 | - And I visit project "Shop" wall page | |
| 9 | - | |
| 10 | - @javascript | |
| 11 | - Scenario: Write comment | |
| 12 | - Given I write new comment "my special test message" | |
| 13 | - Then I should see project wall note "my special test message" | |
| 14 | - | |
| 15 | - Then I visit project "Shop" wall page | |
| 16 | - And I should see project wall note "my special test message" |
features/steps/project/wall.rb
| ... | ... | @@ -1,18 +0,0 @@ |
| 1 | -class ProjectWall < Spinach::FeatureSteps | |
| 2 | - include SharedAuthentication | |
| 3 | - include SharedProject | |
| 4 | - include SharedNote | |
| 5 | - include SharedPaths | |
| 6 | - | |
| 7 | - | |
| 8 | - Given 'I write new comment "my special test message"' do | |
| 9 | - within(".wall-note-form") do | |
| 10 | - fill_in "note[note]", with: "my special test message" | |
| 11 | - click_button "Add Comment" | |
| 12 | - end | |
| 13 | - end | |
| 14 | - | |
| 15 | - Then 'I should see project wall note "my special test message"' do | |
| 16 | - page.should have_content "my special test message" | |
| 17 | - end | |
| 18 | -end |
features/steps/shared/paths.rb
| ... | ... | @@ -204,10 +204,6 @@ module SharedPaths |
| 204 | 204 | visit project_merge_requests_path(@project) |
| 205 | 205 | end |
| 206 | 206 | |
| 207 | - step "I visit my project's wall page" do | |
| 208 | - visit project_wall_path(@project) | |
| 209 | - end | |
| 210 | - | |
| 211 | 207 | step "I visit my project's wiki page" do |
| 212 | 208 | visit project_wiki_path(@project, :home) |
| 213 | 209 | end |
| ... | ... | @@ -319,10 +315,6 @@ module SharedPaths |
| 319 | 315 | visit project_team_index_path(project) |
| 320 | 316 | end |
| 321 | 317 | |
| 322 | - step 'I visit project "Shop" wall page' do | |
| 323 | - visit project_wall_path(project) | |
| 324 | - end | |
| 325 | - | |
| 326 | 318 | step 'I visit project wiki page' do |
| 327 | 319 | visit project_wiki_path(@project, :home) |
| 328 | 320 | end | ... | ... |
spec/features/security/project/internal_access_spec.rb
| ... | ... | @@ -87,17 +87,6 @@ describe "Internal Project Access", feature: true do |
| 87 | 87 | it { should be_denied_for :visitor } |
| 88 | 88 | end |
| 89 | 89 | |
| 90 | - describe "GET /:project_path/wall" do | |
| 91 | - subject { project_wall_path(project) } | |
| 92 | - | |
| 93 | - it { should be_allowed_for master } | |
| 94 | - it { should be_allowed_for reporter } | |
| 95 | - it { should be_allowed_for :admin } | |
| 96 | - it { should be_allowed_for guest } | |
| 97 | - it { should be_allowed_for :user } | |
| 98 | - it { should be_denied_for :visitor } | |
| 99 | - end | |
| 100 | - | |
| 101 | 90 | describe "GET /:project_path/blob" do |
| 102 | 91 | before do |
| 103 | 92 | commit = project.repository.commit | ... | ... |
spec/features/security/project/private_access_spec.rb
| ... | ... | @@ -87,17 +87,6 @@ describe "Private Project Access", feature: true do |
| 87 | 87 | it { should be_denied_for :visitor } |
| 88 | 88 | end |
| 89 | 89 | |
| 90 | - describe "GET /:project_path/wall" do | |
| 91 | - subject { project_wall_path(project) } | |
| 92 | - | |
| 93 | - it { should be_allowed_for master } | |
| 94 | - it { should be_allowed_for reporter } | |
| 95 | - it { should be_allowed_for :admin } | |
| 96 | - it { should be_denied_for guest } | |
| 97 | - it { should be_denied_for :user } | |
| 98 | - it { should be_denied_for :visitor } | |
| 99 | - end | |
| 100 | - | |
| 101 | 90 | describe "GET /:project_path/blob" do |
| 102 | 91 | before do |
| 103 | 92 | commit = project.repository.commit | ... | ... |
spec/features/security/project/public_access_spec.rb
| ... | ... | @@ -92,17 +92,6 @@ describe "Public Project Access", feature: true do |
| 92 | 92 | it { should be_denied_for :visitor } |
| 93 | 93 | end |
| 94 | 94 | |
| 95 | - describe "GET /:project_path/wall" do | |
| 96 | - subject { project_wall_path(project) } | |
| 97 | - | |
| 98 | - it { should be_allowed_for master } | |
| 99 | - it { should be_allowed_for reporter } | |
| 100 | - it { should be_allowed_for :admin } | |
| 101 | - it { should be_allowed_for guest } | |
| 102 | - it { should be_allowed_for :user } | |
| 103 | - it { should be_allowed_for :visitor } | |
| 104 | - end | |
| 105 | - | |
| 106 | 95 | describe "GET /:project_path/blob" do |
| 107 | 96 | before do |
| 108 | 97 | commit = project.repository.commit | ... | ... |
spec/mailers/notify_spec.rb
| ... | ... | @@ -410,22 +410,6 @@ describe Notify do |
| 410 | 410 | end |
| 411 | 411 | end |
| 412 | 412 | |
| 413 | - describe 'on a project wall' do | |
| 414 | - let(:note_on_the_wall_path) { project_wall_path(project, anchor: "note_#{note.id}") } | |
| 415 | - | |
| 416 | - subject { Notify.note_wall_email(recipient.id, note.id) } | |
| 417 | - | |
| 418 | - it_behaves_like 'a note email' | |
| 419 | - | |
| 420 | - it 'has the correct subject' do | |
| 421 | - should have_subject /#{project.name}/ | |
| 422 | - end | |
| 423 | - | |
| 424 | - it 'contains a link to the wall note' do | |
| 425 | - should have_body_text /#{note_on_the_wall_path}/ | |
| 426 | - end | |
| 427 | - end | |
| 428 | - | |
| 429 | 413 | describe 'on a commit' do |
| 430 | 414 | let(:commit) { project.repository.commit } |
| 431 | 415 | ... | ... |
spec/requests/api/notes_spec.rb
| ... | ... | @@ -13,58 +13,8 @@ describe API::API, api: true do |
| 13 | 13 | let!(:issue_note) { create(:note, noteable: issue, project: project, author: user) } |
| 14 | 14 | let!(:merge_request_note) { create(:note, noteable: merge_request, project: project, author: user) } |
| 15 | 15 | let!(:snippet_note) { create(:note, noteable: snippet, project: project, author: user) } |
| 16 | - let!(:wall_note) { create(:note, project: project, author: user) } | |
| 17 | 16 | before { project.team << [user, :reporter] } |
| 18 | 17 | |
| 19 | - describe "GET /projects/:id/notes" do | |
| 20 | - context "when unauthenticated" do | |
| 21 | - it "should return authentication error" do | |
| 22 | - get api("/projects/#{project.id}/notes") | |
| 23 | - response.status.should == 401 | |
| 24 | - end | |
| 25 | - end | |
| 26 | - | |
| 27 | - context "when authenticated" do | |
| 28 | - it "should return project wall notes" do | |
| 29 | - get api("/projects/#{project.id}/notes", user) | |
| 30 | - response.status.should == 200 | |
| 31 | - json_response.should be_an Array | |
| 32 | - json_response.first['body'].should == wall_note.note | |
| 33 | - end | |
| 34 | - end | |
| 35 | - end | |
| 36 | - | |
| 37 | - describe "GET /projects/:id/notes/:note_id" do | |
| 38 | - it "should return a wall note by id" do | |
| 39 | - get api("/projects/#{project.id}/notes/#{wall_note.id}", user) | |
| 40 | - response.status.should == 200 | |
| 41 | - json_response['body'].should == wall_note.note | |
| 42 | - end | |
| 43 | - | |
| 44 | - it "should return a 404 error if note not found" do | |
| 45 | - get api("/projects/#{project.id}/notes/123", user) | |
| 46 | - response.status.should == 404 | |
| 47 | - end | |
| 48 | - end | |
| 49 | - | |
| 50 | - describe "POST /projects/:id/notes" do | |
| 51 | - it "should create a new wall note" do | |
| 52 | - post api("/projects/#{project.id}/notes", user), body: 'hi!' | |
| 53 | - response.status.should == 201 | |
| 54 | - json_response['body'].should == 'hi!' | |
| 55 | - end | |
| 56 | - | |
| 57 | - it "should return 401 unauthorized error" do | |
| 58 | - post api("/projects/#{project.id}/notes") | |
| 59 | - response.status.should == 401 | |
| 60 | - end | |
| 61 | - | |
| 62 | - it "should return a 400 bad request if body is missing" do | |
| 63 | - post api("/projects/#{project.id}/notes", user) | |
| 64 | - response.status.should == 400 | |
| 65 | - end | |
| 66 | - end | |
| 67 | - | |
| 68 | 18 | describe "GET /projects/:id/noteable/:noteable_id/notes" do |
| 69 | 19 | context "when noteable is an Issue" do |
| 70 | 20 | it "should return an array of issue notes" do | ... | ... |
spec/requests/api/projects_spec.rb
| ... | ... | @@ -126,7 +126,6 @@ describe API::API, api: true do |
| 126 | 126 | project = attributes_for(:project, { |
| 127 | 127 | description: Faker::Lorem.sentence, |
| 128 | 128 | issues_enabled: false, |
| 129 | - wall_enabled: false, | |
| 130 | 129 | merge_requests_enabled: false, |
| 131 | 130 | wiki_enabled: false |
| 132 | 131 | }) |
| ... | ... | @@ -208,7 +207,6 @@ describe API::API, api: true do |
| 208 | 207 | project = attributes_for(:project, { |
| 209 | 208 | description: Faker::Lorem.sentence, |
| 210 | 209 | issues_enabled: false, |
| 211 | - wall_enabled: false, | |
| 212 | 210 | merge_requests_enabled: false, |
| 213 | 211 | wiki_enabled: false |
| 214 | 212 | }) | ... | ... |
spec/routing/project_routing_spec.rb
| ... | ... | @@ -56,7 +56,6 @@ end |
| 56 | 56 | # projects POST /projects(.:format) projects#create |
| 57 | 57 | # new_project GET /projects/new(.:format) projects#new |
| 58 | 58 | # fork_project POST /:id/fork(.:format) projects#fork |
| 59 | -# wall_project GET /:id/wall(.:format) projects#wall | |
| 60 | 59 | # files_project GET /:id/files(.:format) projects#files |
| 61 | 60 | # edit_project GET /:id/edit(.:format) projects#edit |
| 62 | 61 | # project GET /:id(.:format) projects#show |
| ... | ... | @@ -75,10 +74,6 @@ describe ProjectsController, "routing" do |
| 75 | 74 | post("/gitlab/gitlabhq/fork").should route_to('projects#fork', id: 'gitlab/gitlabhq') |
| 76 | 75 | end |
| 77 | 76 | |
| 78 | - it "to #wall" do | |
| 79 | - get("/gitlab/gitlabhq/wall").should route_to('projects/walls#show', project_id: 'gitlab/gitlabhq') | |
| 80 | - end | |
| 81 | - | |
| 82 | 77 | it "to #edit" do |
| 83 | 78 | get("/gitlab/gitlabhq/edit").should route_to('projects#edit', id: 'gitlab/gitlabhq') |
| 84 | 79 | end | ... | ... |
spec/services/projects/create_service_spec.rb
| ... | ... | @@ -65,7 +65,6 @@ describe Projects::CreateService do |
| 65 | 65 | @settings.stub(:issues) { true } |
| 66 | 66 | @settings.stub(:merge_requests) { true } |
| 67 | 67 | @settings.stub(:wiki) { true } |
| 68 | - @settings.stub(:wall) { true } | |
| 69 | 68 | @settings.stub(:snippets) { true } |
| 70 | 69 | stub_const("Settings", Class.new) |
| 71 | 70 | @restrictions = double("restrictions") |
| ... | ... | @@ -108,7 +107,6 @@ describe Projects::CreateService do |
| 108 | 107 | @settings.stub(:issues) { true } |
| 109 | 108 | @settings.stub(:merge_requests) { true } |
| 110 | 109 | @settings.stub(:wiki) { true } |
| 111 | - @settings.stub(:wall) { true } | |
| 112 | 110 | @settings.stub(:snippets) { true } |
| 113 | 111 | @settings.stub(:visibility_level) { Gitlab::VisibilityLevel::PRIVATE } |
| 114 | 112 | stub_const("Settings", Class.new) | ... | ... |