Commit fc99ed95 authored by Paul Slaughter's avatar Paul Slaughter

Add spec for edit board name

parent 4dcb1599
......@@ -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