Beefy Boxes and Bandwidth Generously Provided by pair Networks
"be consistent"
 
PerlMonks  

Re: Testing Zork-style game

by andyf (Pilgrim)
on Jun 28, 2004 at 18:28 UTC ( #370281=note: print w/ replies, xml ) Need Help??


in reply to Testing Zork-style game

Just a thought. Is the output unique for every state in the game? If not ( I suspect it isn't - ie you will be in many situations which return "You are in a room with a window, there is one door to the North and one door to the South" coresponding to completely different game states.) then a test suite mapping input to output doesn't prove your implementation in quite the same way. My approach might be to write a function in the C, Perl, and Lisp implementations that dumps the game state in a standard format. Use that in your tests. When you have proved that the same state sequence solves the game, then add your output - the same for every implementation. Interesting to read Knuths take on Adventure! BOL Andy

Log In?
Username:
Password:

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://370281]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others taking refuge in the Monastery: (7)
As of 2016-06-25 12:05 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?
    My preferred method of making French fries (chips) is in a ...











    Results (325 votes). Check out past polls.