SoftwareTesting Paper Solved
SoftwareTesting Paper Solved
9. What is thread?
Ans: A thread in system testing is a sequence of interconnected Atomic System
Functions (ASF) that together accomplish a specific user task or workflow in a
system. It includes all the steps a user takes to achieve a particular outcome to ensure
that the system correctly executes the complete sequence of operations required.
10. What is composition?
In software testing, composition refers to the practice of combining multiple
components or objects to create a more complex system. It involves testing how
these combined parts interact and work together to ensure they function as expected
when integrated.
11. Define exploratory testing.
Ans: Exploratory testing is an approach to software testing where testers
simultaneously design and execute test cases based on their domain knowledge,
experience, and intuition. Unlike traditional scripted testing exploratory testing
involves testers exploring the software application dynamically, without predefined
test cases. Testers learn about the application as they test, uncovering defects,
understanding functionalities and identifying potential risks through an iterative and
explorative approach. The goal of exploratory testing is to discover issues that might
not be found through structured testing techniques.
2. Robust Boundary Value Testing: Robust Boundary Value Testing extends Normal Boundary
Value Testing by including values just outside the valid range. It tests the system's ability to
handle inputs slightly beyond the expected boundaries.
Robust Boundary Value Testing is crucial for systems where input validation directly impacts
functionality and security. By including tests for inputs just outside the accepted ranges, RBVT
helps ensure that the application is secure against unusual or unexpected inputs, enhancing the
overall resilience and reliability of the system. This testing approach is particularly valuable in
protecting against errors that could lead to exceptions, system crashes, or security breaches.
Robust boundary value test cases for two variables are shown in Figure 2.2
3. Worst-Case Boundary Value Testing: Worst-Case Boundary Value Testing examines the
effects of all combinations of boundary values across multiple variables. It explores interactions
between variables at their boundary conditions.
This type of testing is particularly useful in critical systems where failure can result in significant
consequences, ensuring that the system is robust against a wide range of inputs and,
conditions. It's essential for ensuring the reliability and stability of system in real world scenarios
where multiple factors may affect outcomes simultaneously.
The result of the two-variable version of this is shown in Figure 2.3.
4. Robust Worst-Case Boundary Value Testing: Robust Worst-Case Boundary Value Testing
combines out-of-range values for multiple variables to stress test the system. It includes extreme
combinations, even those outside the valid input ranges. This approach focuses on evaluating
the software's behavior under extreme conditions while also testing for robustness against
unexpected inputs and variations in the boundary values of multiple variables simultaneously.
PART C
1)Explain SATM.
Ans: The Simple ATM System [SATM) serves as a practical example to illustrate the
complexities involved in integration and system testing of a client-server architecture. With a set
of functionalities captured in a series of interactive screens, the SATM system provides an ideal
case to examine how different components within an ATM interface work together to handle
user transactions seamlessly.
Problem Statement: The Simple ATM system simulates real-world banking transactions via an
interface shown in Figure 1.6. It demonstrates how various components interact to complete
user-driven tasks.
Identity Key user interaction
Inserting the ATM card.
Selecting a transaction type.
Receiving the card and receipt.
Entering the PIN.
Performing the transaction.
A terminal is equipped with various user interaction components like a card slot, keypad,
and screens for displaying messages and options. Customers interact with the SATM by
using a plastic card encoded with a personal account number (PAN). The system
progresses through multiple screens, each corresponding to different stages of
transaction processing from card insertion, PIN entry, transaction selection, to the final
transaction execution. The SATM interacts with bank customers using a sequence of 15
interactive screens as depicted in Figure 1.7. Each screen represents a different stage of
the transaction process, capturing all necessary user interactions and system responses
. Initial Interaction: When a customer approaches the SATM, the interface shown on screen 1
prompts them to insert their ATM card into the card slot. This triggers a verification process
where the system checks the personal account number (PAN] encoded on the card against an
internal database.
. Authentication: If the PAN is verified, the system advances the customer to screen 2, asking
for a PIN. If the PAN does not match, screen 4 appears, indicating the card is invalid and will be
retained. After correct PIN entry, the customer moves to screen 5; incorrect entries after three
attempts lead to screen 4 where the card is retained.
Transaction Selection: On screen 5, the customer selects from available transactions: balance
inquiry, deposit, or withdrawal. The system then navigates to different screens based on the
selection:
Balance Inquiry: Leads directly to screen 14 showing the account balance.
Deposit: If the deposit slot is operational (as per the terminal control file), the system proceeds to
screen 7 to accept the deposit amount. If there is an issue, it moves to screen 12. Following the
deposit, the system processes the transaction and updates the balance on screen 14.
Withdrawal: The system first checks the status of the withdrawal chute. If it's jammed, screen 10
is displayed. If it's operational, screen 7 appears for entering the withdrawal amount. Post this, if
the funds are insufficient, screen 8 is shown; otherwise, the system processes the withdrawal and
displays the new balance on screen 14.
2)Explain STLC.
Ans: The Testing Life Cycle is a critical framework in software development that
systematically identifies, diagnoses, and resolves issues within a software product to ensure
quality and reliability. By following a structured approach, teams can effectively address defects,
enhance functionality, and meet specified requirements. This disciplined process helps prevent
defects from reaching production, reducing costs and increasing user satisfaction. The Testing
Life Cycle in the below diagram illustrates the various stages involved in identifying and
resolving issues during software development. This cycle is an integral part of ensuring software
quality through systematic testing and issue management.
1. Specification (Spec): The testing cycle begins at the specification phase, where requirements
are defined and documented. It is crucial to have a clear, thorough, and unambiguous
specification because errors at this stage can propagate through to later stages, leading to more
severe issues.
2. Design: During the design phase, the specifications are transformed into a design plan that
outlines the software architecture and its components. Faults can arise here if the design does not
accurately or efficiently implement the specifications. Such design faults could be logical errors
in flow or inefficient architecture choices.
3. Coding: In the coding phase, developers write the actual code based on the design documents.
This stage is prone to introducing faults due to human error in implementing the design logic,
misunderstanding requirements, or syntactical errors in the code.
4. Testing: Once coding is completed, the testing phase begins to check the software for defects
{faults} and ensure that it performs as expected. The goal is to identify and document any
incidents arising from faults in the software.
5. Classify Fault: When a fault causes an incident, the issue is analyzed and classified. This
involves determining the nature of the fault, such as whether it's due to a requirem ent
misunderstanding, design error, or coding mistake. Classifying incidents helps in prioritizing
them for fixes.
6. Isolate Fault: Once an incident is reported and classified, the next step is to isolate the specific
part of the code or design that is causing the problem. This precise identification is critical for
effectively addressing the fault without introducing new issues.
7. Fault Resolution; The final phase in the testing cycle is resolving the fault. This involves
modifying the code or design to fix the issue and verifying that the fix resolves the problem
without causing additional problems. This stage is crucial as inadequately resolved faults can
lead to further errors or even new faults.
Disadvantages of TDD:
1. Dependency on Test Frameworks: TDD heavily relies on test frameworks, and without them,
it becomes challenging to practice TDD effectively.
2. Limited Design Opportunities: The bottom-up nature of TDD may limit opportunities for
elegant design as it focuses on incremental improvements through refactorings.
3. Inadequate for Deep Faults: TDD may not effectively reveal deeper faults that require a
comprehensive understanding of the code such as those uncovered by data flow testing.
4. Learning Curve: TDD may have a steep learning curve for developers who are new to the
practice, as it requires a shift in mindset and workflow.
5. Time-Consuming: Initially, TDD may seem time-consuming as developers need to write tests
alongside the code, which can slow down the development process compared to traditional
methods.
Disadvantages of TDD:
1. Dependency on Test Frameworks: TDD heavily relies on test frameworks, and without them,
it becomes challenging to practice TDD effectively.
2. Limited Design Opportunities: The bottom-up nature of TDD may limit opportunities for
elegant design as it focuses on incremental improvements through refactorings.
3. Inadequate for Deep Faults: TDD may not effectively reveal deeper faults that require a
comprehensive understanding of the code such as those uncovered by data flow testing.
4. Learning Curve: TDD may have a steep learning curve for developers who are new to the
practice, as it requires a shift in mindset and workflow.
5. Time-Consuming: Initially, TDD may seem time-consuming as developers need to write tests
alongside the code, which can slow down the development process compared to traditional
methods.
Example for Boundary Value Testing: Suppose a function is designed to accept an integer
value from 1 to 100 inclusive. Boundary would generate test cases for values at and around the
boundaries:
Just below the minimum boundary [e.g., 0]
At the minimum boundary [e.g., 1]
Just above the minimum boundary [e.g., 2)
Just below the maximum boundary [e.g., 99]
At the minimum boundary [e.g., 100)
Just above the maximum boundary [e.g., 101)