Tetris Is Hard To Test
New submitter JackDW writes: Tetris is one of the best-known computer games ever made. It's easy to play but hard to master, and it's based on a NP-hard problem. But that's not all that's difficult about it. Though it's simple enough to be implemented in one line of BBC BASIC, it's complex enough to be really hard to thoroughly test.
It may seem like you can test everything in Tetris just by playing it for a few minutes, but this is very unlikely! As I explain in this article, the game is filled with special cases that rarely occur in normal play, and these can only be easily found with the help of a coverage tool.
It may seem like you can test everything in Tetris just by playing it for a few minutes, but this is very unlikely! As I explain in this article, the game is filled with special cases that rarely occur in normal play, and these can only be easily found with the help of a coverage tool.
If anybody wrote code like that for me, they'd be made to sit on the naughty step and think very, very hard about what they'd done.
It may seem like you can test everything in Tetris just by playing it for a few minutes, but this is very unlikely! As I explain in this article, the game is filled with special cases that rarely occur in normal play, and these can only be easily found with the help of a coverage tool.
Tetris doesn't need coverage tool to test you. Everything about you.
Code-coverage tool is crutch for weak capitalist engineer. Tetris is Soviet technology, forged by people's will.
10 PRINT CHR$(205.5+RND(1)); : GOTO 10
What's harder than NP-hard?
Intractable.
"First they came for the slanderers and i said nothing."