Example #1
0
 public static void Run(string directory, string filename, bool compare_image_data, IMetadataInvariantValidator invariant, params IMetadataModificationValidator[] modifications)
 {
     if (modifications.Length == 0)
     {
         ImageTest test = new ImageTest()
         {
             ImageFileName         = filename,
             ImageDirectory        = directory,
             TempDirectory         = directory,
             CompareImageData      = compare_image_data,
             InvariantValidator    = invariant,
             ModificationValidator = null
         };
         test.TestImage();
     }
     else
     {
         foreach (var modification in modifications)
         {
             ImageTest test = new ImageTest()
             {
                 ImageFileName         = filename,
                 ImageDirectory        = directory,
                 TempDirectory         = directory,
                 CompareImageData      = compare_image_data,
                 InvariantValidator    = invariant,
                 ModificationValidator = modification
             };
             test.TestImage();
         }
     }
 }
Example #2
0
		public static void Run (string directory, string filename, bool compare_image_data, IMetadataInvariantValidator invariant, params IMetadataModificationValidator[] modifications)
		{
			if (modifications.Length == 0) {
				ImageTest test = new ImageTest () {
						ImageFileName = filename,
						ImageDirectory = directory,
						TempDirectory = directory,
						CompareImageData = compare_image_data,
						InvariantValidator = invariant,
						ModificationValidator = null
					};
					test.TestImage ();
			} else {
				foreach (var modification in modifications) {
					ImageTest test = new ImageTest () {
						ImageFileName = filename,
						ImageDirectory = directory,
						TempDirectory = directory,
						CompareImageData = compare_image_data,
						InvariantValidator = invariant,
						ModificationValidator = modification
					};
					test.TestImage ();
				}
			}
		}