JUnit test cases for method which may include call to other methods?

You should take a deep look for DBUnit in raltionship with Databases. And you should update to a newer release of JUnit 4.8.1 is the newest as far as I know.

But in newer release annotations are used. I don't know annotations,thats why I am trying with junit3.8. – Rashmi May 6 '10 at 9:20.

If you're writing unit tests, then unless you're testing the actual DB layer logic, you want to take the database out of the equation. Ideally you'll do this by replacing your db layer with mocks/stubs/fakes. If you really want to test your db layer, then take a look at dbUnit which can setup your database to a known state and clean up again afterwards.

If you're writing unit tests, then unless you're testing the actual DB layer logic, you want to take the database out of the equation. Ideally you'll do this by replacing your db layer with mocks/stubs/fakes.

I cant really gove you an answer,but what I can give you is a way to a solution, that is you have to find the anglde that you relate to or peaks your interest. A good paper is one that people get drawn into because it reaches them ln some way.As for me WW11 to me, I think of the holocaust and the effect it had on the survivors, their families and those who stood by and did nothing until it was too late.

Related Questions