-
Notifications
You must be signed in to change notification settings - Fork 318
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
fix : add error handler for addProduct and addBillingPlan from subscription helper #623
Conversation
add white space end of file
Feat/subscriptions
…er was successful or not.
…on helper was successful or not.
Codecov ReportAll modified and coverable lines are covered by tests ✅
❗ Your organization needs to install the Codecov GitHub app to enable full functionality. Additional details and impacted files@@ Coverage Diff @@
## v3.0 #623 +/- ##
============================================
+ Coverage 96.46% 96.48% +0.01%
- Complexity 268 270 +2
============================================
Files 34 34
Lines 1133 1139 +6
============================================
+ Hits 1093 1099 +6
Misses 40 40 ☔ View full report in Codecov by Sentry. |
…ing_plan and it_throws_exception_when_get_error_for_creating_a_product
@@ -255,6 +255,52 @@ public function it_throws_exception_when_invalid_interval_is_provided_for_creati | |||
$this->client = $this->client->addCustomPlan('Demo Plan', 'Demo Plan', 100, 'MONTHLY', 3); | |||
} | |||
|
|||
/** @test */ | |||
public function it_throws_exception_when_get_error_for_creating_a_billing_plan() |
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.
Method name AdapterCreateSubscriptionHelpersTest::it_throws_exception_when_get_error_for_creating_a_billing_plan
is not in camel caps format
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.
@srmklive should I rename it to camelCase format ? I see other code using snake_case
} | ||
|
||
/** @test */ | ||
public function it_throws_exception_when_get_error_for_creating_a_product() |
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.
Method name AdapterCreateSubscriptionHelpersTest::it_throws_exception_when_get_error_for_creating_a_product
is not in camel caps format
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.
@srmklive should I rename it to camelCase format ? I see other code using snake_case
This makes it easier for developers to track where errors occur.
Currently it only displays the message
"Undefined key id".
This occurs because an error occurred while making a request to the PayPal API.
which resulted in
product
properties andbilling_plan
not storing data properly.So. we need to check before store response data to
product
properties andbilling_plan