1 Reply Latest reply: Aug 9, 2011 4:35 PM by Pierluigi Vernetto RSS

    Automatic Test Cases

    877269
      Dears,

      I have a composite web service that call Data adapter .My problem is that i want to use automatic test cases for the data Adapter

      Suppose.

      Data adapter perform insert operation in database custID (unique Id)

      If I run test case once it works fine.

      At a later stage is development i want to run the same test case again it gives me error as CustId already exist in data base.

      I want to run test cases that does not perform commit operation to the database.

      Kindly help is this regard.

      Regards,
      Rizwan Ahmed Vohra
        • 1. Re: Automatic Test Cases
          Pierluigi Vernetto
          in the past I have used a wonderful tool called unitils, it includes also dbunit
          http://www.unitils.org/summary.html

          there is a learning curve but the documentation is good

          the idea is that each test should clean up the tables it uses before it is run

          I have never tried NOT committing the data in the DB during the tests, I am not sure if it is a good practice.