Complete Hybrid Framework Implementation

In the previous section, we have built a thin slice and automated the login and logout and applied the concepts of page-object, data-driven and keyword-driven frameworks.

Now lets go ahead and complete the entire shopping cart experience here and build the page-objects connect them as per the behavior of the application.

It is assumed that you have Ruby, cucumber and selenium components set up on your machine already. If not, please follow the below links:

By the way, the entire project code base is already ready for checkout. If you do not know how to use github, please download a zip at the bottom right corner on the github page..

Download HybridFramework CodeBase

if you see “ampersand less than” symbol on this page, it is because of some formatting issue. It is basically “less than” symbol. I will try to fix it, for now, I don’t have a way.


  1. Revisit the workflow once again
  2. Write page-objects for all pages in the workflow
  3. Write Cucumber features – current one building on top of the previous one [That means you can run any feature independently, however will also be able to connect the dots once you execute them all]
  4. Write Step Definitions
  5. Execute them
  6. Go treat yourself



SummerDresses Catalog Page:


We also capture the pop up that appears after clicking add to cart on the “Printed Summer Dress



ShoppingCart Summary Page:



Address Page:

If you have a new account, then you will have more fields than what is shown on this page, however page-object has captured all just in case.



Shipping Page:



Payment Method Page:


Order Summary Page:



Order Confirmation Page:



Complete Cucumber Feature:

I am posting only the entire workflow scenario here, however if you check out the code base, the features are organized incrementally i.e. login.feature, then select product.feature, then checkout.feature and so on.

Step Definitions:

Execution and output:

The scenario should run all the way from login to order confirmation.

This completes our section on framework types. Please write to me [contact form on the right or] if you like this section. I will appreciate your feedback and further questions as I spent lot of time trying to make this presentable on website.

Shopping Cart Automated - page-object pattern