March 2023
Intermediate to advanced
280 pages
3h 52m
English
Currently, the test runner’s reporting code is pretty fixed. There’s no way to configure it or switch it out. This might be a problem, for example, with sending output to a text file on a Continuous Integration (CI) environment, since text files don’t support ANSI escape codes.
In this chapter we’ll implement a system for supporting different output mechanisms for test reports. We’ll do this by writing a basic event dispatcher that will allow us to dispatch events to a reporter.
How the observer pattern can be applied to ...
Read now
Unlock full access