- Python3.12 (Might work on 3.10, 3.11 as well, haven't tested though)
- Project directory:-
a. Name should be of the form
lab1_entry1_entry2_entry3
b. Should contain a Makefile c. Runningmake
inside the project directory should build a binary namedspreadsheet
in{project_dir}/target/release
git clone TODO
cd lab1_autograder
- Create python virtualenv:-
python3.12 -m venv venv
- Activate environment:-
source venv/bin/activate
- Install dependencies:-
pip install -r requirements.txt
python main.py {path_to_proj_dir} {path_to_test_dir}
python main.py {path_to_proj_dir} {path_to_test_dir}/x.cmds
- Install asciinema
- Run
asciinema play demo.cast
Every test X has 2 components:- x.cmds
and x.exp
. x.cmds
is the input to
your program. And x.exp
is the expected output.
The file follows a structured layout with three distinct sections: metadata, spreadsheet data, and a separator.
An example file might look like this:
ok 0
ZZZ
999 -5
*****************
The first line consists of two parts:
[status] [exp_time]
status
: A string indicating status of the command. Common values might include:ok
: Indicates a successful operation.error
: Indicates a failure or issue.
exp_time
: A numeric value, expected time that should be taken to run the commands .
Example:
ok 0
- Here,
ok
signifies success, and0
indicate that running this command should take 0 seconds.
This section contains tabular data that appears similar to a spreadsheet. This section could also be empty if output has been disabled.
ZZZ
999 -5
ZZZ
: This is column header.999 -5
: Represents a row of data with values separated by spaces.
The final line consists of a sequence of asterisks (*
):
*****************
- This serves as a seperation marker between outputs of diferent commands .
If you want to share your own interesting test cases with your classmates, feel free
to add them in students_tests
directory, and raise a PR. Please follow the format above.
If you find any bug in the autograder, you can either fix it and raise a PR, or create an issue on github, I will try to fix it ASAP.
- Zip your project directoy
zip -r lab1_entry1_entry2.zip lab1_entry1_entry2 -x "lab1_entry1_entry2/target/*"
Note that this is the same directory that you passed to the test script. - Submit on moodle.
TA TODOs:-
Testcases:-
stddevavgdiv/0- scroll
- cyclic dependency
- range