Follow Techotopia on Twitter

On-line Guides
All Guides
eBook Store
iOS / Android
Linux for Beginners
Office Productivity
Linux Installation
Linux Security
Linux Utilities
Linux Virtualization
Linux Kernel
System/Network Admin
Programming
Scripting Languages
Development Tools
Web Development
GUI Toolkits/Desktop
Databases
Mail Systems
openSolaris
Eclipse Documentation
Techotopia.com
Virtuatopia.com
Answertopia.com

How To Guides
Virtualization
General System Admin
Linux Security
Linux Filesystems
Web Servers
Graphics & Desktop
PC Hardware
Windows
Problem Solutions
Privacy Policy

  




 

 

Eclipse Application Testing Guide
Previous Page Home Next Page

Editing a test

You can inspect and modify a test prior to compiling and running it.

Note, the test is not yet executable. You can immediately make the test executable by right-clicking it in the Test Navigator of the Test Perspective and selecting Generate. Or you can first edit the test by right-clicking it and selecting Open.

Open the performance test in the TPTP URL Test editor.

The test opens in the Overview tab (see the bottom border) with the four edit areas (TPTP URL Test and Source Information on the left and Deployment and HTTP Requests on the right) expanded. You switch to the other edit panes by clicking the appropriate tab.

The TPTP URL Test area displays the test's name, an optional description, the test's type, and the name of the file containing the test. Information appearing in boxes can be edited. The Name box under TPTP URL Test displays the name of the test. You can change the name. If you do, the name displayed in the Test Navigator of the Test Perspective changes also but the filename containing the test does not change. In this example, the test's name, as listed in the Test Navigator of the Test Perspective and displayed in the Name box. The tester has decided to change the name to something more descriptive of the task that the test emulates, searchEmployeeDB.

The Source Information area displays the Java package name that will contain the test's executable Java code when it is generated, and the Java class implementing the test. You can relocate the code to a different package by clicking the Browse button under the Package Name: box. To open the generated source code for the TPTP URL test, click Open. Alternatively, right-click the TPTP URL test in the Test Navigator and select Open Source or Alt+Shift+T, O.

The HTTP Requests area on the right lists all HTTP requests in the test. Clicking one of these requests takes you to the HTTP Requests view.

You can also get to this edit pane by clicking the HTTP Requests tab along the bottom. When you click a request on the left, you see that request's properties on the right. You can:

  • Change the properties of an existing request
  • Add a new request and fill in its properties
  • Rearrange the order of the requests
  • Remove requests

To open the generated source code for the HTTP request, select the HTTP request and click Open. Alternatively, right-click the HTTP request under the TPTP URL test in the Test Navigator and select Open Source or Alt+Shift+T, O.

Use the Deployment section to set the number of users that you want to simulate during test execution.

Clicking the Behavior tab opens the behavior edit pane.

The HTTP requests are listed by page, as invocations, inside a loop construct initially named Loop 1. With this loop selected, you can rename the loop, describe what it does, or change the Number of Iterations. When Synchronous is checked, each iteration of the loop is executed sequentially. That is, the invocations and nested loops contained in the loop are executed, based to their Synchronous property, for an iteration before continuing to the next iteration. Conversely, when Synchronous is unchecked, the iterations of the loop are executed simultaneously. That is, the invocations and nested loops contained in the loop are executed, based to their Synchronous property, for all iterations at the same time. Inside Loop 1, you can:

  • Re-arrange the invocations
  • Remove invocations
  • Modify an invocation such that it invokes another existing test suite. Thus, if you click an invocation, an Edit button appears under Detailed Properties. Clicking this button opens the Test Invocation dialog box, allowing you to invoke another existing test suite in your workspace with the selected GET invocation.

With the Add button, you can create a new loop. Then, by right-clicking that new loop and selecting Invocation, you can populate the new loop with invocations of other test suites or test suite instances. You can also nest loops, and create invocations that are outside of any loop. With an invocation selected, you can rename the invocation, describe what it does, or modify an invocation such that it invokes another existing test suite. When Synchronous is checked, the invocation is executed sequentially. That is, the invocation is executed before continuing to the next invocation or loop. Conversely, when Synchronous is unchecked, the invocation executed simultaneously. That is, the invocation is executed at the same time as the sibling invocations and loops.


 
 
  Published under the terms of the Eclipse Public License Version 1.0 ("EPL") Design by Interspire