I’m updating one of the pieces of sample code that we put on CodeProject a couple of years ago. A client wants a version of the COM object socket server that has been built with the latest version of our server framework and which supports outbound connections as well as inbound. The work has been going reasonably well until this afternoon when I found I had a problem shutting down the socket connections that I’d opened.
My ski trip is over and I’m back in the UK for a while so I expect my technical writing will resume real soon now.
A long time ago, on Practical Testing: I mentioned that there was a small chance that the way that ResetTimer() operated could mean that you could pass in a handle that you no longer owned and affect someone else’s timer by mistake; I said it was unlikely to cause problems… In this posting we fix this problem and in the process show how TDD builds up a set of tests that can support you during redesign…
Skill skiing, well, not right at this moment, we’re currently on a ‘ski holiday’ in Ireland… Back to Megève on the 27th.
I’m currently based in Megève and my blogging (over here) has tended to be more about the skiing that I’ve been doing than the technical stuff. I expect I’ll write a technical post or two later in the week… Perhaps… Unless it snows again ;)
Today we had a second Christmas celebration. Michelle and I and my sister and her boyfriend went to my parent’s house for a meal. Michelle and I had spent Christmas with Michelle’s family and my sister was away over Christmas so we’d planned to have our family Christmas today. This was all fine until Boxing Day when we saw the news about Asia. My sister and her boyfriend were spending Christmas in Sri Lanka…
Roy Osherove links to Mockpp a mock object framework for C++ and comments on how the framework is painful to use (and it looks like it was painful to write…) He concludes that he’s getting on just fine writing his mocks manually… In my experience you’d miss a lot of very useful learning and design work if you didn’t write the mocks manually…
If you’re using a mock object to help you test a piece of code that’s under development, that is, you’re doing TDD or something close, then the act of creating the mock is useful for the design work that you’re doing by doing TDD… Using a framework to create your mocks for you means that you don’t get to experience as much of the “being a client of your own code” experience as you might otherwise, therefore it’s something to avoid; IMHO…
It’s been a busy week. We got back from Verbier on Saturday and I’d hurt my knee, so I was sad, and limping and slow. I then had a mass of things to do to finish all of my client obligations by today. I collected up some blog postings that I was going to reply to, when I got a moment, and now I have a moment I find that one of them has vanished…
Today was my last day with one of my current clients. In the end the hand over went well, but then I did start the process off a long time ago….
Back in September I lamented how hand overs can sometimes become hand offs when the people that you’re trying to hand over to don’t put in the work required to take on the work you’re giving them. The blog posting worked ;) and the managers at the client site (who read my blog) set about dealing with the issue.
Updated 26th Feb 2024 to fix broken links
I find myself agreeing with Chris on this one. I just dont think I’m clever enough to use these ‘modern’ C++ template programming styles reliably in a way that makes the resulting code better and easier to maintain by others. I’ve tried, but I tend to end up with a confusing mess that I can’t understand when I come back to it. What’s more I often find that I can’t justify the additional complexity of the result compared to doing the work in the ‘old-school’ non template way.