Forums / Categories / PeopleSoft / PeopleSoft Testing Framework?

    PeopleSoft Testing Framework?

    Can any provide me with a PTF example script of looping through a set of test data and validating data on a page? The data could be loaded from a PS query or file. It would include EMPLID, and data that I want to validate. I want to loop through many rows and don't want to repeat writing the same script.

    An example or any suggestion would be appreciated.

    Thanks.

    Here is an example from Financials - Journal Entry. You will need to Parse this for it to display correctly. I put a pipe between each of the column values for Type, Action, Recognition and Value. Hope it helps.

    Type| Action| Recognition| Value
    Variable | Set_Value | &Ln| 1
    Loop| For| &Ln = 1 to &Lns |
    Variable| Set_Value| &JrnlLn| subtract(&Ln|1)
    Page| Go_To| Lines
    Span| Verify| id=JOURNAL_LINE$&JrnlLn| &Ln
    Variable| Set_Value| &Calc_BU| concat(&BUSINESS_UNIT_L|&Ln)
    Text| Set_Value| name=BUSINESS_UNIT$&JrnlLn| &Calc_BU
    Variable| Set_Value| &Calc_SPEEDTYPE| concat(&SPEEDTYPE_KEY_L|&Ln)
    Text| Set_Value| name=SPEEDTYPE_KEY$&JrnlLn| &Calc_SPEEDTYPE
    Variable| Set_Value| &Calc_ACCOUNT| concat(&ACCOUNT_L|&Ln)
    Text| Set_Value| name=ACCOUNT$&JrnlLn| &Calc_ACCOUNT
    Variable| Set_Value| &Calc_CHARTFIELD1| concat(&CHARTFIELD1_L|&Ln)
    Text| Set_Value| name=CHARTFIELD1$&JrnlLn| &Calc_CHARTFIELD1
    Variable| Set_Value| &Calc_DEPTID | concat(&DEPTID_L|&Ln)
    Text| Set_Value| name=DEPTID$&JrnlLn| &Calc_DEPTID
    Conditional| If_Then| &Uses_PROJ_ID_AFFILIATE_FOREIGN_CURR ="YES"|
    Variable| Set_Value| &Calc_PROJECT_ID| concat(&PROJECT_ID_L|&Ln)
    Text| Set_Value| name=PROJECT_ID$&JrnlL| &Calc_PROJECT_ID
    Variable| Set_Value| &Calc_AFFILIATE| concat(&AFFILIATE_L|&Ln)
    Text| Set_Value| name=AFFILIATE$&JrnlLn| &Calc_AFFILIATE
    Variable| Set_Value| &Calc_FOREIGN_CURRENCY| concat(&FOREIGN_CURRENCY_L|&Ln)
    Text| Set_Value| name=FOREIGN_CURRENCY$&JrnlLn| &Calc_FOREIGN_CURRENCY
    Conditional| End_If | |
    Variable| Set_Value| &Calc_FOREIGN_AMOUNT| concat(&FOREIGN_AMOUNT_L|&Ln)
    Text| Set_Value| name=FOREIGN_AMOUNT$&JrnlLn| &Calc_FOREIGN_AMOUNT
    Conditional| If_Then| &Use_open_ITEM ="YES"|
    Variable| Set_Value| &Calc_OPEN_ITEM_KEY | concat(&OPEN_ITEM_KEY_L|&Ln)
    Text| Set_Value| name=OPEN_ITEM_KEY$&JrnlLn| &Calc_OPEN_ITEM_KEY
    Conditional| End_If | |
    Conditional| If_Then| &Ln <> &Lns |
    Link| Click| name=JRNL_PANELS_WRK_PB_INSERT_LN|
    Conditional| End_If | |
    Loop| Next | |

    @Chris Stephenson I also want to mention that I can't take credit for this code. It was created for us by a consultant from Elire name Valentin Todorow.

    @Paul Chin-Lai Hi Paul, the DataLoader/PSQuery example in PeopleBooks PeopleTools 8.57 PTF has a good example. By getting the &rowcount as one of your parameters, you can use it to loop through your result set. Within the loop, you can put your code. This works as I have used it. I haven't done one by reading from a file.

    @Erlinda Arreola Thanks for the direction. That looks like what I need. DataLoader was introduced in PT 8.56 and I am currently on 8.55.. So, I'm pausing on this until I get an environment with later Tools.

    @Paul Chin-Lai It works in both 8.56 and 8.57. The only issue we had is when we tried creating a copy of the delivered permission list (PL) and then assigned the copied PL to me, we can't get it to work. Instead we just used the delivered PL.

     
Log in to reply

Looks like your connection to Quest Oracle Community was lost, please wait while we try to reconnect.