On high level, the whole
Cucumber is composed of three components:
Parser, representing a source of features (default one parses
Runner, executing scenarios of features received from a
Parser, and emitting
events (default one executes concurrently).
events (default one outputs to STDOUT).
Any of these components is replaceable. This makes
Cucumber fully extensible, without a need to rewrite the whole library if it doesn't meet some exotic requirements. One could always write its own component, satisfying the needs, and use it. Imagine the situation, where features are sourced from distributed queue (like Kafka), then executed by a cluster of external workers (like Kubernetes
Jobs), and, finally, results are emitted to different reporting systems by network. All this possible by introducing custom components, capable of doing that, without a need to change the framework.
To feel a little bit of its taste, we will write some trivial implementations of each component in subchapters below.