diff options
Diffstat (limited to 'spec/features/projects/services/user_activates_slack_slash_command_spec.rb')
-rw-r--r-- | spec/features/projects/services/user_activates_slack_slash_command_spec.rb | 9 |
1 files changed, 3 insertions, 6 deletions
diff --git a/spec/features/projects/services/user_activates_slack_slash_command_spec.rb b/spec/features/projects/services/user_activates_slack_slash_command_spec.rb index 4ce1acd9377..05f1a0c6b17 100644 --- a/spec/features/projects/services/user_activates_slack_slash_command_spec.rb +++ b/spec/features/projects/services/user_activates_slack_slash_command_spec.rb @@ -3,13 +3,10 @@ require 'spec_helper' describe 'Slack slash commands' do - let(:user) { create(:user) } - let(:project) { create(:project) } + include_context 'project service activation' before do - project.add_maintainer(user) - sign_in(user) - visit edit_project_service_path(project, :slack_slash_commands) + visit_project_integration('Slack slash commands') end it 'shows a token placeholder' do @@ -24,7 +21,7 @@ describe 'Slack slash commands' do it 'redirects to the integrations page after saving but not activating', :js do fill_in 'service_token', with: 'token' - find('input[name="service[active]"] + button').click + click_active_toggle click_on 'Save' expect(current_path).to eq(project_settings_integrations_path(project)) |