Automated Specification-Based Testing of REST APIs
Nowadays, REpresentational State Transfer Application Programming Interfaces (REST APIs) are widely used in web applications, hence a plethora of test cases are developed to validate the APIs calls. We propose a solution that automates the generation of test cases for REST APIs based on their specif...
Main Authors: | , , , |
---|---|
Format: | Article |
Language: | English |
Published: |
MDPI AG
2021-08-01
|
Series: | Sensors |
Subjects: | |
Online Access: | https://www.mdpi.com/1424-8220/21/16/5375 |
id |
doaj-cac5e63776ab4687b76f26d6f900a621 |
---|---|
record_format |
Article |
spelling |
doaj-cac5e63776ab4687b76f26d6f900a6212021-08-26T14:18:51ZengMDPI AGSensors1424-82202021-08-01215375537510.3390/s21165375Automated Specification-Based Testing of REST APIsOvidiu Baniaș0Diana Florea1Robert Gyalai2Daniel-Ioan Curiac3Automation and Applied Informatics Department, Politehnica University of Timisoara, Parvan 2, 300223 Timisoara, RomaniaAutomation and Applied Informatics Department, Politehnica University of Timisoara, Parvan 2, 300223 Timisoara, RomaniaAutomation and Applied Informatics Department, Politehnica University of Timisoara, Parvan 2, 300223 Timisoara, RomaniaAutomation and Applied Informatics Department, Politehnica University of Timisoara, Parvan 2, 300223 Timisoara, RomaniaNowadays, REpresentational State Transfer Application Programming Interfaces (REST APIs) are widely used in web applications, hence a plethora of test cases are developed to validate the APIs calls. We propose a solution that automates the generation of test cases for REST APIs based on their specifications. In our approach, apart from the automatic generation of test cases, we provide an option for the user to influence the test case generation process. By adding user interaction, we aim to augment the automatic generation of APIs test cases with human testing expertise and specific context. We use the latest version of OpenAPI 3.x and a wide range of coverage metrics to analyze the functionality and performance of the generated test cases, and non-functional metrics to analyze the performance of the APIs. The experiments proved the effectiveness and practicability of our method.https://www.mdpi.com/1424-8220/21/16/5375software testingspecification-based testingautomatic test case generationREST APIOpenAPI 3.x |
collection |
DOAJ |
language |
English |
format |
Article |
sources |
DOAJ |
author |
Ovidiu Baniaș Diana Florea Robert Gyalai Daniel-Ioan Curiac |
spellingShingle |
Ovidiu Baniaș Diana Florea Robert Gyalai Daniel-Ioan Curiac Automated Specification-Based Testing of REST APIs Sensors software testing specification-based testing automatic test case generation REST API OpenAPI 3.x |
author_facet |
Ovidiu Baniaș Diana Florea Robert Gyalai Daniel-Ioan Curiac |
author_sort |
Ovidiu Baniaș |
title |
Automated Specification-Based Testing of REST APIs |
title_short |
Automated Specification-Based Testing of REST APIs |
title_full |
Automated Specification-Based Testing of REST APIs |
title_fullStr |
Automated Specification-Based Testing of REST APIs |
title_full_unstemmed |
Automated Specification-Based Testing of REST APIs |
title_sort |
automated specification-based testing of rest apis |
publisher |
MDPI AG |
series |
Sensors |
issn |
1424-8220 |
publishDate |
2021-08-01 |
description |
Nowadays, REpresentational State Transfer Application Programming Interfaces (REST APIs) are widely used in web applications, hence a plethora of test cases are developed to validate the APIs calls. We propose a solution that automates the generation of test cases for REST APIs based on their specifications. In our approach, apart from the automatic generation of test cases, we provide an option for the user to influence the test case generation process. By adding user interaction, we aim to augment the automatic generation of APIs test cases with human testing expertise and specific context. We use the latest version of OpenAPI 3.x and a wide range of coverage metrics to analyze the functionality and performance of the generated test cases, and non-functional metrics to analyze the performance of the APIs. The experiments proved the effectiveness and practicability of our method. |
topic |
software testing specification-based testing automatic test case generation REST API OpenAPI 3.x |
url |
https://www.mdpi.com/1424-8220/21/16/5375 |
work_keys_str_mv |
AT ovidiubanias automatedspecificationbasedtestingofrestapis AT dianaflorea automatedspecificationbasedtestingofrestapis AT robertgyalai automatedspecificationbasedtestingofrestapis AT danielioancuriac automatedspecificationbasedtestingofrestapis |
_version_ |
1721190202101202944 |