Monday, February 20, 2017

Introducing FitNesse, the testing framework


Talking about test automation often is a discussion about tooling, what tool is best for what purpose. Normally I do not take part in this, in my view a tool is a tool is a tool.
Knowledge on what tools are available and what each has to offer is a necessity, you need that to be able to fill your personal toolbox, but more important is the ability to pick up a tool an know how to use it reasonably well in a matter of days. Each place you work at has it's own demands on environment, the tools already in place and the personal preference of the people who make up the organisation. All this means that knowing all tools a bit, know a few well and have the ability to ramp up your skills fast is far more important than picking a tool and sticking with it.

Yet, this post is about the specific tool FitNesse because I think it is underestimated in the market for a variety of reasons, not in the last place because it is relatively unknown in my local market and it is user friendly. It took me a while to understand how user-friendliness can be detrimental to the popularity of any tool/framework but I think I have it figured out. Because FitNesse allows you to set up your tests in a way that you can explain to business users what you did and what your data points are in a way that is editable to them, there is some obscurity in the step to the actual (java) testing code. This is a good thing, the java code is not causing static in gaining the business trust that the tests are performing. On the other hand, those who are writing the tests like to be more on top of the code and view the format FitNesse offers as a hindrance. This is a bad thing, as it displays a misunderstanding of the framework FitNesse offers.

So let's go into that a bit more. According to the wikipedia page, FitNesse is "a webserver, a wiki and an automated testing tool for software". The rest of the page is technically true but somewhat confusing, it took me a while to figure it out myself. This is another reason FitNesse is under represented, the documentation and publications could use some work.

So here is my explanation of FitNesse to other testers and developers: "It is a stand-alone, no server needed, testing framework that allows you to write both very transparent test scripts in a table based format and set up data driven testing using javacode, whatever your preference." The use of the term framework is to emphasize you can go whatever direction you want when writing your java tests while the framework will take care of data input and output validation, reporting and integration with CI/CD tooling.

And there you go, FitNesse is a tabular view on either testdata and outcome predictions and with the right plugins, a tabular view on your testscripts.

To make the distinction more clear:

  • FitNesse provides you with a framework to give a tabular view on your input/output tables, while your java-based testscript is somewhat hidden
OR

  • FitNesse (with the right plugins) provides you with a wiki-based platform to give you transparent test scripting as well as input/output tables.

These two implementations are not exclusive, you can even mix and match in the same testscript if you desire to do so, but realize that whatever you do, you create a presentable test set that is build upon a mature framework.

In the first case, your testscripts require more than basic java knowledge and a thorough understanding of test automation, where it's strengths and weaknesses lie. In the second case, java is less important, some programming concepts are still required but this goes for the entirety of the test automation role.


No comments:

Post a Comment