TestWorks Conf The magic of models for 1000% test automation - Machiel van der Bijl

36
Axini Modeling and Model Based Testing ITAB SCRP protocol

Transcript of TestWorks Conf The magic of models for 1000% test automation - Machiel van der Bijl

Page 1: TestWorks Conf The magic of models for 1000% test automation - Machiel van der Bijl

Axini Modeling and Model Based Testing

ITAB SCRP protocol

Page 2: TestWorks Conf The magic of models for 1000% test automation - Machiel van der Bijl

Goal:

• Give a hands on impression of MBT with the Axini MBT tool-set

• For non-technical aspects, let’s discuss that after the presentation J

2

Page 3: TestWorks Conf The magic of models for 1000% test automation - Machiel van der Bijl

• Axini

• Machiel

3

Page 4: TestWorks Conf The magic of models for 1000% test automation - Machiel van der Bijl

4

What do you want to hear?

Page 5: TestWorks Conf The magic of models for 1000% test automation - Machiel van der Bijl

Contents

• Modeling and Model-Based Testing

• SCRP case– Intro

– Modeling and testing

5

Page 6: TestWorks Conf The magic of models for 1000% test automation - Machiel van der Bijl

6

MBT ingredients

Model AxiniTestManager SUT

test generationand execution

test-evaluation

Adapter

simulation

Page 7: TestWorks Conf The magic of models for 1000% test automation - Machiel van der Bijl

Test process

1. (Create specification)

2. Interpret specification

3. Create test

4. Predict outcome5. Execute test6. Check outcome

Page 8: TestWorks Conf The magic of models for 1000% test automation - Machiel van der Bijl

Kinds of test automation

UFT/CucumberAxini MBT

1. (Create specification)

2. Interpret specification

3. Create test

4. Predict outcome5. Execute test6. Check outcome

Page 9: TestWorks Conf The magic of models for 1000% test automation - Machiel van der Bijl

hand UFT MBT or

Create specification N N NInterpret specification N N N NCreate model - - N

Create test N N PPredict outcome N N Pscript test - N P

Execute test N P PCheck outcome N P P

Manual vs automatic

Page 10: TestWorks Conf The magic of models for 1000% test automation - Machiel van der Bijl

hand UFT MBT or

Create specification N N NInterpret specification N N N NCreate model - - N

Create test N N PPredict outcome N N Pscript test - N P

Execute test N P PCheck outcome N P P

Maintenance trap

Page 11: TestWorks Conf The magic of models for 1000% test automation - Machiel van der Bijl

Example

11

Page 12: TestWorks Conf The magic of models for 1000% test automation - Machiel van der Bijl
Page 13: TestWorks Conf The magic of models for 1000% test automation - Machiel van der Bijl

?button

!lamp on

?button

!lamp off

Page 14: TestWorks Conf The magic of models for 1000% test automation - Machiel van der Bijl

?button

!lamp on

?button

!lamp off

Page 15: TestWorks Conf The magic of models for 1000% test automation - Machiel van der Bijl

?button

!lamp on

?button

!lamp off

Page 16: TestWorks Conf The magic of models for 1000% test automation - Machiel van der Bijl

?button

!lamp on

?button

!lamp off

Page 17: TestWorks Conf The magic of models for 1000% test automation - Machiel van der Bijl

?button

!lamp on

?button

!lamp off

Page 18: TestWorks Conf The magic of models for 1000% test automation - Machiel van der Bijl

Why do our clients MBT?

• Faster in production

• Higher quality

• Lower total cost of ownership

18

Page 19: TestWorks Conf The magic of models for 1000% test automation - Machiel van der Bijl

SCRP case

19

Page 20: TestWorks Conf The magic of models for 1000% test automation - Machiel van der Bijl

ITAB Self Scanning

20

Back office

Page 21: TestWorks Conf The magic of models for 1000% test automation - Machiel van der Bijl

ScanFlow Cash Register Protocol

21

IDLE

OPEN

TRANSING

ENDING

Open account

Register articlesClose account

Pay bill

Page 22: TestWorks Conf The magic of models for 1000% test automation - Machiel van der Bijl

Initialize SCRP Service (from spec)

Command

• None; a transport connection suffices.

Response

• 220 SCRP Service ready

22

Page 23: TestWorks Conf The magic of models for 1000% test automation - Machiel van der Bijl

Cash Register Sign On

Command

• SIGNON <SFU_id>[:<password>]

Response

• 251 Signed On

• 450 Signing rejected

• 551 Authentication failed

23

Page 24: TestWorks Conf The magic of models for 1000% test automation - Machiel van der Bijl

Open Account

Command

• OPEN [<account>|<barcode>]

Response

• 231 <account> Account opened

• 530 No such account

• 531 Invalid account state

24

Page 25: TestWorks Conf The magic of models for 1000% test automation - Machiel van der Bijl

Request Article Registration

Command

• ARTREG [<barcode>[:<amount>]]

Response• {212 <description>[:<price>[:<amount>]]}

232 <nr_articles>:<subtotal> Article registered

• 511 No such article

• 531 Invalid account state

25

Page 26: TestWorks Conf The magic of models for 1000% test automation - Machiel van der Bijl

Close Current Account

Command

• CLOSE

Response• {212 description>[:<price>[:<amount>]]}

230 <endtotal> Account closed

• 531 Invalid account state

26

Page 27: TestWorks Conf The magic of models for 1000% test automation - Machiel van der Bijl

Request Account Transaction

Command

• TRANS <tr_method>>[:<amount>]

Response

• 240 Transaction succeeded

• 531 Invalid account state

• 540 No such transaction method

• 542 <failure_ind> Transaction failed

27

Page 28: TestWorks Conf The magic of models for 1000% test automation - Machiel van der Bijl

Round-up Account

Command

• IDLE

Response

• 233 Account idled

• 531 Invalid account state

28

Page 29: TestWorks Conf The magic of models for 1000% test automation - Machiel van der Bijl

How  to  test  manually?

demo

29

Page 30: TestWorks Conf The magic of models for 1000% test automation - Machiel van der Bijl

How  to  test  with  MBT?

demo

30

Page 31: TestWorks Conf The magic of models for 1000% test automation - Machiel van der Bijl

Modeling concepts

• channel– A channel over which the system

communicates with its environment

• state– A named state in model

• send ‘label’– Specifies that system can send ‘label’

• receive ‘label’– Specifies that system can receive ‘label’

31

Page 32: TestWorks Conf The magic of models for 1000% test automation - Machiel van der Bijl

Start: A simple model

• Initialize service

• Signon

• Open

• Article registration

• Close

• Pay

• Reset to idle32

Page 33: TestWorks Conf The magic of models for 1000% test automation - Machiel van der Bijl

Pleasant modeling

• macro’s

• behaviors

• choice

• repeat

33

Page 34: TestWorks Conf The magic of models for 1000% test automation - Machiel van der Bijl

34

TIL?

Page 35: TestWorks Conf The magic of models for 1000% test automation - Machiel van der Bijl

TIL

• AML process modeling language

• Axini MBT approach

• MBT can be applied to real world problems

• How we generate many test-cases from 1 model

• Axini TestManager

35

Page 36: TestWorks Conf The magic of models for 1000% test automation - Machiel van der Bijl

Want to learn more?

• Join our fall MBT course!

[email protected]

+31 6 16 4 26 332

Amsterdam

36