debian-mirror-gitlab/spec/features/groups/labels/edit_spec.rb

22 lines
525 B
Ruby
Raw Normal View History

2017-08-17 22:00:37 +05:30
require 'spec_helper'
2017-09-10 17:25:29 +05:30
feature 'Edit group label' do
2017-08-17 22:00:37 +05:30
given(:user) { create(:user) }
given(:group) { create(:group) }
given(:label) { create(:group_label, group: group) }
background do
group.add_owner(user)
2017-09-10 17:25:29 +05:30
sign_in(user)
2017-08-17 22:00:37 +05:30
visit edit_group_label_path(group, label)
end
scenario 'update label with new title' do
fill_in 'label_title', with: 'new label name'
click_button 'Save changes'
expect(current_path).to eq(root_path)
expect(label.reload.title).to eq('new label name')
end
end