<?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>Pedro Pimentel &#187; hints</title>
	<atom:link href="http://www.pedropimentel.com/category/hints/feed/" rel="self" type="application/rss+xml" />
	<link>http://www.pedropimentel.com</link>
	<description>Ruby on Rails Evangelist</description>
	<lastBuildDate>Thu, 29 Jul 2010 14:51:53 +0000</lastBuildDate>
	<generator>http://wordpress.org/?v=2.8.4</generator>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
			<item>
		<title>How do I keep Track of what I&#8217;ve learnt</title>
		<link>http://www.pedropimentel.com/2010/07/29/how-do-i-keep-track-of-what-ive-learnt/</link>
		<comments>http://www.pedropimentel.com/2010/07/29/how-do-i-keep-track-of-what-ive-learnt/#comments</comments>
		<pubDate>Thu, 29 Jul 2010 14:51:53 +0000</pubDate>
		<dc:creator>Pedro Pimentel</dc:creator>
				<category><![CDATA[hints]]></category>
		<category><![CDATA[personal]]></category>
		<category><![CDATA[information]]></category>
		<category><![CDATA[learn]]></category>
		<category><![CDATA[techinique]]></category>

		<guid isPermaLink="false">http://www.pedropimentel.com/?p=214</guid>
		<description><![CDATA[
I have something to confess:  I&#8217;m an information addicted. I&#8217;m always reading books, checking out news, following a few hundred blogs, following another few hundred people on twitter and the list just goes on and on. I bet you do the same.
First of all, this is not about how to just pass over your next [...]


Probably Related posts:<ol><li><a href='http://www.pedropimentel.com/2008/06/09/rails-21-whats-new/' rel='bookmark' title='Permanent Link: RELEASED &#8211; &#8220;Rails 2.1 &#8211; What`s new ?&#8221; Book'>RELEASED &#8211; &#8220;Rails 2.1 &#8211; What`s new ?&#8221; Book</a></li>
<li><a href='http://www.pedropimentel.com/2008/10/22/why-i-have-been-away/' rel='bookmark' title='Permanent Link: Why I have been away'>Why I have been away</a></li>
<li><a href='http://www.pedropimentel.com/2008/04/21/google-summer-of-code/' rel='bookmark' title='Permanent Link: Google Summer of Code'>Google Summer of Code</a></li>
</ol>]]></description>
			<content:encoded><![CDATA[<p style="text-align: center;"><a href="http://www.pedropimentel.com/wp-content/uploads/2010/07/imhereforthelearningrevolution.png"><img class="aligncenter size-medium wp-image-235" title="i m here for the learning revolution" src="http://www.pedropimentel.com/wp-content/uploads/2010/07/imhereforthelearningrevolution-360x450.png" alt="i m here for the learning revolution" width="360" height="450" /></a></p>
<p>I have something to confess:  I&#8217;m an information addicted. I&#8217;m always reading books, checking out news, following a few hundred blogs, following another few hundred people on twitter and the list just goes on and on. I bet you do the same.</p>
<p>First of all, this is not about how to just pass over your next university exams but how to keep yourself updated or learn something with all the information we are throw everyday. It&#8217;s not possible (for me at least) to keep track from everything I read.  People like me reads hundreds of information sources, mostly online. Besides that we also read books, attend conferences, meet new people, etc. We are literally bloated by information from everywhere.</p>
<p>how can we manage to digest this huge amount of information we face everyday ?</p>
<p><span id="more-214"></span></p>
<p style="text-align: center;"><a href="http://www.pedropimentel.com/wp-content/uploads/2010/07/sleep-learning.jpg"><img class="aligncenter size-full wp-image-234" title="sleep-learning" src="http://www.pedropimentel.com/wp-content/uploads/2010/07/sleep-learning.jpg" alt="sleep-learning" width="450" height="300" /></a></p>
<p>We all know there&#8217;s no unique answer for that question. Everybody has a different approach when it comes to learn something. Some people prefer to take notes while reading, some people prefer to record audio snippets, some people like to create songs that resemble the information, (your method here). As you might think, I happen to have my own technique (probably not only mine) and it&#8217;s being very useful to me.</p>
<p>I read somewhere else a good analogy: we have two &#8220;<em>databases</em>&#8221; in our brain. One is the short-term memory database and the other is the long-term one.  When we read something, every piece of information goes to our short-term memory which is something like a &#8220;<em>heap</em>&#8221; of unclassified information . As this &#8220;<em>database</em>&#8221; isn&#8217;t classified, our brain doesn&#8217;t know if the information is useful or not.  Later on, it can be even 10 minutes, when we try to recall some information from it, we may not be able to easily do it because isn&#8217;t classified yet. But no worries : how many times happened to you that you remembered something just a few hours later while doing something else? That happens because our searching process is asynchronous.</p>
<p>Ok, our information searching process is asynchronous, so what ? It literally means, your brain is still <em>learning</em> some subject even after you stopped thinking about it. It&#8217;s like dispatching a background process. The <em>problem</em> is you need to constantly remember that subject in order to transfer it to your long-term memory.</p>
<p style="text-align: center;"><a href="http://www.pedropimentel.com/wp-content/uploads/2010/07/learning_to_skate.jpg"><img class="aligncenter size-medium wp-image-236" title="learning_to_skate" src="http://www.pedropimentel.com/wp-content/uploads/2010/07/learning_to_skate-307x450.jpg" alt="learning_to_skate" width="307" height="450" /></a></p>
<p>You can achieve that by keeping a sort of <em>learning log</em>. I&#8217;ve tried many tools to help me keeping track of what I want to learn. For instance, a simple text editor, an iphone app. You just need to ensure you have quick and easy access to it&#8230;.As I&#8217;m a very moody person I keep changing, right now, for instance, I&#8217;m using a folder of my browser&#8217;s favorites bar which I sync across my computers. Sometimes I also use the favorites features from twitter. As I&#8217;m always checking them, I keep remembering the subjects I have demonstrated interest. Most of this links are shortcuts to blog posts, interviews, podcasts, which I may have read/listened only once. But just the fact I&#8217;m recalling the title, it helps me to internally recall the content I read before from that source. In case I don&#8217;t remember what&#8217;s the content is about I just go there and skim over the text so I get the general idea. If even doing so, I don&#8217;t understand the content, then I mark it to read it later using a javascript snippet.</p>
<p>What happens when my <em>learning log</em> stack is getting excessively big ? Just use your common sense! If you get to the point where you always need to recall every item in your list, something is wrong! So, how many items should you have in your list? It may vary from person to person. In my case I found 10 to be a good size. It doesn&#8217;t mean I need to first learn all 10 items and them move to the next 10 items. Some items can be in your list for a relatively long time, it&#8217;s strongly dependent on how complex is the subject and how fast you can learn.</p>
<p>Defining when you &#8220;learned&#8221; something is very subjective. In my opinion, you can&#8217;t know everything. My &#8220;learned&#8221; definition is when I get to the point where I can explain the subject to someone else and they properly understand it. Having a time constraint can help too, like imposing yourself a 15 days limit for the items in your list.</p>
<p>Resources used:</p>
<ul>
<li>Learning log (official way) http://www.csudh.edu/titlev/learninglog.htm</li>
<li>Read it later http://readitlaterlist.com/</li>
</ul>


<p>Probably Related posts:<ol><li><a href='http://www.pedropimentel.com/2008/06/09/rails-21-whats-new/' rel='bookmark' title='Permanent Link: RELEASED &#8211; &#8220;Rails 2.1 &#8211; What`s new ?&#8221; Book'>RELEASED &#8211; &#8220;Rails 2.1 &#8211; What`s new ?&#8221; Book</a></li>
<li><a href='http://www.pedropimentel.com/2008/10/22/why-i-have-been-away/' rel='bookmark' title='Permanent Link: Why I have been away'>Why I have been away</a></li>
<li><a href='http://www.pedropimentel.com/2008/04/21/google-summer-of-code/' rel='bookmark' title='Permanent Link: Google Summer of Code'>Google Summer of Code</a></li>
</ol></p>]]></content:encoded>
			<wfw:commentRss>http://www.pedropimentel.com/2010/07/29/how-do-i-keep-track-of-what-ive-learnt/feed/</wfw:commentRss>
		<slash:comments>4</slash:comments>
		</item>
		<item>
		<title>Why my f***ing awesome web app doesn&#8217; t move forward ?</title>
		<link>http://www.pedropimentel.com/2009/06/16/why-my-fing-awesome-web-app-doesn-t-move-forward/</link>
		<comments>http://www.pedropimentel.com/2009/06/16/why-my-fing-awesome-web-app-doesn-t-move-forward/#comments</comments>
		<pubDate>Tue, 16 Jun 2009 19:01:22 +0000</pubDate>
		<dc:creator>Pedro Pimentel</dc:creator>
				<category><![CDATA[Business Admin]]></category>
		<category><![CDATA[hints]]></category>
		<category><![CDATA[rant]]></category>
		<category><![CDATA[social applications]]></category>
		<category><![CDATA[social apps]]></category>
		<category><![CDATA[twitter]]></category>
		<category><![CDATA[user]]></category>
		<category><![CDATA[user focused applications]]></category>
		<category><![CDATA[web 2.0]]></category>

		<guid isPermaLink="false">http://www.pedropimentel.com/?p=172</guid>
		<description><![CDATA[
What prevents an application, like  Twitter,  of acquiring more and more users besides the geek users? Even within my circle of friends and acquaintances that work/study with IT, when I talk about I&#8217; m a Twitter user, I need to repeat uncountable times what Twitter is about  and I usually explain to them according [...]


Probably Related posts:<ol><li><a href='http://www.pedropimentel.com/2008/05/12/criei-um-software-revolucionario-e-agora/' rel='bookmark' title='Permanent Link: Por que meu software revolucionário não deslancha?'>Por que meu software revolucionário não deslancha?</a></li>
<li><a href='http://www.pedropimentel.com/2008/04/17/fisl-90-primeiro-dia/' rel='bookmark' title='Permanent Link: FISL 9.0 &#8211; First day'>FISL 9.0 &#8211; First day</a></li>
</ol>]]></description>
			<content:encoded><![CDATA[<p style="text-align: center;"><img class="alignnone" title="Designing for the social web" src="http://farm4.static.flickr.com/3588/3394810309_19db8a7dbb.jpg" alt="" width="500" height="333" /></p>
<p>What prevents an application, like  <a title="Twitter" href="http://www.twitter.com">Twitter</a>,  of acquiring more and more users besides the geek users? Even within my circle of friends and acquaintances that work/study with IT, when I talk about I&#8217; m a Twitter user, I need to repeat uncountable times what Twitter is about  and I usually explain to them according to what twitter advertise as their goal (Not a micro blogging tool, What are you doing?). In 90% of the cases, they say they heard about it but don&#8217;t know what´s its purpose, in other words, they don´t know how they could use twitter for their benefit. &#8221;<em>Why would I tell ´followers´ what I am doing </em>?¨ is the most asked question after  my explanation.  It means Twitter´s initial goal failed to instigate the user to create a new need, but why ?</p>
<p><span id="more-172"></span></p>
<p style="text-align: center; "><img class="aligncenter" title="graph" src="http://upload.wikimedia.org/wikipedia/en/4/45/DiffusionOfInnovation.png" alt="" width="548" height="194" /></p>
<p>As seen in the graph, there´s  a steep  that divides <em>Early adopte</em>r users from the <em>mainstream</em> users. I believe that this gap,  which is always  the final &#8220;test&#8221; to any application to become popular, is becoming even steeper between  the <em>Early Adopter</em> user (the ones who adopt new technologies before the vast majority of people) and the <em>mainstream</em> user due the fact  most of the services around the web, like twitter,  being targeted (mostly due to bad advertisement) to <em>Early Adopters</em> users. Like I said before, it happens that for <em>mainstream</em> users the reason for what they would use something needs to be clearly written in giant letters with neon lights otherwise they won´t buy  your idea by just &#8220;giving a try&#8221;.</p>
<p>I myself, being an <em>early adopter</em> user, believe we are living in some kind of technological bubble and even though we see so many applications doing success around there, most of them are not even close of what they could reach because they are kept restricted to the <em>geek</em> world. There&#8217;s a lot of things that could be achieved. In my opinion, before saturating the market with thousands of applications that  deliver the same product in different designs, we could stop being so selfish and besides developing applications we should care about how we are going to sell our idea and how to create the need inside the user´s mind.</p>
<p>However, create focusing the real need of the final user isn&#8217; t a easy task. We, developers, having the bad habit of programming to ourselves, solving our own problems and satisfying our selfish needs doesn´t help much either. Because of that, we live in this technological bubble where we create services/products to impress our friends with all our freak techniques and for what ? Just to be to be used by ourselves. But how to break the bubble ? How to identify the needs of the <em>mainstream</em> users ? It&#8217;s really hard to give final answers to these questions, however, I believe the solution is start paying attention to our non-geek friends (if you don´t have non-geek friends, can be your mom)  in their day-to-day and trying to assume the <em>mainstream</em> user&#8217;s role. </p>
<p>Users don´t like to take risk. They are very different from people like me and probably you. They don´t care about 99% of the things we care about,  so pay attention to the people around you, notice how they interact with the computer as well their reactions behind it. One user screwing his face in front of the computer can be the best time to ask him to find out what&#8217; s wrong and how he think it might be possible to improve.</p>


<p>Probably Related posts:<ol><li><a href='http://www.pedropimentel.com/2008/05/12/criei-um-software-revolucionario-e-agora/' rel='bookmark' title='Permanent Link: Por que meu software revolucionário não deslancha?'>Por que meu software revolucionário não deslancha?</a></li>
<li><a href='http://www.pedropimentel.com/2008/04/17/fisl-90-primeiro-dia/' rel='bookmark' title='Permanent Link: FISL 9.0 &#8211; First day'>FISL 9.0 &#8211; First day</a></li>
</ol></p>]]></content:encoded>
			<wfw:commentRss>http://www.pedropimentel.com/2009/06/16/why-my-fing-awesome-web-app-doesn-t-move-forward/feed/</wfw:commentRss>
		<slash:comments>4</slash:comments>
		</item>
		<item>
		<title>A recipe for Lazy Programmers</title>
		<link>http://www.pedropimentel.com/2009/06/14/a-recipe-for-lazy-programmers/</link>
		<comments>http://www.pedropimentel.com/2009/06/14/a-recipe-for-lazy-programmers/#comments</comments>
		<pubDate>Sun, 14 Jun 2009 15:07:23 +0000</pubDate>
		<dc:creator>Pedro Pimentel</dc:creator>
				<category><![CDATA[hints]]></category>
		<category><![CDATA[laziness]]></category>
		<category><![CDATA[lazy]]></category>
		<category><![CDATA[programming]]></category>
		<category><![CDATA[salad recipe]]></category>

		<guid isPermaLink="false">http://www.pedropimentel.com/?p=141</guid>
		<description><![CDATA[
Fact: programmers are one of the laziest creatures on earth and when it comes to ruby programmers, like me, the problem is even worse. We don´t like to spend more than 5 minutes cooking something while we could be doing something more important like chatting with your friends on freenode.

After spending more time than I [...]


No related posts.]]></description>
			<content:encoded><![CDATA[<p style="text-align: center;"><img class="aligncenter" title="Lazy geek" src="http://www.seandwyer.net/wp-content/uploads/2008/08/lazygeekcushion.jpg" alt="" width="400" height="254" /></p>
<p>Fact: programmers are one of the laziest creatures on earth and when it comes to ruby programmers, like me, the problem is even worse. We don´t like to spend more than 5 minutes cooking something while we could be doing something more important like chatting with your friends on freenode.</p>
<p><span id="more-141"></span><br />
After spending more time than I wanted in the kitchen, I came with this recipe that is easily modifiable and IMHO it´s delicious and nutritive. So, here´s what you need:</p>
<ul>
<li>olives, I´m using french style olives, but you can use any other one</li>
<li>balsamic vinegar, preferably an original one from Modena, Italy</li>
<li>a good quality extra virgin olive oil</li>
<li>honey</li>
<li>cheese, you can choose, but I strongly recommend using goat cheese, camembert or brie</li>
<li>cherry tomatoes</li>
<li>vegetables, I´m using lettuce and its variants, but  you can put any other vegetable you like</li>
</ul>
<p>First, start slicing the vegetables in way you can eat without cutting them.</p>
<p><img class="aligncenter size-medium wp-image-150" title="p1030249" src="http://www.pedropimentel.com/wp-content/uploads/2009/06/p1030249-450x337.jpg" alt="p1030249" width="450" height="337" /></p>
<p>Then pour honey over the vegetables like drawing lines. Be careful not to add too much honey otherwise will be more a dessert rather than a salad.</p>
<p><img class="aligncenter size-medium wp-image-151" title="p1030251" src="http://www.pedropimentel.com/wp-content/uploads/2009/06/p1030251-450x337.jpg" alt="p1030251" width="450" height="337" /></p>
<p>Cut the cheese in cubes and add it over the salad. As I´m using goat cheese which is a little bit too strong for my taste, I added less cheese and due to its form factor, I´m using slices of it</p>
<p><img class="aligncenter size-medium wp-image-152" title="p1030252" src="http://www.pedropimentel.com/wp-content/uploads/2009/06/p1030252-450x337.jpg" alt="p1030252" width="450" height="337" /></p>
<p>Now you add about 1.5 level tablespoons (15ml) of balsamic vinegar over the salad.</p>
<p><img class="aligncenter size-medium wp-image-153" title="p1030253" src="http://www.pedropimentel.com/wp-content/uploads/2009/06/p1030253-450x337.jpg" alt="p1030253" width="450" height="337" /></p>
<p>The lasts steps are no mistery: you add olives, cherry tomatoes, dress the salad with the extra virgin olive oil and that´s pretty much of it.</p>
<p><img class="aligncenter size-medium wp-image-154" title="p1030254" src="http://www.pedropimentel.com/wp-content/uploads/2009/06/p1030254-450x337.jpg" alt="p1030254" width="450" height="337" /></p>
<p>Now the best part: you can try your very new salad ! <strong><em>B</em></strong><em><strong>on Appétit</strong></em></p>
<p>Just in case you´re wondering about which olive oil and balsamic vinegar I used, here are them:</p>
<p><img class="aligncenter size-thumbnail wp-image-155" title="Extra virgin olive oil" src="http://www.pedropimentel.com/wp-content/uploads/2009/06/p1030241-150x150.jpg" alt="Extra virgin olive oil" width="150" height="150" /><br />
Venta Barón, from Spain<br />
<img class="aligncenter size-thumbnail wp-image-142" title="Balsamic vinegar" src="http://www.pedropimentel.com/wp-content/uploads/2009/06/p1030240-150x150.jpg" alt="Balsamic vinegar" width="150" height="150" /><br />
Ponti, from Italy</p>


<p>No related posts.</p>]]></content:encoded>
			<wfw:commentRss>http://www.pedropimentel.com/2009/06/14/a-recipe-for-lazy-programmers/feed/</wfw:commentRss>
		<slash:comments>2</slash:comments>
		</item>
		<item>
		<title>View sql queries in your console</title>
		<link>http://www.pedropimentel.com/2009/03/22/view-sql-queries-in-your-console/</link>
		<comments>http://www.pedropimentel.com/2009/03/22/view-sql-queries-in-your-console/#comments</comments>
		<pubDate>Sun, 22 Mar 2009 21:45:02 +0000</pubDate>
		<dc:creator>Pedro Pimentel</dc:creator>
				<category><![CDATA[hints]]></category>
		<category><![CDATA[rails]]></category>

		<guid isPermaLink="false">http://www.pedropimentel.com/?p=123</guid>
		<description><![CDATA[Don&#8217;t you think it&#8217;s really irritating when, in the console, you are testing your model&#8217;s methods and everytime you need to check how each SQL query was formed you need to go to another tab to visualize the log ???
Your frustation is over. Just add the following lines in your .irbrc file:

def log_to
  ActiveRecord::Base.logger [...]


Probably Related posts:<ol><li><a href='http://www.pedropimentel.com/2008/10/01/how_to_run_just_one_test_from_your_terminal/' rel='bookmark' title='Permanent Link: How to Run Just one Test Method from your Terminal'>How to Run Just one Test Method from your Terminal</a></li>
<li><a href='http://www.pedropimentel.com/2008/06/15/ultrasphinx-bug/' rel='bookmark' title='Permanent Link: Ultrasphinx bug?'>Ultrasphinx bug?</a></li>
<li><a href='http://www.pedropimentel.com/2008/06/02/open-source-rails/' rel='bookmark' title='Permanent Link: Open Source Rails'>Open Source Rails</a></li>
</ol>]]></description>
			<content:encoded><![CDATA[<p>Don&#8217;t you think it&#8217;s really irritating when, in the console, you are testing your model&#8217;s methods and everytime you need to check how each SQL query was formed you need to go to another tab to visualize the log ???</p>
<p>Your frustation is over. Just add the following lines in your .irbrc file:</p>

<div class="wp_syntax"><div class="code"><pre class="ruby" style="font-family:monospace;"><span style="color:#9966CC; font-weight:bold;">def</span> log_to
  <span style="color:#6666ff; font-weight:bold;">ActiveRecord::Base</span>.<span style="color:#9900CC;">logger</span> = <span style="color:#CC00FF; font-weight:bold;">Logger</span>.<span style="color:#9900CC;">new</span><span style="color:#006600; font-weight:bold;">&#40;</span>$stdout<span style="color:#006600; font-weight:bold;">&#41;</span>
  <span style="color:#6666ff; font-weight:bold;">ActiveRecord::Base</span>.<span style="color:#9900CC;">connection_pool</span>.<span style="color:#9900CC;">clear_reloadable_connections</span>!
<span style="color:#9966CC; font-weight:bold;">end</span></pre></div></div>

<p>You can change the method&#8217;s name to whatever suits your needs. After that, every time you are in your application&#8217;s console you just type <em>log_to</em> and you&#8217;re ready to go:</p>

<div class="wp_syntax"><div class="code"><pre class="bash" style="font-family:monospace;"><span style="color: #000000; font-weight: bold;">&gt;&gt;</span> log_to
=<span style="color: #000000; font-weight: bold;">&gt;</span> <span style="color: #7a0874; font-weight: bold;">&#91;</span><span style="color: #7a0874; font-weight: bold;">&#93;</span>
<span style="color: #000000; font-weight: bold;">&gt;&gt;</span> MyModel.count
  SQL <span style="color: #7a0874; font-weight: bold;">&#40;</span>1.8ms<span style="color: #7a0874; font-weight: bold;">&#41;</span> SELECT count<span style="color: #7a0874; font-weight: bold;">&#40;</span><span style="color: #000000; font-weight: bold;">*</span><span style="color: #7a0874; font-weight: bold;">&#41;</span> <span style="color: #c20cb9; font-weight: bold;">as</span> count_all FROM <span style="color: #ff0000;">&quot;mymodels&quot;</span>
=<span style="color: #000000; font-weight: bold;">&gt;</span> <span style="color: #000000;">10</span></pre></div></div>

<p>This hint I got it from <a title="Pratik Naik" href="http://m.onkey.org/">Pratik Naik</a> while doing pair programming with him at the company I work.</p>


<p>Probably Related posts:<ol><li><a href='http://www.pedropimentel.com/2008/10/01/how_to_run_just_one_test_from_your_terminal/' rel='bookmark' title='Permanent Link: How to Run Just one Test Method from your Terminal'>How to Run Just one Test Method from your Terminal</a></li>
<li><a href='http://www.pedropimentel.com/2008/06/15/ultrasphinx-bug/' rel='bookmark' title='Permanent Link: Ultrasphinx bug?'>Ultrasphinx bug?</a></li>
<li><a href='http://www.pedropimentel.com/2008/06/02/open-source-rails/' rel='bookmark' title='Permanent Link: Open Source Rails'>Open Source Rails</a></li>
</ol></p>]]></content:encoded>
			<wfw:commentRss>http://www.pedropimentel.com/2009/03/22/view-sql-queries-in-your-console/feed/</wfw:commentRss>
		<slash:comments>2</slash:comments>
		</item>
		<item>
		<title>How to Run Just one Test Method from your Terminal</title>
		<link>http://www.pedropimentel.com/2008/10/01/how_to_run_just_one_test_from_your_terminal/</link>
		<comments>http://www.pedropimentel.com/2008/10/01/how_to_run_just_one_test_from_your_terminal/#comments</comments>
		<pubDate>Thu, 02 Oct 2008 01:45:07 +0000</pubDate>
		<dc:creator>Pedro Pimentel</dc:creator>
				<category><![CDATA[hints]]></category>
		<category><![CDATA[rails]]></category>
		<category><![CDATA[ruby]]></category>
		<category><![CDATA[ruby test]]></category>

		<guid isPermaLink="false">http://www.pedropimentel.com/?p=75</guid>
		<description><![CDATA[Many times I found myself running all tests just after modifying just one test method. Depending on the size of your project and its test ratio, it can be a very boring waiting for it to finish.
It can be even worse: Imagine you have other tests failing. How can you improve your productivity ?  Just [...]


Probably Related posts:<ol><li><a href='http://www.pedropimentel.com/2009/12/15/method-dispatch-in-ruby/' rel='bookmark' title='Permanent Link: Method dispatch in Ruby'>Method dispatch in Ruby</a></li>
<li><a href='http://www.pedropimentel.com/2008/07/28/writing-optioned-software/' rel='bookmark' title='Permanent Link: Writing Opinionated Software'>Writing Opinionated Software</a></li>
<li><a href='http://www.pedropimentel.com/2009/03/22/view-sql-queries-in-your-console/' rel='bookmark' title='Permanent Link: View sql queries in your console'>View sql queries in your console</a></li>
</ol>]]></description>
			<content:encoded><![CDATA[<p>Many times I found myself running all tests just after modifying just one test method. Depending on the size of your project and its test ratio, it can be a very boring waiting for it to finish.</p>
<p>It can be even worse: Imagine you have other tests failing. How can you improve your productivity ?  Just use the &#8220;-n method_name&#8221; parameter for the method you want to test.</p>

<div class="wp_syntax"><div class="code"><pre class="bash" style="font-family:monospace;">ruby path_to_your_test_case <span style="color: #660033;">-n</span> method_you_want_to_test</pre></div></div>

<p>A real example, I want to test the &#8220;test_should_do_stuff&#8221; method inside my &#8220;stuff_controller_test.rb&#8221;:</p>

<div class="wp_syntax"><div class="code"><pre class="bash" style="font-family:monospace;">ruby test<span style="color: #000000; font-weight: bold;">/</span>functional<span style="color: #000000; font-weight: bold;">/</span>stuff_controller_test.rb <span style="color: #660033;">-n</span> test_should_do_stuff</pre></div></div>

<p>Worth remember that stills load your fixtures and preforms setup, it only won&#8217;t execute the other test methods.</p>


<p>Probably Related posts:<ol><li><a href='http://www.pedropimentel.com/2009/12/15/method-dispatch-in-ruby/' rel='bookmark' title='Permanent Link: Method dispatch in Ruby'>Method dispatch in Ruby</a></li>
<li><a href='http://www.pedropimentel.com/2008/07/28/writing-optioned-software/' rel='bookmark' title='Permanent Link: Writing Opinionated Software'>Writing Opinionated Software</a></li>
<li><a href='http://www.pedropimentel.com/2009/03/22/view-sql-queries-in-your-console/' rel='bookmark' title='Permanent Link: View sql queries in your console'>View sql queries in your console</a></li>
</ol></p>]]></content:encoded>
			<wfw:commentRss>http://www.pedropimentel.com/2008/10/01/how_to_run_just_one_test_from_your_terminal/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
	</channel>
</rss>
