Chapter 11: How to Construct Complex Scenarios
Whereas the examples in Section 3, Designing and Building Automated Test for Microsoft Dynamics 365 Business Central, covered the main, one-fold principles of an automated test using the ATDD format, this chapter shows you how to go about complex scenarios.
To achieve your goals as an end-user in Dynamics 365 Business Central, being the ERP package it is, you often end up exercising a substantial chain of consecutive actions. Say you need to test applying a payment to a posted invoice. In order to run this process, a number of related things need to happen first. You have to create a customer, create an item, create and post the invoice, and create and post the payment. And eventually, verify all relevant results.
How do you go about constructing a suite of tests for that? How to create reusable parts? And how to make use of already existing helper functions in the Microsoft test libraries?
In this chapter, we will get answers...