TDD Three Ways

Tickets Here!

Date Thursday 20th June 2019
Time 6:00 pm for 6:30pm start. 9pm finish
Location   Incremental Group, 5th Floor, The Garment Factory, 10 Montrose St, Glasgow G1 1RE

** For tonight’s event please use the side door as the main door will be shut. Once inside head up to the 5th floor.**

For our June event we’re trying three different styles of pair programming using TDD.

  • Ping Pong
  • Silent
  • Beginners Mind

We’ll try each style for 30/40 minutes then share what we learned at the end.

Don’t worry if you’ve never pair programmed or done TDD before. We’ll be pairing people up to make sure every pair has at least one person who’s done both.

Please bring your laptops!


Ping Pong

In pairs:

  • A writes a new test and sees that it fails.
  • B implements the code needed to pass the test.
  • B writes the next test and sees that it fails.
  • A implements the code needed to pass the test.

And so on. Refactoring is done whenever the need arises by whoever is driving.

More info: Ping Pong Pattern


In pairs:

  • You are not allowed to talk.
  • All the communication is made through code.
  • You are not allowed to use paper or write comments in the code or other files.
  • Set a three minute timer and switch every three minutes.

More info: Silent

Beginners Mind

In Pairs

  • One person is the driver and does all the coding
  • One person is the navigator and asks beginner, even basic and stupid questions like “what are you doing”, “why are you doing this”, “tell me what is happening in this code”
  • the driver is not allowed to be angry by the beginner questions of the technical coach; the driver needs to always explain what is their current idea, how they can implement it and why they chose this path.
  • Switch roles when were halfway through

More info: Beginners Mind

The Exercise - Bank Account

You are working for a new challenger bank building their backend system.

Please implement the following features:

  1. User can check balance

  2. User can make a deposit to the account. A deposit has:
    • amount
    • description
    • transaction type of ‘deposit’
    • transaction date
  3. User can make a withdraw from the account. A withdrawl is the same as deposit except it has:
    • transaction type of ‘withdrawl’
  4. Account can have an overdraft. If user goes over the overdraft they are fined £10. The transaction type is ‘fine’.

  5. User can get a list of transactions.

  6. Account pays 2% interest on savings, calculated monthly.

If you’re not sure about a requirement just make something up, but try to keep things simple. Remember, it’s just an exercise! You don’t need to worry about capital gains tax or GDRP compliance!

For simplicity, don’t worry about error cases (what if deposit amount is negative? etc).

Use your favourite lanaguge/tool/framework to build the app or build it online using

Have fun!