Search icon
Arrow left icon
All Products
Best Sellers
New Releases
Books
Videos
Audiobooks
Learning Hub
Newsletters
Free Learning
Arrow right icon
Automated Testing in Microsoft Dynamics 365 Business Central - Second Edition

You're reading from  Automated Testing in Microsoft Dynamics 365 Business Central - Second Edition

Product type Book
Published in Dec 2021
Publisher Packt
ISBN-13 9781801816427
Pages 406 pages
Edition 2nd Edition
Languages

Table of Contents (22) Chapters

Preface Section 1: Automated Testing – A General Overview
Chapter 1: Introduction to Automated Testing Chapter 2: Test Automation and Test-Driven Development Section 2:Automated Testing in Microsoft Dynamics 365 Business Central
Chapter 3: The Testability Framework Chapter 4: The Test Tools, Standard Tests, and Standard Test Libraries Section 3:Designing and Building Automated Tests for Microsoft Dynamics 365 Business Central
Chapter 5: Test Plan and Test Design Chapter 6: From Customer Wish to Test Automation – the Basics Chapter 7: From Customer Wish to Test Automation – Next Level Chapter 8: From Customer Wish to Test Automation – the TDD way Section 4:Integrating Automated Tests in Your Daily Development Practice
Chapter 9: How to Integrate Test Automation in Daily Development Practice Chapter 10: Getting Business Central Standard Tests Working on Your Code Section 5:Advanced Topics
Chapter 11: How to Construct Complex Scenarios Chapter 12: Writing Testable Code Chapter 13: Testing Incoming and Outgoing Calls Section 6:Appendix
Other Books You May Enjoy Appendix: Getting Up and Running with Business Central, VS Code, and the GitHub Project

Test example 11 – how to unit test event subscribers' logic

In the LookupValue extension, we extended the standard application logic by means of the following six event subscribers:

  1. OnCreateCustomerFromTemplateOnBeforeCustomerInsert Event

    [to be found in ContactEvents.Codeunit.al]

  2. OnApplyTemplateOnBeforeCustomerModifyEvent

    [to be found in CustomerTemplEvents.Codeunit.Codeunit.al]

  3. OnAfterCopySellToCustomerAddressFieldsFromCustomer Event

    [to be found in SalesHeaderEvents.Codeunit.al]

  4. OnBeforeCreateShptLineFromSalesLineEvent

    [to be found in WhseCreateSourceDocumentEvents.Codeunit.al]

  5. OnBeforePostSalesDocEvent

    [to be found in SalesPostEvents.Codeunit.al]

  6. OnBeforePostSourceDocumentEvent

    [to be found in WhsePostShipmentEvents.Codeunit.al]

Customer wish

These event subscribers were based on the following customer wishes:

  • Event subscribers 1 and 2:

    When creating a customer from a customer template, the Lookup Value Code field should be inherited...

lock icon The rest of the chapter is locked
Register for a free Packt account to unlock a world of extra content!
A free Packt account unlocks extra newsletters, articles, discounted offers, and much more. Start advancing your knowledge today.
Unlock this book and the full library FREE for 7 days
Get unlimited access to 7000+ expert-authored eBooks and videos courses covering every tech area you can think of
Renews at $15.99/month. Cancel anytime}