CodeX
Published in

CodeX

Using Jest Unit Tests to successfully test map functions

Today we’re going to demonstrate how map works and how implementing map a certain way can break a test. In the code samples below, there are 2 ways of using map to do the same thing. One passes a function to a map (ie. uses quite a common…

--

--

Get the Medium app

A button that says 'Download on the App Store', and if clicked it will lead you to the iOS App store
A button that says 'Get it on, Google Play', and if clicked it will lead you to the Google Play store