@@ -18,11 +18,22 @@ describe('Todo state', function()
18
18
19
19
it (' should properly cycle through all defined custom states' , function ()
20
20
config :extend ({
21
- org_todo_keywords = { ' TODO' , ' WAITING' , ' PROCESSING' , ' |' , ' CONFIRM' , ' DONE' },
21
+ org_todo_keywords = {
22
+ ' TODO' ,
23
+ ' WAITING' ,
24
+ ' PROCESSING' ,
25
+ ' HYPHEN-KEYWORD' ,
26
+ ' MULTI-HYPHEN-KEYWORD' ,
27
+ ' |' ,
28
+ ' CONFIRM' ,
29
+ ' DONE' ,
30
+ },
22
31
})
23
32
local next_state = TodoState :new ({ current_state = ' TODO' })
24
33
assert .are .same ({ value = ' WAITING' , type = ' TODO' , hl = ' OrgTODO' }, next_state :get_next ())
25
34
assert .are .same ({ value = ' PROCESSING' , type = ' TODO' , hl = ' OrgTODO' }, next_state :get_next ())
35
+ assert .are .same ({ value = ' HYPHEN-KEYWORD' , type = ' TODO' , hl = ' OrgTODO' }, next_state :get_next ())
36
+ assert .are .same ({ value = ' MULTI-HYPHEN-KEYWORD' , type = ' TODO' , hl = ' OrgTODO' }, next_state :get_next ())
26
37
assert .are .same ({ value = ' CONFIRM' , type = ' DONE' , hl = ' OrgDONE' }, next_state :get_next ())
27
38
assert .are .same ({ value = ' DONE' , type = ' DONE' , hl = ' OrgDONE' }, next_state :get_next ())
28
39
assert .are .same ({ value = ' ' , type = ' ' }, next_state :get_next ())
@@ -32,6 +43,8 @@ describe('Todo state', function()
32
43
assert .are .same ({ value = ' ' , type = ' ' }, prev_state :get_prev ())
33
44
assert .are .same ({ value = ' DONE' , type = ' DONE' , hl = ' OrgDONE' }, prev_state :get_prev ())
34
45
assert .are .same ({ value = ' CONFIRM' , type = ' DONE' , hl = ' OrgDONE' }, prev_state :get_prev ())
46
+ assert .are .same ({ value = ' MULTI-HYPHEN-KEYWORD' , type = ' TODO' , hl = ' OrgTODO' }, prev_state :get_prev ())
47
+ assert .are .same ({ value = ' HYPHEN-KEYWORD' , type = ' TODO' , hl = ' OrgTODO' }, prev_state :get_prev ())
35
48
assert .are .same ({ value = ' PROCESSING' , type = ' TODO' , hl = ' OrgTODO' }, prev_state :get_prev ())
36
49
assert .are .same ({ value = ' WAITING' , type = ' TODO' , hl = ' OrgTODO' }, prev_state :get_prev ())
37
50
assert .are .same ({ value = ' TODO' , type = ' TODO' , hl = ' OrgTODO' }, prev_state :get_prev ())
0 commit comments