selenium clear cache code example
Example 1: ubuntu clear dns cache
sudo systemd-resolve --flush-caches
Example 2: how to clear cache selenium
ChromeDriver chromeDriver = new ChromeDriver();
chromeDriver.manage().deleteAllCookies();
chromeDriver.get("chrome://settings/clearBrowserData");
chromeDriver.findElementByXPath("//settings-ui").sendKeys(Keys.ENTER);
return chromeDriver;
Example 3: clear cache manjaro
sudo pacman -Sc