Same tests on different URL's? - Printable Version +- Micro Focus QTP (UFT) Forums (https://www.learnqtp.com/forums) +-- Forum: Micro Focus UFT (earlier known as QTP) (https://www.learnqtp.com/forums/Forum-Micro-Focus-UFT-earlier-known-as-QTP) +--- Forum: UFT / QTP Beginners (https://www.learnqtp.com/forums/Forum-UFT-QTP-Beginners) +--- Thread: Same tests on different URL's? (/Thread-Same-tests-on-different-URL-s) |
Same tests on different URL's? - Mukesh.Laxmidhar - 09-28-2010 Hi guys, I have automated some regression tests for one URL, but how can I iterate the same tests for other URL's. The URL's are different but everything else is suppose to be identical. Hence the same testing on all URL's. Thanks and kind regards, Mukesh L. RE: Same tests on different URL's? - A.Saini - 09-28-2010 Hi Mukesh, Are you sure that on different URL everthing else is identical? Please check it again.Use object spy for detail checking. I think it should be different. RE: Same tests on different URL's? - PrabhatN - 09-28-2010 Hi Mukesh, Make sure everything is same for different URLs because the "Browser" object properties are different for different URLs. The only property that can identify different Browsers is "CreationTime". If still everything same then you can acheive this task as follows: 1. In the Global Sheet, name a column as "URLs_In" and give all the URLs you want to test under this column. 2. Change/Set the "Data Table iteration" option to "Run on all rows" (File-->Settings-->Run-->Data Table iteration) 3. Create an action and name it "Launch_URL" and write the below code inside it Code: SystemUtil.Run "iexplore",DataTable("URLs_In",dtGlobalSheet) 4. Then call your other actions that deal with actual test. Make sure you are identifying the "Browser" object by "CreationTime" property 5. After each iteration (at the last line of your last action) write the below code Code: Browser("CreationTime:=0").Close Hope it will help you. RE: Same tests on different URL's? - Mukesh.Laxmidhar - 09-28-2010 "It's alive!" First of all Ankur & Prabhat, thanks for your responses. Yes I see what you both mean, but the company is using some web based Content Man. Sys were they have different frontends to reduce the load. Even though the FrontEnd url is different, all the obj. and links for some reason seems to have same path. Since I am new here I don't have all the details yet Prabhat thanks for the list, works like a charm. - Mukesh L. |