watin

WatiN clear browser cache

It seems the ClearCache method doesn't quite work for IE in WatiN. at least, it doesn't work for things you've cached SINCE you've opened the instance. Any suggestions? I tried using ReOpen, but it errors. It also seems to do the same thing as Browser.Close(); Browser = new IE(); Which is slow. My tests take just about twice as l...

how to maximize firefox child browser in watin?

I have taken latest watiN trunck for to support FireFox 'AttachTo' The following code correctly maximize the parent window browser.ShowWindow(watiN.Trunk.Core.Native.Windows.NativeMethods.WindowShowStyle.Maximize); I have written the following code to maximize the child browser. childBrowser.ShowWindow(watiN.Trunk.Core.Native.Windows.N...

WatiN pressTab doesn't press tab

Has anyone found a means to press tab with watiN in Internet explorer? ...

Watin testing of FckEditor

I have been working on the integration testing of a webapp using watin. The webapp uses fckeditor as one of the richtext controls. Here is the piece of html of the viewsource of my webapp that includes fckeditor iframe id="ctl00_HeaderMain_txtSafetyNetDescription___Frame" src="/FCKEditor/editor/fckeditor.html?InstanceName=ctl00_Header...

How to disable a .DLL's console output?

Hello everyone. I used to use WatiN for my Web Automation project. But, IE looked slow to me. I tried to use WatiN with FF projects, but it seems WatiN with Firefox is not as powerful as WatiN with IE. Before I though this, I researched how to use WatiN in Firefox 3.5. Because WatiN comes with jssh for FF 2.x and FF 3.x. When I use Wat...

Fileuploader.set(..filename..) does it work only when the system window is active and not locked?

Hi All, I have the below automated code using WATiN. ... IE.Settings.WaitForCompleteTimeOut = 360; IE.Settings.MakeNewIeInstanceVisible = false; IE browser = new IE(); browser.GoTo("my web site that has uploader"); browser.FileUpload(Find.ById("FileUploader")).Set("File name and location"); browser.Button(Find.ById("btnNext")).Click();...

Hiding Internet Explorer when WatiN is run

I would like to know how I can prevent Internet Explorer from firing up every time I run my console application which uses WatiN for testing live sites. When I run my console application it fires up internet explore and runs through all the tests that I have created using WatiN. What I want is for my console application to run through...

Watin - problems with page redirects

I'am trying out Watind. I am having problems with a Login page og the applciation, which automatically redirects to the main page (without any user intervention). It looks like WatiN has troubles with this. Wehn I Invoke: IE ie = new IE("http://localhost/MyApp/Login.aspx"); The browser opens, it redirects to "Main.aspx", but Watin time...

Get async postback state for WatiN test

This post below pretty much says it all. The only issue is the solution (I'm looking at Randy's solution in the comments section) is ASP.Net specific and I'm testing a ColdFusion website using WatiN. So I need a solution that will work with ColdFusion… http://pushpontech.blogspot.com/2008/04/ajax-issues-with-watin.html I know I could u...

Waiting for a text change in WatiN

I am trying to test a web page that has ajax calls to update a price. An ajax call is fired on page load to update an initially empty div. This is the extension method I'm using to wait for a change in the inner text of the div. public static void WaitForTextChange(this IE ie, string id) { string old = ie.Element(id).Text; ie.E...

Accessing multiple divs using Watin

I was trying to retrieve multiple divs which have the same class name using watin. I am not able to initalize a DivCollection object and use it for this. Can someone please tell me the parameters that needs to be passed to initialize a DivCollection. ...

Silverlight Automation Similar to Watin

I am considering porting a WPF application to Silverlight. However, the WPF application uses Watin to spawn IE processes and automate certain tasks. My question is if there is a way to automate tasks in Silverlight by spawning popups and performing tasks in them similar to how you would with Watin. ...

Finding an element inside another

Hi In a UI component I have a wrapper called "main_calendar" and inside there are several child nodes I want to retrieve. Using watin how do I narrow down the search of a specific element inside another one? Thanks in advance Bruno ...

WatiN through TFS on Windows 2008 Server

Hello, I'm trying to run WatiN tests through continuous build on TFS, but I can't get it to work. The errror I get is following: WatiN.Core.Exceptions.IENotFoundException : Could not find an IE window matching constraint: Timeout while waiting to attach to newly created instance of IE.. Search expired after '30' seconds. at WatiN...

Compound or chain "find by" methods using WatiN

WatiN has several helpful find by methods, but is it possible to chain or compound them? Specifically I'd like to find link by name that is also near another piece of text. ...

Using WatiN through MbUnit to test ASP .Net MVC web application

I am trying to apply some WatiN UI tests to my new ASP .Net MVC application, running the WatiN tests through MbUnit, but am having some difficulties. If I follow the instructions (exactly) on this page, then the google homepage loads, up the text is inserted, the search is done and the test passes. (no problem here). However, when I si...

Watin: Search in children of an element

I want to do a "two step" search using Watin. For example I would like to search for a ul-tag having class "abc". Then I would like to search for a certain li-tag inside that element. The code might look like this: ie.ElementWithTag("ul", Find.ByClass("abc")).ElementsWithTag("li", Find.ByXYZ()); But Element does not have an ElementWit...

How can i access my own custom tag using WatiN

Suppose, if i have a element like this in page <ele id="g" type="elebox"> I want to use custom type for this, I tried to use ElementContainer for creating a custom type and use ElementOfType to find this control in the document. But it is not seems to be working out. [ElementTag("ele")] public class Ele : ElementContainer<Element> {...

Watin: Clicking on a element works in debug mode but not otherwise

I've below code which basically clicks on a Click event present a table, browser.Frame("f").Element("Table1").Click(); it works properly when during debug mode (like if i put a break point and execute it). But, it does not work when i run it in a flow, I've used SimpleTimer to wait until Settings.WaitForCompleteTimeOut, but no use. A...

What is the best way to crawl a login based sites?

I've to automate a file download activity from a website (similar to, let's say, yahoomail.com). To reach a page which has this file download link, i've to login, jump from page to page to provide some parameters like dates etc., and finally click on download link. I am thinking of three approaches: Using WatIN and develop a windows s...