November 11, 2015

How to perform automated testing for an eCommerce application?

Are you an automated tester writing tests for the eCommerce application at your company?

If so... Do you feel like comparing notes? I'm new to the world of automation. I've only been doing it since March of this year, and I would love to compare and contrast what your world is like. 

For automation, at work we use:

Automation Framework

Selenium WebDriver 2: A library that opens browsers, inspect web elements such as text boxes, dropdown listboxes, radio buttons, alert messages, buttons, and manipulated them. Easy to learn. 

Programming Language

Java 7 (soon upgrading to Java 8). Using Object Oriented Programming design to make sure that the tests and test framework is DRY? A bit harder to learn. YAGNI? Easy. SOLID? Much harder to learn. 

Test Framework: 

Test NG

Continuous Integration System


Virtual Test Machines

Sauce Labs

Software Development Methodology: 

Agile, two week sprints

Integrated Development Environment (IDE)

IntelliJ, Enterprise Edition

What we are Automating:

We developed our own shopping cart and admin portal so we can be more in tune with our business needs. If anything goes wrong with our order system, we can do a very quick turnaround time fixing any problems. 

How we work with the Development Team: 

The software testing team is embedded in the eCommerce team, both automation and manual. The entire eCommerce team attends the same sprint planning, daily scrum, and sprint retrospective, keeping us aligned with the entire team.   
Automation has its own Sprint, a secondary sprint planning, with the QA Manager as the Product Owner, grooming, prioritizing, and adding stories to our backlog. This helps keep both testing teams aligned. 

Our Test Development Process:

  • TestRail: Our entire automation test suite is data driven, from our hourly tests to our full regression test suite. Each test is a row that can be dragged-and-dropped into different categories. 
  • Automated Tests: Each test is linked in our Java codebase to a TestNG @Test annotated with the JIRA ticket number. Each test is comprised of actions to navigate to certain pages, groups of actions to get and compare data, and assert statements on what we are testing. Asserts should only go in the actual automated test. 
  • Actions classes: Need to Login()? FillAnOrder()? FillBillingAndShipping()? We have actions for that. If you are doing something special the first time around, it may be fine if you keep it in the @Test class, but if you are doing the same series of steps more than once, refactor it all out and put it in the actions class. 
  • Page Objects: Each page of our site has its own Java class, a Page Object, making the locators of each and every web element, from dropdown listboxes to textboxes and buttons easy to find. This should be the only place where we interact with a web page, from the Document Object Model (DOM).
  • Web Elements: We use CSS Selectors to find the elements on a web page. We found that Ids can change easily. The position of a web element also can change, ruling out XPath. To help us in our automation, we have web elements embedded with a value called "data-qa". Need to find that Free Shipping Level Radio button? It is at the very top of the corresponding page object and is:
private final By FREE_SHIPPING_LEVEL = By.cssSelector("[data-qa='shipping-level-free']");

Future Plans for the Automation Team:

With only three people on the automation team, we are finding that we can barely keep up with the backlog of automating new stuff just added to the regression test suite, and at the same time refactoring our old stuff, making the tests more robust. Maybe we could build on the actions classes and use Cucumber-JVM, so other developers and other QA Engineers can can build the individual tests, while our team focuses on building out tools? Or should we go the keyword driven approach?

I joked with my manager... if only we could contact Amazon and see what automation tools and techniques they use to test their eCommerce application. He mentioned... well, there is LinkedIn and Twitter!

... So, do you test an eCommerce application, such as a shopping cart? What is your automation team like where you work? What tools do you use? How are tests structured? And have you gone the Behavior Driven route, such as with Cucumber? Or did you opt for a more Keyword driven approach?

More Fitbit-Boston related articles on this blog:

-T.J. Maher
 Sr. QA Engineer, Fitbit
 // Manual tester, 15 years
 // Automated tester for [ 9 ] months and counting

Please note: 'Adventures in Automation' is a personal blog about automated testing. It is not an official blog of


Joe Lie said...

I did not know much about it but now I have learned a lot from it. I share it with my all friends and We can find out more about it thank you for sharing it If you need help with your assignment so visit writing report service

Spencer L. Watson said...

I look forward to seeing your new posts every day. I think many people like your article. Thanks for sharing these remarkable things. Please continue to uphold! Mens Yellowstone Jackets And Coats Buy

ZoeyWinston said...

Both automated and manual software testing is included into the eCommerce team. The daily scrum, sprint retrospective, Assignment Writing Service and sprint planning meetings are all attended by the whole eCommerce team, which keeps everyone on the same page.

Will Steven said...

Our experienced Divorce Lawyers Northern Virginia offers you legal represent and guidance for divorce cases

charloteequeen said...

"Mastering the art of automated testing opens up a realm of possibilities for efficiency and precision in software development. Your 'How to Perform Automated Testing' guide is a gem, providing a roadmap for quality assurance that every developer should bookmark.divorce lawyers elmira new york The step-by-step approach, insightful tips, and emphasis on best practices make it an invaluable resource. Here's to streamlining workflows and ensuring robust, bug-free code! 🚀🤖 #AutomationExcellence #CodeQuality"

KirstenSmallT said...

Looking for a Bank Ruptcy Lawyer Near Me? Our skilled team is provide a legal lawyer.

Unknown said...

To defend your rights if you're charged with a sexual offense in Northern Virginia, get in touch with a knowledgeable sex crime attorney. They can offer a solid defense and legal advice because of their shown experience.
Sex Crime Lawyer Northern Virginia

Unknown said...

Protective orders, which offer legal protection from abuse, are expressly designed to address domestic concerns in Virginia. With their wider application, restraining orders can be used to stop harassment or unwelcome contact in a variety of circumstances.
protective order vs restraining order virginia