This is an exercise where I've implemented a basic Cucumber test framework using watir-webdriver and page object model. In this exercise I'm performing some tests on some well known websites. I've used the page-object gem for easy implementation of page object model.
- Ruby 2.3.1
- Bundler gem
- Firefox 46 or 47.0.1, but not 47.
Ruby can be installed following the instructions on its website
To install Bundler gem + other gem dependencies:
make env
To execute all the tests in this repo and generate HTML report
make test
To install gem dependencies and run all tests
make all
To run features in parallel
make parallel
More options can be found in the Makefile.
- Not using backgrounds as scenarios are small enough so it wouldn’t make much of a difference.
- Not using scenario outlines as I didn’t see the need since I’m not testing several similar test cases with different inputs and outputs.
- Not using headless mode (at this point) as I wanted to see the tests executing.
- Not using config files to set up hosts or timeouts at this point as it wasn't necessary for the bare bones version.
- Not sure about best location for pages. They're living in a lib folder for now.
- Implementing my own page objects without the need for the page-object gem.
- Implementing option to run in PhantomJS.