-
-
Notifications
You must be signed in to change notification settings - Fork 55
Closed
Labels
Description
Do you want to request a feature or report a bug?
Bug
What is the current behavior?
Exception calling "Stop" with "0" argument(s): "Unable to cast object of type 'System.DBNull' to type 'System.String'."
How to reproduce:
run sqlcover against a database without database level triggers, it will succeed. Add 1 database trigger to the database and sqlcover will fail.
I took your script from the encryption error issue and found that Database Level Triggers do not have object_names pulled from the query you provided.
SELECT object_id, '[' + object_schema_name(object_id) + '].[' + object_name(object_id) + ']' as object_name, definition, uses_quoted_identifier from sys.sql_modules where object_id not in (select object_id from sys.objects where type = 'IF')
This is when using the covering other stuff scripts.
$coverage = new-object SQLCover.CodeCoverage($connectionString, $database, $true, $false)
$coverage.Start()
#do stuff here
$coverageResults = $coverage.Stop()
Reactions are currently unavailable