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

feat: Set default billing terms for missing info cache #4614

Merged

Conversation

zachaysan
Copy link
Contributor

Changes

This updates the billing period API usage to 30 day defaults for the current billing period and previous billing period.

How did you test this code?

Split a test into two separate tests and verified the mocked calls.

@zachaysan zachaysan requested a review from a team as a code owner September 10, 2024 14:38
@zachaysan zachaysan requested review from matthewelwell and removed request for a team September 10, 2024 14:38
Copy link

vercel bot commented Sep 10, 2024

The latest updates on your projects. Learn more about Vercel for Git ↗︎

3 Skipped Deployments
Name Status Preview Comments Updated (UTC)
docs ⬜️ Ignored (Inspect) Visit Preview Sep 16, 2024 6:33pm
flagsmith-frontend-preview ⬜️ Ignored (Inspect) Visit Preview Sep 16, 2024 6:33pm
flagsmith-frontend-staging ⬜️ Ignored (Inspect) Visit Preview Sep 16, 2024 6:33pm

@github-actions github-actions bot added api Issue related to the REST API feature New feature or request labels Sep 10, 2024
Copy link
Contributor

github-actions bot commented Sep 10, 2024

Docker builds report

Image Build Status Security report
ghcr.io/flagsmith/flagsmith-api-test:pr-4614 Finished ✅ Skipped
ghcr.io/flagsmith/flagsmith-frontend:pr-4614 Finished ✅ Results
ghcr.io/flagsmith/flagsmith-api:pr-4614 Finished ✅ Results
ghcr.io/flagsmith/flagsmith:pr-4614 Finished ✅ Results
ghcr.io/flagsmith/flagsmith-private-cloud:pr-4614 Finished ✅ Results

Copy link
Contributor

github-actions bot commented Sep 10, 2024

Uffizzi Preview deployment-56100 was deleted.

Copy link

codecov bot commented Sep 10, 2024

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 97.17%. Comparing base (1b22cf5) to head (0d2021d).
Report is 29 commits behind head on main.

Additional details and impacted files
@@           Coverage Diff            @@
##             main    #4614    +/-   ##
========================================
  Coverage   97.16%   97.17%            
========================================
  Files        1160     1162     +2     
  Lines       40137    40275   +138     
========================================
+ Hits        39000    39138   +138     
  Misses       1137     1137            

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@matthewelwell
Copy link
Contributor

I've read the description of this PR a few times and I can't make any sense of it? Can you reword it at all?

This updates the billing period API usage to 30 day defaults for the current billing period and previous billing period.

def test_get_usage_data_returns_empty_list_when_unset_subscription_information_cache(
period: str,
@pytest.mark.freeze_time("2023-01-19T09:09:47.325132+00:00")
def test_get_usage_data_returns_empty_list_when_unset_subscription_information_cache_for_previous_billing_period(
Copy link
Contributor

Choose a reason for hiding this comment

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

I think the name of this test (and the following one) needs updating to reflect the new behaviour?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Nice catch. Fixed.

@github-actions github-actions bot added feature New feature or request and removed feature New feature or request labels Sep 16, 2024
@matthewelwell matthewelwell added this pull request to the merge queue Sep 26, 2024
Merged via the queue into main with commit f9069e4 Sep 26, 2024
35 checks passed
@matthewelwell matthewelwell deleted the feat/set_default_billing_terms_for_missing_info_cache branch September 26, 2024 10:19
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
api Issue related to the REST API feature New feature or request
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants