Hi Team,
Our test application use java script navigator.clipboard.writetext to copy content into clipboard, when we run cases with telerik 2024, some scenario pops error "fail to copy", the exception for java script is "NotAllowedError: Failed to execute 'writeText' on 'Clipboard': Write permission denied.".
After check, we can see it's because clipboard-write is denied when telerik open browser, but if we manually open the browser, it's fine. Only failed for browser which is opened by telerik.
You can use below example code to check in browsers which is opened by telerik.
test code:
// Initialize the settings
mySettings = new Settings();
// Set the default browser
mySettings.Web.DefaultBrowser = BrowserType.Chrome; // we can change the two lines for different scenario test
mySettings.Web.UseBrowserExtension = false;
myManager = new Manager(mySettings);
// Start the manager
myManager.Start();
// Launch a new browser instance. [This will launch an IE instance given the setting above]
myManager.LaunchNewBrowser();
myManager.ActiveBrowser.NavigateTo("https://www.telerik.com");
when the browser is opened, you can execute below script in develop tools.
await navigator.permissions.query({
name: 'clipboard-write',
});
Below is what I have summary for telerik 2024 and 2022, please help to confirm if all the the denied scenarios are expected.
Thanks,
Jun