After being bitten a couple of times by bad refactoring and a broken app — even with all my tests green — I started to research about integration tests in React. Possibly also with Redux and React Router. To my absolute shock, I couldn’t find any good material out there.
Showing posts with label test. Show all posts
Showing posts with label test. Show all posts
Sunday, December 31, 2017
Real integration tests with React, Redux and Router
After being bitten a couple of times by bad refactoring and a broken app — even with all my tests green — I started to research about integration tests in React. Possibly also with Redux and React Router. To my absolute shock, I couldn’t find any good material out there.
Thursday, December 21, 2017
Test redux actions that calls an API
export function receivingItems() { return (dispatch, getState) => { axios.get('/api/items') .then(function(response) { dispatch(receivedItems(response.data)); }); }; } describe('Items Action Creator', () => { it('should create a receiving items function', () => { expect(receivingItems()).to.be.a.
Subscribe to:
Posts (Atom)
bundlephobia
JavaScript bloat is a more real problem today than it ever was. Bundlephobia lets you understand the performance cost of adding a npm pack...
-
Programmers almost always need the ability to find and replace certain text across multiple files in their projects. Most IDEs provide find ...
-
This is yet another rails stack installation how to. It is useful for installing a production rails hosting environment using Nginx as the ...
-
Git is a Version Control System , it is used to keep a history of all the changes you made into your code, manage releases, makes it easier...