A portion of the disclosure of this patent document contains material which is subject to copyright protection. The copyright owner has no objection to the facsimile reproduction by anyone of the patent document or the patent disclosure as it appears in the Patent and Trademark Office patent file or records, but otherwise reserves all copyright rights whatsoever.
1. Field of the Invention
The present invention relates to software testing and, more particularly, to automated analysis and testing of websites.
2. Description of the Related Art
Websites are complex collections of information intended to be viewed and used and interacted with by sending information from a server (website server) over the Internet to users who work with this information from an internet browser client program (internet browser) that typically runs on a personal computer or other computing device. A common Internet browser is Internet Explorer (IE) by Microsoft Corporation. The IE browser runs on the Microsoft Windows NT and Windows 2000 operating systems.
Testing and analysis of websites is needed to: (i) confirm content and proper operation and proper content (i.e., functional testing and validation); (ii) determine delivered performance of a website server (i.e., website timing and tuning); (iii) analyze capacity of the website server by imposing realistic loads (i.e., website server loading); and (iv) identify erroneous website pages (i.e., site analysis).
Conventionally, there are several alternative methods that can be used to obtain information about how a website behaves when viewed from the Windows environment. One conventional method intercepts a Windows event loop. Another conventional method intercepts a HTTP protocol sequence by building a wrapper or proxy around an instance of the Internet browser. Both of these conventional methods have disadvantages. One disadvantage of intercepting the Windows event loop is that every keyboard activity and/or mouse activity at the primitive level of its interaction with the operating system must be handled. This leads to cumbersome programming. One disadvantage of intercepting of the HTTP protocol sequence via a wrapper or proxy is that the focus is on the communication between the Internet browser and the server.
Thus there is a need for improved approaches to testing websites.
Broadly speaking, the invention relates to improved approaches for testing websites. According to one aspect of the invention website testing is performed in a browser environment. As such, information for testing can be obtained from a browser that is able to perform automated analysis and testing of websites. For example, the browser can emulate operation of an Internet Explorer (IE) browser while having additional functionality to provide automated analysis and testing of websites. The invention can thus be implemented in a test-enabled Internet browser.
The invention can be implemented in numerous ways including, a method, system, device, graphical user interface, and a computer readable medium. Several embodiments of the invention are discussed below.
Other aspects and advantages of the invention will become apparent from the following detailed description taken in conjunction with the accompanying drawings which illustrate, by way of example, the principles of the invention.
The invention will be readily understood by the following detailed description in conjunction with the accompanying drawings, wherein like reference numerals designate like structural elements, and in which:
Broadly speaking, the invention relates to improved approaches for testing websites. According to one aspect of the invention website testing is performed in a browser environment. As such, information for testing can be obtained from a browser that is able to perform automated analysis and testing of websites. For example, the browser can emulate operation of an Internet Explorer (IE) browser while providing additional functionality to provide automated analysis and testing of websites. The invention can thus be implemented in a test-enabled Internet browser.
By performing website testing in a browser environment, various advantages can be facilitated. These advantages can include: greater control of the test process, ability to measure at a fine level of detail, ability to manipulate and validate the contents of website pages as they are rendered, and ability to extract linking and other information from website pages in their fully rendered form.
There are various inventive aspects to the invention. Several of the invention aspects are as follows. These and other aspects described herein can be used separately or in any combination.
According to a general aspect of the invention website testing is performed in a browser environment. As such, information for testing can be obtained from a browser that is able to perform automated analysis and testing of websites. For example, the browser can emulate operation of an Internet Explorer (IE) browser while providing additional functionality to provide automated analysis and testing of websites. The invention can thus be implemented in a test-enabled Internet browser.
The invention enables the analysis of websites to produce a script-like recording that captures the essence of user activity for purposes of playback against the website server that will serve to reproduce the behavior noted during the recording, the capture during the recording process of validation information that can be used to ascertain after the fact if the website under test has changed, the actual playback of scripts recording in accordance with the above, and the automatic development of PASS/FAIL results based on whether the validation facts written in the script are true at the time of playback. The invention also enables analysis of the times the invention records as it plays back certain events, the emulation of multiple users for purposes of generating the load equivalent to multiple users as seen by a website server, and the static analysis of individual website pages to ascertain certain properties of them, their dependence on other pages, and the availability, download size and speed, and other quantitative factors and measurements about them.
According a first aspect of the invention, record and playback capabilities are provided. Here, a test-enabled web browser is used in the normal way to interact with the website under test. During this interaction, the user can command certain kinds of data to be extracted into a script file as a part of the recording process. The resulting recording is thus typically not a detailed record of user keyboard and mouse activity such as might be achieved by intercepting the Windows event loop, but instead is an abstraction of that activity based on analysis of the event triggers that happen as a consequence of the user taking action(s). In one embodiment, the test enabled web browser is implemented such that it web browsing operations are identical to that in an IE browser because the same Dynamic Linked Libraries (DLLs) as are used in the underlying Windows environment. The recording that results will, on playback, interact with the website under test to produce the same results as were attained at the time the recording was made, assuming that the website under test has not changed. This mode of operation is important to proper operation of the invention as a regression and test system because this mode permits recordings to behave in a way that reveals actual content and behavior errors, but not to be confused by variations in type font and user presentation of the information that the browser extracts from the website. In one representative embodiment this information can be kept in a standard ASCII file.
Overall timing of the recording process can be preserved in a series of wait commands within the script that cause the playback engine to emulate the user “think time” with 1.0 millisecond precision. The nature of the recording mechanism in the invention makes it possible to assure that full synchronization occurs during playback, even if some parts of the website server behave faster or slower than during the recording.
According a second aspect of the invention, validation capabilities are provided. During recording a user can select and specify certain information that is extracted immediately from the current rendition of a web page and which is deposited in special formats within the recorded script. This information can include such facts as the specific content of a part of a web page at a particular element count offset, the date and file details of an image, the checksum (the sum of all of the pixels) of a selected region of an image on a page, etc. At playback time, this information can be checked using an internal model of the web page. If the validation checkpoints fail, then error messages and other kinds of responses are given. In the representative embodiment this information is kept in a series of ASCII logfiles.
According a third aspect of the invention, script playback is provided. During playback, the script is read and interpretively executed by the invention and the instructions are fed to the test-enabled web browser so that it will act identically the way the user acted during the recording process in terms of producing the identical same effect. Any wait time values that are noted from the script can be played back (i.e., counted out) at a specific playback multiplier ratio in relation to real time. If the multiplier is 0, then all waits are set to zero. However, the nature of the recording mechanism in the invention makes it possible to assure that full synchronization occurs during playback, even if some parts of the website server behave faster or slower than during the recording. In one embodiment, the script playback can take on an adaptive nature so that changes to web pages can be gracefully tolerated.
According a fourth aspect of the invention, timing evaluations are provided. In addition to wait times which were discussed above, the invention measures details of web page component downloads by monitoring the contents of a cache. All of the phases of download of pages can be monitored for detailed timing values, including base page download, linked page download (JavaScript and Cascading Style Sheets (CSSs) etc.), plus individual images files and other supporting pages that are reference by the web page as it is being downloaded. According to one embodiment, the invention takes times from its internal 1.0 millisecond clock and associates these times to the actual (measured) download timings for every part of a web page and its components. Such information can be used to analyze slow-loading pages and/or image parts.
According a fifth aspect of the invention, server load testing can be performed. The goal of website server load testing is to simulate realistic load in order to determine limits and capacities of the website server machines. The invention accomplishes this goal by taking advantage of the fact that, running with the cache turned off, multiple copies of the test-enabled browser can execute on the client machine each running a separate playback script. All extant copies of the invention can run the same script, or each copy can run a different script, or any combination of the above. The complex of multiple playbacks is called a load scenario and the invention uses a special mechanism that permits a special kind of playback script called a load test script. LoadTest data can be accumulated in a special LoadTest results log that is implemented in accordance with the conventions of the underlying Windows environment. Analyses of these log files is generally well known, and aims to portray the minimum, average, and maximum response times for all playbacks in progress.
According a sixth aspect of the invention, site analysis can be performed. In the invention use is made of standard methods of recursive descent examination of website pages to construct a detailed dependence map showing the relationships between the starting website page Universal Resource Locator (URL) and the child (or dependent) pages via their link structure. In accordance with standard methods (e.g., spider), the search of a website is limited to a user-specified maximum depth, to a user-specified maximum time, and/or to a user-specified maximum number of website pages to visit or links to accumulate. According to this aspect, as this search process is being accomplished, each retrieved page can be passed through one or more quality filters. Filtering, for example, can be based on byte count, presence of spelling errors, presence of strings, download times, etc. The results of the filtering process can be presented to a user in real-time and in a display page that is updated for the user on the Windows desktop each time the respective filter finds new information. In one embodiment, the spider is performed by the test-enabled browser.
A test-enabled browser processing 200 initially begins with a decision 202 that determines whether a trigger has been received. When the decision 202 determines that a trigger for the test-enabled browser has not yet been received, then the test-enabled browser processing 200 awaits such a trigger. Once the decision 202 determines that a trigger has been received for the test-enabled browser, test-based processing is performed 204. Here, the test-based processing is the processing needed to carry out the particular type of testing being performed on a determined website. Following the performance of the test-based processing, browser-based processing is performed 206. Here, the browser-based processing is processing typically performed by a browser application (network browser). Here, the browser-based processing, in one implementation, can be provided using the code resources w stored in the IE based library 102 illustrated in
The test-enabled browser can perform a variety of different tests for websites. One such test is referred to as a load test, in which loads are artificially supplied to a particular website to test its performance and abilities under such circumstances.
According to one embodiment, the system and method of the invention can be implemented by a number of elements that work together to accomplish the intended results. In this embodiment, the test-enabled browser is referred to as eValid.
1. General—OS Context
2. General—Normal Browser Operation
3. General—Graphical User Interface(GUI)
4. General—Application Programming Interface
5. General—Script Language
6. General—Script Command Format
7. General—Results Logging
8. Record/Play—General
9. Record/Play—Applets and/or ActiveX Controls
10. Record/Play—Keyboard Actions
11. Record/Play—Modal Dialog Support
12. Record/Play—Applets
13. Record/Play—Application Mode
14. Record/Play—Javascript
15. Record/Play—Multiple-Window (Sub-Browser) Operation
16. Record/Play—Page Synchronization
17. Record/Play—Checksum Synchronization
18. Record/Play—Link Wizard
19. Record/Play—Form Wizard
20. Validation—General
21. Validation—Validate Image
22. Validation—Validate Table Cell
23. Validation—Validate [Selected] Text
24. Playback—Batch Mode
25. Playback—Interactive Mode
26. Playback—Multiple/Repeat Playback
27. Playback—Alarms
28. Playback—Synchronization
29. Playback—Cache Management
30. Playback—Extrinsic Commands
31. Playback—Secure Sessions
32. Playback—Adaptive Playback
33. Timing—General
34. Timing—Detailed Timing
35. Timing—Charting
36. LoadTest—Load Generation
37. LoadTest—Multiple Parallel Browsers
38. LoadTest—Scenario Creation
39. LoadTest—Reporting
40. Site Analysis—General
41. Site Analysis—Limits
42. Site Analysis—Protocols
43. Site Analysis—Files
44. Site Analysis—Filters & Reports
The invention, or aspects thereof, are further described by the following numbered paragraphs:
The invention is preferably implemented in software, but can be implemented in hardware or a combination of hardware and software. The invention can also be embodied as computer readable code on a computer readable medium. The computer readable medium is any data storage device that can store data which can be thereafter be read by a computer system. Examples of the computer readable medium include read-only memory, random-access memory, CD-ROMs, magnetic tape, optical data storage devices, carrier waves. The computer readable medium can also be distributed over a network coupled computer systems so that the computer readable code is stored and executed in a distributed fashion.
Additional details on testing and analysis of websites are contained in Appendices A–F attached hereto and which form part of this application. The Appendices are as follows:
The many features and advantages of the present invention are apparent from the written description and, thus, it is intended by the appended claims to cover all such features and advantages of the invention. Further, since numerous modifications and changes will readily occur to those skilled in the art, it is not desired to limit the invention to the exact construction and operation as illustrated and described. Hence, all suitable modifications and equivalents may be resorted to as falling within the scope of the invention.
This application claims the benefit of U.S. Provisional Patent Application No. 60/293,879, filed May 24, 2001, and entitled “METHOD AND SYSTEM FOR TESTING WEBSITES”, and which is hereby incorporated by reference herein. This application also claims the benefit of U.S. Provisional Patent Application No. 60/244,818, filed Oct. 31, 2000, and entitled “METHOD AND SYSTEM FOR TESTING WEBSITES”, and which is hereby incorporated by reference herein.
| Number | Name | Date | Kind |
|---|---|---|---|
| 5974572 | Weinberg et al. | Oct 1999 | A |
| 6044398 | Marullo et al. | Mar 2000 | A |
| 6138157 | Welter et al. | Oct 2000 | A |
| 6151599 | Shrader et al. | Nov 2000 | A |
| 6157940 | Marullo et al. | Dec 2000 | A |
| 6393479 | Glommen et al. | May 2002 | B1 |
| 6418544 | Nesbitt et al. | Jul 2002 | B1 |
| 6421070 | Ramos et al. | Jul 2002 | B1 |
| 6446120 | Dantressangle | Sep 2002 | B1 |
| 6522995 | Conti et al. | Feb 2003 | B1 |
| 6587969 | Weinberg et al. | Jul 2003 | B1 |
| 6601020 | Myers | Jul 2003 | B1 |
| 6662217 | Godfrey et al. | Dec 2003 | B1 |
| 6741967 | Wu et al. | May 2004 | B1 |
| 6754701 | Kessner | Jun 2004 | B1 |
| 7000224 | Osborne et al. | Feb 2006 | B1 |
| 20020035498 | Kehoe et al. | Mar 2002 | A1 |
| 20020038388 | Netter | Mar 2002 | A1 |
| 20030053420 | Duckett et al. | Mar 2003 | A1 |
| 20040039550 | Myers | Feb 2004 | A1 |
| Number | Date | Country | |
|---|---|---|---|
| 20030005044 A1 | Jan 2003 | US |
| Number | Date | Country | |
|---|---|---|---|
| 60293879 | May 2001 | US | |
| 60244818 | Oct 2000 | US |