コード例 #1
0
 public void CreateUploadDwonloadDirectory()
 {
     CleanupCreatedDirectoriesSafely();
     StepsExecutor.ExecuteSafely(() => Directory.Delete(GetDownloadPath(), true));
     StepsExecutor.ExecuteSafely(() => Directory.Delete(GetUploadPath(), true));
     CleanupCreatedDirectoriesSafely();
 }
コード例 #2
0
 public void AfterWebDriverSetupSetps()
 {
     if (Directory.Exists(appConfigMember.RootDownloadLocation))
     {
         StepsExecutor.ExecuteSafely(() => Directory.Delete(appConfigMember.RootDownloadLocation, true));
         StepsExecutor.ExecuteSafely(() => Directory.CreateDirectory(appConfigMember.RootDownloadLocation));
     }
     if (Directory.Exists(appConfigMember.RootUploadLocation))
     {
         StepsExecutor.ExecuteSafely(() => Directory.Delete(appConfigMember.RootUploadLocation, true));
         StepsExecutor.ExecuteSafely(() => Directory.CreateDirectory(appConfigMember.RootUploadLocation));
     }
 }
コード例 #3
0
 public void AfterWebDriverSetupSetps()
 {
     if (!Directory.Exists(appConfigMember.RootDownloadLocation))
     {
         StepsExecutor.ExecuteSafely(() => Directory.CreateDirectory(appConfigMember.RootDownloadLocation));
     }
     if (!Directory.Exists(appConfigMember.RootUploadLocation))
     {
         StepsExecutor.ExecuteSafely(() => Directory.CreateDirectory(appConfigMember.RootUploadLocation));
     }
     if (!Directory.Exists(appConfigMember.ChromeLogFileLocation))
     {
         StepsExecutor.ExecuteSafely(() => Directory.CreateDirectory(Path.GetDirectoryName(appConfigMember.ChromeLogFileLocation)));
     }
 }
コード例 #4
0
 protected void ExecuteSafely(Action steps)
 {
     StepsExecutor.ExecuteSafely(steps);
 }
コード例 #5
0
 public void CleanupCreatedDirectoriesSafely()
 {
     StepsExecutor.ExecuteSafely(() => Directory.CreateDirectory(GetDownloadPath()));
     StepsExecutor.ExecuteSafely(() => Directory.CreateDirectory(GetUploadPath()));
 }