Commit bb81647e authored by Mike Greiling's avatar Mike Greiling

Merge branch '6377-fix-issue-board-edit' into 'master'

Resolve "'Edit board' does not work and error in console"

Closes #6377

See merge request gitlab-org/gitlab-ee!6081
parents e2b818fc fc99ed95
......@@ -42,6 +42,6 @@
":project-id" => "Number(#{@project&.id})",
":group-id" => "Number(#{@group&.id})",
":can-admin-board" => can?(current_user, :admin_board, parent),
":scoped-issue-board-feature-enabled" => parent.feature_available?(:scoped_issue_board),
":scoped-issue-board-feature-enabled" => parent.feature_available?(:scoped_issue_board) ? 'true' : 'false',
"weights" => [Issue::WEIGHT_ANY] + Issue.weight_options,
"v-if" => "currentPage" }
......@@ -5,12 +5,12 @@ describe 'issue boards', :js do
let(:project) { create(:project, :public) }
let!(:board) { create(:board, project: project) }
before do
project.add_developer(user)
login_as(user)
end
context 'issue board focus mode' do
before do
project.add_developer(user)
login_as(user)
end
it 'shows the button when the feature is enabled' do
stub_licensed_features(issue_board_focus_mode: true)
......@@ -28,6 +28,30 @@ describe 'issue boards', :js do
end
end
context 'with group and reporter' do
let(:group) { create(:group) }
let(:project) { create(:project, :public, namespace: group) }
before do
project.add_master(user)
group.add_reporter(user)
login_as(user)
end
it 'can edit board name' do
visit_board_page
board_name = board.name
new_board_name = board_name + '-Test'
click_button 'Edit board'
fill_in 'board-new-name', with: new_board_name
click_button 'Save changes'
expect(page).to have_content new_board_name
end
end
def visit_board_page
visit project_boards_path(project)
wait_for_requests
......
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