Skip to content

Extract values and add them to constants

What does this MR do and why?

This MR refactors the stop all jobs modal. It extracts all values and puts them into constant.js.

This is a partial MR of a larger featuer. All about it here.

A test implementation of this feature has already been made. How this MR should behave in the feature can be seen here.

Screenshots or screen recordings

Nothing should change in the UI but here is a photo for orientation:

image

image

How to set up and validate locally

  1. Prepare a job with either running or pending job, so the button stop all jobs will be visible in admin jobs area. (I am assuming you have a development environment with existing Ci jobs, no matter what status they have). Open console and type rails c
# rails c

job_pending = ::Ci::Build.first

job_pending.status = "pending"

job_pending.save
  1. Go to Admin > Jobs
  2. The Stop all jobs button should be visible. Click it.
  3. The modal should appear as expected and showed in the pictures above.

MR acceptance checklist

This checklist encourages us to confirm any changes have been analyzed to reduce risks in quality, performance, reliability, security, and maintainability.

Merge request reports