webdriver-wrapper: Wrapper around the webdriver package that automatically manages Selenium

[ browser, bsd3, geckodriver, library, selenium, testing, web, webdriver ] [ Propose Tags ] [ Report a vulnerability ]
Versions [RSS] 0.1.0.0, 0.1.0.1, 0.2.0.0, 0.2.0.1
Change log CHANGELOG.md
Dependencies aeson (>=2.1.2.1 && <2.3), async (>=2.2.5 && <2.3), base (>=4.7 && <5), bytestring (>=0.11.5 && <0.12), directory (>=1.3.8 && <1.4), extra (>=1.7.16 && <1.8), filepath (>=1.4.300 && <1.5), http-conduit (>=2.3.8 && <2.4), http-types (>=0.12.4 && <0.13), process (>=1.6.19 && <1.7), process-extras (>=0.7.4 && <0.8), retry (>=0.9.3 && <0.10), string-interpolate (>=0.3.3 && <0.4), tar (>=0.5.1.1 && <0.7), text (>=2.0.2 && <2.1), unix (>=2.8.4 && <2.9), unordered-containers (>=0.2.20 && <0.3), webdriver (>=0.12.0 && <0.13), zip-archive (>=0.4.3 && <0.5), zlib (>=0.6.3 && <0.8) [details]
License BSD-3-Clause
Copyright 2024 Gabriel Tollini
Author Gabriel Tollini
Maintainer gabrieltollini@hotmail.com
Category browser, selenium, testing, web, webdriver, geckodriver
Home page https://github.com/gtollini/webdriver-wrapper#readme
Bug tracker https://github.com/gtollini/webdriver-wrapper/issues
Source repo head: git clone https://github.com/gtollini/webdriver-wrapper
Uploaded by gtollini at 2024-07-04T17:48:22Z
Distributions NixOS:0.2.0.1, Stackage:0.2.0.1
Downloads 108 total (14 in the last 30 days)
Rating (no votes yet) [estimated by Bayesian average]
Your Rating
  • λ
  • λ
  • λ
Status Docs available [build log]
Last success reported on 2024-07-04 [all 1 reports]

Readme for webdriver-wrapper-0.1.0.0

[back to package description]

webdriver-wrapper

This package was created so end-users don't need to manually manage Selenium or their webdriver when dealing with the webdriver package. For now, only geckodriver (aka Firefox) is supported - but chromedriver should be easy to implement. If you can't use Firefox for whichever reason, let me know and I'll look into implementing chromedriver support.

This package is strongly inspired by sandwich-webdriver. My original use-case didn't require the sandwich test suite, though, so I made this package which intends on being simpler and more minimalistic.

Extra dependencies

You must have Java installed, since Selenium is distributed as a .jar file. I'm running OpenJDK 17 on my machine, and it works perfectly with the selected Selenium version.

How to use

There are two functions which are "batteries-included": wrappedRunSession and wrappedRunWD. Just use them as you would runSession and runWD. The wrapped functions will handle downloading Selenium and geckodriver (if they were not already downloaded), plus starting and stopping Selenium. If you already have some code with runSession or runWD, their wrapped counterparts are drop-in replacements.