Exemple #1
0
 public Bug(string title, string description, PriorityType priorityType,
            BugSeverityType bugSeverityType, IMember assignee, ICollection <string> stepToReproduce)
     : base(title, description, priorityType, assignee)
 {
     this.PriorityType     = priorityType;
     this.SeverityType     = bugSeverityType;
     this.StatusType       = BugStatusType.Active;
     this.stepsToReproduce = new List <string>();
 }
Exemple #2
0
        public void ChangeSeverity(string newSeverity)
        {
            if (newSeverity == null)
            {
                throw new ArgumentNullException(ModelConstants.InvalidNullStatus);
            }

            else
            {
                BugSeverityType severityEnum = Enum.Parse <BugSeverityType>(newSeverity);
                this.SeverityType = severityEnum;
            }
        }
Exemple #3
0
        public void ChangeSeverity(string severity)
        {
            if (severity == null)
            {
                throw new ArgumentNullException("Severity cannot be null or empty!");
            }

            else
            {
                BugSeverityType severityEnum = (BugSeverityType)Enum.Parse(typeof(BugSeverityType), severity, true);
                this.Severity = severityEnum;
            }
        }
Exemple #4
0
        public Bug(string title, string description, IList <string> stepsToReproduce,
                   PriorityType priority, BugSeverityType severity, IBoard board, IPerson assignee = null)
            : base(title, description, priority, board, assignee)
        {
            if (stepsToReproduce == null)
            {
                throw new ArgumentNullException("Steps to reproduce cannot be null!");
            }

            if (!stepsToReproduce.Any())
            {
                throw new ArgumentException("There must be at least one step to reproduce for the bug!");
            }

            this.stepsToReproduce = stepsToReproduce;
            this.Severity         = severity;
            this.Status           = BugStatusType.Active;
        }
Exemple #5
0
 public void ChangeSeverity(BugSeverityType bugSeverityType)
 {
     this.SeverityType = bugSeverityType;
 }
 CreateBug(string title, string description, PriorityType priorityType,
           BugSeverityType bugSeverityType, IMember assignee, List <string> stepsToReproduce)
 {
     return(new Bug(title, description, priorityType, bugSeverityType, assignee, stepsToReproduce));
 }
 CreateBug(string title, string description, ICollection <string> stepsToReproduce, PriorityType priorityType,
           BugSeverityType bugSeverityType, BugStatusType bugStatusType, IMember assignee)
 {
     return(new Bug(title, description, stepsToReproduce, priorityType,
                    bugSeverityType, bugStatusType, assignee));
 }
Exemple #8
0
 public IBug CreateBug(string title, string description, IList <string> stepsToReproduce, PriorityType priority, BugSeverityType severity, IBoard board, IPerson assignee = null)
 {
     return(new Bug(title, description, stepsToReproduce, priority, severity, board));
 }