CPRE Requirements Modeling & Use Cases 1 — Questions and Answers
Question 1: In UML use case modeling, what does a '<<include>>' relationship between two use cases indicate?
- The base use case optionally incorporates the behavior of the included use case
- The base use case always incorporates the behavior of the included use case (Correct answer)
- The included use case can extend the base use case under certain conditions
- The two use cases share a common actor
Correct answer: The base use case always incorporates the behavior of the included use case
An <<include>> relationship means the base use case always (unconditionally) invokes the included use case as part of its execution.
Question 2: Which element in a use case model represents the boundary between the system under specification and its environment?
- Actor
- Use case
- System boundary (subject) (Correct answer)
- Association
Correct answer: System boundary (subject)
The system boundary (also called the subject in UML 2) defines what is inside the system versus what is external to it.
Question 3: A use case description includes a 'main success scenario' and 'extensions'. What do extensions represent?
- Additional actors who may trigger the use case
- Alternative flows that handle exceptions or optional branches (Correct answer)
- Non-functional requirements related to the use case
- Pre-conditions that must be met before the use case starts
Correct answer: Alternative flows that handle exceptions or optional branches
Extensions (also called alternative flows) describe how the use case handles deviations, exceptions, or optional paths from the main success scenario.
Question 4: In requirements modeling, what is the primary purpose of an Entity-Relationship Diagram (ERD)?
- To model the sequence of interactions between actors and the system
- To illustrate the data structures and relationships between data entities (Correct answer)
- To define the states and transitions of system objects
- To show the hierarchical decomposition of system functions
Correct answer: To illustrate the data structures and relationships between data entities
An ERD models the data domain by showing entities, their attributes, and the relationships (cardinality and participation) between them.
Question 5: Which of the following is a valid pre-condition in a use case specification?
- The system shall display a confirmation message after saving
- The user must be logged in and have appropriate permissions before initiating the transaction (Correct answer)
- The use case ends when the user closes the application
- The system processes the request within two seconds
Correct answer: The user must be logged in and have appropriate permissions before initiating the transaction
A pre-condition states what must be true before the use case can begin; requiring the user to be authenticated is a classic pre-condition.
Question 6: In a context diagram (Level-0 DFD), what do the external entities connected to the central process represent?
- Internal subsystems of the system under development
- Data stores within the system
- Actors or systems outside the scope that interact with the system (Correct answer)
- Non-functional requirements for the system
Correct answer: Actors or systems outside the scope that interact with the system
External entities in a context diagram represent actors, users, or external systems that lie outside the system boundary but exchange data with it.
Question 7: What distinguishes a primary actor from a secondary actor in use case modeling?
- A primary actor is always human, whereas a secondary actor can be an external system
- A primary actor initiates the use case to achieve a goal, while a secondary actor provides services to the system (Correct answer)
- A primary actor is more important to the business domain than a secondary actor
- A primary actor appears in the main success scenario only, while a secondary actor appears in extensions
Correct answer: A primary actor initiates the use case to achieve a goal, while a secondary actor provides services to the system
A primary actor initiates the use case and has a goal to fulfill, whereas a secondary actor supports the system during the execution (e.g., an external payment gateway).
In UML use case modeling, what does a '>' relationship between two use cases indicate?