Think Code AB Blog http://www.thinkcode.se/blog Thoughts and opinions from Think Code AB What is the size of a baby step? http://www.thinkcode.se/blog/2019/05/18/what-is-the-size-of-a-baby-step

It is easy to agree that baby steps are good when doing something complicated. They allow you to move slowly but steadily. That is why baby steps are recommended when doing software development.

If we agree that baby steps are good, the next question is "How large is a baby step?"

This is where it gets interesting and this is where I see different interpretations.

]]>
What is BDD? http://www.thinkcode.se/blog/2019/04/24/what-is-bdd

Defining what Behaviour-Driven Development, BDD, is not easy. It is sometimes described as a bounded context of ideas.

What is rather clear to me is that there are a two properties everyone seems to be able to agree upon.

These are:

  • Conversations - talk to each other and get a better understanding
  • Concrete examples - share concrete usage examples for a better understanding

In order to get full benefit from these, I want to add

  • Automated acceptance tests - transform the concrete examples into executables examples
  • Code - write the production code that implement the rules checked by the concrete examples

to the list.

]]>
How to implement a Cucumber-JVM plugin http://www.thinkcode.se/blog/2019/03/07/how-to-implement-a-cucumberjvm-plugin

Cucumber-JVM comes with some built in plugins. They are mostly used for reporting. If the built in plugins aren't enough for your needs, it is possible to implement your own plugin.

This blog post will show you how to

  • Implement a plugin that will receive events from Cucumber
  • Add that plugin as a part of your execution
]]>
Kubernetes service node port range http://www.thinkcode.se/blog/2019/02/20/kubernetes-service-node-port-range

The default node port range for Kubernetes is 30000 - 32767. As it is a default, a reasonable assumption would be that it can be changed. So far so good. However, it turns out that the documentation on how to change the default is hard to find.

kube-apiserver

The port range is controlled by the kube-apiserver which is a pod running inside your Kubernetes cluster. It is created from a pod definition located in /etc/kubernetes/manifests/kube-apiserver.yaml.

]]>
A Jersey client supporting https http://www.thinkcode.se/blog/2019/01/27/a-jersey-client-supporting-https

When testing a rest service behind https, you must be able to create a client that supports an encrypted connection.

The trick is to create a javax.ws.rs.client.Client and set the sslContext as well as the hostnameVerifier() properly.

]]>
Data tables in Cucumber 3 http://www.thinkcode.se/blog/2018/06/30/data-tables-in-cucumber-3

Version 3 of Cucumber for Java has recently been released. It brings Cucumber expressions to Cucumber-JVM. It also brings a new implementation of Data tables.

From a Gherkin perspective, nothing has changed. Data tables are supported as earlier. As a developer you need to adapt the steps a bit.

]]>
I T.A.K.E. Unconference 2018 http://www.thinkcode.se/blog/2018/05/20/i-take-unconference-2018

In june 2018 I will return to I T.A.K.E. Unconference in Bucharest, Romania. I run two sessions there:

These two sessions combine something I think is very important. They combine clean and understandable code with discovering what to implement. Understanding what to do is often more valuable than to know how to implement something. Implementing the wrong solution may even be harmful and is just as much waste as implementing something wrong.

]]>
What does BDD really stand for? http://www.thinkcode.se/blog/2018/04/17/what-does-bdd-really-stand-for

BDD is the acronym for Behaviour-Driven Development. It is a way to describe the behaviour of a system and a way to make sure that it is developed to behave as it should.

BDD is used for understanding what to create and for verifying the result.

Business-Driven Development

But BDD could also be the acronym for Business-Driven Development. BDDers work really hard to bridge the communication gap between development and business. We really try to involve the business people in the development. We value their input and love discussing concrete examples describing what the system should do. How it is done is less important when understanding what really matters for the business. Focusing on the what and not the how is a differentiator between communicative developers and regular developers.

]]>
Testing stage 2018 http://www.thinkcode.se/blog/2018/03/26/testing-stage-2018

In April I will be talking at Testing stage in Kiev, Ukraine

I have two sessions:

  • Test automation - the supporting architecture
  • Why is good design important for test automation?

They are connected in the sense that they are both about how to implement the support code you need for your test automation initiative. As a developer, I know that how you implement code is really important. It is ultimately a matter of maintainability. And maintainability is probably the most important property a piece of code can have after being correct. Code that can't be maintained will create problems for you during the entire lifetime of your product.

]]>
Getting started with Cucumber for JavaScript http://www.thinkcode.se/blog/2018/02/07/getting-started-with-cucumber-for-javascript

I usually describe myself as a Java backend developer. That is actually not completely true. I tend not to shy away from the frontend, but I prefer the backend because it is usually much easier to test.

This backend focus has allowed me to almost entirely miss out on JavaScript development. I can't say that I mind that much. I use JavaScript when a web page needs it, but I use Google a lot to find examples I can modify to fit my needs.

One thing I am curious about though is to be able to use Cucumber-js. I have never done it before so this a blog post that will describe my experience getting started.

]]>