- Test-Driven Java Development(Second Edition)
- Alex Garcia Viktor Farcic
- 109字
- 2021-06-24 18:31:54
Test – X plays right after O
Finally, we can check whether X's turn comes after O played.
If the last turn was played by O, then the next turn should be played by X.
There's nothing to do to fulfill this test and, therefore, the test is useless and should be discarded. If you write this test, you'll discover that it is a false positive. It would pass without changing the implementation; try it out. Write this test and if it is successful without writing any implementation code, discard it.
The source code can be found in the 02-next-player branch of the tdd-java-ch03-tic-tac-toe Git repository at https://bitbucket.org/vfarcic/tdd-java-ch03-tic-tac-toe/branch/02-next-player.
推薦閱讀
- The Complete Rust Programming Reference Guide
- TypeScript入門(mén)與實(shí)戰(zhàn)
- Vue.js快速入門(mén)與深入實(shí)戰(zhàn)
- Instant Typeahead.js
- Lighttpd源碼分析
- C#開(kāi)發(fā)案例精粹
- C#程序設(shè)計(jì)(項(xiàng)目教學(xué)版)
- Python爬蟲(chóng)、數(shù)據(jù)分析與可視化:工具詳解與案例實(shí)戰(zhàn)
- 零基礎(chǔ)學(xué)C語(yǔ)言程序設(shè)計(jì)
- Android Development Tools for Eclipse
- OpenCV with Python Blueprints
- Hacking Android
- After Effects CC技術(shù)大全
- Building UIs with Wijmo
- Pandas 1.x Cookbook