how to test edge case errors

50 views
Skip to first unread message

Yurii Korotia

unread,
Dec 11, 2020, 9:25:56 AM12/11/20
to AdWords API and Google Ads API Forum
Hello

I have several edge cases I would like to test semi-automatically.. or even manually

1. AuthorizationErrorReason::CUSTOMER_NOT_ACTIVE
2. RateExceededError
3. DatabaseError

how do I test  such errors on test account? Maybe there is way to simulate it somehow.

regards

Google Ads API Forum Advisor Prod

unread,
Dec 14, 2020, 5:36:11 PM12/14/20
to yu...@clicktech.com, adwor...@googlegroups.com

Hi Yurii,

Thank you for reaching out. If you would like to test in an automatic fashion, you could utilize the testing framework. If you would like to do that manually, you would have to do it via the Google Ads UI. However, based on the nature of these errors, they are more appropriate to be tested via code.

Thanks and regards,
Xiaoming, Google Ads API Team
 

Google Logo
Xiaoming
Google Ads API Team
 


ref:_00D1U1174p._5004Q28pJGg:ref

Yurii Korotia

unread,
Dec 15, 2020, 4:21:03 AM12/15/20
to AdWords API and Google Ads API Forum
good morning

thank you for your answer.

yes, I did unit testing for it, but I was wondering to see real response from your servers, as you have sometimes errors in partialErrors property.
So, basically, I am curious if those errors are throws as exceptions or returned in partialErrors property too.

regards

Google Ads API Forum Advisor Prod

unread,
Dec 15, 2020, 11:07:28 PM12/15/20
to yu...@clicktech.com, adwor...@googlegroups.com
Hi Yurii,

Thank you for your email and follow up. Going back to the list of errors you wish to test out :


1. AuthorizationErrorReason::CUSTOMER_NOT_ACTIVE
2. RateExceededError
3. DatabaseError

Most of items #1 and #3's scenarios would not be possible using test accounts. As for the RateExceededError, you can refer here for more information on how these limits are encountered. You can test getting the rateScope = DEVELOPER by hitting the limits associated to a test account level access as stated here.

As for the rateScope = ACCOUNT, you may try and perform a high number of requests within a short period of time against a single Google Ads (test/production) account. 

For partial failures, you may refer to this documentation instead for the implementation. Please note as well that not all scenarios or errors in the supported services may be tested using test accounts.

Best regards,

Google Logo
Peter Laurence Napa Oliquino
Google Ads API Team
 


 

ref:_00D1U1174p._5004Q28pJGg:ref

Yurii Korotia

unread,
Dec 16, 2020, 4:23:41 AM12/16/20
to AdWords API and Google Ads API Forum
hello Peter

Yes, I know about those docs. Thank you for confirmation that I need to check those errors on production-like account. I will continue in that direction then.

You can close this topic. Thank you very much.

have a nice day!
Reply all
Reply to author
Forward
0 new messages