JUNIT TEST Case Sample for fresher
This is basic test case created using JUNIT. Which will give you basic understanding of Junit testcase . /** * */ package test; /** * @author PraveenKumar * */ public class JunitTest { public boolean validatePositivenonZero(int a, int b){ if(a > 0 && b > 0){ return false; } return true; } public int add(int a , int b){ return a+b; } public int multiply(int a, int b){ return a*b ; } public double add(double a, double b){ return a+b; } } /** * */ package com.junit.testcase.test; import static org.junit.Assert.*; import junit.framework.Assert; import org.junit.After; import org.junit.AfterClass; import org.junit.Before; import org.junit.Test; import test.JunitTest; /** * @author PraveenKumar * */ public class UnitTestCase { private int a; private int b; /** * @throws java.lang.Exception ...