Assertion chaining with Hamcrest

5.0 02 In some cases we want to assert more than one thing in a test. For instance when testing a financial application with a chart of accounts that contains multiple calculated fields. Those fields […]

A guide to clear assertions with Hamcrest

5.0 01 A good practice in test automation is the use of Descriptive And Meaningful Phrases (also known as DAMP). This means that our tests clearly tell us what they do in language that is […]

Set up a Selenium project environment

0.0 00 Problem This recipe will describe how we can set up our project environment. We will use Eclipse as development environment as further examples will be written in Java, but we can use any […]

Model the application interface

1.0 02 The first step we have to take in implementing the page object model is that we have to model the user experience. This means that all page specific elements has to be extracted […]

Expose methods

0.0 00 We can expose methods in order to reduce duplicated code. We are able to call the method multiple times. This will ensure a better maintainable test code, because we only have to make […]

Dealing with moving focus

0.0 00 Problem Imagine the following situation: after accepting a confirmation dialog you will be redirected to another page. This recipe will explain how to deal with this inevitable situation. Prerequisites We have made a […]

Page Object Model – Introduction

5.0 01 Creating Selenium test cases can result in an unmaintainable project. One of the reasons is that too many duplicated code is used. Duplicated code could be caused by duplicated functionality and this will […]