SIGAVDI #46: Corned beef & cabbage edition

Hello friends,

It’s been two weeks since the last SIGAVDI. I visited my kids in Pennsylvania last weekend, then came home and went into a bit of an emotional tailspin. As of today (Sunday) I’m feeling a bit better. I attribute the improvement mostly to getting some much-needed human touch and socialization over the past two days. It’s amazing how much these things help.

Heads up: I’m officially looking for a part-time consulting client. There’s some more info here; feel free to pass it along!

Some premises about my relationship with unit testing:

  1. I like test-driven development.
  2. I like driving out individual object design small, isolated (e.g. no database) unit tests.
  3. I think of these unit tests as a design aid, full stop. Any help they provide with preventing regressions is gravy.
  4. I treat unit tests as disposable. Once they have served their purpose as design aids, I will only keep them around so long as they aren’t getting in the way.

These four premises are strongly interconnected. Take away #1 (test first), and tests are no longer a design aid and none of the other points are valid. Take away #2 (isolation) and we get into integration test territory where there’s a much higher possibility of tests having regression-prevention value. Take away #3 (design focus) and the other points lose their justification. Take away #4 (disposability) and I spend all my time updating tests broken code changes.

This makes  it easy for me to find myself at cross purposes with others in discussions about unit testing, because often they come into the conversation not sharing my premises. For instance, if your focus in unit testing is on preventing regressions, you might well decide isolated unit tests are more trouble than they are worth. I can’t really argue with that.

A recent conversation on this topic inspired the thought from the driving-design perspective, maybe unit tests are really just a crutch for languages that don’t have a sufficiently strong REPL experience. While I don’t think this is strictly true, I think the perspective shines a useful light on what we’re really trying to accomplish with unit tests. I almost think that what I really want out of unit tests is the ability to fiddle with live objects in a REPL until they do what I want, and then save that REPL session directly to a test for convenience in flagging API changes.

That conversation also spawned the idea of immutable unit tests: unit tests that can only be deleted, never updated. A bit like TCR. I wonder if this would place some helpful incentives on the test-writing process.

So I tweeted about some of these thoughts and someone was like “don’t say that in public, you might lead junior developers astray”. And it got me thinking about how I’ve said similar things in the past. There’s a trope in the developer practices conversation that goes: “there are some things experts do which we shouldn’t talk about in public, because someone impressionable might get the wrong idea.”

The more I think about this, the more I wonder if it’s healthy or constructive. What do you think?

Sometimes you make me feel like I’m living at the end of the world.

— The Cure, Plainsong

I’ve been thinking and talking to friends about apocalyptic relationships. That’s my phrase for relationships that are premised on a model of “you and me against the world”. Imagine the post-apocalyptic film or novel of your choice, with the two romantic leads braving a treacherous wasteland full of bandits and mutants, and you have the right idea.

Apocalyptic relationships are inward-facing. They survive on the energy of “anti”. They have only one speed: intense. They draw their intensity from scarcity. You and me: we’re the only ones who can help each other through this hellscape.

For many years I was in a relationship that only really worked when it was in the apocalyptic mode. Now I feel like I’m keenly sensitized to the “smell” of potential apocalypse. I’ve been talking to friends about their experiences with apocalyptic pairings. Once likened it to a “Bonnie and Clyde” feel. A relational suicide pact. They all agree though: these relationships are engrossing, intoxicating, profoundly difficult to move on from, and they feel like nothing else could ever come close in terms of intensity of feeling.

I’d be curious to hear your experiences and thoughts, if any.

OK, let’s see how I did:

This week my friend Janelle is visiting (you should check out her book!). We’re mostly going to be working on our own respective projects, but I’m hoping to make some kind of collaboration emerge as well. Goals for the week:

  • Stream/record some kind of collab with Janelle (IdeaFlow demo??).
  • Finalize my new working arrangement with Cohere.
  • Get to a tentative agreement on a consulting gig (probably over-optimistic but I can hope).
  • Nail down April travel plans.
  • Clean up the weight room and do some lifting.
  • Sundry RubyTapas and Rubber Duck meetings and related work.
  • Attend a new meetup (I have one picked out already!)
  • Attend some part of Big Ears Festival.

OK, that’s it for this week. Thanks for reading!

Leave a Reply

Your email address will not be published. Required fields are marked *