@@ -75,6 +75,40 @@ public static function responseProvider()
7575 ),
7676 'exception ' => new \Github \Exception \ApiLimitExceedException (5000 ),
7777 ],
78+ 'Rate Limit Exceeded via 403 status ' => [
79+ 'response ' => new Response (
80+ 403 ,
81+ [
82+ 'Content-Type ' => 'application/json ' ,
83+ 'X-RateLimit-Remaining ' => 0 ,
84+ 'X-RateLimit-Limit ' => 5000 ,
85+ 'X-RateLimit-Reset ' => 1609245810 ,
86+ ],
87+ json_encode (
88+ [
89+ 'message ' => 'API rate limit exceeded for installation ID xxxxxxx. ' ,
90+ ]
91+ )
92+ ),
93+ 'exception ' => new \Github \Exception \ApiLimitExceedException (5000 ),
94+ ],
95+ 'Secondary Rate Limit Exceeded via 403 status ' => [
96+ 'response ' => new Response (
97+ 403 ,
98+ [
99+ 'Content-Type ' => 'application/json ' ,
100+ 'X-RateLimit-Remaining ' => 100 ,
101+ 'X-RateLimit-Limit ' => 5000 ,
102+ 'X-RateLimit-Reset ' => 1609245810 ,
103+ ],
104+ json_encode (
105+ [
106+ 'message ' => 'You have exceeded a secondary rate limit. Please wait a few minutes before you try again. ' ,
107+ ]
108+ )
109+ ),
110+ 'exception ' => new \Github \Exception \ApiLimitExceedException (5000 ),
111+ ],
78112 'Two Factor Authentication Required ' => [
79113 'response ' => new Response (
80114 401 ,
0 commit comments