SWE 637 Assignment 9
Fall 2017
Logic-Based Testing for Code

Due 13-November, beginning of class


The software is done. We’re just trying to get it to work.
—Statement made in a Joint STARS E-8A FSD Executive Program

Answer the following questions. Bring hardcopies of your answers to class; either hand written or printouts. All homeworks are due before class on the due date. You may use one of the collaborative options as specified on the syllabus, but any help not allowed by that policy will be an honor code violation.

  1. (20 pts.) The Minimal MUMCUT class is taken from the logic coverage web application on the book website.
    1. How many total predicates are in the class?
    2. How many predicates have 1 clause? 2 clauses? 3 clauses? 4 clauses? etc.
    3. Answer c-g for for all predicates in the MinimalMUMCUT class that have more than two clauses. You can skip all predicates that only have one or two clauses.

    4. List the clauses in the predicate.
    5. Compute (and simplify) the conditions under which each clause determines the value of the predicate.
    6. Write the complete truth table for the predicate. Label your rows starting from 1. Use the format in the example underneath the definition of Combinatorial Coverage in Section 8.1 (that is, row 1 should be all clauses true.) You should include columns for the conditions under which each clause determines the predicate, and also a column for the predicate itself.
    7. Give rows from your table that satisfy Correlated Active Clause Coverage (CACC) with respect to each clause (only 2 rows per clause).
    8. Give rows from your table that satisfy Restricted Active Clause Coverage (RACC) with respect to each clause.

    The bonus will be worth up to 5 extra points. Also, it must be submitted with the rest of the homework. That is, you may not submit the homework on time and the bonus portion late.

  2. BONUS: Automate your CACC tests with JUnit and run them. To compile MinimalMUMCUT, you will need some of the other classes from the web application. You can find the source files online.