Title: STG: A Symbolic Test Generation Tool
1STG A Symbolic Test Generation Tool
- D.Clarke, T.Jéron, V.Rusu, E.Zinovieva
- August 27, 2002
2Black-Box Conformance Testing
Systems Implementation
Is there a difference between expected and actual
behavior of the system?
Specification, Test Purposes
- Automatic Test Case Generation
- TorX
- TGV
- STG
- etc.
Executable Test Case
Test Execution
Inconclusive
Fail
Pass
3Problems with LTS and Solution
Possible
- State-space explosion
- Test cases are not readily understandable.
Use a new model and symbolic techniques to
produce a test case!
4Input/Output Symbolic Transition System
Specification
Test Purpose
Return ! (mRemVal)
(mBev COFFEE) Deliver ! (mBev)
Cancel ?
Coffee Machine
5STG Architecture
Test Case IOSTS
Specification IOSTS
Specification NTIF
Translation IOSTS to C
Translation NTIF to IOSTS
Symbolic Test Generation
Test Purpose IOSTS
- Product
- Closure
- Selection
- Simplification
- Adding Verdicts.
Executable Test Program C
STG
Test Purpose NTIF
6Test Case IUT
pPricegt0
BeverageType ChooseBeverage
(BeverageType mBev) cerr ltlt
"ChooseBeverage(" if(mBev COFFEE)
cerr ltlt TEA)" return TEA
if(mBev TEA) cerr ltlt "TEA)"
return TEA
Coin ! (mCoinVal) vPaid0mCoinVal
(vPaidltpPrice) (mRemValpPrice-vPaid) Return ?
(mRemVal)
(vPaidgtpPrice) (mRemValvPaid-pPrice) Return
? (mRemVal) vPaidpPrice
(vBevmBev) not (mBevCOFFEE) Deliver ? (mBev)
ChooseBeverage ! (mBev) vBev mBev
(vBevmBev) (mBevCOFFEE) Deliver ? (mBev)
not (vBevmBev) Deliver ? (mBev)
Fail
Coffee Machine
7Simplified Test Case
Coffee Machine
8Demo Time
9Case Study
- 3GPP Card is a multi-application microprocessor
smart card - File System
- Specification has about 100 transitions, 50
locations, 30 variables.
- CEPS is a standard for creating inter-operable
multi-currency smart card e-purse system - CEP Inquiry Slot Information
- Specification has about 100 transitions, 40
variables.
Smart Cards
103GPP Card Specification
vCurrPhasemanufacturing
vCurrPhaseutilization
vCurrPhaseutilization
! vMFcreated
See original specification for more details
11Test Purpose search_record
Begin
ResetCardCold?
ChoosePhase
CurrPhaseutilization
CurrPhasemanufacturing
Reject
ResetCardWarm?
mReply x61 Reply!(mReply)
See original test purpose for more details
Accept
12Demo Time
13Some References
- STG is available at
- http//www.irisa.fr/pampa/perso/rusu/stg
- The papers are available at
- http//www.irisa.fr/prive/lenaz/research/research.
html - jeronrusu_at_irisa.fr - for hard questions
- lenaz_at_irisa.fr - for simple questions ? .