mirror of
https://github.com/sudoxnym/habitica.git
synced 2026-08-04 01:29:21 +00:00
Made sure to use api.startOfDay in dailies.coffee unit test when calculating day of the week.
This commit is contained in:
parent
90dd078a6a
commit
0dcd388925
1 changed files with 1 additions and 1 deletions
|
|
@ -348,7 +348,7 @@ describe 'weekly that repeats on M,W,F every x days', ->
|
|||
_.times 100, (day) ->
|
||||
valid_days = { Mon: true, Wed: true, Fri: true }
|
||||
day_to_test = start_date.add(day, 'days')
|
||||
day_of_week = moment(day_to_test).format('ddd')
|
||||
day_of_week = shared.startOfDay({now:day_to_test}).format('ddd')
|
||||
|
||||
isDue = shared.shouldDo day_to_test, weekly
|
||||
is_correct_week = shared.numWeeksApart(day_to_test, start_date) % due == 0
|
||||
|
|
|
|||
Loading…
Reference in a new issue