<?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/"
	xmlns:georss="http://www.georss.org/georss" xmlns:geo="http://www.w3.org/2003/01/geo/wgs84_pos#" xmlns:media="http://search.yahoo.com/mrss/"
	>

<channel>
	<title>Nothing Else, Nothing Less</title>
	<atom:link href="http://antoniosomolinos.wordpress.com/feed/" rel="self" type="application/rss+xml" />
	<link>http://antoniosomolinos.wordpress.com</link>
	<description>Just another WordPress.com weblog</description>
	<lastBuildDate>Tue, 20 Oct 2009 13:24:58 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.com/</generator>
<cloud domain='antoniosomolinos.wordpress.com' port='80' path='/?rsscloud=notify' registerProcedure='' protocol='http-post' />
<image>
		<url>http://s2.wp.com/i/buttonw-com.png</url>
		<title>Nothing Else, Nothing Less</title>
		<link>http://antoniosomolinos.wordpress.com</link>
	</image>
	<atom:link rel="search" type="application/opensearchdescription+xml" href="http://antoniosomolinos.wordpress.com/osd.xml" title="Nothing Else, Nothing Less" />
	<atom:link rel='hub' href='http://antoniosomolinos.wordpress.com/?pushpress=hub'/>
		<item>
		<title>Functional testing scheduled withing Continuous Integration System</title>
		<link>http://antoniosomolinos.wordpress.com/2009/10/20/functional-testing-scheduled-withing-continuous-integration-system/</link>
		<comments>http://antoniosomolinos.wordpress.com/2009/10/20/functional-testing-scheduled-withing-continuous-integration-system/#comments</comments>
		<pubDate>Tue, 20 Oct 2009 12:57:17 +0000</pubDate>
		<dc:creator>antoniosomo</dc:creator>
				<category><![CDATA[Testing and Quality]]></category>
		<category><![CDATA[cruise control junit selenium watij quality testing automated]]></category>

		<guid isPermaLink="false">http://antoniosomolinos.wordpress.com/?p=9</guid>
		<description><![CDATA[After some days fighting against how to set a continuous integration system for testing functional requirements of a java project, I have found a solution. Firstly, we decide to use Selenium as the automation tool because it seemed to be an easy way to get the code of an execution made directly through the browser. [...]<img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=antoniosomolinos.wordpress.com&amp;blog=9983039&amp;post=9&amp;subd=antoniosomolinos&amp;ref=&amp;feed=1" width="1" height="1" />]]></description>
			<content:encoded><![CDATA[<p>After some days fighting against how to set a continuous integration system for testing functional requirements of a java project, I have found a solution.</p>
<p>Firstly, we decide to use Selenium as the automation tool because it seemed to be an easy way to get the code of an execution made directly through the browser.  In order to get this job done, we downloaded the plugin for Firefox and the Selenium Remote Control package to install the server where the testing was going to be performed. We navigate though our application and the plugin recorded all the execution, then we exported the execution as a junit test and we added it to our suite. It seemed to be really easy. We found some directions to add the ant tasks in order to get the Selenium server up, then run the Junits tests and Stop the server. We added that tasks to the build.xml that Cruise Control (CC, our coninuous integration system) run and forced a new build.</p>
<p>Our first issue was that we could start and stop the server but running it through the CC caused some troubles and the junit didnt join it correctly, so an exception was raised all the time. Then we realized that starting the server manually fixed that problem and the junit run correctly in the server&#8230;but then the problem where we stuck definitely appeared. You cannot use IExplorer and RC-Selenium with https requests&#8230;.so we had to find another solution for the problem.</p>
<p>We decided to use WATIJ although</p>
<ol>
<li>Only works with IE (but is our requirement)</li>
<li>Has some incompatibilities with IE7 (but we assumed them)</li>
<li>It does not have a record/playback system (but we assumed it)</li>
</ol>
<p>The only thing you have to do is to add the JAR neccesaries for the compilation to the Ant task in the build.xml of the project&#8230;but of course&#8230;running it using CC was not going to be that easy!</p>
<p>First thing that you can see is that when you run the junit, you cannot see any browser appearing, it is run in the background&#8230;so you have to test first (for example, using eclipse) that the test is developed correctly. Another advice is use the tearDown inherited function of the TestCase class to close the IE, because if any assert fails the IE window stays opened and then the system becomes unstable. Finally we also realized that you MUST perform ONE TEST per CLASS, this is because of the former reason. If you have many tests under the same JUNIT, since the watij function append does not work with IE7,  you have to start IE each time that you have to set initial state of the test and close it at the end. Having this configuration is so easy to fall in an unstable state and get some Exceptions that wil drive you to fail in your tests. We have tested sucessfully the configuration that we recommend.</p>
<p>Nothing else, and nothing less</p>
<br />  <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/antoniosomolinos.wordpress.com/9/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/antoniosomolinos.wordpress.com/9/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/antoniosomolinos.wordpress.com/9/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/antoniosomolinos.wordpress.com/9/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gofacebook/antoniosomolinos.wordpress.com/9/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/facebook/antoniosomolinos.wordpress.com/9/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gotwitter/antoniosomolinos.wordpress.com/9/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/twitter/antoniosomolinos.wordpress.com/9/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/antoniosomolinos.wordpress.com/9/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/antoniosomolinos.wordpress.com/9/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/antoniosomolinos.wordpress.com/9/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/antoniosomolinos.wordpress.com/9/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/antoniosomolinos.wordpress.com/9/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/antoniosomolinos.wordpress.com/9/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=antoniosomolinos.wordpress.com&amp;blog=9983039&amp;post=9&amp;subd=antoniosomolinos&amp;ref=&amp;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://antoniosomolinos.wordpress.com/2009/10/20/functional-testing-scheduled-withing-continuous-integration-system/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
	
		<media:content url="http://0.gravatar.com/avatar/a49ea37e9b79b5924684f23f4bfc263b?s=96&#38;d=identicon&#38;r=G" medium="image">
			<media:title type="html">antoniosomo</media:title>
		</media:content>
	</item>
	</channel>
</rss>
