Safari - How To Automate The Reset Safari Items - safari

Using Safari browser and finding one hurdle to making it my default browser - there is no default setting for clearing/deleting all the stuff you find in the menu's Reset Safari panel.
I made an Automator routine using the 'Watch Me' to do this and quit safari - it works. But, I'd really like to not have the steps display while it's running. The show actions is not selected but, they still show.
I tried creating a script but Safari dictionary does not have the option for Reset (or any of the reset panels items...)
So, how can I accomplish this?

Related

How to get rid of google pop-ups while testing and navigation google url?

Every time I navigate to google through Selenium, I encounter this popup. I can't click on the search bar. Is there a way to close permanently this popup without using any JS alert method etc.?
I tried some extensions but it didn't work
Click the Lock button (🔒) on the top-left of the search box
Click on 'Cookies'
Make sure you're on 'allowed' and find anything on the lines of google.com
Click Block, Done and refresh the page
Additionally, you may want to try it first without the web-driver 'Chrome is being controlled by automated test software' mode, so open Google Chrome you way you usually would.

Tooltip covers the button so I get org.openqa.selenium.ElementClickInterceptedException

I'm using Selenium for integration testing of our web app, and it's been working great up until I got far enough down the sidebar menu. Suddently the Create test would fail with org.openqa.selenium.ElementClickInterceptedException: element click intercepted. Other element would receive the click:
The error was very sporadic - order of tests would affect which test class failed - but finally I figured out the reason is that the tooltip from the most recently clicked menu option covers the button I'm trying to click. Not really sure why sending input to form elements (using WebElement:sendKeys() and org.openqa.selenium.support.ui.Select) does not count as moving the mouse away.
Is there a way to make Selenium work around this, or do we have to turn off tooltips in the test version (for obvious reasons I don't like the idea of running our tests on a custom version of the web app)?

How to handle Micro Popup in Webdriver.io browser

When starting a website, I find it difficult to click Block button on Microphone popup because I can't query this popup (and also with block btn)
How can I handle this problem with Webdriver.io in browser?
enter image description here
One option is to use chrome command line switches. You can find the list here.
The one you are looking for is use-fake-device-for-media-stream. You can set this in your config file so that every time the chrome is launched, it won't show this popup since it is already set to a fake device.

How can I fix a button that is clicked but does not perform any actions?

So I'm currently working on a new project and I need to write some automated tests.
I came across a problem and I don't know how to fix it. If the button of my web page is clicked running selenium it doesn't perform any actions, but if I open the web page manualy and click on the button, everything works fine.
NOTE: I'm completely sure that the xpath is correct and the button is being clicked...
This is what happens running with selenium:
And this is what happens openning the web page manually and clicking on the button:

What is going wrong with kendo upload cancel?

I am seeing a very odd thing happen with kendo UI's kendoUpload. I have implemented a custom UI for displaying the files being uploaded, along with a progress bar and a cancel button. Kendo does not offer an API for cancelling uploads, but I read here that you can tap into kendo's default upload progress display to cancel an upload. That is exactly what I did, with the following javascript function attached to my custom cancel button:
var fileName = _getFileNameForThisCancelButton();
var kendoUpload = $('#file_upload').data('kendoUpload');
if (kendoUpload) {
var cancelButton = kendoUpload.wrapper.find('ul.k-upload-files')
.find('.k-file:has([title="' + fileName + '"]) .k-cancel');
cancelButton.click();
}
This little function works as far as it does fire the kendoUpload's cancel event, and the network traffic stops, so data is apparently no longer being sent from the browser to the server.
However, as soon as one cancel button is clicked, any subsequent requests to the site from the browser where the cancel button was clicked hang forever. Note this is for the entire site, not just the file upload page, and only for the browser in question -- the site still loads in other browsers where upload cancel buttons have not been clicked. This goes for Chrome 30.0.1599.69 m, Firefox 20.0, and IE8.
With Firefox and IE, simply closing and restarting the browser causes the hanging to stop, and the site loads again. With Chrome I have found this doesn't work, and neither does logging out of my local machine -- I have to do a full reboot to get the site to load again in Chrome. I think this may have something to do with my Chrome settings though. I have it set up to load all of my last tabs when re-opening, and I have noticed that closing and re-opening Chrome also does not delete my login cookie for the site. Either way, It's the same issue even if it is harder to reset in Chrome.
So... any ideas what is going on here? It seems almost as if the browsers are still waiting for a response from the server for the cancelled upload and blocking on the entire site waiting for a response that will never be delivered.
Updates
Turns out I was right about Chrome. After disabling the "Continue where I left off" startup option, Chrome now behaves the same as FF and IE -- need to close and reopen the browser to get the site to load again.
I have also tried this without the custom UI, meaning I turned off showFileList: false when creating the widget and clicked the actual cancel button. Starting to wonder if this has anything to do with the POST method on the server...?