Get a Wii Fit without getting ripped off


As you probably know, the Wii is the most popular console this year. And, the most popular game is the Wii Fit. Because of this, you are seeing Wii Fits on eBay selling for $150 – $200+ and on Craigslist for $125+ (primarily used). Considering the game sells for $89, this is a huge ripoff.
 
Online merchants are taking advatage of the disparity too. Those that have it in stock are selling for $140+ (have seen more than $200) for the console alone. Even Toys R Us, which is bound to sell the unit for only $89 has figured a way around it. Bundle it with a game they are currently selling for $35 and charge $169 ($35 more than the two together).
 
What’s a guy to do?
 
Go to http://wiitracker.com/wiifit and watch the site. They check for units every 10 minutes on a variety of sites. When one becomes available for a price you like, click the link and put it in a shopping cart and order it. I ended up getting a bundle with the 5-in-1 Wii Fit Fitness Bundle for $128 ($89 console, $38 bundle). I could have waited a bit, as I have seen a $90 console pop up a few times, but the kids are anxious to get going. I would imagine I can return the bundle, as it is charge separately on the bill, but it has a nice cover for the balance board, so I will give it a chance.
 
You should not pay more than $90 for a $90 game.
 
Peace and Grace,
Greg

Behavior Driven Development (BDD)


I have been developing lately using Behavior Driven Development, or BDD. I am not using a "true" BDD "product" like Behave# at the moment, so I am merely attempting to tailor my tests to focus on behavior. Thus far, I have focused more on business objects, so the tests are a bit less use case type of behavior, but I like what I see thus far.
 
I am not using VS 2010, which allows you to use a test first approach. This is not a major issue, overall, except that I am not being a true purist at the moment. I am stubbing in the classes prior to the test, in many cases. When I do, I stub in so the tests red light. I wish 2010 was already out, so I could be a better boy, but I am not going to install 2010 on a machine where i am doing productoin work. That is fine, as you cannot install it now anyway. 🙂
 
 DISCLAIMER: I am new to this.
 
Her eis how I see it with business objects. I will read some more prior to cementing this approach. If anyone is extremely BDD savvy, please critique. I would love to learn more.
 
Essentially, my unit test classes are set up to indicuate the condition, or behavior, being tested. For object instantiation, it ends up like so:
 
    [TestClass()]
    public class when_creating_a_column_from_values
    {
    }
 
and
 
    [TestClass()]
    public class when_creating_a_column_from_a_column_row
    {
    }
 
I then set up the expectations. For the constructor, the test is something like:
 
        [TestMethod()]
        public void should_create_column_object()
        {
        }
 
I then have some tests, using the same default data, for the different properties of the object. As these are business objects, the behavior is just instantiation of the objects and making sure the properties fill corretly, both from constructor and when set is called. I have worked out the tests for Column, ColumnCollection and DbTable. What is cool is I can create my test lists with the same name as the class, thus when I see a test fail, it will appear in the test runner like so )wioll get a pic later):
 
when_creating_a_column_from_values     scale_should_be_set_to_zero
 
I can then discern that the scale is not zero, which will more easily lead me to the actual problem without digging too far into the test code. Thus far, it seems to be saving a bit of time, but I will defer the final analysis until I have used it for some time. I do think this way of setting up tests is clearer than the Class for Class way, ie:
 
[TestClass]
public class ColumnTests
{
   [TestMethod]
   public void ScaleTest()
   {
   }
}
 
I know that setting the Scale property failed somehow, but I am not sure what the expected outcome is without digging into the test results. Not a big deal, but I like the BDD method a bit better.
 
As I am seeing BDD, I can see ending up with numerous test classes, unlike the "traditional" way TDD is taught in Visual Studio (which is not a purist approach). For example, if a single object has multiple behaviors, you will have a class for each one. This is not a real issue, but it is something to consider.
 
As I go forward, I am wondering how I should set up my test projects. Do I group the etsts the way I do now, which is a test library for each class library project? Or, do I group behavior? Or perhaps, a library for a library, with behavior grouped in folders. So many questions. I am sure I will figure out what is most comfortable as time goes on.
 
Tomorrow, I will get into the meat of the application and the placement of the tests should ferret out a bit. I am going to leave a library for a library right now, with a few folders, as needed, to organize the test code. Thus far I am enjoying the paradigm shift. I need to read a bit more tonight before I go to bed.
 
Peace and Grace,
Greg

Visual Studio 2010 and TDD


I have been playing with Visual Studio 2010 a lot lately. I am, overall, impressed with where they are going, but I have found that the CTP is stil a bit rough. For the record, I have not gotten an dog food drop from Microsoft, so I can freely talk about my findings.
 
It is nice that Micrsooft is finally adopting a test first approach. I can now write my tests up front and then implement the class and the methods from the test code. One thing I have noticed, however, it only recognizes classes without a static method. For example, I wrote the following test code.
 
[TestMethod]
public void
       should_return_a_value_between_1_and_10_with_null_seed()
{
 int? min = 1;
 int? max = 10;
 int? seed = null;
 
 int actual = RandomGenerator.GetRandomInt32(min, max, seed);
 Assert.IsTrue(actual >= min, "Value is less than min value.");
 Assert.IsTrue(actual <= max, "Value is more than max value.");
}
There is nothing stellar about this particular test method. It is simply a call on a static method. Yet, the IDE does not respect the control + period to bring out the drop down. The solution, in the CTP is to write a line like the following:
 
RandomGenerator generator = new RandomGenerator();
 
This will allow you to use control + period and create the class. One other little glitch in the process. The class created will bear the namespace of the test project, even when you create it in another project. This is minor, but I hope they have this respecting the actual class by RTM.
 
I have one wish on my wish list, as well. I wuld like to have it create the project, if it is not already present. Under the current implementation, I have to creat the project and then run the refactor to create the class. This is not a major deal, but it would be nice to have it create the entire project. Yes, this menas I have to use full syntax in my test code, but what power it would yield.
 
Peace and Grace,
Greg