AgileDotNet Conference…

November 11, 2008

AgileDotNet Conference 2008
This Friday, Improving Enterprises and Microsoft are putting on a 1-day FREE (as in beer) conference to showcase agile methods in a .NET ecosystem. I will be giving my “Refactoring To Patterns” talk on the development track but there will also be two other tracks (Biz/PM related & Requirements/QA related) and number of knowledgeable speakers. I’m really looking forward to hanging out with folks and sharing ideas on how we can better promote and utilize the systems we work with to adopt agile practices and principles.

Regardless of whether you’re new to agile concepts or already moving towards adoption, you will have an informative and good time. If you’re interested, go sign up while there are still spaces available.


David O’Hara is a Principal with Improving Enterprises in Dallas, Texas.


Honored…

October 7, 2008

MVPLogo.gifHaving only thrown myself into the community relatively recently, I was honored (and a bit surprised) to have been given this award. I look forward to the opportunity to continue sharing the things that I’ve learned and spreading the motivation to become a better developer. I want to thank my family for putting up with my extracurricular activities and being supportive of me following my passions. Also, a thank you to Microsoft – I take back like 3 of those things I said about you last week.

Next on my list of awards to achieve, an honorable hair mention from Justice Gray


Introduction to CodeRush: Part 1

September 1, 2008

I believe that anyone not using a productivity tool with their IDE is wasting time and, quite possibly, ripping off their employer/client. I don’t care if it’s CodeRush, Resharper, CodeSmart, or whatever but you should get a tool, get familiar with it and use it for everything it’s worth. I enjoy using the CodeRush/Refactor Pro! tools. As a matter of fact, I feel like I can’t hardly use Visual Studio without them. The only drawback I’ve found with CodeRush is that discoverability is just not there and with the vast array of capabilities, a lot of folks would rather do without than flounder so I’m hoping that this will help to ease that learning curve.

This “episode” is the first in a series screencasts I’ve been trying to put together for a while and I’m hoping that it will introduce the new user and maybe even show some existing users a few things that they didn’t know. I’m certainly no professional video editor so please excuse the quality while I try to find the right mix but I would appreciate your feedback.
Anyway, we’ll take a look at the structure markup that CodeRush does to help enhance readability and decorate code to make certain aspects visually evident. And we’ll be introduced to the mnemonic templating system and how just a few keystrokes can turn our intent to code.


Announcement: NDDNUG – Refactoring To Patterns

July 6, 2008

On Wednesday, July 9th, I’ll be giving a talk at the North Dallas .NET User Group called “Refactoring to Patterns (Not the Book)”. It’s not going to be some dry, academic talk with and bunch of UML and “Hello World” examples but an example using “real world” code like what you and I work with in our every day lives. The main patterns we’ll focus on for this web application are Model-View-Presenter and Adapter. My intent is to show the things that I’ve discovered in journey towards better, more maintainable code and provide ways to apply that knowledge in a realistic fashion. This is going to be a code intensive talk and, hopefully, a very interactive one.

Here’s the sign up form – I hope to see you there.

UPDATE: Here’s a link to the Google Code repository that contains both a start and end copy of the solution so you can see and try the refactoring that was demonstrated.


David O’Hara is a Principal with Improving Enterprises in Dallas, Texas.


Reducing Unit Testing Friction…

June 26, 2008

Gears.jpgIt doesn’t matter if you’re a TDD purist or a test-as-you-go guy, having a quick way to execute the tests that you’ve created is critical to them actually getting run as regularly as they need to be. To that end, here is the current setup that I’m using to make this as easy as possible.

Everyone knows that I’m a sucker for a new tool but this tool has been with me for quite a while and I’m skeptical that anything will be able to replace it. TestDriven.Net is the foundation of a great workflow when it comes to unit testing and it’s truly worth the small amount that Jaime asks for his efforts. He’s a great guy and it’s a great tool – go buy it and install it immediately.
So now that you have it installed, there a couple of settings in Visual Studio that help make that test/code/test cycle even tighter.

Keyboard shortcuts

Once you have TestDriven installed, you’ll notice some extra options in the context menus when you right-click on class files, projects and even in code. These will allow you to run tests in various fashions but I’m a lazy man and I hate moving my fingers off the keyboard so I’ve added a few shortcuts to Visual Studio. In the options menu for “Keyboard”, I bind Control-1 to “TestDriven.NET.RunTests”, Control-2 to “TestDriven.NET.ReRunWithDefault”, and Control-3 to “TestDriven.NET.ReRunWithDebugger”. The way this helps me is that I am able to use Control-1 to execute the test that the cursor currently resides in (if you’re in between tests or on the fixture itself, it will run all in that fixture). If it doesn’t pass, I can hop over to the code that’s being tested, make the changes and then just press Control-2 to see if the test passes. No back and forth between the two. The last shortcut is helpful because it allows me to set a breakpoint where I am (using F9 of course) and rerun the test so that it will hit that breakpoint. Again, no back and forth.

Output window

Every time you execute a test, the tool bar will give you a quick look at the status but the output window will be your friend when things don’t quite execute as planned. All the output gets piped here but you don’t need it in your face so be sure that the “Show Output window when build starts” is unchecked but also be sure that you have it collapsed just below your code file. output window.jpg This way if you do have need to see what is in the output, you can just press Control-Alt-O and it will pop up with focus. (Pressing Escape will cause it to hide again and leave us in our code.)

I still haven’t quite figured out how to bind to the “Run All Tests” so if you have a suggestion, I’d love to hear it. However, I do still find it helpful that a “Run All Tests” will execute again when using the rerun shortcuts and I use that quite a bit right before commits. (If you’re not religious about running ALL tests before a commit, I hereby grant your co-workers permission to knee-cap you.)

Because unit tests only provide benefit when they are actually run, we need to do everything that we can to tighten the code/test loop and make executing the right thing at the rightht time as easy as possible.


David O’Hara is a Principal Consultant with Improving Enterprises in Dallas, Texas.


Follow

Get every new post delivered to your Inbox.