Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How do I perform automated unit testing in SSIS packages?

How can I unit test SSIS packages? I want to be able to create and maintain unit tests for various components such as the workflow tasks, data flow tasks, event handlers, etc.

Are there any existing techniques, frameworks, and/or tools that can be used?

like image 687
Ray Avatar asked Oct 22 '08 16:10

Ray


People also ask

How do you automate SSIS packages?

In SSMS, in Object Explorer, select the SSISDB database, select a folder, select a project, and then select a package. Right-click on the package and select Schedule. The New Schedule dialog box opens. On the General page of the New Schedule dialog box, provide a name and description for the new scheduled job.


3 Answers

ssisUnit

A unit testing framework for SQL Server Integration Services

like image 119
Ray Avatar answered Oct 09 '22 16:10

Ray


Nowadays, ssisUnit isn't up to date and exist modern unit testing framework for SQL Server Integration Services called SSISTester.

MSDN article

Nuget

like image 20
Ruslan Hamzatov Avatar answered Oct 09 '22 17:10

Ruslan Hamzatov


some testing practices I usually follow when testing SSIS packages.

I always test at package level (it usually does not make a lot of sense to me to test at a lower level than this.... )

I usually keep a testing data environment with pretty small data sets.

Also a testing configuration profile (config files) pointing to the testing data sets and any other different testing parameters.

Depending of the nature of the project sometimes I also keep some database backups used to be restored whenever we want to reset the environment initial status (or any other statuses in the ETL process).

All of these combined in a good set of testing scripts (python, powershell...) calling the packages via dtexec, it's a pretty useful recipe for me ;-)

like image 30
river0 Avatar answered Oct 09 '22 15:10

river0