Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Issue #5359 - Extend utility scripts to find out quota and its usage #5390

Open
wants to merge 17 commits into
base: staging
Choose a base branch
from

Conversation

jacobcons
Copy link

@jacobcons jacobcons commented Feb 4, 2025

This fixes #5359

Description

  • For each license in the output of allExpiredLicenses and allActiveLicenses scripts, include data quota usage, and license count data for the teamspace the license belongs to
  • Fixed a bug in which allExpiredLicenses would include active licenses as long as it belongs to a teamspace with at least one expired license (and made a similar fix for allActiveLicenses)
  • Fixed a bug in which quotaInfo includes licenses of an invalid type
  • gitignore .idea/

Test cases

  • Updated tests for allExpiredLicenses and allActiveLicenses scripts, ensuring it's seeded with teamspaces that contain multiple licenses
  • Created tests for getTeamspaceValidLicenses, extractTeamspaceActiveLicenses and extractTeamspaceExpiredLicenses
  • Updated testSufficientQuota test to mock a db result of the correct format

@jacobcons jacobcons changed the title Issue 5359 - Extend utility scripts to find out quota and its usage Issue #5359 - Extend utility scripts to find out quota and its usage Feb 4, 2025
@jacobcons
Copy link
Author

@carmenfan Just tagging you here because I can't request a review without write access to the repo 😄

@carmenfan
Copy link
Member

@jacobcons all good, I saw it. Just a bit preoccupied to have a look! Thank you for contributing 😄

@jacobcons
Copy link
Author

@carmenfan No worries at all! 😄

@carmenfan carmenfan self-assigned this Feb 10, 2025
Copy link
Member

@carmenfan carmenfan left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It's failing test coverage, any chance you can have a look? (If not don't worry, we can take over when a member of the team have capacity)
image

You should be able to run the full test suite by running yarn test:v5 (only external dependency is a rabbitmq service)

jacobcons and others added 3 commits February 12, 2025 11:53
…scriptions and defaults, add tests for full coverage, refactoring of teamspacesetting license functions to be a bit more efficient
@jacobcons
Copy link
Author

@carmenfan Should all be good now 😄

@jacobcons jacobcons requested a review from carmenfan February 18, 2025 11:02
@jacobcons
Copy link
Author

Hey @carmenfan, just following up on this PR. Would love to get your thoughts when you have a chance.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants