<?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>blog.dervalp.com &#187; Agile</title>
	<atom:link href="http://blog.dervalp.com/tag/agile/feed/" rel="self" type="application/rss+xml" />
	<link>http://blog.dervalp.com</link>
	<description>Think before Programming (Public learning)</description>
	<lastBuildDate>Sat, 20 Mar 2010 22:22:42 +0000</lastBuildDate>
	<generator>http://wordpress.org/?v=2.8</generator>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
			<item>
		<title>Kiwi MVC.NET : Why this, why that ? I explain my architecture choices Part 5 [source on codeplex]</title>
		<link>http://blog.dervalp.com/2009/05/29/kiwi-mvcnet-why-this-why-that-i-explain-my-architecture-choices-part-5/</link>
		<comments>http://blog.dervalp.com/2009/05/29/kiwi-mvcnet-why-this-why-that-i-explain-my-architecture-choices-part-5/#comments</comments>
		<pubDate>Fri, 29 May 2009 18:26:39 +0000</pubDate>
		<dc:creator>dervalp</dc:creator>
				<category><![CDATA[Kiwi MVC]]></category>
		<category><![CDATA[Agile]]></category>
		<category><![CDATA[ASP.NET]]></category>
		<category><![CDATA[C#.NET]]></category>
		<category><![CDATA[CMS]]></category>
		<category><![CDATA[MVC]]></category>
		<category><![CDATA[MVC.NET]]></category>
		<category><![CDATA[TDD]]></category>

		<guid isPermaLink="false">http://blog.dervalp.com/?p=283</guid>
		<description><![CDATA[So, I work hard these days to  finish my data access. I would like to explain you how I see application&#8217;s design.
As I told you before, I want to separate my application in 3 parts. I know that architecture could be discussed but I would make this point clear, it should be &#8220;re-factored&#8221;. Anyway, for [...]]]></description>
			<content:encoded><![CDATA[<p>So, I work hard these days to  finish my data access. I would like to explain you how I see application&#8217;s design.</p>
<p>As I told you before, I want to separate my application in 3 parts. I know that architecture could be discussed but I would make this point clear, it should be &#8220;re-factored&#8221;. Anyway, for the moment, I think it is enough flexible for what I want to do <span style="text-decoration: underline;">NOW</span>.</p>
<p>Here is a reminder of my layers:</p>
<ul>
<li>The Web application which will be the view of my application.</li>
</ul>
<ul>
<li>The controller with all my business logic embedded in a library Service.</li>
</ul>
<ul>
<li>The model library which will contain my models, my data access (repository) and all my filter static classes.</li>
</ul>
<h2><span id="more-283"></span></h2>
<p>To improve my explanations, I hand draw a little pseudo UML diagram :</p>
<p><img class="alignnone size-full wp-image-287" title="kiwi_mvc_pseudo_uml" src="http://blog.dervalp.com/wp-content/uploads/2009/05/kiwi_mvc_pseudo_uml.jpg" alt="kiwi_mvc_pseudo_uml" width="805" height="626" /></p>
<p>What I want it is to keep as much as I can the &#8220;Soc&#8221; (separation of concern). My service should make what a service should do and if I want to change my repository with a Oracle one, I could change it only by modifying the instantiation of my service (with DI for the future). I want to keep that &#8220;philosophy&#8221; all along the development but philosophy is not obligation.</p>
<p>In the same way, you&#8217;ve certainly noticed that I often return an IQueryable for my &#8220;get&#8221; method (see listing 1). I know this should be better to return a List type cause it is a more &#8220;standard&#8221; and you do not have to use the Linq library. Nevertheless I think I will keep it. I do not want to call to often the .IEnumerable function and also it will be easier to use my filter classes.</p>
<p>As the only developer for this application, I assume my choices. <img src='http://blog.dervalp.com/wp-includes/images/smilies/icon_smile.gif' alt=':)' class='wp-smiley' />  If you have remarks about this, please leave a comment.</p>
<p>Listing 1 : Example of the getPages method who retreive all the page from my db</p>
<pre class="brush: c;">

public IQueryable&lt;Page&gt; getPages()
{

return from p in _db.Posts
where p.Type == &quot;Page&quot;
let lp = getLocalizedPages(p.PostID)
select new Page
{
PageID = p.PostID,
Author = p.Author,
Date = p.Date,
PageLozalized = new LazyList&lt;PageLocalized&gt;(lp),
ModifiedDate = p.ModifiedDate,
Password = p.Password ?? string.Empty,
Permalink = p.Permalink,
Status = p.PostStatusID,
Version = p.RevisionOf

};
}

private IQueryable&lt;PageLocalized&gt; getLocalizedPages(int postID)
{
return from lp in _db.PostCultureDetails
where lp.PostID == postID
select new PageLocalized()
{
Description = lp.Excerpt,
Text = lp.Text,
Title = lp.Title,
LanguageCode = (from culture in _db.Cultures
where culture.CultureID == lp.CultureID
select culture.LanguageCode).SingleOrDefault()

};

}
</pre>
<p><strong>Why I did not use Entity framework ?</strong> I hate when the framework decide for me which object I should use. Also, the time I would spend to make it work as I want is doubtless longer than the time I wrote my custom Linq to Sql Class. Entity framework could be great for simple application but for an application who will grow in the future (as I expect Kiwi will do) I do not think it&#8217;s a good choice.</p>
<p><strong>Why I did not use NHibernate ? </strong>I could have chosen NHibernate, but I absolutely wanted to play with Linq. Also, maybe in the future I could make the data access with it and compare what&#8217;s better for my application. Anyway, this is not the time to do this.</p>
<p>If you have other questions like this, please, do not hesitate.</p>
<p><strong>And now the service :<br />
</strong></p>
<p>As I mentioned, my data access is almost finished (for the moment). I am going to create the services I need for my application. Evidently, always in a TDD approach.</p>
<p><strong>Kiwi Part 4 was bullshit :</strong></p>
<p>Maybe it was but the aim of that post was to show you how to start with TDD. And I know that I was going in front of a wall. Indeed, I had an empty db and the post object was the most connected object. As you know in TDD, you write a test, you write <span style="text-decoration: underline;">some code</span>. I realized that I should have written a lot (before creating the &#8220;SaveFunction&#8221; for it). I needed the category object, the comment object,&#8230; Thus, I begin to create a save function for the category object (alway with a tdd style).</p>
<p>Create the test :</p>
<pre class="brush: text;">
//Spike Test !!!
[TestMethod]
public void SqlPostRepositoryTest_can_add_category()
{

Category category = new Category();
category.CreatedDate = DateTime.Now;
category.CategoryParentID = 0;
var categoryEn = new CategoryLocalized() {Description = &quot;This is a test&quot;, Value = &quot;Software Development&quot;, LangageCode = &quot;EN&quot;};
var categoryFR = new CategoryLocalized() { Description = &quot;Ceci est un test&quot;, Value = &quot;Développement Logiciel&quot;, LangageCode = &quot;FR&quot; };

var list = new LazyList&lt;CategoryLocalized&gt;();
list.Add(categoryEn);
list.Add(categoryFR);

category.LocalizedCategory = list;

_repository.Save(category);

Assert.IsNotNull(category);

}
</pre>
<p>And after the function I need :</p>
<pre class="brush: c;">

//save or add a category

public void Save (Category category)
{
var dbCategory = (from c in _db.Categories
where c.CategoryID == category.CategoryID
select c).SingleOrDefault();
if(dbCategory == null)
{
dbCategory = new SqlRepository.Category();
dbCategory.CreatedDate = DateTime.Now;
dbCategory.ParentID = category.CategoryParentID;
//commit the change to have the id and insert the culture
_db.Categories.InsertOnSubmit(dbCategory);
_db.SubmitChanges();

//foreach culture we have in the objec we add it in the table CategoryCultureDetail
foreach (CategoryLocalized item in category.LocalizedCategory)
{
var dbitem = new CategoryCultureDetail();
//some Object to DB
dbitem.CategoryID = dbCategory.CategoryID;
dbitem.Description = item.Description;
dbitem.Value = item.Value;
dbitem.CultureID =
(from culture in _db.Cultures
where culture.LanguageCode == item.LangageCode
select culture.CultureID).SingleOrDefault();
dbCategory.CategoryCultureDetails.Add(dbitem);
_db.SubmitChanges();
}

}
else
{

foreach (CategoryLocalized item in category.LocalizedCategory)
{
var thisCategoryLocalized = (from cn in _db.CategoryCultureDetails
where cn.CategoryID == category.CategoryID
where cn.CultureID ==   (from culture in _db.Cultures
where culture.LanguageCode == item.LangageCode
select culture.CultureID).SingleOrDefault()
select cn).SingleOrDefault();
thisCategoryLocalized.Description = item.Description;
thisCategoryLocalized.Value = item.Value;
_db.CategoryCultureDetails.InsertOnSubmit(thisCategoryLocalized);
_db.SubmitChanges();

}
}
}
</pre>
<p>Of course, you see the &#8220;final&#8221; result. To have that, I went by little piece of code. Test, write, build, test, write, build, test &#8230;</p>
<p>I also know the test you see above is not a unit test, it is more an integration test or a spike test and it will be deleted or commented in the future.</p>
<p>But the name is <span style="text-decoration: underline;">test driven </span>design and not &#8220;make pure unit test&#8221; design.</p>
<p>NOTE : I know I am saying that each time I post but I will try to add the source code in my codeplex project this afternoon.</p>
<p>UPDATE  : I put the source on code plex, if you would like to see it : http://dervalp.codeplex.com/</p>
<p>I have some troubles with codeplex, I will check this out tomorrow cause I am a bit tired today.</p>
<!-- Social Bookmarks BEGIN -->
<div class="social_bookmark">
<a title="Click me to see the sites." href="#" onclick="$$('div.d283').each( function(e) { e.visualEffect('slide_down',{duration:2.5}) }); return false;"><strong><em>Bookmark It</em></strong></a>
<br />
<div class="d283" style="overflow:hidden">
<br />
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://del.icio.us/post?url=http://blog.dervalp.com/2009/05/29/kiwi-mvcnet-why-this-why-that-i-explain-my-architecture-choices-part-5/&amp;title=Kiwi+MVC.NET+%3A+Why+this%2C+why+that+%3F+I+explain+my+architecture+choices+Part+5+%5Bsource+on+codeplex%5D" rel="nofollow" title="Add to&nbsp;Del.icio.us"><img class="social_img" src="http://blog.dervalp.com/wp-content/plugins/social-bookmarks/images/delicious.png" title="Add to&nbsp;Del.icio.us" alt="Add to&nbsp;Del.icio.us" /></a>
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://digg.com/submit?phase=2&amp;url=http://blog.dervalp.com/2009/05/29/kiwi-mvcnet-why-this-why-that-i-explain-my-architecture-choices-part-5/&amp;title=Kiwi+MVC.NET+%3A+Why+this%2C+why+that+%3F+I+explain+my+architecture+choices+Part+5+%5Bsource+on+codeplex%5D" rel="nofollow" title="Add to&nbsp;digg"><img class="social_img" src="http://blog.dervalp.com/wp-content/plugins/social-bookmarks/images/digg.png" title="Add to&nbsp;digg" alt="Add to&nbsp;digg" /></a>
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://www.facebook.com/sharer.php?u=http://blog.dervalp.com/2009/05/29/kiwi-mvcnet-why-this-why-that-i-explain-my-architecture-choices-part-5/" rel="nofollow" title="Add to&nbsp;Facebook"><img class="social_img" src="http://blog.dervalp.com/wp-content/plugins/social-bookmarks/images/facebook.png" title="Add to&nbsp;Facebook" alt="Add to&nbsp;Facebook" /></a>
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://www.google.com/bookmarks/mark?op=edit&amp;output=popup&amp;bkmk=http://blog.dervalp.com/2009/05/29/kiwi-mvcnet-why-this-why-that-i-explain-my-architecture-choices-part-5/&amp;title=Kiwi+MVC.NET+%3A+Why+this%2C+why+that+%3F+I+explain+my+architecture+choices+Part+5+%5Bsource+on+codeplex%5D" rel="nofollow" title="Add to&nbsp;Google Bookmarks"><img class="social_img" src="http://blog.dervalp.com/wp-content/plugins/social-bookmarks/images/google.png" title="Add to&nbsp;Google Bookmarks" alt="Add to&nbsp;Google Bookmarks" /></a>
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://reddit.com/submit?url=http://blog.dervalp.com/2009/05/29/kiwi-mvcnet-why-this-why-that-i-explain-my-architecture-choices-part-5/&amp;title=Kiwi+MVC.NET+%3A+Why+this%2C+why+that+%3F+I+explain+my+architecture+choices+Part+5+%5Bsource+on+codeplex%5D" rel="nofollow" title="Add to&nbsp;reddit"><img class="social_img" src="http://blog.dervalp.com/wp-content/plugins/social-bookmarks/images/reddit.png" title="Add to&nbsp;reddit" alt="Add to&nbsp;reddit" /></a>
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://www.stumbleupon.com/submit.php?url=http://blog.dervalp.com/2009/05/29/kiwi-mvcnet-why-this-why-that-i-explain-my-architecture-choices-part-5/&amp;title=Kiwi+MVC.NET+%3A+Why+this%2C+why+that+%3F+I+explain+my+architecture+choices+Part+5+%5Bsource+on+codeplex%5D" rel="nofollow" title="Add to&nbsp;Stumble Upon"><img class="social_img" src="http://blog.dervalp.com/wp-content/plugins/social-bookmarks/images/stumbleupon.png" title="Add to&nbsp;Stumble Upon" alt="Add to&nbsp;Stumble Upon" /></a>
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://twitter.com/home/?status=Check+out+Kiwi+MVC.NET+%3A+Why+this%2C+why+that+%3F+I+explain+my+architecture+choices+Part+5+%5Bsource+on+codeplex%5D+@+http://blog.dervalp.com/2009/05/29/kiwi-mvcnet-why-this-why-that-i-explain-my-architecture-choices-part-5/" rel="nofollow" title="Add to&nbsp;Twitter"><img class="social_img" src="http://blog.dervalp.com/wp-content/plugins/social-bookmarks/images/twitter.png" title="Add to&nbsp;Twitter" alt="Add to&nbsp;Twitter" /></a>
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://myweb2.search.yahoo.com/myresults/bookmarklet?u=http://blog.dervalp.com/2009/05/29/kiwi-mvcnet-why-this-why-that-i-explain-my-architecture-choices-part-5/&amp;t=Kiwi+MVC.NET+%3A+Why+this%2C+why+that+%3F+I+explain+my+architecture+choices+Part+5+%5Bsource+on+codeplex%5D" rel="nofollow" title="Add to&nbsp;Yahoo My Web"><img class="social_img" src="http://blog.dervalp.com/wp-content/plugins/social-bookmarks/images/yahoo.png" title="Add to&nbsp;Yahoo My Web" alt="Add to&nbsp;Yahoo My Web" /></a>
<br />
<a style="font-size:90%;text-align: right; " title="Click me to hide the sites." href="#" onclick="$$('div.d283').each( function(e) { e.visualEffect('slide_up',{duration:0.5}) }); return false;">Hide Sites</a>
</div>
</div>
<!-- Social Bookmarks END -->
<script type="text/javascript">$$('div.d283').each( function(e) { e.visualEffect('slide_up',{duration:0.5}) }); </script>]]></content:encoded>
			<wfw:commentRss>http://blog.dervalp.com/2009/05/29/kiwi-mvcnet-why-this-why-that-i-explain-my-architecture-choices-part-5/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Agile &#8211; Test Driven Design &#8220;Need it or not Need it&#8221;</title>
		<link>http://blog.dervalp.com/2009/05/27/agile-test-driven-design-i-do-need-it/</link>
		<comments>http://blog.dervalp.com/2009/05/27/agile-test-driven-design-i-do-need-it/#comments</comments>
		<pubDate>Wed, 27 May 2009 09:43:34 +0000</pubDate>
		<dc:creator>dervalp</dc:creator>
				<category><![CDATA[Agile]]></category>
		<category><![CDATA[C#.NET]]></category>
		<category><![CDATA[TDD]]></category>

		<guid isPermaLink="false">http://blog.dervalp.com/?p=237</guid>
		<description><![CDATA[What my colleagues often say when they hear TDD is :  &#8220;It makes no sense&#8221;, &#8220;We do not need that&#8221;, &#8220;I am doing without TDD since ten years&#8221;.
Indeed, maybe, you do not need it. Indeed, you were doing without it but if you are a developer, you should be open to new technologies, curious and [...]]]></description>
			<content:encoded><![CDATA[<p>What my colleagues often say when they hear TDD is :  &#8220;It makes no sense&#8221;, &#8220;We do not need that&#8221;, &#8220;I am doing without TDD since ten years&#8221;.</p>
<p>Indeed, maybe, you do not need it. Indeed, you were doing without it but if you are a developer, you should be open to new technologies, curious and maybe you should test it before saying that you do not need it.</p>
<p>Main bugs come from stupid errors. If you use TDD, a lot of this (syntax, typo, omission) error will emerge quickly.</p>
<h2><span id="more-237"></span></h2>
<p>To make your code testable you have to understand all the methods and objects you use. I think it is the main reason why some developers fear about TDD cause if you want to simulate your httpcontext for example, you have to understand how a httpcontext works.  Also, to do that, you have to &#8220;mock&#8221;, good tools exist to help developers to setup fake context but It cost you time.</p>
<p>Is it worth? I would say yes. In the end of the process,  you can be self-confident with your code and you can explain to everyone what you are doing without gray area. Moreover, if you change something in your code, you should be able to know if there are side effects or not. You will execute all your tests and if all your tests pass, you are safe. If not, you can immediately  know where you have to change.</p>
<p>The other great thing with TDD is the iterative way. You create a test, it fails, you write some code, you execute the test, if it is ok, you write a new test,&#8230; Like this you feel less overwhelmed by your project.</p>
<p><img class="alignnone size-full wp-image-244" title="tdd_test" src="http://blog.dervalp.com/wp-content/uploads/2009/05/tdd_test.jpg" alt="tdd_test" width="380" height="732" /></p>
<p>The definition from Wikipedia :</p>
<p><em>Test-driven development (TDD) is a software development technique that uses short development iterations based on pre-written test cases that define desired improvements or new functions. Each iteration produces code necessary to pass that iteration&#8217;s tests. Finally, the programmer or team refactors the code to accommodate changes. A key TDD concept is that preparing tests before coding facilitates rapid feedback changes. Note that test-driven development is a software design method, not merely a method of testing.</em></p>
<p>“The act of writing a unit test is more an act of design than of verification.<span> </span>It is also more an act of documentation than of verification.<span> </span>The act of writing a unit test closes a remarkable number of feedback  loops, the least of which is the one pertaining to verification of function”.<a href="http://www.amazon.com/exec/obidos/ASIN/0135974445/ambysoftinc"> Bob Martin</a></p>
<p>I guess it is what a developer should understand. Writing a test is not only test but it a act of design.</p>
<p>For example, we have an application who manage flights in the Airport X. And the client want to see all the flight details who land between 3 PM and 4 PM in that Airport. The questions are : What do you need ? Where do I have to query the data ? Also, maybe you have to deal with 5 or 6 web services.  How are you going to test this function without unit tests ?  Are you going to create a gridview to see the results and go in debug mode ? It is going to be a nightmare. But if you go step by step by using TDD, I am sure it will be easier cause when you will write your tests, you will ask the right questions and you will better understand the domain you are dealing with. It is, &#8220;Think before programming&#8221;.</p>
<p>In conclusion, I am not going to explain how TDD is working. I know some websites explain that better than me. I will give you some links that I&#8217;ve found usefull during my learning process.  Also, maybe my opinion on TDD will change, in that case, I will update this post. As usual, feeback is welcome.</p>
<p>Related Links :</p>
<p><a href="http://www.agiledata.org/essays/tdd.html">Wikipedia</a></p>
<p><a href="http://www.agiledata.org/essays/tdd.html">AgileData</a></p>
<p><a href="http://blog.wekeroad.com/tag/tdd/">Rob Connery</a></p>
<p><a href="http://haacked.com/Tags/TDD/default.aspx">Phil Haack</a></p>
<p>NOTE : For my unit tests, I am using Visual Studio 2008 SP1. I used <a href="http://www.nunit.org/index.php">Nunit</a> in the past but, for me, VS makes a good job with unit test so I&#8217;ve switched. If you have feedback in that topic, you&#8217;re welcome.</p>
<p>NOTE2 : TDD without Mocking is not TDD, I will write a post about that in the future.</p>
<!-- Social Bookmarks BEGIN -->
<div class="social_bookmark">
<a title="Click me to see the sites." href="#" onclick="$$('div.d237').each( function(e) { e.visualEffect('slide_down',{duration:2.5}) }); return false;"><strong><em>Bookmark It</em></strong></a>
<br />
<div class="d237" style="overflow:hidden">
<br />
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://del.icio.us/post?url=http://blog.dervalp.com/2009/05/27/agile-test-driven-design-i-do-need-it/&amp;title=Agile+%26%238211%3B+Test+Driven+Design+%26%238220%3BNeed+it+or+not+Need+it%26%238221%3B" rel="nofollow" title="Add to&nbsp;Del.icio.us"><img class="social_img" src="http://blog.dervalp.com/wp-content/plugins/social-bookmarks/images/delicious.png" title="Add to&nbsp;Del.icio.us" alt="Add to&nbsp;Del.icio.us" /></a>
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://digg.com/submit?phase=2&amp;url=http://blog.dervalp.com/2009/05/27/agile-test-driven-design-i-do-need-it/&amp;title=Agile+%26%238211%3B+Test+Driven+Design+%26%238220%3BNeed+it+or+not+Need+it%26%238221%3B" rel="nofollow" title="Add to&nbsp;digg"><img class="social_img" src="http://blog.dervalp.com/wp-content/plugins/social-bookmarks/images/digg.png" title="Add to&nbsp;digg" alt="Add to&nbsp;digg" /></a>
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://www.facebook.com/sharer.php?u=http://blog.dervalp.com/2009/05/27/agile-test-driven-design-i-do-need-it/" rel="nofollow" title="Add to&nbsp;Facebook"><img class="social_img" src="http://blog.dervalp.com/wp-content/plugins/social-bookmarks/images/facebook.png" title="Add to&nbsp;Facebook" alt="Add to&nbsp;Facebook" /></a>
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://www.google.com/bookmarks/mark?op=edit&amp;output=popup&amp;bkmk=http://blog.dervalp.com/2009/05/27/agile-test-driven-design-i-do-need-it/&amp;title=Agile+%26%238211%3B+Test+Driven+Design+%26%238220%3BNeed+it+or+not+Need+it%26%238221%3B" rel="nofollow" title="Add to&nbsp;Google Bookmarks"><img class="social_img" src="http://blog.dervalp.com/wp-content/plugins/social-bookmarks/images/google.png" title="Add to&nbsp;Google Bookmarks" alt="Add to&nbsp;Google Bookmarks" /></a>
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://reddit.com/submit?url=http://blog.dervalp.com/2009/05/27/agile-test-driven-design-i-do-need-it/&amp;title=Agile+%26%238211%3B+Test+Driven+Design+%26%238220%3BNeed+it+or+not+Need+it%26%238221%3B" rel="nofollow" title="Add to&nbsp;reddit"><img class="social_img" src="http://blog.dervalp.com/wp-content/plugins/social-bookmarks/images/reddit.png" title="Add to&nbsp;reddit" alt="Add to&nbsp;reddit" /></a>
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://www.stumbleupon.com/submit.php?url=http://blog.dervalp.com/2009/05/27/agile-test-driven-design-i-do-need-it/&amp;title=Agile+%26%238211%3B+Test+Driven+Design+%26%238220%3BNeed+it+or+not+Need+it%26%238221%3B" rel="nofollow" title="Add to&nbsp;Stumble Upon"><img class="social_img" src="http://blog.dervalp.com/wp-content/plugins/social-bookmarks/images/stumbleupon.png" title="Add to&nbsp;Stumble Upon" alt="Add to&nbsp;Stumble Upon" /></a>
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://twitter.com/home/?status=Check+out+Agile+%26%238211%3B+Test+Driven+Design+%26%238220%3BNeed+it+or+not+Need+it%26%238221%3B+@+http://blog.dervalp.com/2009/05/27/agile-test-driven-design-i-do-need-it/" rel="nofollow" title="Add to&nbsp;Twitter"><img class="social_img" src="http://blog.dervalp.com/wp-content/plugins/social-bookmarks/images/twitter.png" title="Add to&nbsp;Twitter" alt="Add to&nbsp;Twitter" /></a>
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://myweb2.search.yahoo.com/myresults/bookmarklet?u=http://blog.dervalp.com/2009/05/27/agile-test-driven-design-i-do-need-it/&amp;t=Agile+%26%238211%3B+Test+Driven+Design+%26%238220%3BNeed+it+or+not+Need+it%26%238221%3B" rel="nofollow" title="Add to&nbsp;Yahoo My Web"><img class="social_img" src="http://blog.dervalp.com/wp-content/plugins/social-bookmarks/images/yahoo.png" title="Add to&nbsp;Yahoo My Web" alt="Add to&nbsp;Yahoo My Web" /></a>
<br />
<a style="font-size:90%;text-align: right; " title="Click me to hide the sites." href="#" onclick="$$('div.d237').each( function(e) { e.visualEffect('slide_up',{duration:0.5}) }); return false;">Hide Sites</a>
</div>
</div>
<!-- Social Bookmarks END -->
<script type="text/javascript">$$('div.d237').each( function(e) { e.visualEffect('slide_up',{duration:0.5}) }); </script>]]></content:encoded>
			<wfw:commentRss>http://blog.dervalp.com/2009/05/27/agile-test-driven-design-i-do-need-it/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Agile &#8211; Scrum &#8220;I believe in a better way&#8221;</title>
		<link>http://blog.dervalp.com/2009/05/08/scrum-i-believe-in-a-better-way/</link>
		<comments>http://blog.dervalp.com/2009/05/08/scrum-i-believe-in-a-better-way/#comments</comments>
		<pubDate>Fri, 08 May 2009 14:22:07 +0000</pubDate>
		<dc:creator>dervalp</dc:creator>
				<category><![CDATA[Agile]]></category>
		<category><![CDATA[Scrum]]></category>
		<category><![CDATA[Scrum Master]]></category>

		<guid isPermaLink="false">http://www.blog.dervalp.com/?p=3</guid>
		<description><![CDATA[If Ben Harper was a developper, sure, he would have use Scrum.
First of all, Scrum is just a methodology and not a magic word that would erase all the problems during your development lifecycle. Rather than invent a new definition of Scrum, look at the wikipedia definition:
Scrum is an iterative incremental process of software development [...]]]></description>
			<content:encoded><![CDATA[<p>If Ben Harper was a developper, sure, he would have use Scrum.</p>
<p>First of all, Scrum is just a methodology and not a magic word that would erase all the problems during your development lifecycle. Rather than invent a new definition of Scrum, look at the wikipedia definition:</p>
<p><em><strong>Scrum</strong> is an iterative incremental process of software development commonly used with agile software development. </em></p>
<p>The significant word here is <strong>iterative</strong>.</p>
<p>I have sometimes lack of motivation, sure, you sometimes have too, so let&#8217;s begin with a too classic Developper Story :</p>
<p>Your project manager arrive with a really really really important project from the business with a f***** high top priority. The release date is tomorrow and you have half a post-it as specifications.</p>
<h2><span id="more-3"></span></h2>
<p>After crying, screaming, &#8220;black outing&#8221;, think about a resignation, you will begin to feel overwhelmed by the whole project.</p>
<p>At this point, take a break and learn Scrum.</p>
<p>Scrum splits an entire project in little comprehensive action. It helps us to focus on what is important now and not what you will do in one week. Sure, do not forget to think before programming but do not believe the user specification as the holy grail cause there is 95 % that it will change.</p>
<p>Overview from <a title="http://www.mountaingoatsoftware.com/" href="http://www.mountaingoatsoftware.com/" target="_blank">Mountaingoatsoftware</a></p>
<p><a href="http://webconfig.ca/wp-content/uploads/2009/04/scrummediumlabelled1.png"><img class="aligncenter size-full wp-image-50" title="Scrum overview" src="http://webconfig.ca/wp-content/uploads/2009/04/scrummediumlabelled1.png" alt="Scrum overview" width="471" height="228" /></a></p>
<p style="clear:both;">
<p><strong>Let&#8217;s play : the roles in Scrum</strong></p>
<p>Two groups : the pigs and the chickens, based on a joke.</p>
<p>Here is the joke :</p>
<p><em>A pig and a chicken are walking down a road. The chicken looks at the pig and says, &#8220;Hey, why don&#8217;t we open a restaurant?&#8221; The pig looks back at the chicken and says, &#8220;Good idea, what do you want to call it?&#8221; The chicken thinks about it and says, &#8220;Why don&#8217;t we call it &#8216;Ham and Eggs&#8217;?&#8221; &#8220;I don&#8217;t think so,&#8221; says the pig, &#8220;I&#8217;d be committed, but you&#8217;d only be involved.&#8221;</em></p>
<p>From wikipedia :  The &#8220;pigs&#8221; are committed to building software regularly and frequently, while everyone else is a &#8220;chicken&#8221; &#8211; interested in the project but really indifferent because if it fails they&#8217;re not the pigs &#8211; that is, they weren&#8217;t the ones that committed to doing it. The needs, desires, ideas and influences of the chicken roles are taken into account, but are not in any way allowed to affect, distort or get in the way of the actual Scrum project.</p>
<p><em><strong>PO</strong></em> (product owner) :  <em>The Product Owner represents the voice of the customer. He/she ensures that the Scrum Team works with the &#8220;right things&#8221; from a business perspective. The Product Owner writes user stories, prioritizes them and then places them in the product backlog</em></p>
<p>Generally, it is you manager or you project leader. The point here is to convinced you manager to play that game. Explain him that Scrum will help to have a better view on what the team is doing. Do not forget to show him the product backlog and the sprint backlog with the little graphics (we will see that later). I am sure he will be happy. If he is still not convinced, try a strike or organize a strategy with your colleagues to find out how you could transform you boss as a product owner. There are plenty of arguments on the net and in your head.</p>
<p><strong>ScrumMaster (or Facilitator</strong>) :</p>
<p><em>Scrum is facilitated by a ScrumMaster, whose primary job is to remove impediments to the ability of the team to deliver the sprint goal. The ScrumMaster is not the leader of the team (as the team is self-organizing) but acts as a buffer between the team and any distracting influences. The ScrumMaster ensures that the Scrum process is used as intended. The ScrumMaster is the enforcer of rules. A key part of the ScrumMaster&#8217;s role is to protect the team and keep them focused on the tasks in hand.</em></p>
<p>He acts like a shield for the team. Avoid the word <em>&#8220;self-organizing</em>&#8221; near you boss, he will be scared to lose the control. Another tip, use the word Facilitator instead of Scrummaster, the scrum master is not a manager or a leader so avoid the full of meaning word &#8220;master&#8221;. If you want, you can change your facilitator at the end of the sprint. It brings fresh air for the facilitator himselft and the developer who will take the place for a sprint. Sure, you facilitator can act as a developer or you have a strange team (Yeah, I know It happens).</p>
<p><strong>The Team </strong><br />
<em>The team has the responsibility to deliver the product. A team is typically made up of 5–9 people with cross-functional skills who do the actual work (designer, developer, tester, technical communicator, etc.).</em></p>
<p>I know, sometimes you are only 3 or 4. I do not know if there is a minimum number. I used to develop in a 3 people team with SCRUM and I can say that It is make sense.</p>
<p>Try to find a funny name for you team, it can bring fun and jokes&#8230;</p>
<p>The Team, the ScrumMaster and the PO are pigs.</p>
<p><strong>The User :</strong></p>
<p><em>The software is being built for someone</em></p>
<p><strong>Stakeholders (customers, vendors) :</strong></p>
<p><em>These are the people who enable the project and for whom the project will produce the agreed-upon benefit[s], which justify its production. They are only directly involved in the process during the sprint reviews.</em></p>
<p>Sometimes Stakeholders are Users, prepare to have a lot of changes in your specifications.</p>
<p><strong>Managers :</strong></p>
<p><em>People who will set up the environment for the product development organizations.</em></p>
<p><strong>The important thing : communication</strong></p>
<p>- The Daily Scrum</p>
<p>Each morning (8:00 am for us), the scrumaster (see below) organize a little meeting (about 15 minutes) next the cofee machine and ask three questions to all the team members:</p>
<ul>
<li>What did you do yesterday ?</li>
</ul>
<ul>
<li>What will you do today?</li>
</ul>
<ul>
<li>Are there any impediments in your way?</li>
</ul>
<p style="clear:both;">The daily scrum is not a place for debating technical problems and personal life, it is just a quick overview which helps everyone to know what you are doing, what you finished and what you will do.  You have to answer quickly like &#8220;I need some help for &#8230;&#8221; or &#8220;I am strugling with &#8230;&#8221; At the end of the meeting, if the SCRUM master cannot help you directly, he will take the point and decide who can help you or what you have to do.</p>
<p>- Sprint Planning Meeting (PO + ScrumMaster + Team + others significant manager or custormers)</p>
<p>At the beginning of the sprint cycle (every 15–30 days)</p>
<p>The Sprint Planning Meeting is attended by the Product Owner, Scrum Master, the entire Scrum Team, and any interested and appropriate management or customer representatives. During that meeting, you define which tasks will move from the product backlog to the sprint back log. Team members ask questions to know more about specifications and together you define the priority of the tasks. The PO and the ScrumMaster define the goals for the sprint. After the sprint planning meeting, the team discuss if the goals are realistic and negotiate with the PO if there is some change to do.</p>
<p>Please, PO and ScrumMaster, involve your team in the sprint planning meeting, it is very important that the team feels the issues and the context of the projects they are working on.</p>
<p>- Sprint Review Meeting (PO + ScrumMaster + Team + others significant manager or custormers)</p>
<p>During that meeting you will discuss on what is completed and not completed. The limit of time is 4 hours. I encourage the team to make a demo of the new features. It is more visual than a powerpoint. The most important for the team is that the general aims are achieved. If not, it is normal in the beginning cause you need more experience to evaluate correctly the sprint backlog.</p>
<p>- Sprint Retrospective (PO + ScrumMaster + Team)</p>
<p>Discuss on what it works and did not work.  Two main questions during that meeting : What went well during the sprint? What could be improved in the next sprint? Do not hesitate to improve you process.</p>
<p>The artifacts :</p>
<p>The product backlog :</p>
<p>From Mountain Goat Software : The Product Backlog is the master list of all functionality desired in the product. When a project is initiated there is no comprehensive, time-consuming effort to write down all foreseeable tasks or requirements. Typically, a project writes down everything obvious, which is almost always more than enough for a first sprint. The Product Backlog is then allowed to grow and change as more is learned about the product and its customers.</p>
<p>Here is the example of a product backlog : <a href="http://webconfig.ca/wp-content/uploads/2009/04/simpleproductbacklog.xls">simpleproductbacklog</a></p>
<p>The Sprint backlog (wikipedia):</p>
<p>This is a greatly detailed document containing information about how the team is going to implement the features for the upcoming sprint. Features are broken down into tasks; as a best practice tasks are normally estimated between four and 16 hours of work. With this level of detail the whole team understands exactly what to do, and anyone can potentially pick a task from the list. Tasks on the sprint backlog are never assigned; rather, tasks are signed up for by the team members as needed, according to the set priority and the team member skills. The sprint backlog is property of the Team. Estimations are set by the Team. Often an according <strong>Task Board</strong> is used to see and change the state of the tasks of the current sprint, like &#8220;to do&#8221;, &#8220;in progress&#8221; and &#8220;done&#8221;.</p>
<p>Example of a sprint backlog <a href="http://webconfig.ca/wp-content/uploads/2009/04/template_scrumsprint_backlog.xlsx">template_sprint_backlog</a></p>
<p style="clear:both;">You can find others sprint backlog and product backlog after a quick search on google&#8230;</p>
<p style="clear:both;"><strong>Conclusion</strong></p>
<p style="clear:both;">Like I said before, Scrum is not magic and does not resolve lack of communication, programming errors and environment difficulties. It is just a methodology. I choose Scrum because you do not need 100 hours to understand it and to setting up the environment. You only need your team and some post-it. Managers and customers can easily understand how it works and this is not necessary the case in an IT department. Scrum helps also to avoid an overwhelmed feeling and brings democracy in a team (which is a good thing in my point of view). This is the team who is responsible and not a particular member. It brings also cohesion and team spirit.  I advise you to try it and see if it can fit to your team.</p>
<p style="clear:both;">I hope I give you a good overview.</p>
<p style="clear:both;">If you have questions, do not hesitate to ask me by comments.</p>
<!-- Social Bookmarks BEGIN -->
<div class="social_bookmark">
<a title="Click me to see the sites." href="#" onclick="$$('div.d3').each( function(e) { e.visualEffect('slide_down',{duration:2.5}) }); return false;"><strong><em>Bookmark It</em></strong></a>
<br />
<div class="d3" style="overflow:hidden">
<br />
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://del.icio.us/post?url=http://blog.dervalp.com/2009/05/08/scrum-i-believe-in-a-better-way/&amp;title=Agile+%26%238211%3B+Scrum+%26%238220%3BI+believe+in+a+better+way%26%238221%3B" rel="nofollow" title="Add to&nbsp;Del.icio.us"><img class="social_img" src="http://blog.dervalp.com/wp-content/plugins/social-bookmarks/images/delicious.png" title="Add to&nbsp;Del.icio.us" alt="Add to&nbsp;Del.icio.us" /></a>
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://digg.com/submit?phase=2&amp;url=http://blog.dervalp.com/2009/05/08/scrum-i-believe-in-a-better-way/&amp;title=Agile+%26%238211%3B+Scrum+%26%238220%3BI+believe+in+a+better+way%26%238221%3B" rel="nofollow" title="Add to&nbsp;digg"><img class="social_img" src="http://blog.dervalp.com/wp-content/plugins/social-bookmarks/images/digg.png" title="Add to&nbsp;digg" alt="Add to&nbsp;digg" /></a>
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://www.facebook.com/sharer.php?u=http://blog.dervalp.com/2009/05/08/scrum-i-believe-in-a-better-way/" rel="nofollow" title="Add to&nbsp;Facebook"><img class="social_img" src="http://blog.dervalp.com/wp-content/plugins/social-bookmarks/images/facebook.png" title="Add to&nbsp;Facebook" alt="Add to&nbsp;Facebook" /></a>
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://www.google.com/bookmarks/mark?op=edit&amp;output=popup&amp;bkmk=http://blog.dervalp.com/2009/05/08/scrum-i-believe-in-a-better-way/&amp;title=Agile+%26%238211%3B+Scrum+%26%238220%3BI+believe+in+a+better+way%26%238221%3B" rel="nofollow" title="Add to&nbsp;Google Bookmarks"><img class="social_img" src="http://blog.dervalp.com/wp-content/plugins/social-bookmarks/images/google.png" title="Add to&nbsp;Google Bookmarks" alt="Add to&nbsp;Google Bookmarks" /></a>
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://reddit.com/submit?url=http://blog.dervalp.com/2009/05/08/scrum-i-believe-in-a-better-way/&amp;title=Agile+%26%238211%3B+Scrum+%26%238220%3BI+believe+in+a+better+way%26%238221%3B" rel="nofollow" title="Add to&nbsp;reddit"><img class="social_img" src="http://blog.dervalp.com/wp-content/plugins/social-bookmarks/images/reddit.png" title="Add to&nbsp;reddit" alt="Add to&nbsp;reddit" /></a>
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://www.stumbleupon.com/submit.php?url=http://blog.dervalp.com/2009/05/08/scrum-i-believe-in-a-better-way/&amp;title=Agile+%26%238211%3B+Scrum+%26%238220%3BI+believe+in+a+better+way%26%238221%3B" rel="nofollow" title="Add to&nbsp;Stumble Upon"><img class="social_img" src="http://blog.dervalp.com/wp-content/plugins/social-bookmarks/images/stumbleupon.png" title="Add to&nbsp;Stumble Upon" alt="Add to&nbsp;Stumble Upon" /></a>
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://twitter.com/home/?status=Check+out+Agile+%26%238211%3B+Scrum+%26%238220%3BI+believe+in+a+better+way%26%238221%3B+@+http://blog.dervalp.com/2009/05/08/scrum-i-believe-in-a-better-way/" rel="nofollow" title="Add to&nbsp;Twitter"><img class="social_img" src="http://blog.dervalp.com/wp-content/plugins/social-bookmarks/images/twitter.png" title="Add to&nbsp;Twitter" alt="Add to&nbsp;Twitter" /></a>
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://myweb2.search.yahoo.com/myresults/bookmarklet?u=http://blog.dervalp.com/2009/05/08/scrum-i-believe-in-a-better-way/&amp;t=Agile+%26%238211%3B+Scrum+%26%238220%3BI+believe+in+a+better+way%26%238221%3B" rel="nofollow" title="Add to&nbsp;Yahoo My Web"><img class="social_img" src="http://blog.dervalp.com/wp-content/plugins/social-bookmarks/images/yahoo.png" title="Add to&nbsp;Yahoo My Web" alt="Add to&nbsp;Yahoo My Web" /></a>
<br />
<a style="font-size:90%;text-align: right; " title="Click me to hide the sites." href="#" onclick="$$('div.d3').each( function(e) { e.visualEffect('slide_up',{duration:0.5}) }); return false;">Hide Sites</a>
</div>
</div>
<!-- Social Bookmarks END -->
<script type="text/javascript">$$('div.d3').each( function(e) { e.visualEffect('slide_up',{duration:0.5}) }); </script>]]></content:encoded>
			<wfw:commentRss>http://blog.dervalp.com/2009/05/08/scrum-i-believe-in-a-better-way/feed/</wfw:commentRss>
		<slash:comments>2</slash:comments>
		</item>
	</channel>
</rss>
