warning

79
WARNING These slides are not optimized for printing or exam preparation. These are for lecture delivery only. These slides are made for PowerPoint 2010. They may not show up well on other PowerPoint versions. You can download PowerPoint 2010 viewer from here . These slides contain a lot of animations. For optimal results, watch in slideshow mode.

Upload: haley-oliver

Post on 01-Jan-2016

27 views

Category:

Documents


0 download

DESCRIPTION

WARNING. These slides are not optimized for printing or exam preparation. These are for lecture delivery only. These slides are made for PowerPoint 2010. They may not show up well on other PowerPoint versions . You can download PowerPoint 2010 viewer from here . - PowerPoint PPT Presentation

TRANSCRIPT

Page 1: WARNING

WARNING

These slides are not optimized for printing or exam preparation. These are for lecture delivery only.

These slides are made for PowerPoint 2010. They may not show up well on other PowerPoint versions. You can download PowerPoint 2010 viewer from here.

These slides contain a lot of animations. For optimal results, watch in slideshow mode.

Page 2: WARNING
Page 3: WARNING
Page 4: WARNING
Page 5: WARNING

But it worked in my

machine!Our

tester

Your software

Page 6: WARNING

Quality Assurance: Testing and Beyond

CS2103/T, Lecture 9, Part 1, [Oct 18, 2013]

Page 7: WARNING
Page 8: WARNING

Validation Verification

[Quality Assurance]

Page 9: WARNING

Validation Verification

[Quality Assurance]

Are we building the correct product?

Are we building the product correctly?

Page 10: WARNING

Validation Verification

[Quality Assurance]

Are we building the correct product?

Are we building the product correctly?

Page 11: WARNING

Validation Verification

[Quality Assurance]

Are we building the correct product?

Are we building the product correctly?

FAIL!

Page 12: WARNING

Validation Verification

[Quality Assurance]

Are we building the correct product?

Are we building the product correctly?

FAIL! FAIL!

Page 13: WARNING

Validation Verification

[Quality Assurance]

Buggy requirements Buggy code

FAIL! FAIL!

Page 14: WARNING

Validation Verification

[Quality Assurance]

Two QA activities for a PC version of a ‘Snakes and ladders’ game:a) Ensure that the game allows players to decide

who throws the die first.b) When more than one piece is on a square,

ensure that it is the piece that belongs to the current player that will be moved.

(Are we building the correct product?)

(Are we building the product correctly?)

snakes {a|b}e.g. snakes a

77577tinyurl.com/questionSMS

Which one is more related to verification than validation?

Page 15: WARNING

Validation Verification

[Quality Assurance]

Page 16: WARNING

Validation Verification

[Quality Assurance]

Page 17: WARNING

Validation Verification

E.g. Acceptance testing E.g. System testing

[Quality Assurance]

Page 18: WARNING

Validation Verification

E.g. Acceptance testing E.g. System testing

[Quality Assurance]

Product

Page 19: WARNING

Validation Verification

E.g. Acceptance testing E.g. System testing

[Quality Assurance]

Product

Page 20: WARNING

Validation Verification

E.g. Acceptance testing E.g. System testing

[Quality Assurance]

Product

Page 21: WARNING

Validation Verification

E.g. Acceptance testing E.g. System testing

[Quality Assurance]

Product

But it worked in my

machine!

Page 22: WARNING

Validation Verification

E.g. Acceptance testing E.g. System testing

[Quality Assurance]

Product

Page 23: WARNING

Validation Verification

E.g. Acceptance testing E.g. System testing

[Quality Assurance]

Product

System specification

Requirements specification

Page 24: WARNING

Validation Verification

E.g. Acceptance testing E.g. System testing

[Quality Assurance]

Product

System specification

Requirements specification

Page 25: WARNING

Validation Verification

[Quality Assurance]

Product

E.g. Acceptance testing E.g. System testing

Page 26: WARNING

Validation Verification

[Quality Assurance]

Product

E.g. Acceptance testing E.g. System testing

Page 27: WARNING

Validation Verification

[Quality Assurance]

Product

E.g. Acceptance testing E.g. System testing

Page 28: WARNING

Validation Verification

E.g. Acceptance testing E.g. System testing

Back-end

GUI

[Quality Assurance]

Product

Page 29: WARNING

Validation Verification

E.g. Acceptance testing E.g. System testing

Back-end

GUI

[Quality Assurance]

GUI testing

Page 30: WARNING

Validation Verification

E.g. Acceptance testing E.g. System testing

Back-end

GUI

[Quality Assurance]

GUI testing

Page 31: WARNING

Validation Verification

E.g. Acceptance testing E.g. System testing

Back-end

GUI

[Quality Assurance]

GUI testing

Page 32: WARNING

Validation Verification

E.g. Acceptance testing E.g. System testing

Back-end

GUI

[Quality Assurance]

GUI testing

GU

I

Logic

Automated API tester

Manual testing

(or automate)

Page 33: WARNING

Validation Verification

E.g. Acceptance testing E.g. System testing

Back-end

GUI

[Quality Assurance]

GUI testing

GU

I

Logic

Automated API tester

Manual testing

(or automate)

Page 34: WARNING

Validation Verification

E.g. Acceptance testing E.g. System testing

Back-end

GUI

[Quality Assurance]

GUI testing

Page 35: WARNING

GUI testing

Page 36: WARNING

GUI testing

Page 37: WARNING

GUI testing

Page 38: WARNING

GUI testing

Page 39: WARNING

GUI testing

Page 40: WARNING

GUI testing

Page 41: WARNING

Validation Verification

E.g. Acceptance testing E.g. System testing

Back-end

GUI

[Quality Assurance]

GUI testing

Page 42: WARNING

Validation Verification

E.g. Acceptance testing E.g. System testing

Back-end

GUI

[Quality Assurance]

Page 43: WARNING

Validation Verification

E.g. Acceptance testing E.g. System testing

[Quality Assurance]

← How much of this is being tested?

Page 44: WARNING

Validation Verification

E.g. Acceptance testing E.g. System testing

[Quality Assurance]

← How much of this is being tested?

Page 45: WARNING
Page 46: WARNING
Page 47: WARNING
Page 48: WARNING
Page 49: WARNING

Using EclEmma coverage tool on TEAMMATES

Page 50: WARNING

Validation Verification

E.g. Acceptance testing E.g. System testing

[Quality Assurance]

← How much of this is being tested?

Page 51: WARNING

Validation Verification

E.g. Acceptance testing E.g. System testing

[Quality Assurance]

← How much of this is being tested?

Statement coverage

Function coverage

Condition coverage

Exit/entry coverage

Branch coverage

Path coverage

Page 52: WARNING

Validation Verification

E.g. Acceptance testing E.g. System testing

[Quality Assurance]

← How much of this is being tested?

Statement coverage

Path coverage

Page 53: WARNING

Validation Verification

E.g. Acceptance testing E.g. System testing

[Quality Assurance]

← How much of this is being tested?

Statement coverage

Path coveragevoid readInput(){

while ( hasInput() ) input += readFromKeyboard();

}

Page 54: WARNING

Validation Verification

E.g. Acceptance testing E.g. System testing

[Quality Assurance]

← How much of this is being tested?

Statement coverage

void readInput(){while ( hasInput() )

input += readFromKeyboard();}

Page 55: WARNING

Validation Verification

E.g. Acceptance testing E.g. System testing

[Quality Assurance]

← How much of this is being tested?

void readInput(){while ( hasInput() )

input += readFromKeyboard();}

Path coverage

Page 56: WARNING

Validation Verification

E.g. Acceptance testing E.g. System testing

[Quality Assurance]

← How much of this is being tested?

void readInput(){while ( hasInput() )

input += readFromKeyboard();}

Path coverage

Page 57: WARNING

Validation Verification

E.g. Acceptance testing E.g. System testing

[Quality Assurance]

← How much of this is being tested?

void readInput(){while ( hasInput() )

input += readFromKeyboard();}

Path coverage

Page 58: WARNING

Validation Verification

E.g. Acceptance testing E.g. System testing

[Quality Assurance]

← How much of this is being tested?

void readInput(){while ( hasInput() )

input += readFromKeyboard();}

Path coverage

Page 59: WARNING

Validation Verification

E.g. Acceptance testing E.g. System testing

[Quality Assurance]

← How much of this is being tested?

void readInput(){while ( hasInput() )

input += readFromKeyboard();}

Path coverage

Page 60: WARNING

Validation Verification

E.g. Acceptance testing E.g. System testing

[Quality Assurance]

← How much of this is being tested?

Path coveragevoid readInput(){

while ( hasInput() ) input += readFromKeyboard();

}

Control Flow Graphs

Page 61: WARNING

Validation Verification

E.g. Acceptance testing E.g. System testing

[Quality Assurance]

← How much of this is being tested?

Statement coverage

Function coverage

Condition coverage

Exit/entry coverage

Branch coverage

Path coverage

Page 62: WARNING

Validation Verification

E.g. Acceptance testing

[Quality Assurance]

E.g. System testing

just testing?

Page 63: WARNING

Validation Verification

E.g. Acceptance testing

[Quality Assurance]

E.g. System testing

Other QA techniques

just testing?

Page 64: WARNING

[Quality Assurance]

Other QA techniques

Page 65: WARNING

Validation Verification

E.g. Acceptance testing

[Quality Assurance]

Code reviews • static analysis • formal methods• …

Other QA techniques

Page 66: WARNING

Validation Verification

E.g. Acceptance testing

[Quality Assurance]

Other QA techniques

Code reviews • static analysis • formal methods• …

Page 67: WARNING

Validation Verification

E.g. Acceptance testing

[Quality Assurance]

Other QA techniques

Code reviews • static analysis • formal methods• …

Page 68: WARNING

Validation Verification

E.g. Acceptance testing

[Quality Assurance]

Other QA techniques

Code reviews • static analysis • formal methods• …

Page 69: WARNING

Validation Verification

E.g. Acceptance testing

[Quality Assurance]

Other QA techniques

Code reviews • static analysis • formal methods• …

Page 70: WARNING

Validation Verification

E.g. Acceptance testing

[Quality Assurance]

Other QA techniques

Code reviews • static analysis • formal methods• …

Using CodeProAnalytix static analysis tool on TEAMMATES

Page 71: WARNING

Validation Verification

E.g. Acceptance testing

[Quality Assurance]

Other QA techniques

Code reviews • static analysis • formal methods• …

Page 72: WARNING

Validation Verification

E.g. Acceptance testing

[Quality Assurance]

Other QA techniques

Code reviews • static analysis • formal methods• …

SUT doubleAmount(int):int

Page 73: WARNING

Validation Verification

E.g. Acceptance testing

[Quality Assurance]

Other QA techniques

Code reviews • static analysis • formal methods• …

Text case 1: Input: 23 Expected output: 46

Text case 2: Input: 10 Expected output : 20

Text case n: Input: -2 Expected output : -4

Testi

ng

SUT doubleAmount(int):int

Page 74: WARNING

Validation Verification

E.g. Acceptance testing

[Quality Assurance]

Other QA techniques

Code reviews • static analysis • formal methods• …

Mathematically prove if input = x

then, output = 2x

Testi

ng

SUT doubleAmount(int):int

Text case 1: Input: 23 Expected output: 46

Text case 2: Input: 10 Expected output : 20

Text case n: Input: -2 Expected output : -4

Page 75: WARNING

Validation Verification

E.g. Acceptance testing

[Quality Assurance]

Other QA techniques

Code reviews • static analysis • formal methods• …

Page 76: WARNING

Validation Verification

E.g. Acceptance testing

[Quality Assurance]

Other QA techniques

Code reviews • static analysis • formal methods• …

Page 77: WARNING
Page 78: WARNING

Have the ability to relate these concepts to the project: validation, verification, system testing, acceptance testing , code coverage, GUI testing, other QA techniques.

For example, the ability to explain how the above was done in the project, or why they were not done and how you could have done them.

You are welcome to, but not required to, use • Automation of GUI testing• Using tools to measure coverage• Path analysis• Apply other QA techniques

Page 79: WARNING

If all tests pass and those tests achieve100% path coverage (all possible execution paths through the code have been tested), can the software still have bugs?

(Discuss with neighbors before submitting)

buggy {yes|no}e.g. buggy yes

77577tinyurl.com/questionSMS