Which of the following is the correct way of taking screenshot of a full page?

page.screenshot(new Page.ScreenshotOptions().setPath(Paths.get("Target path of screenshot file")))
page.screenshot(new Page.ScreenshotOptions().setPath(Paths.set("Target path of screenshot file")))
page.screenshot(new Page.ScreenshotOptions().setPath(Paths.get("Target path of screenshot file")).setClip("True"))
page.screenshot(new Page.ScreenshotOptions().setPath(Paths.get("Target path of screenshot file")).setFullPage(true));
Verified Answer
Correct Option - d

To get all Infosys Certified Playwright Java Automation Tester Exam questions Join Telegram Group https://rebrand.ly/lex-telegram-236dee

Telegram