-
Notifications
You must be signed in to change notification settings - Fork 388
[wip] typed param example #680
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
[wip] typed param example #680
Conversation
mickjermsurawong-stripe
commented
Feb 19, 2019
- This is illustrative PR to explain Basic primitives for typed params #679
- Please see the tests using the typed params in commit with message prefixed with "test:..."
|
|
||
| @Test | ||
| public void testCreateWithParams() throws StripeException { | ||
| SkuCreateParams.Inventory inventory = SkuCreateParams.Inventory.builder() |
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.
Inner inventory object passed as argument to the parent param builder.
| verifyRequest( | ||
| ApiResource.RequestMethod.POST, | ||
| String.format("/v1/invoices/%s", invoice.getId()), | ||
| paramsWithEmpty |
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.
Verify that "EMPTY" enums are serialized as nulls
| .addExpand("review") | ||
| .addExpand("source") | ||
| .addExpand("transfer_data.destination") | ||
| .build(); |
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.
Basic expand params
2e0e183 to
a648412
Compare
|
OMG this is freaking awesome. Everyone using stripe-java is going to love you for this, haha. |
|
thanks @brandur-stripe! :) |
b5c3ee3 to
f22e048
Compare
a648412 to
f85f773
Compare
f85f773 to
793b24a
Compare
4add333 to
a2e28d2
Compare