Create a XTR configuration JSON file

Description

The ‘config.json’ file is the project’s configuration file. It specifies the location of important files for XTR. Below is an example of this file:

{
        "core": "mtf",
        "core_version": "*",
        "testbench_config_folder": "%PD%/config/TestBenchConfigs",
        "test_suite_folder": "%CD%/config/Test_series",
        "extended_system_path": [],

    "override_config":{
        "core": {
        "runner_class": "xtr.core.runner.DefaultRunner",
        "logging": {
            "level": "DEBUG",
            "output_path": "."
        }},
        "plugins": {
            "modules": [
            "tetk.core_framework.mtf.connector",
            "xtr.plugins.xtr_default_report_plugin",
            "xtr.plugins.xtr_junit_xml_report_plugin",
            "xtr.plugins.xtr_unittest_robot_report_plugin",
            "xtr.plugins.xtr_watcher_plugin"
            ]
        }

    }
}
  • Core: Indicates the core framework in use, such as MTF, TDFNext, andisdk and more.

  • core_version: Specifies the framework’s version: MTF version.

  • testbench_config_folder: Specifies the path to the Test bench config folder.

  • test_suite_folder: Specifies the path to the Test_series folder.

  • extended_system_path: Extends the Python execution system path which useful for importing third-party modules.

  • override_config: Allows you to override some of the default configurations of the test runner.

    runner_class: Specifies the test runner style. You currently have two options: either the unittest style, which is the default, or the pytest style. To select one of the options, use the following values:

    • unittest runner: “xtr.core.runner.DefaultRunner”

    • pytest runner: “xtr.core.runner.PyTestRunner”,

    logging: Sets the log level and the output path of the log files. Generally, the ‘DEBUG’ level is used at the start of a project for detailed information useful for debugging. Once the project is stable enough, you can choose the ‘INFO’ level for general information.

  • plugins: Enables optional plugins, such as reporting plugins, to extend the test runner’s functionality.