Chapter (i) test process-Test cases

Source: Internet
Author: User

In order to be most effective and efficient, test cases must be designed, not just slapped together. The word "design" has the following definition:

1. To conceive or form in the mind; invent: devise a good reason to try the Star Test meeting. to articulate a plan; design: Develop a marketing strategy for a new product.

2. In order to plan systematically, it is usually in the form of a document: Design a schema (building), and design a test case.

3. To create or invent for a particular purpose or effect: to design a game that attracts all ages.

4. As a goal or purpose;

5. To create or execute in an artistic or highly skilled manner.

Key point in order to be most effective and efficient, test cases must be designed rather than (not just slapped together).

Each of these definitions is applicable to the design of good test cases. With regard to the design of test cases, Roger Pressman wrote:

"In software and other engineering design, product testing can be used as a preliminary design challenge for the product itself." However... Software engineers typically treat testing as an afterthought, and developing test cases is

' Feel right ' but there's no guarantee that it will be completely covered. Looking back at the goal of the entire test, we have to design the test to find as many mistakes as possible with the minimum of time and effort. ”

The carefully designed test cases contain the following three sections:

Input

Output

Order of execution

The Key point test case consists of the order of input, output, and execution.

Input

Input is generally considered to be input data at the keyboard. Although this is an important source of system input, data can come from other-from the system's data interface, from the device's data interface, to read the file or database, which is the system when the data arrives and executes in the environment.

Output

There are also a number of outputs. Usually the output is considered to be the data displayed on the computer screen. In addition, data can be sent to interface systems and external devices. Data can be written to a file or database. This output condition or environment may be altered by the execution of the system.

All of these have light input and output as an important part of a test case. In the design of test cases, the decision to expect output is a "Oracle" function.

An Oracle are any program, process, or data this provides the Test designer with the expected result of a test. Beizer lists five Oracle types: Kiddie Oracles----Just run the program and see what's out there. If it looks right, then it's right. Regression test Suites----Run the program and compare the output to the results obtained with the same test on previous versions of the program. Validated Date----Run the program and compare the result with a standard based on a table, rule, or other acceptable definition of valid output. Purchased Test Suites---Run the program based on a standard test component that has been created and validated beforehand. Testing of programs like compilation, Browser, and SQL processing is usually based on such a component. The Existing program----run it and output is compared to the output of other versions of the program.

Order of execution

There are two types of test case design styles for the order of test execution. Cascading test Cases (cascading test cases)----test cases can be interdependent. For example, the first test case demonstrates a particular function of the software and then leaves the system with a state that allows the second test case to execute. Consider these situations in the test data database: Create a record read this record update this record read this record delete this record read this delete record

Each of the tests above depends on the previous test. The advantage is that each test case is significantly smaller and simpler. The disadvantage is that if a test fails, subsequent tests may not work. A stand-alone test case (independent) is fully self-contained----each test case. Testing does not depend on either one or requires other tests to have been successfully performed. The advantage is that any number of tests can be performed in any order. The disadvantage is that any test will become larger and more complex, making it more difficult to design, create, and maintain test cases.

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.