I often “see” functionality I am testing as a tree diagram

Creating a tree diagram can be a helpful way to visualise functionality that is accessed via hierarchical structures like menus and the tree diagrams can help to plan testing. In my mind’s eye I often see functionality as a tree diagram.

C.S French says that trees are “hierarchical data structures rather like the familiar family tree” and that “the elements of a tree are called nodes” [1].  The example tree diagram below shows the settings menus on a website. 

Tree diagrams are hierarchical and show the items that you are analysing as nodes in a hierarchy like the hierarchy they are part of. This means that in the example above you see the menu items in the tree diagram similar to how they appear in the menu hierarchy in the app you are testing. 

In the diagram above each node is a menu item, if your diagram was for config options each node would be a different config option. 

It could also be that there are a series of choices that a user can make that are not in a menu. The user starts by choosing a or b, but then for either a or b there can be more choices and then for those choices there may also be more choices that can be made. The structure of these choices is a hierarchy that can also be analysed in a tree diagram.

Visualising the choices in the functionality you are testing as nodes on a tree diagram can help you plan to get the test coverage you want to achieve.You can show in the diagram which nodes you are going to test, or you can use the diagram to ensure that you do some testing of all the nodes. It could be that for the changes that you are testing you need to test all menu options, or it could be that you only need to test all the menu options at a particular level in the menu. Your tree diagram can sometimes contain more nodes than you have time to test. If there are more nodes in the tree diagram than you are going to test then being able to visualise your choices can make choices as to what to test.

Diagrams are also useful to share. If you have created a tree diagram you can share it with your team members and ask them to review it. The team can then see what you are going to test, and you can explain your reasoning. This is really helpful as it can improve understanding of the functionality and team members can offer suggestions that improve the diagram. The diagram can also be useful to share with managers, particularly if you need to show that there is insufficient time to test all the items.

I find tree diagrams are a useful way to visualise functionality that is accessed via menus as a tree diagram. I hope that you find tree diagrams useful too.

References

[1] Computer Science 4th Edition by C.S French

Published by Mike Harris

Mike has been working in testing for 20 years and is the lone tester for Geckoboard. He has been a Test Lead and has also worked as a part of waterfall, lean and agile teams. He has a B.Sc.(HONS) from Middlesex University and is an Associate of the University of Hertfordshire. He has set up and led a Testing Community of Practice and been part of a successful agile transition. He is Vice-Chair of the British Computer Society’s Specialist Interest Group in Software Testing. He also contributed to the e-books Testing Stories and How Can I test This? and has had articles published by the Ministry of Testing, LambdaTest and The QA Lead.

Leave a comment

Design a site like this with WordPress.com
Get started