Forum Discussion

heidi_n's avatar
heidi_n
Regular Contributor
12 years ago

How to handle a URL that changes every time the test is run?

How should I handle URLs that change every time the test is run? I am using keyword tests and IE.



I keep getting:



The page 'http://xxxxx-x/pls/dad_11111/web_eco_admin.get_data?v_eco_responsibility_id=41' was not found.



Additional Info:



The Browser('iexplore') does not contain Page("http://xxxxx-x/pls/dad_11111/web_eco_admin.get_data?v_eco_responsibility_id=41").

3 Replies

  • tristaanogre's avatar
    tristaanogre
    Esteemed Contributor
    Depending upon how you have your information organized, it's a matter of finding the right place of putting the wildcard.



    I'm assuming, based upon your original information, that what is changing everytime is the v_eco_responsibility_id.  Pretty much, what I'd do is change your page declaration in your keyword test to point to




    Page("http://xxxxx-x/pls/dad_11111/web_eco_admin.get_data?v_eco_responsibility_id=*")



    Hope this helps...
  • tristaanogre's avatar
    tristaanogre
    Esteemed Contributor
    If you double-click on the onscreen action for Frame('details'), you should get an edit window for the onscreen action.  There is a text field across the middle of the window labeled "Object".  In that text field is the full object reference for the object you are operating against.  You should be able to, in that field, edit the text for the page to include the necessary asterisk/wildcard character (see attachement).

  • heidi_n's avatar
    heidi_n
    Regular Contributor
    Hi Robert,



    Yes, the v_eco_responsibility_id changes every time.



    This sounds like it will work. How do I make these changes so that v_eco_responsibility_id=*?



    Attached is a screenshot.