(Credit: Patrick J. Lynch)
As a professional software developer, I often ponder the similarities and correspondences between programming and martial arts. A style of martial arts is ultimately just an algorithm—executed in wetware rather than with integrated computer circuits—and there are many interesting correlations to be found between these two outwardly distinct disciplines.
Within both fields, the need for testing is widely acknowledged. I am not referring to rank or belt testing, but to a comparison of expected and actual algorithmic results. Ideally, we would find no differences during this comparison: every strategy and tactic, principle and technique would perform exactly as intended. In reality, the flawless style of martial arts is as elusive as the bug-free operating system.
The complex algorithms of a martial art call for rigorous testing, and the standards applied by many martial artists are inadequate to the task. “If it works, use it” may pass for wisdom in JKD or MMA circles, but to an experienced software engineer, it reflects the absolute lowest level of competence. Well-written software not only works, it also follows design principles that recognize the inevitability of change.
Defense In Depth
Most of us lack the resources or motivation to design a completely new style of martial arts. Instead, we can only test our chosen style as thoroughly as possible, exposing any defects for repair. The standard practices of the software industry provide a framework against which we can evaluate the completeness of our martial arts testing.
Unit testing is the execution of a complete class, routine, or small program that has been written by a single programmer or team of programmers, which is tested in isolation from the more complete system.
Integration testing is the combined execution of two or more classes, packages, components or subsystems that have been created by multiple programmers or programming teams. This kind of testing typically starts as soon as there are two classes to test and continued until the entire system is complete.
Regression testing is the repetition of previously executed test cases for the purpose of finding defects in software that previously passed the same set of tests.
System testing is the execution of the software in its final configuration, including integration with other software and hardware systems. It tests for security, performance, resource loss, timing problems, and other issues that can’t be tested at lower levels of integration.
Do you have a comprehensive test plan for your martial art, addressing each of the levels listed above? Or do you prefer to rely on luck?