-
Notifications
You must be signed in to change notification settings - Fork 28
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: Add GQL Invoice type with related resolvers #586
Conversation
Codecov ReportAttention: Patch coverage is
✅ All tests successful. No failed tests found.
Additional details and impacted files@@ Coverage Diff @@
## main #586 +/- ##
===========================================
Coverage 95.87000 95.87000
===========================================
Files 782 784 +2
Lines 17418 17499 +81
===========================================
+ Hits 16699 16778 +79
- Misses 719 721 +2
Flags with carried forward coverage won't be shown. Click here to find out more. ☔ View full report in Codecov by Sentry. |
Codecov ReportAttention: Patch coverage is ✅ All tests successful. No failed tests found.
📢 Thoughts on this report? Let us know! |
Codecov ReportAttention: Patch coverage is
✅ All tests successful. No failed tests found. @@ Coverage Diff @@
## main #586 +/- ##
==========================================
+ Coverage 91.42% 91.45% +0.03%
==========================================
Files 604 606 +2
Lines 16100 16181 +81
==========================================
+ Hits 14720 14799 +79
- Misses 1380 1382 +2
Flags with carried forward coverage won't be shown. Click here to find out more.
📣 Codecov offers a browser extension for seamless coverage viewing on GitHub. Try it in Chrome or Firefox today! |
Codecov ReportAttention: Patch coverage is
✅ All tests successful. No failed tests found @@ Coverage Diff @@
## main #586 +/- ##
==========================================
+ Coverage 91.42% 91.45% +0.03%
==========================================
Files 604 606 +2
Lines 16100 16181 +81
==========================================
+ Hits 14720 14799 +79
- Misses 1380 1382 +2
Flags with carried forward coverage won't be shown. Click here to find out more.
|
… the legacy plan name from mock
return invoice["customer_name"] | ||
|
||
|
||
# NOTE: This doesn't currently look to be used in gazebo, maybe can remove? |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Fine to remove these unused ones imo.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Gonna do all the gut removal stuff in a followup PR if that's aight
Purpose/Motivation
We want to convert REST endpoints -> GQL where it makes sense. This PR aims to tackle the API side of the /invoices endpoint, creating resolvers for the related models
Stripe invoice model can be found here: https://docs.stripe.com/api/invoices
Links to relevant tickets
Relates to codecov/engineering-team#1471
What does this PR do?
Aims to add Invoice Type to the owner model, and invoice resolvers for the new type created.
There are also some comments around some unused fields on the invoice model that we were returning from stripe, but don't seem to be used in Gazebo anywhere. These are definitely worth removing, since there isn't really a point in overfetching data atm.
The resolvers for the invoice model are fairly straightforward, we're just pulling off attributes from the invoice object being returned from the stripe API called in the invoice resolver on the owner model.
Notes to Reviewer
Legal Boilerplate
Look, I get it. The entity doing business as "Sentry" was incorporated in the State of Delaware in 2015 as Functional Software, Inc. In 2022 this entity acquired Codecov and as result Sentry is going to need some rights from me in order to utilize my contributions in this PR. So here's the deal: I retain all rights, title and interest in and to my contributions, and by keeping this boilerplate intact I confirm that Sentry can use, modify, copy, and redistribute my contributions, under Sentry's choice of terms.