Skip to the content

Directions ASIA 2023

Writing testable code and why it matters

Date: 27-04-2023 | From: 12:30 to 13:15 | Room: Air

Writing good, quality code is hard. Most of developers would agree to that. However, where many would disagree is what exactly it means "quality code". Spoiler alert: cops don't tell you much about code quality.

One of the most commonly accepted definitions of good code is "code that functions as intended for end-users without any deficiencies". But that's only one side of the story. Another side, possibly more important, is how to make sure that your code satisfies this definition. Another spoiler alert: it has all to do with testability.

This session takes a look at testability from a different angle. What does it mean for your code to be testable, and how you can make it more testable? And most of all, why should you care?

Rather than talking about AL test framework features, this session focuses on coding best practices that make sure writing test code is a breeze. Instead of teaching you about test codeunits, test functions, and such - you should already be familiar with them! - this session will talk about test doubles, interfaces, coding for robust extensibility and related concepts. You'll learn how to make your code more extensible while making it more robust at the same time.


Vjekoslav Babic

Vjekoslav Babic

Solutions Architect | MVP

Bio: Vjekoslav Babić, or just Vjeko as he prefers to go by in the community in a vain attempt to simplify his absurd Slavic name, is a Business Central architect, developer, trainer, author and blogger. With more than two decades of experience in the IT, he worked with vast range of technologies, but his passion has always been anything that had to do with the web and mobile worlds. Deep down, Vjeko is an incurable hacker who took quite a long time to realize that the one thing he really loves is writing code, plain and simple. He immensely enjoys breaking things apart to see how they work, not necessarily always putting them back together. As a frequent speaker at conferences, in his demos, and on his blog, he is always pushing the boundaries of what's possible, connecting the world of Business Central with just about anything that can be plugged into it through some obscure loophole or undocumented interface, especially if they are not meant to be used that way. In Vjeko's view, nothing is really meant to be used in any particular way and figuring out how to make things useful beyond their intended purpose is the meaning of life, in a way. Since spring 2010, Vjeko has been awarded the Most Valuable Professional (MVP) award for Microsoft Dynamics NAV. You can meet him at his blog " - ideas in the cloud".