We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 6e60693 commit 87b3d5eCopy full SHA for 87b3d5e
1 file changed
test/plan/parser_test.janet
@@ -204,6 +204,21 @@
204
(test (task :title) "Fix the lamp")
205
(test (task :done) true)))
206
207
+(deftest "parses a plan with an event without any tasks"
208
+ (def plan-string
209
+ ```
210
+ # Main TODO
211
+
212
+ ## 2020-07-30, Thursday
213
214
+ - Talked to Mike & Molly
215
+ ```)
216
+ (def plan ((parse plan-string) :plan))
217
+ (test (length (plan :days)) 1)
218
+ (let [day ((plan :days) 0)
219
+ event ((day :events) 0)]
220
+ (test (event :title) "Talked to Mike & Molly")))
221
222
(deftest "returns an error when the plan can't be parsed"
223
(def plan-string
224
```
0 commit comments