Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

What are Objects?

In Qualitia Automation Studio (QAS), Objects refer to the controls of the application being tested.

...

Each object is displayed with its attributes such as object name and class.

Describing a Test Object

To describe a test object, you provide a set of property names and their corresponding values.

...

This description helps to identify the objects in the Application Under Test (AUT).

Object-Related Functions

The Objects section on the Develop screen of Qualitia Automation Studio allows you to:

  • Create objects: Suppose you're testing a new feature in a web application that includes a new form for user registration. In this case, you would need to create new objects in Qualitia for each of the form fields (like username, email, password, etc.) and buttons (like submit, cancel, etc.) in the form.

  • Edit objects: Let's say the developers have updated the user interface of the application, changing the ID of the "Submit" button in the form from "submitBtn" to "submitButton". In this case, you would need to edit the "Submit" button object in Qualitia to update its property value to match the new ID.

  • Delete objects: If a feature or element of the application is removed during a redesign, such as a "Cancel" button from a form, you would need to delete the corresponding "Cancel" button object from Qualitia to keep your test cases up to date.

...

  • Locate objects: In a large application with hundreds of test objects, you might need to find a specific object quickly. For example, if you need to update the properties of a "Login" button object, you can use the search function in Qualitia to find this object quickly instead of scrolling through a long list of objects.

...

  • Import objects: If you're working in a team and a team member has already defined some objects for their part of the application, you can import those objects into your project instead of creating them from scratch. This can save time and ensure consistency across the team's work.

Using Leveraging Regular Expressions

If there is a browser with the title "MyBrowser", you can use a regular expression like "MyB.*" for the title property. Suppose you are testing a web application that dynamically generates page titles based on the content, but all titles start with "MyApp". You can use the regular expression "MyApp.*" to match any page title that starts with "MyApp", allowing your tests to work regardless of the specific page being tested.

Using Key Names

If you have a key "TitleKey" storing the value "MyBrowser", you can use the Property Value for the Browser's title as "{TitleKey}".

Use Case: Let us say Assume you are testing a multi-language application where the title of the browser changes based on the selected language. Instead of creating separate objects for each language, you can store the title for each language in a key (like "EnglishTitleKey", "SpanishTitleKey", etc.) and use these keys in the Property Value field. This way, you can easily switch between languages during testing by just changing the key values.

...

  1. Test Case 1: Add a product to the cart.

  2. Test Case 2: Remove a product from the cart.

In both the test cases, you need to interact with a product object. The product object has a property "ProductID," which is used to identify the product.

...

Now, in Test Case 2, you are testing the functionality of removing a product with ProductID "456" from the cart. You use the same key name "ProductKey" , but this time you set its value to with value as "456." . In your test steps, you again use "{ProductKey}" to refer to the ProductID. When this test runs, Qualitia will replace "{ProductKey}" with "456", and the test will remove the product with ProductID "456" from the cart.

Even though you used the same key name "ProductKey" in both test cases, changing the key value in Test Case 2 did not affect Test Case 1. This is because the scope of the key is limited to the test case in which it is used. This allows you to reuse the same key names across different test cases without worrying about conflicts or unintended side effectsconsequences.

Concatenating Keys and Strings

If you have two keys,

  • "StartKey" = Begin

  • "EndKey" = End

You can combine them in several ways to yield different outputs:

  • "{StartKey}{EndKey}" will yield "BeginEnd"

  • "Start{EndKey}" will yield "StartEnd"

  • "{StartKey}ning" will yield "Beginning"

Suppose you are testing a web application that generates dynamic URLs based on user input. The URL structure is www.example.com/{userInput}Page. You can store the user input in a key, say UserKey. In your test steps, you can refer to the URL as www.example.com/{UserKey}Page. This way, you can easily test with different user inputs by just changing the value of UserKey.

Special Characters

  • Braces ({}) - Key Name Identifiers

...

  • : If you have a key named "TitleKey" storing the value "MyBrowser,"

...

  • you will use it in the Property Value field as "{TitleKey}".

...

  • Suppose you are testing a web application where the page title changes based on user actions. Instead of creating separate objects for each title, you can store the title in a key and use that key in the Property Valuefield. This way, you can easily change the title being tested by just changing the value of the key.

  • Forward Slash (/) - Escape Character in Qualitia

...

  • : If you want to use a string that includes a brace in the Property Value field, you will need to precede it with a forward slash, like "/{MyString".

...

  • Suppose you are testing a code editor application where users can input code snippets. If you want to test with a string that includes a brace, you will need to use a forward slash to escape the brace so that Qualitia does not interpret it as a key name identifier.

  • Caret (^) - Array Data Separator

...

  • : If you want to pass an array of strings like "Apple", "Banana", and "Cherry" in the Property Value field, you will use a caret as a separator, like "Apple^Banana^Cherry".

...

  • Use Case: Suppose you are testing a feature where a user can select multiple items from a list and the selected items are sent to the server as a string separated by ^. In your test data, you can store the selected items as "Apple^Banana^Cherry". In your test steps, you can use this string directly to simulate the user selecting "Apple", "Banana", and "Cherry" from the list.