摘要
随着科技的进步,软件在各行各业发挥的作用已经达到空前的重要程度。因此为了保障其使用性能,必须在投入使用之前完成高覆盖率和高准确度的测试工作。近年来随着Python语言的发展以及逐渐普遍的应用,作为一种解释性语言其在自动化测试方面所能提供的优势足以媲美发展较早的Java语言。通过Python语言及其自带unittest框架完成一个自动化测试框架的搭建,实现一个主机安全监控系统中客户端的自动化测试,通过自动化的方式对主机进行端口开启和关闭以及帐号的新增和删除,然后查看客户端是否能够捕捉到该操作,以此测试系统的功能是否正常实现。根据该测试实例,完成自动化测试框架的设计和描述,实现提高测试效率和准确性的目标。
In recent years,with the development of the Python language and its gradual widespread application,as an interpreted language,its advantages in automated testing are comparable to the earlier developed Java language.This paper uses Python language and its built-in unittest framework to complete the construction of an automated test framework,realizes the automated test of the client in a host security monitoring system,and automatically opens and closes the host port and adds and deletes accounts,and then check whether the client can capture the operation to test whether the function of the system is implemented normally.According to the test case,complete the design and description of the automated test framework,and achieve the goal of improving test efficiency and accuracy.
出处
《工业控制计算机》
2021年第10期109-110,113,共3页
Industrial Control Computer