4452 - Testing Final Flashcards
What does statistical testing reflect and what does it measure?
reflects: frequency of user inputs
measures: system reliability
What does defect testing discover?
system defects
What are the 4 testing stages?
- unit testing
- integration testing
- system testing
- user/acceptance testing
What is unit testing?
the testing of individual components
What is integration testing?
the testing of interactions between components
What is system testing?
testing the complete system prior to delivery
What is acceptance testing?
testing done by end users to ensure that the system delivers on business and user needs
What is black box testing?
Its where something is inputted to the system and then the output is compared to the expected output
What is white box testing?
Its where the input is selected with explicit knowledge of the internal workings of the system
What types of testing are included in the white box test suite?
- edge (decision) testing
- path testing
- statement testing
- condition testing
What is regression testing? What does it ensure?
- Regression testing is used to make sure that a defect fix, added functionality, really any changes to the code does not change functionalities or behaviors that should not be affected
- ensures that modified code has not broken the code it modified
What are the two broad techniques used during unit testing?
functional testing and structural testing
What are the two types of structural testing methods? What is the difference between them?
Control flow testing, data flow testing
- one is based on control flow graphs the other is based on data flow graphs
What does integration testing attempt to construct?
the system architecture
Integration testing wants to uncover defects associated with what?
interfaces
When is integration testing complete?
- when all modules are fully integrated together
- when all the test cases have been executed
- when all the severe and moderate defects have been found and fixed
What does system testing check the system against?
the quality requirements
A system must be constructed in a ________ for system testing to be performed
an emulated environment that is as close to the real production environment as possible
Where is acceptance testing performed and who performs it?
in the production environment by the end users
what is the key difference between testing and debugging?
testing confirms the presence of defects, debugging actually locates and fixes them
What are the activities in testing?
IDBEC:
- identify
- design
- build
- execute
- compare
What is “built” during the build activity in testing?
test cases
What are the activities in debugging?
LDRRe
- locate
- design
- repair
- re-test
What is a test condition?
it is the goal of a test case, it is something you want to verify
What does a test case consist of?
test data to be inputted and an expected output
What is a test set?
a collection of test cases
What do test scripts contain?
data and instructions for testing
What is the system that performs the checking of the observed behavior referred to as?
oracle
program behavior can be specified in which three ways?
- plain natural language
- state diagrams
- formal mathematical specifications
What are automated oracles?
a pre determined input output relationship that is checked for all outputs
What is considered completeness for functionality testing and structural testing?
functional; the behavior of all functional partitions are tested
structural; all statement, all branches, all loops
What are the three reasons for test stopping?
- budget exceeded or deadline needs to be met
- desired coverage reached
- desired level of failure intensity reached
What does boundary value testing do?
targets failures in application at the boundary of the equivalence classes
what does equivalence class partitioning do?
selects partitions from WITHIN equivalence classes
boundary value testing and equivalence partitioning tests may overlap (T/F)
T
What are nodes in a CFG?
statements or groups of statements
what are edges in CFG?
the flow of control; there is an edge between i and j if j can be executed immediately after i completes
what is statement coverage?
run tests until all statements have been executed
what is edge coverage?
run tests until all edges in control flow graph have been executed at least once
what is condition coverage?
like edge coverage but with additional attention being paid to conditionals - ensuring that all combinations have been tested
what is path coverage?
ensuring that all paths (start node to end node) have been executed multiple times
for loop based paths what test cases should you write?
three cases:
- skip the loop
- execute it once
- execute it multiple times
what does the driver component do in unit tests?
it takes test case data and passes it into the component being tested and returns the results
what do stubs do? what MUST they use?
replace the modules that are subordinate to the subsystem being tested. They MUST use the modules exact interface
why is test selection difficult?
because of two aspects of the input domain for the partition; its large size and complexity
how does equivalence portioning solve the input domain size issue?
by creating a relatively small number of disjoint sub-domains that allow the system to be tested with N test cases for N sub domains or partitions
what are the two objectives for test generation?
completeness and efficiency
what is the difference between weak and strong equivalence class testing?
weak; uses one variable from each equivalence class in a test case strong; uses the Cartesian product of the partition subset
what is the minimum number of test cases that can be in weak equivalence class testing?
the number of classes in the partition with the largest number of subsets
in strong equivalence classes the interactions between the represented values and any ______ is tested?
subsets
What is the foundation for partitioning equivalence classes?
expected behavior
what is the difference between normal and robust testing strategies
normal: equivalence classes of valid values of inputs
robust: equivalence classes of valid and invalid values of inputs
what is efficiency for equivalence classes?
identify test cases using only one element from each equivalence classes
what ratio is effectiveness evaluated on for equivalence class testing
failures exposed by equivalence class testing vs total failures in the system
what is the typically effectiveness of equivalence partitioning?
less than 1
what are ways to improve the effectiveness of equivalence class testing?
- unambiguous and complete specifications of the requirements
- carefully selected equivalence partitioning
what is uni dimensional partitioning for compound data types?
when you consider only 1 variable at a time
what is multi-dimensional partitioning for compound data types?
the input domain is the set product of the the variable inputs
what are the 4 steps of equivalence classing?
- identify the input domain
- equivalence classing: partition the set of values of each variable into disjoint subsets
- combine the equivalence classing
- identify the infeasible equivalence classes
what is the main source for identifying inputs and outputs for equivalence testing?
the software requirements
input variables don’t include environmental variables (T/F)
F; they do
how can equivalence classes be defined?
using multidimensional partitioning
what inputs are used in infeasible equivalence classes?
inputs that cannot be generated during the test
what are the three steps to boundary value testing?
- partition the input domain
- identify the boundary
- select test data
when does BVA work well?
when program to be tested is a function of several independent variables that are physically bounded quantities and when the selected test data is chosen with no consideration for the function of the program or the semantic meaning of the variable
what do decision variables make easier?
to make sure all possible conditions have been accounted for
what is logic based modeling?
associating conditions with actions to be performed
what are default rules in limited entry decision tables?
indicate actions to be taken when none of the rules apply
what must you ensure before using a decision table?
that the rules are complete and consistent
how do you create a decision table? (what are the steps)
- determine the actions, conditions and values, and how many rules you want to specify
- encode all the possible rules and the actions for each rule
- reduce where you can
what is TAP?
test anything protocol :)
what does it mean that drivers and stubs are considered “overhead”?
they must be written but are not considered part of the testing software product
what is the mocha testing tool based off of?
the javasript test framework
what runs mocha on server and client side
node-js and browser
mocha tests run asynchronously (T/F)
True
mocha test run in parallel (T/F)
False; they run serially
what is a test runner?
the driver; takes test cases and returns results
what is a test fixture?
a test environment used by multiple test cases
what does TAP allows in terms of communications?
it allows for communication between unit tests and the test harness
what is the test harness?
the automated test framework
what was tap initially designed for and when?
for the perl interpreter in 1987
what are the two inputs of the describe function in mocha?
the name of the test group and the all back function
what are the two inputs of the it function
the name of the test case and the call back function that contains the actual test
what is the difference between the it and describe function
describe –> test group (higher level)
it –> test case
what are the 4 hooks in mocha?
- beforeEach
- afterEach
- after
- before
what runs first beforeEach() or before()?
before
what does SDK testing use for white box testing?
user code test coverage reports
what kind of testing does api testing use?
black box testing
what does api testing use of the server side?
REST
what function are stubs written in for EQT?
beforeEach and afterEach
what does the spy function solve?
it prevents the program from not calling subsequent arguments after an invalid return
what are the three types of functional testing?
- equivalence class
- boundary value
- decision table
what three basic metrics can be used to evaluate functional testing methods?
- effort
- efficiency
- effectiveness