DW RT Hellormt PDF

You might also like

Download as pdf or txt
Download as pdf or txt
You are on page 1of 22

Hello World: Rational Manual Tester

Accelerating the pace and quality of the manual testing process


Skill Level: Intermediate Brian Bryson Technology Evangelist IBM

26 Dec 2006 This tutorial introduces you to IBM Rational Manual Tester and highlights some of its basic features. It includes practical exercises that show you how to create robust and modular manual tests, save time with automated data entry, and reduce manual test errors with automated data comparison.

Section 1. Before you start


About this series
This series is for novices who want high-level overviews of IBM software products. The modules are designed to introduce the products and draw your interest for further exploration. The exercises only cover the basic concepts, but are enough to get you started.

About this tutorial


This tutorial provides a high-level overview of IBM Rational Manual Tester, and gives you the opportunity to practice using it with hands-on exercises. Step-by-step instructions show you how to create, execute, and examine the results of manual tests to ensure the quality of your software application.

Rational Manual Tester Copyright IBM Corporation 2006. All rights reserved.

Trademarks Page 1 of 22

developerWorks

ibm.com/developerWorks

This tutorial was created with the version 7.0 of Rational Manual Tester. The exercises can be completed with both the trial and the licensed versions of Rational Manual Tester.

About the application under test


The exercises in this tutorial will help you create and execute tests against a sample application, ClassicsCD. The ClassicsCD application is an online music store that specializes in classical music. Using it, you can place orders for CDs, as well as view the status of existing orders and customer accounts. The ClassicsCD sample application is installed automatically by Rational Manual Tester.

Objectives
After completing this tutorial, you should understand the basic functions of Rational Manual Tester. You should also be able to create manual tests, similar to those demonstrated in the exercises, to validate the quality of your software application.

Prerequisites
This tutorial is for testers new to Rational Manual Tester. No pre-requisite knowledge is assumed or required. To complete the exercises in this tutorial, install Rational Manual Tester. To view the demos included in this tutorial, you should have JavaScript enabled in your browser, and Macromedia Flash Player version 6 or later installed. You can download the latest Flash Player at http://www.macromedia.com/go/getflashplayer/

Animated demos
If this is your first encounter with a developerWorks tutorial that includes demos, here are a few things you might want to know: Demos are an optional way to see the steps described in the tutorial. To see an animated demo, click the Show me link. The demo opens in a new browser window. Each demo contains a navigation bar at the bottom of the screen. Use the navigation bar to pause, exit, rewind, or fast forward portions of the demo. The demos are 800 x 600 pixels. If this is the maximum resolution of your
Rational Manual Tester Copyright IBM Corporation 2006. All rights reserved. Trademarks Page 2 of 22

ibm.com/developerWorks

developerWorks

screen, or if your resolution is lower than this, you will have to scroll to see some areas of the demo. You should have JavaScript enabled in your browser, and Macromedia Flash Player version 6 or later installed.

Section 2. Introduction
At first glance, manual application testing seems a simple process. Write down some test steps in a text file or document, perform those steps, and note the results in a spreadsheet. What could be simpler? Seasoned quality assurance professionals would certainly confirm that, while it may seem simple in theory, in practice managing the manual testing process quickly becomes overwhelming. Test maintenance becomes a problem when an application changes and test steps need to be updated. Worse, test steps documented in multiple tests must be kept in sync. Furthermore, entering complex data into applications is often an error-prone exercise, as is the comparison of expected and actual results. Test results quickly pile up, finally, and you will soon find yourself not knowing what has been tested, what works, and what does not work. Rational Manual Tester is an intuitive application that helps you document, execute, and manage the manual testing process. Using Rational Manual Tester, you will be able to: Minimize test maintenance by creating tests that document common content in a single location Eliminate human error during the data entry and data comparison stages of test execution Collect and organize your test results in a simple, intuitive interface

Getting started
When you first launch Rational Manual Tester you will be greeted by the Welcome page, shown in Figure 1. Figure 1. Welcome screen

Rational Manual Tester Copyright IBM Corporation 2006. All rights reserved.

Trademarks Page 3 of 22

developerWorks

ibm.com/developerWorks

The Welcome page offers quick links to tutorials and samples. Click the Overview icon to browse all of the materials. For a quick multi-media overview of the product, take the 5-minute Product Tour. Close the Welcome page and you will be taken to the Workbench. The Workbench is the main interface for Rational Manual Tester, and it is where you will do all of your test work.

Workbench overview
There are five main tabs on the Rational Manual Tester Workbench, as shown in Figure 2. Figure 2. Rational Manual Tester Workbench

Rational Manual Tester Copyright IBM Corporation 2006. All rights reserved.

Trademarks Page 4 of 22

ibm.com/developerWorks

developerWorks

Explore the power of Eclipse


Rational Manual Tester uses the Eclipse framework as its development environment. Among the many benefits of this environment is the flexibility it allows you with regards to the layout. You can adjust the size of any of the views, and you can move the tabs around. You can even layer tabs on top of each other, hiding rarely used tabs and giving more space to your most prominent tabs. To re-arrange your workbench, simply drag the views around the desktop by their tabs.

Following are the elements in the Workbench In the middle of the Workbench is the Editor tab. The Editor is used to document a manual test. By default, when you open the Workbench, the Editor displays an empty test called "untitled.rmt". On the left side is the Outline tab. It displays a short summary of each step documented in the Editor. The Outline tab is also used to link (share) content among tests. Next to the Outline tab is the Recent Files tab. This tab displays the files that you have been working with, to make it easy for you to open a
Rational Manual Tester Copyright IBM Corporation 2006. All rights reserved. Trademarks Page 5 of 22

developerWorks

ibm.com/developerWorks

recently used test or test result. The Reuse tab is at the top right. You can place test content that will be reused among multiple tests on the Reuse tab for quick access. The Properties tab is at the bottom right. It contains additional information about the test currently displayed in the Editor. Note that in the bottom left corner of the Workbench is a toolbar that lets you quickly get back to the Welcome page and all of the other Rational Manual Tester introductory assets

Tutorial configuration
Included with this tutorial is some sample data that you will use during the exercises. This sample data is in the tutorial sample data .zip file included with this tutorial. Perform the following steps to configure Rational Manual Tester to use this data. 1. Expand the .zip file to a location on your hard drive. For the purposes of this tutorial, we'll assume that you have expanded the file to the C:\ directory, which would automatically place the files in C:\Rational Manual Tester Tutorial. In Rational Manual Tester, select Window > Preferences. On the Main Preferences page, click the Browse button for the Re-use file location, as depicted in Figure 3. The re-use file location specifies the directory where the list of your re-usable statements will be stored. Specify C:\Rational Manual Tester Tutorial as the re-use file location.

2. 3.

4.

Figure 3. Reuse file location on the Main Preferences page

Rational Manual Tester Copyright IBM Corporation 2006. All rights reserved.

Trademarks Page 6 of 22

ibm.com/developerWorks

developerWorks

Section 3. Authoring manual tests


Jump-start the testing process
Do you already have tests documented in another tool such as IBM Rational TestManager, Microsoft Word, or Microsoft Excel? If so, you can import these tests into Rational Manual Tester. Select File > Import Test Document to use the Rational Manual Tester Import wizard to import your existing tests into the Rational Manual Tester framework.

A manual test in Rational Manual Tester is a document with an ordered set of steps that users will execute to perform a given set of actions against their application. This section will examine the four different types of test statements used by Rational Manual Tester and then proceed to use those statements types to create our first test. Four types of test statements Manual tests can contain four types of statements. Each statement type is denoted by an icon at the beginning of each statement in the test editor. Step : A step is a statement that instructs the tester to perform some

action. For example, "Start the application" or "Click the New button" might be common test step instructions. Verification Point : A verification point is a statement that instructs the user to verify a particular behavior of the application under test. "Verify that the Login button appears in the top right corner" or "Does the application return the date in the format mm/dd/yy?" are examples of common verification point statements. When the tester executes a test that contains a verification point, the tester must enter a result for each verification point. Reporting Point : A reporting point is a high-level verification point. It is often used to ask a summary question about the success or failure of the entire test. A good practice is to end every test with a reporting point. The Pass or Fail verdict assigned to this reporting point will be the verdict assigned to the overall test. Group : A group indicates a block of related statements. For example, you might have a group called Login that contains steps for entering a
Rational Manual Tester Copyright IBM Corporation 2006. All rights reserved. Trademarks Page 7 of 22

developerWorks

ibm.com/developerWorks

user id, entering a password, and clicking Login.

Creating a test script


Using the four types of statements above, you can now create your first test script. You're going to start from scratch, and build a test that will verify the status of an order in your online store, ClassicsCD. Animated demo
Would you like to see these steps demonstrated for you? Show me

Creating steps and leveraging re-usable statements To create some re-usable statements, follow these steps. 1. 2. 3. If it's not already open, launch the ClassicsCD application from Start > All Programs > IBM Rational Manual Tester > ClassicsJavaA. If it's not already open, launch Rational Manual Tester. If this is your first time using the tool, you should have a blank script (untitled.rmt) open and ready. If not, select File > New to create a new blank script.

The first step of the test will be to launch your application. This is a step that is common to many tests and exists already in our Re-use view. 4. Click on the statement in the Re-use view and drag it into your test. It becomes the second statement in your test under Begin typing test statements here. Note that the statement has a gray background, indicating it is a re-used statement. Press Enter to move the cursor to a new step. Type Select Order > View Existing Order Status... as the next step. It's a good idea to use color coding in your tests. Highlight Order > View Existing Order Status... in the statement you just created and click the color palette icon on the toolbar. Change the color to match the coloring of the first statement. On the color grid it is in the third

5. 6. 7.

Rational Manual Tester Copyright IBM Corporation 2006. All rights reserved.

Trademarks Page 8 of 22

ibm.com/developerWorks

developerWorks

row, third from the right. 8. With Order > View Existing Order Status... still highlighted, press CTRL-B or select the Bold icon from the toolbar to bold this selection. 9. Press Enter to move the cursor to a new blank line in the test.

10. Finally, remove the first statement that Rational Manual Tester automatically included at the beginning. In the Outline view, right-click the blank first statement in the test and select Delete. 11. Select File > Save and save your test as Verify Order Status. Figure 4 shows the first step in the Verify Order Status.rmt test. Figure 4. Verify Order Status test step 1

Create a statement group To create a statement group, follow these steps. 1. Type Select User Susan Flontly as the next step. Highlight the name Susan Flontly, change the color, and apply bold formatting as you did in the previous section. In the ClassicsCD application, select Order > View Existing Order Status. Select Susan Flontly from the Full Name drop down. Do not click OK yet. You'll now leverage the ability to insert a screenshot into your test. Select Capture > Image from the menu. In the Capture Image dialog, select the 2nd option, Window, Dialog, etc. and click OK. Using the hand pointer, point to the View Order Status window. When the

2. 3. 4. 5. 6.

Rational Manual Tester Copyright IBM Corporation 2006. All rights reserved.

Trademarks Page 9 of 22

developerWorks

ibm.com/developerWorks

dialog border turns red, click your mouse button to grab a snapshot. 7. Press Enter to move to the next line, and type Place cursor in Password field and paste in password from clipboard as the next step. Bold the word paste. In the lower right of the Properties view, select the Clipboard tab. In the Paste Data field, type the word secret. When you execute this step, you will be able to paste this value into the test. Note that a little data icon appears next to the step icon to indicate that there is data associated with this step.

8. 9.

10. Press Enter to move to a new line, and type the step Click OK . Bold the word OK. 11. Press Enter to move the cursor to a new blank line in the test. 12. Now you'll group these last three steps. Highlight the last three steps (from Select User to Click OK). Right-click and select Add to Group. 13. Notice that the statements were grouped together under a folder that reads "Add group description here". Replace that group description with View Order Status for Susan Flontly. 14. Select File > Save and save your test as Verify Order Status. 15. For future use, make this group a re-usable statement. In the Outline view, drag the group over to the Re-use view. Now, this group of steps can be reused in other tests. Figure 5 shows the group of steps. Figure 5. Verify Order Status test step 2

Rational Manual Tester Copyright IBM Corporation 2006. All rights reserved.

Trademarks Page 10 of 22

ibm.com/developerWorks

developerWorks

Create a verification point for automated comparison To create a verification point, follow these steps. 1. 2. 3. In the ClassicsCD Application, click OK to view the order status for Susan Flontly. Click the order information, and then press CTRL-C to copy this information to the clipboard. In Rational Manual Tester, the last line of your test should be a blank line that is not part of the View Order Status for Susan Flontly group. If it is not, create a blank line for your next step. If it shows up as part of the group, right click and select Remove from Group. 4. Type Highlight all of Order 5, hit CTRL-C to copy data to clipboard and perform a data compare as the next step. Bold the CTRL-C. Optionally, take a screenshot to make the test easier to execute.
Trademarks Page 11 of 22

Rational Manual Tester Copyright IBM Corporation 2006. All rights reserved.

developerWorks

ibm.com/developerWorks

5.

Right-click the statement you just typed and select Statement Type > Set as Verification Point. This will enable you to associate a Pass/Fail verdict with this step when you run the test. In the Properties view, select the Clipboard tab. In the Compare Data box, paste the order information you copied from the application by pressing CTRL-V. Note again the data icon next to the step icon. The last two characters you pasted into the Compare data window should be 00. Remove these two zeros. This will produce a defect to find when you run the test. Press Enter to move to a blank line in the test, and then type Click Close as the next step. Check the statement type for the last step. It should be Step, but may have defaulted to Verification Point based on the last statement. If the statement type is Verification Point, change it back to Step.

6.

7.

8. 9.

10. Press Enter to move to a blank line in the test, and type Close ClassicsCD. 11. Press Enter to move to a blank line in the test, and type Report Verdict. 12. Finally, right-click your final statement and change it to a Reporting Point by selecting Statement Type > Set as Reporting Point. Always make the last step of every test a reporting point. The Pass/Fail verdict you assign to this reporting point will be the verdict assigned to the test as a whole. 13. Select File > Save to save your work. Figure 6 shows the Reporting Point you inserted. Figure 6. Verify Order Status test step 3

Rational Manual Tester Copyright IBM Corporation 2006. All rights reserved.

Trademarks Page 12 of 22

ibm.com/developerWorks

developerWorks

Creating a test script summary


Congratulations! You have just authored your first manual test in Rational Manual Tester. You've used steps, groups, reporting points, and verification points. You've used a shared statement available from another test, and you've tagged one of your statements as a re-usable statement for future tests. You've added a little color, and you've added a screenshot as well. If it seemed like you were doing a lot in that exercise, you were! If, by chance, you feel that you have gone astray in following the steps to this point,

Rational Manual Tester Copyright IBM Corporation 2006. All rights reserved.

Trademarks Page 13 of 22

developerWorks

ibm.com/developerWorks

you can open the Verify Order Status Backup. It contains a final copy of the test you just created. You can use it as the basis for the remaining two exercises.

Section 4. Manual test execution


Animated demo
Would you like to see these steps demonstrated for you? Show me.

With your test complete, it's time to move on to test execution. During test execution, Rational Manual Tester will walk you through your test, step by step. The interface will appear transparent (as shown in Figure 7), so that you'll be able to see both your application and the test. You'll proceed to follow the test, step by step. For Verification and Reporting Points, you will enter a Pass/Fail verdict to record the status of your test. Upon completion, you'll save your results and, finally, be able to view a log of your test.

Execute the test


Figure 7. Translucent playback window

Rational Manual Tester Copyright IBM Corporation 2006. All rights reserved.

Trademarks Page 14 of 22

ibm.com/developerWorks

developerWorks

1. 2.

Execute your test by selecting Run > Run Script. As you execute, Rational Manual Tester puts an arrow pointing at the test step you should execute. The first step is to launch the application. Follow the steps to start ClassicsCD. Click the Apply button to acknowledge completion of this step.

3.

Note that the pointer moves to the next step. 4. To complete the second step of the test, select Order > View Existing Order Status, and click the Apply button . To complete the next step of the test, select Susan Flontly, and click Apply . To complete the next step of the test, place the cursor in the Password field and paste the password from the clipboard. Rational Manual Tester's automated data entry enters the password for you: no more typos! Click Apply to move to the next step.

5.

6.

Rational Manual Tester Copyright IBM Corporation 2006. All rights reserved.

Trademarks Page 15 of 22

developerWorks

ibm.com/developerWorks

7.

To complete the next step of the test, click OK, and then click Apply to move to the next step. To complete the next step of the test, highlight all of Order 5 and press CTRL-C to copy data to the clipboard and perform a data compare. Click the Compare Copied Text to Expected Text button . Note the difference that Rational Manual Tester has found. The expected total price is 53.85, the actual is 53.8500, as shown in Figure 8. Rational Manual Tester's automated data comparison tool is very precise. Would you have caught that discrepancy? Figure 8. Automated data comparison

8.

9.

10. Click OK to close the comparison. 11. Add a comment to this step. In the Properties view, select the Comments tab. In the Comments box, type Price has too many decimal points. 12. Add a screenshot to illustrate the problem. Click the Capture Image icon on the toolbar to capture an image of the price region of the screen. 13. In the File Name dialog, name the file Price. 14. Click OK and drag the cursor to capture the Total price from the View Existing Orders dialog. 15. In the verdict drop-down, select fail and click Apply to complete the step. 16. To complete the next step of the test, click Close, and click Apply to move to the next step. 17. On the final step, select pass from the verdict drop-down to assign a

Rational Manual Tester Copyright IBM Corporation 2006. All rights reserved.

Trademarks Page 16 of 22

ibm.com/developerWorks

developerWorks

verdict of pass to the entire test and click Apply to complete the test. 18. Select Yes when prompted to save your test results. 19. Accept the default name of Verify Order Status and click Save to save your results. Note that if you expect to run a test several times, it is often a good idea to use a name with a date and time, such as Verify Order Status_18Dec2006.

Execute the test summary


Need to take a break?
At any point during test execution you can pause and save your work. Selecting Run > Pause/Return to Script. Manual Tester will save your work, and you'll be able to resume later, at a more convenient time. This is especially useful for tests that encounter blocking defects that prevent completion of the test.

Another major milestone! You have run your first manual test. You saw how Rational Manual Tester uses a translucent interface to maximize real estate. You executed steps and verification points that used automated data entry and capture. You noted test results, made comments, and took screenshots. Well done!

Section 5. Examining the test results


Animated demo
Would you like to see these steps demonstrated for you? Show me>

Examine the log


The last step in your journey will have you examining your test log, as shown in Figure 9. You'll examine the data that is captured in the log, and explore the opportunities to integrate to IBM's defect tracking and test management system, IBM Rational ClearQuest.

Rational Manual Tester Copyright IBM Corporation 2006. All rights reserved.

Trademarks Page 17 of 22

developerWorks

ibm.com/developerWorks

Figure 9. Test log results

1. 2. 3.

Navigate to the Recent Files view by clicking on the Recent Files tab. It is the tab beside the outline view. In the Test Logs folder, double click the Verify Order Status execution file to view your test log. The test log has two tabs, Overview and Events. The Overview tab contains information such as the final verdict and the time of test execution. There is also a link you can click to open up a copy of the test. Select the Events tab. The Events tab is located at the bottom left of the test log. Expand the log Events by clicking the plus sign beside the Verify Order Status line of the log. Click each event, noting the general properties (such as time and date) that Rational Manual Tester has captured for each.
Trademarks Page 18 of 22

4. 5. 6.

Rational Manual Tester Copyright IBM Corporation 2006. All rights reserved.

ibm.com/developerWorks

developerWorks

7.

Click the (fail) Highlight all of Order 5, hit CT event. Note your comment for this event, as well as the link to your screenshot of Price.jpg.

Examine the log summary


Well done, you've completed the journey. Quickly going over the log, you were able to see all the key information, captured at both the log level and the log event level. You were able to see your comments, your screen shot, and date and time stamp information for every step. You now have everything you need to report on the results of your testing. Defect and test management In your exploration of the test log, did you notice the ClearQuest Records section? If ClearQuest were installed, you could entered a defect directly from the Rational Manual Tester log. In fact, the integration is even tighter than simple defect entry. If you explore the Rational Manual Tester interface, you will see how tightly Rational Manual Tester is tied to ClearQuest. You can log into ClearQuest from Rational Manual Tester, and you can view the ClearQuest Test Manager feature, which controls your test plan and reports on your aggregated results. Together, Rational Manual Tester and ClearQuest certainly make a combination whose whole is greater than the sum of its parts.

Section 6. Summary
Wrap-up
This tutorial provided an introduction to Rational Manual Tester. By performing the tutorial steps, you authored, executed, and examined the results of a manual test. You learned the following: During test authoring, you covered key functionality such as re-usable steps, which promote re-use and reduce script maintenance. During test execution, you leveraged Rational Manual Tester's ability to automatically enter and validate data to ensure error-free testing.

Rational Manual Tester Copyright IBM Corporation 2006. All rights reserved.

Trademarks Page 19 of 22

developerWorks

ibm.com/developerWorks

Finally, during execution, you saw the great level of detail captured in the test log, from time stamps to comments to screenshots, all of which provide great test results documentation. Congratulations. You now have everything you need to go out and start documenting, executing, and analyzing your manual tests with IBM Rational Manual Tester.

Rational Manual Tester Copyright IBM Corporation 2006. All rights reserved.

Trademarks Page 20 of 22

ibm.com/developerWorks

developerWorks

Downloads
Description
Rational Manual Tester Tutorial Sample Data Information about download methods

Name
RMTTutorialSampleData.zip

Size
145KB

Download method
HTTP

Rational Manual Tester Copyright IBM Corporation 2006. All rights reserved.

Trademarks Page 21 of 22

developerWorks

ibm.com/developerWorks

Resources
Download the Rational Manual Tester Trial Software. Share tips and tricks in the Rational Manual Tester Discussion Forum.

About the author


Brian Bryson Brian Bryson joined Rational Software in 1995 with a strong background in Quality Assurance. Currently, he is a member of the product team that plans and delivers the IBM Rational automated toolset. A former instructor at Carleton University in Ottawa, Canada, Mr. Bryson has taught the IBM Rational approach to quality management to undergraduate students, as well as to employees of organizations worldwide.

Rational Manual Tester Copyright IBM Corporation 2006. All rights reserved.

Trademarks Page 22 of 22

You might also like