Unit Testing Tomas Žvirgžda IFM-9/2.

Slides:



Advertisements
Similar presentations
Software Testing Technique. Introduction Software Testing is the process of executing a program or system with the intent of finding errors. It involves.
Advertisements

Software Testing. Quality is Hard to Pin Down Concise, clear definition is elusive Not easily quantifiable Many things to many people You'll know it when.
SOFTWARE TESTING. Software Testing Principles Types of software tests Test planning Test Development Test Execution and Reporting Test tools and Methods.
SOFTWARE TESTING. INTRODUCTION  Software Testing is the process of executing a program or system with the intent of finding errors.  It involves any.
Two Key ERP Principles Standardisation – Industry level – Firm level Centralisation – Cost saving – eg computing – Control over resources – Organisational.
Adaptive Processes Software Processes Adaptive Processes.
© Copyright Eliyahu Brutman Programming Techniques Course.
Software Testing. “Software and Cathedrals are much the same: First we build them, then we pray!!!” -Sam Redwine, Jr.
Software Testing Prasad G.
Software Testing Introduction. Agenda Software Testing Definition Software Testing Objectives Software Testing Strategies Software Test Classifications.
© 2006, Cognizant Technology Solutions. All Rights Reserved. The information contained herein is subject to change without notice. Automation – How to.
Business Register Guidelines for Small Developing Nations Proposal for Discussion Geoff Mead and Ron Mckenzie Statistics New Zealand
By for Test Driven Development: Industry practice and teaching tool Robert Vanderwall, Ph.D. 1 WISTPC-15.
©Ian Sommerville 2004Software Engineering, 7th edition. Chapter 23 Slide 1 Software testing.
Software Process Model
Software Construction. Implementation System Specification Requirements Analysis Architectural Design Detailed Design Coding & Debugging Unit Testing.
Test Organization and Management
Managing the development and purchase of information systems (Part 1)
© 2012 IBM Corporation Rational Insight | Back to Basis Series Chao Zhang Unit Testing.
ITEC224 Database Programming
Test Roles and Independence of Testing Telerik Software Academy Software Quality Assurance.
Higher Computing Software Development. Software Development Process There are 7 main stages involved in developing a new software program: Analysis Design.
1 A Survey of Unit Testing Practices Prof. Per Runeson – Lund University Per Beremark – SPIN-syd.
Software Testing The process of operating a system or component under specified conditions, observing and recording the results, and making an evaluation.
BTEC Unit 06 – Lesson 08 Principals of Software Design Mr C Johnston ICT Teacher

OBJECT ORIENTED SYSTEM ANALYSIS AND DESIGN. COURSE OUTLINE The world of the Information Systems Analyst Approaches to System Development The Analyst as.
Test Driven Development Arrange, Act, Assert… Awesome Jason Offutt Software Engineer Central Christian Church
Chapter SIX Implementation, Testing and Pragmatics Making it a reality.
Topics Covered Phase 1: Preliminary investigation Phase 1: Preliminary investigation Phase 2: Feasibility Study Phase 2: Feasibility Study Phase 3: System.
© UNT in partnership with TEA1 7 th Grade Career Exploration Module Career Focus: Computer Software Engineer Vocabulary.
Testing, Testing & Testing - By M.D.ACHARYA QA doesn't make software but makes it better.
Test automation analysis in System Testing for the Intelligent Packet Core Author: Mona Saxena Supervisor: Professor Jörg Ott Nokia Networks, Helsinki.
Deploy Interfaces POS | Expense | Payables MONDAY, NOVEMBER 9 TH, 2015 Presented by: Claudia Musick Implementation Consultant.
Chapter 1: Fundamental of Testing Systems Testing & Evaluation (MNN1063)
Software Engineering Saeed Akhtar The University of Lahore.
1 Software Testing Strategies: Approaches, Issues, Testing Tools.
1)History of water fall model. 2)Features of water fall model. 3)Phase of water fall model. 4)Brief description of phases. 5)Advantages. 6)Disadvantages.
Unit Testing by Jon Edgar. Structure of Presentation Structure What is Unit Testing? Worked Example Extreme Programming (XP) Implementation Limitation.
Test Driven Development Introduction Issued date: 8/29/2007 Author: Nguyen Phuc Hai.
Observing the Current System Benefits Can see how the system actually works in practice Can ask people to explain what they are doing – to gain a clear.
Stages in Research Process Formulate Problem Determine Research Design Determine Data Collection Method Design Data Collection Forms Design Sample & Collect.
SOFTWARE TESTING LECTURE 9. OBSERVATIONS ABOUT TESTING “ Testing is the process of executing a program with the intention of finding errors. ” – Myers.
Powerpoint Templates Page 1 Powerpoint Templates Unit Testing Ari Seppi
Software Testing History, Trends, Perspectives – a Brief Overview.
BUSINESS INFORMATION SYSTEMS
Test Roles and Independence of Testing
PREPARED BY G.VIJAYA KUMAR ASST.PROFESSOR
Software Engineering (CSI 321)
Software Testing.
Introduction to Visual Basic 2008 Programming
Software Engineering (CSI 321)
Object-oriented software testing
Introduction to Design Patterns
Quality Management Perfectqaservices.
System Development Life Cycle (SDLC)
Buy Skin Lightening Cream UK | Everything4you
Tools of Software Development
Introduction to Systems Analysis and Design
Verification and Validation Unit Testing
Higher-Level Testing and Integration Testing
Sharing the good, the bad, the ugly & What can we do about it?
Systems Analysis and Design
CS240: Advanced Programming Concepts
Software Reviews - Overview
Delivering Business Value Faster
TYPES OF TESTING.
Code vulnerabilities Vulnerabilities are mistakes, errors or weaknesses in a piece of software’s source code that can be directly used by a hacker to perform.
Integration Testing.
A Development-Testing-Maintenance model for software evolution
Presentation transcript:

Unit Testing Tomas Žvirgžda IFM-9/2

Agenda What is Unit Testing? Benefits? What should it cover? Who should do it? Tomasa Žvirgžda

Agenda What are benefits of automated unit testing? Test-driven development and Unit testing. Boundary between unit test and integration test. Containing boundary between unit and integration test. Tomasa Žvirgžda

What is Unit Testing? “The software literature (notably the military standards) define a unit along the lines of the smallest collection of code which can be [usefully] tested”. “Unit testing is a method by which individual units of source code are tested to determine if they are fit for use“. Tomasa Žvirgžda

Benefits? It's not good for time and resources consumption: Maintenance (time and resources) Time spend to write test cases It's good for errors finding and QA: More errors are found at this stage then others Better QA Tomasa Žvirgžda

What should it cover? Test plan: Implementation Test process Test strategy Responsibilities Standards, tools... Implementation Tomasa Žvirgžda

Who should do it? “Because unit testing is primarily focussed on the implementation, and requires an understanding of the design intent, it is much more efficiently done by the designers rather then by independent testers” Tomasa Žvirgžda

What are benefits of automated unit testing? Saves time and resources: No need to write same test case again Faster testing process Easier maintenance Other benefits Tomasa Žvirgžda

Test-driven development and Unit testing. When software is developed using a test-driven approach, the unit test may take the place of formal design. Each unit test can be seen as a design element specifying classes, methods, and observable behavior. Tomasa Žvirgžda

Boundary between unit test and integration test. A unit test should usually not go outside of its own class boundary: No database activity No network activity No other activity Other vise, it's an integration test. Tomasa Žvirgžda

Containing boundary between unit and integration test. You will not cross a boundary between unit and integration test if you use “fakes” and “mock” objects. “fakes” or “mock” objects mimics a state of the object which is accessing database, network and etc. You can prepare a substituting object with any state you want. Tomasa Žvirgžda

Summary Unit testing is a method by which individual units of source code are tested to determine if they are fit for use. Unit testing is much more efficiently done by the designers rather then by independent testers. Automated unit testing saves time and resources. Use “fakes” and “mock” objects to contain boundary between unit and integration testing. Tomasa Žvirgžda

Questions What is unit testing? Can unit testing by applied to bottom-up testing approach? What are benefits of unit testing? What drawbacks you can see in unit testing? How can you save time and resources applying unit testing? Tomasa Žvirgžda