Rants, rambles, news and notes from another geek

Mastering My Machine Repaves With Git and PowerShell

You repave how often?

I’ve always been someone who likes regularly rebuilding my Windows machines. (See this post or this post for some ancient history on this.) I know this isn’t needed as much as it used to be, but I still find myself starting to get that itch anywhere from 6-weeks to 3-months after I last flattened the box.

I’m convinced that part of this is due to my willingness to try out new apps, hack on things, mess with my registry, try beta drivers, etc. Say what you will… Those things make me happy!

So rather than curtail those things, I just figure out ways to get around it. As I like to explain to my wife, “What I really enjoy is bending computer to my will.”

Solarized Colors for Visual Studio 11

Update: I sent a pull-request to David Thibault and this update is now in his mainline repository.

I’m sure everyone and their dog knows by now that we changed the color theme in VS11 Beta to something a little more… ummm… monochromatic.

If you didn’t read about it, you should visit the Visual Studio blog and read Introducing the New Developer Experience.

Regardless of what you think about it, I do know that the UX designers had an admirable goal in mind, and that was making the code be the bit you see the most, and take the chrome out of your line of sight. The idea is to let you focus where it matters and not have Las Vegas lights happening all around it distracting you.

Regardless, I’m not here to comment on all that, but on what I like to do to make the experience even better.

SOLARIZE IT!

Return of Game of Thrones

How psyched was I when a few weeks ago my wife Emily decided to start watching Game of Thrones (which I had kept on our media server hoping this would happen). You see, I’ve read all of the books and thoroughly enjoyed the HBO adaptation of Book 1. But she’s not historically been a huge fan of sci-fi or fantasy stuff.

But when she came to me and said, “Honey I can’t stop watching it,” I knew she was hooked and I’d have someone to watch Season 2 with. She also has had a thing for Peter Dinklage since The Station Agent, so that helps a bit. Ned getting killed at the end of Season one sent her for a bit of a loop, but she’s just gonna have to get used to George R. R. Martin killing off characters.

So now each week we sit together and enjoy the carnage that is this world. The season is going well so far. It seems to be following the book reasonably well, and of course they’re working in all the new characters we’ll need for this book’s storyline. I don’t want to give anything away, but it should be quite interesting to see how they handle some of the things to come.

Visual Studio 11 Fakes Part 1 - Stubs

Background

Over the years I’ve heard many customers ask us to ship a mocking framework in Visual Studio. I was always a bit cautious about providing this for a few different reasons.

First, I’ve always been hesitant to recommend “mocks” when unit testing, preferring stubs in most cases. For anyone unsure of the difference between a Mock and a Stub, I suggest you read Martin Fowler’s excellent article Mocks Aren’t Stubs.

On the one hand there is a difference in how test results are verified: a
distinction between state verification and behavior verification. On the other
hand is a whole different philosophy to the way testing and design play
together...

Basically a stub is a test fake (or dummy) that is used as a stand-in for the real type. You do this to avoid having to pass in a real object, which would extend your test beyond the realm of “unit”. They are frequently used when doing classical “Arrange, Act, Assert” state-based testing. A mock, on the other hand, provides not only a fake implementation but also logic for verifying how calls were made on the fake. When you are testing side- effects, protocols and interactions between objects, they are extremely valuable.

Switching the Blog to Octopress

A week or so ago, Mark Groves mentioned to me that he was thinking about going to a totally static blog system for his photo site. He pointed me to some of the cool work done by the Code 52 guys, particularly Pretzel and Markpad.

I’ve been a fan of Markdown for quite a while and have been using it on my GitHub project pages for the readme content, but I’m not really sure why I never hit upon the idea of using it for my blog posts and translating it to HTML in a kind of a compilation pass. Editing blog posts in Vim feels very natural to me, but I hate the idea of having to write HTML and all that crap. Markdown is a lot more natural to write. I also like the idea of getting off of a particular content management system / blog engine, of keeping my content in a source control repository, and of having total freedom of hosting. And of course, you can’t beat static HTML for site responsiveness.

What's New in Visual Studio 11 Beta Unit Testing

For those of you who haven’t been following the changes to unit testing that we first previewed back at the //BUILD/ conference, and for those you who did but want to know what has changed, this post is going to take you through the whole thing. We have made a lot of changes to testing in Visual Studio. These changes are pretty drastic in some cases, but were driven by years of customer feedback and a clarification of our focus and vision.

Visual Studio 11 Beta - Unit Testing Plugins List

One of the things I’m really proud of in the new Visual Studio 11 developer experience is the investment we made in developer and unit testing. We first started talking about this back at the //BUILD/ conference, and since then have spent a lot of time working with community partners to get them ready for the Beta release today.

I’m very happy, therefore, to be able to highlight the frameworks & test runners that have shipped support for VS11 Beta. (More to come, see below.)

Unit Testing With MSTest, xUnit and NUnit in the VS11 Developer Preview

Back in September, at the //build/windows conference, we were very excited to get to show off our new unit testing experience for Visual Studio 11.

One of the things we heard over and over since we first shipped unit testing in VSTS was that customers wanted a) to be able to run whatever unit testing framework they want and b) it has to be fast an non-intrusive. Thus was born our new experience.

Free Test-First Development Training - 24 Hours Only

For anyone with teams or managers wondering about Test-First Development or TDD techniques, my friends at Pluralsight are giving a free course for the next 24-hours. TDD expert David Starr and Scott Allen will take you through the history, background and techniques. He also includes data in support of test-first practices in case you’re in a situation where you’re getting management pushback.