Testing in Extreme Programming

Slides:



Advertisements
Similar presentations
Extreme Programming Alexander Kanavin Lappeenranta University of Technology.
Advertisements

An Introduction to eXtreme Programming Michael L. Collard, Ph.D. Department of Computer Science Kent State University.
Computer Science 209 Testing With JUnit. Why Test? I don ’ t have time, I ’ ve got a deadline to meet The more pressure I feel, the fewer tests I will.
What is Unit Testing? How TDD Works? Tsvyatko Konov Telerik Corporation
A little Software Engineering: Agile Software Development C Sc 335 Rick Mercer.
ITEC 370 Lecture 25 Lifecycles. Review Questions? F give prototype demonstration –Testing plan for your software Life cycles –Scrum (Roles, Meetings,
Agile development By Sam Chamberlain. First a bit of history..
Approach of Unit testing with the help of JUnit Satish Mishra
XP – eXtreme Programming A gentle introduction. Cleviton Vinícius Jobson Ronan Thiago Rodrigues.
Agile Methods and Extreme Programming CSSE 376, Software Quality Assurance Rose-Hulman Institute of Technology March 23, 2007.
Extreme Programming: Practices and Strategies Extreme Programming Practices and Strategies Mohammad Alshayeb Information and Computer.
JUnit. What is unit testing? A unit is the smallest testable part of an application. A unit test automatically verifies the correctness of the unit. There.
Extreme Programming Team Members Gowri Devi Yalamanchi Sandhya Ravi.
JUnit. Why is testing good? Due to psychological factors, programmers are bad testers. A computer can test much faster than a human Philosophy: “If it.
24-Jun-15 JUnit. 2 Test suites Obviously you have to test your code to get it working in the first place You can do ad hoc testing (running whatever tests.
Extreme Programming Mark Steverson. What Is Extreme Programming? ● Extreme Programming (XP) is a lightweight, agile methodology developed by Kent Beck.
24-Jun-15 JUnit. 2 Test suites Obviously you have to test your code to get it working in the first place You can do ad hoc testing (running whatever tests.
Xtreme Programming. Software Life Cycle The activities that take place between the time software program is first conceived and the time it is finally.
Presentation Outline What is JUnit? Why Use JUnit? JUnit Features Design of JUnit Downloading JUnit Writing Tests – TestCase – TestSuite Organizing The.
George Blank University Lecturer. JUnit for Test Driven Development By Vivek Bhagat, George Blank.
©Ian Sommerville 2004Software Engineering, 7th edition. Chapter 17 Slide 1 Extreme Programming.
Test Driven Development TDD. Testing ”Testing can never demonstrate the absence of errors in software, only their presence” Edsger W. Dijkstra (but it.
Concordia University Department of Computer Science and Software Engineering Click to edit Master title style ADVANCED PROGRAMMING PRACTICES Unit Testing.
JUnit The framework. Goal of the presentation showing the design and construction of JUnit, a piece of software with proven value.
Lecture 6 Software Testing and jUnit CS140 Dick Steflik.
Chapter 3 – Agile Software Development 1Chapter 3 Agile software development.
EXtreme Programming: An Introduction Presentation by: Jon Banta.
T-unit: Tcl Unit Test Package Automated Unit Test Package For Tcl Procedures Final Presentation Joseph Boyle Loyola Marymount University.
Unit testing Unit testing TDD with JUnit. Unit Testing Unit testing with JUnit 2 Testing concepts Unit testing Testing tools JUnit Practical use of tools.
Extreme/Agile Programming Prabhaker Mateti. ACK These slides are collected from many authors along with a few of mine. Many thanks to all these authors.
Extreme Programming.
1 김 수 동 Dept. of Computer Science Soongsil University Tel Fax
Introduction to JUnit 3.8 SEG 3203 Winter ‘07 Prepared By Samia Niamatullah.
XP Overview Short Life cycle Risky / Dynamic Requirements Increase developer productivity.
December Using Software Development Methodology (SDM) in the Third Teaching Unit (laboratory) CS Teachers Conference Dr. Orit Hazzan & Yael Dubinsky.
Unit Testing with JUnit and Clover Based on material from: Daniel Amyot JUnit Web site.
A tool for test-driven development
AP-1 4. Agile Processes. AP-2 Agile Processes Focus on creating a working system Different attitude on measuring progress XP Scrum.
Extreme Programming Based on and
EMBEDDED REAL-TIME, INC. December 8, 2015 Java Unit Mark Mosher Rochester Java Users Group.
JUnit Don Braffitt Updated: 10-Jun-2011.
Extreme programming (XP) Variant of agile Takes commonsense practices to extreme levels © 2012 by Václav Rajlich1.
S Ramakrishnan1 Systems V & V, Quality and Standards Dr Sita Ramakrishnan School CSSE Monash University.
CSC 480 Software Engineering Extreme Programming.
Agenda: Overview of Agile testing Difference between Agile and traditional Methodology Agile Development Methodologies Extreme Programming Test Driven.
CS223: Software Engineering Lecture 18: The XP. Recap Introduction to Agile Methodology Customer centric approach Issues of Agile methodology Where to.
Extreme programming (XP) Advanced Software Engineering Dr Nuha El-Khalili.
1 Advanced Computer Programming Project Management: Basics Copyright © Texas Education Agency, 2013.
Software Development. The Software Life Cycle Encompasses all activities from initial analysis until obsolescence Analysis of problem or request Analysis.
Introduction to Unit Testing and JUnit David Rabinowitz.
SWE 434 SOFTWARE TESTING AND VALIDATION LAB2 – INTRODUCTION TO JUNIT 1 SWE 434 Lab.
Embedded Systems Software Engineering
Software Development.
Implementing Full-Stack Test Automation for Drupal 8
Don Braffitt Updated: 26-Mar-2013
Introduction to JUnit CS 4501 / 6501 Software Testing
Unit testing Java programs Using JUnit
Planning User stories are written.
Extreme Programming.
An Automated Testing Framework
Software Engineering 1, CS 355 Unit Testing with JUnit
What do you need to know about XP?
Test-first development
Testing and Test-Driven Development CSC 4700 Software Engineering
Introduction to JUnit CS 4501 / 6501 Software Testing
eXtreme Programming (XP) and eXtreme Modeling (XM)
Introduction to JUnit IT323 – Software Engineering II
Refactoring.
Extreme Programming.
JUnit Dwight Deugo Nesa Matic Portions of the notes for this lecture include excerpts from the Eclipse 3.0 and.
Presentation transcript:

Testing in Extreme Programming By Mong-Hang Vo CS 240 Software Project Master of Science in Computer Science San Jose State University December 03, 2003 Professor Badrul Sarwar

Agenda Testing in XP Overview JUnit Framework

Rules and Practices of XP Planning Designing Coding Code the unit tests first Testing

Coding The Unit Tests First Create one test to define some small aspect of the problem Then create the simplest code that will make that test pass Then create a second test Add to the code you just created to make this new test pass … Continue until there is nothing left to test.

Coding The Unit Tests First Give a better idea of what features need to be in a class Immediate feedback Easier and faster to create your code No need to create them after the code Save you a lot of time.

Testing in XP Unit Tests Acceptance Tests.

Testing in XP All code must have unit tests All code must pass unit tests before it can released When a bug is found tests are created Acceptance tests are run often and the score is published.

Unit Tests Majority of the testing in XP is unit testing Unit tests XP style Download a unit test framework to be able to create automated unit tests suites Test all classes in the system Create your tests first before coding Unit tests are released into the code repository along with the code they test.

Unit tests Enable Collective Code Ownership Enable refactoring.

Collective Code Ownership Everyone in the development team owns all the code When a change is required, any programmer can make the change at any time More reliable than putting a single person in charge of specific classes.

Refactoring Removing redundant and unused code Keep the design simple.

Acceptance Tests Created from user stories provided by the customers Are black box system tests Should be automated so it can be run often The implementation and running of acceptance tests can be done by the Software QA team.

Quality assurance (QA) An essential part of the XP process Can be done by a separate group Can be integrated into the development team XP requires development to have much closer relationship with QA

Unit Tests Framework Download JUnit Framework www. XProgramming.com http://www.junit.org Developed by Luckily Erich Gamma and Kent Beck The standard for unit testing in Java.

JUnit Framework A set of classes that allows you to easily create and run a set of unit tests. Run unit tests Command line mode JUnit GUI A test case is usually implemented as a subclass of junit.framework.TestCase

JUnit Framework The execution of a test method in JUnit follows the model: setUp(); test<method_name>(); tearDown(); Junit distinguishes errors from failures. Failures are anticipated by the assert methods. These methods compare actual result with expected results.

JUnit Framework If a test fails, execution of the current test method is aborted. A test case repeats the above model, using reflection to find all test methods. Test methods must be public, void, take no arguments, and have a name that starts with "test" (so that reflection can determine which methods to call).

JUnit Framework

JUnit Framework

JUnit Framework Automate unit testing of Java classes Test code should be documented with Javadocs. Easier to maintain well-documented test cases Is an easy-to-use framework.

References http://www.extremeprogramming.org Unit tests Samples in JUnit installation Unit Testing: Test Early, Test Often by Michael Olan Test first, code later: a guide to integrating JUnit into development process by Thomas Hammell and Robert Nettleton (sjlibray.org)

Thank You!