I started an enjoyable discussion on Twitter the other day. Here’s a brief summary.

So I idly wondered whether it was possible to construct a barber-style paradox around context-driven testing (CDT) and tweeted this:

A Context-Driven tester says that CDT is not applicable on some project, given the context, and tests accordingly. Is this CDT?

I deliberately left this ambiguous. It could mean a few things, including:

  • deciding how to test in the context
  • any testing activities undertaken after evaluation of context 
  • both of the above 
  • all of the work the tester does on that project

I think it’s possible to make a case for all of them being CDT based on the original tweet. But it doesn’t mean that any particular instance of them must be.

For example, the context-driven tester might not act in a context-driven way at some point (perhaps only context-aware). Or while not doing CDT the context-driven tester might actually be constantly re-evaluating the context looking for a point at which the context changes sufficiently to prefer another approach, i.e. practising CDT. The Twitter thread didn’t really explore this aspect.

There was keen discussion about whether it was even possible to find a place that CDT was not appropriate and @huibschoots dug up a link to a Bach/Bolton presentation that suggests a few.

Some testers said that they would always do CDT here. This example from @kengel100:

@qahiccupps @huibschoots @kinofrost if I place myself in this situation there is still a need for CDT. Tester dependent?

In an attempt at clarity, multiple definitions of CDT are given at context-driven-testing.com. One includes this:

The essence of context-driven testing is project-appropriate application of skill and judgment.  

I didn’t give any project context. There is none, it’s a thought experiment. The context-driven-testing.com web site also says:

Context-driven testers reject the notion of best practices, because they present certain practices as appropriate independent of context. 

So I speculated about whether there was an argument that it is not context-driven to insist on CDT, particularly given that there are some occasions where it’s plausible to think that CDT might legitimately not be used. I suppose I’m also thinking about whether asserting that you will always practice context-driven testing effectively makes CDT your best practice.

@kengel100 @huibschoots @kinofrost Interesting variant question. Is it CDT to say that we must approach any problem using CDT? Does a tester self-declared as CD use CDT in all contexts? (i.e. regardless of context)

@kinofrost put his response to the idea that there was a contradiction in having the intention to do CDT irrespective of context nicely:

@qahiccupps @kengel100 @huibschoots It’s self-refuting. Like saying there’s a car driver who always drives car irrespective of having a car.

So I ended up asking myself whether I was worrying away at a potential something or making a something out of nothing.

@kinofrost @kengel100 @huibschoots Started with a hypothetical corner. Wondering if I’m digging a hypothetical hole. 

Image: https://flic.kr/p/hnimz3