I am Probably Not
February 7, 2009 by johanneslinkAnd the Birds they Are Singing
February 4, 2009 by johanneslinkI’m definitely not the first one to write about their twitter experiences. I especially like this presentation because it sort of reflects my past two months of twittering, and gives me some inkling of what I might see there in the future.
There were two reasons for me to get onto the train in the first place:
a) I was told by many that the cream of the technology crop had already moved away from the blogosphere. If I wanted to be in on the most recent trends and tools and techniques I would have to follow people’s tweets instead of their weblogs.
b) Due to a chronic writer’s block I needed a way to get some stuff out without having to write full sentences or even paragraphs.
I feel like a lucky guy considering the fact that hardly any one from my personal life is on twitter, so I only follow 30+ people on a regular basis. That’s both not much and quite a lot. It does not take me long to read the 50+ updates per day and identify the 5+ that trigger something in me. But it would take all day to follow up on the 5+ topics, so I do that for only 1 or 2 per day. I actually feel closer to the origin of new ideas and I guess I know a bit more about the (mostly) humans whose tweets I follow. On the other hand, it’s my impression there has been nothing so far technologywise which I wouldn’t have learned about through a different channel.
How about my own writing? In the beginning I was quite self-consciuos as more people started to follow me, quite a few of which I really consider to be top notch in their field. This self-consciousness made me polish my updates to a ridiculous degree. Spending 30 minutes to spit out <141 characters: How vain can you get? Change made its way, though, after about a month (and a skiing holiday). Since then I basically write what comes to my mind and what I consider worthwhile to read for at least one of my followers. My rule is to not spend more than 5 minutes on a single post; if I catch myself doing otherwise, I delete all text and go back to real work.
Will I go on twittering? Abolutely, at least for the time being. Do I feel addicted? Not really, it’s more like a comfortable way to procrastinate. Should you follow me? Do as you please, I won’t hold it against you either way.
Keeping Up My Programming Skills As a Non Programming Consultant
January 18, 2009 by johanneslinkWorking as development coach instead of as contracting developer has at least one crucial advantage: I can charge a significant better rate since daily rates for “mere programmers”.
But there is a reverses side to the same coin: People – my customers – don’t pay me for programming any more. I might be allowed to pair with their development staff from time to time to TEACH certain skills like design or OO or TDD or mocking. But the intensive programming experience with (pair) flow, new technologies, LEARNING and everything is out of reach for me during my payed time. So I have to confess that I wrote the last line of real code, ie. code someone payed for to do important business stuff, almost three years ago. Honestly, I’m somewhat ashamed about that since I’ve always stated – and stated very loudly – that those who don’t program any more shouldn’t tell others about programming.
For a while a I tried to counter my loss of actual programming practice by doing small OS projects on the side and reworking my workshop exercises to a ridiculous degree. This does not yield the same benefits, though, as programming for and with others. That’s why I used an open space session during XP Days Germany 2008 to offer the start of a “development project for bored consultants” and invited fellow retirees to join me for regular (remote) pairing sessions – and real meetings once or twice per year. Of course, it always takes longer to make the first step, but I’m proud to anounce that the kick-off meeting will eventually take place in a few weeks. We are seven people so far which leaves plenty of room for other enthusiasts to join us. Drop me an email if…
- you’d like to spent (at least) one day per month in a project with other agile consultants and you are willing to give this project priority on that day.
- you are not too strongly opposed to start (test-driven) development with Groovy and Grails.
We are planning to do most of the development work in remote pairing sessions. Up to date the participants are spread widely (but not evenly) across Germany, so there might be some chance to meet for programming sessions from time to time. The kick-off will be held on February 20 & 21 in a place not too far from Frankfurt. We’d all be delighted to have a couple of more faces show up.
P.S.: Thanks, Willem, for pointing out the best remedy against writer’s block
Can You Touch Type?
September 15, 2008 by johanneslinkWell, I can’t. That’s why it struck a chord with me when I read Steve Yegge’s rant about those developers who claim that typing is not really important for fluent programming. The article is a very funny read and it left me determined to learn touch typing now – not today, but tomorrow – or maybe the year after tomorrow.
Can anyone recommend a good touch typing teaching software in German?
AJAX Travelogue (Part 7): MockMe
August 9, 2008 by johanneslinkIn the previous episode you’ve learned why a mocking framework seems to be a reasonable idea even in a language that provides closures and duck typing. MockMe is such a framework. I started to develop it after fighting the usability war with the existing ones I found out there.
MockMe has two fundamental ideas:
- The basic granularity of mocking should be the function. If I want to, I can fake the behaviour of a single function without influencing the rest (of an object or a prototype or the global namespace or whatever).
- Most of the time, spying is a better idea than mocking because it’s simpler. Spying basically means that, instead of specifying the expected interaction with your mock spy object before doing the test, you use the mock spy object to spy into the interaction as it happens and verify that afterwards. In that respect I borrowed heavily from mockito, a spying framework that’s gaining more and more attention in the Java world.
Let’s look at the example from yesterday:
var Speaker = {
say: function(msg) {
alert(msg);
}
};
var DoubleSpeaker = {
say: function(msg) {
Speaker.say(msg+msg);
}
};
We would like to write a test for DoubleSpeaker.say to verify that Speaker.say is being called with the argument duobled. Using MockMe the test looks like this:
testDoubleSpeaker: function() { with(this) {
mock(Speaker).andDo(function() {
DoubleSpeaker.say('oops');
verify(Speaker.say)('oopsoops');
});
}},
That’s fairly easy, isn’t it. It has only a third of the lines compared to the hand-crafted version.
There are mainly two reasons I prefer spying over mocking: (a) It does not break the standard testing flow of setup -> test -> assert. (b) It’s harder to overspecify your implementation’s behaviour.
The difference between spying and mocking has been described by Gerard Meszaros in his book on test patterns. Among many other valuable contributions he succeeds in sorting out the differences in the terms used by different writers. That said, I still call MockMe a mocking framework for the selfish reason that mock has become the term that is being used most in the agile testing community.
To wrap up, the next example demonstrates that stubbing with MockMe is equally straightforward:
testStubbing: function() { with(this) {
useMockerFor(function(mocker) {
var f = mocker.mock();
when(f)(1, 'two').thenReturn('hiho');
assertEqual('hiho', f(1, 'two'));
});
}}
Here is where you can find more on how to use MockMe.
