Good test data is hard to come by. Learn how to use data simulation to improve the test data management process and save valuable time normally spent waiting for test data.
Good test data is hard to come by, and test teams are often left waiting for test data to be produced for them. According to a recent survey from Sogeti, up to 60% of application development and testing time is devoted to data-related tasks, and many project overruns are due to inefficiencies in test data provisioning. In general, up to 20% of the average software development lifecycle is lost waiting for data!
To improve this process, testing teams can use service virtualization to augment traditional test data extraction. With this method of data simulation, testers can quickly build meaningful test data by capturing realistic test data from interactions between components in their existing system (real and virtualized), and building data models that can be shared and controlled directly by testing teams.
How do you benefit from data simulation?
The process is as follows:
- Define monitors: Monitors are proxies that intercept and record the data traffic between users and servers.
- Capture: Test data is captured by monitors and recorded from existing testing via functional, performance and security testing already in place by the development team. The application under test likely has dependencies on various types of services such as databases, legacy mainframe systems and many others. As test automation is executed the transactions and data between the application and services is recorded by the monitors and stored in the virtual service repository.
- Create: The captured transactions and data are sent to the service virtualization engine to create simulated virtualized services with associated test data.
- Deploy: The created services are stored and deployed to a virtual service repository allowing for later consumption.
- Manage: Orchestration of these virtualized service is required to make service virtualization work in a
- Consume: Test data management and integrated orchestration of these virtual services means automated API and service-level testing is robust, easily repeatable and easier.
How does it work in practice?
A good example might be replacing a reliance on a shared database by swapping it with a virtual service. This allows for parallel and independent testing, that would otherwise conflict. With data simulation, testers can generate, subset, mask, and create individual customized test data for their needs.
By replacing shared dependencies such as databases, service virtualization removes the needs for the infrastructure and complexity required to host the database environment. In turn, this means isolated test suites and the ability to cover extreme and corner cases. Although the virtualized dependencies are not the “real thing,” some actions (e.g. an insert and update operation on a database) add some complexity to virtualization.
After capturing transactions and data, there is full control over the contents of the data from within the data manager. In addition, a model is abstracted automatically from the data based on database extraction or through the interactions observed during the recordings. This create model, as illustrated below, allows for better understanding of the data structure and relationships. This understanding is key to the next steps of masking, generating, and subsetting.
Quickly getting secure, real data for testing
Test data is hard to procure and a risk to manage. A solution based on secure, real data capture provides the best way to get the data you need, as fast as you need it. Service virtualization helps teams capture this data earlier in the development process, to be easily used for testing. With this modern approach to test data management, testers can securely store and manage test data, customize data sets for their needs, reduce the risk and liability of using production data, and reduce overall project risk and costs. For more information, you can download the free whitepaper: Tired of waiting for test data? Here’s the solution to your test data management headaches.
Chris Colosimo is a Product Manager, with expertise in SDLC acceleration through automation. Chris strategizes product development and deployment of Parasoft’s Continuous Testing solutions (Parasoft SOAtest, Virtualize and Continuous Testing Platform). Being a service virtualization and API testing subject matter expert and focusing on the concept of Continuous testing at speed, he works with developers and testers to discover constraints, evolve process, and facilitate the change management required to adopt agile and DevOps principals throughout an organization. Keen to share his knowledge and vast experience he frequently writes blogs and can be followed on Linkedin.