https://github.com/sridharbandi/selenium-ruby-template
Selenium Ruby Unit Test Template with Page Object Model
https://github.com/sridharbandi/selenium-ruby-template
page-object-model ruby selenium unittest webdriver webdrivermanager
Last synced: 6 months ago
JSON representation
Selenium Ruby Unit Test Template with Page Object Model
- Host: GitHub
- URL: https://github.com/sridharbandi/selenium-ruby-template
- Owner: sridharbandi
- Created: 2018-06-03T20:00:01.000Z (over 7 years ago)
- Default Branch: master
- Last Pushed: 2018-06-03T21:09:48.000Z (over 7 years ago)
- Last Synced: 2025-04-11T05:06:02.560Z (6 months ago)
- Topics: page-object-model, ruby, selenium, unittest, webdriver, webdrivermanager
- Language: Ruby
- Homepage:
- Size: 14.6 KB
- Stars: 4
- Watchers: 1
- Forks: 1
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
## Selenium Ruby Unit Test Template with Page Object Model
To automate [Selenium Webdriver](https://docs.seleniumhq.org/projects/webdriver/) binaries management in runtime am using [webdrivermanager](https://github.com/jeffnyman/webdriver_manager), an excellent library by [jeffnyman](https://github.com/jeffnyman)
### How to use?
Create the Page Objects of your Web application under **_lib/pageobjects_** package, call those Page Objects in tests under **_test_** package (Sample Page Objects, testcase included in this template)### How to run?
To install the dependencies issue the below command in project root directory
```javascript
bundler install
```
To run the tests issue the below commands in project root directory
```javascript
ruby -Ilib:test test/my_test.rb
```
By default it runs in Chrome browser, you can specify which browser to use as well
```javascript
ruby -Ilib:test test/my_test.rb firefox
```
Currently browsers added in this template are
* chrome
* firefox
* edge
* ie> Feel free to modify it to your own needs :)