Understanding the benefits of Test Driven Development.

The challenges in building of the moment, effective, in demand software is a very live discussion; it’s a tricky business. What is needed today, could be obsolete tomorrow. 

There are layers of challenges in software development. From prioritising buildout, to finding the right people for the job and having the bandwidth to keep up with a rapidly evolving technical landscape. Software development is often seen as a dark art. Complex, error prone and seemingly never finished.

Over our blog series, we will be sharing our perspective on some of these challenges and how we work here at Platinum Informatics, to remove obstacles and leverage opportunities to offer the best, unparalleled software products. In this blog, we explore how we use Test Driven Development as a guiding principle for building, developing, and testing our software. 

Test Driven Development (TDD) is used to drive the development of applications. Put simply, to implement TDD you:

  1. express your design intent in a test that fails,
  2. design and write just enough production code to make it pass,
  3. refactor and repeat.

TDD challenges traditional testing methods, by writing the tests before writing the code. It’s a validated approach which ensures development work is consistently of a high quality. It’s a discipline here that we abide by as it improves the quality and reliability of production code. Three major motivations for using a TDD approach are:

(1) Perspective shift

TDD forces you to be very focused on your actions, minute by minute. You constantly specify your intent with a failing test, then do just enough work to deliver on that need. We always like to try and anchor this in the solution domain, so you are constantly thinking about customer needs. It is a great way to reduce bloat, unnecessary code, and complexity. TDD drives focused development that solves the problem in hand.

(2) It worked just a moment ago

If we truly commit to TDD, this means tiny iterations, in the order of minutes not hours, we are never far away from when the tests were passed, and the system worked. In a complex, error-prone environment, the ability to hit a button and verify all your previous intentions are still ‘true’ is invaluable. How many times have you written an hour’s worth of code, attempted an end-to-end manual test, and then waded through a sea of errors to get to something that works? With TDD you don’t need to back up too far to get to a stable functioning state, therefore TDD is an upfront investment in reliable code.

(3) Documentation of intent 

With the best intentions and a commitment to writing clean, self-documenting code, there is no denying that source code alone makes for an anaemic picture of how the system works. All this effort put into specifying our intent in tests adds a second voice to the code. The tests help us to understand our expectation for the production code in terms of what inputs and outputs are expected, the type of error states we have anticipated in design and how the system should behave.

In our area of work, there is no room for error. There are countless examples of where TDD has helped us to build out a better, more reliable product that is fit for purpose. Our commitment to application testing using this approach is another marker of how we are applying best practice methods to build a product that customers trust and can rely on. 

Whereas many software companies are reactive, building products that solve only today’s problems, Platinum Desimal is revolutionary. It recognises today’s problems but provides a solution that will drastically change the face of future laboratory operations and discovery.

Here at Platinum Desimal, we’re an agile team, co-producing software that solves three major challenges in research efforts today (the volume of data, complexity and reproducibility). We have a highly skilled technical team who constantly challenge ourselves to be ahead of the curve. We have one shared vision – to bring the digital lab of the future to the research laboratories of today – which is so necessary to realise our global research capabilities. For more information on how we can help you, please get in touch. 

[1] What is Test Driven Development (TDD)?

[2] J.B Rainsberger- TDD

Latest Platinum Desimal News

Discover the future