/// <summary> /// Create a new Test Set in the project. /// </summary> /// <param name="name">Test Set name</param> /// <param name="suite">Parent Regression suite</param> /// <returns>Newly created test set</returns> public TestSet CreateTestSet(string name, RegressionSuite suite) { return(Instance.Create.TestSet(name, suite, this, null)); }
/// <summary> /// Create a new Test Set in the project. /// </summary> /// <param name="name">Test Set name</param> /// <param name="suite">Parent Regression suite</param> /// <param name="attributes">Additional attributes</param> /// <returns>Newly created test set</returns> public TestSet CreateTestSet(string name, RegressionSuite suite, IDictionary <string, object> attributes) { return(Instance.Create.TestSet(name, suite, this, attributes)); }
/// <summary> /// Create new Test Set /// </summary> /// <param name="name">Test Set name</param> /// <param name="suite">Parent RegressionSuite</param> /// <param name="project">Parent Project</param> /// <param name="attributes">Additional attributes that should be set in order to be able to save when there is validation</param> /// <returns>Newly created Test Set</returns> public TestSet TestSet(string name, RegressionSuite suite, Project project, IDictionary<string, object> attributes) { // TODO invent consistent solution, possibly remove ability to create Test Sets from project if(!suite.RegressionPlan.Project.Equals(project)) { throw new InvalidOperationException("Suite should belong to the project passed in parameters"); } var testSet = new TestSet(instance) { Name = name, RegressionSuite = suite, Project = project }; AddAttributes(testSet, attributes); testSet.Save(); return testSet; }
/// <summary> /// Create new Test Set /// </summary> /// <param name="name">Test Set name</param> /// <param name="suite">Parent RegressionSuite</param> /// <param name="project">Parent Project</param> /// <returns>Newly created Test Set</returns> public TestSet TestSet(string name, RegressionSuite suite, Project project) { return TestSet(name, suite, project, null); }
///<summary> /// Create a new Regression Suite with title and Regression Plan ///</summary> ///<param name="name">Title of the suite</param> ///<param name="regressionPlan">Regression Plan to assign</param> ///<param name="attributes">Additional attributes for initialization of Regression Suite.</param> ///<returns>Regression Suite</returns> public RegressionSuite RegressionSuite(string name, RegressionPlan regressionPlan, IDictionary<string, object> attributes) { var regressionSuite = new RegressionSuite(instance) { Name = name, RegressionPlan = regressionPlan }; AddAttributes(regressionSuite, attributes); regressionSuite.Save(); return regressionSuite; }