Software Testing - Introduction -

Size: px
Start display at page:

Download "Software Testing - Introduction -"

Transcription

1 Software Testing - Introduction - Bugs? What is testing? The RIP model. How important is testing? Test case, test requirement, coverage criteria, coverage level, criteria subsumption. An introduction to JUnit and EclEmma. Testing and the software development process. Testing activities. Testing levels.!! Verificação e Validação de Software! Departamento de Informática! Faculdade de Ciências da Universidade de Lisboa!! Eduardo Marques, edrdo@di.fc.ul.pt

2 Bug as such li/le faults and difficulties are called show themselves, and months of anxious watching, st=dy, and labor are requisite before commercial success or failure is ceraainly reached. [Thomas Edison, 1878] Did You Know? Edison Coined the Term Bug, A. Magoun and P. Israel, The Institute, IEEE ! 2

3 First act=al case of bug being found [!!] Note in Harvard Mark II logbook by Grace Hopper, 1947 [actual moth (bug) part of the logbook], U.S. Naval Historical Center Online Library Photograph 3

4 Other famous bugs Pentium FDIV bug (1994) = Ariane 5 bug (1996) It took the European Space Agency 10 years and $7 billion to produce Ariane 5 [ ]. All it took to explode that rocket less than a minute into its maiden voyage last June, scattering fiery rubble across the mangrove swamps of French Guiana, was a small computer program trying to stuff a 64-bit number into a 16-bit space.! From: A bug and a Crash, James Gleick, ariane.html Apple Maps, 2012 Citius, Ministério da Justiça, Other examples: History s Worst Software Bugs, Wired [link]

5 A simple bug public static int numzero(int[] x) {! // Effects: if x == null throw NullPointerException! // else return the number of occurrences of 0 in x! 1 int count = 0;! 2 for (int i = 1; i < x.length; i++)! 3 if (x[i] == 0)! 4 count++;! 5 return count;! } There is a simple bug in numzero Where is the bug location in the source code? How would you fix it? If the bug is location is reached, how does it corrupt program state? Does it always corrupt program state? If program state is corrupted, does numzero fail? How? 5 The term bug is ambiguous however are we referring to the source code or to outcome of a failed execution? We need clear terminology.

6 Fault, Error, Failure [Falta,Erro, Falha] public static int numzero(int[] x) {! // Effects: if x == null throw NullPointerException! // else return the number of occurrences of 0 in x! 1 int count = 0;! 2 for (int i = 1; i < x.length; i++)! 3 if (x[i] == 0)! 4 count++;! 5 return count;! } Fault: a defect in source code [~ the location of the bug] i = 1 in the code [should be fixed to i = 0] Error: erroneous program state caused by execution of the defect i becomes 1 (array entry 0 is not ever read) Failure: propagation of erroneous state to the program outputs The output value for x = { 0, 1, 0 } is 1 instead of the expected value 2. 6 Failure happens as long as x.length > 0 && x[0] = 0

7 State representation - convention We will represent program states using the notation <var=v1,...,varn=vn, PC=program counter> Example sequence of states in the execution of numzero({0,1,2,0}) 1: < x={0,1,2,0}, PC=[int count=0 (l1)] >! 2: < x={0,1,2,0}, count=0, PC=[i=1 (l2)] >! 3: < x={0,1,2,0}, count=0,i=1,pc=[i<x.length (l2)] >! 4: < x={0,1,2,0}, count=0,i=1,pc=[if(x[i]==0) (l3)] >!...! <x={0,1,2,0}, count=1, PC=[return count;(l5)] > 7

8 Error state - convention We will use the convention: an error state is the first different state in execution in comparison to an execution to the state sequence of what would be the correct program. If we had i=0 the execution of numzero({0,1,2,0}) would begin with states: 1: < x={0,1,2,0}, PC=[int count=0 (l1)] >! 2: < x={0,1,2,0}, count=0, PC=[i=0 (l2)] >! 3: < x={0,1,2,0}, count=0,i=0,pc=[i<x.length (l2)] >...! Instead we have 1: < x={0,1,2,0}, PC=[int count=0 (l1)] >! 2: < x={0,1,2,0}, count=0, PC=[i=1 (l2)] >! 3: < x={0,1,2,0}, count=0,i=1,pc=[i<x.length (l2)] >...! The first error state is 2: < x={0,1,2,0}, count=0, PC=[i=1 (l2)] > 8

9 Basic terminology Recall: Fault: A static defect in the software s source code (defined by one or more source code locations) Error: An incorrect internal state that is the manifestation of some fault [to be further clarified further on]. Failure: External, incorrect behavior with respect to the requirements or other description of the expected behavior. Testing :evaluating software by observing its execution. Test failure : a test execution that results in a failure. Debugging: the process of finding a fault given a failure. 9

10 Test failure - RIP model Reachability The fault is reached. Infection Execution of the fault leads to an error. Propagation Errors are propagated to the program output (failure) If the RIP conditions are met, we say that there is a test failure. 10

11 numzero: execution w/error but no failure reachability + infection but no propagation public static int numzero(int[] x) {! // Effects: if x == null throw NullPointerException! // else return the number of occurrences of 0 in x! 1 int count = 0;! 2 for (int i = 1; i < x.length; i++)! 3 if (x[i] == 0)! 4 count++;! 5 return count;! } Considering an execution where x = { 1, 0, 2, 0} Error: <x={1,0,2,0}, i=1, count=0, PC= if...,l3> deviates from expected internal state <x={1,0,2,0}, i=0,count=1,pc =[if..., l3]>! No Failure! numzero({1,0,2,0}) will return 2 as expected. 11

12 numzero: execution w/error and failure reachability + infection + propagation public static int numzero(int[] x) {! // Effects: if x == null throw NullPointerException! // else return the number of occurrences of 0 in x! 1 int count = 0;! 2 for (int i = 1; i < x.length; i++)! 3 if (x[i] == 0)! 4 count++;! 5 return count;! } Considering an execution where x = { 0, 1, 2, 0} Error: <x={0,1,2,0}, i=1, count=0, PC= if...,l3> deviates from expected internal state <x={1,0,2,0}, i=0,count=1,pc =[if..., l3]>! And failure: numzero({0,1,2,0}) will return 1 rather than 2. 12

13 13 How important is testing?

14 How mature is your testing?! Beizer s scale for test process maturity [ A & O, page 8] Level 0: There s no difference between testing and debugging. Level 1: The purpose of testing is to show that the software works. Level 2: The purpose of testing is to show that the software doesn t work. Level 3: The purpose of testing is not to prove anything specific, but to reduce the risk of using the software. Level 4: Testing is a mental discipline that helps all IT professionals develop higher quality software. 14

15 Debug only? Level 0: There s no d i ff e re n c e b e t w e e n testing and debugging. We should try to prevent bugs early on rather than wait for them to come and haunt us ( m a n y t i m e s w i t h d i s a s t r o u s consequences). 15

16 Developer versus tester? 16 Level 1: The purpose of testing is to show that the software works (developer-biased view ). But generally, correctness is impossible to establish or demonstrate Level 2: The purpose of testing is to show that the software doesn t work ( testerbiased view ). A negative view, still it is in line with the basic aim of software testing Both views fail to answer the question: do we have good software or bad tests?

17 Mature testing Correctness cannot generally be achieved or demonstrated through testing. Testing cannot prove the absence of bugs, but merely expose them. Developers and testers should be on the same boat though. Level 3: The purpose of testing is not to prove anything specific, but to reduce the risk of using the software. A general, overall understanding is required of how to devise tests, and derive confidence/risk levels from their execution. Level 4: Testing is a mental discipline that helps all IT professionals develop higher quality software. The grand philosophical view : testing should be an integral part of the development process and play an important role towards the general the aim of improving software quality. 17

18 More terminology - test case Test case: A test case is composed of the test case values, expected results, prefix values, and postfix values necessary for a complete execution and evaluation of the software under test. Test case values: the input values necessary to complete some execution of the software under test. Expected values: the expected result that will be produced by the test case if and only if the program satisfies its intended behavior. Prefix values/actions: any inputs/commands necessary to put the software into the appropriate state to receive the test case values. Postfix values/actions : any inputs/commands that need to be sent to the software after the test case values are sent. 18

19 Test case execution setup/execute prefix values/actions 1 setup test case values (inputs) 2 execute software under test (SUT) 3 compare test outputs vs expected values 4 setup/execute postfix values/actions 5 We ll focus today only on testing that requires steps

20 Example test cases for numzero public static int numzero(int[] x) {! // Effects: if x == null throw NullPointerException! // else return the number of occurrences of 0 in x! 1 int count = 0;! 2 for (int i = 1; i < x.length; i++)! 3 if (x[i] == 0)! 4 count++;! 5 return count;! } test case test case values (x) expected values actual execution failure? 1 null NullPointerException NullPointerException No 2 { } 0 0 No 3 { 1,2,3 } 0 0 No 4 {1,0,1,0} 2 2 No 20 5 {0,1,2,0} 2 1 Yes

21 More terminology Test set: a set of test cases. We will use notation T for a test set. Test requirement : requirement that should be satisfied by a test set. Test requirements normally come in sets. We use notation TR for the set of test requirements. Coverage criterion: A coverage criterion C is a rule or collection of rules that define a set of test requirements TR(C) to be satisfied by a test set. Coverage level: the percentage of test requirements that are satisfied by a test set. We say T satisfies C if the coverage level of TR(C) by T is 100 %. Infeasible requirement: requirement that cannot be satisfied by any test case. If there are infeasible test requirements, the coverage level will never be 100%. 21

22 Basic coverage criteria public static int numzero(int[] x) {! // Effects: if x == null throw NullPointerException! // else return the number of occurrences of 0 in x! 1 int count = 0; /* I1 */! 2 for (int i = 1 /* I2 */; i < x.length /* I3,B1 */; i++ /* I4 */)! 3 if (x[i] == 0) /* I5,B2 */! 4 count++; /* I6 */! 5 return count; /* I7 */! } Line coverage (LC): cover every line in the SUT. TR(LC) = { line 1, line 2, line 3, line 4, line 5 } Instruction coverage (IC): cover every instruction in the SUT. TR(IC) = { I1, I2, I3, I4, I5, I6, I7 } Branch coverage (BC): cover every instruction, and including all cases at choice points (if, switch-case, etc). 22 TR(BC) = { NPE-B1, B1,!B1, B2,!B2 }

23 LC, IC, BC for numzero public static int numzero(int[] x) {! // Effects: if x == null throw NullPointerException! // else return the number of occurrences of 0 in x! 1 int count = 0; /* I1 */! 2 for (int i = 1 /* I2 */; i < x.length /* I3,B1 */; i++ /* I4 */)! 3 if (x[i] == 0) /* I5,B2 */! 4 count++; /* I6 */! 5 return count; /* I7 */! } test case test case values (x) expected values exec. result test fails? LC IC BC t1 null NPE NPE no 1 2 i1 i2 i3 NPE-B1 t2 { } 0 0 no i1 i2 i3 i7!b1 t3 {1,2} 0 0 no All except i6 B1,!B1,!B2 t4 {0,0 } 2 1 yes All All B1,!B1, B2 23 t5 {1,1,0} 1 0 no All All B1,!B1, B2,!B2

24 LC, IC, BC for numzero T (test set) LC level IC level BC level { t1 } 40 % (2/5) 42 % (3/7) 20 % (1/5) { t1, t2 } 60 % (3/5) 57 % (4/7) 40 % (2/5) { t2, t3 } 80 % (4/5) 85 % (6/7) 60 % (3/5) { t4 } 100 % (5/5) 100 % (7/7) 60 % (3/5) { t1, t5} 100 % (5/5) 100 % (7/7) 100 % (5/5) test case test case values (x) expected values exec. result test fails? LC IC BC t1 null NPE NPE no 1 2 i1 i2 i3 NPE-B1 t2 { } 0 0 no i1 i2 i3 i7!b1 t3 {1,2} 0 0 no All except i6 B1,!B1,!B2 t4 {0,0} 2 1 yes All All B1,!B1, B2 24 t5 {1,1,0} 1 0 no All All B1,!B1, B2,!B2

25 LC, IC, BC for numzero T (test set) LC level IC level BC level { t1 } 100 % 40 coverage % (2/5) for all criteria 42 % (3/7) 20 % (1/5) { t1, t2 } but bug is not exposed!!! 60 % (3/5) 57 % (4/7) t1 and t5 do not fail 40 % (2/5) { t2, t3 } 80 % (4/5) 85 % (6/7) 60 % (3/5) { t4 } 100 % (5/5) 100 % (7/7) 60 % (3/5) { t1, t5} 100 % (5/5) 100 % (7/7) 100 % (7/7) test case test case values (x) expected values exec. result test fails? LC IC BC t1 null NPE NPE no 1 2 i1 i2 i3 NPE-B1 t2 { } 0 0 no i1 i2 i3 i7!b1 t3 {1,2} 0 0 no All except i6 B1,!B1,!B2 t4 {0,0} 2 1 yes All All B1,!B1, B2 25 t5 {1,1,0} 1 0 no All All B1,!B1, B2,!B2

26 Criteria subsumption Criteria Subsumption: A coverage criterion C1 subsumes C2 if and only if every test set that satisfies criterion C1 also satisfies C2. For instance: instruction coverage subsumes line coverage branch coverage subsumes instruction coverage The inverse is not true. In the previous slide: If count++ appeared in the same line as if (x[i] == 0), test case t3 would cover all lines but not all instructions (instruction i6 is not be executed by t3). Test t4 covers all instructions, but not all branches. 26

27 Introduction to JUnit JUnit is a testing framework for Java (the most widely used one). Eclipse SDK includes JUnit and a GUI interface for it. Today we ll look at: JUnit test classes Anatomy of basic JUnit test methods JUnit assertions and other misc. features Associated patterns for test programming 27

28 JUnit - test classes 28 import static org.junit.assert.*;! import static vvs.arrayoperations.numzero;! import org.junit.test;!! public class ArrayOperationsNumZeroTest public void testnumzeroemptyarray() {!!! int x[] = {}; // zero-sized array!!! int n = numzero(x);!!! assertequals("0 zeros", 0, n);!! public void testnumzeroarraywithnozeros() {!!! int[] x = { 1,2, 3 };!!! int n = numzero(x);! imports test class test method annotation - one per test case - another test method/case!! assertequals("0 zeros in an array with no zeros", 0, n);!! }!...

29 JUnit/xUnit - conventions Testclass class pattern [G.Meszaros page 373] Group related test methods in a single test class. The name of test packages/classes/methods should at least transmit: The name of the SUT class (e.g., TestArrayOperationsNumZero) The name of the method or feature being tested (e.g., TestArrayOperationsNumZero) The relevant characteristics of the test case values per each test method (e.g., testnumzeroemptyarray) See G. Meszaros, xunit Testing patterns, page 158 It is also common to prefix or suffix test classes with Test and prefix test methods with test. 29

30 JUnit - test public void testnumzeroarraywithnozeros() {!! int[] x = { 1,2, 3 };! 1) setup test case values!!! int n = numzero(x);! 2) execute SUT!!! assertequals("0 zeros in an array with no zeros", 0, n);! }!... Test design atterns 3) assert expected vs. test outputs Setup + execute SUT + verify expected results (+ teardown) expected Use assertion methods provided by JUnit to verify expected results exec. output Use assertion messages together with assertion methods to give an indication of what went worn 30 Four-phase test, Assertion Method, and Assertion Message patterns [G. Meszaros, pages ]

31 JUnit assertions Method assertequals(msg,expected,value)! assertnotequals(msg,expected,value) asserttrue(msg, value)! assertfalse(msg, value) assertnull(msg, expression)! assertnotnull(msg, expression) assertarrayequals(msg, vexp, vval) assertsame(msg, expected, value) Checked condition value.equals(expected)!!value.equals(expected) value == true! value == false value == null! value!= null Arrays vexp and vval have the same contents. value == expected! (exactly the same object reference)! Full list at 31

32 Other JUnit features: exceptions as expected (expected = NullPointerException.class)!! public void testnumzerowithnullargument() {!!! int[] x = null;! numzero(x);!! } equivalent public void testnumzerowithnullargument1() {! int[] x = null;! try {! numzero(x);! fail("expected NullPointerException");! } catch (NullPointerException e) { }! } 32 Note: the 2nd pattern is more verbose and unnecessary in this case. It is useful in situations when we wish to perform other assertions beyond the expected exception behavior.

33 Other JUnit features: prefix/postfix actions public static void globalsetup() {! // prefix actions executed once before any test!...! public static void globalteardown() {! // prefix actions executed once after all tests!...! public void pertestsetup() {! // prefix actions executed before each test!...! public static void pertestteardown() {! // actions executed after each test!...! }

34 Test engineering - terminology Validation [A & O, p.11] The process of evaluating software at the end of the software development to ensure compliance with intended usage. not done by developers, but by experts in the intended usage of the software Verification [A & O, p.11] The process of determining whether the products of a given phase of the software development process fulfill the requirements established during the previous phase. requires technical background on the software, normally done by developers at the various stages of development 34

35 Test engineering - activities Test Manager } design Test Designs instantiate Executable Tests [A & O, p. 4]! Test Engineer Test Engineer Test Engineer P Computer execute Output Evaluate 35 different activities, technical backgrounds, levels of automation...

36 Types of Test Activities Summary 1a. Design Design test values to satisfy engineering goals Criteria Requires knowledge of discrete math, programming and testing 1b. Design Design test values from domain knowledge and intuition Human Requires knowledge of domain, UI, testing 2. Automation Embed test values into executable scripts Requires knowledge of scripting 3. Execution Run tests on the software and record the results Requires very little knowledge 4. Evaluation Evaluate results of testing, report to developers Requires domain knowledge These four general test activities are quite different It is a poor use of resources to use people inappropriately Introduction to Software Testing (Ch 1) Ammann & Offutt

37 Test engineering - overall goals Validation [A & O, p.11] The process of evaluating software at the end of the software development to ensure compliance with intended usage. not done by developers, but by experts in the intended usage of the software Verification [A & O, p.11] The process of determining whether the products of a given phase of the software development process fulfill the requirements established during the previous phase. requires technical background on the software, normally done by developers at the various stages of development 37

38 Testing and the SW development lifecycle Requirements Analysis Test Acceptance Test Validation Architectural Design Design Information System Test Subsystem Design Integration Test Detailed Design Module Test Verification Implementation Unit Test 38 [A & O, p 6]

39 Old : Testing at Different Levels main Class P Acceptance testing: Is the software acceptable to the user? Class A Class B System testing: Test the overall functionality of the system method ma1() method mb1() method ma2() method mb2() This view obscures underlying similarities Integration testing: Test how modules interact with each other Module testing: Test each class, file, module or component Unit testing: Test each unit (method) individually Introduction to Software Testing (Ch 1) Ammann & Offutt 53

40 Exercise 1 [Adapted from Exercise 3, page 16 from A & O, code in provided Eclipse project] F o r e a c h o f t h e f o u r m e t h o d s findlast( ), countpositive(), lastzero(), and oddorpos() (a) Identify the fault and what would be the correct code. (b) If possible, identify a test case that does not execute the fault (reachability condition not met). (c) Identify a test case that leads to failure (reachability, infection and propagation conditions all met). Identify the first error state. (d) If possible identify a test case that results in an error, but not a failure (propagation condition not met). Identify the first error state. (e) If possible, identify a test case that executes the fault but does not lead to an error state (infection condition not met). 40

41 Exercise 2 Write a JUnit test class for each method in exercise 1: (a) Start by writing tests that satisfy Line Coverage (b) Enhance the tests (if necessary) to satisfy Instruction Coverage (c) Enhance the tests (if necessary) to satisfy Branch Coverage Assess the coverage of your tests using EclEmma See Eclipse update site: 41

Faults, Errors, Failures

Faults, Errors, Failures Faults, Errors, Failures CS 4501 / 6501 Software Testing [Ammann and Offutt, Introduction to Software Testing ] 1 Software Testing Review Testing = process of finding input values to check against a software

More information

Fault, Error, and Failure

Fault, Error, and Failure Fault, Error, and Failure Testing, Quality Assurance, and Maintenance Winter 2018 Prof. Arie Gurfinkel based on slides by Prof. Lin Tan and others Terminology, IEEE 610.12-1990 Fault -- often referred

More information

Software Quality Assurance & Testing

Software Quality Assurance & Testing Software Quality Assurance & Testing 1.Software Testing - An ISTQB-BCS Certified Tester Foundation Guide 3rd edition, 2015 Brian Hambling, Peter Morgan, Geoff Thompson, Peter Williams,Angelina Samaroo

More information

More JUnit CS 4501 / 6501 Software Testing

More JUnit CS 4501 / 6501 Software Testing More JUnit CS 4501 / 6501 Software Testing [Ammann and Offutt, Introduction to Software Testing ] 1 Common methods review asserttrue(boolean condition) Assert that a condition is true asserttrue(string

More information

Basic Definitions: Testing

Basic Definitions: Testing Basic Definitions: Testing l What is software testing? Running a program In order to find faults a.k.a. defects a.k.a. errors a.k.a. flaws a.k.a. faults a.k.a. BUGS 1 Bugs Hopper s bug (moth stuck in a

More information

Logic-based test coverage

Logic-based test coverage Logic-based test coverage!!! Basic approach Clauses and predicates Basic coverage criteria: CC, PC, CoC Structural logic coverage of source code Logic coverage of specifications Active clause coverage

More information

Logic-based test coverage

Logic-based test coverage Eduardo Marques, Vasco Thudichum Vasconcelos Logic-based test coverage Basic approach Clauses and predicates Basic coverage criteria: CC, PC, CoC Structural logic coverage of source code Logic coverage

More information

Software Testing Lecture 1. Justin Pearson

Software Testing Lecture 1. Justin Pearson Software Testing Lecture 1 Justin Pearson 2017 1 / 50 Four Questions Does my software work? 2 / 50 Four Questions Does my software work? Does my software meet its specification? 3 / 50 Four Questions Does

More information

https://www.lri.fr/ linaye/gl.html

https://www.lri.fr/ linaye/gl.html Software Engineering https://www.lri.fr/ linaye/gl.html lina.ye@centralesupelec.fr Sequence 3, 2017-2018 1/61 Software Engineering Plan 1 2 3 4 5 2/61 Software Engineering Software Testing 3/61 Software

More information

Software Testing Prof. Meenakshi D Souza Department of Computer Science and Engineering International Institute of Information Technology, Bangalore

Software Testing Prof. Meenakshi D Souza Department of Computer Science and Engineering International Institute of Information Technology, Bangalore Software Testing Prof. Meenakshi D Souza Department of Computer Science and Engineering International Institute of Information Technology, Bangalore Lecture 04 Software Test Automation: JUnit as an example

More information

Anders Fröberg TDDD80 STORAGE AND TESTING

Anders Fröberg TDDD80 STORAGE AND TESTING Anders Fröberg anders.froberg@liu.se TDDD80 STORAGE AND TESTING 1 Agenda: Test Unit testing vs Traditional Testing Debugging and Refactoring Deployment (Test Driven Development (TDD)) (Acceptance Test

More information

Programming Embedded Systems

Programming Embedded Systems Programming Embedded Systems Lecture 8 Overview of software testing Wednesday Feb 8, 2012 Philipp Rümmer Uppsala University Philipp.Ruemmer@it.uu.se 1/53 Lecture outline Testing in general Unit testing

More information

Regression testing. Whenever you find a bug. Why is this a good idea?

Regression testing. Whenever you find a bug. Why is this a good idea? Regression testing Whenever you find a bug Reproduce it (before you fix it!) Store input that elicited that bug Store correct output Put into test suite Then, fix it and verify the fix Why is this a good

More information

CS 520 Theory and Practice of Software Engineering Fall 2018

CS 520 Theory and Practice of Software Engineering Fall 2018 Today CS 52 Theory and Practice of Software Engineering Fall 218 Software testing October 11, 218 Introduction to software testing Blackbox vs. whitebox testing Unit testing (vs. integration vs. system

More information

Program-based Mutation Testing

Program-based Mutation Testing Program-based Mutation Testing CS 4501 / 6501 Software Testing [Ammann and Offutt, Introduction to Software Testing, Ch. 9.2] 1 Applying Syntax-Based Testing to Programs Test requirements are derived from

More information

Topics in Software Testing

Topics in Software Testing Dependable Software Systems Topics in Software Testing Material drawn from [Beizer, Sommerville] Software Testing Software testing is a critical element of software quality assurance and represents the

More information

Software Testing part II (white box) Lecturer: Giuseppe Santucci

Software Testing part II (white box) Lecturer: Giuseppe Santucci Software Testing part II (white box) Lecturer: Giuseppe Santucci 4. White box testing White-box (or Glass-box) testing: general characteristics Statement coverage Decision coverage Condition coverage Decision

More information

The Importance of Test

The Importance of Test Software Testing Mistake in coding is called error, Error found by tester is called defect, Defect accepted by development team is called bug, Product does not meet the requirements then it Is failure.

More information

Programming Embedded Systems

Programming Embedded Systems Programming Embedded Systems Overview of testing techniques Monday March 3, 2014 Philipp Rümmer Uppsala University Philipp.Ruemmer@it.uu.se 1/70 Lecture outline Background, testing in general Unit testing

More information

Test automation / JUnit. Building automatically repeatable test suites

Test automation / JUnit. Building automatically repeatable test suites Test automation / JUnit Building automatically repeatable test suites Test automation n Test automation is software that automates any aspect of testing n Generating test inputs and expected results n

More information

Test automation Test automation / JUnit

Test automation Test automation / JUnit Test automation Test automation / JUnit Building automatically repeatable test suites Test automation is software that automates any aspect of testing Generating test inputs and expected results Running

More information

Softwaretechnik. Lecture 08: Testing and Debugging Overview. Peter Thiemann SS University of Freiburg, Germany

Softwaretechnik. Lecture 08: Testing and Debugging Overview. Peter Thiemann SS University of Freiburg, Germany Softwaretechnik Lecture 08: Testing and Debugging Overview Peter Thiemann University of Freiburg, Germany SS 2012 Literature Essential Reading Why Programs Fail: A Guide to Systematic Debugging, A Zeller

More information

Manuel Oriol, CHCRC-C, Software Testing ABB

Manuel Oriol, CHCRC-C, Software Testing ABB Manuel Oriol, CHCRC-C, 08.11.2017 Software Testing Slide 1 About me 1998 2004 2005 2008 2011 Slide 2 Introduction Why do we test? Did you have to deal with testing in the past? Slide 3 Ariane 5 http://www.youtube.com/watch?v=kyurqduyepi

More information

EECS 4313 Software Engineering Testing

EECS 4313 Software Engineering Testing EECS 4313 Software Engineering Testing Topic 03: Test automation / JUnit - Building automatically repeatable test suites Zhen Ming (Jack) Jiang Acknowledgement Some slides are from Prof. Alex Orso Relevant

More information

CS159. Nathan Sprague. September 30, 2015

CS159. Nathan Sprague. September 30, 2015 CS159 Nathan Sprague September 30, 2015 Testing Happens at Multiple Levels Unit Testing - Test individual classes in isolation. Focus is on making sure that each method works according to specification.

More information

Steps for project success. git status. Milestones. Deliverables. Homework 1 submitted Homework 2 will be posted October 26.

Steps for project success. git status. Milestones. Deliverables. Homework 1 submitted Homework 2 will be posted October 26. git status Steps for project success Homework 1 submitted Homework 2 will be posted October 26 due November 16, 9AM Projects underway project status check-in meetings November 9 System-building project

More information

Computer Science and Software Engineering University of Wisconsin - Platteville 9-Software Testing, Verification and Validation

Computer Science and Software Engineering University of Wisconsin - Platteville 9-Software Testing, Verification and Validation Computer Science and Software Engineering University of Wisconsin - Platteville 9-Software Testing, Verification and Validation Yan Shi SE 2730 Lecture Notes Verification and Validation Verification: Are

More information

Testing, Debugging, and Verification

Testing, Debugging, and Verification Testing, Debugging, and Verification TDA567/DIT082 Introduction Srinivas Pinisetty 30 October 2017 Software is everywhere Complexity, evolution, reuse, multiple domains/teams, Software bug Error Fault

More information

Agile Software Development. Lecture 7: Software Testing

Agile Software Development. Lecture 7: Software Testing Agile Software Development Lecture 7: Software Testing Mahmoud El-Gayyar elgayyar@ci.suez.edu.eg Slides are a modified version of the slides by Prof. Kenneth M. Anderson Outline Testing Terminology Types

More information

CSE 403: Software Engineering, Fall courses.cs.washington.edu/courses/cse403/16au/ Unit Testing. Emina Torlak

CSE 403: Software Engineering, Fall courses.cs.washington.edu/courses/cse403/16au/ Unit Testing. Emina Torlak CSE 403: Software Engineering, Fall 2016 courses.cs.washington.edu/courses/cse403/16au/ Unit Testing Emina Torlak emina@cs.washington.edu Outline Software quality control Effective unit testing Coverage

More information

Softwaretechnik. Lecture 08: Testing and Debugging Overview. Peter Thiemann SS University of Freiburg, Germany

Softwaretechnik. Lecture 08: Testing and Debugging Overview. Peter Thiemann SS University of Freiburg, Germany Softwaretechnik Lecture 08: Testing and Debugging Overview Peter Thiemann University of Freiburg, Germany SS 2012 Literature Essential Reading Why Programs Fail: A Guide to Systematic Debugging, A Zeller

More information

CS 520 Theory and Practice of Software Engineering Fall 2018

CS 520 Theory and Practice of Software Engineering Fall 2018 CS 520 Theory and Practice of Software Engineering Fall 2018 Nediyana Daskalova Monday, 4PM CS 151 Debugging October 30, 2018 Personalized Behavior-Powered Systems for Guiding Self-Experiments Help me

More information

Testing: Coverage and Structural Coverage

Testing: Coverage and Structural Coverage Testing: Coverage and Structural Coverage Testing, Quality Assurance, and Maintenance Winter 2018 Prof. Arie Gurfinkel based on slides by Prof. Marsha Chechik and Prof. Lin Tan How would you test this

More information

EECS 4313 Software Engineering Testing. Topic 01: Limits and objectives of software testing Zhen Ming (Jack) Jiang

EECS 4313 Software Engineering Testing. Topic 01: Limits and objectives of software testing Zhen Ming (Jack) Jiang EECS 4313 Software Engineering Testing Topic 01: Limits and objectives of software testing Zhen Ming (Jack) Jiang Acknowledge Some of the contents are from Prof. Alex Orso, Bil Tzerpos and Gunnar Gotshalks

More information

Written exam TDDD04 Software Testing

Written exam TDDD04 Software Testing LiTH, Linköpings tekniska högskola IDA, Institutionen för datavetenskap Ola Leifler Written exam TDDD04 Software Testing 2016-10-26 Permissible aids Dictionary (printed, NOT electronic) Teacher on duty

More information

Announcements. Lab tomorrow. Quiz Thursday P3 due Friday. Exceptions and unit testing

Announcements. Lab tomorrow. Quiz Thursday P3 due Friday. Exceptions and unit testing Announcements Lab tomorrow Exceptions and unit testing Quiz Thursday P3 due Friday Follow-ups Exceptions and Try-catch Using try-catch with loops Comparison to switch vs. if-else if Realistic examples

More information

Software Testing: Introduction

Software Testing: Introduction Software Testing: Introduction Mohammad Mousavi Halmstad University, Sweden http://bit.ly/tav16 Testing and Verification, January 22, 2016 Outline Organization Why? What? How?, When? Contact information

More information

Lecture 20: SW Testing Presented by: Mohammad El-Ramly, PhD

Lecture 20: SW Testing Presented by: Mohammad El-Ramly, PhD Cairo University Faculty of Computers and Information CS251 Software Engineering Lecture 20: SW Testing Presented by: Mohammad El-Ramly, PhD http://www.acadox.com/join/75udwt Outline Definition of Software

More information

Testing: Coverage and Structural Coverage

Testing: Coverage and Structural Coverage Testing: Coverage and Structural Coverage Testing, Quality Assurance, and Maintenance Winter 2017 Prof. Arie Gurfinkel based on slides by Prof. Marsha Chechik and Prof. Lin Tan How would you test this

More information

Unit Testing : Software Testing

Unit Testing : Software Testing Unit Testing 219343: Software Testing Some materials are from Alberto Savoia's slides on unit testing, George Necula's software engineering course, and Hunt and Thomas, Pragmatic Unit Testing, 2003. 11/24/07

More information

Test-Driven Development (a.k.a. Design to Test) CSE260, Computer Science B: Honors Stony Brook University

Test-Driven Development (a.k.a. Design to Test) CSE260, Computer Science B: Honors Stony Brook University Test-Driven Development (a.k.a. Design to Test) CSE260, Computer Science B: Honors Stony Brook University http://www.cs.stonybrook.edu/~cse260 Person-hours Labor is sometimes measured in person-hours,

More information

Testing. CMSC 433 Programming Language Technologies and Paradigms Spring A Real Testing Example. Example (Black Box)?

Testing. CMSC 433 Programming Language Technologies and Paradigms Spring A Real Testing Example. Example (Black Box)? Testing CMSC 433 Programming Language Technologies and Paradigms Spring 2007 Testing Feb. 15, 2007 Some slides adapted from FSE 98 Tutorial by Michal Young and Mauro Pezze Execute program on sample input

More information

Lecture 15 Software Testing

Lecture 15 Software Testing Lecture 15 Software Testing Includes slides from the companion website for Sommerville, Software Engineering, 10/e. Pearson Higher Education, 2016. All rights reserved. Used with permission. Topics covered

More information

Testing. ECE/CS 5780/6780: Embedded System Design. Why is testing so hard? Why do testing?

Testing. ECE/CS 5780/6780: Embedded System Design. Why is testing so hard? Why do testing? Testing ECE/CS 5780/6780: Embedded System Design Scott R. Little Lecture 24: Introduction to Software Testing and Verification What is software testing? Running a program in order to find bugs (faults,

More information

Three General Principles of QA. COMP 4004 Fall Notes Adapted from Dr. A. Williams

Three General Principles of QA. COMP 4004 Fall Notes Adapted from Dr. A. Williams Three General Principles of QA COMP 4004 Fall 2008 Notes Adapted from Dr. A. Williams Software Quality Assurance Lec2 1 Three General Principles of QA Know what you are doing. Know what you should be doing.

More information

Test automation / JUnit. Building automatically repeatable test suites

Test automation / JUnit. Building automatically repeatable test suites Test automation / JUnit Building automatically repeatable test suites JUnit in Eclipse For this course, we will use JUnit in Eclipse It is automatically a part of Eclipse One documentation site (all one

More information

MTAT : Software Testing

MTAT : Software Testing MTAT.03.159: Software Testing Lecture 01: Introduction to Software Testing (Textbook Ch. 1-3) Spring 2017 Dietmar Pfahl email: dietmar.pfahl@ut.ee Structure of Lecture 1 Introduction and Motivation Course

More information

Graph Coverage for Source Code. Data Flow Graph Coverage for Source Code

Graph Coverage for Source Code. Data Flow Graph Coverage for Source Code Graph Coverage for Source Code Data Flow Graph Coverage for Source Code 1 Graph Coverage for Design Elements Use of data abstraction and object oriented software has increased importance on modularity

More information

Introduction to Software Testing Chapter 5.1 Syntax-based Testing

Introduction to Software Testing Chapter 5.1 Syntax-based Testing Introduction to Software Testing Chapter 5.1 Syntax-based Testing Paul Ammann & Jeff Offutt http://www.cs.gmu.edu/~offutt/ softwaretest/ Ch. 5 : Syntax Coverage Four Structures for Modeling Software Graphs

More information

Verification and Validation. Ian Sommerville 2004 Software Engineering, 7th edition. Chapter 22 Slide 1

Verification and Validation. Ian Sommerville 2004 Software Engineering, 7th edition. Chapter 22 Slide 1 Verification and Validation Ian Sommerville 2004 Software Engineering, 7th edition. Chapter 22 Slide 1 Verification vs validation Verification: "Are we building the product right?. The software should

More information

Unit testing. JUnit. JUnit and Eclipse. A JUnit test class 3/6/17. A method is flagged as a JUnit test case.

Unit testing. JUnit. JUnit and Eclipse. A JUnit test class 3/6/17. A method is flagged as a JUnit test case. Unit testing JUnit ENGI 5895 unit testing: Looking for errors in a subsystem in isolation. Generally a "subsystem" means a particular class or object. The Java library JUnit helps us to easily perform

More information

Software Engineering

Software Engineering Software Engineering Lecture 13: Testing and Debugging Testing Peter Thiemann University of Freiburg, Germany SS 2014 Recap Recap Testing detect the presence of bugs by observing failures Recap Testing

More information

Junit Overview. By Ana I. Duncan

Junit Overview. By Ana I. Duncan Junit Overview By Ana I. Duncan 1 What Is Junit Why Junit, Why test? Junit Lifecycle Junit Examples from CM Other Testing frameworks Resources Before After Agenda 2 JUnit is a member of the xunit testing

More information

Aerospace Software Engineering

Aerospace Software Engineering 16.35 Aerospace Software Engineering Verification & Validation Prof. Kristina Lundqvist Dept. of Aero/Astro, MIT Would You...... trust a completely-automated nuclear power plant?... trust a completely-automated

More information

Software Engineering 2 A practical course in software engineering. Ekkart Kindler

Software Engineering 2 A practical course in software engineering. Ekkart Kindler Software Engineering 2 A practical course in software engineering Quality Management Main Message Planning phase Definition phase Design phase Implem. phase Acceptance phase Mainten. phase 3 1. Overview

More information

Ingegneria del Software Corso di Laurea in Informatica per il Management

Ingegneria del Software Corso di Laurea in Informatica per il Management Ingegneria del Software Corso di Laurea in Informatica per il Management Software testing Davide Rossi Dipartimento di Informatica Università di Bologna Validation and verification Software testing is

More information

Django Data Model Revisited and Testing Introduction

Django Data Model Revisited and Testing Introduction Django Data Model Revisited and Testing Introduction CS 370 SE Practicum, Cengiz Günay (Some slides courtesy of Eugene Agichtein and the Internets) CS 370, Günay (Emory) Django Data and Testing Intro Spring

More information

10. Software Testing Fundamental Concepts

10. Software Testing Fundamental Concepts 10. Software Testing Fundamental Concepts Department of Computer Science and Engineering Hanyang University ERICA Campus 1 st Semester 2016 Testing in Object-Oriented Point of View Error Correction Cost

More information

An Introduction to Systematic Software Testing. Robert France CSU

An Introduction to Systematic Software Testing. Robert France CSU An Introduction to Systematic Software Testing Robert France CSU Why do we need to systematically test software? Poor quality products can Inconvenience direct and indirect users Result in severe financial

More information

Section 4: Graphs and Testing. Slides by Erin Peach and Nick Carney

Section 4: Graphs and Testing. Slides by Erin Peach and Nick Carney Section 4: Graphs and Testing Slides by Erin Peach and Nick Carney with material from Vinod Rathnam, Alex Mariakakis, Krysta Yousoufian, Mike Ernst, Kellen Donohue AGENDA Graphs JUnit Testing Test Script

More information

Unit testing. unit testing: Looking for errors in a subsystem in isolation. The basic idea: JUnit provides "assert" commands to help us write tests.

Unit testing. unit testing: Looking for errors in a subsystem in isolation. The basic idea: JUnit provides assert commands to help us write tests. JUnit ENGI 5895 Adapted from slides created by Marty Stepp based on materials by M. Ernst, S. Reges, D. Notkin, R. Mercer, Wikipedia http://www.cs.washington.edu/331/ 1 Unit testing unit testing: Looking

More information

Software Testing for Developer Development Testing. Duvan Luong, Ph.D. Operational Excellence Networks

Software Testing for Developer Development Testing. Duvan Luong, Ph.D. Operational Excellence Networks Software Testing for Developer Development Testing Duvan Luong, Ph.D. Operational Excellence Networks Contents R&D Testing Approaches Static Analysis White Box Testing Black Box Testing 4/2/2012 2 Development

More information

Software Engineering Testing and Debugging Testing

Software Engineering Testing and Debugging Testing Software Engineering Testing and Debugging Testing Prof. Dr. Peter Thiemann Universitt Freiburg 08.06.2011 Recap Testing detect the presence of bugs by observing failures Debugging find the bug causing

More information

Chapter 8 Software Testing. Chapter 8 Software testing

Chapter 8 Software Testing. Chapter 8 Software testing Chapter 8 Software Testing 1 Topics covered Introduction to testing Stages for testing software system are: Development testing Release testing User testing Test-driven development as interleave approach.

More information

GENERATING COST-EFFECTIVE CRITERIA-BASED TESTS FROM BEHAVIORAL MODELS

GENERATING COST-EFFECTIVE CRITERIA-BASED TESTS FROM BEHAVIORAL MODELS GENERATING COST-EFFECTIVE CRITERIA-BASED TESTS FROM BEHAVIORAL MODELS by Nan Li A Dissertation Submitted to the Graduate Faculty of George Mason University In Partial Fulfillment of The Requirements for

More information

The Software Engineering Profession SWENET Module April 2004

The Software Engineering Profession SWENET Module April 2004 The Software Engineering Profession SWENET Module April 2004 Developed with support from the National Science Foundation SE Profession - 1 Overview What is an engineering profession? What does take to

More information

Principles of Software Construction: Objects, Design, and Concurrency (Part 2: Designing (Sub )Systems)

Principles of Software Construction: Objects, Design, and Concurrency (Part 2: Designing (Sub )Systems) Principles of Software Construction: Objects, Design, and Concurrency (Part 2: Designing (Sub )Systems) More Analysis for Functional Correctness Jonathan Aldrich Charlie Garrod School of Computer Science

More information

Software Engineering Theory. Lena Buffoni (slides by Kristian Sandahl/Mariam Kamkar) Department of Computer and Information Science

Software Engineering Theory. Lena Buffoni (slides by Kristian Sandahl/Mariam Kamkar) Department of Computer and Information Science Software Engineering Theory Lena Buffoni (slides by Kristian Sandahl/Mariam Kamkar) Department of Computer and Information Science 2015-09-20 Title/Lecturer SEPTEMBER 20, 2016 2 Requirement formalization

More information

CSE 201 JAVA PROGRAMMING I. Copyright 2016 by Smart Coding School

CSE 201 JAVA PROGRAMMING I. Copyright 2016 by Smart Coding School CSE 201 JAVA PROGRAMMING I Primitive Data Type Primitive Data Type 8-bit signed Two s complement Integer -128 ~ 127 Primitive Data Type 16-bit signed Two s complement Integer -32768 ~ 32767 Primitive Data

More information

MTAT : Software Testing

MTAT : Software Testing MTAT.03.159: Software Testing Lecture 02: Basic Black-Box and White-Box Testing Techniques (Textbook Ch. 4 & 5) Spring 2018 Dietmar Pfahl email: dietmar.pfahl@ut.ee Structure of Lecture 2 Black-Box vs.

More information

MTAT : Software Testing

MTAT : Software Testing MTAT.03.159: Software Testing Lecture 03: White-Box Testing (Textbook Ch. 5) Dietmar Pfahl Spring 2017 email: dietmar.pfahl@ut.ee Lecture Chapter 5 White-box testing techniques (Lab 3) Structure of Lecture

More information

Jtest Tutorial. Tutorial

Jtest Tutorial. Tutorial Jtest Jtest Welcome to the Jtest. This tutorial walks you through how to perform common Jtest tasks using example files. Please note that although the four types of tests (static analysis, white-box testing,

More information

Testing. Topics. Types of Testing. Types of Testing

Testing. Topics. Types of Testing. Types of Testing Topics 1) What are common types of testing? a) Testing like a user: through the UI. b) Testing like a dev: through the code. 2) What makes a good bug report? 3) How can we write code to test code (via

More information

Test design techniques

Test design techniques INF3121 : Software Testing 12. 02. 2015 Lecture 4 Test design techniques Lecturer: Raluca Florea INF3121/ 12.02.2015 / Raluca Florea 1 Overview 1. The test development process 2. Categories of test design

More information

In this Lecture you will Learn: Testing in Software Development Process. What is Software Testing. Static Testing vs.

In this Lecture you will Learn: Testing in Software Development Process. What is Software Testing. Static Testing vs. In this Lecture you will Learn: Testing in Software Development Process Examine the verification and validation activities in software development process stage by stage Introduce some basic concepts of

More information

C07: Testing and JUnit

C07: Testing and JUnit CISC 3120 C07: Testing and JUnit Hui Chen Department of Computer & Information Science CUNY Brooklyn College 9/19/2017 CUNY Brooklyn College 1 Outline Recap and issues Grades and feedback Assignments &

More information

Video 2.1. Arvind Bhusnurmath. Property of Penn Engineering, Arvind Bhusnurmath. SD1x-2 1

Video 2.1. Arvind Bhusnurmath. Property of Penn Engineering, Arvind Bhusnurmath. SD1x-2 1 Video 2.1 Arvind Bhusnurmath SD1x-2 1 Topics Why is testing important? Different types of testing Unit testing SD1x-2 2 Software testing Integral part of development. If you ship a software with bugs,

More information

Overview. State-of-the-Art. Relative cost of error correction. CS 619 Introduction to OO Design and Development. Testing.

Overview. State-of-the-Art. Relative cost of error correction. CS 619 Introduction to OO Design and Development. Testing. Overview CS 619 Introduction to OO Design and Development ing! Preliminaries! All sorts of test techniques! Comparison of test techniques! Software reliability Fall 2012! Main issues: There are a great

More information

F. Tip and M. Weintraub FUNCTIONAL TESTING

F. Tip and M. Weintraub FUNCTIONAL TESTING F. Tip and M. Weintraub FUNCTIONAL TESTING ACKNOWLEDGEMENTS Thanks go to Andreas Zeller for allowing incorporation of his materials 2 HOW TO TELL IF A SYSTEM MEETS EXPECTATIONS? Two options: 1. testing:

More information

Modern Methods in Software Engineering. Testing.

Modern Methods in Software Engineering. Testing. Modern Methods in Software Engineering Testing www.imit.kth.se/courses/2g1522 Literature used Text book Chapter 11 Introduction Content Terminology Types of errors Dealing with errors Component Testing

More information

Question 1: What is a code walk-through, and how is it performed?

Question 1: What is a code walk-through, and how is it performed? Question 1: What is a code walk-through, and how is it performed? Response: Code walk-throughs have traditionally been viewed as informal evaluations of code, but more attention is being given to this

More information

Chapter 11, Testing. Using UML, Patterns, and Java. Object-Oriented Software Engineering

Chapter 11, Testing. Using UML, Patterns, and Java. Object-Oriented Software Engineering Chapter 11, Testing Using UML, Patterns, and Java Object-Oriented Software Engineering Outline Terminology Types of errors Dealing with errors Quality assurance vs Testing Component Testing! Unit testing!

More information

Program Correctness and Efficiency. Chapter 2

Program Correctness and Efficiency. Chapter 2 Program Correctness and Efficiency Chapter 2 Chapter Objectives To understand the differences between the three categories of program errors To understand the effect of an uncaught exception and why you

More information

Logic Coverage for Source Code

Logic Coverage for Source Code Logic Coverage for Source Code CS 4501 / 6501 Software Testing [Ammann and Offutt, Introduction to Software Testing, Ch. 8] 1 Structural Logic Coverage for Source Code Aim: to identify test requirements

More information

Introduc)on to tes)ng with JUnit. Workshop 3

Introduc)on to tes)ng with JUnit. Workshop 3 Introduc)on to tes)ng with JUnit Workshop 3 We have to deal with errors Early errors are usually syntax errors. The compiler will spot these. Later errors are usually logic errors. The compiler cannot

More information

Topics. Software Testing Test Driven Development Black Box Testing Unit Testing White Box Testing Coverage Testing Software Debugging

Topics. Software Testing Test Driven Development Black Box Testing Unit Testing White Box Testing Coverage Testing Software Debugging Supplemental Materials: Software esting CS2: Data Structures and Algorithms Colorado State University Chris Wilcox, Russ Wakefield, Wim Bohm, Dave Matthews opics Software esting est Driven Development

More information

JUnit Testing Framework Architecture

JUnit Testing Framework Architecture JUnit Testing Framework Architecture Unit under test (usually a class or a small number of classes) Test environment (fixture) Program state (e.g., some collection of variables/objects that will be used

More information

Software Verification and Validation. Prof. Lionel Briand Ph.D., IEEE Fellow

Software Verification and Validation. Prof. Lionel Briand Ph.D., IEEE Fellow Software Verification and Validation Prof. Lionel Briand Ph.D., IEEE Fellow 1 White-Box Testing 2 White-Box vs. Black-BoxTesting: Reminder Software Representation (Model) Associated Criteria Test cases

More information

Test Automation. 20 December 2017

Test Automation. 20 December 2017 Test Automation 20 December 2017 The problem of test automation Testing has repetitive components, so automation is justified The problem is cost-benefit evaluation of automation [Kaner] Time for: test

More information

Chapter 10. Testing and Quality Assurance

Chapter 10. Testing and Quality Assurance Chapter 10 Testing and Quality Assurance Different styles of doing code review Human Reviewer Code Inspection with continuous integration infrastructure Pinger s testing set up Testing Related topics 1.

More information

Software Engineering

Software Engineering Software Engineering Lecture 15: Testing and Debugging Debugging Peter Thiemann University of Freiburg, Germany SS 2014 Motivation Debugging is unavoidable and a major economical factor Software bugs cost

More information

Testing. Technion Institute of Technology Author: Assaf Israel. Author: Assaf Israel - Technion

Testing. Technion Institute of Technology Author: Assaf Israel. Author: Assaf Israel - Technion Testing Technion Institute of Technology 236700 1 Author: Assaf Israel Why test? Programming is incremental by nature We want to verify we haven t broken anything Tests not only examine the code s functionality

More information

INTRODUCTION TO SOFTWARE ENGINEERING

INTRODUCTION TO SOFTWARE ENGINEERING INTRODUCTION TO SOFTWARE ENGINEERING Introduction to Software Testing d_sinnig@cs.concordia.ca Department for Computer Science and Software Engineering What is software testing? Software testing consists

More information

When Trouble Comes: The Basics of Debugging

When Trouble Comes: The Basics of Debugging When Trouble Comes: The Basics of Debugging No one is capable of performing IT tasks flawlessly all of the time. Therefore, web page design, programming and any other logical activity will require debugging

More information

Checking Current Code Coverage

Checking Current Code Coverage Junit Tests Checking Current Code Coverage We use onap Sonar to track code coverage (sonar.onap.org) To see the appc coverage, click on the appc project on the front page (make sure you choose the most

More information

Chap 2. Introduction to Software Testing

Chap 2. Introduction to Software Testing Chap 2. Introduction to Software Testing 2.1 Software Testing Concepts and Processes 2.2 Test Management 1 2.1 Software Testing Concepts and Processes 1. Introduction 2. Testing Dimensions 3. Test Concepts

More information

Testing! The material for this lecture is drawn, in part, from! The Practice of Programming (Kernighan & Pike) Chapter 6!

Testing! The material for this lecture is drawn, in part, from! The Practice of Programming (Kernighan & Pike) Chapter 6! Testing The material for this lecture is drawn, in part, from The Practice of Programming (Kernighan & Pike) Chapter 6 1 Goals of this Lecture Help you learn about: Internal testing External testing General

More information

Second assignment came out Monday evening. Find defects in Hnefetafl rules written by your classmates. Topic: Code Inspection and Testing

Second assignment came out Monday evening. Find defects in Hnefetafl rules written by your classmates. Topic: Code Inspection and Testing Announcements Second assignment came out Monday evening Topic: Code Inspection and Testing Find defects in Hnefetafl rules written by your classmates Compare inspection, coverage testing, random testing,

More information

MTAT : Software Testing

MTAT : Software Testing MTAT.03.159: Software Testing Lecture 03: White-Box Testing (Textbook Ch. 5) Dietmar Pfahl Spring 2016 email: dietmar.pfahl@ut.ee Lecture Chapter 5 White-box testing techniques (Lab 3) Structure of Lecture

More information

Integration Testing. Conrad Hughes School of Informatics. Slides thanks to Stuart Anderson

Integration Testing. Conrad Hughes School of Informatics. Slides thanks to Stuart Anderson Integration Testing Conrad Hughes School of Informatics Slides thanks to Stuart Anderson 19 February 2010 Software Testing: Lecture 10 1 Unit Test vs Integration Testing 1 The ideal in unit testing is

More information