Summary

In this chapter, we introduced unit testing for languages implemented with Xtext. Being able to test most of the DSL aspects without having to start an Eclipse environment, really speeds up development.

TDD is an important programming methodology that helps you make your implementations more modular, more reliable, and resilient to changes of the libraries used by your code.

In the next chapter, we will implement a DSL based on expressions. In spite of the apparent simplicity, parsing and checking expressions is not that simple, since arithmetic and boolean expressions are inherently recursive, and dealing with recursion always requires some additional attention and effort. We will also implement a type system to check that expressions are ...

Get Implementing Domain-Specific Languages with Xtext and Xtend - Second Edition now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.