Tải bản đầy đủ (.pdf) (92 trang)

Integration & System Testing potx

Bạn đang xem bản rút gọn của tài liệu. Xem và tải ngay bản đầy đủ của tài liệu tại đây (1.01 MB, 92 trang )

Integration & System
Testing
2
Contents
 Levels of Testing
 Integration Testing
 System Testing
 Additional System Test Categories
3
Levels of Testing
4
Levels of Testing
 Waterfall model
Requirements
Specification
Preliminary
Design
Detailed
Design
Coding
Unit
Testing
Integration
Testing
System
Testing
5
Levels of Testing
 Unit testing
 Integration Testing
 System Testing


 Acceptance Testing
 Regression Testing
6
Unit testing
 Lowest Level of Testing
 Individual unit of the software is tested in
isolation from other parts of a program
 What can be a unit?
 Function / method / module / class / component
 Screen / Program
 Back-end related to a Screen
 Screen + back end
7
Unit testing
 Uncover errors in design and implementation,
including
 data structure in a unit
 program logic and program structure in a unit
 unit interface
 functions and operations of a unit
 Unit testers
 developers of the units
8
Integration Testing
 Intermediate level of testing
 Group of dependent components are tested together
 Test that evaluates the interaction and consistency of interacting
components
 Uncover errors in:
 Design and construction of software architecture

 Integrated functions or operations at sub-system level
 Interfaces and interactions between them
 Resource integration and/or environment integration
 Integration testers
 either developers and/or test engineers
9
System Testing
 Test the whole system
 Test end to end functionality
 Testing against complete requirement
 Requirement focus
 Test cases derived from specification
 System testers
 test engineers
10
Acceptance Testing
 User (or customer) involved
 Environment as close to field use as possible
 Focus on:
 Building confidence
 Compliance with defined acceptance criteria in
the contract
11
Regression Testing
 Testing activities occur after software changes
 Regression testing usually refers to testing activities
during software maintenance phase
 Retest changed components (or parts)
 Check the affected parts (or components)
 Who perform regression testing

 Developers - regression testing at the unit level or integration
 Test engineers - regression testing at the function level
 QA and test engineers - regression testing at the system level
12
Example: SATM
 Simple Automatic Teller Machine (SATM)
 reduced commercial ATM system
 hundreds of screens
 Has 15 screens
 Used to illustrate some testing approaches
 Integartion testing, system testing
13
Example: SATM
 Decomposed by screens
 screen1 welcome
 screen2 enter PIN
 screen3 wrong PIN
 screen4 PIN failed, card retained
 screen5 select trans type
 screen6 select account type
 screen7 enter amount
 screen8 insufficient funds
 screen9 cannot dispense that amount
 screen10 cannot process withdrawals
 screen11 take your cash
 screen12 cannot process deposits
 screen13 put dep envelop in slot
 screen14 another transaction?
 screen15 Thanks; take card and receipt
14

Example: SATM
15
Example: SATM
 Functional
decomposition
16
Example: SATM
17
Example: SATM
18
Integration Testing
19
Goals of Integration Testing
 Presumes previously tested units
 Not system testing (at level of system inputs
and outputs)
 Tests functionality "between" unit and system
levels
 Simulation of other components/units
 Stubs receive output from test objects
 Drivers generate input to test objects
20
Approaches to Integration
Testing
 Based on Functional Decomposition
 Big Bang
 Top-Down
 Bottom-Up
 Sandwich
 Based on Call Graph

 Pair-wise integration
 Neighborhood integration
 Based on Paths
 MM-Paths
 Atomic System Functions
21
Integration Testing Based on
Functional Decomposition
 SATM Functional Decomposition Tree
22
Approaches to Integration
Testing
 Based on Functional Decomposition
 Big Bang
 Top-Down
 Bottom-Up
 Sandwich
 Based on Call Graph
 Pair-wise integration
 Neighborhood integration
 Based on Paths
 MM-Paths
 Atomic System Functions
23
Big bang Integration
Combine (or integrate) all parts at once
 Advantages
 simple
 Disadvantages
 hard to debugging, not easy to isolate errors

 not easy to validate test results
 impossible to form an integrated system
24
Top-down integration
 Begins with the main program (the root of the tree)
 Needs the stubs
 receive output from test objects
 Testers have to develop the stubs
 Stub example
 returns a PIN instead of looking-up in a table
Procedure GetPINforPAN (PAN, ExpectedPIN) STUB
IF PAN = '1123' THEN PIN := '8876';
IF PAN = '1234' THEN PIN := '8765';
IF PAN = '8746' THEN PIN := '1253';
End,
25
Top-down integration
 Integration process
1. The main control module is used as a test driver, and the stub
are substituted for all modules directly subordinate to the main
control module
2. Subordinate stubs are replaced one at a time with actual
modules
3. Tests are conducted as each module is integrated
4. On completion of each set of tests, another stub is replaced with
the real module
5. Regression testing may conducted
 Pros and cons top-down integration
 stub construction cost
 major control function can be tested early

×