public void respects_the_profile_flag() { var project = new Project { Name = "MyProject", Profile = "Regular"}; project.Save("myproject.xml"); ProjectLoader.Load("myproject.xml", null, "Phantom").Profile.ShouldEqual("Phantom"); }
public void respects_the_compile_target_flag() { var project = new Project { Name = "MyProject", CompileTarget = "debug" }; project.Save("myproject.xml"); ProjectLoader.Load("myproject.xml", "release", null).CompileTarget.ShouldEqual("release"); }
public void load_a_project_from_the_project_file_if_it_is_found() { var project = new Project { Name = "MyProject", Profile = "Regular", CompileTarget = "retail" }; project.Save("myproject.xml"); var input = new RunInput {Path = "myproject.xml"}; var loader = new ProjectFileLoader(new FubuCore.FileSystem()).Load(input.Path); loader.Name.ShouldEqual("MyProject"); loader.Profile.ShouldEqual("Regular"); loader.CompileTarget.ShouldEqual("retail"); }
public void delete_a_test_file() { var project = new Project { BinaryFolder = string.Empty, ProjectFolder = "", TestFolder = "" }; var test = new Test("test to be saved"); test.AddComment("some comment"); test.FileName = "Test001.xml"; project.Save(test); File.Exists("Test001.xml").ShouldBeTrue(); project.DeleteFile(test); File.Exists("Test001.xml").ShouldBeFalse(); }
public void SetUp() { var project = new Project { BinaryFolder = string.Empty, ProjectFolder = "", TestFolder = "" }; test = new Test("Test001"); test.AddComment("some comment"); project.Save(test); project.RenameTest(test, "New Name"); }
public void save_and_load_a_test() { var project = new Project { BinaryFolder = string.Empty, ProjectFolder = "", TestFolder = "" }; var test = new Test("test to be saved"); test.AddComment("some comment"); test.FileName = "Test001.xml"; project.Save(test); Test test2 = new TestReader().ReadFromFile(test.FileName); test2.Name.ShouldEqual(test.Name); test2.Parts.Count.ShouldEqual(1); test2.FileName.ShouldEqual("Test001.xml"); }