ose-net/yesql.net

Check if the collection passed as argument has null, empty string, or white-space characters

Closed this issue · 0 comments

LoadFromFiles and LoadFromDirectories does not throw any error when any element has a null value, empty string, or white-space characters:

var data = new YeSqlLoader().LoadFromFiles(new[] { "sample.sql", null, "", "    " });

Expected behavior

It should generate the following error:

Unhandled exception. System.ArgumentException: 'files' collection cannot contain elements with a null value, an empty string or consists only of white-space characters.

Template:

'{0}' collection cannot contain elements with a null value, an empty string or consists only of white-space characters.