I have an array of website urls. I am looping each with another loop for links form its sitemap.
The code I have works but finishes the inner sitemap loop way too early (after 5 iterations) and goes to the next url.
Modules I am usng are puppeteer, mocha lodash and fs extra.
I attempted lodash in the second loop but received a memory leak so I went for a standard loop.
Why is there an extra }) at the end of the code?
Why have we got a foreach outside of the it declaration?
Why do we not expect anything? What’s the result of this test?
Ok thanks for that I will look at it and make some amendments.
The forEach is outside of the ‘it’ because I want to run the test for each specific test.
I want to eventually take screenshots and compare them to previous screenshots taken.
I havent added all the code as this is the code that is causing the issue.
urls are external. links are an array created from the page sitemap. Sorry im an apprentice developer. Really interested in this and always willing to learn.