Validate() 공개 메소드

public Validate ( ) : ErrorCollection
리턴 ErrorCollection
예제 #1
0
        public void naming_convention_is_empty_test()
        {
            AviSynthBatchSettings avsBatchSettings;
            IAviSynthValidationService validationService;

            //given an empty batch directory
            avsBatchSettings = new AviSynthBatchSettings() { AviSynthFilesOutputDirectoryPath = "C:\\temp", NamingConvention = string.Empty, NumberOfFiles = 1 };
            //when I validate
            validationService = new AviSynthValidationService(avsBatchSettings);
            ErrorCollection errors = validationService.Validate();
            //then error list contains error
            Assert.AreEqual(errors[0].Description, "Naming Convention is required");
        }
예제 #2
0
        public void batch_directory_is_invalid_directory_test()
        {
            AviSynthBatchSettings avsBatchSettings;
            IAviSynthValidationService validationService;

            //given an empty batch directory
            avsBatchSettings = new AviSynthBatchSettings() { AviSynthFilesOutputDirectoryPath = "BatchDirectory", NamingConvention = "NamingConvention", NumberOfFiles = 1 };
            //when I validate
            validationService = new AviSynthValidationService(avsBatchSettings);
            ErrorCollection errors = validationService.Validate();
            //then error list contains error
            Assert.AreEqual(errors[0].Description, "Batch Directory does not exist!");
        }