Search code examples
automated-testsdatabase-testing

which s best way to test the database packages?


I am currently working on a project where we need to test the database packages and functions. We need to provide the input parameters to the database package and test the packages returns the expected value, also we want to test the response time of the request.

Please advice, if there is any tool available to perform this or we can write our test cases in Junit or some other framework. Which one will be best approach?


Solution

  • I've used a more native approach when I had to do DWH testing. I've arranged the Test framework around the Dev data integration framework that was already in place. So i had a lot of reusable jobs, configurations and code. But using OOP like you suggest

    write our test cases in Junit

    is a way to go too. But keep in mind that very often the DWH design is very complex (with a lot of aspects to consider) and interacting with the Persistence layer is not always the best candidate for testing strategy. A more DB oriented solution (like tSQLt) offers a significant performance.

    enter image description here

    Those resources helped me a lot: