Chapter 10Databases
Back in Chapter 6, Keeping Your Cucumbers Sweet we described the risks associated with leaky scenarios, where data left behind by one scenario affects the results of the next. In this chapter we’re going to illustrate this problem with an example, and we’ll describe the two methods for dealing with it, along with their advantages and disadvantages.
For this final installment of the worked example, we’re going to introduce a relational database into our ATM system. Right now, our file-based database can only store the balance of a single customer’s account. Let’s introduce the capacity to store the balance for several different accounts, using a database table to store each customer’s account balance in a separate row. ...
Become an O’Reilly member and get unlimited access to this title plus top books and audiobooks from O’Reilly and nearly 200 top publishers, thousands of courses curated by job role, 150+ live events each month,
and much more.
Read now
Unlock full access