c# - Acceptance Tests for Tetris when using Test Driven Development -
i want try implement tetris game using tdd.
from i've come understand when reading growing object-oriented software, guided tests, should start defining acceptance tests. if right, acceptance tests when doing tdd defined use cases.
it of great importance define first acceptance test work "skeleton" of app, should kind of simple.
i've choosen following 2 acceptance tests first implement:
- the game starts , player closes it.
- the game starts , player nothing. loses.
are these 2 acceptance tests starting tests? next acceptance tests? think of like
- the game starts , square pieces drop. player puts them in such way lines "explode", making game after 100 game-steps still not over.
but feel kind of awkward, in real tetris game have different pieces falling, , acceptance testing should about.
also, feel kind of tempted try implement in 1 go when doing (2), think not 1 pretends when implementing second acceptance test. guess idea have game implemented after 6-7 of them, not on second. right?
thanks
i think first game field , looks after number of frames defined blocks dropped. example using cucumber:
scenario: dropping first square given empty 10x2 field when square dropped @ column 4 , 48 frames have passed field should contain square @ (4, 1) when 48 frames have passed field should contain square @ (4, 2) scenario: dropping square on full stack given empty 10x2 field , square @ (4, 2) when square dropped @ column 4 , 48 frames have passed game should on
if of cucumber feature specs, might want try cuke4nuke .net or cuke4duke java.
Comments
Post a Comment