From c4d6dbdb100bb66db9b184c653617c47a63e91ca Mon Sep 17 00:00:00 2001 From: Quey-Liang Kao Date: Mon, 14 Aug 2017 16:12:53 +0800 Subject: Implement the "dn" feature: Deleteing notes --- todolist/parser_test.go | 7 +++++++ 1 file changed, 7 insertions(+) (limited to 'todolist/parser_test.go') diff --git a/todolist/parser_test.go b/todolist/parser_test.go index 9412bdf..e5c7007 100644 --- a/todolist/parser_test.go +++ b/todolist/parser_test.go @@ -84,6 +84,13 @@ func TestParseNotes(t *testing.T) { if todo.Notes[0] != "www.google.com" { t.Error("Expected note 1 to be 'www.google.com' but got", todo.Notes[0]) } + + if parser.ParseNotes(todo, "dn 1 0") != "delete" { + t.Error("Expected Notes to be deleted") + } + if len(todo.Notes) != 0 { + t.Error("Expected no note") + } } func TestDueToday(t *testing.T) { -- cgit v1.3