Skip to content

Commit

Permalink
Merge branch 'V0.5_additional_tests' of https://github.com/CS2103AUG2…
Browse files Browse the repository at this point in the history
…016-T13-C2/main into V0.5_additional_tests
  • Loading branch information
Kevin Ong authored and Kevin Ong committed Nov 7, 2016
2 parents ad5cc60 + a2c58eb commit 71de9b5
Show file tree
Hide file tree
Showing 5 changed files with 102 additions and 147 deletions.
136 changes: 48 additions & 88 deletions docs/UserGuide.md
Original file line number Diff line number Diff line change
Expand Up @@ -22,9 +22,9 @@
e.g. typing **`help`** and pressing <kbd>Enter</kbd> will open the help window.
5. Some example commands you can try:
* **`list`** : lists all activities
* **`add`**` CS2103 T7A1 d/tomorrow 1500 p/2 r/today 1800 t/teamC2` :
* **`add`**` CS2103 T7A1 d/6 Oct 2016 p/2 r/5 Oct 2016 1800 t/teamC2` :
adds an activity named `CS2103 T7A1` to the Lifekeeper.
* **`delete`**` 1` : deletes the 1st activity shown in the current list
* **`delete`**` 3` : deletes the 3rd activity shown in the current list
* **`exit`** : exits the app
6. Refer to the [Features](#features) section below for details of each command.<br>

Expand Down Expand Up @@ -55,42 +55,30 @@ Format: `add ACTIVITY_NAME {[d/DUEDATE] [p/PRIORITY_LEVEL]}{[s/START_TIME] [e/EN
* `tomorrow [TIME]`
* `today [TIME]`


When `TIME` is omitted the default `TIME` will be set to 2359 on the input date given in `DUEDATE`.


`PRIORITY_LEVEL` has to be an integer between `1` to `3`, with `3` being the highest priority, and `1` being the lowest priority.

`PRIORITY_LEVEL` has to be an integer equal or larger than 1, with `1` being the top priority.

`START_TIME` accepts `Date Time` format input and variable inputs namely:
* `tomorrow TIME`
* `today TIME`
* `every DAY_OF_WEEK TIME`
* `tomorrow [TIME]`
* `today [TIME]`

`END_TIME` accepts `Date Time` format input and variable inputs namely:
* `tomorrow TIME`
* `today TIME`
* `every DAY_OF_WEEK TIME`
* `TIME`

When `END_TIME` is omitted and `START_TIME` input is given the default `END_TIME` will be set to 1 hour after `START_TIME`
* `tomorrow [TIME]`
* `today [TIME]`


`REMINDER` accepts `Date Time` format input and variable inputs namely:
* `tomorrow TIME`
* `today TIME`

At the stipulated `Date Time` of `REMINDER`, a pop-up notification will appear as a form of reminder.

* `tomorrow`
* `today`
* `[TIME] before` sets reminder at the specified time before the `DUEDATE`. e.g. `0015 before` for a reminder 15 minutes before the `DUEDATE`.

Examples:
* `add Grocery Shopping`
* `add Assignment 1 d/tomorrow p/1 r/today 2000`
* `add Project Report d/tomorrow 1700 t/school`
* `add CS2103 T7A1 d/6-12-2016 p/2 r/5-12-2016 1800 t/teamC2`
* `add Lunch s/today 1200`
* `add Assignment 1 d/Tomorrow p/1 r/Today 2000`
* `add Project Report d/Tomorrow 1700 t/school`
* `add CS2103 T7A1 d/6 Oct 2016 p/2 r/5 Oct 2016 1800 t/teamC2`
* `add Lunch s/1200 e/1300`
* `add Executive Meeting s/tomorrow 0900 e/tomorrow 1200`
* `add Concert s/tomorrow 1800 e/tomorrow 2000 r/today 1800 t/Leisure`
* `add Concert s/tomorrow 1800 e/tomorrow 2000 t/Leisure`

<!-- @@author A0131813R -->
#### Listing activities : `list`
Expand All @@ -101,40 +89,49 @@ Format: `list [TYPE]`
> If TYPE is not given, all the activites in Lifekeeper will be listed
> If TYPE is given only activities of that type will be listed
`TYPE` accepts the following `done`, `activities`, `events` or `tasks`
`TYPE` accepts the following `activities`, `events`, `tasks`, `done` or `all`.

Examples:
* `list event`

> shows all events in the list.

#### Find by tag: `findtag `
Shows a list of all entries with the tags in LifeKeeper.<br>
Format: `findtag KEYWORD`

> All the entries with tags in Lifekeeper will be listed
<!-- @@author A0125097A -->

#### Finding activities by name: `find`
#### Finding activities by name or tag(s): `find`
Finding all activities containing the queried keyword in their name
* Finds activities whose names contain any of the given keywords.<br>
* Format: `find KEYWORD [MORE_KEYWORDS]`

> * The search is not case sensitive. e.g `study` will match `Study`
> * Tasks matching at least one keyword will be returned.
e.g. KEYWORD `Shopping` will match the NAME entry `Clothes Shopping`
> * The order of the keywords matters. e.g. `Assignment Due` will not match `Due Assignment`
> * Words containing the keywords will be matched e.g. `Exam` will match `Exams`
> * Tasks matching at least one keyword will be returned (i.e. `OR` search).
e.g. `Shopping` will match `Clothes Shopping`

Examples:
* `find Homework Assignment`<br>
* `find activities Homework Assignment`<br>
Returns Any activities with words containing `Homework`, `homework`, `Assignment`, or `assignment` in their names.

<!-- @@author A0125680H -->
Finding all activities containing a certain tag
* Finds activities which has tags of given keywords attached to it.<br>
* Format: `findtag KEYWORD`
* Format: `find tags KEYWORD [MORE_KEYWORDS]`

> * The search is case sensitive.
> * The search is not case sensitive.
> * Only full words will be matched.
> * Only tags matching the EXACT keyword will be returned.
> * Only tags matching the EXACT keyword will be returned.
Examples:
* `find CS2103`
Returns Any activities containing the tag `CS2103` but not`cs2103`, `CS2103T` or `CS2103Project`.
Returns Any activities containing the tag `CS2103` or `cs2103` but not `CS2103T` or `CS2103 Project`.

#### Deleting an activity: `delete`
Deletes the selected activity from Lifekeeper. Irreversible.<br>
Expand All @@ -152,22 +149,21 @@ Examples:
`delete 2`<br>
Deletes the 2nd activity listed in the results of the `find` command.


<!-- @@author A0125097A -->
#### Marking an activity as completed: `done`
Marks the activity as completed. Only applicable to activities without start and end time. <br>
#### Marking an activity as done: `done`
Marks the activity as completed.<br>
Format: `done INDEX`

> Marks the activity with `INDEX` as completed.
The index refers to the index number shown in the most recent listing.<br>

Examples:
* `list`<br>
`done 1`<br>
Marks the 1st activity in the Lifekeeper activity list as completed.
* `find Admin`<br>
`done 2`<br>
Marks the 2nd activity in the results of the `find` command as completed.
Selects the 2nd activity in the results of the `find` command and then marks it as completed.

<!-- @@author A0125680H -->
#### Editing an activity: `edit`
Expand Down Expand Up @@ -198,64 +194,28 @@ Format: `clear`
Exits the program.<br>
Format: `exit`

<!-- @@author A0125680H -->
#### Opening a data file : `open`
Loads data from an existing data file into the program.

* If no filepath or an invalid filepath is specified, or the specified file does not exist, the file chooser will be brought up instead.<br>
* '/' or '\' can be used to separate components of a file path.
* The `.xml` file suffix may or may not be specified.
* Format: `open [FILE_PATH]`

> File name cannot consist of any of the following characters: '<', '>', ':', '"', '|', '?', '*'
Examples:
* `open data/toopen.xml`<br>
Loads data from the file `toopen.xml`, in the folder `data` that is in the same directory as the executable JAR file.

<!-- @@author A0125680H -->
#### Saving into a new file : `save`
Saves the Lifekeeper data into a file specified by the user.

* If no filepath or an invalid filepath is specified, the file chooser will be brought up instead.<br>
* '/' or '\' can be used to separate components of a file path.
* The `.xml` file suffix may or may not be specified.
* Format: `save [FILE_PATH]`

> File name cannot consist of any of the following characters: '<', '>', ':', '"', '|', '?', '*'
Examples:
* `save data/tosave.xml`<br>
Creates a new folder named `data` in the same directory as the executable JAR file, and saves the Lifekeeper data in the file `tosave.xml` in that folder.

#### Autosaving of data
Lifekeeper data are saved in the hard disk automatically after any command that changes the data (add, edit, delete).<br>
There is no need to save manually.
#### Saving the data
Lifekeeper data are saved in the hard disk automatically after any command that changes the data.<br>
There is no need to save manually.

## FAQ

**Q**: How do I transfer my data to another Computer?<br>
**A**: Install the app in the other computer and overwrite the empty data file it creates with
the file that contains the data of your previous Lifekeeper folder.



<!-- @@author A0125097A -->

## Command Summary

Command | Format | Sample Input
-------- | :-------- | :--------
Add | `add ACTIVITY_NAME {[d/DUEDATE] [p/PRIORITY_LEVEL]} {[s/START_TIME] [e/END_TIME]} [r/REMINDER] [t/TAG]...` | add Dinner with friends s/tomorrow 1800 e/1930 r/today 1800 t/dinner
Edit | `edit INDEX [n/ACTIVITY_NAME] {[d/DUEDATE] [p/PRIORITY_LEVEL]} {[s/START_TIME] [e/END_TIME]} [r/REMINDER] [t/TAG]...` | edit 2 n/assignment d/tuesday 1800 r/monday 1800 t/
Command | Format
-------- | :--------
Add | `add ACTIVITY_NAME {[d/DUEDATE] [p/PRIORITY_LEVEL]} {[s/START_TIME] [e/END_TIME]} [r/REMINDER] [t/TAG]...`
Edit | `edit INDEX [n/ACTIVITY_NAME] {[d/DUEDATE] [p/PRIORITY_LEVEL]} {[s/START_TIME] [e/END_TIME]} [r/REMINDER] [t/TAG]...`
Clear | `clear`
Delete | `delete INDEX` | delete 2
Find | `find KEYWORD [MORE_KEYWORDS]` | find assignment
Delete | `delete INDEX`
Find | `find KEYWORD [MORE_KEYWORDS]`
List | `list`
Find Tags | `findtag` | findtag dinner
Done | `done INDEX` | done 2
Find Tags | `findtag`
Done | `done INDEX`
Undo | `undo`
Help | `help`
Open | `open [FILE_PATH]` | open data/savefile.xml
Save | `save [FILE_PATH]` | save work/schedule.xml
Exit | `exit`
98 changes: 48 additions & 50 deletions src/test/data/ManualTesting/TestScript.md
Original file line number Diff line number Diff line change
@@ -1,47 +1,27 @@
# Test Script

* [Quick Start](#quick-start)
* [Description](#description)
* [Testing Commands](#Testing Commands)
* [Testing Commands](#testing-commands)
* [Command Summary](#command-summary)

## Quick Start

0. Ensure you have Java version `1.8.0_60` or later installed in your Computer.<br>
> Having any Java 8 version is not enough. <br>
This app will not work with earlier versions of Java 8.


1. Type the command in the command box and press <kbd>Enter</kbd> to execute it. <br>
e.g. typing **`help`** and pressing <kbd>Enter</kbd> will open the help window.
2. To open the SampleData, type **`open`** and press <kbd>Enter</kbd>. Then choose the saved location of SampleData, which should end with *src\test\data\ManualTesting\SampleData.xml*
3. Some example commands you can try:
* **`list`** : lists all activities
* **`add`**` CS2103 T7A1 d/6 Oct 2016 p/2 r/5 Oct 2016 1800 t/teamC2` :
adds an activity named `CS2103 T7A1` to the Lifekeeper.
* **`delete`**` 3` : deletes the 3rd activity shown in the current list
* **`exit`** : exits the app
4. Refer to the [Description](#description) section below for details of the LifeKeeper.<br>


## Description

0. Each card in the bottom left panel is a task added to the LifeKeeper.
1. The LifeKeeper supports three types of entries:
* Each card in the bottom left panel is a task added to the LifeKeeper.
* The LifeKeeper supports three types of entries:
* `Activity`
* `Task`
* `Event`
2. Activity is a floating task which must have a valid `NAME` and optional `[REMINDER]`.<br>
3. Task is a task which must have a valid `NAME` and either `[DUEDATE]` or [PRIORITY]`. `[REMINDER]` can also be entered together with the rest.<br>
4. Event is a task which must have a valid `NAME` and `[STARTTIME]` and optional `[ENDTIME]`. `[REMINDER]` can also be entered together with the rest.<br>
5. All task types can have optional `[TAG]`, each task accepts multiple tags. `Tags` are shown with `[]`. <br>
6. Colours of the background of the cards indicate the status of the task.
* `Green`: Task or Activity that has been marked as done, or an Event that has passed. A text `Completed` or `Event Over` is shown to notify user of the status of the task/event
* `Yellow`: Task with a deadline within three days. A text `Task Deadline Approaching` is also shown to notify user of the impending deadline.
* `Red`: Task with a duedate that has passed and yet not marked as done. A text `Task Overdue` is also shown to reminder user of the overdue task.
* `Blue`: Events that are ongoing. This is defined as an event with a start time before the current time, and an end time after the current time. A text `Event Ongoing` is shown to notify the user of the event status.
* `White`: The default colour indicating all other types of tasks.
7. <img src="priority3.png" width="15"> shown on the right side of the card indicates the important or priority of the task. There are four levels of priority 0, 1, 2, 3 which are indicated by the number of exclamation marks shown. Priority is only applicable to task but not activity or event.
* Activity is a floating task which must have a valid `NAME` and optional `[REMINDER]`.<br>
* Task is a task which must have a valid `NAME` and either `[DUEDATE]` or [PRIORITY]`. `[REMINDER]` can also be entered together with the rest.<br>
* Event is a task which must have a valid `NAME` and `[STARTTIME]` and optional `[ENDTIME]`. `[REMINDER]` can also be entered together with the rest.<br>
* All task types can have optional `[TAG]`, each task accepts multiple tags. `Tags` are shown with `[]`. <br>
* Colours of the background of the cards indicate the status of the task.
* `Green`: Task or Activity that has been marked as done, or an Event that has passed. A text `Completed` or `Event Over` is shown to notify user of the status of the task/event
* `Yellow`: Task with a deadline within three days. A text `Task Deadline Approaching` is also shown to notify user of the impending deadline.
* `Red`: Task with a duedate that has passed and yet not marked as done. A text `Task Overdue` is also shown to reminder user of the overdue task.
* `Blue`: Events that are ongoing. This is defined as an event with a start time before the current time, and an end time after the current time. A text `Event Ongoing` is shown to notify the user of the event status.
* `White`: The default colour indicating all other types of tasks.
* <img src="priority3.png" width="15"> shown on the right side of the card indicates the important or priority of the task. There are four levels of priority 0, 1, 2, 3 which are indicated by the number of exclamation marks shown. Priority is only applicable to task but not activity or event.

## Loading saved data
Method 1
Expand All @@ -61,9 +41,13 @@ Method 2
> * Items with `...` after them can have multiple instances.
> * The order of parameters is not fixed.
### Help Command

#### Testing Command: `help`

> Help window pops up
### Add Command

#### Testing Command: `add activity`

Expand Down Expand Up @@ -100,18 +84,12 @@ Method 2
> An invalid error will be shown, prompting the user that `Event end time is before start time`.
> For all tasks with reminder, the reminder will automatically pop up at the scheduled time when the app is open.
#### Testing Command: `add do IE 3101 Tutorial d/today p/3 t/IE3101`

> A new task is added to the top of the list with name `do IE 3101 Tutorial`, duedate ` Due on (Today's Date) 11:59PM`, tag `[IE3101]` and <img src="src/main/resources/images/priority3.png" width="15">
> A new task is added to the top of the list with name `do IE 3101 Tutorial`, duedate ` Due on (Today's Date) 11:59PM`, tag `[IE3101]` and <img src="priority3.png" width="15">.
> The colour of the background of the card will also turn yellow with the text `Task Deadline Approaching` shown on the right of the card.
#### Testing Command: `add IE3100 Assignment 4 d/wed 1800 t/IE3100`.
#### Testing Command: `add IE3100 Tutorial d/wed 1800 t/IE3100`.

> A new task is added to the top of the list with name `IE3100 Assignment 4`, duedate ` Due on (upcoming Wednesday's date) 6:00P` and `Reminder: -`
> There is also a tag `[IE3100]` shown.
#### Testing Command: `add IE3100 Assignment 4 p/2 t/IE3100`
#### Testing Command: `add IE3100 Group Assignment p/2 t/IE3100`

> A new task is added to the top of the list with name `IE3100 Assignment 4`, `Reminder: -` and <img src="priority2.png" width="15">.
> There is also a tag `[IE3100]` shown.
Expand Down Expand Up @@ -186,19 +164,15 @@ Method 2

> Invalid command since the reminder time is before the current time. Result Bar shows the error that `reminder time has passed`.
#### Testing Command: `add revision for IE3120 s/10-10-2016 1200
#### Testing Command: `add revision for IE3120 s/10-10-2016 1200`

> Invalid command since the start time for the adding event is before the current time.
#### Testing Command: `add YellowCare Concert e/10-10-2017 1200
#### Testing Command: `add YellowCare Concert e/10-10-2017 1200`

> Invalid command since there is only end time without a start time for the event.




### Test Edit Command:
### Edit Command

#### Testing Command: `add assignment 2`, <kbd>Enter</kbd> , `edit 1 n/assignment 3`

Expand Down Expand Up @@ -251,9 +225,33 @@ Method 2



###Test Findtag Command
### Find tag Command

#### Testing Command: `findtag IE3100`

> The command returns all the entries with the tag IE3100
### Done Command

#### Testing Command: `add speak to Prof r/today 2300`, <kbd>Enter</kbd> , 'done'

> The newly added activity `speak to Prof` will be marked as a done task.
> It will be removed from the list and moved to the done list.
#### Testing Command: `add speak to ISE Department d/today 1700`, <kbd>Enter</kbd> , 'done'

> The newly added task `speak to ISE Department` will be marked as a done task.
> It will be removed from the list and moved to the done list.
### List Command

#### Testing Command: `list all`

> Listing command that shows all the tasks inside the Lifekeeper
#### Testing Command: `list`

> The default listing with all the tasks excluding completed


Expand Down
Binary file added src/test/data/ManualTesting/priority3.png
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.

0 comments on commit 71de9b5

Please sign in to comment.