单项选择题在unittest中,如何为测试用例设置后置条件()

A.在测试用例中添加tearDown()方法
B.在测试用例中添加setUp()方法
C.在测试用例中添加postCondition()方法
D.在测试用例中添加preCondition()方法


你可能感兴趣的试题

1.单项选择题在unittest中,如何表示测试用例的一个步骤()

A.使用print语句输出日志信息
B.使用注释表示步骤
C.使用setUp()和tearDown()方法包裹步骤
D.使用addStep()方法表示步骤

2.单项选择题unittest中的断言用于什么()

A.检查测试用例的输出
B.检查测试用例的输入
C.检查测试用例的执行结果
D.检查测试用例的性能

3.单项选择题使用unittest的测试用例应该继承哪个类()

A.unittest.TestCase
B.unittest.TestSuite
C.unittest.TestLoader
D.unittest.TestResult

4.单项选择题使用unittest需要先导入哪个模块()

A.unittest
B.test
C.unit
D.pytest

5.单项选择题JMeter测试报告中,哪个组件可以提供HTTP请求的平均响应时间和标准偏差等指标()

A.Summary Report
B.View Results Tree
C.Aggregate Report
D.Assertion Results

6.单项选择题JMeter测试报告中,哪个图表可以显示每个HTTP请求的响应时间分布()

A.Summary Report
B.Response Times Distribution
C.Aggregate Report
D.Response Times Over Time

7.单项选择题JMeter测试报告中,哪个图表可以显示测试执行期间吞吐量的变化()

A.Aggregate Graph
B.Response Times Over Time
C.Active Threads Over Time
D.Bytes Throughput Over Time

8.单项选择题JMeter测试报告中,哪个组件提供了关于每个HTTP请求的详细信息()

A.Summary Report
B.View Results Tree
C.Aggregate Report
D.Response Times Over Time

9.单项选择题JMeter测试报告中,哪个组件可以提供HTTP请求的连接时间和等待时间等指标()

A.Summary Report
B.View Results Tree
C.Aggregate Report
D.Response Times Over Time

10.单项选择题JMeter测试报告中,哪个图表可以显示每个HTTP请求的响应时间和吞吐量的关系()

A.Summary Report
B.Response Times Over Time
C.Aggregate Graph
D.Bytes Throughput Over Time