Introduction to Testing UC Santa Cruz CMPS 171 – Game Design Studio II 8 February 2011.

Slides:



Advertisements
Similar presentations
Testing Relational Database
Advertisements

Extreme Programming Alexander Kanavin Lappeenranta University of Technology.
Testing and Quality Assurance
Learning from Postmortems (slides adapted from Michael Mateas) UC Santa Cruz CMPS 171 – Game Design Studio II
Copyright © 2006 Software Quality Research Laboratory DANSE Software Quality Assurance Tom Swain Software Quality Research Laboratory University of Tennessee.
Software Testing and Quality Assurance
Software Testing and Quality Assurance
Introduction to UML (slides adapted from Michael Mateas)
Equivalence Class Testing, Decision Table Testing
SE 555 Software Requirements & Specification Requirements Validation.
Copyright by Scott GrissomCh 1 Software Development Slide 1 Software Development The process of developing large software projects Different Approaches.
CS4723 Software Validation and Quality Assurance Lecture 02 Overview of Software Testing.
The Software Product Life Cycle. Views of the Software Product Life Cycle  Management  Software engineering  Engineering design  Architectural design.
Testing - an Overview September 10, What is it, Why do it? Testing is a set of activities aimed at validating that an attribute or capability.
Requirements Engineering Process – 1
Equivalence Class Testing
Black Box Software Testing
1 Functional Testing Motivation Example Basic Methods Timing: 30 minutes.
What is Business Analysis Planning & Monitoring?
System/Software Testing
SOFTWARE TESTING STRATEGIES CIS518001VA : ADVANCED SOFTWARE ENGINEERING TERM PAPER.
Test plans CSCI102 - Systems ITCS905 - Systems MCS Systems.
CPIS 357 Software Quality & Testing
CMSC 345 Fall 2000 Unit Testing. The testing process.
1 REQUIREMENT ENGINEERING Chapter 7. 2 REQUIREMENT ENGINEERING Definition Establishing what the customer requires from a software system. OR It helps.
Lecture 11 Testing and Debugging SFDV Principles of Information Systems.
Testing -- Part II. Testing The role of testing is to: w Locate errors that can then be fixed to produce a more reliable product w Design tests that systematically.
CSE403 Software Engineering Autumn 2001 More Testing Gary Kimura Lecture #10 October 22, 2001.
Unit Testing 101 Black Box v. White Box. Definition of V&V Verification - is the product correct Validation - is it the correct product.
1 Introduction to Software Engineering Lecture 1.
7 Systems Analysis and Design in a Changing World, Fifth Edition.
Software Testing and Quality Assurance Software Quality Assurance 1.
Today’s Agenda  Reminder: HW #1 Due next class  Quick Review  Input Space Partitioning Software Testing and Maintenance 1.
Requirements Management with Use Cases Module 10: Requirements Across the Product Lifecycle Requirements Management with Use Cases Module 10: Requirements.
The Software Development Process
Chapter 8 Lecture 1 Software Testing. Program testing Testing is intended to show that a program does what it is intended to do and to discover program.
Requirements Validation
CPSC 873 John D. McGregor Session 9 Testing Vocabulary.
Testing and inspecting to ensure high quality An extreme and easily understood kind of failure is an outright crash. However, any violation of requirements.
Rational Unified Process Fundamentals Module 4: Core Workflows II - Concepts Rational Unified Process Fundamentals Module 4: Core Workflows II - Concepts.
Requirement engineering & Requirement tasks/Management. 1Prepared By:Jay A.Dave.
Dynamic Testing.
1 The Software Development Process ► Systems analysis ► Systems design ► Implementation ► Testing ► Documentation ► Evaluation ► Maintenance.
HNDIT23082 Lecture 09:Software Testing. Validations and Verification Validation and verification ( V & V ) is the name given to the checking and analysis.
Software Development Process CS 360 Lecture 3. Software Process The software process is a structured set of activities required to develop a software.
1 Phase Testing. Janice Regan, For each group of units Overview of Implementation phase Create Class Skeletons Define Implementation Plan (+ determine.
Testing Overview Software Reliability Techniques Testing Concepts CEN 4010 Class 24 – 11/17.
Equivalence Class Testing, Decision Table Testing UC Santa Cruz CMPS 171 – Game Design Studio II courses.soe.ucsc.edu/courses/cmps171/Winter12/01
Copyright 2015, Robert W. Hasker. Classic Model Gathering Requirements Specification Scenarios Sequences Design Architecture Class, state models Implementation.
Introduction to Testing UC Santa Cruz CMPS 171 – Game Design Studio II courses.soe.ucsc.edu/courses/cmps171/Winter12/01 14 February 2011.
1 Software Testing. 2 What is Software Testing ? Testing is a verification and validation activity that is performed by executing program code.
Chapter 2- Software Development Process  Product Components  Software Project Staff  Software Development Lifecycle Models.
Decision Tables. UC Santa Cruz CMPS 171 – Game Design Studio II courses.soe.ucsc.edu/courses/cmps171/Winter13/01 1 February 2013.
Functional testing, Equivalence class testing
SOFTWARE TESTING Date: 29-Dec-2016 By: Ram Karthick.
Software Testing.
John D. McGregor Session 9 Testing Vocabulary
Input Space Partition Testing CS 4501 / 6501 Software Testing
CS5123 Software Validation and Quality Assurance
John D. McGregor Session 9 Testing Vocabulary
Chapter 3: The Project Management Process Groups: A Case Study
Software Requirements analysis & specifications
Chapter 10 Verification and Validation of Simulation Models
John D. McGregor Session 9 Testing Vocabulary
Lecture 09:Software Testing
Static Testing Static testing refers to testing that takes place without Execution - examining and reviewing it. Dynamic Testing Dynamic testing is what.
Test Case Test case Describes an input Description and an expected output Description. Test case ID Section 1: Before execution Section 2: After execution.
Requirements Engineering Process – 1
Chapter 5 Understanding Requirements.
CSE 1020:Software Development
Presentation transcript:

Introduction to Testing UC Santa Cruz CMPS 171 – Game Design Studio II 8 February 2011

UC SANTA CRUZ Lab Update  Ongoing issues  Accounts on machines – Update from Melissa  Speakers for lab addition computers  Speakers ordered  C++ books, games (LBP 2), Xbox controller receiver  Request ordered  Apple developer license  Still investigating  Others?

UC SANTA CRUZ Upcoming deadlines  Thursday (Feb. 10) Web site skeleton  URL, design template, minimal content  Thursday (Feb. 10) Game playtesting plan  More details to come  Who will conduct tests and write playtest report? How will you recruit testers? Where will you conduct playtests? What specific gameplay issues do you want to focus on in first few weeks of playtesting?  Friday (Feb. 11): team status reporting  Due by midnight  Report on team activities this week  Be sure to use CS 171 team status reporting template  See  Scrum Masters use different template from rest of team  Friday (Feb. 11): updated Sprint burndown charts  Ideally these are updated daily, so they’re useful for your team  Thursday (Feb. 17): end of Sprint 2  9 days left in this sprint

UC SANTA CRUZ Software Engineering: Model-based collaboration  Over a software project, software engineers collaborate to create a series of models that describe the system’s behavior  capture system goals and behavior in models  creation of shared meaning around these models  Constant task: elimination of error and ambiguity within the models Stakeholders/ Users/Customers Software Engineers Models R equirements Use cases, scenarios, requirements statements R equirements Engineer Stakeholders Software Architecture Feature model, arch. diagrams, tradeoff analyses, arch. document System Architect Design UML, design documents Developer Code Unit Test Inspection Source code, test code, build scripts, test harness Bug reporting, tracking, & fixing Bug reports, code patches Users Customers Project management Collaboration Goals - Develop shared mental model of system - Negotiate scope and capabilities - Elicit requirements from stakeholders - Drive convergence to single architecture - Negotiate modular decomposition - Reduce dependencies among org. units - Resolve inconsistencies - Negotiate interfaces and use protocols - Record design rationale - Negotiate dependencies among classes and methods - Identify and eliminate bugs - Resolve edit conflicts - Identify and confirm bugs - Verify and apply code patches - Identify new feature requests

UC SANTA CRUZ Ways of removing software errors  Inspection  Engineers examine a model, looking for errors  Use their expertise to evaluate model for correctness  Example: software inspections, requirements inspections, heuristic walkthrough of user interfaces  Refinement  Engineers take a given model and produce another model from it  Process of making new models exposes missing information and assumptions in base models  Examples: formal specifications, pseudocode, UML  Simulation  Make a model executable, then verify its behavior meets expectations  Example: executable Statecharts  Rewriting  Take an existing model and rewrite it at the same level of abstraction, hopefully simplifying the model and thereby removing error  Example: code refactoring  Testing  Provide specific inputs to an executable model, and then verify the outputs are correct (with respect to a specification of correct behavior, or oracle)  Example: software testing  Analysis  A piece of analysis software examines an executable model of a system (source code) for errors  Example: static source code analysis (Findbugs), verifying XML against a DTD

UC SANTA CRUZ Software Testing  Software testing has two primary goals:  Descriptive  Provide an evaluation of the quality or acceptability of a software system  “Is the program acceptable to the customer?”  “Is the program ready to be released?”  Perfective  Reveal problems in a software system, so they can be fixed Flickr: DaveBleasdale

UC SANTA CRUZ Testing Scope  Software can be tested at varying sizes  Unit test  Testing a small number of methods/functions (often 1)  Testing new code before check-in  Object test  Testing all of the methods of an object’s implementation  Usually focuses on one object, but may include other objects (e.g., an object whose role depends on working with other object, such as the strategy pattern).  Integration test  Testing how a collection of objects or collection of methods/functions work together.  Focus is on ensuring that bugs are not introduced by interactions among the behavior of constituent parts  System test  Testing an entire software system as a whole

UC SANTA CRUZ Functional vs Structural Testing  There are two fundamental approaches to testing software  Functional (Black Box)  No detailed knowledge of internal implementation  Treats system as function mapping inputs to outputs  Structural (White Box or Clear Box)  Can use detailed knowledge of internal implementation detail  Can “see” inside the implementation Flickr: rileyporter Flickr: cjkershner

UC SANTA CRUZ Distinguishing Functional vs Structural Functional (Black Box) Structural (White Box) SpecificationProgram SpecificationProgram Test Cases (Functional Method 1)Test Cases (Functional Method 1I) Test Cases (Structural Method 1)Test Cases (Structural Method 1I)

UC SANTA CRUZ Testing Exercise  Triangle problem  A program reads three integer values from the console. The three values are interpreted as representing the lengths of the sides of a triangle. The program prints a message that states whether the triangle is scalene, isosceles, or equilateral.  Write a set of test cases (inputs to the method) that would adequately test this method.  Recall:  Equilateral triangle:  Three equal sides, three equal angles (all 60 degrees)  Isosceles triangle:  Two equal sides, two equal angles  Scalene triangle:  No equal sides, no equal angles

UC SANTA CRUZ Test cases (from the class)  6,6,6 – for testing equilateral  0,0,0 – equal numbers, but not a valid triangle  2,3,4 – testing scalene triangle  -1,1,1 – negative numbers  2,3,6 – not a valid triangle  Maxint, maxint, maxint – test integer boundaries  5, 5, 9 – isoceles  1, 0, 0 – not valid, test zero detection for isoceles  9, 5, 5, - test ordering of inputs for detect isoceles  2, 2, 8 – Two sides same length, but not valid triangle  5, 9, 5 – iteration on 5, 9, 5  Iterations of negative numbers (1, -1, 1), (1, 1, -1)  Real numbers as inputs (2.5, etc.)  1, 2, 3 – not a valid triangle, boundary value where first two sides equal the third  one, two, three (strings)  A, B, C (and –A, -B, -C)  -e  5, 2 (not enough inputs) and 1,2,3,4,5 (too many inputs)  -2, 2, 2 – even numbers with negatives  5, 5, 2 (acute isoceles)  Observation: shows examples of boundary value and equivalence class testing

UC SANTA CRUZ Did you miss these?  Some values specify an invalid triangle  Examples; 1, 2, 3 or 1, 2, 4 are not valid triangles  Even if the angle between the first two sides is 180 degrees, the third side is still too long!  Did you give as test cases:  Non-integers?  Non-numeric values?  Negative numbers?  Note how some of the values are given by your knowledge of the domain (triangles), and others based on knowledge of the range of possible inputs

UC SANTA CRUZ Types of Functional Tests  Boundary Value Testing  Test values just before, on, and after some input boundary  E.g., -1, 0, 1  Equivalence Class Testing  Provide representative samples within a large space of similar (“equivalent”) tests  Decision-Table Testing  Create a table that lists all possible outcomes for a set of inputs  Use this table to drive test case selection

UC SANTA CRUZ Boundary Value Testing  Core idea: provide inputs just before, on, and just after some inflection in the input space  Intuition: errors occur at extremes of input space  Example:  Determining if a point is in a range Provide test inputs at: min, min+, nominal, max-, and max minmin+nommax-max

UC SANTA CRUZ Variations on Boundary Value Testing  Robustness testing  Add min- and max+ to values tested  Worst-case testing  When multiple variables might be experiencing extreme at the same time. Example: robust worst-case testing with two variables min- min+nommax-maxmin max+

UC SANTA CRUZ Triangle Problem (Revisited)  Let’s revisit the triangle problem, and determine the set of boundary value test cases  Set arbitrary upper bound on side length of 200  Lower bound of all ranges is 1 (are integers)  Focus only on valid inputs