Testing is important, and PeopleSoft Test Framework can help

Testing, it should be an (if not the most) important part of your upgrade and maintenance projects. In earlier days, when upgrades where done roughly once every three years (or more) testing outside of the big upgrades could be kept to a minimum.

With PeopleSoft Update Manager (PUM) and 9.0 / PeopleTools releases 8.54 and 8.55 updates are being released more frequent.

This change means you need to start testing more often, to ensure application functionality, not only for major upgrades but also after small fixes.

PeopleSoft Test Framework (PTF) can help you save time and add consistency and reliability to your testing process. This is achieved by using the PeopleSoft Test Framework recording and playback capabilities.

PTF is primarily aimed at functional testing. Thanks to the recording functionality being easy to use, business users can make recordings without a lot of technical knowledge. They can even be migrated with the use of Application Designer.

To build the tests user clicks, together with data input, are recorded in a simple step-by-step manner. All you need to record scripts is PTF and Internet Explorer (and of course your test scripts).

While recording scripts can still only be done using Internet Explorer, as of PeopleTools 8.55 the playback of tests is supported on multiple browsers. Those are Google Chrome, Firefox, Internet Explorer and Microsoft Edge. PTF is now finally offering multi-browser support, and can now be used for browser compatibility testing.

New Features

Lets briefly mention some of the new features of PTF in PeopleTools 8.55.
The most exciting new feature in PeopleTools 8.55 is the feature mentioned before, being able to playback tests on multiple browsers. This makes it possible to not only do functionality testing but also browser compatibility. The browsers now supported for playback are: Microsoft Edge, Google Chrome, Mozilla Firefox and Internet Explorer.

Also new since PT 8.55 is the support for Single Sign-on (SSO) and custom login pages, eliminating the need for a dedicated PeopleSoft instance when using SSO.
Another new feature is the ability to simply run a test by right clicking on the Test Case from the test suite view.
As of PT 8.55 PTF is able to recognize field properties, including color, font size and properties of an object.

#TODAY

The functionality in PTF that I would like to highlight, since I use it a lot, is the reserved words functionality. With reserved words you can use some preset variables and incorporate them into your test scripts. When you are writing/recording test scripts there are occasions where the input data has to be the current date. Luckily the creators of PTF have thought of this. By using the reserved word #TODAY in your test script you tell the system to use the current date as input for the selected input field.
A little example:

In the screenshot below you will find two fields that I would like to fill with the current date at the time of playback, the Effective Date field and the As of field;

Blog PTF 1

The Effective Date field normally get’s filled with the current date as soon as I add a new row. The As of date however retains the value previously filled in.

By replacing the date that I filled in during the recording of this test case with the reserved word #TODAY in the PTF test editor screen, PTF will recognize the use of a reserved word and automatically fill in the current date in the given input box.

In the PTF test editor screen this part of the script will look like this;

Blog PTF 2

This is one short example of how a reserved word, in this case #TODAY, can be used in PTF to help make tests more specific.

Excel driven test cases

One of the ways to rapidly define test cases after recording your initial test case is the use of Excel. By exporting your test case to Excel, then adding new data (test cases) to the Excel sheet and importing the Excel file back into PTF you can easily create multiple test cases.

How it is done? Let me briefly show you;

First open the test for which you would like to create multiple test cases.
Then navigate in PTF to Test > Export as shown in the screenshot below.

Blog PTF 3

In the export screen, select a file path where you would like to store the export and give your export a name. After this, click ‘start’ to start exporting your current test data.

Blog PTF 4

Once the export is completed, click close and open the exported file (with Excel).
The test case in this example adds an emergency phone number to a students record.
The export looks like this:

Blog PTF 5

Using Excel we can fill in the data to add new test cases. Row number 2 contains the test case names.
If we want to add a test case called EXAMPLE for example, the data we fill in should look like this:

Blog PTF 6

When we save this edited excel file and import it back into our test, you will see that the test case EXAMPLE will be added to the test.

To import the test case(s) you have made in Excel follow the following steps:

Navigate to Test > Import in the test editor screen in PTF.

Blog PTF 7

In the import screen select the file path of the Excel file made and click ‘Open’.

Blog PTF 8

When opened we select the test cases we want to import.
(I deselected DEFAULT as I prefer to keep my original recording in tact)
Then click Start to import the cases.

Blog PTF 9

Now you can click close and you can see the new test case is imported into your test.

Blog PTF 10

Generate your test cases

I know what you are thinking, all nice and easy but I still have to collect the data myself.

But there is a way to automate this process as well! You can do this by building a query to extract the necessary/specific data to an excel file, then placing this data into the exported Excel file from the test and lastly importing it back into PTF like previously explained.

Let me show you how;

First I made a query to extract 10 students who do not have an emergency phone number yet. The query looks like this:

Blog PTF 11

In the query I have used expressions to align the data extracted with the fields of the test case in Excel. The result looks like this:

Blog PTF 12

Now we select the data (without the headers) and paste it in a special way into the Excel export from the test case. We use the special Paste > Transposing option to align the data with our existing data.
Blog PTF 13

In English it will look like this:
Blog PTF 14
The result should be that our extracted data aligns nicely with the data from our previous cases.
Blog PTF 15

Finally, we can import this data to create the test cases within PTF.
We can do that by repeating the import steps as described in the previous example.

Navigate to Test > Import in the test editor screen in PTF.
Blog PTF 16

In the import screen select the file path of the Excel file made and click ‘Open’.
Blog PTF 17

When opened we select the test cases we want to import. (I deselected DEFAULT and EXAMPLE as I prefer to keep my original cases in tact). Then click Start to import the cases.
Blog PTF 18

Now you can click close and you can see the new test case is imported into your test.
Blog PTF 19

Last word of advice

Lastly I would like to give a little unasked advice, even though it is a bit of an obvious one.

The sooner you start using PTF, the easier it will be to maintain your test database. Yes, the initial effort will be substantial but once made you only have to focus on changes in functionality and the creation of test scripts of new functionality and custom changes made to your system over time. As for this upkeep, my advice is to make the creation of test scripts of these new functionalities and customizations part of your upgrade projects and change management processes. This way it will be the easiest to have an up to date test database at all times.

It also makes it easier to use complete or partial functionality testing during projects or even at a set interval to ensure continuity. Since it requires simply playing back the test scripts you have recorded, you no longer need a room full of people going through a stack of step by step test scripts on paper (think about all the ink and paper you can save  not to mention the resources).

There are so many more tips and tricks and pieces of advice that can be given, but that would make this blog become too long.

If you want to know more about PTF or feel the need for support while implementing PTF into your organization, feel free to contact CY2, we are here to help!

More information about PTF can also be read in Oracle’s online documentation.