crystal-loot / selenium.cr

Selenium library for Crystal
https://crystal-loot.github.io/selenium.cr/
MIT License
24 stars 7 forks source link

Add new manager to interact with WebStorage #29

Closed Dakad closed 1 year ago

Dakad commented 1 year ago

Fixes #19

Description

Little change to allow access to the LocalStorage and SessionStorage. The WebStorage is accessible via HTTP endpoints, so we send a JS script for the browser to run. The code structure is heavily inspired by what is done on https://github.com/SeleniumHQ/selenium/blob/de7acb9099f42f8aaa1a4f7bf5d00e3c102947ae/rb/lib/selenium/webdriver/remote/bridge.rb#L278

How it was tested?

Locally by running headless Firefox