Category: Testing

Testing redux-thunk like you always want it

Redux Thunk is one of the most if not the most popular Redux middleware with over 2 million downloads a month. If you compare this number to the Redux 4 million downloads a month, it is easy to figure out that over half of Redux projects are using Redux Thunk. As the name “thunk” suggests, the main goal of Redux Tunk is to allow for lazy evaluation (dispatching) of actions. While this makes it possible to dispatch actions in an asynchronous manner, it also makes it harder to test.

Fixtures, the way to manage sample and test data

Fixtures are a thin abstraction layer over sample data in your application which allows for better organizing, often complex, data structures representing different entities. If this sounds like a vague description or does not ring the bell maybe an example will speak to you better.

Set up Selenium for Firefox and Chrome

Automated browser tests, in my case, are often part of continuous integration (CI). Failure = no deploy. This naturally creates some expectations towards acceptance/end to end testing framework. I haven’t found the tool which would meet all requirements although CodeceptJS is close. Nevertheless, no matter whether you use Protractor, Nightwatch.js, WebdriverIO, CodeceptJS or anything else based on Selenium you need to set it up and make it talk to the browser.

This website uses cookies. Continuing to use this website gives consent to cookies being used. You can disable them in your browser's settings.