You are on page 1of 61

PeopleSoft Test Framework

8.53 Self Study Guide


PeopleSoft Test Framework 8.53 Self Study Guide
Copyright © 2015, Oracle and/or its affiliates. All rights reserved.
Oracle and Java are registered trademarks of Oracle and/or its affiliates. Other names may be trademarks of
their respective owners.
Intel and Intel Xeon are trademarks or registered trademarks of Intel Corporation. All SPARC trademarks are
used under license and are trademarks or registered trademarks of SPARC International, Inc. AMD, Opteron,
the AMD logo, and the AMD Opteron logo are trademarks or registered trademarks of Advanced Micro
Devices. UNIX is a registered trademark of The Open Group.
This software and related documentation are provided under a license agreement containing restrictions on
use and disclosure and are protected by intellectual property laws. Except as expressly permitted in your
license agreement or allowed by law, you may not use, copy, reproduce, translate, broadcast, modify, license,
transmit, distribute, exhibit, perform, publish, or display any part, in any form, or by any means. Reverse
engineering, disassembly, or decompilation of this software, unless required by law for interoperability, is
prohibited.
The information contained herein is subject to change without notice and is not warranted to be error-free. If
you find any errors, please report them to us in writing.
If this is software or related documentation that is delivered to the U.S. Government or anyone licensing it on
behalf of the U.S. Government, the following notice is applicable:
U.S. GOVERNMENT END USERS: Oracle programs, including any operating system, integrated software,
any programs installed on the hardware, and/or documentation, delivered to U.S. Government end users are
"commercial computer software" pursuant to the applicable Federal Acquisition Regulation and agency-
specific supplemental regulations. As such, use, duplication, disclosure, modification, and adaptation of the
programs, including any operating system, integrated software, any programs installed on the hardware,
and/or documentation, shall be subject to license terms and license restrictions applicable to the programs.
No other rights are granted to the U.S. Government.
This software or hardware is developed for general use in a variety of information management applications.
It is not developed or intended for use in any inherently dangerous applications, including applications that
may create a risk of personal injury. If you use this software or hardware in dangerous applications, then you
shall be responsible to take all appropriate fail-safe, backup, redundancy, and other measures to ensure its
safe use. Oracle Corporation and its affiliates disclaim any liability for any damages caused by use of this
software or hardware in dangerous applications.
This software or hardware and documentation may provide access to or information on content, products, and
services from third parties. Oracle Corporation and its affiliates are not responsible for and expressly disclaim
all warranties of any kind with respect to third-party content, products, and services. Oracle Corporation and
its affiliates will not be responsible for any loss, costs, or damages incurred due to your access to or use of
third-party content, products, or services.
PeopleSoft Test Framework 8.53 Self Study Guide

Table of Contents

PEOPLESOFT TEST FRAMEWORK 8.53 ............................................................................... 1 


UNDERSTANDING THE PTF TECHNOLOGY .................................................................. 1 
Unit Test ................................................................................................................................................. 2 
System Test........................................................................................................................................... 2 
Integration Test ................................................................................................................................... 2 
Parallel Test ........................................................................................................................................... 3 
Performance Test ................................................................................................................................ 3 
Acceptance Test ................................................................................................................................... 3 

UNDERSTANDING THE FEATURES AND BENEFITS OF PTF .................................. 3 


Test Assets Stored in the Database ............................................................................................. 3 
Enhanced Security .............................................................................................................................. 4 
Facilitate Maintenance Due to Upgrades .................................................................................... 4 
PeopleTools Metadata ........................................................................................................................ 5 
Record and Playback .......................................................................................................................... 5 
Interface with Other PeopleTools .................................................................................................. 6 

INSTALLING AND CONFIGURING PTF .......................................................................... 6 


Understanding the PTF Development Environment ................................................................ 7 
Configuring the PTF Environment ................................................................................................. 7 
Verifying Integration Broker Setup ............................................................................................... 8 
Setting Up Security ........................................................................................................................... 10 
Defining Configuration Options .................................................................................................... 12 
Configuring an Application for Testing ...................................................................................... 12 
Creating a Connection to the PTF Environment ..................................................................... 13 
Configuring Execution Options ..................................................................................................... 14 
Configuring Local Options .............................................................................................................. 16 

CREATING TESTS AND TEST CASES ............................................................................. 18 


Recording a Test ................................................................................................................................ 18 
Using the Log Viewer ....................................................................................................................... 20 
Understanding Test Cleanup ......................................................................................................... 22 
Creating Test Cases .......................................................................................................................... 23 

DEVELOPING TESTS ........................................................................................................... 24 
Understanding the PTF Test Structure ...................................................................................... 24 
Understanding the PTF Test Language ...................................................................................... 26 
Working with Get_Property Action and the Message Tool ................................................. 27 
The Log Type and the #LIST# Reserved Word ...................................................................... 30 

OPTIMIZING TESTS ............................................................................................................ 31 
Understanding Calling and Creating Tests ............................................................................... 31 
Library Tests ....................................................................................................................................... 32 
Shell Tests ............................................................................................................................................ 33 
Using Conditional Logic ................................................................................................................... 34 
Adding Page Prompting to a Test ................................................................................................ 35 

INCORPORATING SCROLL HANDLING ....................................................................... 36 


Understanding Scroll Handling ..................................................................................................... 36 
Incorporating Scroll Handling Into a Test ................................................................................ 37 

Page ii
PeopleSoft Test Framework 8.53 Self Study Guide

IDENTIFYING CHANGE IMPACTS ................................................................................. 42 


Understanding Change Impacts ................................................................................................... 42 
Running a Test Maintenance Report ........................................................................................... 44 
Understanding How to Interpret Test Maintenance Reports ............................................. 49 
Running a Test Coverage Report ................................................................................................. 51 
Performing Test Maintenance ....................................................................................................... 54 

Page iii
PeopleSoft Test Framework 8.53 Self Study Guide

PEOPLESOFT TEST FRAMEWORK 8.53


PeopleSoft Test Framework (PTF) enables you to automate functional
testing of PeopleSoft applications.

PTF works by replicating the actions of a single user executing functional


tests against the PeopleSoft browser-based application. You can record
manual test procedures and save them within the framework. Later
(perhaps after an application upgrade or patch), you can execute those
tests against the application to verify whether the application still behaves
as expected.

The document describes PTF technology and its features and benefits. It
also describes the following processes:
 Installing and configuring PTF.
 Creating tests and test cases.
 Developing tests.
 Optimizing tests.
 Incorporating scroll handling.
 Identifying change impacts.

Understanding the PTF Technology


Often, test requirements go beyond simply recording and playback of an
application. PTF enables you to build complex tests step by step using the
PTF test development platform.
The PTF test development platform integrates PTF Explorer, which
organizes test assets, the PTF Test Recorder, the PTF Test Editor, which is
an intuitive graphic user interface, debugging tools, and the PTF Log
Viewer.

PTF automates various tasks within a PeopleSoft application, primarily


functional testing. Automating functional testing enables testers to
execute more tests with greater accuracy during a shorter time.

You can use PTF with most types of tests. A testing strategy provides the
basis for understanding how you will test the upgrade application. Your
organization may or may not require all of the testing stages listed for
your upgrade; that is determined by your testing strategy.

You can take more than one approach and method for testing your
upgrade. There are no standardized rules existing for testing. Several
types of testing can be used to determine whether an application is
functioning correctly after the upgrade. Testing types do not necessarily
run systematically, one after another; different test conditions can
sometimes run in parallel.

Page 1
PeopleSoft Test Framework 8.53 Self Study Guide

The terminology for types of testing can vary between different people
and organizations. Therefore, within your organization, especially within
the upgrade project team, everyone needs to understand the terms and
definitions of the testing that you will be performing.

Unit Test

 Tests individual online transactions and batch processes on an


upgraded database.
 Validates data that was converted during an upgrade.
 Verifies that you can access existing data and enter new data
successfully.
 Tests customizations that were reapplied to an upgraded database.
 Tests each customization individually along with all related
processes.
 Does not test business processes.
Note: Online transactions are handled by core PTF record and playback
functionality, while batch processes can be automated with the
Process.Run action.

System Test

 Tests all processes from beginning to end.


 Includes business processes that cross PeopleSoft applications and
those that interact with third-party systems.
 Is performed by technical and functional resources after unit testing
is complete.
 Compares expected results with actual results.
 Is performed on both current and upgraded databases.
 Resolves discrepancies before moving into user testing.
Note: PTF is used to verify end-to-end processes, using the flexibility of
shell tests and test cases. It cannot be used to test third-party products.

Integration Test

 Determines whether the system works both functionally and


technically.
 Ensures that bugs and design flaws are resolved before user
testing.
 Verifies that users can successfully run business processes.
 Tests all business processes, including online and batch.
 Determines whether processes can be completed in the time
allowed.
 Is performed by technical resources after completion of unit testing.
PTF is very useful for integration testing.

Page 2
PeopleSoft Test Framework 8.53 Self Study Guide

Parallel Test

 Tests specific business processes.


 Is performed by technical and functional resources.
 Is performed on both current and upgraded databases.

Performance Test (limited use)

 May be performed as part of system, integration, and user testing.


 Measures differences between current and upgraded system
performance.
 Tests performance both online and in batch.
 Is performed by technical and functional resources.
PTF replicates the behavior of a single user interacting with a PeopleSoft
application, so it has limited use in performance testing.

Acceptance Test

 Validates data, business rules, and business process requirements.


 Defines acceptance criteria for an upgrade.
 Performs full end-to-end testing.
 Is performed by functional resources following system or
integration testing.
 Is not performed with developer or super user access.
 Uses PTF tests based on business processes, performance, and
production security.

Regression Test

 Ensures that no new defects were introduced during a move.


 Runs a predefined set of scripts to confirm the test move.
 Is performed by functional resources before Go Live.
 Reruns PTF tests from previous testing.

Understanding the Features and Benefits of PTF


PTF enables you to build complex tests step by step using the PTF test
platform framework. The section describes the features and benefits of
PTF.

Test Assets Stored in the Database

Page 3
PeopleSoft Test Framework 8.53 Self Study Guide

Test assets stored in the database

The test assets are stored in the database and they are readily accessible
to anyone with authorized access, which facilitates collaboration.

Also, tests and test cases (test data) are PeopleTools managed objects, so
they can be included in upgrade projects along with other managed
objects and moved to a new database as part of the upgrade process.

Enhanced Security

Test data is stored in the database, so it has the same level of security as
application data. Data can be accessed and updated only through
PeopleSoft Pure Internet Architecture and web services.

In addition, the PTF client, which is the program that you use to create
and execute tests, is secured by PeopleSoft user IDs and roles.

As another security feature, a password that is recorded as part of a test


is encrypted.

Facilitate Maintenance Due to Upgrades

Maintenance Report to show the changes in the upgrade that effect the tests

Page 4
PeopleSoft Test Framework 8.53 Self Study Guide

Many PeopleSoft customers report that the single largest cost of


upgrading is testing. The PTF test maintenance process drastically reduces
the expense and risk in testing upgrades by providing reports that tell you
what changes in the upgrade affect which tests in your test library.
Because PTF tests are PeopleTools managed objects, PTF is able to
validate recorded objects against PeopleSoft object metadata definitions.
As a result, you are able to assertively verify the existence of test objects
before running a test rather than running the test to identify invalid object
definitions by trial and error.

PeopleTools Metadata

Recognizing metadata of an object definition

PeopleTools metadata relates to the object definitions (records, fields,


pages, and components) that are used to develop PeopleSoft applications.
When PTF records a test, it recognizes the metadata and uses, for
instance, the actual name of a field rather than the position of that field
on a page. As a result, if the field is moved in a subsequent revision, PTF
is still able to locate it when the test is executed.

Record and Playback

Page 5
PeopleSoft Test Framework 8.53 Self Study Guide

Record and playback approach to automation

PTF works by replicating the actions of a single user executing functional


tests against the PeopleSoft browser-based application. Users can record
manual test procedures and save them within the framework. Later
(perhaps after an application upgrade or patch), users can execute those
tests against the application to verify whether the application still behaves
as expected.

This method for capturing and executing tests is often called the record
and playback approach to automation.

Interface with Other PeopleTools

Interface with other PeopleTools

PTF tests can run processes and reports through Process Scheduler, as
well as queries and DataMover programs.

Installing and Configuring PTF


The PTF client is a standalone program that runs on a Microsoft Windows
workstation. The PTF client connects to the PeopleSoft application
database, where test assets are stored using a secure HTTPS connection
through Integration Broker Web Services.

The following sections elaborate on:


 The PTF development environment and the environment configuration
for PTF.
 Verifying Integration Broker setup.
 Setting up security.
 Defining configuration options.
 Configuring an application for testing.

Page 6
PeopleSoft Test Framework 8.53 Self Study Guide

 Creating a connection to the PTF environment.


 Configuring the execution options.
 Configuring the local options.

Understanding the PTF Development Environment

A PTF development environment consists of the following elements:

PTF development environment

 A PTF client instance.


The PTF client is a standalone program that runs on a Microsoft
Windows workstation.
 A connection to a PeopleSoft application database where test assets
are stored.
The PTF client connects to the PeopleSoft application database, where
test assets are stored using a secure HTTPS connection through
Integration Broker Web Services. No client connectivity software is
required.
 A Microsoft Internet Explorer browser instance.
The browser connects to the PeopleSoft application using HTTP through
the PeopleSoft Pure Internet Architecture.
 A connection to a PeopleSoft application that is to be tested.
The PTF client connects to the PeopleSoft application that is to be
tested through a Microsoft Internet Explorer browser session.
 PTF test assets (tests and test cases) are stored in tables in a
PeopleSoft application database. You can use any application database
certified to run on PeopleTools 8.52 or higher as a PTF environment.

Note: The PeopleSoft application database where test assets are stored
and the PeopleSoft application that is to be tested are not required to be
on the same database, but Oracle strongly recommends that you use the
same database for both.

Configuring the PTF Environment

When configuring an environment for PTF, there are several parts you
must set or verify:

Page 7
PeopleSoft Test Framework 8.53 Self Study Guide

1. PTF communicates with the application database using Integration


Broker. To verify that Integration Broker is set up for your
application:
a. In your PeopleSoft application, access the Gateways page.
b. Verify that the gateway URL field references the correct
machine name.
c. Click the Ping Gateway button.
d. Verify that the message returns a status of ACTIVE.
2. Verify that the Gateway Default App Server URL is specified on the
PeopleSoft Node Configuration page.
3. The Default User ID field for the ANONYMOUS node must have, at
a minimum, a PTF User role.
You can verify the default user ID for the ANONYMOUS node using
the Node Definitions page.
4. If your environment is not configured to use SSL, select the Allow
Untrusted SSL check box on the Define Configuration Options
page.
5. Select the Show Connection & Sys Info and the Generate HTML
for Testing check boxes on the Debugging page of the Web
Profile Configuration component to configure the PeopleSoft
application for testing.
You must restart the web server for changes to the web profile to
take effect.

The above processes are explained in the next sections.

Verifying Integration Broker Setup

If Integration Broker is not set up correctly in your organization, you will


need to work with your Integration Broker administrator.

See the product documentation for PeopleTools: Test Framework; it has


additional details that will help your Integration Broker administrator
configure Integration Broker to communicate with PTF.

Note: As a PTF user or administrator, you are not expected to set up and
configure Integration Broker. The information provided in these topics
regarding Integration Broker is presented only for the purpose of
identifying potential problems. If there is any problem with Integration
Broker, you should contact your Integration Broker administrator.

To verify that Integration Broker has been set up correctly to


communicate with PTF:
1. Click PeopleTools, Integration Broker, Configuration,
Gateways.
2. Click Search to search for integration gateways.
3. Use the Gateways page to specify the location of the gateway,
update configuration settings, and register target connectors to be
used with the gateway. The following example shows a Gateway
page:

Page 8
PeopleSoft Test Framework 8.53 Self Study Guide

Gateways page

4. Click the Ping Gateway button.


5. A window appears confirming that the gateway is active. Note the
Tools Version shown here; you will need to remember it later on a
subsequent page.
6. Click the Close button.
7. Next, take a look at the gateway setup properties to verify that
they are configured correctly. Click the Gateway Setup
Properties link.
8. Use the Gateway Properties page to sign in to access the
gateway properties. Notice that the text above the login area
provides the default user ID.
Enter the user ID and password. Enter "administrator" for user id
and “password” for password. Click OK.
9. Use the PeopleSoft Node Configuration page to specify
information about the Application Server and nodes.
10.Verify that the App Server URL has been specified correctly.
The App Server URL should be in this format:
<machine_name>:<JOLT_port>
The JOLT port number generally corresponds to the JSL port
number as defined in the application server configuration. The
default is 9000.
11.The user ID must be one that has, as a minimum, a PTF User role.
You will learn how to assign the PTF User role to the PTFTRN user in
the "Setting Up Security" section.
12.The Tools Release value must exactly match the PeopleTools
release that appears on the confirmation page when you click the
Ping Gateways button.
You can also press CTRL+J from any application page to view the
PeopleTools release.

Page 9
PeopleSoft Test Framework 8.53 Self Study Guide

PeopleSoft Node Configuration page

Setting Up Security

Note: In the following section PTFTRN is taken as an example user ID and


Anonymous is taken as an example node.

The Default User ID for the ANONYMOUS node must have, at a minimum,
a PTF User role. Other acceptable roles are PTF Editor and PTF
Administrator.

You can verify the default user ID for the ANONYMOUS node using the
Node Definitions page.

When PTF sends service operation requests to Integration Broker, the


service operations are set up so that the requests will be assigned to a
delivered node called the ANONYMOUS node. Therefore, permissions are
applied based on the default user ID associated with the ANONYMOUS
node. The user ID must be linked to one of the PTF roles for the service
operation requests to be authorized.

In the following steps PTFTRN user is assigned the PTF User role to setup
security:
1. Click Main Menu, PeopleTools, Integration Broker,
Integration Setup, Nodes.
2. Search for the Anonymous user.
3. Click the ANONYMOUS link.
4. Use the Node Definitions page to specify information about nodes
(such as authentication and user data).
Notice that the Default User ID for the ANONYMOUS node is
PTFTRN shown in the example below.

Page 10
PeopleSoft Test Framework 8.53 Self Study Guide

Node Definitions Page

5. To ensure that the PTFTRN user has, at minimum, the PTF user
role. Click the PeopleTools, Security, User Profiles, User
Profiles.
6. Search and open the user id PTFTRN from the User Profiles search
page.
7. Use the User Profiles - Roles page to specify the user roles to
which a specified person has access. Note that the PTFTRN user
does have the PTF Administrator role, which includes the PTF User
role's privileges, so it is not necessary in this case to add the PTF
User role. You will add it to review the process for adding a role.

Roles page

Page 11
PeopleSoft Test Framework 8.53 Self Study Guide

Defining Configuration Options

If your environment is not configured to use SSL, select the Allow


Untrusted SSL check box on the Define Configuration Options page:
1. Click Main Menu, PeopleTools, Lifecycle Tools, Test
Framework, Define Configuration Options. The Define
Configuration Options page appears.

Configurations Options page

2. Use the Define Configuration Options page to specify whether


you want to allow untrusted SSL certificates. Click the Allow
Untrusted SSL option.
3. Click Save.

Configuring an Application for Testing

Select the Generate HTML for Testing and the Show Connection &
Sys Info check boxes on the Debugging page of the Web Profile
Configuration component to configure the PeopleSoft application for
testing.

Note: You must restart the web server for changes to the web profile to
take effect.

Navigate to the Web Profile Configuration component and configure


the application for testing:
1. Click Main Menu, PeopleTools, Web Profile, Web Profile
Configuration. The Web Profile Configuration search page
appears.
2. Search and open the profile name.
3. Click the Debugging tab. Use the Debugging page to specify
debugging options to use for PTF.

Page 12
PeopleSoft Test Framework 8.53 Self Study Guide

Debugging page

4. Click the Show Connection & Sys Info option.


5. Click the Generate HTML for Testing option.
6. Click the Write Dump File option.
7. Click the Save button.

Creating a Connection to the PTF Environment

Run the PTF client to create a connection to the PTF environment. Click
the New button if you are creating a new connection. The following
example shows the login screen for a new connection in PTF:

Page 13
PeopleSoft Test Framework 8.53 Self Study Guide

PeopleSoft Test Framework –Signon page

Enter the following:


Database Enter the database name.
Name
Server Port Use the Server:Port field to enter the server
name for the environment. The format for the
server name is:
<machine_name>:<https_port>
If the https port is the default, 443, then the
port number is optional. You can also enter a
complete https URL in this format:
https://<machine_name>:<https_port>/
PSIGW/HttpListeningConnector
Node ID The Node ID field is required if more than one
database is connected to the server. Since that
is not the case in our example, leave it blank.
User Enter the user ID, and password. The User ID
ID/Password is a valid user name for the PeopleSoft
application that contains the environment. The
user must have one of the following PTF user
roles: PTF Administrator, PTF Editor, or PTF
User.

Click the OK button. The PeopleSoft Test Framework window appears,


showing the database you specified.

Configuring Execution Options

Execution options are stored as part of the metadata for a PTF


environment and are available to all users of that environment. Only a PTF

Page 14
PeopleSoft Test Framework 8.53 Self Study Guide

administrator (a user with the PTF Administrator role) is able to insert,


delete, or modify execution options.

Because test assets are PeopleTools managed objects, Oracle strongly


recommends that you run tests only against the database on which they
are stored. As part of the PTF maintenance process, PTF synchronizes test
definitions with application metadata definitions. If you run tests against a
different application database, you may encounter problems when an
application is customized or upgraded. A PTF administrator can limit
execution options to environments running against the same database
where test assets are stored.

From the PTF window (the PTF window is labeled with the name of the
current PTF environment), you can access the Execution Options dialog
box where you can configure settings for the PeopleSoft applications that
you test with PTF.

You can also access the Execution Options dialog box by clicking the
execution option link in the lower right corner of the PTF application
window. The execution option link is labeled with the name of the default
execution option.
When you click the Accept button in the Execution Options dialog box,
PTF stores the name of the selected execution option and uses it, by
default, in subsequent test recordings and executions. To configure the
execution options:
1. Click @PTF Course DB, Execution Options. The Execution
Options dialog box appears to configure the options you use with
PTF.

Execution Options dialog box

Page 15
PeopleSoft Test Framework 8.53 Self Study Guide

2. Click the Insert button.


3. Enter the configuration details:
Name You can use any name for the database. It should
be descriptive.
URL Enter the URL for the application to be tested. You
can copy and paste the URL from your login page.
User ID The user must be a valid user with one of the PTF
roles assigned.
Password Enter required information.
Process Enter required information.
Server
Date Format Enter required information.
Log Folder If a log folder does not exist, it will be created with
the name you specify.

Verbose Verbose logging records a detail line in the log for


each step executed in the test.
Non-verbose logging records only the test rollup
status (Pass or Fail).

4. You can select Yes in the Skip PageSave drop-down list to


prevent a test from executing a save. You would, for instance,
select this option to avoid creating duplicate values if you plan to
run a test repeatedly.
5. You can select Yes in the Skip RunRequest drop-down list to
prevent the test from executing process requests.
6. Save the execution options.
7. Click the Accept button to complete configuring execution options.

Configuring Local Options

Local options settings are used when PTF runs processes or executes
queries.
You use the Local Options window to configure timeouts for processes
launched from a PTF test. The following example shows the Local
Options… dialog box:

Page 16
PeopleSoft Test Framework 8.53 Self Study Guide

Local Options dialog box

Local options are specific to the machine on which the PTF client is
installed. The local options settings are stored in the localoptions.xml
file in the PTF data directory (C:\Documents and
Settings\<User>\Application Data\PeopleSoft\PeopleSoft Test Framework
by default).

To configure local options:


1. Click @PTF Course DB, Local Options… Local Options dialog box
appears.
2. Configure the following and click OK:
Queued timeout The maximum time allowed for a process to be
queued before PTF logs a warning or a fail
message.
Posting timeout The maximum time allowed for a process to post
before PTF logs a warning or a fail message.
Processing timeout The maximum time allowed for a process to
complete before PTF logs a warning or a fail
message.
Queued: Log Specifies whether a timeout causes PTF to log a
Result warning (the LogWarning option) or a fail
message (the LogFail option).
If LogFail is selected and Stop on Error is set in
the Debug menu, then execution will stop if a
timeout occurs.

Page 17
PeopleSoft Test Framework 8.53 Self Study Guide

Posting: Log Result Specifies whether a timeout causes PTF to log a


warning or a fail message. If LogFail is selected
and Stop on Error is set in the Debug menu,
then execution will stop if a timeout occurs.
Output Folder Specifies where the generated log files are stored.
A default location is defined when PTF is installed,
but you can change it.
Output Format Specifies the format in which the log files are
generated. The available choices in the drop down
list are XLS, CSV, and XML.
Grid: Show Field Enables you to specify how field labels appear in
Label the test window.
 Tooltip-Shows field labels as tooltips (hover
text). It is the default option.
 Column-Shows field labels in a column.

Auto-Check Syntax Set to Yes to be prompted to check syntax every


time you save a test.
File.Download: If set to Yes, PTF prompts for the file path when
prompt for path file download steps are encountered.

Creating Tests and Test Cases


PTF includes several components that you use to organize, record, and
maintain tests and test cases.

The following sections elaborate on:


 Recording a test.
 Using the log viewer.
 Describing test cleanup.
 Creating test cases.

Recording a Test

To record a test, you perform the following steps:


1. Open a test.
 If you are recording within an existing test, highlight a test step.
The system inserts the new steps in the new recording following
the highlighted step.
 If you are recording a new test, then click Create, Folder to
create a new folder to save your test. Then create a new test
and save.
Note: Test names and test case names can consist of letters,
numbers, and underscores, but they must begin with a letter.
PTF converts test names and test case names to uppercase. Two
tests in the same database instance must not have the same
name, even if they reside in different folders.
Note: Recording begins at Step 2. Step 1 is always
Browser.Start or Browser.Start_Login.
2. Launch the Test Recorder.

Page 18
PeopleSoft Test Framework 8.53 Self Study Guide

a. Select Test, Open Test Recorder with a test open.


b. Click the Show Test Recorder button in the toolbar.
Note: You can reposition the Test Recorder toolbar to best
view the application during recording.

New test recording


c. Hook a browser.
3. Click the Start Web Client button on the recorder toolbar.
4. Select a browser window with the test application open and hooking
the application by dragging the Select Browser icon to the
browser window.
5. Start recording.
6. Perform the test steps in the PeopleSoft application.
You can drag and drop the Verify button (the button with the green
check over the text "Ver") from the Test Recorder toolbar to the
Customer description field in the application, to insert a step with a
Verify action into your test. The step is automatically populated
with the object ID and value of the field.
7. Stop recording. Close the Test Recorder. The test appears. The test
steps reflect every action you took while recording the test: entered
text, mouse clicks, and so forth.

Completed test recording


8. Save the test.
9. Run the test. The test log is displayed. Examine it, noting that the
information you entered appears in the log steps.

Page 19
PeopleSoft Test Framework 8.53 Self Study Guide

Best Practices
The following best practices are recommended when recording tests:
 Record first, and record whenever possible to drive as much
information as possible, including PeopleTools metadata, into the
recorded test. If you need to add a new step to a test, select the
spot in the test where the new step will occur and record the step
at the insertion point.
 Assertively record every test step from the test. Even if input fields
are already set to the expected value, you must explicitly enter or
set that value when recording. The recorder only captures actions
that you take against objects during record time. If you skip an
object during recording because it is already set to the desired
value, then the test will ignore it and fail if the default value of the
same object is different during execution.
 You may need to repeat some actions to record the desired step.
For instance, if the test instructions say to select a check box but
the check box is already selected, you will need to deselect it first
and then reselect it. After recording is complete, delete the extra
step in your test.
 When you record a date field that includes a calendar object, which
enables the user to select a date, you must explicitly enter the date
value in the edit box. Do not use the calendar to select a date.
 In this topic, you will record a simple test, deliberately including
some errors that you will clean up in a subsequent topic.

Using the Log Viewer

Whenever you run a test, PTF creates an execution log entry. The log is
located in PTF Explorer under the test name, in the log folder specified in
Execution Options dialog box.

After you run a test, PTF automatically displays the log in the Log
Viewer. You can also view a log by opening it from PTF Explorer.

Typically, the Log Viewer includes one high-level entry for each step in the
test. Entries for complex steps appear in collapsible sections that you can
expand to view additional details.

An icon or shaded label appears next to each log entry, indicating the
success state of the associated step.

You can change the appearance of the icons by selecting Log, Change
Log View.

To open the Log Viewer:


1. Navigate to the test of which you want to view log.

Page 20
PeopleSoft Test Framework 8.53 Self Study Guide

2. Click the Logs tree icon .

Logs tree

The table describes the icons you see under Logs:


A green flag icon indicates that the test executed
successfully.
A red exclamation point icon indicates that the test
encountered a condition that it was not configured
to handle, or the test encountered an error while
PTF was configured to stop on all errors.
A red flag indicates that one or more steps in the
test failed to execute properly.
3. Right click an item and select Open to open the log file of that item.
The log file opens.
The Log Viewer window is used to view your test logs and other
information about your tests.

Page 21
PeopleSoft Test Framework 8.53 Self Study Guide

Left Pane

Right Pane

Bottom Pane

Logs Viewer window


Left Pane Displays the log details, such as mouse
clicks, actions taken, and so forth.
Right Pane Displays the execution options that were
used for the test.
Bottom Pane Displays information about the selected entry
in the log.

In the Log Viewer:


1. Right click a tree item and select Go to Test Step to use the PTF Test
Editor to view and edit the steps in your test.
The test steps are displayed with the selected step highlighted. If you
need to make changes to the test step, you can do it on this page.
2. Go to Log, Change Log View to change the error flag icons into color
coded text bars.
3. Go to Log, Highlight Errors to highlight the error text.
4. Click the screenshot icon to view image of the application screen at
that point in the test execution.

Understanding Test Cleanup

When you create or open a test, test case, or shell test, it opens in the
Test Editor.

The Test Editor enables you to:


 Record and edit test steps.
 Add, copy, and delete test steps.
To remove an unneeded step, you highlight its row and delete it.

Page 22
PeopleSoft Test Framework 8.53 Self Study Guide

 Create and edit test cases.

o Sometimes you enter incorrect values while recording a test.


This is easy to fix in the Test Editor, simply select the
incorrect text and replace it.
o You can also modify test steps. For example, a common
modification is to replace the Browser.Start line and the
related lines that follow it with a Browser.Start_Login
action.
The Start_Login action opens the browser instance where
the test will be executed and logs into the PeopleSoft
application using the URL, user ID, and password from the
selected execution option.
Coding user-specific information into many tests may make
future updates difficult if user IDs in the test environment
change.
To make a recorded test easier to maintain, change
Browser.Start to Browser.Start_Login and delete the
extra steps that were recorded logging in.
o As you modify your recorded tests, you will often need to
manually add steps that cannot be recorded. To add a step
manually, click the Insert Step button or right-click and
select Insert Step.
A blank row is inserted. To enter information, simply select it
from the drop-down lists or type or copy it into the text
fields.
 View both test and test data, or test case, in a single view.
 Debug tests.

Creating Test Cases

Often, you will want to run the same test multiple times using different
values in the Value column. Test cases enable you to associate different
sets of data with a test.

You can view and edit both the test and test case in a single unified
window.

You can run a test case by selecting the test case and running the test.
You can also run multiple test cases by calling them from another test or a
shell test.

The test case associated with the original test is named DEFAULT.

To create a test case:


1. Save a copy of a test in PTF Test Editor.
2. Create a new test case
a. Click the New Test Case button to create a new test case.
b. Enter different values for the test case.

Page 23
PeopleSoft Test Framework 8.53 Self Study Guide

c. Click Save and then Run to execute the test case.


The test runs and the log file is displayed.

Developing Tests
PTF uses a specific structure and test language to describe each step in a
test.

The following sections elaborate on:


 The PTF Test Structure
 The PTF Test Language
 Get_Property action and the Message Tool
 Log Type and #LIST# reserved word

Understanding the PTF Test Structure

Tests are made up of a series of steps, which execute in sequence when


you run the test. Typically, a test has a single step for each instruction in
a manual test case.

A step is made up of a set of eight fields. The PTF test language focuses
primarily on the following four fields (the exception is the Scroll action,
which also uses Scroll ID):
Type: The type of object being acted upon or the type of action to be
taken.
Action: The action to be taken in relation to the selected Type.
Recognition: Use this field primarily to identify the target object in an
application. Some actions use this field for other purposes as well.
Value: Use this field primarily to supply the value that is being set or
verified in the target application. Some actions use this field for other
purposes as well.

When you record a test, PTF automatically inserts a step for every action
you take and populates the Type, Action, Recognition, and Value
fields. An example of a test case is shown below:

Page 24
PeopleSoft Test Framework 8.53 Self Study Guide

Test case-TRN_09_TEST_DEV_VERIFY

Type and Action


The Type and Action fields are closely tied in the PTF test language.
When you create or modify a test, you can select the Type for the step
from a drop-down list, which relieves you of remembering or looking up
the names and correct spelling for the types. The Type field displays the
type of object to be acted upon:
 Browser: Interact with the browser in some way (typically logging
in or setting a frameset).
 Link: Interact with a hyperlink, usually by clicking it.
 Button: Click on the specified button.
 Text: Set the value in the field to the specified text.
 Span: Fields that are set to display only in Application Designer.

Each type has a set of actions that is associated with it. The Action drop-
down list lists the actions available for a selected type. Examples of an
action include clicking a button or link, setting a particular value in a field,
selecting a check box or combo box, or logging in.

As you develop tests you may need to modify the recorded steps or create
new steps. For example, you can change the Start action to Start_Login
for the Browser type. In some cases, you will need to manually insert
types that cannot be recorded or that are more convenient to insert
manually.

Recognition
The Recognition field is used primarily to identify the specific target object
to be acted upon.
In the example displayed above, the TRN_09_TEST_DEV_VERIFY test,
several objects are included with the Name=<value> format, such as

Page 25
PeopleSoft Test Framework 8.53 Self Study Guide

Name=PSU_STUDENT_TBL_CUSTOMER_ID to identify the database


field containing the company with which the student is associated.

Value Field
The Value field contains the value to which the specified object is to be set
in the test. When you record the test, PTF identifies the correct format for
the value and includes it in this field; for example, the label on a radio
button option might be Technical but the actual value in the database is T.

You can change a value by selecting it and typing a new value in the field,
but it is generally best practice to re-record whenever possible to ensure
that PTF is picking up the correct values.

Actions that set or verify a value in the application, such as Set_Value or


Verify, will typically be skipped if the Value field is left blank.

Scroll ID
The Scroll ID field is only used for a particular type of action called a Scroll
action.

Seq
The Seq (Sequence) is the order in which the steps occur in the test. This
sequence number can change; for example, if at some future time you
add a step between steps 1 and 2, the new step is given the Seq number
2 and the remaining steps are renumbered accordingly.

The ID is the unique identifier for the row. This number never changes,
even if this or other rows are moved or deleted. Though the numbers in
this example are sequential, they can appear out of order if steps are
added or deleted after the test was initially recorded.

Understanding the PTF Test Language

Some of the important components of the PTF test language include:


 Parameters.
 Variables.
 Reserved words.

Typically, you place parameters in the Recognition field using the


following structure:
param=value
The system ignores unneeded parameters. For example, Browser.Start
and Browser.Start_Login do not require any parameters, so the system
ignores any values in the Recognition field for these actions.
Variables enable you to work with steps in which the information or values
are not known when you create the test, or the information or values for a
step change each time the test executes.

Page 26
PeopleSoft Test Framework 8.53 Self Study Guide

You prefix variables with an ampersand (&).

Store a value for a variable either by placing the ret=&varname


parameter in the Recognition field in a step that supports return values or
by using a Variable.Set_Value step.

You use reserved words to supply information that is not known until a
test executes. Prefix reserved words with a pound sign (#) and use them
in the Value field of a test to verify a condition, change the value in an
application field, or both.
For example, the #TODAY reserved word sets the Start Date field to the
current date and the expression #TODAY+5 sets the End Date field to
five days from today.

For a complete list, refer to the "Test Language Reference" topic in the
PeopleSoft Test Framework Online Help.

Working with Get_Property Action and the Message Tool

To copy an existing test:


1. Open a test case. When you copy an existing test, verify that the
user name and password to log in to PIA are set correctly. These
values enable the test to log in properly when you run it.
2. Select @PTF Course DB, Execution Options… to view and edit
setup information for your PTF database.
3. Delete and record new steps.

To use the Get_Property Action:


1. Open a test in PTF where you will like to add the Get_Property
action. For this example, the TRN_09_TEST_DEV test is opened.
2. Click Seq* where new steps are to be added.
3. Click Show Test Recorder.
4. Click Start Web Client on the recorder.
5. Navigate to the location from where you want to start the recording
and click the Start Recording button.
6. Drag the Verify button in the recorder to a field. In this example
we want to use Get_Property on the Student ID field.

Page 27
PeopleSoft Test Framework 8.53 Self Study Guide

Student ID field where the Verify button is dragged

7. Click Stop Recording button and close the recorder.

A new line is added to the test. Because you want to use this line to get a
value rather than verify one, you need to make a change to the Action
field.
1. Click the Action cell.
2. Click the Get_Property list item.
To use Get_Property, you need to know:
a. The type of the object.
b. The identifier of the object (Name, Comment, ID, and so on).
c. The name of the object.
d. The property you want to return.
The following example shows by recording a Verify step, the
requirements got captured:
a. The type of the object: Span
b. The identifier of the object: ID
c. The name of the object:
PSU_STUDENT_TBL_STUDENT_ID

Page 28
PeopleSoft Test Framework 8.53 Self Study Guide

Get_Property action

Only the property you want to return is required for which you use the
Message tool.
1. Select Tools, Message. The Message tool appears. The Message
tool shows details about an object in the application, including
name, object type, and value. The following example shows the
Message tool.

Message Tool

2. Navigate to the location in the browser where the action is required.


In the example, it is the Education and Skills page of Student ID
2001.
3. Select Menu in the Message tool, HTML Browser, Show. The
Object Properties window appears.
This window displays properties and values of HTML objects as you
hover over them using the Object Properties icon. Alternatively,
you can drag and drop the Object Properties icon onto an object.

Page 29
PeopleSoft Test Framework 8.53 Self Study Guide

Object Properties window

Note: You can double-click a line in the HTML Browser Object


Properties window to copy the text to the clipboard.

From the HTML Browser Object Properties window, you can


learn the properties and values of an object that you need for the
Get_Property action. For example, you can see that the Object
Type is Span.
The Span object type uses the ID property to identify an only
object. The recorded step already contains the
ID=PSU_STUDENT_TBL_STUDENT_ID parameter.
The Value for the innerText property is 2001, so you know that
innerText is the property you want to return.
4. Return to the test in PTF and click the Recognition cell.
Again, the step already contains the
ID=PSU_STUDENT_TBL_STUDENT_ID parameter.
You need to add the prop=innerText parameter to specify the
property you want returned, and you need to add the
ret=&StudID parameter to specify the variable that will store the
returned value.
5. Delete the value in the Value field because your original line was a
Verify action and you have changed it to a Get_Property action,
you no longer need a value in the Value field.
6. Save the test.

The Log Type and the #LIST# Reserved Word

Log actions create entries in the execution log. They are useful for
debugging as well as documenting test results.
The Log.Message action writes the text in the Recognition field to the
execution log with a status of Info, replacing the variable with the value
in the variable.
To include a message in the log file:

Page 30
PeopleSoft Test Framework 8.53 Self Study Guide

1. Open a test and insert a new step above a row. Right click the
Seq*. Click the Insert Step, Insert Step Above. A new row is
inserted.
2. Click Type.
3. Select Log from the drop down list.
4. Click Action.
5. Select Message from the drop down list.
6. Click Recognition cell.
7. Enter the message.
8. Save and run the test.
9. The message is displayed in the log file.

To use the #LIST# reserved word to set the value in a list of values, and
verify that the correct value has been set:
1. Select ComboBox from Type drop down list.
2. Select Set_Value from Action drop down list.
3. Enter value in Recognition cell.
4. Use the #LIST# reserved word in the Value field to verify the
values in the Project Role list, and identify the one to which you
want to set it.

The #LIST# reserved word:


 Checks the values of a combo box. It works with either the full text
entries in the combo box, or the metadata translation (XLAT)
values of the entries.
 Checks one or more values and then set an item in a drop-down list
box, list the items separated by a vertical pipe (|) and place
brackets ([]) around the item that you want to select.
 Expects the value in the field to equal the value in brackets. If it
does not find that value, it logs an error and sets the field to that
value.

Optimizing Tests
PTF includes several features that enable you to create tests that are
efficient and reusable.

The following sections elaborate on:


 Calling tests.
 Creating a library test.
 Creating a shell test.
 Using conditional logic.
 Adding page prompting to a test.

Understanding Calling and Creating Tests

If a test uses a sequence of steps repeatedly, you may prefer to isolate


the repetitive sequence of steps and move them to another, smaller test.

Page 31
PeopleSoft Test Framework 8.53 Self Study Guide

Doing so enables you to call the steps repeatedly and also make them
available to other tests that use the same sequence of steps.

Moving shared test steps to a distinct test (a called, or child, test)


provides these benefits:
 Reduces the amount of recording or development you need to do.
 Reduces the amount of debugging you need to do.
 Reduces the effects of development changes that require manual
updates to existing tests.

You can use the Test.Exec action to call any other test, but you may be
able to manage and identify the relationships between calling and called
tests more easily in the PeopleSoft Test Framework (PTF) Explorer tree if
you use library tests and shell tests.

Library Tests

A library test cannot be executed by itself; it must be called by another


test.
To create the content for a library test, you can either:
 Identify the repetitive steps from another test, copy them, paste
them into a new test, and save the new test as a library test. Don't
forget to save the original test after you have removed the
repetitive steps.
 Open an existing test; delete everything that is not part of the
repetitive steps, and then save the remainder as a library test.

To specify that a test is a library test from another test:


1. Copy a test and then remove all the lines but the part that contains
the information that will be saved in the library test.
2. Click the Test Properties icon.
3. Select the Library Test check box. The Test Properties window is
shown in the below example.

Page 32
PeopleSoft Test Framework 8.53 Self Study Guide

Test Properties window

4. Save the test as a Library test. Notice that the name is modified.
5. Define a test to call the library test:
a. Save another copy of the original test file.
b. Delete the lines included in the library test and save it with a
new name.
c. Add a line to the calling test that will call the library test.
For this line, the type is Test and the action is Exec. The
Recognition field should contain the name of the library test
you want to call.
6. Add few new test cases to the Test.
7. Define a shell script that will call your test cases.
Note: Remember that each test case calls the library test that you
defined. So as the current structure is defined, running the shell
script will call each of the created test cases, and each test case will
in turn call the same library test.

Shell Tests

A shell test is a type of test that you use primarily to call other tests. For
this reason, a shell test only supports these actions:
Test.Exec - calling other tests.
DataMover.Exec - calling data mover scripts.
Query.Exec - running queries.
Variable.Set_Value - manipulating variables.

Page 33
PeopleSoft Test Framework 8.53 Self Study Guide

Organizing component tests into shells enables you to identify large


business process-oriented type tests (that is, the type that cross multiple
components and online activities). The steps available in shell tests are
intentionally limited to represent high-level business process flows
through called test routines.

To create a shell test using the Test.Exec action to call some other tests:
1. Open the test that will call the library test.
2. Use the PTF Test Editor to view and edit information about your
test.
3. Edit the information and click Test Case Save As… to save few
test cases.
4. Click Create, Shell Test. The Shell: NewShellTest! window
displays.

Shell: NewShellTest! window

5. Click Test, Save As… and save the Shell test.


6. Enter the names of the test and its test cases that you want the
shell test to call and save.

Using Conditional Logic

Some test scenarios call for conditional logic—special handling based on


information gathered from the application during the test.

Conditional logic uses a Conditional.If_Then step with a


Conditional.End_If step. The If_Then step evaluates a statement. If
the statement is true, then PTF executes the subsequent steps until it
encounters the End_If step. If the statement is false, then execution
skips to the step following the End_If step.

Page 34
PeopleSoft Test Framework 8.53 Self Study Guide

The Same address as Customer check box on the Students page is


associated with a PeopleCode program that changes the student's
telephone and address information to the telephone and address
information of the customer, which is the organization for which the
student works.

This test checks whether the address is changed when the Same address
as Customer check box is selected. The PeopleCode only executes when
the value of the check box changes; therefore, if the value of the field is
already Y, then the test must select the check box to change it to N and
then select it again to change the value to Y.

Adding Page Prompting to a Test

Step-by-step navigation presents a number of problems:


 Menu navigation can change between releases or from one test
environment to another.
 You may need to add in one test case and update in another test
case.
 Step-by-step navigation requires several steps.
 PTF page prompting steps make tests repeatable and more robust
by simplifying test data and replacing it with intelligence built into
the step.

Page prompting functions replace explicit navigation in the test and take
the user directly to the component search page by URL manipulation. A
test with the navigation explicitly defined can break when the navigation
changes, even though the application is working fine. Page prompting
avoids this problem.

Using Page Prompting

 Use a Page.Prompt step to open a component based on the


MENU.COMPONENT.MARKET recognition string.
 Use CTRL+J to determine the menu name and component name.
For the purposes of these examples, market is GBL.

In the Value field, you must provide an action. Valid values are:
 Add.
 Add update.
 Add correct.
 Update.
 Update all.
 Correction.
If the component has a search page, use one or more Set_Value steps,
as needed, to specify the search key and use the Page.PromptOk step to
close the search page.

Page 35
PeopleSoft Test Framework 8.53 Self Study Guide

Incorporating Scroll Handling


PTF provides several actions to manage scroll areas and grids.

The following sections describe:


 Scroll handling.
 Incorporating scroll handling into a test.

Understanding Scroll Handling

Data in a PeopleSoft component is organized hierarchically using rowsets,


or scrolls, and rows.

You can implement a scroll as a scroll area or a grid. In scroll areas, the
fields appear on the page in a freeform manner. In scroll grids, fields
appear as columns similar to those on a spreadsheet. Individual rows of
data within a scroll or grid are uniquely identified by a set of one or more
fields, or keys.
An example of a scroll area and a scroll grid is shown below:

Scroll Grid

Scroll Area

Scroll grid and scroll area

The challenge to scroll handling is that, as they are recorded, tests


reference items in scrolls by an absolute position defined by a dollar sign
and an integer (for example, $3). Positions start at 0, so $3 would
indicate the fourth position in a scroll. This means that, in tests defined in
this manner, any changes to the location of a particular item in a scroll
would cause the test to fail.

Page 36
PeopleSoft Test Framework 8.53 Self Study Guide

For example, Student A might have four proficiencies including proficiency


X referenced at position 4 ($3), but Student B might have only three
proficiencies with X referenced at position 2 ($1). If a test initially written
for Student A were run with a test case referencing Student B, the test
would fail because it would be unable to find Proficiency X in the different
location. Further, the test would even fail for Student A if more proficiency
was subsequently added and the location of Proficiency X changed in the
list.

Incorporating Scroll Handling Into a Test

When you record a test that references a scroll, PTF generates a step
similar to the one shown in the image below:

A recorded step referencing the scroll in PTF

The step in the above example uses two elements in the Name=
parameter in the Recognition column to reference the Role Name
field:

• The name of the field (PSU_STUDENT_EXP_SKILL).


• Its row position index ($3).

A row position index is composed of a dollar sign ($) and an integer.


Position indexes start at $0, so $3 refers to the fourth row.
This test will work as recorded until the grid position of the row that
contains PT changes. For instance, if another row is inserted before PT,
then the PT row position index changes to $4, and the test fails. The
same problem occurs if the grid is sorted differently, or if a different test
case refers to a different student.

Page 37
PeopleSoft Test Framework 8.53 Self Study Guide

Using dynamic position index variable

To avoid the problem of test failure due to the inability to locate scroll
items referenced by absolute locations, you can incorporate scroll
handling into your tests by using dynamic position index variables.
Rows 11, 12, and 13 (by Seq number) in the above example show how
the previous example can be changed so that it will be able to find the
item regardless of its location. We will go over the example step by step.
To create a dynamic position index variable:
1. Create one or more Key_Set steps.
a. Create one Key_Set step for each field in a scroll key.
b. If the key consists of three fields, create three Key_Set
steps and specify key values for each of the three fields.
c. Key_Set requires two parameters in the Recognition
column: Type= and Name=.
You can get these values by recording a step with the PTF
recorder and then manually modifying the recorded step or
by copying the information from the application using the
Message tool and pasting into a step.
d. Specify the field value in the Value column.
e. You can use the PTF Recorder or Message tool to get the
field value as well.
f. The Key_Set step defines the key value, but PTF does not
take an explicit action on the page based on the key until it
executes an Action step.
In the above image, row 11 is an example of a Key_Set step. In
the example, this step locates the row where the Skill field
(PSU_STUDENT_EXP_SKILL) contains PT. Key_Set requires two
parameters in the Recognition column: Type= and Name=.

2. Create an Action step.


a. Create an Action step based on what action you want to
take on a row, such as update, insert, select, and so on.

Page 38
PeopleSoft Test Framework 8.53 Self Study Guide

For example, if you want to select a row, enter sel in the


Value field.
b. The Action step attempts to locate a row defined by
Key_Set.
If a row is found, it returns the index of the row.
c. Use the ret=parameter of the Action step to populate a
variable (referred to as an index variable) with the index
value.
Row 12, in the above image is an example of an Action step. This
step is based on what action you want to take on a row: update,
insert, select, and so on. In this example we want to select a row,
so we enter sel in the Value field.

3. Use the index variable for other steps.


a. After you have the row position stored in the index variable,
you can use that value to reference other fields in that row.
b. Now whenever the test is run, the index variable is updated
dynamically by the Key_Set and Action steps and the
positional reference is accurate.
In the above image, row 12 shows a step that uses an index
variable. The index variable is updated dynamically by the Key_Set
and Action steps and the positional reference is accurate.
4. Specify the Scroll ID.
a. Assign a scroll ID to group Scroll actions for each scroll.
b. Use a different scroll ID and index variable for each different
scroll area.
c. You can assign any integer you like as long as it is unique.
d. Scroll ID is a required field for Scroll actions.
e. If you are taking multiple actions in the same scroll, using
the same scroll ID and index variable improves performance
over using a new scroll ID.

The following steps describe how to add scroll handling to a test that
enters details on Education and Skills of a user:
Create a new test:
1. Start by changing the Browser.Start action to
Browser.Start_Login in Seq 1 Action cell. The example below
illustrates it:

2. Begin recording the steps in the test. Click the Show Test Recorder
button. The Test Recorder window opens.

Page 39
PeopleSoft Test Framework 8.53 Self Study Guide

3. The steps in the test are as follows:


a. Click Main Menu, Students, Personal Information.
b. Search Student ID 2001.
c. Click Education and Skills tab.
d. Change Mark Larsen's PeopleTools proficiency rating to
Low. Click the Row 4 Proficiency list.

4. Complete the steps and stop the recorder. Close the Test Recorder
window.
The test appears. Notice that the test specifies that the
PSU_STUDENT_EXP_PROFICIENCY value in position $3 (the
fourth item in the grid) will be set to L.

PSU_STUDENT_EXP_PROFIECIENCY set to L in position $3

5. Click Save and Run. The test runs successfully and the log file is
displayed.
6. Close the log file.
7. Save another test case with changed value for the Student ID and
proficiency level as follows:
 Student ID (Seq 7 value field): 2224
 Proficiency (Seq 11 value field): H
8. Save and Run the test case.
Notice that the test case fails in the following example:

Page 40
PeopleSoft Test Framework 8.53 Self Study Guide

Log file displaying Failure result

The failure is due to the fact that PTF could not find the object
referenced for the student with Student ID 2224.
Looking at Student ID 2224's Education and Skills page, we see
that Florence Paul has only three skills listed, and the PeopleTools
skill is listed in position $2 (that is, the third row of the grid).
Because the test explicitly refers to the value in position $3 (the
fourth row in the grid, which does not exist for Student ID 2224),
the test will fail.

To change the test and its test cases so that scroll handling is
accomplished correctly:
1. Remove the row that explicitly references a specific position.
Replace that with rows to perform scroll handling. Right-click and
Delete the Seq 11 row header.
2. Start by adding a Scroll ID to identify that all the actions are to be
performed on the same scroll item.
Click the Seq * Scroll ID cell. Enter following:
 Scroll ID: 1
 Type: Scroll
 Action: Key_Set
 Recognition: Type=Text; Name=PSU_STUDENT_EXP_SKILL
 Value: PT
3. The next row refers to the same scroll ID. The action will return the
row identified in the Key_Set action; in this example, the row
containing the value PT. Enter following:
 Scroll ID: 1
 Type: Scroll
 Action: Action
 Recognition: Ret=&SkillRow
 Value: sel

Page 41
PeopleSoft Test Framework 8.53 Self Study Guide

4. Next, add a row to set the value in the identified field.


 Type: ComboBox
 Action: Set_Value
 Recognition:
Name=PSU_STUDENT_EXP_PROFICIENCY&SkillRow
 Value: L
The below example displays the values entered:

Rows with entered values

5. Save and Run the test cases. The test cases will run successfully.

Identifying Change Impacts


In the course of customizations and upgrades, changes are made to,
among other elements, application menus, components, pages, records,
and fields. Tests that were developed prior to these changes may fail
when executed against the new application. For instance, if a field is
deleted, renamed, or moved to another page, any step that references
that field will fail.
The following sections elaborate on:
 The change impacts.
 Running a test maintenance report.
 Describing how to interpret test maintenance reports.
 Running a test coverage report.
 Performing test maintenance.

Understanding Change Impacts

When an application is upgraded, testers face two major challenges:


 Identifying which tests will fail because of changes in the target
application.
 Identifying gaps in test coverage where new functionality was
introduced.

Test developers must identify and update every step in each test that is
affected by a change.

Page 42
PeopleSoft Test Framework 8.53 Self Study Guide

One way to identify the effects on tests is to run each test against the new
application and note where the test fails. This manual process is time-
consuming, expensive, and prone to errors. It also fails to identify those
areas in the new application that are not covered by existing tests.

Because PTF test assets are PeopleTools metadata and because PTF tests
incorporate references to PeopleTools metadata—that is, menus,
components, pages, records, and fields—PTF is able to automate the
process of correlating metadata changes with existing tests.
PeopleSoft Test Framework delivers several tools that help test developers
determine the effect of changes. The tools you can use to help in
determining the effect of changes:
 Test Maintenance Report.
 Test Coverage Report.

A test maintenance report correlates PeopleTools compare report


data with PTF test metadata to identify certain changes to
components, menus, pages, records, and fields that may affect the
PTF tests.

You use the Create Test Maintenance Report wizard to go through the
steps needed to generate a Test Maintenance Report. You will learn how
to do this in the next topic.

Another tool that helps test developers to determine the effect of changes
is the Test Coverage Report.
A test coverage report correlates PeopleTools project data with PTF test
metadata to identify components, menus, pages, records, and fields that
are referenced in PTF tests.

When used in conjunction with Usage Monitor, test coverage correlations


can be extended to include information about all managed objects.

A test coverage report identifies which objects included in the change


project are referenced by which PTF test. Any object included in the
change project that is not referenced in the PTF test metadata appears in
the report identified as a coverage gap.
Note that you can query these tables using PS Query to produce your own
maintenance and coverage reports:

• PSPTTSTMAINTRPT
This PTF table contains the data that is used to create the Test
Maintenance report.

• PSPTTSTCOVRGRPT
This PTF table contains the data that is used to create the Test Coverage
report.

Page 43
PeopleSoft Test Framework 8.53 Self Study Guide

Running a Test Maintenance Report

Use the Create Test Maintenance Report wizard to run test


maintenance reports. The wizard consists of three steps:
 Manual Tasks
This page of the wizard guides you through the tasks to create a
compare report that PTF will use as a basis for the maintenance
report. The compare report generates a comparison between the
Application Designer objects before an upgrade and after an
upgrade.
 Analyze Compare Data
In this step, you specify which compare report PTF will analyze.
This analysis can be used in the next step to generate a
maintenance report.
 Generate Report
In this step, you select an analysis from which the maintenance
report will be generated. In addition, you specify the report format
and whether to run the report based on a single test or all of the
tests in the database.

The following section describes how to use Create Test Maintenance


Report wizard to create a report:
Step 1 of 4:
Click Main Menu, PeopleTools, Lifecycle Tools, Test Framework,
Create Test Maintenance Report.
The Create Test Maintenance Report wizard appears at step 1 of 4. Here
you can track the manual tasks that you must perform before you can
generate the Test Maintenance Report.

Create Test Maintenance Report page

The first step in creating a test maintenance report comprises five manual
tasks that you will complete in Application Designer to create a compare
report that PTF uses as a basis for the maintenance report.

Page 44
PeopleSoft Test Framework 8.53 Self Study Guide

Note: For the example in this topic, the tasks for Step 1 only need to be
executed once.

As you progress through the Create Test Maintenance Report wizard, it


tracks which tasks you have completed and which page you are on. When
you exit the wizard and then return to it, it sends you to the last visited
page.

This tracking is done according to user ID. This means that if two users
share the same user ID, the second user may not enter the first page
when accessing the wizard. The wizard will take the second user to where
the previous user left it.

If two different users with different user IDs work on the same project,
the wizard does not track the state for the second user. For instance, if
the first user completed the tasks for Step 1, the second user needs to
check the five tasks on Step 1 to bypass that step.
The step 1 has five tasks:
Task 1: Import only the project definition for the change project.
Open Application Designer and click Tools, Copy Project, From File…
In Copy From File: Select Project window, select PO_PROJ_UPGRADE in
Select Project From the List Below section.
The Copy From File window shows the PO_PROJ_UPGRADE project,
like in the example below. Click Deselect All.

Copy From File window

Click Copy.

Task 2: Rename the change project imported in Task 1 to create


the snapshot project.
Click File, Save Project As… In the Save Project Name As field, enter
SA_PROJ_SNAP.

Task 3: Create a snapshot of the original metadata definitions by


exporting the snapshot project created in Task 2 to file.
a. Click Tools, Copy Project, To File…

Page 45
PeopleSoft Test Framework 8.53 Self Study Guide

b. Click the Copy button on Copy To File window shown in the


example below:

Copy To File window

Task 4: Import the change project (definitions and objects).

a. Click Tools, Copy Project, From File…

b. Select PO_PROJ_UPGRADE list item.

c. Verify that File is selected in the Use Project Definition from:


field.
Click the OK button.
d. Verify that all Definition Type(s) are selected. Click Copy.

Task 5: Compare the snapshot project (from file) to the database,


and save the compare output to tables. This compares the current
(target) database with the pre-change (source) project,
SA_PROJ_SNAP.
a. Click Tools, Compare and Report, From File…
b. Select SA_PROJ_SNAP list item.
c. Click Yes to replace the SA_PROJ_SNAP created in Task 2.
Compare and Report From File dialog box opens.
d. Click Options to set the report options. The Upgrade Options
dialog box opens.
e. Click Report Options tab. The following example shows the
dialog box.

Page 46
PeopleSoft Test Framework 8.53 Self Study Guide

Upgrade Options: Report Options tab

f. Click the Generate Output to Tables check box.


g. Click Report Filter tab.
h. Click Select All to select all check boxes in the grid.
i. Click OK to return to the Compare and Report From File
dialog box.
j. Click Compare button. The comparison is run and several
intermediate result windows are displayed. The following
example illustrates:

Compare result windows

Page 47
PeopleSoft Test Framework 8.53 Self Study Guide

Step 2 of 4:
To generate the Test Maintenance Report, open the PIA:
1. Click Main Menu, PeopleTools, Lifecycle Tools, Test
Framework, Create Test Maintenance Report.
2. Select all the check boxes in Step 1 of 4.
3. Click Next to open step 2 of 4 where you select a report to
analyze.
4. A project name can appear more than once in the list because
the Compare Output to Table feature stores data by both
project name and compare date and time. The most recent
compare will appear first in the list.

Create Test Maintenance Report: Step 2 of 4

5. Select a Compare Report. Click the Compare Type drop down


list and select From File list item.
6. Click the Analyze button. The analysis is performed and PTF
displays a dialog box when it is finished. Click the OK button.

Step 3 of 4:
Use the Create Test Maintenance Report - Step 3 of 4 page to select an
analyzed project for generating your report. Sets of compare data are
listed by project name, the date and time the compare was generated,
and the date and time the analysis was run. The following example shows
step 3 of 4.

Create Test Maintenance Report: Step 3 of 4

In this example, select SA_PROJ_SNAP. Click Next button.

Step 4 of 4:

Page 48
PeopleSoft Test Framework 8.53 Self Study Guide

Use the Create Test Maintenance Report - Step 4 of 4 page to specify which
PTF tests to include in the maintenance report, and the report format (PIA or
BI Publisher). Then generate the report. The following example displays step
4 of 4.

Create Test Maintenance Report: Step 4 of 4

1. Click Select All at the bottom of the page.


2. Click Generate Report. PTF generates the report and displays it in
the window. This example shows how the report appears if you
select the BI Publisher format option.

Test Maintenance Report

Understanding How to Interpret Test Maintenance Reports

Test Maintenance Report comprises of many columns explained


below. The following example shows a Test Maintenance Report for the
project SA_PROJ_SNAP. The contents are marked and elaborated below:

Page 49
PeopleSoft Test Framework 8.53 Self Study Guide

Test Maintenance Report in XML format

1. The Test Name field displays the name of the test that is
affected by a change. A test maintenance report is sorted by
test name. Within each test name grouping, the report items are
sorted by priority according to the values specified on the
Define Analysis Rules page.
2. This column shows the category to which the change belongs, in
this case Medium. The information is gathered from the Define
Analysis Rules page.
3. This column lists the type of definition that was changed.
Definitions include:
 Menu.
 Component.
 Page.
 Record.
 Field.
4. The Step ID is a unique and unchanging identifier for a step in a
test. Each step has a Step ID and a Sequence Number, but
the Sequence Number, unlike the Step ID, changes when test
steps are added or deleted.
5. The Seq. Nbr (Sequence Number) of a test step reflects the
relative run order position of the step within the test.
6. Status indicates whether, within the test, the step is active or
inactive.
7. Indicates whether the object was:
a. Changed.
b. Added.
c. Deleted.
8. Pre Object Value and Post Object Value indicate what the
value was before and after the change was made.

Page 50
PeopleSoft Test Framework 8.53 Self Study Guide

The above example is the XML report, the same in the browser will have
same fields but arrangement may differ. Following example shows the
same Test Maintenance Report in the PIA.

Test Maintenance Report in PIA

Notice also that the Market field appears in the PIA report, but not in the
XML report. This is because, for this particular report, the column does not
contain a value. The Market field, when present (for components) includes
the market (for instance, GBL). To the extreme right an additional column
for Description is also present.

Running a Test Coverage Report

A test coverage report identifies which objects included in the change


project are referenced by which PTF test. Any object included in the
Change Project that is not referenced in the PTF test metadata will appear
in this report identified as a coverage gap.
To run a test coverage report:
1. Click Main Menu, PeopleTools, Lifecycle Tools, Test
Framework, Create Test Coverage Report.
2. The Create Test Coverage Report page as shown in the example
below appears:

Page 51
PeopleSoft Test Framework 8.53 Self Study Guide

Create Test Coverage Report: Step 1 of 2

You use the Create Test Coverage Report page to select a project for
which to generate a report and specify report options.
PTF generates a coverage report based on a change project. All the
projects in the database are listed, sorted with most recent first. You can
click the column headings to change the sort order.
In this example, you select the project that you want to use to generate
the report.

1. Click the PO_PROJ_UPGRADE option.


2. Click Next. The example below shows the displayed page:

Page 52
PeopleSoft Test Framework 8.53 Self Study Guide

Create Test Coverage Report: Step 2 of 2

3. Specify one or more tests to include in the report. In this example


we will choose all of them. Click the Select All button.
4. Select to generate your report in PIA to view it in the application
browser, or BI Publisher format to create an XML formatted text file
in Report Format group box.
5. Select Usage Monitor RPT to include usage monitor data in a test
coverage report. You need to generate usage monitor data while
creating your tests.
6. Click the Generate Report button.
Following report is generated. The column heads are explained
below:

Page 53
PeopleSoft Test Framework 8.53 Self Study Guide

Report

Test Name Shows which existing tests reference the definitions


in the project and which definitions have no test
coverage.
Object Type Shows the type of definition that was in the change
project.
Object Name Shows the primary key of the object.
Object Detail Shows additional keys (as applicable) required to
uniquely identify the object.
Test Metadata Shows Active or Inactive, value, if the object is
referenced in a PTF test. It reflects whether within
the test, the referenced step is active or inactive.
If the object is not referenced in a PTF test, this
value is No Data.
Usage Monitor Shows the status of the Include Usage Monitor
Data Data. When the Include Usage Monitor Data
check box is selected, this value is Yes or No.
When the Include Usage Monitor Data check
box is deselected, the value is set to No Data.

Performing Test Maintenance

After you run the Test Coverage Report to determine which areas are not
included in test coverage, you can edit your tests to make sure that these
areas are covered.
The Test Coverage Report that is generated in the above section has
several items listed as having no test coverage. The first of these is the

Page 54
PeopleSoft Test Framework 8.53 Self Study Guide

ADDRESS2 field. The example below displays the report.

You can edit the PO_VENDORS test to supply a value for one of the fields
on the Vendors page that was left out of the initial test. You will do this
by recording a new step using the Test Recorder.

To add a value to the ADDRESS2 field and update the test:


In the PeopleSoft Test Framework, open the test in the PTF Test Editor.
Go to the sequence number after which the action is missing. In this case
Seq no. 13. Click the Show Test Recorder button.

Test

1. Start the web client. Navigate to the page from where information
is missing. In this case, the page that displays the Vendor
Information page for Matsui Supply Co. This is where you want to
begin recording your step. You can see in the below example the
Address 2 is missing:

Page 55
PeopleSoft Test Framework 8.53 Self Study Guide

Test Recorder window

1. Click the Start Recording button. Enter Address 2 and click the
Stop Recording button.
2. Close the recorder and click Yes when prompted to save the
recorded action.
The test reappears with the new row that has the newly recorded
action.

Newly recorded action

3. Save the test. Next time the test coverage report is run, the
Address 2 field will not be included in the list of fields that have no
test coverage.

Test maintenance is successfully and easily performed using the


PTF.

Page 56

You might also like