CISC 327: Assignment 3 FAQ

Should we use our incomplete set of tests from A1, or try to make them complete?

You should make a reasonable effort to add the tests you missed, but it's not the focus of Assignment 3.

(1) Can we use Python or ... to run the tests instead of shell scripts? (2) Relatedly, do we have to have test inputs (and outputs) in individual text files or could we embed them as strings inside our Python test harness?

(1) Yes, but there's a risk the TAs will decide your code is less clear or readable than the shell scripts would be. There is also a risk that you will accidentally "save state" across different runs of the Front End; each Front End run should be independent, but if you implemented the Front End in Python and then write a testing harness in Python, you might accidentally depend on objects or instance variables left over from the first run. You can avoid this risk by writing the testing harness as a completely separate program that simulates running the Front End from the command line. In Python, this should be possible by calling os.system. (2) Please put them in individual text files. This is mostly to make things easier to mark, not for any principled reason.

What are the .log files for?

The .log files are the console/terminal output from the Front End, such as user prompts.

Unlike the Transaction Summary File, which has a fixed format specified in the project requirements, the specific contents of the "expected" .log file are up to you. So, you can use the current behaviour of your Front End to define what is expected—essentially doing regression testing. That is, whatever your Front End currently produces on the terminal becomes the expected .log file for that test case.