清单4给出gps代码的一个简单测试用例。
测试包括本文中讨论的测试再加上许多大容量的简单测试用例。
The tests include those discussed in this paper plus a number of high-volume simple test cases.
采用一个可以一直重现问题的简单测试用例通常都是个好主意,因为这可以显著地加速解决问题的过程。
Having a simple straightforward test case consistently reproducing the problem is always preferable, as it significantly speeds up resolution of the problem.
测试用例包含几个简单的命令参数处理,然后是一个循环,它计算指定值(如果有的话)的阶乘。
The test case consists of some simple command argument processing followed by a loop that calculates the factorial of the specified values (if any).
清单5看起来很简单,但是我为它编写了几个测试用例,看看会是什么情况。
Listing 5 looks pretty simple, but let's see what happens when I write a few test cases for it.
最简单的处理测试用例优先权的方法是关键路径的识别。
The simplest approach to test case prioritization is identification of critical path.
为了测试这点,导入一个简单的测试用例并运行测试。
记住该GUI之所以简单只有一个原因:它演示了TestNG - Abbot的三个fixture类以及一些要引导的测试用例!
Keep in mind that this GUI is simple for a reason: It demonstrates three of TestNG-Abbot's fixture classes and a few test cases to boot!
接下来,您需要向您的测试用例添加一个简单的测试脚本。
Next, you need to add a simple test script to your test case.
根据前面简单的单元测试用例,这块代码是“干净,绿色”的——但只有在我真正彻底地测试这块代码的情况下这才有意义。
So the code is "clean and green," according to my simple unit test case — but that's meaningful only if I'm really testing the code thoroughly.
因为测试用例易于创建,您能够简单地运行和维护测试,这有时会导致测试用例膨胀。
This can sometimes lead to test case bloat, where you are running and maintaining tests simply because they were easy to create.
但目前,使用这个简单的测试用例来确保您的环境工作正常。
For now, use this simple test case to ensure your environment is working correctly.
您的框架应该为每个测试用例分配一个数,为了简单地再次运行失败的测试用例。
Your framework should assign a number to each test case to allow for easy rerunning of failing test cases.
下面是我们的简单示例所生成的测试用例类。
Here is the generated test case class for our simple example.
自动化那些故事的测试用例,是预防缺陷在后续故事中出现的最简单、最有效的方法。
And I think that automated story tests are the simplest and most certain way to prevent defects cropping up in stories later on.
为Linux内核创建测试用例相当简单;通常要么要求特定的范围,要么要求广泛的范围。
Creating test cases for the Linux kernel is pretty straightforward; usually either very specific or very broad coverage is desired.
清单2给出了针对这个类的一个简单的JUnit测试用例,图1展示了我在Eclipse中运行这个测试时的结果。
Listing 2 gives a simple JUnit test case for this class, and Figure 1 shows the results when I run this test in eclipse.
在最简单的情况下,我们可以只使用unittest . main来运行测试用例,这将断定哪些需要运行。
In the simplest case, we can run the test cases using just unittest.main , which figures out what needs to be run.
Rubyon Rails通过在默认情况下创建一些简单的测试用例来取得了巨大优势,您也可以这么做。
Ruby on Rails gets tremendous leverage by creating some simple test cases by default. You can too.
清单5中的测试用例利用get :list命令执行了一个简单的HTTP get。
The test case in Listing 5 does a simple HTTP get with the get :list command. Then, the test case runs three assertions
这似乎是一个简单的分层问题,但即使有一个非常简化的测试用例,错误仍然明显。
It seems like a simple layering issue, but even with a very simplified test case the bug is still apparent.
一种更加简单的方案是使用自分流模式,把测试用例自身作为残根。
A simpler solution is to apply the self-shunt pattern and use the test-case object itself as a stub.
这些都是简单的测试用例,测试一些应用程序代码。
这些都是简单的测试用例,测试一些应用程序代码。
应用推荐