 Introduction  This strategy designs tests that are independent of the implementation (code) of the software Black-Box Testing.

Slides:



Advertisements
Similar presentations
Testing and Inspecting to Ensure High Quality
Advertisements

2017/3/25 Test Case Upgrade from “Test Case-Training Material v1.4.ppt” of Testing basics Authors: NganVK Version: 1.4 Last Update: Dec-2005.
Software Testing Technique. Introduction Software Testing is the process of executing a program or system with the intent of finding errors. It involves.
Black Box Testing Sources: Code Complete, 2 nd Ed., Steve McConnell Software Engineering, 5 th Ed., Roger Pressman Testing Computer Software, 2 nd Ed.,
Chapter 1 Object-Oriented Concepts. A class consists of variables called fields together with functions called methods that act on those fields.
SOFTWARE TESTING. INTRODUCTION  Software Testing is the process of executing a program or system with the intent of finding errors.  It involves any.
-- Finishing Design Unit -- Intro to Glass Box Testing ECEN5543 / CSCI 5548 SW Eng of Standalone Programs University of Colorado, Boulder.
Annoucements  Next labs 9 and 10 are paired for everyone. So don’t miss the lab.  There is a review session for the quiz on Monday, November 4, at 8:00.
Blackbox Testing Fra: CS Fall Blackbox Testing AKA Specification-Based Uses functional requirements to derive test cases Assumes errors include.
1 CODE TESTING Principles and Alternatives. 2 Testing - Basics goal - find errors –focus is the source code (executable system) –test team wants to achieve.
Chapter 17 Software Testing Techniques
1 These courseware materials are to be used in conjunction with Software Engineering: A Practitioner’s Approach, 5/e and are provided with permission by.
Testing an individual module
Chapter 18 Testing Conventional Applications
CS4723 Software Validation and Quality Assurance Lecture 02 Overview of Software Testing.
1 Software Testing and Quality Assurance Lecture 5 - Software Testing Techniques.
Software Engineering Lecture 12 Software Testing Techniques 1.
1 Software Testing Techniques CIS 375 Bruce R. Maxim UM-Dearborn.
Equivalence Class Testing
Handouts Software Testing and Quality Assurance Theory and Practice Chapter 9 Functional Testing
Black Box Software Testing
Test Design Techniques
Software Testing Sudipto Ghosh CS 406 Fall 99 November 9, 1999.
Dr. Pedro Mejia Alvarez Software Testing Slide 1 Software Testing: Building Test Cases.
Dynamic Black-Box Testing Part 2
Software Testing (Part 2)
Introduction Telerik Software Academy Software Quality Assurance.
CMSC 345 Fall 2000 Unit Testing. The testing process.
Testing phases. Test data Inputs which have been devised to test the system Test cases Inputs to test the system and the predicted outputs from these.
CS4311 Spring 2011 Unit Testing Dr. Guoqiang Hu Department of Computer Science UTEP.
Black-Box Testing Techniques I Software Testing Lecture 4.
1 Phase Testing. \ 2 Overview of Implementation phase Create Class Skeletons Define Implementation Plan (+ determine subphases) Define Coding Standards.
CEN 5070 – Software V&V BOUNDARY TESTING © , Dr. E.L. Jones.
Software Testing The process of operating a system or component under specified conditions, observing and recording the results, and making an evaluation.
Requirements-based Test Generation for Functional Testing (© 2012 Professor W. Eric Wong, The University of Texas at Dallas) 1 W. Eric Wong Department.
Software Transition Testing Presented By: Varun Phanda
Agenda Introduction Overview of White-box testing Basis path testing
Black-Box Testing Techniques I
Black Box Testing Techniques Chapter 7. Black Box Testing Techniques Prepared by: Kris C. Calpotura, CoE, MSME, MIT  Introduction Introduction  Equivalence.
Black-box Testing.
1 Software Engineering: A Practitioner’s Approach, 6/e Chapter 14a: Software Testing Techniques Software Engineering: A Practitioner’s Approach, 6/e Chapter.
(1) Unit Testing and Test Planning CS2110: SW Development Methods These slides design for use in lab. They supplement more complete slides used in lecture.
Software Testing Input Space Partition Testing. 2 Input Space Coverage Four Structures for Modeling Software Graphs Logic Input Space Syntax Use cases.
Today’s Agenda  Reminder: HW #1 Due next class  Quick Review  Input Space Partitioning Software Testing and Maintenance 1.
CEN 5070 – Software V&V What is Software Testing © , Dr. E.L. Jones.
SOFTWARE TESTING. INTRODUCTION Testing forms the first step in determining the errors in a program. It is the major quality control measure used during.
Testing and inspecting to ensure high quality An extreme and easily understood kind of failure is an outright crash. However, any violation of requirements.
CEN Software V & V Unit Testing Concepts 2/2000Unit Test Concepts2 Purpose This module presents the basic concepts of black-box and white-box.
Theory and Practice of Software Testing
Software Quality Assurance and Testing Fazal Rehman Shamil.
1. Black Box Testing  Black box testing is also called functional testing  Black box testing ignores the internal mechanism of a system or component.
Theory and Practice of Software Testing Chapter 14 Presman Software Testing Tactics BLACK BOX TESTING.
1 © 2011 Professor W. Eric Wong, The University of Texas at Dallas Requirements-based Test Generation for Functional Testing W. Eric Wong Department of.
1 These courseware materials are to be used in conjunction with Software Engineering: A Practitioner’s Approach, 5/e and are provided with permission by.
Black Box Unit Testing What is black-box testing? Unit (code, module) seen as a black box No access to the internal or logical structure Determine.
Chapter 1 The Phases of Software Development. Software Development Phases ● Specification of the task ● Design of a solution ● Implementation of solution.
SOFTWARE TESTING LECTURE 9. OBSERVATIONS ABOUT TESTING “ Testing is the process of executing a program with the intention of finding errors. ” – Myers.
Testing It is much better to have a plan when testing your programs than it is to just randomly try values in a haphazard fashion. Testing Strategies:
1 Software Testing. 2 What is Software Testing ? Testing is a verification and validation activity that is performed by executing program code.
Software Testing.
Black Box Testing PPT Sources: Code Complete, 2nd Ed., Steve McConnell
Software Testing Techniques
Chapter 13 & 14 Software Testing Strategies and Techniques
Types of Testing Visit to more Learning Resources.
UNIT-4 BLACKBOX AND WHITEBOX TESTING
CIS 4932 Software Testing White-Box Testing
Test Case Test case Describes an input Description and an expected output Description. Test case ID Section 1: Before execution Section 2: After execution.
CEN Software V & V Unit Testing Concepts
CSE 1020:Software Development
UNIT-4 BLACKBOX AND WHITEBOX TESTING
Presentation transcript:

 Introduction  This strategy designs tests that are independent of the implementation (code) of the software Black-Box Testing

 Introduction  There are two types of black-box tests: 1)FT: Functional Test: tests cases derived from the functional specification of the software. 2)BT: Boundary Test: test cases derived from boundary conditions on input data (or arguments) Black-Box Testing

 Sample A Operation Specification Operation Name: ComputePay Precondition: N/A Narrative: Compute pay for an hourly employee, given the hours worked (Hrs), and hourly pay rate (Rate). Compute overtime at 1.5 times for hours in excess of 40.0.

 Sample A Decision Table Condition Condition c1: Hrs <= 40 Action a1: Pay = Hrs * Rate a2: Pay = Rate*(40+1.5(Hrs-40)) YN X X tc1 tc

 Sample A Test Cases (functional) CONCEPT: Functional test coverage is achieved by designing at least one test case for each column of the decision table. Each column represents a BEHAVIOR of the function. Mathematically, behavior corresponds to an equivalence class defined by the combination of conditions in that column. This combination of conditions forces the function to exhibit this behavior. The test case designed for a column tests the behavior corresponding to the column.

 Sample A Test Cases (functional) [continued] RULE: Design one test case FOR EACH COLUMN

 Sample A Test Script (later)

 Sample B Operation Specification *Enhancement to the specification of ComputePay given in Sample A Operation Name: GrossPay Precondition: 0 <= Hrs <= <= Rate <= 20 Narrative: Compute pay for an hourly employee, given the hours worked (Hrs), and hourly pay rate (Rate). Compute overtime at 1.5 times for hours in excess of Return -1 when Hrs or Rate are invalid.

 Sample B Decision Table Condition c1: Hrs <= 40 c3: Hrs <= 112 c4: Rate >= 5.15 c5: Rate <= Action a1: Pay = Hrs * Rate a2: Pay = 40*Rate + 1.5*(Hrs-40)*Rate a3: Pay = -1 tc1tc2tc3tc4tc5tc6tc7tc8 YNYNYNYN YYN----- YY-N---- YY--NN-- YY----NN X X XXXXXX tc1tc2tc3tc4tc5tc6tc7tc8

 Sample C Test Cases NOTE: Test cases (3-8) test the preconditions.

 Sample C Test Cases [continued] B4: Test Script (N/A)

 BOUNDARY VALUE TESTING INTRODUCTION CONCEPT: Most programming errors occur at or near the values that define the domain of variables that determine the function of a program. The "off-by-one" error is a common programming error. Boundary value testing is driven by the equalities/inequalities which appear in the condition part of the decision table.

 BOUNDARY VALUE TESTING GUIDELINE Suppose you had c: x <= a The boundary values are typically: {OUT, AT, IN}, where OUT means "just outside" the boundary; AT means on the boundary; IN means just inside. a-1a+1 INATOUT(hi) a

 BOUNDARY VALUE TESTING GUIDELINE [continued] The following test cases must be used: c: x <= a, use test cases: IN: x = a-1; AT: x = a; outHI: x = a+1 c: x >= a, use test cases: IN: x = a+1; AT: x = a; outLO: x = a-1

 BOUNDARY VALUE TESTING GUIDELINE [continued] c: x = a, use test cases: AT: x = a; OUTLO: x = a-1; OUTHI = a+1 Note: for equality, there is no IN, so treat "too small" as OUTLO and "too large" as OUTHI. c: x < a, use test cases: IN: x = a-1; outHI: x = a; Note: for strict inequality, there is no AT. c: x > a, use test cases: IN: x = a+1; outLO: x = a;

 BOUNDARY VALUE TESTING GUIDELINE [continued] General Rule for c: x <= a; AT = a IN = a-prec(a) outHI = a+prec(a) where prec(a) is the precision of a. for integers... prec(a) = 1 when 2 decimal places used... prec(a) = 0.01

 BOUNDARY VALUE TESTING BOUNDARY VALUES FOR GrossPay

 BOUNDARY VALUE TESTING BOUNDARY VALUE TEST CASES for GrossPay

 BOUNDARY VALUE TESTING OBSERVATIONS 1.Functional Testing MFT = Min # functional tests cases = #cols in decision table Functional tests augmented by boundary tests BC = 3 * (#condition rows) - (#strict inequalites) 3.Overall # required black box test cases based on decision table: TC= MFT + BC = #columns + 3 * (#condition rows) - (#strict inequality condition rows)

 BOUNDARY VALUE TESTING OBSERVATIONS For GrossPay: #cols = 8 #condition rows = 5 #strict inequalities = 0 TC = 8 + 3*5 = = 23 INSIGHT: Before thinking about cutting corners, suppose your company had 10,000 employees who were paid weekly. In two years, ComputePay is executed 10000*52*2=1,040,000 times, over a MILLION TIMES!! Is 23 test cases too much to make sure GrossPay works correctly??