Automated Model Generation using Graphwalker Based On Given-When-Then Specifications

Detta är en Kandidat-uppsats från Mälardalens högskola/Akademin för innovation, design och teknik

Författare: Joakim Korhonen; [2020]

Nyckelord: ;

Sammanfattning: Software testing is often a laborious and costly process, as testers need extensive domain-specific knowledge and engineering experience to manually create test cases for diverse test scenarios. These scenarios in many industrial projects are represented in requirement specification documents. Since the creation of test cases from these requirements is manual and is error-prone, researchers have proposed methods to automate the creation of tests and execution of tests. One of the most popular approaches is called model-based testing. Model-based testing uses models to manually or automatically create tests based on existing models. Since most of the effort in model-based testing lies in the creation of the model, this thesis aims at improving a model-based testing tool. This improvement is for generating a model from Natural language as this is what requirements usually are written in. Given-When-Then is a test-case writing template used to specify a system's behavior. To implement the natural language processing into a model-based testing tool, an extension for Graphwalker was created. Graphwalker is a popular open-source model-based testing tool, which can create, edit, and test the models created. The extension is using requirements as input written in natural languages and then creates a model based on the requirements provided. Graphwalker's models are based on finite state machines that have elements such as vertices and edges. The model also can change its state, change values of variables, and block access to certain elements. Graphwalker can however not generate models from natural language requirements. This thesis shows how one can transform natural language requirements into models. The extension is implemented to use requirements through both manual input and via a JSON file and it is processing the text and tags each word. These tags will then be used to interpret the sentence meaning and will either create a transition, change a value, or block access to a selected element. The results of this thesis show that this extension is an applicable method to automatically generate models for the GraphWalker tool. This extension can be used and improved by both researchers and practitioners.

  HÄR KAN DU HÄMTA UPPSATSEN I FULLTEXT. (följ länken till nästa sida)