Esempio n. 1
0
 public void BackupNow_FirstTime_CreatesValidRepositoryAndWorkingTree()
 {
     using (var scenario = new BackupScenario("BackupNow_NewFolder_CreatesNewRepository"))
     {
         scenario.BackupNow();
         scenario.AssertDirExistsInWorkingDirectory(".hg");
         scenario.AssertFileExistsInRepo("Test.lift");
         scenario.AssertFileExistsInRepo("Test.WeSayConfig");
         scenario.AssertFileExistsInRepo(Path.Combine("WritingSystems", "qaa-x-qaa.ldml"));
         scenario.AssertFileExistsInRepo(Path.Combine("WritingSystems", "en.ldml"));
         scenario.AssertFileExistsInWorkingDirectory("Test.lift");
         scenario.AssertFileExistsInWorkingDirectory("Test.WeSayConfig");
         scenario.AssertFileExistsInWorkingDirectory(Path.Combine("WritingSystems", "qaa-x-qaa.ldml"));
         scenario.AssertFileExistsInWorkingDirectory(Path.Combine("WritingSystems", "en.ldml"));
     }
 }
Esempio n. 2
0
 public void BackupNow_ExistingRepository_AddsNewFileToBackupDir()
 {
     // Test causes a crash in WrapShellCall.exe - is there an updated version?
     using (var scenario = new BackupScenario("BackupNow_ExistingRepository_AddsNewFileToBackupDir"))
     {
         scenario.BackupNow();
         scenario.MakeTestLiftFile("blah.lift");
         scenario.BackupNow();
         scenario.AssertFileExistsInWorkingDirectory("blah.lift");
         scenario.AssertFileExistsInRepo("blah.lift");
     }
 }
Esempio n. 3
0
		public void BackupNow_ExistingRepository_AddsNewFileToBackupDir()
		{
			// Test causes a crash in WrapShellCall.exe - is there an updated version?
			using (BackupScenario scenario = new BackupScenario("BackupNow_ExistingRepository_AddsNewFileToBackupDir"))
			{
				scenario.BackupNow();
				File.Create(Path.Combine(scenario.SourceProjectDir, "blah.foo")).Close();
				scenario.BackupNow();
				scenario.AssertFileExistsInWorkingDirectory("blah.foo");
				scenario.AssertFileExistsInRepo("blah.foo");
			}
		}
Esempio n. 4
0
		public void BackupNow_FirstTime_CreatesValidRepositoryAndWorkingTree()
		{
			using (BackupScenario scenario = new BackupScenario("BackupNow_NewFolder_CreatesNewRepository"))
			{
				scenario.BackupNow();
				scenario.AssertDirExistsInWorkingDirectory(".hg");
				scenario.AssertFileExistsInRepo("test.lift");
				scenario.AssertFileExistsInRepo("test.WeSayConfig");
				scenario.AssertFileExistsInRepo("WritingSystemPrefs.xml");
				scenario.AssertFileExistsInWorkingDirectory("test.lift");
				scenario.AssertFileExistsInWorkingDirectory("test.WeSayConfig");
				scenario.AssertFileExistsInWorkingDirectory("WritingSystemPrefs.xml");
			}
		}