Commit 8efa88a3 authored by Phil Hughes's avatar Phil Hughes

Fixed feature spec not waiting for ajax request to finish

Fixed 404 in project milestones when not logged in
parent 79c7188a
...@@ -8,7 +8,7 @@ class Projects::MilestonesController < Projects::ApplicationController ...@@ -8,7 +8,7 @@ class Projects::MilestonesController < Projects::ApplicationController
before_action :authorize_read_milestone! before_action :authorize_read_milestone!
# Allow admin milestone # Allow admin milestone
before_action :authorize_admin_milestone!, except: [:index, :show] before_action :authorize_admin_milestone!, except: [:index, :show, :merge_requests, :participants, :labels]
respond_to :html respond_to :html
......
...@@ -86,6 +86,9 @@ describe 'Milestone draggable', feature: true, js: true do ...@@ -86,6 +86,9 @@ describe 'Milestone draggable', feature: true, js: true do
visit namespace_project_milestone_path(project.namespace, project, milestone) visit namespace_project_milestone_path(project.namespace, project, milestone)
page.find("a[href='#tab-merge-requests']").click page.find("a[href='#tab-merge-requests']").click
wait_for_ajax
scroll_into_view('.milestone-content') scroll_into_view('.milestone-content')
drag_to(selector: '.merge_requests-sortable-list', list_to_index: 1) drag_to(selector: '.merge_requests-sortable-list', list_to_index: 1)
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment