aboutsummaryrefslogtreecommitdiff
path: root/tests/todo-app.spec.ts
diff options
context:
space:
mode:
Diffstat (limited to 'tests/todo-app.spec.ts')
-rw-r--r--tests/todo-app.spec.ts14
1 files changed, 14 insertions, 0 deletions
diff --git a/tests/todo-app.spec.ts b/tests/todo-app.spec.ts
index 7fe7d2f..6595bbf 100644
--- a/tests/todo-app.spec.ts
+++ b/tests/todo-app.spec.ts
@@ -49,5 +49,19 @@ describe('todo-app example', () => {
'Kill all the non-believers',
)
})
+
+ // TODO: Add toggle state after implementing conditionals
+ it('should check item when clicked', async () => {
+ expect(
+ getComputedStyle($taskItems[0]).getPropertyValue('--checked'),
+ ).toBe(`'0'`)
+
+ $taskItems[0].click()
+ await delay(100)
+
+ expect(
+ getComputedStyle($taskItems[0]).getPropertyValue('--checked'),
+ ).toBe(`"1"`) // TODO: look into the quotes issue
+ })
})
})