Learning Objectives
Understanding CRUD
Review: One test script file contains multiple related test cases
Whenever possible, keep test data independent from among test cases.
Knowledge Point
CRUD is a software acronym for create, read, update and delete, which are four typical functions to access/store a data object (from/into) database.
For readers not familiar with CRUD, let me illustrate with an example. In an eBusiness app, the typical workflow is that a customer checks out and makes a payment to an invoice. There are at least three pieces of data stored in the system:
Customer
a customer previously created.Invoice
a new invoice is createdPayment
a new payment is created for the invoice
For each data, there can be at least four operations, such as “update customer’s details”, “delete an existing customer”, “view (read) the customer details”, “edit invoice”, “delete invoice”, …, etc.
CRUD testing is to verify these operations.
In a typical software project, there are a number of CRUD tests.
For this exercise, use WhenWise Sandbox’s database reset utility, before each test case!
driver.get("https://whenwise.agileway.net/reset")
Test Suite #22
Keep reading with a 7-day free trial
Subscribe to AgileWay’s Test Automation & Continuous Testing Blog to keep reading this post and get 7 days of free access to the full post archives.