<?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>The Joy of Hack &#187; Testing</title>
	<atom:link href="http://www.aijazansari.com/tag/testing/feed/" rel="self" type="application/rss+xml" />
	<link>http://www.aijazansari.com</link>
	<description>For people who like to make things</description>
	<lastBuildDate>Tue, 20 Jul 2010 13:20:08 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	
		<item>
		<title>The Performance Cost of Using WordPress</title>
		<link>http://www.aijazansari.com/2010/03/31/performance-cost-of-using-wordpress/</link>
		<comments>http://www.aijazansari.com/2010/03/31/performance-cost-of-using-wordpress/#comments</comments>
		<pubDate>Wed, 31 Mar 2010 17:57:48 +0000</pubDate>
		<dc:creator>Aijaz Ansari</dc:creator>
				<category><![CDATA[Computers]]></category>
		<category><![CDATA[Apache]]></category>
		<category><![CDATA[Caching]]></category>
		<category><![CDATA[DNS]]></category>
		<category><![CDATA[Efficiency]]></category>
		<category><![CDATA[Etag]]></category>
		<category><![CDATA[HTTP]]></category>
		<category><![CDATA[Metrics]]></category>
		<category><![CDATA[Programming]]></category>
		<category><![CDATA[Safari Web Browser]]></category>
		<category><![CDATA[Spiders]]></category>
		<category><![CDATA[TaskForest]]></category>
		<category><![CDATA[Testing]]></category>
		<category><![CDATA[Websites]]></category>
		<category><![CDATA[WordPress]]></category>

		<guid isPermaLink="false">http://www.aijazansari.com/?p=531</guid>
		<description><![CDATA[I recently tried to switch a website over from a homegrown content management system to WordPress.  The results were thoroughly disheartening.  This post illustrates the steps I took, and how I managed to move in the opposite direction and optimize my site even more.  ]]></description>
			<content:encoded><![CDATA[<p>Happy with my experience with a custom WordPress installation for this blog, I decided to try using the blogging platform for the <a title="TaskForest Job Scheduler" href="http://www.taskforest.com/">TaskForest</a> website.  The two main reasons were the ease of creating RSS feeds and the ability for users to comment on posts or articles.  After a few days of tinkering around, I&#8217;ve come to the conclusion that, at least for TaskForest, WordPress would cause more problems than it would solve. Here&#8217;s how I came to that conclusion:</p>
<h2>Setting up a Sandbox Domain</h2>
<p>The first step in trying out WordPress was to set up a new domain just for testing out the WordPress installation.  This way, I wouldn&#8217;t affect the taskforest.com domain during my experiments.  I happen to run my own name servers using Daniel Bernstein&#8217;s <a href="http://cr.yp.to/djbdns.html"><em>tinydns</em></a>, so I decided to create a new domain called <em>tf.enoor.com</em>, a subdomain of my defunct company&#8217;s domain.  Since I use bluehost.com&#8217;s WordPress hosting service, I had to make their name servers responsible for the domain.  All that&#8217;s needed is adding the following two lines to <em>/etc/tinydns/root/data</em>:</p>
<pre class="brush: plain;">
&amp;tf.enoor.com:74.220.195.31:ns1.bluehost.com:300
&amp;tf.enoor.com:69.89.16.4:ns2.bluehost.com:300
</pre>
<h2>Selecting a Theme</h2>
<p>After setting up WordPress, the next step was to select a theme.  I wanted something similar to TaskForest&#8217;s current design, so I chose the remarkably customizable <a title="Suffusion" href="http://www.aquoid.com/news/themes/suffusion/">Suffusion</a> theme.  After some tinkering I was able to get a site that was quite similar to the original, with one compromise &#8211; I could get either the logo or the site&#8217;s name in the header, but not both.  Not the way they are on the current site.  It&#8217;s quite important that the site&#8217;s name appear in the header, because that helps with Search Engine Ranking.  So with a heavy heart I decided to omit the logo.</p>
<h2>The Problem with Content</h2>
<p>TaskForest ships with its own web server to support <a href="http://en.wikipedia.org/wiki/Representational_State_Transfer">REST</a> interface.  As part of the included website is all the documentation for the system. Just like the code, this documentation is under source control, and it&#8217;s also used to populate the taskforest.com website.  This way, I can ensure that both the taskforest.com website and a user&#8217;s local install have the most up-to-date docs, as long as the user is running the latest version of the software.  What this also means is that I have a few dozen webpages that need to be transfered to WordPress before the new site can go live.  I was already resigned to the fact that the URLs of these pages would be different &#8211; the current site has URLs that look like <em>http://www.taskforest.com/about.html</em>, but the default WordPress installation would use URLs that look like <em>http://www.taskforest.com/about/</em>.  It&#8217;s not a huge deal, but I prefer my way.</p>
<p>The bigger issue is that when a new version of the software is released, the pages change.  The current build process ensures that the client website and the taskforest.com website stay in sync.  Now if I use WordPress, I don&#8217;t want to manually edit the pages using the WP admin site.  I need to install a new plugin that handles inclusion of files.  So, I installed the WP Include plugin.  I&#8217;d have to change my build process, but I could get it to work.</p>
<h2>Putting It All Together</h2>
<p>Okay, so I got the themes and plugins installed, and I&#8217;ve got the process worked out.  It was then time to try a proof of concept with a single page.  It worked just as expected, but the site seemed very sluggish.  I made sure I didn&#8217;t have anything enabled that I didn&#8217;t need.  Still, the site was noticeably slower than the existing site, and that&#8217;s with only one non-blank page and zero blog posts.  I thought that maybe the problem was that the bluehost.com shared server was too slow.  I just happened to have an unused server in the same data center that hosts taskforest.com.  The same kind of server as well. It took the better part of the morning, but I installed PHP, mysql and WordPress on that server.  In installed PHP as a static module within Apache, for optimal performance.  Even then, on a pristine machine running nothing else, it was <strong>slow</strong>.</p>
<h2>How Slow is Slow?</h2>
<p>Anyone who knows me knows that I&#8217;m an Engineer, and as an Engineer I like metrics.  I wanted to know that it wasn&#8217;t just my own bias that was penalizing WordPress over my established way of doing things.  So, I looked at the Safari web browser on the Mac.  Safari has a really useful feature called the Web Inspector that, among other things, displays the amount of time it takes for different parts of a page to load.  The numbers were very surprising.  With WordPress, a new page would take <strong>1.75</strong> seconds to load &#8211; an eternity on a high-speed broadband connection.  A subsequent request of the same page would take about <strong>700ms</strong>. Switching to the TaskForest website&#8217;s strategy would take about <strong>800ms</strong> for a new page, and <strong>275ms</strong> for a cached page.  That&#8217;s more than a <strong>20</strong><strong>0%</strong> increase in speed!  The TaskForest website used a preprocessor that allowed for including header files.  It ran under mod_perl.  I decided to write a spider that crawled the website and convert everything to static pages, and serve those pages without mod_perl.  With this enhancement, the results were even better.  I saw a <strong>400% to 800% speed increase</strong>, with cached pages taking just <strong>140ms</strong> to load.</p>
<p>One of the reasons WordPress&#8217;s numbers were so poor is that if articles like <a href="http://www.codinghorror.com/blog/2008/04/behold-wordpress-destroyer-of-cpus.html">this one</a> are still correct, WordPerfect does not cache the content of pages by default.  Resources within the HTML page, like images or javascript files seem to be cached, but every page still does upto 120 database accesses depending on the setup.  Apache is a lot better at caching requests for static HTML pages.  Even the TaskForest webserver used for the REST API, caches data very intelligently using the HTTP headers.</p>
<h2>What Does This All Mean?</h2>
<p>Given the amount of compromises I would have to make in the design, layout and build process, switching to WordPress would have been very painful.  However, with the performance hit the site would be taking, it seems unlikely that I&#8217;ll switch to WP any for the TaskForest website any time soon.  I think I&#8217;d rather write a script to generate RSS feeds on demand and automatically submit the feed to feed notification sites like pingomatic. I think this was a great learning experience that will help me with similar decisions in the future.  And I also got to write a cool spider and increase the speed of the TaskForest web site.</p>
<div id="attachment_559" class="wp-caption alignnone" style="width: 595px"><a rel="attachment wp-att-559" href="http://www.aijazansari.com/2010/03/31/performance-cost-of-using-wordpress/webinspector/"><img class="size-large wp-image-559" title="Safari's Web Inspector" src="http://www.aijazansari.com/wp-content/uploads/2010/03/WebInspector-585x351.png" alt="" width="585" height="351" /></a><p class="wp-caption-text">Safari&#39;s Web Inspector</p></div>
]]></content:encoded>
			<wfw:commentRss>http://www.aijazansari.com/2010/03/31/performance-cost-of-using-wordpress/feed/</wfw:commentRss>
		<slash:comments>4</slash:comments>
		</item>
		<item>
		<title>Adding A Grid To Your Websites</title>
		<link>http://www.aijazansari.com/2010/03/05/adding-a-grid-to-your-websites/</link>
		<comments>http://www.aijazansari.com/2010/03/05/adding-a-grid-to-your-websites/#comments</comments>
		<pubDate>Sat, 06 Mar 2010 05:26:47 +0000</pubDate>
		<dc:creator>Aijaz Ansari</dc:creator>
				<category><![CDATA[Computers]]></category>
		<category><![CDATA[Design]]></category>
		<category><![CDATA[Grids]]></category>
		<category><![CDATA[Testing]]></category>
		<category><![CDATA[Web]]></category>

		<guid isPermaLink="false">http://www.aijazansari.com/?p=492</guid>
		<description><![CDATA[The #grid website has a great tool for web designers -it &#8220;inserts a layout grid in web pages, allows you to hold it in place, and toggle between displaying it in the foreground or background.&#8221;  Go to their website and have a look.  It&#8217;s pretty impressive.  Simple, but impressive.  I think I&#8217;m gonna give this [...]]]></description>
			<content:encoded><![CDATA[<div id="attachment_493" class="wp-caption alignleft" style="width: 199px"><a rel="attachment wp-att-493" href="http://www.aijazansari.com/2010/03/05/adding-a-grid-to-your-websites/20100305-_jaz1036-edit/"><img class="size-medium wp-image-493" title="190 S. La Salle St." src="http://www.aijazansari.com/wp-content/uploads/2010/03/20100305-_JAZ1036-Edit-189x285.jpg" alt="190 S. La Salle St." width="189" height="285" /></a><p class="wp-caption-text">190 S. La Salle St. - Downtown Chicago</p></div>
<p>The <a href="http://hashgrid.com/">#grid</a> website has a great tool for web designers -it &#8220;inserts a layout grid in web pages, allows you to hold it in place, and toggle between displaying it in the foreground or background.&#8221;  Go to their <a href="http://hashgrid.com">website</a> and have a look.  It&#8217;s pretty impressive.  Simple, but impressive.  I think I&#8217;m gonna give this a shot for the next web site I design.  I think it would be really useful in development, not as much in a production environment.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.aijazansari.com/2010/03/05/adding-a-grid-to-your-websites/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Follow up: Google Admits Buzz Was Only Tested Internally</title>
		<link>http://www.aijazansari.com/2010/02/16/follow-up-google-admits-buzz-was-only-tested-internally/</link>
		<comments>http://www.aijazansari.com/2010/02/16/follow-up-google-admits-buzz-was-only-tested-internally/#comments</comments>
		<pubDate>Wed, 17 Feb 2010 04:29:50 +0000</pubDate>
		<dc:creator>Aijaz Ansari</dc:creator>
				<category><![CDATA[Computers]]></category>
		<category><![CDATA[Buzz]]></category>
		<category><![CDATA[Google]]></category>
		<category><![CDATA[Testing]]></category>

		<guid isPermaLink="false">http://www.aijazansari.com/?p=345</guid>
		<description><![CDATA[In yesterday&#8217;s article about Google Buzz, I guessed that &#8220;the problem was that the population for whom the system was designed wasn’t necessarily the only population actually using the system.&#8221;  I gave Google the benefit of the doubt: I am certain Google tested their application thoroughly.  They’ve been known to do extensive usability tests for [...]]]></description>
			<content:encoded><![CDATA[<p><a rel="attachment wp-att-408" href="http://www.aijazansari.com/2010/02/16/follow-up-google-admits-buzz-was-only-tested-internally/3043988249_165091e8e7_b/"><img class="alignleft size-medium wp-image-408" title="Kite Flying on a Summer's Day" src="http://www.aijazansari.com/wp-content/uploads/2010/02/3043988249_165091e8e7_b-190x285.jpg" alt="Kite Flying on a Summer's Day" width="133" height="200" /></a>In <a href="http://www.aijazansari.com/2010/02/15/sometimes-testing-isnt-enough/">yesterday&#8217;s article</a> about Google Buzz, I guessed that &#8220;the problem was that the population for whom the system was designed wasn’t necessarily the only population actually using the system.&#8221;  I gave Google the benefit of the doubt:</p>
<blockquote><p>I am certain Google tested their application thoroughly.  They’ve been known to do extensive usability tests for the seemingly tiniest of changes to their web site.  But even the most well-implemented tests are incomplete if they’re not performed on a statistically representative sample of the audience.</p></blockquote>
<p>But today, the BBC reported that <a href="http://news.bbc.co.uk/2/hi/technology/8517613.stm">Google has admitted that they only tested Buzz internally</a>, and bypassed their regular rigorous testing procedures &#8212; possibly in an attempt to get it out the door as soon as possible. I&#8217;ll let the pundits decide if it did more harm than good to the firm, but it&#8217;s a warning to other software developers: skipping testing can lead to embarrassing failures.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.aijazansari.com/2010/02/16/follow-up-google-admits-buzz-was-only-tested-internally/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Sometimes Testing Isn&#8217;t Enough</title>
		<link>http://www.aijazansari.com/2010/02/15/sometimes-testing-isnt-enough/</link>
		<comments>http://www.aijazansari.com/2010/02/15/sometimes-testing-isnt-enough/#comments</comments>
		<pubDate>Mon, 15 Feb 2010 07:41:07 +0000</pubDate>
		<dc:creator>Aijaz Ansari</dc:creator>
				<category><![CDATA[Computers]]></category>
		<category><![CDATA[Apple]]></category>
		<category><![CDATA[Buzz]]></category>
		<category><![CDATA[Google]]></category>
		<category><![CDATA[iPad]]></category>
		<category><![CDATA[My Software]]></category>
		<category><![CDATA[Privacy]]></category>
		<category><![CDATA[Services]]></category>
		<category><![CDATA[SMS]]></category>
		<category><![CDATA[Testing]]></category>
		<category><![CDATA[Usability]]></category>
		<category><![CDATA[Virgin Mobile]]></category>

		<guid isPermaLink="false">http://www.aijazansari.com/?p=318</guid>
		<description><![CDATA[In the first few days after the release of Google Buzz many people (including myself) criticized Google for exposing their users' private information.  This was a couple of weeks after Apple got a lot flak for their unfortunately-named iPad, and the same week that we heard reports of a woman who broke up with her boyfriend after finding some suggestive text messages on his cell phone - messages that came pre-loaded on the phone.  I think that all these cases were not caused by a lack testing, but by testing the wrong audience.  Let's examine these three cases and see what we can learn from them:]]></description>
			<content:encoded><![CDATA[<p><a rel="attachment wp-att-333" href="http://www.aijazansari.com/2010/02/15/sometimes-testing-isnt-enough/img_7679/"><img class="alignleft size-thumbnail wp-image-333" title="A Bee.  Buzzing." src="http://www.aijazansari.com/wp-content/uploads/2010/02/IMG_7679-170x170.jpg" alt="A Bee.  Buzzing." width="170" height="170" /></a>In the first few days after the release of <a title="Google Buzz" href="http://www.google.com/buzz">Google Buzz</a> many people (including myself) criticized Google for <a title="Google Buzz Has A Huge Privacy Flaw" href="http://www.businessinsider.com/warning-google-buzz-has-a-huge-privacy-flaw-2010-2">exposing their users&#8217; private information</a>.  This was a couple of weeks after Apple got a lot flak for their unfortunately-named iPad, and the same week that we heard <a title="Built-in text messages ruined his life" href="http://www.winnipegfreepress.com/local/built-in-text-messages-ruined-life-says-city-man-83622857.html">reports</a> of a woman who broke up with her boyfriend after finding some suggestive text messages on his cell phone &#8211; messages that came pre-loaded on the phone.  I think that all these cases were not caused by a lack testing, but by testing the wrong audience.  Let&#8217;s examine these three cases and see what we can learn from them:<span id="more-318"></span></p>
<h4>Google Buzz</h4>
<p>Almost immediately after Google started rolling out Buzz to its Gmail clients various blogs reported that there was an egregious flaw in the system that exposed people&#8217;s private contacts to the rest of the world.  When a Gmail user logged in, they were presented with a dialog box that asked them if they wanted an introduction to Buzz or not.  If the user declined, it didn&#8217;t mean that Buzz was disabled &#8211; it only meant that they didn&#8217;t want the intro.  What Google did behind the scenes was that they scanned the user&#8217;s emails and collected the emails of the people with whom the user corresponded most often.  Then, it automatically modified the user&#8217;s Gmail account to &#8216;follow&#8217; those people in Buzz.</p>
<p>But here&#8217;s the thing that infuriated most people &#8211; it made that list of the people that user&#8217;s following public: Anyone who looked at the user&#8217;s public Google profile could see who that person was following.  In other words, anyone looking at that user&#8217;s public profile could see who that user emailed most often.</p>
<p>Now pretend you&#8217;re a reporter who&#8217;s communicating with dissidents in Myanmar or Iran.  Would you want your heretofore anonymous sources made public?  <a title="Google Buzz Privacy Issues Have Real Life Implications" href="http://techcrunch.com/2010/02/12/google-buzz-privacy/">In one reported case</a>, a woman&#8217;s most frequent contacts were her boyfriend and her mother.  Her third-most-frequent contact (with a lot fewer emails) was her abusive ex-husband, from whom she had kept her email address hidden.  But what Google did when they released Buzz is automatically have her follow her ex, and share her shared Google Reader messages, including her location and workplace with her ex.</p>
<p><a title="Google Buzz: Privacy Nightmare" href="http://news.cnet.com/8301-31322_3-10451428-256.html">Another blogger reported</a> that her Android phone uploaded to her public profile a photo that she had taken, but not uploaded. She thought her photo was private, but Google&#8217;s assumption was that if the photo was on her phone, it would be okay to upload it to her public profile.</p>
<p><a title="Watch Out Who You Reply To On Google Buzz" href="http://techcrunch.com/2010/02/11/reply-google-buzz-exposing-email/">The third problem</a> that surfaced in the two days after Buzz was released was that in some cases users thought that they were referencing a person&#8217;s public email address in a buzz (think of it as a retweet or a reply) but in reality were referencing a private email address.  When they selected a person by their name, it wasn&#8217;t clear which email address was linked to that name.  For example, if John Smith&#8217;s public email address is john_smith@example.com, and his personal address is js_123@example.com, and the public address is associated with a Google profile, a Buzz user may inadvertently select the private email address in a buzz, thus exposing John&#8217;s private address to everyone he follows.</p>
<h4>The iPad</h4>
<p>In the minutes after Apple&#8217;s Steve Jobs announced the new mobile appliance&#8217;s name, people started making very funny, original and sometimes vulgar jokes about the name iPad.  I could post them here, but the jokes are old by now.</p>
<h4>Salacious Texts On Samsung Virgin Mobile Phones</h4>
<p>According to <a title="Built-in text messages ruined his life" href="http://www.winnipegfreepress.com/local/built-in-text-messages-ruined-life-says-city-man-83622857.html">this article</a>, a 49 year old man from Winnipeg can no longer have a relationship with the woman he loved because she accused him of cheating on him.  Her proof?  Sexy text messages on his cell phones.  He denied the affair, but couldn&#8217;t explain how they got there.  Only later did he learn that the messages were pre-loaded by Virgin Mobile.</p>
<h4>What Do These Cases Have in Common?</h4>
<p>As an outsider it appears to me that in each of the three cases the problem was that the population for whom the system was designed wasn&#8217;t necessarily the only population actually using the system.  Let&#8217;s look at the Google Buzz case.  If we claim that Google is neither evil nor stupid, what went wrong?  I think there were several assumptions that the Google developers and designers made that were incorrect.</p>
<p>Buzz seemed to have be designed for people who collaborate together in tightly knit groups.  The assumption is that people who want to share information with each other communicate a lot with each other.  In real life that isn&#8217;t always true, and neither is the converse.  In many cases the people that I want to share the most with are people with whom I have so many channels of communication (including the dinner table) that any single channel like email contains a fraction of the actual communication taking place.  Similarly, as in the case of the lady who was hiding her online identity from her ex, the people we communicate with aren&#8217;t always the people we want to share information with.  If Google&#8217;s designers approached their product with that bias, they could have made (and did make) a technically excellent product that worked as they intended, and whose test cases passed, but which did exactly the wrong thing.</p>
<p>I think that that&#8217;s essentially the core problem with the issue of the publication of private photos and email addresses.  The joke in the blogs was that Buzz was designed for an people like engineers at Google, not for people who go to parties and take pictures that they would regret the next morning (and I know they&#8217;re not mutually exclusive groups).  Unlike in the business world and the networks of sites like LinkedIn, people sometimes guard their email addresses jealously and do not want them published without their authorization.</p>
<p>I am certain Google tested their application thoroughly.  They&#8217;ve been known to do extensive usability tests for the seemingly tiniest of changes to their web site.  But even the most well-implemented tests are incomplete if they&#8217;re not performed on a statistically representative sample of the audience.</p>
<p>The same can be said for Apple and Virgin Mobile.  On of the most insightful questions asked after the iPad announcement was, &#8220;Did Apple not have any women on the product naming committee?&#8221;  Did Virgin Mobile think that their only consumers would be teenagers who would find the default text messages cute and funny and have the technical expertise to realize that these messages were pre-loaded?  While Apple seemed to have failed to consider about half of the human race while naming their product, Virgin failed to consider the less savvy part of the population who are their customers.</p>
<p>What I don&#8217;t know is this: Let&#8217;s assume I&#8217;m wrong, and that in all three cases a statistically-representative portion of the population was tested or considered.  If that&#8217;s true, then could these three cases be considered edge conditions?  While a problem could exist in theory could the actual problems be so few that they&#8217;re statistically insignificant?  If you&#8217;re the person whose lost a relationship or now have to worry about being stalked by an ex it doesn&#8217;t really matter.  It&#8217;s affected your life in a significant way.</p>
<h4>What Can Software Developers Learn From This?</h4>
<p>I don&#8217;t think anyone or any company (not even Google) can make the perfect application that pleases everyone.  But I think that there are a few rules of thumb that we should follow, to prevent embarrassing and distressing problems.</p>
<p>First: Applications like these should not take action on behalf of the user.  The system should assume that the user always knows what&#8217;s best for them.  The most the program should do is make suggestions that the user can then decide to obey or ignore.  This is exactly what Google did (among other things) to change Buzz after the huge public outcry.</p>
<p>Second: Features, no matter how well-intentioned, no should never be opt-out.  They should always be opt-in.  Buzz was essentially an opt-out system.  You could be vulnerable by not doing anything. It isn&#8217;t that way now, but it was for those two days when Google&#8217;s reputation took a massive hit.</p>
<p>Third: Designers and service providers need to pay careful attention to who their users actually are.  They&#8217;re not necessarily men, not necessarily tech-savvy teens or professionals looking to increase their network.  They could include people very different from us.</p>
<p>As developers and designers we need to realize that the products we make will be used in manners that we never imagined, by people who we don&#8217;t understand.  If we give our customers the ability to control how our products and services are used, we&#8217;ll be helping them and thus helping ourselves.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.aijazansari.com/2010/02/15/sometimes-testing-isnt-enough/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>Why Should I Use CPAN?</title>
		<link>http://www.aijazansari.com/2010/02/13/why-should-i-use-cpan/</link>
		<comments>http://www.aijazansari.com/2010/02/13/why-should-i-use-cpan/#comments</comments>
		<pubDate>Sun, 14 Feb 2010 01:01:08 +0000</pubDate>
		<dc:creator>Aijaz Ansari</dc:creator>
				<category><![CDATA[Computers]]></category>
		<category><![CDATA[CPAN]]></category>
		<category><![CDATA[Perl]]></category>
		<category><![CDATA[TaskForest]]></category>
		<category><![CDATA[Testing]]></category>

		<guid isPermaLink="false">http://www.aijazansari.com/?p=296</guid>
		<description><![CDATA[Why should a program depend on so many external modules when it could implement what it needs itself?]]></description>
			<content:encoded><![CDATA[<p>I came across some comments made about an open source program that I had written in perl.  The user was complaining about how he couldn&#8217;t get it to install.  The reason was that the program relies on other modules from the archive of open source perl software known as <a href="http://www.cpan.org/">CPAN (Comprehensive Perl Archive Network)</a>, and one of them failed to install.</p>
<p>This got me thinking about the benefits of using third-party libraries in our own code.  Why should a program depend on so many external modules when it could implement what it needs itself?</p>
<p>The answer, in one word, is &#8220;Testing.&#8221;  A well-written piece of software isn&#8217;t considered complete if it doesn&#8217;t have well-documented tests that exercise every part of the program.</p>
<p>There are many common tasks that most programs perform &#8211; such as reading configuration food, performing date arithmetic and writing to log files.  Every popular language has third-party libraries that perform these tasks correctly and reliably.  If I were to try to duplicate them, it would almost certainly result in inferior code; the mature libraries have had the benefits of extensive testing as well as enhancements and fixes of bugs reported by users.  Using third-party software allows me to focus on my program and what makes it unique.</p>
<div id="attachment_297" class="wp-caption alignnone" style="width: 449px"><a rel="attachment wp-att-297" href="http://www.aijazansari.com/2010/02/13/why-should-i-use-cpan/camel/"><img class="size-medium wp-image-297" title="Persuading the Camel" src="http://www.aijazansari.com/wp-content/uploads/2010/02/camel-439x293.jpg" alt="Getting the Camel to Do What You Want" width="439" height="293" /></a><p class="wp-caption-text">Perl can be a little stubborn, sometimes.</p></div>
]]></content:encoded>
			<wfw:commentRss>http://www.aijazansari.com/2010/02/13/why-should-i-use-cpan/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
	</channel>
</rss>
