Skip to content

Commit

Permalink
scroll to the end of the page
Browse files Browse the repository at this point in the history
  • Loading branch information
Dou Du committed May 29, 2024
1 parent fb373ef commit cf365e1
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion test/test.py
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ def download_widget_image(self):
self.driver.set_window_size(1280, 1080)
time.sleep(3)
self.driver.save_screenshot("widget-01.png")
self.driver.execute_script("window.scrollTo(0, 1000)")
self.driver.execute_script("window.scrollTo(0,document.body.scrollHeight)")
time.sleep(3)
self.driver.save_screenshot("widget-02.png")

Expand Down

0 comments on commit cf365e1

Please sign in to comment.