Skip to main content

Managing Test Data

Test data refers to the essential information or values necessary for configuring and executing a test case. The validation of various scenarios within numerous test cases often demands a substantial amount of test data.

This document provides a guide for incorporating and managing test data within DevAssure to facilitate the execution and validation of your test cases.

Supported Test Data Types

DevAssure allows you to include test data in different formats to suit your testing needs:

  • Table: This is a versatile format for structured test data. You can create tables with multiple rows and columns, defining the data type (Number, Text, Boolean) for each column.

  • CSV (Comma-Separated Values): For a simpler data structure, you can import existing CSV files containing your test data. This allows easy integration of pre-defined test data sets.

  • Database: DevAssure supports integration with mySQL and PostgreSQL databases. If the test data resides within any of theses database, you can connect and retrieve data directly. This is useful for managing large datasets or complex data relationships.

Creating Test Data for a Test Case

Here's how to create test data for a specific test case in DevAssure:

  1. Navigate to the Test Data Tab: Within the test case editor, locate the "Test Data" tab.

  2. Select Data Format: Choose the appropriate format for your test data from the available options in the dropdown menu.

  3. Using Table Data:

    • Selecting "Table" from the format options will generate a default table with two columns.
    • Define the data type for each column by clicking the icon on the column header and selecting the desired type (Number, Text, Boolean).
    • To rename a column, simply click on the existing header and enter the new name.
    • Add new columns by clicking the "+" icon next to the existing columns.
    • Add new rows for additional test data entries using the "+" icon below the existing rows.
    • Delete unnecessary columns by right-clicking on the column header and selecting "Delete".

  1. Using CSV Data:

  • Selecting "CSV" presents two modes:
    • Use a saved CSV data config - Choose a saved CSV config file from the test data.

    • Upload CSV for this test - Select a CSV file from file explorer and provide the following field details

      Column separatorEnter the column separator from the file . Default value is ","
      Use first row as headerBy selecting this option, the first row of the CSV file is automatically mapped as column headers for use in test cases.
      Field Name - column mappingInput the field names to be mapped to the columns.
      Reset mappingIf you have modified the data post-loading, click "Reset Mapping" to update the columns.
      Limits and FiltersThe provided options enable users to limit and filter rows from the uploaded data file for use in test data.
  1. Using Database Test Data:

    • Selecting "Database" as the data format allows you to leverage data stored within a database for your test cases.

    • DevAssure provides the option to Choose a saved Database Query config. You can create and store pre-defined queries that retrieve specific data from your database. These queries can be reused across different test cases.

    • Essentially, you can link your test case to a specific database query configuration, enabling it to fetch the required data during execution.

  1. Advanced Test Data:

    • For intricate testing scenarios based on test environment, DevAssure provides advanced options for incorporating test data specific to environments.

    • Selecting "Advanced" from the options, you can choose a saved test config data.

    • Upon selection the test data config file along with the respective environment label and columns are displayed.

    • Similar to csv format, you can limit and filter rows retrieved from the advanced data source using the provided options.

  2. Group:

    • Selecting "Group" allows you to utilize pre-defined groups of test data configurations. These groups combine data from various sources (table, CSV, database, etc.) into a single unit for easier management.

    • When you choose Group you can Choose a saved Test Data Group config, which allows you to choose a saved Test data config file.

    • Upon selection ,the test data config file along with the columns and test environment its associated with are displayed.

Limits and Filters

ALL - Utilize all rows as test data from the uploaded file.

ANY - Choose any 'n' rows from the file for test data.

FIRST - Utilize the first 'n' number of rows from the file for test data.

LAST - Utilize the last 'n' number of rows from the file for test data.

ROW_NUMBERS -Specify the required row numbers to be included in test data.