CENG 334 Homework 1 – Grader

The C grader checks that your merger program produces the correct merged CSV output, that all operator processes exit successfully, and that there are no zombie processes left behind.

For students (grader executable)

If you received a grader executable with your homework package:

  1. Put your compiled merger in the same diory as the grader and the operator executables (sort, filter, unique).
  2. Ensure a tests directory is present (it should be in the same package) with test specs and expected outputs.
  3. Run the grader from that directory (so the merger finds the operators):
    ./grader
    Or from elsewhere: path/to/grader --merger path/to/merger --build-dir path/to/dir --tests-dir path/to/tests
    The grader will run the built-in tests and print one line per test (PASS/FAIL) and a total.

Extending with your own tests

You can add your own test cases so the grader runs them too. Create a directory (e.g. my_tests) with the same layout as tests: for each test, provide:

Then run:

./grader --extra-tests my_tests

Or use only your own test directory:

./grader --tests-dir my_tests

Exit status reporting and EXIT-STATUS lines

The grader verifies operator exit status using a dedicated communication channel, not by looking at the expected output file:

In summary: the expected files check only data. Operator exit status is checked via EXIT-STATUS lines and the HW1_EXIT_REPORT operator→grader log.

← Materials · ← Homework 1