distributed tes ng
play

Distributed Tes,ng R. M. Hierons Brunel University, UK - PowerPoint PPT Presentation

Distributed Tes,ng R. M. Hierons Brunel University, UK rob.hierons@brunel.ac.uk h@p://people.brunel.ac.uk/~csstrmh TAROT 2010 Work With Mercedes Merayo Manuel Nunez


  1. Distributed ¡Tes,ng ¡ R. ¡M. ¡Hierons ¡ Brunel ¡University, ¡UK ¡ rob.hierons@brunel.ac.uk ¡ h@p://people.brunel.ac.uk/~csstrmh ¡ TAROT 2010

  2. Work ¡With ¡  Mercedes ¡Merayo ¡  Manuel ¡Nunez ¡  Jessica ¡Chen ¡  Hasan ¡Ural ¡ TAROT 2010

  3. Mul,-­‑port ¡systems ¡ • Physically ¡distributed ¡interfaces/ports. ¡ • A ¡tester ¡at ¡each ¡port. ¡ tester tester SUT tester TAROT 2010

  4. Distributed ¡tes,ng ¡  Mainly ¡focus ¡on ¡the ¡simplest ¡approach: ¡  The ¡testers ¡cannot ¡communicate ¡with ¡one ¡another ¡  There ¡is ¡no ¡global ¡clock ¡  Observa,ons ¡are ¡‘local’ ¡ TAROT 2010

  5. Mo,va,on ¡  Ini,ally ¡just ¡tes,ng/test ¡genera,on. ¡  The ¡discussion ¡will ¡be ¡around ¡both ¡ • tes%ng ¡and ¡ • implementa%on/conformance ¡rela%ons . ¡  Tes,ng ¡from: ¡ • input ¡output ¡transi,on ¡systems ¡and ¡ • a ¡few ¡notes ¡on ¡finite ¡state ¡machines ¡ TAROT 2010

  6. Tes,ng ¡and ¡Observa,ons ¡ TAROT 2010

  7. Global ¡Traces ¡ • A ¡global ¡trace ¡is ¡a ¡sequence ¡of ¡inputs ¡and ¡ outputs. ¡ • We ¡assume ¡there ¡are ¡m ¡ports ¡and: ¡ – x p ¡will ¡denote ¡an ¡input ¡at ¡port ¡p ¡(from ¡X p ) ¡ – (y 1 ,...,y m ) ¡ ∈ Y, ¡Y=(Y 1 ∪ {-­‑}) × … × (Y m ∪ {-­‑}), ¡will ¡be ¡an ¡ output ¡ • A ¡global ¡trace ¡is ¡an ¡element ¡of ¡(X ¡ × ¡Y)* ¡ ¡ TAROT 2010

  8. Consequences ¡ • Each ¡tester ¡observes ¡only ¡the ¡interac,ons ¡( local ¡ trace ) ¡at ¡its ¡port ¡ Tester 1 SUT Tester 2 x 1 y 1 y 2 x 1 y 1 • The ¡tester ¡at ¡port ¡1 ¡observes ¡x 1 y 1 x 1 y 1 ¡and ¡the ¡tester ¡ at ¡2 ¡observes ¡y 2 ¡only. ¡ TAROT 2010

  9. What ¡the ¡testers ¡observe ¡ • Given ¡global ¡trace ¡z, ¡the ¡tester ¡at ¡p ¡observes ¡a ¡ local ¡trace ¡ π p (z) ¡. ¡ Tester 1 Tester 2 x 1 y 1 y 2 x 1 y 1 TAROT 2010

  10. Controllability ¡problems ¡ • The ¡following ¡test ¡has ¡a ¡controllability ¡ problem: ¡introduces ¡nondeterminism ¡into ¡ tes,ng. ¡ tester SUT tester TAROT 2010

  11. Observability ¡problems ¡ • The ¡following ¡look ¡the ¡same ¡ tester Spec tester tester SUT tester x 1 x 1 y 1 y 1 y 2 x 1 x 1 y 2 y 1 y 1 • Testers/users ¡cannot ¡‘map’ ¡output ¡to ¡input ¡ TAROT 2010

  12. Equivalent ¡global ¡traces ¡ • Since ¡we ¡only ¡observe ¡local ¡traces: ¡ – Global ¡traces ¡z ¡and ¡z’ ¡are ¡indis,nguishable ¡if ¡their ¡ projec,ons ¡are ¡iden,cal: ¡the ¡local ¡traces ¡are ¡the ¡ same. ¡ – We ¡denote ¡this: ¡z ∼ z’ ¡ • The ¡following ¡are ¡equivalent ¡under ¡ ∼ ¡ – x 1 /(y 1 ,y 2 )x 1 /(y 1 ,-­‑) ¡ – x 1 /(y 1 ,-­‑)x 1 /(y 1 , ¡y 2 ) ¡ • Both ¡have ¡x 1 y 1 x 1 y 1 ¡at ¡port ¡1 ¡and ¡y 2 ¡at ¡2. ¡ TAROT 2010

  13. Problem: ¡Test ¡effec,veness ¡is ¡not ¡ monotonic ¡ • Example: ¡x 1 ¡detects ¡a ¡fault ¡but ¡x 1 x 1 ¡does ¡not. ¡ ¡ tester SUT tester tester Spec tester x 1 x 1 y 1 y 1 y 2 x 1 x 1 y 2 y 1 y 1 TAROT 2010

  14. Two ¡approaches ¡to ¡defining ¡ implementa,on ¡rela,ons ¡ • We ¡might ¡have: ¡ – Agents ¡at ¡ports ¡are ¡en,rely ¡‘independent’: ¡ • No ¡external ¡agent ¡can ¡receive ¡informa,on ¡regarding ¡ observa,ons ¡at ¡more ¡than ¡one ¡port ¡ – Or ¡the ¡local ¡traces ¡observed ¡at ¡the ¡ports ¡can ¡be ¡ ‘brought ¡together’ ¡later. ¡ TAROT 2010

  15. Differences ¡  Specifica,on ¡ Tester 1 Tester 2 Tester 1 Tester 2 x x y y' z z'  SUT ¡ Tester 1 SUT Tester 2 x y' z TAROT 2010

  16. Using ¡an ¡external ¡network ¡ • If ¡we ¡connect ¡the ¡testers ¡using ¡an ¡external ¡ network, ¡ some%mes ¡ we ¡can ¡overcome ¡ controllability ¡and ¡observability ¡problems. ¡ tester SUT tester tester SUT tester TAROT 2010

  17. But ¡  If ¡a ¡system ¡has ¡physically ¡distributed ¡interfaces ¡ then ¡the ¡implementa,on ¡rela,on ¡should ¡ reflect ¡this: ¡  Even ¡if ¡we ¡can ¡connect ¡the ¡testers, ¡we ¡should ¡be ¡ careful ¡that ¡we ¡do ¡not ¡give ¡the ¡verdict ¡fail ¡when ¡ the ¡behaviour ¡is ¡acceptable ¡in ¡use. ¡  The ¡users ¡will ¡only ¡observe ¡local ¡traces . ¡ TAROT 2010

  18. Past ¡research ¡ • Mainly ¡on ¡tes,ng ¡from ¡a ¡determinis,c ¡finite ¡ state ¡machine ¡(DFSM): ¡ – Genera,ng ¡test ¡sequences ¡that ¡do ¡not ¡suffer ¡from ¡ controllability ¡and/or ¡observability ¡problems ¡ – Adding ¡coordina,on ¡messages ¡(possibly ¡adding ¡a ¡ minimum ¡number). ¡ TAROT 2010

  19. Problems/issues ¡ • A ¡DFSM ¡can ¡have ¡transi,ons ¡that ¡can’t ¡be ¡ executed ¡without ¡controllability ¡problems. ¡ • Test ¡genera,on ¡algorithms ¡place ¡condi,ons ¡on ¡ the ¡DFSM ¡– ¡they ¡are ¡not ¡general. ¡ • The ¡methods ¡test ¡against ¡the ¡‘tradi,onal’ ¡ implementa,on ¡rela,on ¡– ¡aiming ¡to ¡do ¡too ¡ much? ¡ • Using ¡DFSMs ¡is ¡restric,ve. ¡ TAROT 2010

  20. The ¡solu,on ¡  We ¡need ¡a ¡good ¡understanding ¡of ¡what ¡it ¡ means ¡to ¡dis,nguish ¡two ¡models ¡with ¡ distributed ¡ports. ¡  This ¡gives ¡us ¡new ¡implementa,on ¡rela,ons. ¡  We ¡want ¡to ¡test ¡against ¡these. ¡ TAROT 2010

  21. Input ¡Output ¡Transi,on ¡Systems ¡ (IOTSs) ¡ TAROT 2010

  22. The ¡models ¡ • These ¡are ¡labelled ¡transi,on ¡systems ¡in ¡which ¡ we ¡dis,nguish ¡between ¡input ¡and ¡output. ¡ • We ¡have ¡states ¡and ¡transi,ons ¡between ¡the ¡ states. ¡ • Nota,on: ¡ – Normally ¡we ¡precede ¡the ¡name ¡of ¡an ¡input ¡by ¡? ¡ and ¡the ¡name ¡of ¡an ¡output ¡by ¡!. ¡ TAROT 2010

  23. Internal ¡events ¡and ¡quiescence ¡ • We ¡have ¡two ¡special ¡types ¡of ¡events: ¡ – Internal ¡events ¡(τ) ¡are ¡state ¡transi,ons ¡that ¡do ¡not ¡ require ¡input ¡and ¡do ¡not ¡produce ¡output. ¡ – A ¡state ¡s ¡is ¡quiescent ¡if ¡from ¡s ¡output ¡cannot ¡be ¡ produced ¡without ¡first ¡providing ¡input. ¡ – If ¡s ¡is ¡quiescent ¡then ¡we ¡add ¡a ¡self-­‑loop ¡transi,on ¡ from ¡s ¡with ¡label ¡δ. ¡ TAROT 2010

  24. A ¡simple ¡example ¡ • A ¡(very) ¡simple ¡coffee ¡machine ¡ ?1 ?2 !tea !coffee • We ¡have ¡not ¡shown ¡the ¡self-­‑loops ¡for ¡ quiescence. ¡ TAROT 2010

  25. IOTS ¡models ¡  IOTS ¡models ¡are ¡more ¡general ¡than ¡FSMs: ¡  They ¡can ¡be ¡infinite ¡state ¡models ¡  Input ¡and ¡output ¡need ¡not ¡alternate ¡  There ¡can ¡be ¡internal ¡(unobservable) ¡ac,ons. ¡  We ¡assume: ¡  IOTSs ¡are ¡input ¡enabled ¡  We ¡can ¡observe ¡quiescence ¡ TAROT 2010

  26. Implementa,on ¡rela,ons ¡  There ¡is ¡a ¡standard ¡implementa,on ¡rela,on ¡ (for ¡tes,ng) ¡called ¡ioco ¡  It ¡requires: ¡  If ¡σ ¡is ¡a ¡(suspension) ¡trace ¡of ¡the ¡specifica,on ¡s ¡ and ¡the ¡implementa,on ¡can ¡produce ¡output ¡!o ¡ aoer ¡σ ¡then ¡s ¡must ¡be ¡able ¡to ¡produce ¡output ¡!o ¡ aoer ¡σ ¡ TAROT 2010

  27. Two ¡equivalent ¡processes ¡ • We ¡cannot ¡dis,nguish ¡the ¡following: ¡ ?i 1 ?i 1 !o 2 !o 1 !o 1 !o 2 • Note: ¡assume ¡processes ¡completed ¡to ¡make ¡ them ¡input-­‑enabled. ¡ TAROT 2010

  28. Issue ¡ • When ¡can ¡we ¡‘bring ¡together’ ¡local ¡ observa,ons’? ¡ ?i 1 ?i 1 !o 2 !o 1 !o 1 !o 2 • In ¡this ¡example ¡not ¡aoer ¡?i 1 !o 1 ¡or ¡?i 1 !o 2 ¡ TAROT 2010

  29. When ¡do ¡we ¡make ¡observa,ons? ¡ • For ¡an ¡FSM ¡we ¡observe ¡the ¡projec,ons ¡of ¡ input/output ¡sequences ¡-­‑ ¡we ¡can ¡‘stop’ ¡aoer ¡ an ¡input/output ¡sequence. ¡ • When ¡can ¡we ¡‘stop’ ¡when ¡considering ¡IOTSs? ¡ Possibly: ¡ – Whenever ¡we ¡have ¡quiescence. ¡ • We ¡can ¡then ¡‘bring ¡together ¡local ¡traces’ ¡ TAROT 2010

Download Presentation
Download Policy: The content available on the website is offered to you 'AS IS' for your personal information and use only. It cannot be commercialized, licensed, or distributed on other websites without prior consent from the author. To download a presentation, simply click this link. If you encounter any difficulties during the download process, it's possible that the publisher has removed the file from their server.

Recommend


More recommend