Z-code interpreter which reads commands from a file and prints transcript to a file

Is there a Z-code interpreter which can be started with command line options telling it to read commands from a file and print the game transcript to a file?

I’d like to set up an automated test suite which executes a number of commands and then compares the game transcript to a transcript stored in a file.

Have you seen RegTest?

https://eblong.com/zarf/plotex/regtest.html

1 Like

If you write your tests in the form of an Extension Project (with your test cases as the examples) then the Inform7 IDE can do this by itself.

Or for the main story file, you can make use of the skein and blessed transcripts, although they can sometimes get cluttered if you’re doing a lot of extra manual testing. You can mark them so they don’t get pruned away when you clear the rest of the skein, however.

RegTest is the test suite side of the problem. For the interpreter side, I use Fizmo compiled with either CheapGlk or RemGlk.

1 Like

dumbfrotz runs in console text mode (interactively).

3 Likes

This may not be for an Inform 7 project.

1 Like

Bocfel and my ifvms/ZVM are other options that will work with RegTest.

1 Like

I use ZLR that way in ZILF’s test projects as well as ZLR’s own tests.

1 Like

cat input.txt | frotz zork.dat | tee output.txt

1 Like

Sorry for bumping old topic, but is there a way to switch on keyboard input after all commands in input.txt will over?

Edited: figured it out myself. Leave it here, it might be useful for someone.

cat input.txt - | frotz game...
2 Likes

That is actually a pretty good hack!
Never thought of that one.

Thanks!