Testing the Casino
The July meeting of the Roanoke Valley .NET User Group was one of the best ever!
During the summer months, user group attendance is usually low. Therefore, we try to have meetings that are a little less formal and require less preparation for the presenter. This July we not only had a HIGH ATTENDANCE but we had 100% MEMBER PARTICIPATION during the meeting.
Here's the formula:
- Take the Black Jack Starter Kit
- Add Bugs
- Deliver a brief presentation on Unit Testing in Visual Studio 2008
- Divide the user group into teams. Each team has
- Prearranged team leader
- Laptop with buggy starter kit
- Each team then writes unit tests to try and find the bugs
- Meeting presenters (and bug adders) assist each team and offer guidance as needed
- Give goofy prizes to the team that finds the most bugs
Some additional comments:
- Interestingly enough, each team found the same number of bugs - EVERYONE did a GREAT JOB!!! We gave goofy prizes o everyone.
- Some sample bugs added:
- Comment a line of needed code (like we might do when testing -- and then forget to uncomment)
- Change the operator of a For loop from "< 0" to "< = 0"
- There was a consistent difference between the VB.NET and C# developers on how to correct a line of code. VB vs C# note: The VB developers changed it to: "< = -1"; the C# developers changed it to "< 0"
SPECIAL THANKS to those that helped make this idea work:
- Presenter Will "El Machio" Ashely
- Why unit test
- What to unit test
- How to unit test
- Black Jack Unit Test Workshop with defects added by our own Brian "Cobra Kai" Johnston
- Starter kit overview
- Team / projector assignments
- Team Leaders: Bret Shawn, Tolga Balci and Brian Lanham
- Identify defects by writing unit tests (each team has a team leader that know a little about Unit Testing and Will is going to be available to assist all teams)
- Awards from our geek treasure chest
Photos are posted here:
Code with the bugs and Code with Unit test project have been posted here: