Can You Write A Simple Class For JUnit Testing In 1 Minute

Can You Write A Simple Class For JUnit Testing In 1 Minute


  • 20 Jan, 2012

    You need to write a class with less than 10 lines. Here is a nice example provided in the article "Writing a JUnit Test in 5 minutes" by Kamal Mettananda with some minor changes:package com.parcelhouse.myproj;public class Calc { public int add(int a, int b) { // errorneous method return a+b+1; } public int multiply(int a, int b) { return a*b; }}

    Comments Received:
    Please give your suggestions and feedback:

2009-2016 downloadmela.com. All rights reserved.