I have a list of questions in my array. Inside that array, there are questions, options, type, id. I am rendering a component and using map function to iterate the array. If array has found type 'Radio', I'm rendering another component Radiotypecomponent in parent one and passing props. Similarly, if type is "text" I'm rendering Texttypecomponent, ...etc. Can someone please let me know how to write unit test for this scenario using react testing library?
Thanks!