package seedu.tasklist.testutil;

import seedu.tasklist.model.tag.UniqueTagList;
import seedu.tasklist.model.task.Comment;
import seedu.tasklist.model.task.Name;
import seedu.tasklist.model.task.Priority;
import seedu.tasklist.model.task.ReadOnlyTask;
import seedu.tasklist.model.task.Status;

/**
 * A mutable task object. For testing only.
 */
public class TestTask implements ReadOnlyTask {

    private Name name;
    private Comment comment;
    private Priority priority;
    private Status status;
    private UniqueTagList tags;

    public TestTask() {
        tags = new UniqueTagList();
    }

    /**
     * Creates a copy of {@code taskToCopy}.
     */
    public TestTask(TestTask taskToCopy) {
        this.name = taskToCopy.getName();
        this.comment = taskToCopy.getComment();
        this.priority = taskToCopy.getPriority();
        this.status = taskToCopy.getStatus();
        this.tags = taskToCopy.getTags();
    }

    public void setName(Name name) {
        this.name = name;
    }

    public void setComment(Comment comment) {
        this.comment = comment;
    }


    public void setTags(UniqueTagList tags) {
        this.tags = tags;
    }

    @Override
    public Name getName() {
        return name;
    }


    @Override
    public Comment getComment() {
        return comment;
    }

    @Override
    public UniqueTagList getTags() {
        return tags;
    }

    @Override
    public String toString() {
        return getAsText();
    }

    public String getAddCommand() {
        StringBuilder sb = new StringBuilder();
        sb.append("add " + this.getName().fullName + " ");
        sb.append("c/" + this.getComment().value + " ");
        this.getTags().asObservableList().stream().forEach(s -> sb.append("t/" + s.tagName + " "));
        return sb.toString();
    }

    @Override
    public Priority getPriority() {
        return priority;
    }

    @Override
    public Status getStatus() {
        return status;
    }
}

@@ -1391,32 +1391,194 @@
 turn tags;%0A    %7D
+%0A    %0A    @Override%0A    public Priority getPriority() %7B%0A        return priority;%0A    %7D%0A%0A    @Override%0A    public Status getStatus() %7B%0A        return status;%0A    %7D
 %0A%0A    @Override%0A
@@ -1972,32 +1972,33 @@
 tring();%0A    %7D%0A%0A
+%0A
     @Override%0A  
@@ -2010,32 +2010,233 @@
 lic 
-Priority getPriority() %7B
+String getAsText() %7B%0A        final StringBuilder builder = new StringBuilder();%0A        builder.append(getName())%0A                .append(%22 Comment: %22)%0A                .append(getComment())%0A                .append(%22 Tags: %22);
 %0A   
@@ -2240,39 +2240,93 @@
         
-return priority
+getTags().forEach(builder::append);%0A        return builder.toString()
 ;%0A    %7D%0A
 %0A    @Ov
@@ -2309,33 +2309,37 @@
 String();%0A    %7D%0A
+    
 %0A
-
     @Override%0A  
@@ -2351,50 +2351,334 @@
 lic 
-Status getStatus() %7B%0A        return status
+boolean isSameStateAs(ReadOnlyTask other) %7B%0A        return other == this // short circuit if same object%0A                %7C%7C (other != null // this is first to avoid NPE below%0A                && other.getName().equals(this.getName()) // state checks here onwards%0A                && other.getComment().equals(this.getComment()))
 ;%0A  

Update TestTask.java