Introduces scanner class to read in input
+ and sorts input into appropriate parsing commands
+
+// * @exception Exception if unchecked exceptions appear, not ideally
Introduces scanner class to read in input
+ and sorts input into appropriate parsing commands
+
+// * @exception Exception if unchecked exceptions appear, not ideally
+
+
+
+
diff --git a/src/test/java/DeadlineTest.java b/src/test/java/DeadlineTest.java
new file mode 100644
index 0000000000..c27c66f1cd
--- /dev/null
+++ b/src/test/java/DeadlineTest.java
@@ -0,0 +1,23 @@
+import static org.junit.jupiter.api.Assertions.assertEquals;
+
+import java.time.LocalDate;
+
+import org.junit.jupiter.api.Test;
+
+import duke.Deadline;
+
+public class DeadlineTest {
+ @Test
+ public void toStringTest() {
+ LocalDate parseDate = LocalDate.parse("2021-01-11");
+ Deadline deadline = new Deadline("test", parseDate);
+ assertEquals(deadline.toString(), "[D] [ ] test | by: 11 Jan 2021");
+ }
+
+ @Test
+ public void getTimeTest() {
+ LocalDate parseDate = LocalDate.parse("2021-01-11");
+ Deadline deadline = new Deadline("test", parseDate);
+ assertEquals(deadline.getTime(), parseDate);
+ }
+}
diff --git a/src/test/java/DukeTest.java b/src/test/java/DukeTest.java
new file mode 100644
index 0000000000..2408d7d029
--- /dev/null
+++ b/src/test/java/DukeTest.java
@@ -0,0 +1,10 @@
+import static org.junit.jupiter.api.Assertions.assertEquals;
+
+import org.junit.jupiter.api.Test;
+
+public class DukeTest {
+ @Test
+ public void dummyTest() {
+ assertEquals(2, 2);
+ }
+}
diff --git a/text-ui-test/EXPECTED.TXT b/text-ui-test/EXPECTED.TXT
index 657e74f6e7..e89f6589f5 100644
--- a/text-ui-test/EXPECTED.TXT
+++ b/text-ui-test/EXPECTED.TXT
@@ -1,7 +1,87 @@
-Hello from
- ____ _
-| _ \ _ _| | _____
-| | | | | | | |/ / _ \
-| |_| | |_| | < __/
-|____/ \__,_|_|\_\___|
+Greetings from
+░▄▀▄▀▀▀▀▄▀▄░░░░░░░░░
+░█░░░░░░░░▀▄░░░░░░▄░
+█░░▀░░▀░░░░░▀▄▄░░█░█
+█░▄░█▀░▄░░░░░░░▀▀░░█
+█░░▀▀▀▀░░░░░░░░░░░░█
+█░░░░░░░░░░░░░░░░░░█
+█░░░░░░░░░░░░░░░░░░█
+░█░░▄▄░░▄▄▄▄░░▄▄░░█░
+░█░▄▀█░▄▀░░█░▄▀█░▄▀░
+░░▀░░░▀░░░░░▀░░░▀░░░
+
+____________________________________________________________
+Woof! I'm Doge Duke
+What do you want me to do?
+Type your request in below!
+
+____________________________________________________________
+
+duke.DukeException: Whoops :( I'm sorry, I'm not sure what that means. Did you forget to add a command type?
+
+____________________________________________________________
+Mlem I've added a new command for you to do:
+[T] [ ] rollover
+Now I can do a total of 1 commands!
+____________________________________________________________
+
+This date doesnt exist! The right format should be in yyyy-mm-dd.
+
+____________________________________________________________
+Much wow! I've added a new command with an Event:
+[E] [ ] dog festival | at: 10 Feb 2021
+Now I can do a total of 2 commands!
+____________________________________________________________
+
+
+____________________________________________________________
+Woofers! I've added a new command with a Ded-line:
+[D] [ ] finish doggo treats | by: 11 Mar 2021
+Now I can do a total of 3 commands!
+____________________________________________________________
+
+duke.DukeException: Whoops :( I'm sorry, I'm not sure what that means. Did you forget to add a command type?
+
+____________________________________________________________
+Very Woof! I have completed this commands:
+[T] [X] rollover
+
+____________________________________________________________
+
+duke.DukeException: Eh? Your command description cannot be empty. Try again!
+
+____________________________________________________________
+Very Woof! I have completed this commands:
+[D] [X] finish doggo treats | by: 11 Mar 2021
+
+____________________________________________________________
+
+
+____________________________________________________________
+We found some matching commands:
+1. [E] [ ] dog festival | at: 10 Feb 2021
+2. [D] [X] finish doggo treats | by: 11 Mar 2021
+
+____________________________________________________________
+
+duke.DukeException: What are you referring to? Remember to key in the correct command id!
+
+____________________________________________________________
+Noted! This task has been removed:
+[E] [ ] dog festival | at: 10 Feb 2021
+Now you have 2 commands remaining.
+____________________________________________________________
+
+
+____________________________________________________________
+
+1. [T] [X] rollover
+2. [D] [X] finish doggo treats | by: 11 Mar 2021
+
+____________________________________________________________
+
+
+____________________________________________________________
+Bye! Hope I was a good dog, see you again soon!
+____________________________________________________________
diff --git a/text-ui-test/data/duke.txt b/text-ui-test/data/duke.txt
new file mode 100644
index 0000000000..e64eb8ac9c
--- /dev/null
+++ b/text-ui-test/data/duke.txt
@@ -0,0 +1,2 @@
+T | 1 | rollover
+D | 1 | finish doggo treats | 2021-03-11
diff --git a/text-ui-test/input.txt b/text-ui-test/input.txt
index e69de29bb2..a0d50ddae7 100644
--- a/text-ui-test/input.txt
+++ b/text-ui-test/input.txt
@@ -0,0 +1,14 @@
+paw
+todo rollover
+event dog festival /at 2021-020-10
+event dog festival /at 2021-02-10
+deadline finish doggo treats /by 2021-03-11
+shake
+done 1
+todo
+done 3
+find dog
+delete
+delete 2
+list
+bye
diff --git a/text-ui-test/runtest.sh b/text-ui-test/runtest.sh
old mode 100644
new mode 100755
index c9ec870033..54df5dad0f
--- a/text-ui-test/runtest.sh
+++ b/text-ui-test/runtest.sh
@@ -13,14 +13,14 @@ then
fi
# compile the code into the bin folder, terminates if error occurred
-if ! javac -cp ../src/main/java -Xlint:none -d ../bin ../src/main/java/*.java
+if ! javac -cp ../src/main/java -Xlint:none -d ../bin ../src/main/java/duke/*.java
then
echo "********** BUILD FAILURE **********"
exit 1
fi
# run the program, feed commands from input.txt file and redirect the output to the ACTUAL.TXT
-java -classpath ../bin Duke < input.txt > ACTUAL.TXT
+java -cp ../bin duke.Duke < input.txt > ACTUAL.TXT
# convert to UNIX format
cp EXPECTED.TXT EXPECTED-UNIX.TXT