In this project we will be using webpack to create, edit, and delete tasks from a list of tasks created by the user, the main goals of this project are: Use webpack to bundle JavaScript. Learn how to use proper ES6 syntax. Use ES6 modules to write modular JavaScript.
Description
In this project you will write unit tests for the To Do list application. The testing project has been divided into two parts. In part 1 you will test functions responsible for adding and deleting list items. In part 2 you will test the status and content updates as well as the order re-position of items in the list.
Project requirements
This is a pair-programming project. Please decide whose project will you use for testing.
Use jest framework for testing.
Create a test file ([..].test.js) for a file containing the add item and delete item functions that you want to test.
Take a look at each of these functions. Are they pure functions? If the answer is "yes" then writing tests for them should be straightforward. Some of those functions however will update localStorage and manipulate the DOM. For those, you will need to use mocks:
Mock a storage object to "imitate" localStorage operations (only if you are using jest < 24.x, in newer versions localStorage is mocked automatically).
Mock HTML to test if add/delete functions add or remove exactly one
element to/from the list in the DOM.
Make sure you group your tests using the describe() method.
Description In this project you will write unit tests for the To Do list application. The testing project has been divided into two parts. In part 1 you will test functions responsible for adding and deleting list items. In part 2 you will test the status and content updates as well as the order re-position of items in the list.
Project requirements This is a pair-programming project. Please decide whose project will you use for testing. Use jest framework for testing. Create a test file ([..].test.js) for a file containing the add item and delete item functions that you want to test. Take a look at each of these functions. Are they pure functions? If the answer is "yes" then writing tests for them should be straightforward. Some of those functions however will update localStorage and manipulate the DOM. For those, you will need to use mocks: Mock a storage object to "imitate" localStorage operations (only if you are using jest < 24.x, in newer versions localStorage is mocked automatically). Mock HTML to test if add/delete functions add or remove exactly one
@ivanmvh @M1rn4