SPONSORS:






User Tag List

Results 1 to 3 of 3
  1. #1
    Senior Member
    Join Date
    Jun 2002
    Posts
    119
    Post Thanks / Like
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    How to test and verify a screen that\'s going to change during the test?

    I'm a rookie at SilkTest. I've been testing a web app, a portal, which has a user login and the user can create his own content. I'm getting to the part of the scripting where the tests involve telling the app to add or delete pages, and add or delete content of those pages and change the order of the pages (tabbed for selection), etc. So everything I need to test involves changing the screen. I'm trying to figure how to design tests with verifications, if the window declarations in my frame.inc file are going to get squiddled around as the scripts run. In exploring the question, I ran "Run Window Declarations" and hovered the mouse over a list of three page names in the popup window that manages deleting and order changing. There's an icon next to each name in the list, that you click to delete that page. I could see the tags as Page 1 -- HtmlText #8, Page 2 -- HtmlText #9, and Page 3 -- HtmlText #10. After deleting Page 2, the window refreshes itself and the list is now Page 1 -- HtmlText #8, Page 3 -- HtmlText #9. How can I use "Page3" as an identifier if its tag is going to change on the fly? Won't Silk slip on the banana peel?

    I haven't fooled around with scripting it yet, this is the point I was at when I had to leave work and I puzzled about it on the way home and now I'm hoping to get some tips before I go off this morning.

    I thought that I might call the objects in some "raw" way, like HtmlLink#9.Click() and Verify(HtmlText#10.Exists(), FALSE). I also thought there might be some, way using the GetContents() function, to get the contents at any moment, and scan through it looking for the new tag assignments each time and sort of "reidentifying" my objects based on something in there. I suppose some sort of utility functions could be written that would do that for me.

    I don't know if I'm clear here, this is groping in the dark for me.

    Thanks for any ideas.

    F

    ------------------

  2. #2
    Senior Member
    Join Date
    Nov 2001
    Location
    UK, Oxford
    Posts
    150
    Post Thanks / Like
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Re: How to test and verify a screen that\'s going to change during the test?

    <BLOCKQUOTE><font size="1" face="Verdana, Arial, Helvetica">quote:</font><HR>Originally posted by felecha:
    How can I use "Page3" as an identifier if its tag is going to change on the fly? Won't Silk slip on the banana peel?
    <HR></BLOCKQUOTE>
    Don't use an identifier.
    You should be able to call your pages dynamically.
    I could select a tab in my java app by doing the following:

    JavaMainWin("*structure?").CustomWin("[javax.swing.JRootPane]#1").CustomWin("[javax.swing.JLayeredPane]#1").CustomWin("[javax.swing.JPanel]#1").CustomWin("[javax.swing.JPanel]#1"). JavaJFCPageList("#1").Select("EDITab")

    The tags of your pages go in the quoted sections. Something like:
    HtmlText("whateverTagIs")

    As far as re-examining the objects on your pages, take a look at the FlushCache method, but I personally have only used SilkTest with Java apps.


    ------------------


    [This message has been edited by johntest (edited 09-10-2002).]
    Tempus fugit, Carpe Diem, et al

  3. #3
    Senior Member
    Join Date
    Jun 2002
    Posts
    119
    Post Thanks / Like
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Re: How to test and verify a screen that\'s going to change during the test?

    Great! That's the syntax I was looking for!

    OpeningPage.MainSection.CustomWin("[HtmlPushButton]#1").Click()

    worked slick. Thanks a lot. I had tried all kinds of syntax for that and couldn't find it in the manual or by trying blind.



    ------------------

 

 

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  

vBulletin Optimisation provided by vB Optimise v2.6.0 Beta 4 (Pro) - vBulletin Mods & Addons Copyright © 2016 DragonByte Technologies Ltd.
User Alert System provided by Advanced User Tagging v3.0.9 (Pro) - vBulletin Mods & Addons Copyright © 2016 DragonByte Technologies Ltd.
Questions / Answers Form provided by vBAnswers (Pro) - vBulletin Mods & Addons Copyright © 2016 DragonByte Technologies Ltd.
vBNominatevBulletin Mods & Addons Copyright © 2016 DragonByte Technologies Ltd.
Feedback Buttons provided by Advanced Post Thanks / Like (Pro) - vBulletin Mods & Addons Copyright © 2016 DragonByte Technologies Ltd.
Username Changing provided by Username Change (Free) - vBulletin Mods & Addons Copyright © 2016 DragonByte Technologies Ltd.
BetaSoft Inc.
Digital Point modules: Sphinx-based search
All times are GMT -8. The time now is 02:30 AM.

Copyright BetaSoft Inc.