<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	>

<channel>
	<title>Test Automation Blog &#187; firefox</title>
	<atom:link href="http://testautomationblog.com/tag/firefox/feed/" rel="self" type="application/rss+xml" />
	<link>http://testautomationblog.com</link>
	<description>On software test automation and quality assurance</description>
	<lastBuildDate>Sun, 16 May 2010 09:33:02 +0000</lastBuildDate>
	<generator>http://wordpress.org/?v=2.9.2</generator>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
			<item>
		<title>The Hidden Firefox Profile in Selenium RC Server</title>
		<link>http://testautomationblog.com/2010/05/05/the-hidden-firefox-profile-in-selenium-rc-server/</link>
		<comments>http://testautomationblog.com/2010/05/05/the-hidden-firefox-profile-in-selenium-rc-server/#comments</comments>
		<pubDate>Wed, 05 May 2010 19:24:21 +0000</pubDate>
		<dc:creator>TAB</dc:creator>
				<category><![CDATA[Tips]]></category>
		<category><![CDATA[automation problems]]></category>
		<category><![CDATA[capture network traffic]]></category>
		<category><![CDATA[firefox]]></category>
		<category><![CDATA[firefox profile template]]></category>
		<category><![CDATA[Selenium]]></category>
		<category><![CDATA[Tips & Tricks]]></category>

		<guid isPermaLink="false">http://testautomationblog.com/?p=210</guid>
		<description><![CDATA[You might not know that Selenium provides a feature which allows you to capture the network traffic during a test. Another useful Selenium feature I use is the ability to start the RC server by providing a specific Firefox profile for running the tests. The problem is that those two features do not work together.]]></description>
			<content:encoded><![CDATA[<p style="text-align: center;"><img class="aligncenter size-full wp-image-222" title="Image (c) Arthur Caranta (Arthur40A)" src="http://testautomationblog.com/wp-content/uploads/2010/05/selenium_capture_network_traffic.jpg" alt="Image (c) Arthur Caranta (Arthur40A)" width="300" height="388" /></p>
<p>You might not know that Selenium provides a feature which allows you to capture the network traffic during a test. This might be handy in some cases - for example if you want to check the HTTP response headers returned by the server for some reason or to verify that a specific HTTP request is triggered during a test. I use it for example to verify that a web analytics request is properly triggered on a particular web page.<br />
To use this feature you must start your tests by providing a special option to the start method, i.e.  <strong>selenium.start("captureNetworkTraffic=true");</strong></p>
<p>Another useful Selenium feature I use is the ability to start the RC server by providing a specific Firefox profile for running the tests. Your normal Firefox settings are not used when running tests in <em>*chrome</em> mode. If you want to have a specific Firefox plugin active, or if for example you must use a proxy to access the tested pages, you have to use the <strong>-firefoxProfileTemplate</strong> setting when starting the Selenium server and provide the path to a custom Firefox profile folder that contains all the settings and plugins you want to use.</p>
<p>The problem is that those two features do not work together - when I use the captureNetworkTraffic=true option, I always get some generic Firefox profile and not the one I provide in the firefoxProfileTemplate parameter.</p>
<p>Here is my workaround for this problem. It turns out that inside the Selenium RC server jar there is a folder called <em>customProfileDirCUSTFFCHROME</em>, which contains the small generic firefox profile, used in this case and probably also in the case when you don't provide a custom Firefox profile.</p>
<p>If you want to capture the network traffic and still use a custom Firefox profile,  here  is how you can hack your selenium-server.jar to include a  custom profile.</p>
<ul>
<li>Extract the<em> customProfileDirCUSTFFCHROME</em> folder from selenium-server.jar</li>
<li>Close all Firefox processes. Start Firefox with the <em>-profilemanager</em> option.</li>
<li>Choose 'Create Profile' from the dialog that appears, click 'Choose Folder' and select the folder extracted  from the jar file.This way you will use the profile provided by selenium as a starting point. You can then make configuration changes, add plugins etc.</li>
<li>When you exit firefox, pack all the changed files from the extracted profile folder back into the jar file. Now selenium will always use your custom profile</li>
</ul>
<p>I tested this with Selenium 1.0.3. Works like a charm.</p>
]]></content:encoded>
			<wfw:commentRss>http://testautomationblog.com/2010/05/05/the-hidden-firefox-profile-in-selenium-rc-server/feed/</wfw:commentRss>
		<slash:comments>3</slash:comments>
		</item>
		<item>
		<title>Selenium RC 1.0.3 &#8211; To Upgrade Or Not</title>
		<link>http://testautomationblog.com/2010/03/16/selenium-rc-1-0-3-to-upgrade-or-no/</link>
		<comments>http://testautomationblog.com/2010/03/16/selenium-rc-1-0-3-to-upgrade-or-no/#comments</comments>
		<pubDate>Tue, 16 Mar 2010 18:27:09 +0000</pubDate>
		<dc:creator>TAB</dc:creator>
				<category><![CDATA[News]]></category>
		<category><![CDATA[Test Tool Reviews]]></category>
		<category><![CDATA[automation problems]]></category>
		<category><![CDATA[bugs]]></category>
		<category><![CDATA[firefox]]></category>
		<category><![CDATA[Selenium]]></category>

		<guid isPermaLink="false">http://testautomationblog.com/?p=192</guid>
		<description><![CDATA[... my advise would be – If you have your tests running smoothly on 1.0.1 and you don't need Snow Leopard and/or FF 3.6 support yet, don't bother upgrading for now ...]]></description>
			<content:encoded><![CDATA[<p style="text-align: center;"><img class="aligncenter size-full wp-image-197" title="selenium-automation" src="http://testautomationblog.com/wp-content/uploads/2010/03/selenium-automation.jpg" alt="Image (c) George Rex" width="308" height="410" /></p>
<p style="text-align: left;"><a href="http://testautomationblog.com/wp-content/uploads/2010/03/selenium-automation.jpg"><br />
</a>Having used the 1.0.3 version of Selenium RC for several weeks  I now have an overall impression of the new release. The thing that bugged me most was that the upgrade was not as smooth as I hoped  - several tests that previously worked fine with 1.0.1  started to fail with 1.0.3.  We were able to relatively quickly  find workarounds for what seem to be bugs introduced in the new release. Here are two links to the Selenium issue database  in case you run into the same or similar problems - <a href="http://code.google.com/p/selenium/issues/detail?id=400" target="_blank">400 </a>and <a href="http://code.google.com/p/selenium/issues/detail?id=408" target="_blank">408</a>; look for 'XHR ERROR' exceptions in your logs when opening URLs.</p>
<p style="text-align: left;">With the workarounds our tests became as stable as before – not better and not worse. The new version did not really bring any noticeable improvements for me – I have not yet moved to Firefox 3.6 and I am not a Mac user. So my advise would be – If you have your tests running smoothly on 1.0.1 and you don't need Snow Leopard and/or FF 3.6 support yet, don't bother upgrading for now.  There might be a new release on the horizon.</p>
]]></content:encoded>
			<wfw:commentRss>http://testautomationblog.com/2010/03/16/selenium-rc-1-0-3-to-upgrade-or-no/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Test Selenium XPath Expressions Directly in Firefox</title>
		<link>http://testautomationblog.com/2010/01/17/test-selenium-xpath-expressions-directly-in-firefox/</link>
		<comments>http://testautomationblog.com/2010/01/17/test-selenium-xpath-expressions-directly-in-firefox/#comments</comments>
		<pubDate>Sun, 17 Jan 2010 20:40:13 +0000</pubDate>
		<dc:creator>TAB</dc:creator>
				<category><![CDATA[Test Tool Reviews]]></category>
		<category><![CDATA[Tips]]></category>
		<category><![CDATA[automation tools]]></category>
		<category><![CDATA[firefox]]></category>
		<category><![CDATA[Selenium]]></category>
		<category><![CDATA[test tools]]></category>

		<guid isPermaLink="false">http://testautomationblog.com/?p=178</guid>
		<description><![CDATA[

XPather is a small Firefox extension, which I find indispensable (together with Firebug) when writing Selenium tests.
It adds a 'Show in Xpather...' item to the context menu for all the UI elements on the web page. When selected this option opens a small 'XPather Browser' window showing a  very,  very long XPath expression [...]]]></description>
			<content:encoded><![CDATA[<p><!-- 		@page { margin: 0.79in } 		P { margin-bottom: 0.08in } --></p>
<p style="text-align: center;"><img class="aligncenter size-full wp-image-180" title="xPather" src="http://testautomationblog.com/wp-content/uploads/2010/01/xPather.png" alt="" width="505" height="400" /></p>
<p><a href="http://xpath.alephzarro.com/" target="_blank">XPather</a> is a small Firefox extension, which I find indispensable (together with Firebug) when writing Selenium tests.</p>
<p>It adds a<em> 'Show in Xpather...'</em> item to the context menu for all the UI elements on the web page. When selected this option opens a small<em> 'XPather Browser'</em> window showing a  very,  very long XPath expression which selects the element you chose.</p>
<p>Like <strong>/html/body/table[2]/tbody/tr[2]/td[2]/div[@id='login']/form[@id='gaia_loginform']/div[@id='gaia_loginbox']/table/tbody/tr/td/div/table[@id='gaia_table']/tbody/tr[8]/td[2]/input</strong>, which is the expression you get when you select the 'Sign in' button on the login page of Gmail. Of course you can write your own expressions and test to see what is selected on  the page.  So you can opt to use for example <strong>//input[@name='signIn']</strong>, which is much shorter and better way to locate the same button. I use XPather mostly to interactively test complex expressions whenever I am trying to locate some hard-to-find object on the web page.</p>
]]></content:encoded>
			<wfw:commentRss>http://testautomationblog.com/2010/01/17/test-selenium-xpath-expressions-directly-in-firefox/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Selecting Unnamed Pop-up Windows in Selenium</title>
		<link>http://testautomationblog.com/2009/10/08/selecting-unnamed-pop-up-windows-in-selenium/</link>
		<comments>http://testautomationblog.com/2009/10/08/selecting-unnamed-pop-up-windows-in-selenium/#comments</comments>
		<pubDate>Thu, 08 Oct 2009 18:11:04 +0000</pubDate>
		<dc:creator>TAB</dc:creator>
				<category><![CDATA[Tips]]></category>
		<category><![CDATA[automation problems]]></category>
		<category><![CDATA[Code]]></category>
		<category><![CDATA[firefox]]></category>
		<category><![CDATA[IE]]></category>
		<category><![CDATA[Java]]></category>
		<category><![CDATA[Pop-Up]]></category>
		<category><![CDATA[Selenium]]></category>
		<category><![CDATA[Tips & Tricks]]></category>

		<guid isPermaLink="false">http://testautomationblog.com/?p=133</guid>
		<description><![CDATA[If the application you are testing tends to open new browser windows using the target="_blank" technique, you might have some problems with Selenium.]]></description>
			<content:encoded><![CDATA[<p><em>If the application you are testing tends to open new browser windows using the target="_blank" technique, you might have some problems with Selenium.</em></p>
<p>One of the reasons I find <a href="http://seleniumhq.org/" target="_blank">Selenium</a> a great test automation tool for the web  is that it lets you easily run your test scripts on different browsers without too much effort. Most scripts will run smoothly on IE, Firefox and even on more exotic browsers like Safari, Opera and Chrome without needing browser-specific code or having to tweak the test for a particular browser.  One of the few areas where you are likely to face problems is the handling of pop-up windows.  If the application you are testing tends to open new browser windows using the <strong>target="_blank" </strong>technique, you might have some problems with Selenium. The standard <strong>.selectWindow()</strong> method provided by Selenium requires either a title of the pop-up window (which is often the same as the title of the main window) or a name or a variable name (which are both missing, when the window is opened using a target="_blank" link).</p>
<p>You will need a workaround to select such windows and unfortunately the workarounds do not always work the same for all browsers. The following code snippets might be useful if you run into the same problem. They are tested on the <strong>*chrome</strong> and <strong>*iehta</strong> Selenium modes (with Internet Explorer 7 and Firefox 3).</p>
<p>Here is how you can select the pop-up window which is opened after a target="_blank" link is clicked. This actually combines several hacks and workarounds, but works at the end (at least for me):</p>
<pre class="java">        <span style="color: #808080; font-style: italic;">//A hack to select unnamed pop-up windows</span>
        <span style="color: #b1b100;">if</span> <span style="color: #66cc66;">&#40;</span>browser.<span style="color: #006600;">equals</span><span style="color: #66cc66;">&#40;</span><span style="color: #ff0000;">&quot;*iehta&quot;</span><span style="color: #66cc66;">&#41;</span><span style="color: #66cc66;">&#41;</span><span style="color: #66cc66;">&#123;</span>
            <span style="color: #808080; font-style: italic;">//Find out if Selenium substituted the blank target...</span>
            <span style="color: #b1b100;">if</span> <span style="color: #66cc66;">&#40;</span>selenium.<span style="color: #006600;">isElementPresent</span><span style="color: #66cc66;">&#40;</span>
                       <span style="color: #ff0000;">&quot;//a[starts-with(@target,'selenium_blank')]&quot;</span><span style="color: #66cc66;">&#41;</span><span style="color: #66cc66;">&#41;</span> <span style="color: #66cc66;">&#123;</span>
                <span style="color: #808080; font-style: italic;">// ...and make it notice the new window on IE</span>
                selenium.<span style="color: #006600;">openWindow</span><span style="color: #66cc66;">&#40;</span><span style="color: #ff0000;">&quot;&quot;</span>, selenium.<span style="color: #006600;">getAttribute</span><span style="color: #66cc66;">&#40;</span>
                      <span style="color: #ff0000;">&quot;//a[starts-with(@target,'selenium_blank')]@target&quot;</span><span style="color: #66cc66;">&#41;</span><span style="color: #66cc66;">&#41;</span>;
            <span style="color: #66cc66;">&#125;</span>
        <span style="color: #66cc66;">&#125;</span>
        <a href="http://www.google.com/search?hl=en&amp;q=allinurl%3AString+java.sun.com&amp;btnI=I%27m%20Feeling%20Lucky"><span style="color: #aaaadd; font-weight: bold;">String</span></a> <span style="color: #66cc66;">&#91;</span><span style="color: #66cc66;">&#93;</span> winNames = selenium.<span style="color: #006600;">getAllWindowNames</span><span style="color: #66cc66;">&#40;</span><span style="color: #66cc66;">&#41;</span>;
        <span style="color: #808080; font-style: italic;">//the last one is the pop-up window we want</span>
        selenium.<span style="color: #006600;">waitForPopUp</span><span style="color: #66cc66;">&#40;</span>winNames<span style="color: #66cc66;">&#91;</span>winNames.<span style="color: #006600;">length</span><span style="color: #cc66cc;">-1</span><span style="color: #66cc66;">&#93;</span>, timeout<span style="color: #66cc66;">&#41;</span>;
        selenium.<span style="color: #006600;">selectWindow</span><span style="color: #66cc66;">&#40;</span>winNames<span style="color: #66cc66;">&#91;</span>winNames.<span style="color: #006600;">length</span><span style="color: #cc66cc;">-1</span><span style="color: #66cc66;">&#93;</span><span style="color: #66cc66;">&#41;</span>;</pre>
<p>And here is how you can go back to the main window after you finished working with the pop-up:</p>
<pre class="java">        <a href="http://www.google.com/search?hl=en&amp;q=allinurl%3AString+java.sun.com&amp;btnI=I%27m%20Feeling%20Lucky"><span style="color: #aaaadd; font-weight: bold;">String</span></a> <span style="color: #66cc66;">&#91;</span><span style="color: #66cc66;">&#93;</span> winTitles = selenium.<span style="color: #006600;">getAllWindowTitles</span><span style="color: #66cc66;">&#40;</span><span style="color: #66cc66;">&#41;</span>;
        selenium.<span style="color: #006600;">selectWindow</span><span style="color: #66cc66;">&#40;</span>winTitles<span style="color: #66cc66;">&#91;</span><span style="color: #cc66cc;">0</span><span style="color: #66cc66;">&#93;</span><span style="color: #66cc66;">&#41;</span>;</pre>
]]></content:encoded>
			<wfw:commentRss>http://testautomationblog.com/2009/10/08/selecting-unnamed-pop-up-windows-in-selenium/feed/</wfw:commentRss>
		<slash:comments>3</slash:comments>
		</item>
		<item>
		<title>TestPartner 6 Review &#8211; Visual Tests Redux</title>
		<link>http://testautomationblog.com/2009/04/06/testpartner-review-visual-tests-redux/</link>
		<comments>http://testautomationblog.com/2009/04/06/testpartner-review-visual-tests-redux/#comments</comments>
		<pubDate>Mon, 06 Apr 2009 11:24:51 +0000</pubDate>
		<dc:creator>TAB</dc:creator>
				<category><![CDATA[Test Tool Reviews]]></category>
		<category><![CDATA[automation problems]]></category>
		<category><![CDATA[firefox]]></category>
		<category><![CDATA[IE]]></category>
		<category><![CDATA[record and playback]]></category>
		<category><![CDATA[review]]></category>
		<category><![CDATA[TestPartner]]></category>

		<guid isPermaLink="false">http://testautomationblog.com/?p=60</guid>
		<description><![CDATA[I realized that I was not fair in my previous test,  as I used the last version of Firefox, which unfortunately is not officially supported by TestPartner. To give it a second chance I decided to repeat the test with Internet Explorer. ]]></description>
			<content:encoded><![CDATA[<p><em>Recording does not work, even with IE</em></p>
<p class="MsoNormal"> I realized that I was not fair in my <a href="http://testautomationblog.com/2009/04/03/testpartner-review-visual-tests/" target="_blank">previous test</a>,  as I used the last version of Firefox, which unfortunately is not officially supported by TestPartner. To give it a second chance, I decided to repeat the test with Internet Explorer.  I re-recorded the same scenario, but this time in IE and tried to replay it.</p>
<p class="MsoNormal"> I got a better result, but only slightly. The recorded script was able to log-in, but could not click the button to create a new mail:</p>
<div class="mceTemp mceIEcenter"><a href="http://testautomationblog.com/wp-content/uploads/2009/04/failed-in-ie.png"><img class="aligncenter size-full wp-image-62" title="failed-in-ie" src="http://testautomationblog.com/wp-content/uploads/2009/04/failed-in-ie.png" alt="failed-in-ie" width="506" height="76" /></a></div>
<p class="MsoNormal">The playback failed at step 12, where the tool tries to ‘Attach’ to an HTML frame, identified with ‘<em>Name=c36gxk9p2bo3a</em>’. Attaching to a UI control in TestPartner means simply declaring that the subsequent actions in the script will be executed within this control.  <em>c36gxk9p2bo3a</em> is a generated name which changes each time when you enter GMail.  This was the reason the script could not find the frame, when trying to replay.</p>
<p class="MsoNormal"> If I had to code this script by hand, I would omit this step altogether. Usually it is sufficient to only attach to the browser window and not to specific frames within it. Also, I would not locate the other controls by ID and screen coordinates as the recording did in steps 13 and 14. This will likely fail too, even if the problematic step 12 is fixed.</p>
]]></content:encoded>
			<wfw:commentRss>http://testautomationblog.com/2009/04/06/testpartner-review-visual-tests-redux/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
	</channel>
</rss>
