| 注册
首页|期刊导航|计算机与数字工程|面向CLI的自动化测试方法的研究与实现

面向CLI的自动化测试方法的研究与实现

徐彩霞 葛华勇 侯仰宇

计算机与数字工程2018,Vol.46Issue(2):332-336,5.
计算机与数字工程2018,Vol.46Issue(2):332-336,5.DOI:10.3969/j.issn.1672-9722.2018.02.025

面向CLI的自动化测试方法的研究与实现

Research and Implementation of CLI-Oriented Automation Testing Method

徐彩霞 1葛华勇 1侯仰宇1

作者信息

  • 1. 东华大学信息科学与技术学院 上海201620
  • 折叠

摘要

Abstract

This paper researches and implements a CLI(Command-line Interface)automation testing method using the py-thon,which is aimed at complexity and fallibility of the CLI manual testing method,and script maintenance problems existing in the recording and generating script testing method now.The method adopts the form of data-driven script to separate the test data from the test script and store it in a highly readable yaml data file.Besides,the method uses Python's unittest module to write overall test-ing framework.The framework uses telnet protocol to remote login host,and loads the test data in the yaml file as a parameter into the test script.Then running the test data,and exporting test results to the system interface and the log.The testing results indicate that this method can avoid the error frequency of CLI manual testing effectively,reduce maintenance and enhance reusability of test script.

关键词

CLI自动化测试/数据驱动脚本/telnet协议/unittest模块/yaml文件

Key words

CLI automation testing/data-driven script/telnet protocol/unittest module/yaml file

分类

信息技术与安全科学

引用本文复制引用

徐彩霞,葛华勇,侯仰宇..面向CLI的自动化测试方法的研究与实现[J].计算机与数字工程,2018,46(2):332-336,5.

计算机与数字工程

OACSTPCD

1672-9722

访问量5
|
下载量0
段落导航相关论文