系统测试是什么,需要考虑哪方面

系统测试是什么,需要考虑哪方面,第1张

去搭建测试环境是软件测试实施的一个重要阶段,测试环境适合与否会严重影响测试结果的真实性和正确性。测试环境包括硬件环境和软件环境,硬件环境指测试必需的服务器、客户端、网络连接设备,以及打印机/扫描仪等辅助硬件设备所构成的环境;软件环境指被测软件运行时的 *** 作系统、数据库及其他应用软件构成的环境
一 确定测试环境的组成:
1.所需要的计算机的数量,以及对每台计算机的硬件配置要求,包括CPU的速度、内存和硬盘的容量、网卡所支持的速度、打印机的型号等;
2 部署被测应用的服务器所必需的 *** 作系统、数据库管理系统、中间件、WEB服务器以及其他必需组件的名称、版本,以及所要用到的相关补丁的版本;
3 用来保存各种测试工作中生成的文档和数据的服务器所必需的 *** 作系统、数据库管理系统、中间件、WEB服务器以及其他必需组件的名称、版本,以及所要用到的相关补丁的版本;
4 用来执行测试工作的计算机所必需的 *** 作系统、数据库管理系统、中间件、WEB服务器以及其他必需组件的名称、版本,以及所要用到的相关补丁的版本;
5 是否需要专门的计算机用于被测应用的服务器环境和测试管理服务器的环境的备份;
6 测试中所需要使用的网络环境。例如,如果测试结果同接入Internet的线路的稳定性有关,那么应该考虑为测试环境租用单独的线路;如果测试结果与局域网内的网络速度有关,那么应该保证计算机的网卡、网线以及用到的集线器、交换机都不会成为瓶颈;
二、管理测试环境
1 设置专门的测试环境管理员角色
每个测试项目或测试小组都应当配备一名专门的测试环境管理员,其职责包括:测试环境的搭建。包括 *** 作系统、数据库、中间件、WEB服务器等必须软件的安装,配置,并做好各项安装、配置手册的编写;记录组成测试环境的各台机器的硬件配置、IP地址、端口配置、机器的具体用途,以及当前网络环境的情况;测试环境各项变更的执行及记录;测试环境的备份及恢复; *** 作系统、数据库、中间件、WEB服务器以及被测应用中所需的各用户名、密码以及权限的管理;
2 记录好测试环境管理所需的各种文档:
测试环境的各台机器的硬件环境文档,测试环境的备份和恢复方法手册,并记录每次备份的时间、备份人、备份原因以及所形成的备份文件的文件名和获取方式;用户权限管理文档,记录访问 *** 作系统、数据库、中间件、WEB服务器以及被测应用时所需的各种用户名、密码以及各用户的权限,并对每次变更进行记录
3 测试环境访问权限的管理
为每个访问测试环境的测试人员和开发人员设置单独的用户名和密码。访问 *** 作系统、数据库、WEB服务器以及被测应用等所需的各种用户名、密码、权限,由测试环境管理员统一管理;测试环境管理员拥有全部的权限,开发人员只有对被测应用的访问权限和查看系统日志(只读),测试组成员不授予删除权限,用户及权限的各项维护、变更,需要记录到相应的“用户权限管理文档”中
4 测试环境的备份和恢复
测试环境必须是可恢复的,否则将导致原有的测试用例无法执行,或者发现的缺陷无法重现,最终使测试人员已经完成的工作失去价值。因此,应当在测试环境(特别是软件环境)发生重大变动时进行完整的备份,例如使用Ghost对硬盘或某个分区进行镜像备份。

本文整理来自pro Apache jmter web application和Wikipedia

在一定的负载条件下,评估系统或应用的响应时间,吞吐量等相关指标

功能测试通过之后

对系统进行性能评估,并通过测试发现系统瓶颈,分析定位瓶颈发生的原因,协助开发修复性能问题,提高系统的处理能力。对比不同的系统,确认更好的系统。

主要指标: 响应时间、吞吐量、资源利用率。

The time taken by the application to respond to the user’s request is called the response timeEvery application should strive to minimize the response time

应用程序响应用户请求所需的时间称之为--响应时间。响应时间越小越好

对于常见的B/S结构的响应时间,如下图:

从用户发起请求,到服务完全完成响应的时间。

用户感知时间,有点预加载的意思。即本来一个页面全部信息同时返回,现在改成优先加载一部分内容

服务器处理时间。服务器处理请求并响应的这段时间。与请求的复杂性、系统的硬件及系统服负载有关。

吞吐量:单位时间内处理的事务个数。通常由transactions/second 或 bandwidth (bytes/second)来衡量。吞吐量越大越好。

服务器资源利用率,不应该超过80%的利用率。利用率越低越好。

Scalability measures how well the system can expand its capacity when additional resources are addedIdeally the system capacity will increase linearly as additional resources are added However, this is rarely achieved in practice It’s a good measure to know the resources that would be needed so that the system can handle the projected future loadVertical scalability is achieved by upgrading the hardware For example, by adding more memory, disk,
a better CPU, or additional CPUsHorizontal scalability is achieved by adding servers to the cluster For example, by adding more web
servers and application servers to a webfarm/cluster

主要有压力测试,负载测试,配置测试等

压力测试是应用程序处于超出负荷状态下长时间运行,以测试服务器的稳定性和性能表现。

A load test is a kind of performance test that’s performed at the specified load level So ideally, we would like to perform load tests at varying load levels to note the behavior of the application

在一定的负载条件下,测试应用程序的性能表现。通过不同的负载程度(load levels),观察应用程序的性能表现来得到最大的用户数,响应时间以及资源利用率等指标。

A peak load test is performed at the load that the application is expected to handle For example, e-commerce web sites experience their peak traffic during Black Friday, Cyber Monday, and the Christmas holidays So a peak load test in this case would test the application within the load specification but at the higher end

Note stress tests test beyond the peak load

In a soak test (also called an endurance test), the application is subjected to a specified load that is within the specified limit but for a long duration It is performed for many hours at a time This test determines if the application is properly reusing its resources
This test will surface problems like the following:

Successful web applications experience massive and sometimes exponential growth So it is wise to measure how the application scales Scalability is defined as how well the application handles the increase in load while still meeting the desired performance criteria

A scalability test would increase the resources and test whether or not the application is providing
a corresponding increase in capacity Ideally, we expect linear scalability (ie, doubling the hardware resources should result in double the application capacity)

A capacity test is a load test that establishes the maximum load that the application can handle while
meeting the desired performance criteria The resulting metric is called the maximum capacity It is used in scaling the application and to estimate costs for future growth

A spike test is a load test where the application is subjected to brief periods of sudden increment in load, a small fraction beyond the maximum capacity It is usually done to estimate the weakness/strength of an application The application is expected to be robust and continue to meet the performance criteria during the spike This metric is called the burst capacity

In a performance smoke test, a few common and essential use-cases along with use-cases pertaining to the
code subject to change are together tested for performance It is only when the smoke test succeeds that
the full suite of performance tests are conducted If the smoke test fails, no further performance tests areconducted until the performance defect has been rectified

Modern web application infrastructure is designed to be highly available and resilient to hardware and software failures Ideally, the architecture should ensure that there is no single point of failure and that there are standby servers that can transparently take over without impacting the user experience
In this test various equipment and software failures are simulated and relevant performance tests are
run to verify that the application is still meeting the performance criteria

Rather than testing for performance from a load perspective, tests are created to determine the effects of configuration changes to the system's components on the system's performance and behaviour A common example would be experimenting with different methods of load-balancing


欢迎分享,转载请注明来源:内存溢出

原文地址:https://54852.com/zz/10390631.html

(0)
打赏 微信扫一扫微信扫一扫 支付宝扫一扫支付宝扫一扫
上一篇 2023-05-08
下一篇2023-05-08

发表评论

登录后才能评论

评论列表(0条)

    保存