Brave Browser Selenium automated testing failing

I have a website that I am automatically testing to ensure it runs in all browsers like Chrome, Firefox and Brave etc. But in Brave Browser the following error is coming:

[1592:17984:0325/] Unable to move the cache: Access is denied. (0x5)
[1592:17984:0325/] Unable to move cache folder C:\Users\user\AppData\Local\BraveSoftware\Brave-Browser\User Data\ShaderCache\GPUCache to C:\Users\user\AppData\Local\BraveSoftware\Brave-Browser\User Data\ShaderCache\old_GPUCache_000
[1592:17984:0325/] Unable to create cache
[1592:17984:0325/] Shader Cache Creation failed: -2
Opening in existing browser session.
Exception in thread “main” java.lang.ExceptionInInitializerError
Caused by: org.openqa.selenium.SessionNotCreatedException: Could not start a new session. Possible causes are invalid address of the remote server or browser start-up failure.
at org.openqa.selenium.remote.RemoteWebDriver.execute(
at org.openqa.selenium.remote.RemoteWebDriver.startSession(
at org.openqa.selenium.remote.RemoteWebDriver.(
at org.openqa.selenium.chromium.ChromiumDriver.(
Caused by: org.openqa.selenium.WebDriverException: Driver server process died prematurely.
Build info: version: ‘4.0.0-beta-2’, revision: ‘4ec0cfc112’
System info: host: ‘local’, ip: ‘’, ‘Windows 10’, os.arch: ‘amd64’, os.version: ‘10.0’, java.version: ‘1.8.0_272’
Driver info: driver.version: ChromeDriver
at org.openqa.selenium.remote.service.DriverService.start(
at org.openqa.selenium.remote.service.DriverCommandExecutor.execute(
at org.openqa.selenium.remote.RemoteWebDriver.execute(
… 9 more

It looks like there is some C++ code and with bugs. Is it possible to run Brave browser via command line parameters to have its own cache settings/folders so it doesn’t clash with Actual running? Can the caching be disabled for the automated testing purposes?

Expected result:
The error should not appear

Brave Version( check About Brave):
Version 1.21.77 Chromium: 89.0.4389.90 (Official Build) (64-bit)

This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.