@@ -243,6 +243,15 @@ async def test_aio_params_context(self):
243243 Failed tests
244244 """
245245
246+ def test_wrong_captcha_type (self ):
247+ with pytest .raises (ValueError ):
248+ HCaptchaClassification (
249+ api_key = self .API_KEY ,
250+ captcha_type = self .get_random_string (),
251+ queries = [self .image_body ],
252+ question = self .question ,
253+ )
254+
246255 def test_no_queries (self ):
247256 with pytest .raises (TypeError ):
248257 HCaptchaClassification (
@@ -259,19 +268,6 @@ def test_no_question(self):
259268 queries = [self .image_body ],
260269 )
261270
262-
263- """
264- async def test_aio_api_key_err(self):
265- result = await HCaptchaClassification(
266- api_key=self.get_random_string(36),
267- captcha_type=self.captcha_type,
268- queries=[self.image_body],
269- question=self.question,
270- ).aio_captcha_handler()
271- assert result.errorId == 1
272- assert result.errorCode == "ERROR_KEY_DENIED_ACCESS"
273- assert not result.solution
274-
275271 def test_api_key_err (self ):
276272 result = HCaptchaClassification (
277273 api_key = self .get_random_string (36 ),
@@ -282,4 +278,3 @@ def test_api_key_err(self):
282278 assert result .errorId == 1
283279 assert result .errorCode == "ERROR_KEY_DENIED_ACCESS"
284280 assert not result .solution
285- """
0 commit comments