Contract-Based Testing for Web Services

  • Authors:
  • Guilan Dai;Xiaoying Bai;Yongbo Wang;Fengjun Dai

  • Affiliations:
  • Tsinghua University, China;Tsinghua University, China;Tsinghua University, China;Tsinghua University, China

  • Venue:
  • COMPSAC '07 Proceedings of the 31st Annual International Computer Software and Applications Conference - Volume 01
  • Year:
  • 2007

Quantified Score

Hi-index 0.00

Visualization

Abstract

Service-oriented architectures introduce some important issues that need to be considered when performing software testing. In a service-oriented scenario, users just invoke a service, instead of physically integrating it (as it happens for components). The service provider can decide to maintain the service, and the user could not be aware of that. The dynamically constructed service-based system has to be tested dynamically and automatically at runtime without human intervention. This paper examines the use of Design by Contract for web service descriptions, and explores the issues and solutions of automatic test case generation and test oracle generation in the context of WS testing based on contracts. In our approach, the traditional concept of contracts (pre-condition, post-condition, and invariant) is extended to contain richer information, such as process control, to support automatic test generation. Contracts are used to specify the relation between a component and its clients as a formal agreement, expressing each party's rights and obligations. Contracts can be expressed in the OWL-S process model. By checking whether the web service respects its contracts, we can ascertain its validity. Therefore, contracts provide the basis for the automation of the testing process.