public void Build4ProjectWith4Targets() { RequestDefinition p1 = CreateRequestDefinition("1.proj", new string[4] { "target1", "target2", "target3", "target4" }, null, 0); RequestDefinition p2 = CreateRequestDefinition("2.proj", new string[4] { "target1", "target2", "target3", "target4" }, null, 0); RequestDefinition p3 = CreateRequestDefinition("3.proj", new string[4] { "target1", "target2", "target3", "target4" }, null, 0); RequestDefinition p4 = CreateRequestDefinition("4.proj", new string[4] { "target1", "target2", "target3", "target4" }, null, 0); p1.SubmitBuildRequest(); p1.ValidateBuildResult(); p2.SubmitBuildRequest(); p2.ValidateBuildResult(); p3.SubmitBuildRequest(); p3.ValidateBuildResult(); p4.SubmitBuildRequest(); p4.ValidateBuildResult(); }
/// <summary> /// Send a build request for a project with 1 target and validate the results. The results validated are the events /// raised by the build request engine, the results that was generated by the mock request builder and the cache contents /// </summary> public void BuildOneProject() { RequestDefinition p1 = CreateNewRequest("1.proj"); p1.SubmitBuildRequest(); p1.ValidateBuildResult(); }
/// <summary> /// A new build request from the node for a project which was already previously built in that node but for a different global properties /// </summary> public void ReferenceAProjectAlreadyBuiltInTheNodeButWithDifferentGlobalProperties() { ProjectPropertyInstance prop1 = ProjectPropertyInstance.Create("prop1", "Value1"); ProjectPropertyInstance prop2 = ProjectPropertyInstance.Create("prop2", "Value2"); PropertyDictionary <ProjectPropertyInstance> group1 = new PropertyDictionary <ProjectPropertyInstance>(); group1.Set(prop1); PropertyDictionary <ProjectPropertyInstance> group2 = new PropertyDictionary <ProjectPropertyInstance>(); group2.Set(prop2); RequestDefinition p1 = CreateNewRequest("1.proj", "2.0", new string[1] { "t1" }, group1); RequestDefinition p2 = CreateNewRequest("2.proj"); RequestDefinition p3 = CreateNewRequest("1.proj", "2.0", new string[1] { "t1" }, group2); p2.AddChildDefinition(p3); p1.SubmitBuildRequest(); p1.ValidateBuildResult(); p2.SubmitBuildRequest(); p2.ValidateBuildResult(); }
public void Build1ProjectWith1Target() { RequestDefinition p1 = CreateRequestDefinition("1.proj", null, null, 0); p1.SubmitBuildRequest(); p1.ValidateBuildResult(); }
/// <summary> /// Submit 3 build request where first one has multiple references and last has multiple references. Some of the references are built with different global properties /// </summary> public void BuildMultipleProjectsWithReferencesAndDifferentGlobalProperties() { ProjectPropertyInstance prop1 = ProjectPropertyInstance.Create("prop1", "Value1"); ProjectPropertyInstance prop2 = ProjectPropertyInstance.Create("prop2", "Value2"); PropertyDictionary <ProjectPropertyInstance> group1 = new PropertyDictionary <ProjectPropertyInstance>(); group1.Set(prop1); PropertyDictionary <ProjectPropertyInstance> group2 = new PropertyDictionary <ProjectPropertyInstance>(); group2.Set(prop2); RequestDefinition p1 = CreateNewRequest("1.proj"); RequestDefinition p2 = CreateNewRequest("2.proj"); RequestDefinition p3 = CreateNewRequest("3.proj"); RequestDefinition p4 = CreateNewRequest("4.proj"); RequestDefinition p5 = CreateNewRequest("2.proj", group1); RequestDefinition p6 = CreateNewRequest("6.proj"); RequestDefinition p7 = CreateNewRequest("2.proj", group2); p1.AddChildDefinition(p4); p1.AddChildDefinition(p5); p3.AddChildDefinition(p6); p3.AddChildDefinition(p7); p1.SubmitBuildRequest(); p1.ValidateBuildResult(); p2.SubmitBuildRequest(); p2.ValidateBuildResult(); p3.SubmitBuildRequest(); p3.ValidateBuildResult(); }
public void Build1ProjectWith4Targets() { RequestDefinition p1 = CreateRequestDefinition("1.proj", new string[4] { "target1", "target2", "target3", "target4" }, null, 0); p1.SubmitBuildRequest(); p1.ValidateBuildResult(); }
/// <summary> /// Submit 1 build request which has a single reference /// </summary> public void BuildOneProjectWith1Reference() { RequestDefinition p1 = CreateNewRequest("1.proj"); RequestDefinition p2 = CreateNewRequest("2.proj"); p1.AddChildDefinition(p2); p1.SubmitBuildRequest(); p1.ValidateBuildResult(); }
/// <summary> /// Build the same project twice with different tools version /// </summary> public void BuildingTheSameProjectTwiceWithDifferentToolsVersion() { RequestDefinition p1 = CreateNewRequest("1.proj", "2.0"); RequestDefinition p2 = CreateNewRequest("1.proj", "3.5"); p1.SubmitBuildRequest(); p1.ValidateBuildResult(); p2.SubmitBuildRequest(); p2.ValidateBuildResult(); }
/// <summary> /// A new build request from the node of a project which was already previously built in that node /// </summary> public void ReferenceAProjectAlreadyBuiltInTheNode() { RequestDefinition p1 = CreateNewRequest("1.proj"); RequestDefinition p2 = CreateNewRequest("2.proj"); p2.AddChildDefinition(p1); p1.SubmitBuildRequest(); p1.ValidateBuildResult(); p2.SubmitBuildRequest(); p2.ValidateBuildResult(); }
/// <summary> /// Submit 1 build request which has 3 reference where 2 are the same /// UNDONE: This test will fail due to a bug where 3.proj is added 2 times in the unresolvedConfigurations list thus causing a hang /// </summary> public void BuildOneProjectWith3ReferenceWhere2AreTheSame() { RequestDefinition p1 = CreateNewRequest("1.proj"); RequestDefinition p2 = CreateNewRequest("2.proj"); RequestDefinition p3 = CreateNewRequest("3.proj"); RequestDefinition p4 = CreateNewRequest("3.proj"); p1.AddChildDefinition(p2); p1.AddChildDefinition(p3); p1.AddChildDefinition(p4); p1.SubmitBuildRequest(); p1.ValidateBuildResult(); }
/// <summary> /// Submit 3 build request where project 3 has a reference to Project 1 /// </summary> public void Build3ProjectsWhere3HasAReferenceTo1() { RequestDefinition p1 = CreateNewRequest("1.proj", "2.0"); RequestDefinition p2 = CreateNewRequest("2.proj", "2.0"); RequestDefinition p3 = CreateNewRequest("3.proj", "2.0"); p3.AddChildDefinition(p1); p1.SubmitBuildRequest(); p1.ValidateBuildResult(); p2.SubmitBuildRequest(); p2.ValidateBuildResult(); p3.SubmitBuildRequest(); p3.ValidateBuildResult(); }
/// <summary> /// A new build request from the node for a project which was already previously built in that node but for a different tools version /// </summary> public void ReferenceAProjectAlreadyBuiltInTheNodeButWithDifferentToolsVersion() { RequestDefinition p1 = CreateNewRequest("1.proj", "2.0", new string[1] { "t1" }, null); RequestDefinition p2 = CreateNewRequest("2.proj"); RequestDefinition p3 = CreateNewRequest("1.proj", "3.5", new string[1] { "t1" }, null); p2.AddChildDefinition(p3); p1.SubmitBuildRequest(); p1.ValidateBuildResult(); p2.SubmitBuildRequest(); p2.ValidateBuildResult(); }
/// <summary> /// Submit 3 build request where the last one has a project reference /// </summary> public void BuildMultipleProjectsWithTheLastProjectHavingReferenceToANewProject() { RequestDefinition p1 = CreateNewRequest("1.proj"); RequestDefinition p2 = CreateNewRequest("2.proj"); RequestDefinition p3 = CreateNewRequest("3.proj"); RequestDefinition p4 = CreateNewRequest("4.proj"); p3.AddChildDefinition(p4); p1.SubmitBuildRequest(); p1.ValidateBuildResult(); p2.SubmitBuildRequest(); p2.ValidateBuildResult(); p3.SubmitBuildRequest(); p3.ValidateBuildResult(); }
public void Build4ProjectWith1Target() { RequestDefinition p1 = CreateRequestDefinition("1.proj", null, null, 0); RequestDefinition p2 = CreateRequestDefinition("2.proj", null, null, 0); RequestDefinition p3 = CreateRequestDefinition("3.proj", null, null, 0); RequestDefinition p4 = CreateRequestDefinition("4.proj", null, null, 0); p1.SubmitBuildRequest(); p1.ValidateBuildResult(); p2.SubmitBuildRequest(); p2.ValidateBuildResult(); p3.SubmitBuildRequest(); p3.ValidateBuildResult(); p4.SubmitBuildRequest(); p4.ValidateBuildResult(); }
/// <summary> /// Sends multiple build request and validate the results /// </summary> public void Build4DifferentProjects() { RequestDefinition p1 = CreateNewRequest("1.proj"); RequestDefinition p2 = CreateNewRequest("2.proj"); RequestDefinition p3 = CreateNewRequest("3.proj"); RequestDefinition p4 = CreateNewRequest("4.proj"); p1.SubmitBuildRequest(); p1.ValidateBuildResult(); p2.SubmitBuildRequest(); p2.ValidateBuildResult(); p3.SubmitBuildRequest(); p3.ValidateBuildResult(); p4.SubmitBuildRequest(); p4.ValidateBuildResult(); }
/// <summary> /// Build the same project twice with different global properties /// </summary> public void BuildingTheSameProjectTwiceWithDifferentGlobalProperties() { ProjectPropertyInstance prop1 = ProjectPropertyInstance.Create("prop1", "Value1"); ProjectPropertyInstance prop2 = ProjectPropertyInstance.Create("prop2", "Value2"); PropertyDictionary <ProjectPropertyInstance> group1 = new PropertyDictionary <ProjectPropertyInstance>(); group1.Set(prop1); PropertyDictionary <ProjectPropertyInstance> group2 = new PropertyDictionary <ProjectPropertyInstance>(); group2.Set(prop2); RequestDefinition p1 = CreateNewRequest("1.proj", "2.0", null, group1); RequestDefinition p2 = CreateNewRequest("1.proj", "3.0", null, group2); p1.SubmitBuildRequest(); p1.ValidateBuildResult(); p2.SubmitBuildRequest(); p2.ValidateBuildResult(); }
/// <summary> /// Submit 3 build request where first one has multiple references /// </summary> public void BuildMultipleProjectsWhereFirstReferencesMultipleNewProjects() { RequestDefinition p1 = CreateNewRequest("1.proj"); RequestDefinition p2 = CreateNewRequest("2.proj"); RequestDefinition p3 = CreateNewRequest("3.proj"); RequestDefinition p4 = CreateNewRequest("4.proj"); RequestDefinition p5 = CreateNewRequest("5.proj"); RequestDefinition p6 = CreateNewRequest("6.proj"); p1.AddChildDefinition(p4); p1.AddChildDefinition(p5); p1.AddChildDefinition(p6); p1.SubmitBuildRequest(); p1.ValidateBuildResult(); p2.SubmitBuildRequest(); p2.ValidateBuildResult(); p3.SubmitBuildRequest(); p3.ValidateBuildResult(); }
/// <summary> /// Submit 3 build request where first one has multiple references and last has multiple references. Some of the references are already built /// </summary> public void BuildMultipleProjectsWithReferencesWhereSomeReferencesAreAlreadyBuilt() { RequestDefinition p1 = CreateNewRequest("1.proj"); RequestDefinition p2 = CreateNewRequest("2.proj"); RequestDefinition p3 = CreateNewRequest("3.proj"); RequestDefinition p4 = CreateNewRequest("4.proj"); RequestDefinition p5 = CreateNewRequest("2.proj"); RequestDefinition p6 = CreateNewRequest("6.proj"); RequestDefinition p7 = CreateNewRequest("2.proj"); p1.AddChildDefinition(p4); p1.AddChildDefinition(p5); p3.AddChildDefinition(p6); p3.AddChildDefinition(p7); p1.SubmitBuildRequest(); p1.ValidateBuildResult(); p2.SubmitBuildRequest(); p2.ValidateBuildResult(); p3.SubmitBuildRequest(); p3.ValidateBuildResult(); }
/// <summary> /// Submit 3 build request where first one has multiple references and last has multiple references. Some of the references are built with different tools version /// </summary> public void BuildMultipleProjectsWithReferencesAndDifferentToolsVersion() { RequestDefinition p1 = CreateNewRequest("1.proj", "2.0"); RequestDefinition p2 = CreateNewRequest("2.proj", "2.0"); RequestDefinition p3 = CreateNewRequest("3.proj", "2.0"); RequestDefinition p4 = CreateNewRequest("4.proj", "2.0"); RequestDefinition p5 = CreateNewRequest("2.proj", "3.5"); RequestDefinition p6 = CreateNewRequest("6.proj", "2.0"); RequestDefinition p7 = CreateNewRequest("3.proj", "3.5"); p1.AddChildDefinition(p4); p1.AddChildDefinition(p5); p3.AddChildDefinition(p6); p3.AddChildDefinition(p7); p1.SubmitBuildRequest(); p1.ValidateBuildResult(); p2.SubmitBuildRequest(); p2.ValidateBuildResult(); p3.SubmitBuildRequest(); p3.ValidateBuildResult(); }