Software Testing Structural testing 1.

Slides:



Advertisements
Similar presentations
4.1 Triangles and Angles.
Advertisements

Triangles TOPIC 9 LESSON 9-5.
Overview Functional Testing Boundary Value Testing (BVT)
Warm-up: Find the missing side lengths and angle measures This triangle is an equilateral triangle 10 feet 25 feet This triangle is an isosceles triangle.
Software Testing and Quality Assurance
1 Software Testing and Quality Assurance Lecture 5 - Software Testing Techniques.
Warm Up 1. Find the perimeter of a rectangle with side lengths 12 ft and 20 ft. 3. Find the area of a parallelogram with height 9 in. and base length.
Warm-Up Given: AB has endpoints A (3, -4) and B (-1, -6) Find: Midpoint M and Distance.
Classifying Triangles Students will classify triangles using the lengths of the sides and the angles. S. Calahan October 2010.
Classify Triangles Standard 4C.
Software Testing (Part 2)
Types of 2 D Shapes and There Properties 1)A shape with 3 sides is called a triangle 2)A shape with 4 sides is called a quadrilateral 3)The general term.
1841f06detprob3 MM Stroustrup Ch26 u Comments? u Agree or disagree with his testing approach?
1 testing17 Software Testing Functional, MCC, Dataflow Testing, Cause-Effect Graphing.
1 Equivalence Class Testing Chapter 6. 2 Introduction Boundary Value Testing derives test cases with Massive redundancy Serious gaps Equivalence Class.
841f07frankl12oct21 Evaluating Testing Methods by Delivered Reliability Frankl, Hamlet, Littlewood, Strigini IEEE TOSE Aug98.
Software Testing. Software testing is the execution of software with test data from the problem domain. Software testing is the execution of software.
Lecture 2 Examples Pseudo code and flowcharts. Problem 1 Read a number as input and then print if it is even or odd.
BASIS PATH TESTING.
Triangle A polygon with three sides and three angles. A triangle can be names by its’ side lengths and angles. – Side lengths: isosceles, equilateral,
1841f07subdomains2Aug23 Question u What is the main purpose of software testing?
EXAMPLE 1 Standardized Test Practice SOLUTION Let ( x 1, y 1 ) = ( –3, 5) and ( x 2, y 2 ) = ( 4, – 1 ). = (4 – (–3)) 2 + (– 1 – 5) 2 = = 85 (
Lecture Notes - Copyright © S. C. Kothari, All rights reserved.1 Efficient Debugging CPRE 556 Lecture 19.
1 Input Space Partitioning(2). Reading Assignment P. Ammann and J. Offutt “Introduction to Software Testing” ◦ Chapter 4  Section 4.1  Section
Message: "You are mature"
TRIANGLES AND TYPES OF TRIANGLES. A triangle has three sides.
Types of Triangles. Equilateral Triangle All sides are the same length and all the angles are the same length.
Triangles 1st year P26 Chapter 4.
Types of Triangles. Angles The angles in a triangle add up to o + 60 o + 60 o =
Equivalence Class Testing In chapter 5, we saw that all four variations of boundary value testing are vulnerable to –gaps of untested functionality, and.
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 Software Testing. 2 Equivalence Class Testing 3 The use of equivalence class testing has two motivations: –Sense of complete testing –Avoid redundancy.
Equivalence Class Testing Use the mathematical concept of partitioning into equivalence classes to generate test cases for Functional (Black-box) testing.
1841f06detprob3 Testing Basics Detection probability.
Classifying Triangles. Two Ways to Classify Triangles  By Their Sides  By Their Angles.
Lesson 8.3 Concept: How to classify triangles by their sides and angles. An equilateral triangle has three sides of the same length. An isosceles triangle.
Learning Objective Identify triangles using their sides.
1841f06detprob4 Testing Basics Detection probability.
Mid Unit 5 Review 2-Dimensional Figures.
Triangles.
Software Testing Structural testing 540f07testing17oct25 1.
BASIS PATH TESTING.
Boundaries and C0,C1 Pressman pp
Mid Unit 5 Review 2-Dimensional Figures.
TRI NGLES 2 ways to classify: By Sides By Angles 60 4” 4” 4” 60 60
Angles In Triangles Types of Triangles Isosceles triangle
Overview Functional Testing Boundary Value Testing (BVT)
Detection probability
Identifying functions and using function notation
Triangles A polygon with 3 sides.
Applications of the Distance Formula
Angles In Triangles Types of Triangles Isosceles triangle
Classifying Triangles

Objective - To classify triangles.
Overview Functional Testing Boundary Value Testing (BVT)
Types of Triangles Thursday, 11 April 2019.
Types of Triangles Thursday, 11 April 2019.
The Triangle Inequality
Triangles.
Evaluating Testing Methods by Delivered Reliability
Front of Flipbook Right Triangles Acute Triangles Obtuse Triangles
Intro to Triangles.
5-7 Isosceles and Equilateral Triangles
Classifying Triangles
Classifying Triangles
Classifying Triangles
4-1 Classifying Triangles
Area and Perimeter Triangles.
Presentation transcript:

Software Testing Structural testing 1

Triangle Example cin >> a >> b >> c ; type = “scalene”; if (a == b || a == c || b == c) type= “isoscoles”; if (a == b && a == c) type = “equilateral”; if (a >= b+c || b >= a+c || c >= a+b) type=“not a triangle”; if (a <= 0 || b <= 0 || c <= 0) type=“bad input”; cout<< type;

Control Flow Graph TTYP1 – what are the paths through this code?

A Model of Testing - Mappings a program maps elements of the domain to elements of the range the specification also specifies a mapping of the domain to the range correctness is that the program is the same mapping as the specification 9

Domains in testing 12

Subdomain – typical definition A subdomain is a set of input points (data points, tests, etc) that are treated identically by the program (or almost identically). That is, they usually take the same path through the program and the same operations are applied to the values. Subdomains are normally mutually exclusive

TTYP 2 What is a set test cases for the “path” subdomains for the triangle code?

Typical Structural Coverage C0 – every statement C1 – every branch

Recommended use of C0 and C1 Select good test cases independent of coverage If Cx is not achieved, continue to select specific, but good test cases until Cx is achieved

The specification 13

Program vs Specification Correctness is only in respect to a specification a program without a specification is correct Testing can not ignore the specification Testing can not ignore the program 14

Boundary Testing A boundary test tries to establish that the boundary is in the correct spot. Thus, test cases are chosen on the boundary and as close as possible on the open side. “2-on, 1-off” means two on the boundary spread far apart and one just off the boundary in between the other two 17

Payroll Problem Wages must be greater than zero and less than 100 Hours must be greater than zero and less than 80 Time and a half is paid on hours over 40

Boundary Example - 2on/1off V I II

Triangle Domain

Boundaries in the triangle program Assume max length is 10 What would be 2-on, 1-off for the boundary between isosceles and not-a-triangle?

Exam on Tuesday, Oct 8th 1 cribsheet allowed Both sides, 8.5 by 11, handwritten C++ and SE