Testing Objectives. Successful testing: discovers previously unknown errors

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

Bridge Course On Software Testing

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

Testing. Unit, integration, regression, validation, system. OO Testing techniques Application of traditional techniques to OO software

Chapter 9. Software Testing

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

Types of Software Testing: Different Testing Types with Details

Sample Question Paper. Software Testing (ETIT 414)

WHY TEST SOFTWARE?...

Software Testing TEST CASE SELECTION AND ADEQUECY TEST EXECUTION

Client-server application testing plan

Chapter 8 Software Testing. Chapter 8 Software testing

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

It is primarily checking of the code and/or manually reviewing the code or document to find errors This type of testing can be used by the developer

T Salausjärjestelmät (Cryptosystems) Security testing. Security testing. Outline. Testing Final stages of life cycle

Cursul Aprilie

Program Analysis. Program Analysis

Higher-order Testing. Stuart Anderson. Stuart Anderson Higher-order Testing c 2011

INTRODUCTION TO SOFTWARE ENGINEERING

Verification and Validation

Software Testing. Software Testing. in the textbook. Chapter 8. Verification and Validation. Verification and Validation: Goals

1 Visible deviation from the specification or expected behavior for end-user is called: a) an error b) a fault c) a failure d) a defect e) a mistake

Lecture 15 Software Testing

Software Engineering (CSC 4350/6350) Rao Casturi

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

Software Engineering Fall 2015 (CSC 4350/6350) TR. 5:30 pm 7:15 pm. Rao Casturi 11/10/2015

18-642: Testing Overview

Quote by Bruce Sterling, from: A Software Testing Primer, Nick Jenkins

Software Engineering Fall 2014

Software Testing Interview Question and Answer

Program Verification! Goals of this Lecture! Words from the Wise! Testing!

10. Software Testing Fundamental Concepts

Software Testing. Massimo Felici IF

Verification and Validation. Assuring that a software system meets a user s needs. Verification vs Validation. The V & V Process

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

Ontology Summit 2013: Ontology Evaluation Across the Ontology Lifecyle Track B: Extrinsic Aspects of Ontology Evaluation

Comparison Study of Software Testing Methods and Levels- A Review

Chapter 8 Software Testing

MONIKA HEINER.

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

Software Engineering Testing and Debugging Testing

Chapter 8 Software Testing. Chapter 8 So-ware tes0ng

Software Testing. Testing: Our Experiences

Verification and Validation

Testing. Prof. Clarkson Fall Today s music: Wrecking Ball by Miley Cyrus

Verification and Validation

Verification Overview Testing Theory and Principles Testing in Practice. Verification. Miaoqing Huang University of Arkansas 1 / 80

Basic Concepts of System Testing - A Beginners Guide.

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

Department of Electrical & Computer Engineering, University of Calgary. B.H. Far

SOFTWARE ENGINEERING IT 0301 Semester V B.Nithya,G.Lakshmi Priya Asst Professor SRM University, Kattankulathur

Part 5. Verification and Validation

Software Design Models, Tools & Processes. Lecture 6: Transition Phase Cecilia Mascolo

Testing! Prof. Leon Osterweil! CS 520/620! Spring 2013!

Software Quality Assurance. David Janzen

Topic: Software Verification, Validation and Testing Software Engineering. Faculty of Computing Universiti Teknologi Malaysia

Terminology. There are many different types of errors and different ways how we can deal with them.

Sample Exam Syllabus

Improving Software Testability

Why testing and analysis. Software Testing. A framework for software testing. Outline. Software Qualities. Dependability Properties

Testing is the process of evaluating a system or its component(s) with the intent to find whether it satisfies the specified requirements or not.

Facts About Testing. Cost/benefit. Reveal faults. Bottom-up. Testing takes more than 50% of the total cost of software development

Modern Systems Analysis and Design. Third Edition. Jeffrey A. Hoffer Joey F. George Joseph S. Valacich. Chapter 17 System Implementation

Learning outcomes. Systems Engineering. Debugging Process. Debugging Process. Review

Topics in Software Testing

SmARt Shopping Project

Software Testing. Minsoo Ryu. Hanyang University. Real-Time Computing and Communications Lab., Hanyang University

Quality Assurance: Test Development & Execution. Ian S. King Test Development Lead Windows CE Base OS Team Microsoft Corporation

Quality Assurance = Testing? SOFTWARE QUALITY ASSURANCE. Meaning of Quality. How would you define software quality? Common Measures.

Software Engineering

The Fundamental Testing Process in Practical or Company environment

CS Module 1 Outline. What does Correctness Mean? Correctness Continued. Correctness Continued. Correctness Continued

Software Testing. An Overview

15 Sharing Main Memory Segmentation and Paging

UNIT-2 Levels of Testing

IBM. OA VTAM 3270 Intrusion Detection Services - Overview, Considerations, and Assessment (Prerequisite) z/os Communications Server

How Scalable is your SMB?

Software Testing. Hans-Petter Halvorsen, M.Sc.

Certified Tester Foundation Level(CTFL)

Software Engineering and Scientific Computing

Software Quality. Richard Harris

An Overview of Non-Functional Testing

Data Structures. Subodh Kumar. Dept of Computer Sc. & Engg. IIT Delhi

Module 1 : Fundamentals of Testing. Section 1: Manual Testing

Using Static Code Analysis to Find Bugs Before They Become Failures

Chapter 11, Testing, Part 2: Integration and System Testing

(See related materials in textbook.) CSE 435: Software Engineering (slides adapted from Ghezzi et al & Stirewalt

Verification and Validation. Verification and validation

Chapter 11, Testing, Part 2: Integration and System Testing

W.C.Uduwela. Dept. of Mathematics & Computer Science

16 Sharing Main Memory Segmentation and Paging

Root cause codes: Level One: See Chapter 6 for a discussion of using hierarchical cause codes.

White Paper. How the Meltdown and Spectre bugs work and what you can do to prevent a performance plummet. Contents

C & Data Structures syllabus

Integration Testing Qualidade de Software 2

CMSC 132: OBJECT-ORIENTED PROGRAMMING II

Aerospace Software Engineering

Software Testing. Software Testing. in the textbook. Chapter 8. Verification and Validation. Verification Techniques

QUIZ Friends class Y;

Testing Tools. Software Testing and Verification. Lecture 14. Stephen M. Thebaut, Ph.D. Prepared by. University of Florida

Transcription:

Testing Objectives Informal view: Testing: a process of executing software with the intent of finding errors Good testing: a high probability of finding as-yetundiscovered errors Successful testing: discovers previously unknown errors Formal view Testing is an experiment Hypothesis: there are no faults Independent variables: context and input Dependent variables: output of test Do the experiment: execute the model (program/system) Analysis: are the outputs those predicted by the theory (requirements / logical structure of program) 1

Basic Definitions Test case: specifies Inputs + pre-test state of the software Expected results (outputs + new-state) White-box testing: uses knowledge of the internal structure of the software E.g., write tests to cover internal paths Typically used for unit testing Black-box testing: ignores the internal logic of the software, and looks at what happens at the interface (e.g., given this input, was the produced output correct?) Typically used for system testing 2

Testing Phases Unit testing Initial testing on a developers component Integration testing Testing of incrementally composed components System testing Testing of a fully integrated system Typically two phases: system and stress testing Alpha testing Small set of friendly users live context use Beta testing Larger set of not necessarily friendly users live context use Regression testing Re-testing at unit, integration and system test levels to ensure evolution has not broken non-changed parts 3

Unit Testing Scope: one component from the design Often corresponds to the notion of compilation unit from the programming language Responsibility of the developer Not the job of an independent testing group Both white-box and black-box techniques are used for unit testing Maybe necessary to create stubs and drivers: If related modules are not yet implemented or not yet tested 4

Stubs It may be difficult to test a method or class that interacts with other methods or classes The replacement of a method that has not yet been implemented or tested is called a stub A stub has the same header as the method it replaces, but its body only displays a message indicating that the stub was called or it performs some other hard coded action that allows you to proceed. 5

Drivers A driver program (aka harness) declares any necessary object instances and variables, assigns values to any of the method s inputs, calls the method, and displays the values of any outputs returned by the method You can put a main method in a class to serve as the test driver for that class s methods 6

Basic Strategy for Unit Testing Evaluate the tests using white-box techniques (test adequacy criteria) How well did the tests cover statements, branches, paths, etc.? Many possible criteria; at the very least need 100% branch coverage Create more tests for the inadequacies: e.g., to increase coverage of nested loops Create black-box tests Based on the specification of the unit (as determined during design) E.g. method interface, + preconditions 7

Integration Testing Approach Integration testing: scope = set of interacting components 2 general strategies: top-down and bottom-up Focus: correctness of component interactions Mixture of black-box and white-box techniques Goals Ensure component expectations are met Interfaces used match Interfaces provided Eliminate unwanted component interactions Shared variables, race conditions, pointer problems, etc. Replace unit reality with integration reality Stubs at best model reality Infuse (change management + integration testing) Systematic management of multiple developers making changes to a system Add in integration testing for the recombination phase 8

System Testing Goal: find whether the system does what the customer expects to see Black-box techniques In the spec created during requirements analysis, there should be validation criteria How are the developers and the customers going to agree that the software is good enough? Many issues: functionality, performance, documentation, usability, portability, etc. 9

System Testing (cont) Initial part of system testing is done by the software producer Eventually, we need testing done by the customers (or surrogates) Every time a customer runs the software he/she is testing it Customers are good at doing unexpected things, which is great for testing If the software is built for a single customer: series of acceptance tests Deploy the software in the customer environment and have end-users run it 10

System Testing (cont) If the software is produced for multiple customers: two phases Alpha testing: conducted at the vendor s site by a few customers The vendor records any errors and usage problems Beta testing: the software is distributed to many end-users; they run it in their own environment and report problems Often done by thousands of users 11

Stress Testing Form of system testing: check the behavior of the system under very heavy load conditions E.g., what if we have data sets that are an order of magnitude larger than normal? Will we run out of memory? Will the OS start writing memory pages to disk (thrashing)? E.g., what if our server gets 10 times more client requests than usual? Will the system slow to a crawl? Denial of service attacks? 12

Stress Testing (cont) Goal: find how well the system can cope with defined load and overload Reason 1: determine failure behavior If load goes above the intended (which often is a possibility) how gracefully does the system fail? Reason 2: expose bugs that only occur under heavy loads Especially for system SW, middleware, servers, etc. E.g., memory leaks, incorrect resource allocation and scheduling, race conditions 13

Regression Testing Basic idea: rerun old tests to make sure that nothing was broken by a change Changes: bug fixes, module integration, maintenance enhancements, etc. To be able to do this regularly and efficiently, we need test automation tools Load tests, execute them, check correctness Everything has to be completely automatic Test case database is required Could happen at any time: during initial development or after deployment 14