Save some space - limit the number of old test results

Found an option that really saves some space for TDD:ers in Visual Studio. The test results folder can be limited to a certain number of test runs. That would really have helped me at my latest project where my Test Result folder was several GB.

Go to ToolsOptionsTest ToolsTest Execution.

When you first exceed that number, you’ll be warned that folders will be deleted - thank you very much!

Read More

Sprint Planner Helper – Session 2

OK - if you want to do DDD then you better start out with the Domain Model. So today I created a Class Diagram for my domain. I also try to follow the Extreme OOP rules and TDD (whooa - my head will explode) and use them to guide me through the process.

OK - that was quite exciting. I am not done yet - but I got a first domain-model up and running and started to mass produce unit tests.

I had some trouble with converting back to C# after two year in the VB.NET swamp (Me/this for example) but that will soon be over. Also the support in the studio is sooo much better for C#. I love it - this is what Visual Studio was made for.

**[UPDATED] **I moved the snippet for creating test methods to a post of it’s own. You’ll find it here.

...
Read More

First day of parental leave - I love it!

OK - my first parental leave day is well on the way. You should try this - it’s great!

I thought that I would upload some photos of Albert as the time progress to see how he is developing. Here is one from a few days back.

Right now he’ll walk if I hold his hands, and he talks a lot with two words: Pappa and Albert.

Read More

Sprint Planner Helper – Session 1

I started off very pure and true to the noble principles of TDD and Extreme OOP. Actually, I did decide on a few naming conventions first: the name of the product is Sprint Planner Helper and it will reside in the namespace Marcusoft.SprintPlannerHelper. I also created four projects like this (idea stolen from ASP.NET MVC Storefront):

  • Marcusoft.SprintPlannerHelper.Models - my domain model
  • Marcusoft.SprintPlannerHelper.Service - any services needed for the model, such as database access and so on
  • Marcusoft.SprintPlannerHelper.Web - the ASP.NET MVC Web Application
  • Marcusoft.SprintPlannerHelper.Test - the unit tests of the application

Then I removed all the Class1.cs from all the projects that defaulted them to me. At this point, I realized that I was missing Visual Studio 2008 Power Commands and Resharper at the computer I was using. Had to download them -...

Read More

Sprint Planner Helper - Administration

OK - to get started with this project, I first needed to handle some administrative tasks. I’ve set up a CodePlex project where I will keep the source code. You can find it here: Sprint Planner Helper on CodePlex. You can apply for access to the project to get hold of the sources as they become available.

During the setup, I discovered that the Team Explorer Client used to connect to a TFS Server is actually free! You can download it here.

I also decided to keep the project completely freeware. I will avoid using any paid products to ensure that anyone can reproduce the project on their own machines.

The project is coming along. I’ve created the solution and added my product backlog. Next, I’ll be working on setting up the projects.

P.S.
I also downloaded the ASP.NET MVC 1.0 release candidate, which...

Read More

What to do now - Sprint Planner Helper Initialization

I’m free!!! So what do I do now. I have been talking to my colleagues that now that don’t have to do boring work with them ;) I need another project in order to stay in touch with the IT-business.

Here is the reasons for me doing this at all:

  • Have fun! - the second it’s boring or takes to much time I’ll end it. Promise
  • To learn about DDD, TDD and ASP.NET MVC. These three things has attracted a lot of my interest I would like to try them out out. Oh yeah - it will be in C#! No more VB.NET for me - thank you very much.
  • Cannot take to much time (max 1 hour a day) - as stated earlier. I am not working!
  • Document my progress here on the blog. This idea is a complete rip off from a lot of...
Read More

Clean Code - The Pragmatic Approach

As I mentioned in my previous post, I am currently reading Clean Code by Robert “Uncle Bob” Martin. It’s a great book!

However, having a 200-page book with rules on coding can become overwhelming, especially when trying to adopt these practices within a team.

A while back, we discussed an essay by Jeff Bay called “Object Calisthenics” extensively in the Microsoft community at Avega. This essay offers a very pragmatic approach with 9 rules on how to code.

You can find a PDF version of the rules.

I found that many of the principles Uncle Bob discusses in Clean Code are naturally followed if you adhere to the rules in Object Calisthenics.

I’ll try this approach out sometime. It does seem like a bit of a tough pill to swallow when you look at the list, though.

Read More

Last Day - New Chapter

I have come to a fork in the road of my life (that almost sounds like a poem :)).

Today is my last day on this assignment, where I’ve learned a lot. This time, I’ve delved into SOA, WCF, TFS, AOP, and build scripts, along with SCRUM.

The SCRUM part of this experience was almost a religious one. I feel like a different and better consultant after learning SCRUM, and I don’t think I’ll ever go back.

The future holds six months with Albert and Elin. I will be “daddy-free” (a direct translation of “pappaledig” for all you Swedish readers). This is a wonderful benefit in Sweden where you actually receive money from the government to stay home with your kids. Amazing!

Elin is working nights right now, which means she has a lot of free time during the day. This allows us to spend...

Read More

Create Text File on the Fly in Build Scripts

Yesterday, we made a final touch to our build script (by “we” I mean “I talked about it for five minutes, Christer did it”).

We needed to create a .bat file that installs our database for a specific version and environment. The necessary information is only known at runtime in the build script.

I remembered there was an MSBuild community task for this purpose, and Christer found the task WriteLinesToFile. He then wrote the following target to create the .bat file:

<ItemGroup> <CmdLine Include="@ECHO OFF"/> <CmdLine Include="ECHO About to install version $(BuildVersion) on environment $(DeployEnv)"/> <CmdLine Include="SET /p passw=Enter DB password for $(DeployEnv): "/> <CmdLine Include="CALL main.bat $(DeployEnv) . $(BuildVersion) %passw%"/> <CmdLine Include="PAUSE"/> </ItemGroup> <WriteLinesToFile File=

      Read More