问题
I am trying to get all the cookies of the browser which is opened while we execute automation test using Katalon.
Please suggest how we can extract a specific cookie/list of cookies using Katalon.
I have checked in traditional Selenium/Java; its pretty easy -
driver.manage().getCookieNamed("Cookie Name").getValue();
But I am not getting any clue how to do this in Katalon.
回答1:
Resolved it....
import com.kms.katalon.core.webui.driver.DriverFactory
import org.openqa.selenium.WebDriver
WebDriver driver = DriverFactory.getWebDriver() println driver.manage().getCookieNamed("Cookie Name").getValue()
来源:https://stackoverflow.com/questions/54899900/how-to-extract-browser-cookies-using-katalon-studio