You are on page 1of 40

Software Testing Foundations

Chapter
1 Certified Tester
Introduction MSTB-GTB
2017
Version 2.2.0
© Copyright MSTB-GTB
Chapter 1 Page 1 Software Testing Foundations Certified Tester
V 2.2.0 / 2017
Disclaimer

• These slides are published under CC BY-NC-SA 4.0. This means besides
other things that they can be freely changed and used for non-commercial
purposes. By that we like to reach maximum flexibility for the CTFL
teachers at universities, colleges, and alike. However, we also have to
take into account the interests of the commercial trainings providers,
whose explicit request is not to have these slides freely available in the
Internet.
• Hence, we ask you to make use of the slides only within your lecture
series and exercises on CTFL related matter. Please also advise the
students that a free distribution of the slides would risk the GTB and/or
MSTB cooperation with universities, colleges, etc. – at least wrt. the
exchange of the slides.
• CC BY-NC-SA 4.0: https://creativecommons.org/licenses/by-nc-sa/4.0/

© Copyright MSTB-GTB
Chapter 1 Page 2 Software Testing Foundations Certified Tester
V 2.2.0 / 2017
Acknowledgements
• Large parts of the slides was adopted from a joint training course of various academies. It was updated by GTB
in accordance with the current syllabus 2011, V.1.0.1 from April 2013
• Version v1.0
– Dr. Falk Fraikin, Darmstadt Technical University
– Dr. Eike Hagen Riedemann, Dortmund University
– Prof. Dr. Andreas Spillner, Bremen College
– Prof. Dr. Mario Winter, Cologne Technical College

• Version v2.0
– Dipl.-Inf. Timea Illes-Seifert, Heidelberg University
– Dipl.-Inf. Horst Pohlmann, Ostwestfalen-Lippe College
– Prof. Dr.-Ing. Ina Schieferdecker, Technical University Berlin
– Prof. Dr. Mario Winter, Cologne Technical College
– Localization for Malaysian Universities by MSTB

• Version v2.1 & v2.2


– Dipl.-Inf. Thorsten Geiselhart, Marquardt Group
– Dipl.-Inf. Timea Illes-Seifert, Fiducia & GAD IT AG
– Dipl.-Inf. Horst Pohlmann, Hochschule Ostwestfalen-Lippe
– Prof. Dr.-Ing. Ina Schieferdecker, Technische Universität Berlin
– Dr. Stephan Weißleder, Thales Transportation Systems
– Localization for Malaysian Universities by MSTB

© Copyright MSTB-GTB
Chapter 1 Page 3 Software Testing Foundations Certified Tester
V 2.2.0 / 2017
3 After this lecture, you should...

• Know what further to expect from this lecture


• Have understood the organisation of the lecture and the excercises
• Be able to explain how a defect in software can cause harm to a person,
to the environment, or to a company
• Be able to reason why "exhaustive testing" of a program is typically not
possible
• Have posed your immediate questions and received answers

© Copyright MSTB-GTB
Chapter 1 Page 4 Software Testing Foundations Certified Tester
V 2.2.0 / 2017
However, at first the symbols of the slides
After this lecture, you should know …
3
Big Picture

+/- Discussion

??? Questions

 Exkursus (part of the lecture, but not part of the CTFL syllabus)

? Example

✓ Summary

& Terms and definitions


© Copyright MSTB-GTB
Chapter 1 Page 5 Software Testing Foundations Certified Tester
V 2.2.0 / 2017
Learning Objectives for the part “Fundamentals of Testing“
3 (according to Certified Tester Foundation Level Syllabus, Version 2011)

• 1.1 Why is testing necessary? (K2)


– LO-1.1.1 Describe, with examples, the way in which a defect in software can
cause harm to a person, to the environment, or to a company. (K2)

© Copyright MSTB-GTB
Chapter 1 Page 6 Software Testing Foundations Certified Tester
V 2.2.0 / 2017
1
Chapter

Introduction
} Certified Tester
Introduction  Impact of Software Defects
Appendix  Book references, Magazines,
Organisations, Conferences, Links

© Copyright MSTB-GTB
Chapter 1 Page 7 Software Testing Foundations Certified Tester
V 2.2.0 / 2017
Learning Objectives

• Teaching Fundamentals of Software Verification and Testing


• Definition and Explanation of Terms, Tasks and Activities, Methods and
Specification-based Techniques
• Content of lecture covers internationally fixed syllabus for training
providers
• Preparation for the examination
Certified Tester - Foundation Level
– Internationally recognized certificate
– Recognized professional specialization
– Covering various branches
(commercial software, automotive software, Web applications,
entertainment systems, etc.)

© Copyright MSTB-GTB
Chapter 1 Page 8 Software Testing Foundations Certified Tester
V 2.2.0 / 2017
Certified Tester Qualification

• ISEB - Information Systems Examination Board of the British


Computer Society (BCS) develops Certified Tester Syllabus in
1998
• GTB - German Testing Board is founded in 2001
http://www.german-testing-board.info/
• ISTQB - International Software Testing Qualifications Board
founded in 2002 as holding board of the national boards
http://www.istqb.org/
• Accredition of training providers by national boards
• Certification of attendees by independent certification bodies, in
Germany Cert-IT www.cert-it.com, GASQ http://de.gasq.org/ and
iSQI http://www.isqi.org/

© Copyright MSTB-GTB
Chapter 1 Page 9 Software Testing Foundations Certified Tester
V 2.2.0 / 2017
International Recognition and Wide Deployment
of Certified Tester
* American Software Testing Qualifications Board (ASTQB)
* Australia and New Zealand Testing Board (ANZTB)
* Austrian Testing Board (ATB)
* Bangladesh Software Testing Board (BSTB)
* Belarus Software Testing Qualifications Board (BySTQB)
* Belgium and Netherlands (BNTQB)
Up-to-date information: * Brazilian Software Testing Qualifications Board (BSTQB)
* Canadian Software Testing Board (CSTB)
http://www.istqb.org/ * Chinese Software Testing Qualifications Board (CSTQB)
* Comité Français des Tests Logiciels (CFTL)
* Czech and Slovak Testing Board (CaSTB)
* Danish Software Testing Board (DSTB)
* Egyptian Software Testing Board (ESTB)
and * Estonian Testing Board (ETB)
* Finnish Software Testing Board (FiSTB)
http://www.german-testing-board.info/ * German Testing Board (GTB)
* Gulf Software Testing Board (GSTB)
* Hispanic America Software Testing Qualifications Board (HASTQB)
* Hungarian Testing Board (HTB)
and * Indian Testing Board (ITB)
* Iranian Testing Qualification Board (ITQB)
* Irish Software Testing Board (ISTB)
* Israeli Testing Certification Board (ITCB)
* Italian Software Testing Qualifications Board (ITA-STQB)
http://www.mstb.org * Japan Software Testing Qualifications Board (JSTQB)
* Jordan Software Testing Qualifications Board (JOSTQB)
* Korean Testing Board (KTB)
* Latvian Software Testing Qualification Board (LSTQB)
* Luxembourg Testing Board (LTB)
* Malaysian Software Testing Board (MSTB)
* Nigerian Software and Testing Board (NSTB)
* Norwegian Testing Board (NTB)
* Polish Testing Board (PTB)
* Russian Software Testing Qualifications Board (RSTQB)
* Saudi Arabia Testing Board (KSATB)
* Singapore Testing Qualifications Board (SGTQB)
* South African Software Testing Qualifications Board (SASTQB)
* South East European Testing Board (SEETB)
* Spanish Software Testing Qualifications Board (SSTQB)
* Sri-Lanka Testing Board
* Swedish Software Testing Board (SSTB)
* Swiss Testing Board (STB)
* Turkish Testing Board (TTB)
* Ukrainian Software Quality Board (USQB)
© Copyright MSTB-GTB
Chapter 1 Page 10 Software Testing Foundations Certified Tester * UK Testing Board (UKTB) 10
* Vietnamese Testing Board (VTB) V 2.2.0 / 2017
© Copyright MSTB-GTB
Chapter 1 Page 11 Software Testing Foundations Certified Tester
V 2.2.0 / 2017
Textbook for Certified Tester - Foundation Level

• Andreas Spillner, Tilo Linz, Hans Schaeffer:


Software Testing Foundations
• Rocky Nook
– 4th edition
– March 2014
– 304 pages
– Costs: 35,99 EUR
– ISBN-10: 1492001481
– ISBN-13: 978-1937538422

• Rocky Nook
http://www.rockynook.com/

© Copyright MSTB-GTB
Chapter 1 Page 12 Software Testing Foundations Certified Tester
V 2.2.0 / 2017
Content of Foundation Level Syllabus 2011

Testing
Fundamentals Test Design Test Tool Support
Throughout the Static Techniques
of Testing Techniques Management for Testing
Software Life Cycle
Chapter 1 Chapter 3 Chapter 4 Chapter 5.1 Chapter 6 Chapter 7
Why is Testing Software Static Techniques The Test Develop-
Test Organization Types of Test Tools
Necessary development models and the Test Process ment Process
Chapter 2 Categories of Test Test Planning Effective Use
Test Levels Review Process
Design Techniques and Estimation of Tools
What is Testing
Static Analysis Specification-based Test Progress Moni- Introducing a Tool
Test Types
Seven by Tools Techniques toring and Control into an Organization
Testing Principles
Configuration
Maintenance Testing Chapter 5.2
Fundamental Management
Test Process Structure-based
Techniques Risk and Testing
The Psychology
of Testing Experience-based
Techniques Incident
Management
Code of Ethics Choosing
Test Techniques

Learning objectives (Cognitive levels)

K1: Remember K2: Understand K3: Apply K4: Analyse

© Copyright MSTB-GTB
Chapter 1 Page 13 Software Testing Foundations Certified Tester
V 2.2.0 / 2017
1
Chapter

Introduction
} Certified Tester
Introduction  Impact of Software Defects
Appendix  Book references, Magazines,
Organisations, Conferences, Links

© Copyright MSTB-GTB
Chapter 1 Page 14 Software Testing Foundations Certified Tester
V 2.2.0 / 2017
Introduction

• A software defect – what is it?

© Copyright MSTB-GTB
Chapter 1 Page 15 Software Testing Foundations Certified Tester
V 2.2.0 / 2017
9.9.1945
15:45
The First Software Defect!

A moth in the computer Mark II causes a defect in Relay No. 70, Panel F.
Mrs. Grace Murray Hopper removes the
defect and records it
in the log book.

»First actual case


of bug being found.«

Obvious defect!

Fixing is easy!

Source:
http://www.history.navy.mil/photos/pers-us/uspers-h/g-hoppr.htm

© Copyright MSTB-GTB
Chapter 1 Page 16 Software Testing Foundations Certified Tester
V 2.2.0 / 2017
? Impact of Software Defects

• NASA - Earth observation satellites 1979-1985


– Hole in the ozone layer not detected for 7 years!
– Cause: Software defect – transformation of the
Ozone layer was “averaged” as sensor drift through
automatic zero correction
• ESA, Kourou, French Guyana, 4. June 1996
– Self destruction of Ariane 5 at maiden flight
39 seconds after take-off
– Cause: Software Defect – Position control software
of Ariane 4 reused with Ariane 5 without testing
against take-off trajectory, thereby conversion error
• Manned NASA Space capsule Gemini V
– Missed its airfield by approx. 160 kilometres
– Cause: Software Defect – Rotation of earth around
the sun not taken into consideration!

© Copyright MSTB-GTB
Chapter 1 Page 17 Software Testing Foundations Certified Tester
V 2.2.0 / 2017
? F-18 At the Equator: Documentation Defect

• US Air Force, Program for guided missiles


– Due to lack of memory space the flight coordinates of a missile flying
over the equator were not recalculated, but only the signs were
changed.
– The code was transferred, unchanged to an F-18 military jet.
Consequently the jet was rotating around its own axis while crossing
the equator.
– Luckily:
Defect was noticed in simulator

© Copyright MSTB-GTB
Chapter 1 Page 18 Software Testing Foundations Certified Tester
V 2.2.0 / 2017
? NASA - Mariner 1: Coding error

• On 22.6.1962 the NASA loses the space probe Mariner 1, which is on the
way to Venus.

»Because of a launch-vehicle deviation from the planned flight path, Mariner R-1
was destroyed by the range safety officer after approximately 290 seconds of
flight.«
• Correct coding would have been:

DO 10 I=1,3 (Definition of loop


... in FORTRAN IV)
10 CONTINUE

• Wrong coding was

DO10I=1.3 (Assign the value 1.3


... to the variable DO10I)
10 CONTINUE

© Copyright MSTB-GTB
Chapter 1 Page 19 Software Testing Foundations Certified Tester
V 2.2.0 / 2017
? T-Mobile 2016: Outage

http://fortune.com/2016/09/22/t-mobile-overnight-network-outage/
downloaded March 17, 2017

© Copyright MSTB-GTB
Chapter 1 Page 20 Software Testing Foundations Certified Tester
V 2.2.0 / 2017
? Software Bugs in Automotive

http://fortune.com/2015/07/13/jaguar-recall-software-glitch/, downloaded March


17, 2017
http://theconversation.com/auto-industry-must-tackle-its-software-problems-to-stop-hacks-as-
cars-go-online-45325, downloaded March 17, 2017

© Copyright MSTB-GTB
Chapter 1 Page 21 Software Testing Foundations Certified Tester
V 2.2.0 / 2017
? How do others test?

• Automotive domain
– The component entry test
(Component test)
– Regular tests on running production lines
(Integration test)
– Reality close operational test
(System test)
– Customer test-drive
(Approval test)
– Race operation
(Performance test, Load test)
(Stability, Reliability, Robustness)
– Crash test
(Stress test)

© Copyright MSTB-GTB
Chapter 1 Page 22 Software Testing Foundations Certified Tester
V 2.2.0 / 2017
? Can we test exhaustively?

• A simple program which has three integer inputs should be tested. There
are no other constraints influencing the test object.
• With 16 Bit of integers, each input is able to take on 216 different values.
• With three independent inputs there are
216 * 216 * 216 = 248 possible combinations.
• Each of these combinations is to be tested.
• How long will it take with 100.000 tests per second?

© Copyright MSTB-GTB
Chapter 1 Page 23 Software Testing Foundations Certified Tester
V 2.2.0 / 2017
? Can we test exhaustively?

• A simple program which has three integer inputs should be tested. There
are no other constraints influencing the test object.
• With 16 Bit of integers, each input is able to take on 216 different values.
• With three independent inputs there are
216 * 216 * 216 = 248 possible combinations.
• Each of these combinations is to be tested.
• How long will it take with 100.000 tests per second?

• There are 281.474.976.710.656 test cases


Duration: approx. 90 years

© Copyright MSTB-GTB
Chapter 1 Page 24 Software Testing Foundations Certified Tester
V 2.2.0 / 2017
? Can we test exhaustively?

• A simple program that consists of four A


branches (IF-statements) and one encircling
loop and therefore has five possible paths
within the loop's body, should be tested.
• Assuming that the branches are independent
of each other and are limited to passing a
maximum of 20 times, there is the following
calculation:
51 + 52 + ... + 518 + 519 + 520
• How long will the testing take with 100.000
tests per second?

B
© Copyright MSTB-GTB
Chapter 1 Page 25 Software Testing Foundations Certified Tester
V 2.2.0 / 2017
? Can we test exhaustively?

• A simple program that consists of four A


branches (IF-statements) and one encircling
loop and therefore has five possible paths
within the loop's body, should be tested.
• Assuming that the branches are independent
of each other and are limited to passing a
maximum of 20 times, there is the following
calculation:
51 + 52 + ... + 518 + 519 + 520
• How long will the testing take with 100.000
tests per second?

• There are 119.209.289.550.780 test cases


Duration: approx. 38 years
B
© Copyright MSTB-GTB
Chapter 1 Page 26 Software Testing Foundations Certified Tester
V 2.2.0 / 2017
? First exercise (for warming up!)

A program is to be tested which reads 3 positive integers and interprets


them as measures of a triangle.
The program will signal, whether the triangles are not-equilateral,
isosceles or equilateral triangles.

a b a b a b
c c c
a  b  c a = b  c a = b = c
a  b = c
a = c  b

© Copyright MSTB-GTB
Chapter 1 Page 27 Software Testing Foundations Certified Tester
V 2.2.0 / 2017
? Your suggestions please

• A quick answer to the questions:


– How many tests are needed?
– With which test data would you test the program?

© Copyright MSTB-GTB
Chapter 1 Page 28 Software Testing Foundations Certified Tester
V 2.2.0 / 2017
? Possible Test cases (1/3)

Test cases consist of test data and the expected result


1. 2,3,4 – permissible not-equilateral triangle
2. 2,2,2 – permissible equilateral triangle
3. 2,2,1 – permissible isosceles triangle
4./5. 1,2,2 / 2,1,2
2 more test cases with permutations
for isosceles triangles
6. 1,0,3 – no triangle, one side specification= 0
7./8. 0,1,3 / 1,3,0 - permutations
9. 5,-5,9 – no triangle, one side specification < 0
10./11. -5,5,9 / 5,9,-5 - permutations

© Copyright MSTB-GTB
Chapter 1 Page 29 Software Testing Foundations Certified Tester
V 2.2.0 / 2017
? Possible Test cases (2/3)

12. 1,2,3 – no triangle


Sum of two shorter sides = 3. side length
13./14. 2,3,1 / 3,1,2 - permutations
15. 1,2,4 – no triangle
Sum of two shorter sides < 3. side length
16./17. 2,4,1 / 4,1,2 - permutations
18./19. 0,0,0 – No triangle or failure
all sides = 0, additionally 2 sides = 0 - permutations?
20.-22. Max_int, Max_int, Max_int – permissible equilateral triangle
correct triangle form by testing with maximal numbers, permissible
testing with 2 or 1 maximal number

© Copyright MSTB-GTB
Chapter 1 Page 30 Software Testing Foundations Certified Tester
V 2.2.0 / 2017
? Possible Test cases (3/3)

23.-25. 1,1,4.4567 – Failure indication »no integer numbers«


Permutations? – additionally with 2 or 3 values
26.-28. 1,1,& - Failure indication »Input of letters or special characters«
Permutations? – additionally with 2 or 3 values
29./30. 1,2,3,4 / 2,3 – Failure indication »wrong number of values«
(if input possible)
31. Max_int/2 + 1, Max_int/2 + 1, Max_int/2 + 10 – permissible
isosceles triangle
(Overflow or correct calculation?
With a<=b<=c; Verifying triangle condition with a+b>c,
a+b leads to overflow, see also test case 20)

How many tests did you consider? Source:


Glenford J.Myers, “The Art of Software Testing”,
John Wiley & Sons, 2001, 7th edition

© Copyright MSTB-GTB
Chapter 1 Page 31 Software Testing Foundations Certified Tester
V 2.2.0 / 2017
? Acute angled, obtuse angled and right angled triangles

• If acute angled, obtuse angled and right angled triangles are also
considered the total is 47 test cases.

Summary: Simple problem but complex test

© Copyright MSTB-GTB
Chapter 1 Page 32 Software Testing Foundations Certified Tester
V 2.2.0 / 2017
Finally

• Have fun with testing and enjoy the lecture

© Copyright MSTB-GTB
Chapter 1 Page 33 Software Testing Foundations Certified Tester
V 2.2.0 / 2017
1
Chapter

Introduction
} Certified Tester
Introduction  Impact of Software Defects
Appendix  Book References, Magazines,
Organisations, Conferences, Links

© Copyright MSTB-GTB
Chapter 1 Page 34 Software Testing Foundations Certified Tester
V 2.2.0 / 2017
Book references
Books referenced in ISTQB syllabus Certified Software Tester Foundation Level
• Beizer Boris (1990), Software Testing Techniques (2nd edition), Van Nostrand Reinhold
• Rex Black (2001), Managing the Testing Process (2nd edition), John Wiley & Sons
• Hans Buwalda et al. (2001), Integrated Test Design and Automation, Addison Wesley
• Lee Copeland (2004), A Practitioner's Guide to Software Test Design, Artech House
• Rick David Craig and Stefan P. Jaskiel (2002), Systematic Software Testing, Artech House
• Mark Fewster and Graham Dorothy (1999), Software Test Automation, Addison Wesley
• Tom Gilb and Dorothy Graham (1993), Software Inspection, Addison Wesley
• Bill Hetzel (1988), Complete Guide to Software Testing, QED
• Cem Kaner, James Bach and Bret Pettticord (2002), Lessons Learned in Software Testing, John
Wiley & Sons
• Glenford J. Myers (1979), The Art of Software Testing, John Wiley & Sons
• Erik van Veenendaal (2004), The Testing Practitioner, UTN Publishers

http://www.istqb.org/references/books/referenced-books-in-istqb-syllabi.html
downloaded March 17, 2017

© Copyright MSTB-GTB
Chapter 1 Page 35 Software Testing Foundations Certified Tester
V 2.2.0 / 2017
Books on Advanced Topics

• Colin Willcock, Thomas Deiß, Stephan Tobies,


Stephan Schulz, Stefan Keil, Federico Engler: An
Introduction to TTCN-3. John Wiley & Sons;
Verlag: Wiley; Auflage: 2 (9. Juni 2011)
Introduction to test automation technology TTCN-3

• Justyna Zander, Ina Schieferdecker, Pieter J.


Mosterman: Model-Based Testing for Embedded
Systems, CRC Press, 2011.
Overview on Model-Based Testing for embedded systems

© Copyright MSTB-GTB
Chapter 1 Page 36 Software Testing Foundations Certified Tester
V 2.2.0 / 2017
Magazines on the subject area

• Springer, Software Quality Journal:


http://www.springer.com/computer/swe/journal/11219

• The Journal of Software Testing, Verification and Reliability,


John Wiley & Sons Ltd.
http://onlinelibrary.wiley.com/journal/10.1002/(ISSN)1099-1689

• Better Software
SQE Publications
http://www.stickyminds.com/BetterSoftware/magazine.asp

• Professional Tester, Test Publishing Ltd.


http://www.professionaltester.com/

© Copyright MSTB-GTB
Chapter 1 Page 37 Software Testing Foundations Certified Tester
V 2.2.0 / 2017
Organisations

• ISTQB - International Software Testing


Qualifications Board
founded in 2002 as Holding Board of the
National Boards
http://www.istqb.org/

• GTB - German Testing Board e.V.


http://www.german-testing-board.info

• MSTB – Malaysian Software Testing Board


http://www.mstb.org

© Copyright MSTB-GTB
Chapter 1 Page 38 Software Testing Foundations Certified Tester
V 2.2.0 / 2017
Conferences

Germany
• German Testing Day
http://www.germantestingday.info/
• Iqnite - Conference for Software Quality Management,
http://www.iqnite-conferences.com/iqnite-de/index.aspx/

Malaysia
• SOFTEC ASIA – Software Testing Conference Asia
http://www.qportal.com.my

Europe
• EuroSTAR - European International Conference on Software Testing Analysis and Review
http://www.eurostarconferences.com

International
• ICST – IEEE International Conference on Software Testing, Verification and Validation
http://www.cs.gmu.edu/icst

List of Software Test Conferences


• http://testingconferences.org/

© Copyright MSTB-GTB
Chapter 1 Page 39 Software Testing Foundations Certified Tester
V 2.2.0 / 2017
Testing Companies (Examples)
• SQS Software Quality Systems AG, Köln
http://www.sqs.de

• imbus AG, Möhrendorf


http://www.imbus.de

• SOGETI Deutschland GmbH, Düsseldorf


http://www.sogeti.de

• Ranorex GmbH
http://www.ranorex.de

• Testbirds GmbH
http://www.testbirds.de/

• Custommedia Sdn Bhd


http://www.custommedia.my

• Mesiniaga Sdn Bhd


http://www.mesiniaga.com.my/

• HeiTech Padu Bhd


http://www.heitech.com.my/

© Copyright MSTB-GTB
Chapter 1 Page 40 Software Testing Foundations Certified Tester
V 2.2.0 / 2017

You might also like