TCR Tool (test && commit || revert)
These days I try TCR in different real-world-project to evaluate if it is good or bad. Most of the time I use the variant ‘The Relaxed’ via a simple Bash-script.
Note: TCR (test && commit || revert) is new to you? It is like TDD, but different. Check out this post, which provides background, context and an example.
The script has two downsides that disturb my typical workflow:
- I cannot see my jUnit-Tests-Results properly
- Having the log in my field of view is very disturbing when I execute it in an infinite loop
Not such a big problem, but still not comfortable:
- I cannot switch my strategy (=variant) easily
- I don’t have stats, for example, how big my commits where, etc.
Note: See examples of different variants here.
Therefore, I decided to build a little TCR-Runner. You can see an example here: https://youtu.be/0rlI9mqHpkY
The tool connects via WebSockets to the “Backend,” which executes a specified TCR-Strategy periodically.
The architecture is easily extendable with new variants of TCR for trying them out. It is also Event-Driven, so adding new Components / Displays is trivial.