Chapter 4 Flashcards
difference between test analysis and test design?
test analysis- what to test
test design - how to test
3 test techniques are black box, white and experience based. what are they each?
black box - no reference to internal structure. specification based. test cases independent of how software is implemented
white box -structure based, analysis on test objects internal structure and processing. test cases dependant on design
experience based- uses knowledge of testers for design and implementation of test cases. can detect defects that may have been missed in white and black box
First black box technique? - Equivalence partitioning:
divides data into partitions, based on the expectations that all elements of a given partition are processed the same way.
one test for each partition is sufficient
partitions must not overlap
coverage items are in the EP - to achieve 100% coverage, test cases must exercise all partitions including invalid.
coverage is measured as the number of partitions exercised by at least 1 test case/ total number of partitions
second black box technique? Boundary value analysis ?
the minimum and maximum values of a partition is boundary values.
2-value-BVA : 2 coverage items for each value, the boundary and the closest number to it that doesn’t surpass the boundary.
3-value-BVA: for each boundary value there are three coverage items: this boundary value and both its neighbors. Therefore, in 3-value BVA some of the coverage items may not be boundary values.
3rd black box technique: decision table testing ?
Decision tables are a structured method used to test system requirements that outline how various conditions lead to specific outcomes. They efficiently document complex logic, such as business rules, by organizing conditions and resulting actions into rows and columns. The notation includes “T” for true, “F” for false, “-“ for irrelevant conditions, and “N/A” for infeasible ones. Testers aim for full coverage by exercising all feasible combinations of conditions.
4th black box technique? state transition testing
State transition diagrams and tables depict system states and transitions, while test cases follow sequences of events leading to state changes.
In all states coverage, every state must be visited to achieve 100% coverage, measured by the ratio of visited states to total states.
Valid transitions coverage focuses on exercising all valid transitions, measured by the ratio of exercised valid transitions to total valid transitions.
All transitions coverage extends to both valid and invalid transitions, aiming to avoid fault masking, and achieving it ensures complete coverage of both states and valid transitions, crucial for mission and safety-critical software.
2 white box techniques : statement testing?
aim: design test cases that exercise statements in the code until an acceptable level of coverage is achieved .
the coverage items are epxectibale statements
Achieving 100% statement coverage means every line of code has been executed at least once, potentially revealing defects in those lines. However, it doesn’t guarantee finding all defects, especially those dependent on specific data values. Additionally, it may not cover all decision logic, such as different branches in the code.
2nd white box technique: branch testing?
Branch testing involves exercising the branches in code, which are points where control can transfer to different paths. Achieving 100% branch coverage means all possible branches, including both unconditional and conditional ones, have been tested. However, like statement coverage, it doesn’t guarantee finding all defects, particularly those requiring specific paths through the code. Additionally, branch coverage encompasses statement coverage, meaning achieving 100% branch coverage also ensures 100% statement coverage.
value of white box testing?
White-box testing considers the entire software implementation, making it effective in detecting defects even when the software requirements are unclear or incomplete. However, it may miss defects caused by unimplemented requirements. White-box techniques are useful in static testing, such as code reviews, and provide objective measures of code coverage, allowing for the generation of additional tests to improve coverage and confidence in the code.
experience based test techniques?
- error guessing
-exploratory testing
-checklist based testing
error guessing?
anticipate errors and defects based on testers knowledge
-how application has worked in the past
-types of failures that have occurred in similar apps etc
In general, errors, defects and failures may be related to: input (e.g., correct input not accepted, parameters wrong or missing), output (e.g., wrong format, wrong result), logic (e.g., missing cases, wrong operator), computation (e.g., incorrect operand, wrong computation), interfaces (e.g., parameter mismatch, incompatible types), or data (e.g., incorrect initialization, wrong type).
Fault attacks involve systematically guessing potential errors, defects, and failures in a software system. Testers compile lists of possible issues based on experience, defect data, or common knowledge about software failures. They then design tests to identify, expose, or trigger these defects, helping improve the robustness and reliability of the software.
exploratory testing?
In exploratory testing, tests are simultaneously designed, executed, and evaluated while the tester learns about the test object. The testing is used to learn more about the test object, to explore it more deeply with focused tests, and to create tests for untested areas.
sometimes done using session based testing ,within defined time-box
-the tester uses test charter ( outlines the scope, objectives, and approach of a testing session or activity)
- followed by a debriefing that involves a discussion between the tester and stakeholders interested in the test results of the test session. In this approach test objectives may be treated as high-level test conditions.
pros/cons of exploratory testing?
Exploratory testing is useful when there are few or inadequate specifications or there is significant time pressure on the testing.
Exploratory testing is also useful to complement other more formal test techniques
Exploratory testing will be more effective if the tester is experienced, has domain knowledge and has a high degree of essential skills, like analytical skills, curiosity and creativeness
checklist based testing?
In checklist-based testing, a tester designs, implements, and executes tests to cover test conditions from a checklist.
Checklists can be built based on experience, knowledge about what is important for the user, or an understanding of why and how software fails.
Checklists should not contain items that can be checked automatically, items better suited as entry/exit criteria, or items that are too general
Checklist items are often phrased in the form of a question. It should be possible to check each item separately and directly
Some checklist entries may gradually become less effective over time because the developers will learn to avoid making the same errors.
how to write user story?
-card - the medium used to describe user story eg. electronic board
-conversation -explains how software will be used
-confirmation - acceptance criteria