Skip to content

serhii-chernenko/vue3-toggle-input-component-test

Repository files navigation

difficulty training chapter tags
1
true
Chapter 4: Testing Vue Components and Composables
vue

Toggle Input Component Test Challenge

Your task is to create a component test for the ToggleInput component we created earlier in the training.

Requirements

  1. Test that the v-model value correctly toggles between true and false when the component is clicked

💡 HINT: Feel free to use TypeScript to make your component test type safe if you'd like. This is NOT required however.

💡 HINT: Run the tests with yarn test:unit

Screenshot of the solution