Use Jest to spyOn chained function – Javascript
I am trying to spyOn a chained function for my socketIO server. The first toSpy is working fine but I seem to be unable to check the emit chained function. Anyone a simple and elegant way to test a chained…