Forum Discussion

Afreen's avatar
Afreen
Occasional Contributor
20 days ago

Multiple Test Environment

Hi, Am new in creation of framework structure. i need some insights on how to create a script based framework such that the works for two environment. Please give me some idea or a structure on how to do that. aby using variables or by creating an excel file whichever approach is easy to maintain.

2 Replies

  • Afreen's avatar
    Afreen
    Occasional Contributor

    Python based script. but can give insights on any language and i can relate that with python

  • Hassan_Ballan's avatar
    Hassan_Ballan
    Icon for Champion Level 3 rankChampion Level 3

    Use TestComplete Working With Excel Files via COM to access your Excel data and store the values in TestComplete project variables, and access such project variables in tests.

    You can also parameterize the NameMapping URL by accessing the Project variable as %Variable%.

    TestComplete caches mapped objects. If the variable value is updated during the test run, TestComplete may not update the mapped object’s criteria, and your test will continue using the cached object. To avoid possible issues, add the RefreshMappingInfo method to your test to command TestComplete to clear the cache and search for the object with the updated mapping criteria.

    If this resolves your scenario, marking it as the solution helps future readers find it quickly.