Software Testing Flashcards
what is the prepose of testing?
1- to show that a program does what it is suppose to do
2- discover program defects
When you test software, you execute a program using …. WHAT?
artificial data
in program testing You check the results of the test run for errors, anomalies or information about the program’s (functional OR non-functional) attributes?
non-functional
T/F in program testing it Can reveal the presence of errors NOT their absence.
T
Testing is part of a more GENERAL …………… and …………..process
verification and validation
Testing is part of a more general verification and validation process, which also includes ……….. …………. Techniques
static validation.
Program testing goals are:
- to show the developer and customer that the software meets requirements
- identify cases where the software behaves incorrectly, undesirably , not to its specification
for which software (custom / generic) is that there should be at least one test for every requirement in the requirements document.
Custom Software
for which software (custom / generic) is that there should be tests for all of the system features, plus combinations of these features, that will be incorporated in the product release.
Generic software
DEF is concerned with rooting out undesirable system behavior:
Defect testing
what is the first goal in program testing to….. WHAT?
validation testing
(defect or validation) testing expect the system to perform correctly using a given set of test cases that reflect the system’s expected use?
validation testing
(defect or validation) testing The test cases are designed to expose defects?
defect testing
the test cases in (defect or validation) testing can be deliberately obscure and need not reflect how the system is normally used?
defect
in validation testing:
You expect the system to perform correctly using a given set of …….. …….. that reflect the system’s expected use
test cases
why are you giving a set of test cases in validation testing?
to reflect the system’s expected use.
(defect or validation) testing
Demonstrates to the developer and customer that the software meets requirements.
validation
(defect or validation) testing
A successful test shows the system works as intended.
validation
(defect or validation) testing
Identifies faults where behavior is incorrect or deviates from the specification.
defect
(defect or validation) testing
Identifies faults where behavior is incorrect or deviates from the specification.
defect
in (Verification vs validation) we ask “Are we building the product right”. ?
verfication
(Verification vs validation)
The software should conform to its specification.
verification
in (Verification vs validation) we ask
“Are we building the right product”?
validation
Verification vs validation
The software should do what the user really requires.
validation
a ………test [in defect testing] is a test that makes the system perform incorrectly and so exposes a defect in the system.
Successful
DEF Concerned with analysis of the static system representation to discover problems:
Software inspections
Software inspections May be supplement by ………. ……………… and ……. ……………
tool-based document and code analysis.
DEF Concerned with exercising and observing product behavior:
Software testing
Software (inspections or testing) is called static verification?
Inspection
Software (inspections or testing) is called dynamic verification?
testing
DEF These involve people examining the source representation with the aim of discovering anomalies and defects:
Software inspections
T/F Software Inspections not require execution of a system so may be used before implementation.
T
They have been shown to be an effective technique for discovering program errors.????
Software inspections
During (متى؟), errors can mask (hide) other errors
testing
Advantages of inspections: (3)
- Prevent hidden errors through static analysis, avoiding error interactions.
- Can inspect incomplete systems without needing costly test setups.
- Identify defects and evaluate broader qualities like compliance, portability, and maintainability.
in inspection If a program is incomplete, then you need to develop ……………. …………….to test the parts that are available.
test harnesses
T/F :Inspections and testing are complementary and not opposing verification techniques.
T
T/F: Inspections and testing Both should be used during the V & V process.
T
DEF: can check conformance with a specification but not conformance with the customer’s real requirements:
inspections
DEF CANNOT check non-functional characteristics such as performance, usability, etc:
inspections
name the three stages of testimg:
- Development testing
- Release testing
- User testing
which testing stage is “where the system is tested during development to discover bugs and defects.” ?
Development testing
which testing stage is “where a separate testing team test a complete version of the system before it is released to users.”?
Release testing
which testing stage is “where users or potential users of a system test the system in their own environment.”
user testing
DEF includes all testing activities that are carried out by the team developing the system.
development testing
what are the three kind of testing in development testing?
unit, component, system testing
which development testing part is “where individual program units or object classes are tested.”
unit testing
Unit testing should focus on testing the functionality of what?
object or methods
which development testing part is “where several individual units are integrated to create composite components”
component testing
Component testing should focus on testing what?
component interfaces.
which development testing part is “, where some or all of the components in a system are integrated and the system is tested as a whole”
System testing
System testing should focus on testing What?
component interactions
DEF the process of testing individual components in isolation:
unit testing
Unit testing is a (defect or validation) testing process????
DEFECT
Units in Unit testing can be: (3)
- Functions or methods.
- Object classes with attributes and methods.
- Composite components with defined interfaces.
unit testing should be (automated or manual)?
automated
(why?)so that tests are run and checked without manual intervention.
In automated unit testing, you make use of WHAT?
test automation framework
like: JUnit
(why?) to write and run your program tests.
What do unit testing frameworks provide?
Generic test classes to create specific test cases
How do unit testing frameworks report test results?
through a (GUI)
what are the automated test components?
- A setup part
- A call part
- An assertion part
which automated testing component iswhere you initialize the system with the test case, namely the inputs and expected outputs?
setup
which automated testing component is where you call the object or method to be tested.
call
which automated testing component is where you compare the result of the call with the expected result?
assertion
what does the assertion part compare in automated testing?
the result of the call with the expected result.
in the assertion part of automation testing what happens If the assertion is true?
the test is successful
in the assertion part of automation testing what happens If the assertion is false?
test failed
what should the unit test cases do?(2)
- Show the component works as expected.
- Reveal any defects in the component.
what are the two types of unit testing?
- Test normal operations to ensure expected behavior.
- Test abnormal inputs to catch and handle common problems.
what are two types of testing strategies?
- partition testing
- guideline-based testing
in the second type of unit testing what kind of inputs should we use?
abnormal inputs
why should we use abnormal inputs in unit test cases?
to find common problems, ensuring they are handled properly without crashing the component.
which testing strategy is where you identify groups of inputs that have common characteristics and should be processed in the same way?
partition testing
T/F in partition testing You should choose tests from within each of these groups.
T
which testing strategy is where you use testing guidelines to choose test cases?
Guideline-based testing
In guideline-based testing, guidelines are based on ………. ……………. of common programming ………….during component development.
previous experience
errors
DEF Input data and output results often fall into different classes where all members of a class are related.
partition testing
what are the classes in partition testing called?
equivalence partition or domain
In partition testing, how should test cases be selected?
they should be chosen from each partition.
which testing strategy Tests software with sequences which have only a single value?
Testing guidelines (sequences)
T/F in testing guidelines it Uses sequences of different sizes in different tests.
T
why do we need to derive tests in testing guidelines tests ?
tests so that the first, middle and last elements of the sequence are accessed.
Software components are often …………………………………….that are made up of several interacting objects.
composite components
How do you access the functionality of objects within a composite component?
Through the defined component interface.
What should testing of composite components focus on?
Showing that the component interface behaves according to its specification.
What can you assume has been completed when testing composite components?
Unit tests on the individual objects within the component.
What are the objectives of interface testing?
To detect faults
name the 4 interface types:
- Parameter interfaces
- Shared memory interfaces
- Procedural interfaces Sub-system
- Message passing interfaces Sub-systems
which interface type is Data passed from one method or procedure to another?
parameter interfaces
what interface type is a Block of memory is shared between procedures or functions?
Shared memory interfaces
what interface type is a Sub-system encapsulates a set of procedures to be called by other sub-systems?
Procedural interfaces
which interface type is a Sub-systems request services from other sub-systems
Message passing interfaces
name the 3 interface errors
- interface misuse
- Interface misunderstanding
- timing error
which interface error is A calling component calls another component and makes an error in its use of its interface
interface misuse
“parameters in the wrong order” is an example of which interface error?
Interface misuse
which interface error is A calling component embeds assumptions about the behaviour of the called component which are incorrect?
Interface misunderstanding
which interface error is The called and the calling component operate at different speeds and out-of-date information is accessed.
timing error
What is the main focus in system testing?
Testing the interactions between components.
What does system testing check regarding components?
That components are
1- compatible
2- interact correctly
3- transfer the right data at the right time
T/F: System testing tests the emergent behavior of a system.
T
What may be integrated with newly developed components during system testing?
Reusable components and off-the-shelf systems.
T/F: System testing is a collective rather than an individual process.
T
DEF define the required system test coverage may be developed:
Testing policies
DEF an approach to program development in which you inter-leave testing and code development:
Test-driven development (TDD)
T/F: In TDD, tests are written before the code is developed.
T
What is the critical driver of development in TDD?
passing the test
What must happen before moving to the next increment in TDD?
developed code must pass its test.
Which development method introduced TDD?
Agile methods
T/F: TDD can be used in plan-driven development processes
T
DEF testing the system to check that changes have not ‘broken’ previously working code:
Regression testing
T/F: manual testing process, regression testing is expensive
T
T/F in Regression testing with automated testing, it is simple and straightforward.
T/F
which stages of testing is Testing a particular release of a system intended for use outside the development team?
release testing
which stages of testing’s goal is To convince the supplier that the system is good enough for use?
Release testing
T/F: Release testing must show that the system delivers its specified functionality, performance, and dependability, and that it does not fail during normal use
T
what type of testing process is release testing?
black-box testing process
DEF Part of release testing may involve testing the emergent properties of a system:
performance testing
What emergent properties of a system are tested as part of release testing?
Performance and reliability.
What should tests reflect during performance testing?
The profile of use of the system.
True or False: Performance tests involve increasing the load until the system performance becomes unacceptable.
t
DEF A form of performance testing where the system is deliberately overloaded to test its failure behavior:
stress testing
which stages of testing is : in which users or customers provide input and advice on system testing?
user testing
T/F: User testing is essential, even when comprehensive system and release testing have been carried out
T
what are the 3 types of user testing?
1- Alpha
2- beta
3- acceptance
which type of user testing is where Users of the software work with the development team to test the software at the developer’s site?
Alpha testing
which type of user testing is where A release of the software is made available to users to allow them to experiment and to raise problems that they discover with the system developers?
beta testing
which type of user testing is where Customers test a system to decide whether or not it is ready to be accepted from the system developers and deployed in the customer environment?
acceptance testing
which type of user testing is used Primarily for custom systems?
acceptance testing
What do software customers generally expect all software to be?
Dependable
Customers may accept some system failures for non-critical applications.
T
DEF are usually a result of system errors that are derived from faults in the system
Failures
T/F: faults do not necessarily result in system errors
t
TorF : Errors do not necessarily lead to system failures
T
three types of fault management:
fault avoidance
fault detection
fault tolerance
which fault manag.. is this: Verification and validation techniques are used to discover and remove faults in a system before it is deployed.
Fault detection
which fault manag.. is this: The system is designed so that faults in the delivered software do not result in system failure.
Fault tolerance
which fault manag.. is this: development process is organised so that faults in the system are detected and repaired before delivery to the customer?
Fault avoidance