public void DsfPathDelete_UpdateForEachOutputs_MoreThan1Updates_DoesNothing() { //------------Setup for test-------------------------- var newGuid = Guid.NewGuid(); const string result = "[[CompanyName]]"; var act = new DsfPathDelete { InputPath = string.Concat(TestContext.TestRunDirectory, "\\", newGuid + "[[CompanyName]]2.txt"), Result = result }; var tuple1 = new Tuple<string, string>("Test", "Test"); var tuple2 = new Tuple<string, string>("Test2", "Test2"); //------------Execute Test--------------------------- act.UpdateForEachOutputs(new List<Tuple<string, string>> { tuple1, tuple2 }); //------------Assert Results------------------------- Assert.AreEqual(result, act.Result); }
public void DsfPathDelete_UpdateForEachOutputs_1Updates_UpdateResult() { //------------Setup for test-------------------------- var newGuid = Guid.NewGuid(); var inputPath = string.Concat(TestContext.TestRunDirectory, "\\", newGuid + "[[CompanyName]]2.txt"); var act = new DsfPathDelete { InputPath = inputPath, Result = "[[CompanyName]]" }; var tuple1 = new Tuple<string, string>("[[CompanyName]]", "Test"); //------------Execute Test--------------------------- act.UpdateForEachOutputs(new List<Tuple<string, string>> { tuple1 }); //------------Assert Results------------------------- Assert.AreEqual("Test", act.Result); }
public void DsfPathDelete_UpdateForEachOutputs_NullUpdates_DoesNothing() { //------------Setup for test-------------------------- var newGuid = Guid.NewGuid(); const string result = "[[CompanyName]]"; var act = new DsfPathDelete { InputPath = string.Concat(TestContext.TestRunDirectory, "\\", newGuid + "[[CompanyName]]2.txt"), Result = result }; act.UpdateForEachOutputs(null); //------------Assert Results------------------------- Assert.AreEqual(result, act.Result); }