I wondered if anyone had successfully managed, or knew how to automate the Safari web browser on the Windows platform.
Ideally I would like to automate Safari in a similar way to using mshtml for Internet Explorer. Failing that a way to inject JavaScript into the running process would also be fine. I've used the JavaScript injection method to automate Firefox via the jssh plug-in.
I'm looking to automate the browser using .Net to enhance an existing automation framework WatiN
Edit: Whilst I think selenium might be a great choice for automating Safari in certain scenarios, I would like to use a solution that does not require installing software on the server i.e. Selenium Core or an intermediate proxy server in the case of Selenium Remote Control.
Update: 23-03-2009: Whilst I've not yet found a way to automate Safari, I have found a way to automate Webkit inside of Chrome. If you run Chrome using the --remote-shell-port=9999 command line switches (ref: http://www.ericdlarson.com/misc/chrome_command_line_flags.html) you can send javascript to the browser.
Once connected to the remote debug seesion
- Send debug() to attach to the current tab
- Send any javascript command using print, i.e. print document.window.location.href
We've used this method to add Chrome support to WatiN