Skip to content

Add `seats_in_use` to GitlabSubscriptionHistory tracked attributes

What does this MR do and why?

This implements https://gitlab.com/gitlab-org/gitlab/-/issues/468885, where we want to add seats_in_use to tracked attributes in GitlabSubscriptionHistory:

MR acceptance checklist

Please evaluate this MR against the MR acceptance checklist. It helps you analyze changes to reduce risks in quality, performance, reliability, security, and maintainability.

Screenshots or screen recordings

N/A

How to set up and validate locally

  1. Have a group with a subscription. Make note of the group ID
  2. Open rails console
  3. Grab the subscription subscription = GitlabSubscription.where(namespace_id: 113)[0]
  4. Change the amount of seats in use subscription.seats_in_use = 4
  5. Make sure it has changed by looking at the change array subscription.changed
  6. Save the new value subscription.save!
  7. Make sure there's a new record in the subscription history and that it includes seats_in_use: GitlabSubscriptionHistory.last
Edited by Sheldon Led

Merge request reports