Project 2: Combinatorial & Model-Based Testing on Real-World Projects
This assignment is a continuation of Exercise 2 and contributes to the project grade component. In this project, you will apply functionality-based Input Domain Modeling (IDM) using NIST ACTS and Control Flow Graph (CFG) modeling with Edge-Pair Coverage (EPC) to the real-world codebase you selected and onboarded in Project 1.
Like Project 1, this project is an individual assignment. Every student is independently responsible for selecting a non-trivial method in their own repository, deriving combinatorial test requirements and control paths, implementing automated tests in the project's native test framework, maintaining a passing SonarQube Quality Gate, and critically reflecting on AI-assisted test generation against systematic models.
Target Method Selection Criteria
You will select one non-trivial method from the codebase you used in Project 1. The selected method must satisfy the following criteria:
- Rich Domain Logic: The method must have meaningful business or domain logic (avoid trivial getters/setters, one-line delegate wrappers, or plain CRUD passthroughs).
- Multiple Semantic Parameters / States: The method must accept multiple input arguments, complex object parameters, or depend on non-trivial internal state suitable for partitioning.
- Branching & Control Flow: The method must contain multiple conditional decisions (
if/else,switch, guard clauses), loops (for,while), or exception paths suitable for CFG edge-pair derivation. - Unit-Testability: You must be able to write and execute automated unit tests against this method within your project's existing test framework (e.g., JUnit 5, pytest, Jest/Vitest, Go test).
Getting Started
- In your local repository for your Project 1 codebase:
(Note: If your default branch is named
1 2
git switch main git pull origin mainmasteror something else, use that branch name). - Ensure that your test suite passes cleanly locally and that your GitLab CI/CD pipeline is green.
- Create a working branch for this project:
1git switch -c task/2-modeling
Task 1: Functionality-Based Input Domain Modeling (IDM) with NIST ACTS
Apply functionality-based IDM to your chosen target method:
- Identify characteristics and partitions (blocks).
- Focus strictly on functionality-based characteristics (domain semantics, input ranges, state invariants, boundary values). Avoid superficial interface-based syntax checks.
- Ensure the blocks for each characteristic are disjoint and complete.
- Formulate constraints to eliminate unfeasible or invalid combinations.
- Build the model in NIST ACTS. Define the system (SUT), parameters, and constraints. Then, configure the combinatorial coverage criterion to 2-way strength, which corresponds to Pair-Wise Coverage (PWC). Lastly, run the generation algorithm (IPOG) to create a minimal covering array.
- Export deliverables by saving the ACTS model configuration as XML or text file and the generated test suite configuration as CSV file.
Task 2: Control Flow Graph (CFG) & Edge-Pair Coverage (EPC)
In this task, you will analyse the execution paths of your chosen target method using graph modeling:
- Create the CFG using a diagramming tool (e.g., Draw.io, Excalidraw, PlantUML, Mermaid). Do not forget to label each node with a number or symbol, and label the outward edge(s) from each branching node with the conditional expression.
- Enumerate test requirements using EPC criterion.
- Derive the minimal test paths to cover the test requirements. Label any unfeasible test path, if any.
Task 3: Automated Test Implementation & Quality Gate Maintenance
Implement the test requirements derived from ACTS and your CFG into your codebase's automated test suite:
- Update the ACTS CSV (or create a test fixture) with a new column or mapping for the expected outcome.
- Implement automated tests in your project using its native testing framework.
You may implement them as parameterized/data-driven tests (e.g., JUnit 5
@ParameterizedTestwith@CsvFileSource, pytest@pytest.mark.parametrize) or as discrete unit tests mapped to your ACTS combinations and CFG paths. - Execute the test suite locally and verify all tests pass.
- Push your branch
task/2-modelingto GitLab CSUI, create a Merge Request (MR) targeting your default branch, and ensure the CI/CD pipeline passes. - Verify that your project maintains a passing Quality Gate on SonarQube CSUI with no new blocker or critical quality issues introduced.
Task 4: Generative AI Test Generation Comparison & Reflection
Similar to Exercise 2, evaluate the test suites generated by AI by comparing them against the combinatorial and graph-based models. Prompt a GenAI assistant to generate the unit test suite without prior knowledge of existing test suites in the codebase and without knowledge about this project specifications.
1. Generate Tests via Prompt in Isolation
Copy and paste the following prompt template into a standalone AI chat session on a Web-based chat (e.g., Claude, ChatGPT), or an isolated AI agent session with no access to the source code:
Prompt template for your chosen method:
1 2 3 4 5You are a senior Software Engineer in Test. Write a comprehensive suite of unit tests for the following method in <LANGUAGE>. Focus on boundary values, null/empty inputs, edge cases, and mocking dependencies where necessary. <PASTE_YOUR_METHOD_CODE_HERE>
2. Compare AI Output Against IDM & CFG
Critically compare the AI-generated test suite against:
- ACTS PWC Matrix: Did the AI cover all combinations of inputs? Did it test the exact boundary values, or only generic cases?
- CFG EPC Test Paths: Did the AI exercise all edge pairs, loop iterations, and exception branches?
Document your evaluation and reflection (2–3 paragraphs) in your written report.
Deliverables
At the end of this project, prepare the following artifacts in your fork repository on GitLab CSUI:
- Written Report: A Markdown file named
PROJECT_2_REPORT.mdin the repository root. - ACTS Model & Data Files:
- The ACTS model file (
.xmlor.txt) for your chosen method. - The exported CSV file generated by ACTS.
- The augmented CSV / test data file with expected outcomes (stored under your project's test resources or test directory).
- The ACTS model file (
- CFG Diagram: The exported image file (PNG or JPEG) committed to the repository and referenced in
PROJECT_2_REPORT.md. - Codebase Updates:
- New or updated test files covering your ACTS combinations and CFG paths.
- All tests passing locally and in CI/CD.
- Quality Gate Verification:
- Passing CI/CD pipeline and passing SonarQube Quality Gate on SonarQube CSUI.
The due date of this project is: Sunday, 22 November 2026, 23:55 UTC+7.
Submit the URL of your repository on GitLab CSUI to the designated submission slot on SCELE before the deadline.
GenAI Usage Policy
This project allows GenAI and LLM tools as learning materials and aids. Even so, it is still imperative for you as a course participant of SQA to critically review and factually verify all outputs generated by GenAI.
The use of GenAI does not mean you can entirely delegate your learning process to GenAI. You enrolled in this course to learn and obtain knowledge and skills. Do not make GenAI the one that does the learning, turning you into a "meat proxy" for it.
Allowed Uses
- Conducting the comparative evaluation required in Task 4 using the provided prompt in isolation.
- Asking for documentation and syntax examples regarding your project's test framework (e.g. parameterized test syntax in JUnit/pytest).
- Brainstorming potential semantic partitions and edge cases.
- Directing assistants to help debug failing test runs or pipeline errors.
Prohibited Uses
- Direct, uncritical copy-pasting of AI-generated tables, graphs, or calculations without verification.
- Outsourcing the construction of the CFG or IDM partitions entirely to an AI tool.
Report Template
Use the following Markdown template for PROJECT_2_REPORT.md:
Note: you can write your report in English or Bahasa Indonesia.
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 | |
GenAI Use Disclosure
Antigravity CLI with Gemini 3.8 Flash model was used to proofread this document and generate the report template. We have reviewed and edited the generated text.
References
- NIST Automated Combinatorial Testing for Software (ACTS): https://csrc.nist.gov/projects/automated-combinatorial-testing-for-software
- Paul Ammann & Jeff Offutt, Introduction to Software Testing, 2nd Edition (Cambridge University Press).
- Chapter 6: Input Space Partitioning
- Chapter 7: Graph Coverage
Created: 2026-11-14 01:30:54