mirror of
https://github.com/sudoxnym/habitica.git
synced 2026-08-04 09:39:23 +00:00
18 lines
762 B
CoffeeScript
18 lines
762 B
CoffeeScript
|
|
# ---------- Todos ------------
|
||
|
|
casper.then ->
|
||
|
|
reset()
|
||
|
|
addTasks()
|
||
|
|
|
||
|
|
# Gained exp on +daily
|
||
|
|
casper.then ->
|
||
|
|
user = userBeforeAfter (-> casper.click '.todos input[type="checkbox"]')
|
||
|
|
@test.assertEquals user.before.stats.hp, user.after.stats.hp, '+daily =hp'
|
||
|
|
@test.assert user.before.stats.exp < user.after.stats.exp, '+daily +exp'
|
||
|
|
@test.assert user.before.stats.money < user.after.stats.money, '+daily +money'
|
||
|
|
|
||
|
|
# -daily acts as undo
|
||
|
|
casper.then ->
|
||
|
|
user = userBeforeAfter (-> casper.click '.todos input[type="checkbox"]')
|
||
|
|
@test.assertEquals user.before.stats.hp, user.after.stats.hp, '-daily =hp'
|
||
|
|
@test.assert user.before.stats.exp > user.after.stats.exp, '-daily -exp'
|
||
|
|
@test.assert user.before.stats.money > user.after.stats.money, '-daily -money'
|