@@ -512,7 +512,7 @@ class TestWebElementScreenshot:
512512 """Test screenshot functionality."""
513513
514514 @pytest .mark .asyncio
515- async def test_get_screenshot_success (self , web_element , tmp_path ):
515+ async def test_take_screenshot_success (self , web_element , tmp_path ):
516516 """Test successful element screenshot."""
517517 bounds = {'x' : 10 , 'y' : 20 , 'width' : 100 , 'height' : 50 }
518518 screenshot_data = 'iVBORw0KGgoAAAANSUhEUgAAAAEAAAABCAQAAAC1HAwCAAAAC0lEQVR42mP8/wcAAgAB/edzE+oAAAAASUVORK5CYII='
@@ -530,13 +530,13 @@ async def test_get_screenshot_success(self, web_element, tmp_path):
530530
531531 with patch ('aiofiles.open' ) as mock_aiofiles_open :
532532 mock_aiofiles_open .return_value .__aenter__ .return_value = mock_file
533- await web_element .get_screenshot (str (screenshot_path ), quality = 90 )
533+ await web_element .take_screenshot (str (screenshot_path ), quality = 90 )
534534
535535 # Should call get_bounds_using_js and capture_screenshot
536536 assert web_element ._connection_handler .execute_command .call_count == 2
537537
538538 @pytest .mark .asyncio
539- async def test_get_screenshot_default_quality (self , web_element , tmp_path ):
539+ async def test_take_screenshot_default_quality (self , web_element , tmp_path ):
540540 """Test screenshot with default quality."""
541541 bounds = {'x' : 0 , 'y' : 0 , 'width' : 50 , 'height' : 50 }
542542 screenshot_data = 'iVBORw0KGgoAAAANSUhEUgAAAAEAAAABCAQAAAC1HAwCAAAAC0lEQVR42mP8/wcAAgAB/edzE+oAAAAASUVORK5CYII='
@@ -553,7 +553,7 @@ async def test_get_screenshot_default_quality(self, web_element, tmp_path):
553553
554554 with patch ('aiofiles.open' ) as mock_aiofiles_open :
555555 mock_aiofiles_open .return_value .__aenter__ .return_value = mock_file
556- await web_element .get_screenshot (str (screenshot_path ))
556+ await web_element .take_screenshot (str (screenshot_path ))
557557
558558 # Should call get_bounds_using_js and capture_screenshot
559559 assert web_element ._connection_handler .execute_command .call_count == 2
0 commit comments