debian-mirror-gitlab/spec/features/groups/settings/ci_cd_spec.rb

40 lines
809 B
Ruby
Raw Normal View History

2018-12-05 23:21:45 +05:30
# frozen_string_literal: true
require 'spec_helper'
describe 'Group CI/CD settings' do
include WaitForRequests
2019-05-30 16:15:17 +05:30
let(:user) {create(:user)}
let(:group) {create(:group)}
2018-12-05 23:21:45 +05:30
before do
group.add_owner(user)
sign_in(user)
end
describe 'runners registration token' do
let!(:token) { group.runners_token }
before do
visit group_settings_ci_cd_path(group)
end
it 'has a registration token' do
expect(page.find('#registration_token')).to have_content(token)
end
describe 'reload registration token' do
let(:page_token) { find('#registration_token').text }
before do
click_button 'Reset runners registration token'
end
it 'changes registration token' do
expect(page_token).not_to eq token
end
end
end
end