Web Testing Overview

Source: Internet
Author: User
Tags xunit
Web Applications Program Detailed testing methods and techniques
1. Overview
L with the increase of Web applications, there are more and more applications with the web as the core of new model solutions. The architectures of various applications of many companies are dominated by B/S and Web applications, however, there is no summary of the Web Testing content, so I will summarize the Web testing methods and the testing technology used here to facilitate internal communication.
L The testing method should cover all aspects of web programs as much as possible. The testing technology should inherit the traditional testing technology and combine the characteristics of Web applications.
L related testing and implementation technologies also have a great relationship. As the company uses the J2EE system, only the Java platform can be used in the example ,. NET platform testing technology is not involved for the moment. If you have any, please contact me.
2. Test Method
Note: The choice of testing method depends on your testing strategy.
L The General Web Testing and the previous application testing focus on different aspects, including the following aspects.
L of course, the successful completion of the test also requires support for all aspects of the group and process. You should also pay attention to these aspects.
L some testing methods have been designed into the process and which should be built in your testing team.

2.1 Interface Test
L most people now have Web browsing experience using browsers. Although users are not professional, they are very important to the interface effect. If you focus on this test, it is very important to verify that the application is easy to use. Many people think that this is the least important part of the test, but on the contrary, the interface is very important for customers who do not understand the technology.
L in terms of methods, you can determine the overall style of the page style based on the design documents. If you are professional enough, you can create static HTML based on the webpage staff, CSS and so on even generate several unused solutions for discussion, or submit them to the customer for review, and finally form a unified page/framework. Be careful not to rely on the programmer's artistic literacy to form your web style, which may be terrible.
It mainly includes the following aspects:
Whether the layout of the site map and navigation bar is reasonable, whether the content such as the navigation bar is reasonable, and whether the layout of the content such as the navigation bar is reasonable. Descriptions such as the scroll bar indicate whether the text is reasonable, the location, and whether the text is correct.
Whether the background/tone is correct, beautiful, and meets user needs;
Whether the page is correctly displayed and beautiful in the window (when the browser window is adjusted, the screen is refreshed correctly, whether to verify the submitted data (if on the page)
Connect the form, location, and understanding of the Connection
L main page elements of Web Testing
Ø error tolerance list of page elements (such as input box, time list, or calendar)
Page element list (whether all the required elements are listed for the implementation function, such as buttons, single quotes, check boxes, list boxes, hyperconnections, and input boxes)
Whether error tolerance of page elements exists
Whether error tolerance of page elements is correct
Whether the basic functions of page elements are implemented (such as text effects, animation effects, buttons, and hyperconnections)
Ø shape and placement of page elements (such as buttons, list boxes, check boxes, input boxes, and hyperconnections)
Whether the page elements are correctly displayed (mainly for text, graphics, and signatures)
Whether the element is displayed (whether the element exists)
List of page elements (whether to list all the required elements, such as buttons, single quotes, check boxes, list boxes, hyperconnections, and input boxes)
L Testing Technology
Check the page to see if the page meets your requirements. You can use the compatibility test to display the page without resolution. If there is any impact, You should submit the solution to the designer.
Ø you can view the content, length, and other information of form items in conjunction with the data definition document.
It is best to browse and view dynamically generated pages. For example, the servelet part can be carried out in combination with the encoding specification. Code Check. Whether Chinese characters are supported. If the data is encapsulated in XML, more work will be done.
Interface Test elements:
Compliant with standards and specifications, flexibility, correctness, intuition, comfort, practicability, consistency
L 1. Intuition:
Whether the user interface is clean, not abrupt, not crowded. The interface should not create obstacles for the user. The required functions or expected responses should be obvious, and should appear as expected.
Is the interface organized and laid out properly? Can users easily switch from one function to another? What is the next step? Can I decide to give up or return at any time? Can I quit? Is the input acknowledged? Is the menu or window hidden?
Are there any additional features? Is the overall or local software too much? Is there too many features that complicate your work? Do you feel that the information is too complex?
If all other efforts fail, can the help system help you?
L 2. Consistency
Ø shortcut keys and menu options. Pressing F1 in Windows always gets help information
Do the same terms apply to the entire software? Is the feature name consistent? For example, is "find" always called "find" instead of "Search?
Does the software always target the same level of users? Interest card programs with fancy user interfaces should not Display error messages that leak technical secrets.
Ø button positions and equivalent buttons. Do you notice that the OK button and the cancle button in the dialog box are always at the top or left, while the cancle button is always at the bottom or right? For the same reason, the equivalent button of the cancle button is usually ESC, and the equivalent button of the selected button is usually enter.
L 3. Flexibility
Various options are available for flexible software implementation of the same task.
State termination and skipping, with fault tolerance processing capability.
Ø Data Input and Output. users want to input data and view results in multiple ways. for example, you can insert text on the WordPad by entering, pasting, and reading the text from six file formats as an object, or dragging the text from other programs with the mouse.
L 4. Comfort
Appropriate. The appearance and feeling of the software should be consistent with the work done by the user.
Ø error handling. The program should give a warning before the user executes a serious error operation, and allow the user to recover lost data due to the wrong operation. For example, we think Undo/Redo is of course.
Performance. It is not necessarily a good thing. It is responsive to let users know what the program is doing.
2.2 Function Testing
L functional testing is the focus of testing
It mainly includes the following content:
Connect this connection is different from the connection in the interface test. It focuses on the connection mode and location, such as the image or text placement location, or other methods. The connection here focuses on functions. For example, whether a connection exists or whether the connection is specified.
Ø form submission should simulate user submission to verify whether the function is complete, such as registration information. To test these programs, verify that the server can properly store the data, in addition, programs running in the background can correctly interpret and use the information. There are also data correctness verification, exception handling, and so on, it is best to combine ease of use requirements and so on. The main functions of the B/S structure are as follows: submit data and process data. If there is a fixed operation flow, you can consider the recording function of the automated testing tool, write reusable script code that can be run during testing and regression testing to reduce the workload of testers.
Ø cookies are verified by testers if the system uses cookies. If the registration information is saved in cookies, make sure that the cookie works properly and has been encrypted. If you use cookies to count the number of times, you need to verify that the total number of times is correct. For more information about how to use cookies, see the help information of the browser. If more information is stored in cookies using the B/S structure. The function usability test completes the function test to understand the applicability. It is best to hear the customer's feedback. It is necessary to improve the program if possible, maintaining interactions with customers is also helpful to system satisfaction.
L there are a lot of functional testing techniques. We can use them in combination with the actual environment.
The white box testing technology goes deep into the code-level test. This technology is used to identify the earliest problem and the best effect is also achieved. The main feature of this technology is that the test object enters the code. Based on the developer's familiarity with the Code and the program, the necessary parts are carried out in the software coding stage, the software tests performed by developers based on their understanding and contact with the code are called white box tests. This phase of testing is mainly for software developers. The xunit series tools are used for testing on the Java platform. The xunit testing tool is a Class-level testing tool that tests each class and its methods.
The black box testing technology mainly includes the following aspects, but it is mainly functional. It mainly covers all functions and can be carried out in combination with compatibility and performance testing. Based on the software requirements, design documents, simulate the actual testing of customer scenarios with the system, this testing technology is the most widely used testing technology that covers all aspects of testing. You can consider the following aspects:
Correctness: calculation results, naming, and other aspects
Availability.
Boundary Condition refers to the Boundary Value of the input part, which is to use the equivalence class defined in the general book, and try the maximum, minimum, and invalid data.
The time required for the system to complete a task during the normal use of performance, and the response time for multiple users to use at the same time, within the acceptable range. the system implemented by J2EE technology needs to take care of its performance. The general principle is to accept the performance within 3 seconds, 3-5 seconds, and more than 5 seconds. if you find performance problems during the testing process, it is very difficult to fix them, because this often means
ProgramAlgorithm Poor, poor structure, or design problems. Therefore, in the initial stage of product development, we must consider the performance of the software.
Stress testing tools can be considered for stress testing (stress) users. We recommend that you combine stress and performance testing. if there is a load balancing, you need to turn on the monitoring tool on the server to view the server's CPU usage, memory usage, if necessary, you can simulate a large amount of data input, the impact on the hard disk and other information. if necessary, performance must be optimized (both software and hardware can be used ). the stress test here is intended for certain functions ,.
Error Recovery error handling, page data verification, including sudden power failure and dirty data input.
Security Testing (Security) is under research, but firewall, patch pack. anti-virus software and so on, but you can consider any destructive test. after reading some materials, I learned that the knowledge I have designed here can be written in this book. Not one or two sentences can be clearly written, especially for some commercial websites or related to money, or the web related to company secrets needs to be tested in this regard. In foreign countries, a person dedicated to this line is called a security consultant who can review the code and propose Security suggestions, the solutions to emergencies have occurred. I have not heard of any content dedicated to security technology testing in China.
Compatibility (compatibility) the performance of different browsers and application versions in implementing functions, different ways of accessing the Internet, if you are testing a public website.
L compatibility test content details
Ø hardware platform
Ø browser software and version: browser plug-in, browser options, video resolution and color depth. Text Size, modem rate.
Software Configuration (configuration) such as the no-Use Option of IE browser-the highest security setting, the script program is disabled, and so on. How does your program behave under various no-use settings.
Unit test ):
2.2.1 The differences between white box testing and unit testing are as follows:
L unit testing and white box testing are different. Although both unit testing and white box testing focus on functions, although they both require code support, their levels are different, white-box testing focuses on a method of the same type with a smaller unit, but it may take N categories to complete a unit test. So what is the write drive and stability pile required for unit testing, for example, the query unit is a test class that queries more than N packages, test data, the data that needs to be provided to run the module, the input parameters and the command-issuing driver. is larger than the class.
L another obvious difference is that white-box testing does not allow class interfaces, but the main content of unit testing is class interface testing.
L in many cases, there are few differences, because these two technologies have many interrelated components, but it depends on your attention to quality.
2.2.2 functional test boundary test technical details
Ø Boundary Conditions
Boundary Condition refers to the edge condition of the Operation boundary of the software plan.
If a software test question contains a definite boundary, the data type may be:
Numeric speed character address location size quantity
Consider the following features:
First/last minimum/maximum
Start/finish exceeds/
Null/full shortest/longest
Slowest/fastest earliest/latest
Max/min max/min
Adjacent/farthest
Ø cross-border Testing
It is usually a simple addition of 1 or a small number (for the maximum value) and a reduction of 1 or a small number (for the minimum value), for example:
First minus 1/last plus 1
Start to subtract 1/finish adding 1
Empty and then subtract/Add when full
Slow up/fast up
Max plus 1/min minus 1
Minimum value minus 1/maximum value plus 1
Exceeded/exceeded
Shorter/longer
Earlier/later
Maximum addition 1/minimum reduction 1
L other inputs for this note: Default, blank, null, zero and none; illegal, error, incorrect, and junk data.
2.2.3 Status Testing Technology

Every independent state that the software may enter;
Input and conditions required for transferring from one State to another;
Set conditions and input results when entering or exiting a certain state.

L specific test methods can be referred to as follows:
Ø each status can be accessed at least once;
Testing the most common and common state transition;
The least frequently used Branch between test statuses
Testing all error statuses and returned values
Testing random State Conversion
2.2.4 competitive condition testing technology
L typical competition conditions are as follows:
Ø two different programs save or open the same document at the same time
Share the same printer, communication port or other peripheral devices
Press the key or click the mouse when the software is reading or modifying.
Disable or start multiple instances of the software at the same time
Using different programs to access a common database at the same time
2.3 load stress testing (stresstest)
L here the load "pressure and function test are different. It is the content of the system test and is carried out after the basic functions have been passed. it can be either in the integration test phase or in the system test phase.
L use the load testing tool. A certain number of users can check whether the system performance meets the defined indicators.
L load testing is generally completed using tools, such as LoadRunner, webload, was, EWL, and e-test. The main content is to compile a test script, which generally includes common functions, run the command to generate a report. Therefore, the main content of the load test is not described.
L load testing technology tests the product under various limits (for example, many people use the software at the same time or run the Software Repeatedly) to check the long-term stability of the product. For example, you can use stress testing tools to perform stress testing on Web servers. this test can help you find some large problems, such as crashes, crashes, and memory leaks. Some programs with memory leaks may not encounter problems once or twice, however, if tens of thousands of times are run, more and more memory leaks will cause system slide. There are few systems implemented using J2EE, but there is no memory problem.
All basic tools use thread-based imitation and virtual users. The main difficulty here is the compilation of test scripts. The scripts used by each tool are different, however, most tools provide the recording function, which can be tested by testers without coding.
The system stability test and system limit test can be performed on the extended use of the load tool. For example, if the load size of 100 is used for 24 consecutive hours, microsoft defines that programs that pass the 72-hour test generally do not have stability issues.
2.4 regression test)
L after a while, I will go back and try again to test the previously fixed bug to see if it will reappear.
The regression testing technology can appear at all stages of the testing, whether it is unit testing, integration testing or system testing. Is the process of verifying previous problems.
The purpose of regression testing is to ensure that bugs that have been previously fixed will not appear again. In fact, many bugs are found during regression testing. At this stage, we first need to check whether the previously found bugs have been corrected. It is worth noting that the corrected bugs may also come back, And some bugs may generate new bugs after modification. Therefore, regression testing ensures that corrected bugs are no longer reproduced and new bugs are not generated.
2.5 alpha and beta testing ):
L some beta versions should be released before the product is officially released, so that users can feedback relevant information or find existing bugs to solve them in the official version.
L in particular, when a customer participates, testing the system may lead to some situations that we did not consider and solve some issues that the customer actually cares about.
Different Test Techniques
3.1 coverage Testing Technology
Note: The test coverage rate shows the test completion level. In the test analysis report, it can be used as a basis for quantifying indicators. The higher the test coverage rate, the better the effect.
L coverage testing can be the execution path coverage of the program code or the step coverage of the function implementation (it can be understood as the path coverage of the flowchart ).
L this technology can be used in any testing phase, including unit test necrosis, integration testing, and system testing.
L any of the above testing methods and technologies can be used when this technology is used.
3.2 white box testing and black box Testing Technology
L white box Testing Technology (white box testing) The main feature of this technology is that the testing object enters the code, according to the developer's familiarity with the Code and the program, in the software coding stage, developers perform software testing based on their understanding and contact with the code. This phase of testing is mainly conducted by software developers using xunit tools and may include many aspects such as functionality and performance.
L black box testing (black box testing) the content of black box testing is mainly in the following aspects, but it is mainly functional. It mainly covers all functions and can be carried out in combination with compatibility and performance testing. For details about the different test types, see the above.
3.3 manual and automated tests
L manual testing: manually finding bugs. You can refer to the test above, or perform different tests based on the Implementation Technology and experience.
L automation testing is applicable to specific tools. You can make an automated test plan. You can write or record scripts for some parts that can be automated. You can add functions, fault tolerance, and form submission. For details, refer to Mi, rational or other test tools.
L based on authoritative software testing experience, manual testing is still the main test method. Automatic Testing is not flexible enough and will not be detailed here. Microsoft's testing process is still manually completed 80%.
L automated testing will never replace manual testing, but manual testing requires a lot of work.
3.4 test by phase according to the RUP Standard
L unit tests are described in detail and discussed in unit tests and integration tests. For more information, see.
L integration testing can be divided into functional integration testing and system integration testing. function integration with each other can be called, and the impact of mutual function calling in the system environment can be selected as needed. Focus on functions.
L compatibility, ease of use, and performance can be added to system testing based on function implementation.
L acceptance tests can include alpha and beta tests, which will not be detailed here.
4. Risks and Solutions
Note: The test cannot identify all the problems, but try to solve most of the problems in the development stage.
The test risks are as follows:
L The provision of software and hardware testing environments also has a great impact on the testing results.
L test the team's level, experience, cooperation effect, etc.
L the entire development process attaches importance to the test and the test entry time.
L The testing results may vary depending on the operating system, network environment, and bandwidth in the testing environment. This requires experience and protection of the testing environment.
5. Principles of Software defects
L Software defects are different from software bugs. They affect the system during testing, however, they are not in the design or have different opinions on the modified bug tests and developers.
The software does not provide the functions specified in the product manual.
The software has errors specified in the product manual.
The software function is beyond the scope specified in the product manual.
The software fails to fulfill the goals that should be fulfilled even if not specified in the product manual.
The software tester deems the software hard to understand, difficult to use, slow to run, or the end user thinks it is not good.
6. Document Test
L product manual attribute check list
Ø complete. Are there any omissions or loss? Completely? Is all content contained in a separate use?
Ø accurate. Are the established solutions correct? Is the goal clear? Are there any errors?
Ø accurate, unambiguous, and clear. Is the description clear? Or self-speaking? Is it easy to understand and understand?
Are there any conflicts between product function descriptions and other functions?
Ø apt. Is it necessary to describe the function statement? Is there any additional information? Are features originally required by customers?
Reasonable. Can existing manpower, material resources, and resources be achieved under a specific budget and schedule?
The code is irrelevant. Do you insist on defining products, rather than defining the software design, architecture, and code that they trust?
Ø testability. Can I test the features? Does the tester provide sufficient information to establish a test program for verification?

L statement terms check list
it indicates that the problem is generally characterized by a function that is not carefully considered for whitewashing-it can be attributed to the attribute described above. find out such terms from the product documentation and carefully examine how they are used in the text. the product description may be concealed, disclosed, or vague-either case may be regarded as a software defect.
ø always, each type, all, no, never. if you see such an absolute or positive description, the software tester can start to design a tit-for-tat case.
ø of course, obviously, it is inevitable. these words are intended to induce acceptance of assumptions. do not fall into the trap.
some, sometimes, often, usually, often, mostly, almost. these are too vague. "sometimes" function cannot be tested.
ø and so on, and so on. the function list ended with such a word cannot be tested. the function list must be either absolute or clear, so as to avoid confusion and draw inferences.
good, fast, cheap, efficient, small, and stable. these are uncertain statements and cannot be tested. if it appears in the product manual, you must further specify the meaning.
ø handled, rejected, ignored, and eliminated. these integrity may hide a large number of features that need to be described.
ø if... so... (None otherwise ). find out "if... so... "and lack of supporting" otherwise "structure statement. think about what will happen if "no" happens.

Related Article

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.