<!DOCTYPE html>
<html lang="en">

<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>NATT test configuration editor</title>
    <!-- Bootstrap CSS -->
    <link rel="stylesheet" href="https://stackpath.bootstrapcdn.com/bootstrap/4.5.2/css/bootstrap.min.css">
    <!-- Bootstrap JavaScript -->
    <script src="https://stackpath.bootstrapcdn.com/bootstrap/4.5.2/js/bootstrap.min.js"></script>
    <!-- Font Awesome -->
    <link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/5.15.4/css/all.min.css">
    <!-- Custom style -->
    <link rel="stylesheet" href="{{ url_for('static', filename='css/index_style.css') }}">
    <style>
        body {
            overflow: auto !important;
            color: #eee;
        }
        h1,
        h2,
        h3 {
            color: #bbb !important;
        }

        hr {
            border: 1px solid #999;
        }
        .content-img {
            max-width: 70%;
            display: block;
            margin: 0 auto;
        }
    </style>
</head>

<body>
    <div class="container pt-5">
        <div class="d-flex justify-content-between">
            <h1><i class="fas fa-question-circle"></i> Help</h1>
            <button class="btn btn-outline-light navbar-btn" type="button" onclick="gotoMain()" title="Validate">
                <i class="fas fa-arrow-left"></i> back
            </button>
        </div>
        <hr>

        <div align="center">
            <img src="{{ url_for('get_icon', filename='logo.png') }}" alt="NATT logo" width="21%">
            <h1>Network Application Testing Tool (NATT)</h1>
            <div>
                <img alt="UTB FAI Task" src="https://img.shields.io/badge/UTB_FAI-Software-yellow">
                <img alt="Java"
                    src="https://img.shields.io/badge/Java-007396.svg?logo=java&logoColor=white)](https://www.java.com/">
                <img alt="Gradle"
                    src="https://img.shields.io/badge/Gradle-02303A.svg?logo=gradle&logoColor=white)](https://gradle.org/">
            </div>
            <i>Created as part of the thesis at UTB</i>
        </div>

        <h1 id="-description-of-testing-tool">💡 Description of testing tool</h1>
        <p>This <strong>Black Box</strong> Testing Tool is designed for automating the testing and evaluation of tasks
            without requiring knowledge of the software&#39;s internal structure or implementation details. It offers
            several key features:</p>
        <ul>
            <li><strong>Universality</strong>: The tool supports testing various types of software applications
                regardless of their implementation details.</li>
            <li><strong>Separation</strong>: Emphasizes the separation of the evaluation application and its internal
                logic from the tested tasks.</li>
            <li><strong>Independence</strong>: The tool operates independently of external network resources, allowing
                it to create virtual servers and clients for testing purposes.</li>
            <li><strong>Flexibility</strong>: Users can easily define new test sets using specific keywords in the
                configuration.</li>
        </ul>
        <h1 id="-configuring-of-the-testing-tool">🔧 Configuring of the Testing Tool</h1>
        <p>In order to ensure the versatility of our black box testing tool, we&#39;ve devised a straightforward method
            for users to convey precisely what tasks they want the tool to undertake. This is achieved through the
            utilization of YAML-formatted configurations for test sets. These configurations serve as blueprints,
            enabling the tool to execute tasks reliably and efficiently.</p>
        <p>The configuration language of our tool is designed to be intuitive, comprising a set of keywords that users
            can easily manipulate to tailor their testing requirements. Writing configurations for our tool is akin to
            crafting configurations for GitLab CI/CD pipelines, ensuring familiarity and ease of use for those
            experienced with such processes.</p>
        <h2 id="-understanding-test-structures">🧩 Understanding Test Structures</h2>
        <p>Let&#39;s dive into the structure of tests in our tool. The image below this text shows a diagram of our test
            framework, the core of which comes from the Test Root node. This basic element, paramount in any
            configuration, determines the overarching setting for the testing process. All test suites are defined in
            this root element.</p>
        <p><img class="content-img" src="{{ url_for('get_icon', filename='test_structure.png') }}" alt="Test structure"></p>
        <h1 id="-variables-and-received-messages">📩 Variables and Received Messages</h1>
        <p>During testing, you have the flexibility to work with variable contents or with a message buffer containing
            all messages received during testing. The content of the received message buffer is automatically cleared
            upon the completion of each test case. Variables are only accessible within the context in which they were
            created. Therefore, if a variable is created within a test case, it will only be available within that
            specific test case. There&#39;s no need to declare a variable before writing to it; simply input the desired
            content, and if it doesn&#39;t exist, it will be automatically created.</p>
        <h3 id="important-">Important:</h3>
        <ul>
            <li>
                <p><strong>Variable</strong> - Contains arbitrary data into which information is inserted during test
                    execution. These variables are automatically populated by the tool. The variable
                    <strong>&#39;(module-name)-last-msg&#39;</strong> holds the content of the message received last by
                    a given module. The variable <strong>&#39;(module-name)-action-msg&#39;</strong> contains the
                    content of the message that triggered the termination of the &#39;wait_until&#39; function.</p>
            </li>
            <li>
                <p><strong>Message Buffer</strong> - Contains all messages received during the entire testing duration.
                    Messages are accessible only within the scope of a test case.</p>
            </li>
        </ul>
        <blockquote>
            <p><strong>(module-name)</strong> is replaced with the unique name of the module. The name of the module is
                always defined when it is created</p>
        </blockquote>
        <h1 id="-inserting-variables-into-strings">🔠 Inserting Variables into Strings</h1>
        <p>Accessing the content of variables can be achieved using specific keywords tailored for this purpose, or
            their values can be directly inserted into any parameter of any keyword in the configuration. However, the
            parameter must be of string type. Simply insert the name of the variable preceded by
            <strong>&#39;$&#39;</strong> into the desired string. For example, in the following manner:
            <strong>&quot;Text $var1 Text&quot;</strong>. Name of variable is <strong>&quot;var1&quot;</strong>.</p>
        <h1 id="-keywords">🔑 Keywords</h1>
        <p>This section provides a brief description of all the keywords that the tool allows execution of. Due to the
            extensive scope, only a basic description will be provided here. Detailed descriptions and parameter
            explanations can be found in the documentation.</p>
        <p>Each keyword has a unique name and a set of parameters that must be configured. A keyword can contain any
            number of parameters. Parameters can be of type string, boolean, double, long, or list. For lists, all
            values must be of the same type. The value of a parameter can also contain additional nested keywords.</p>
        <h2 id="main-keywords">Main Keywords</h2>
        <p>This set comprises all the keywords that directly define the testing structure.</p>
        <ol>
            <li><strong><code>test_root</code> – Marks the root element of the test configuration. It must be located at
                    the beginning of the testing configuration. Tests start executing from this point.</strong>
                <ul>
                    <li><code>max_points</code>: <em>Type</em>: float, <em>Description</em>: Maximum points for the
                        test.</li>
                    <li><code>initial_steps</code>: <em>Type</em>: list | not required, <em>Description</em>: Initial
                        steps for all test suites. These steps are performed only once at the beginning and then the
                        test suites are executed.</li>
                    <li><code>test_suites</code>: <em>Type</em>: list, <em>Description</em>: List of test suites.</li>
                </ul>
            </li>
            <li><strong><code>test_suite</code> – Used to define a testing suite.</strong>
                <ul>
                    <li><code>name</code>: <em>Type</em>: string, <em>Description</em>: Name of the test suite.</li>
                    <li><code>delay</code>: <em>Type</em>: long | not required, <em>Description</em>: Delay between
                        executed test cases. After finishing of the test case, it will wait for the specified time.
                        (default: 500 ms)</li>
                    <li><code>initial_steps</code>: <em>Type</em>: list | not required, <em>Description</em>: Initial
                        steps for the test suite. These steps are performed only once at the beginning.</li>
                    <li><code>test_cases</code>: <em>Type</em>: list, <em>Description</em>: List of test cases.</li>
                </ul>
            </li>
            <li><strong><code>test_case</code> – Allows the definition of individual test cases.</strong>
                <ul>
                    <li><code>name</code>: <em>Type</em>: string, <em>Description</em>: Name of the test case.</li>
                    <li><code>description</code>: <em>Type</em>: string, <em>Description</em>: Description of the test
                        case.</li>
                    <li><code>steps</code>: <em>Type</em>: list, <em>Description</em>: Steps to execute in the test
                        case.</li>
                </ul>
            </li>
        </ol>
        <h2 id="keywords-for-controlling-external-applications">Keywords for Controlling External Applications</h2>
        <p>This set includes keywords that enable working with an external application. It&#39;s primarily designed for
            launching and communicating with the tested application.</p>
        <ol>
            <li><strong><code>run_app</code> - Launches the application. At any given time, only one external
                    application can run. It allows the definition of arguments to be passed to the application upon its
                    launch.</strong>
                <ul>
                    <li><code>default</code>: <em>Type</em>: string, <em>Description</em>: Command to run the
                        application. Can run only one application at a time.</li>
                </ul>
            </li>
            <li><strong><code>run_app_later</code> - Launches the application with a time delay. This operation is
                    asynchronous. Again, only one external application can run at a time.</strong>
                <ul>
                    <li><code>command</code>: <em>Type</em>: string, <em>Description</em>: Command to run the
                        application. Can run only one application at a time.</li>
                    <li><code>delay</code>: <em>Type</em>: long, <em>Description</em>: Time after which the application
                        starts.</li>
                </ul>
            </li>
            <li><strong><code>reload_app</code> - Stops the currently running application and restarts it.</strong>
                <ul>
                    <li><code>default</code>: <em>Type</em>: string, <em>Description</em>: Command to reload the
                        application.</li>
                </ul>
            </li>
            <li><strong><code>standard_stream_send</code> - Sends a message to the running application via standard
                    streaming.</strong>
                <ul>
                    <li><code>name</code>: <em>Type</em>: string, <em>Description</em>: Message to send through the
                        standard stream.</li>
                </ul>
            </li>
        </ol>
        <h2 id="general-keywords">General Keywords</h2>
        <p>This set encompasses keywords for working with variables, waiting, conditional waiting, and more.</p>
        <ol>
            <li><strong><code>wait</code> - Pauses the test execution for a defined duration.</strong>
                <ul>
                    <li><code>default</code>: <em>Type</em>: integer, <em>Description</em>: Time to wait in
                        milliseconds.</li>
                </ul>
            </li>
            <li><strong><code>wait_until</code> - Waits until a specific action occurs, triggered by the reception of a
                    message from a certain communication module. It can be extended with filtering conditions. The
                    content of the message that triggered the action is automatically stored in a variable for potential
                    testing.</strong>
                <ul>
                    <li><code>module_name</code>: <em>Type</em>: string, <em>Description</em>: The module that should
                        trigger the action. You can specify multiple modules this way: module-1 &amp; module-2.</li>
                    <li><code>time_out</code>: <em>Type</em>: integer | not required, <em>Description</em>: Maximum
                        waiting time in milliseconds. (default: 10 000 ms)</li>
                </ul>
            </li>
            <li><strong><code>store_to_var</code> - Retrieves and stores the content of a specific message from the
                    message buffer into the chosen variable. If multiple messages match the specified search conditions,
                    the variable stores the first one found, i.e., the one received first.</strong>
                <ul>
                    <li><code>var_name</code>: <em>Type</em>: string, <em>Description</em>: Name of the variable to
                        store the value of the message.</li>
                    <li><code>module_name</code>: <em>Type</em>: string, <em>Description</em>: The module from which the
                        message was received.</li>
                    <li><code>text</code>: <em>Type</em>: string | not required, <em>Description</em>: Text that must be
                        included in the message. (default: &quot;&quot;)</li>
                    <li><code>tag</code>: <em>Type</em>: string | not required, <em>Description</em>: Required tag of
                        the message. (default: &quot;&quot;)</li>
                    <li><code>mode</code>: <em>Type</em>: string | not required, <em>Description</em>: Finding mode.
                        There are these modes: &quot;equals&quot;, &quot;contains&quot;, &quot;startswith&quot;,
                        &quot;endswith&quot;. (default: equals)</li>
                    <li><code>case_sensitive | not required</code>: <em>Type</em>: boolean, <em>Description</em>:
                        Whether the filter should be case sensitive.</li>
                </ul>
            </li>
            <li><strong><code>count_and_store</code> - Counts the number of received messages during a single test case
                    and saves this count into a variable.</strong>
                <ul>
                    <li><code>var_name</code>: <em>Type</em>: string, <em>Description</em>: Variable to store the count.
                    </li>
                    <li><code>module_name</code>: <em>Type</em>: string, <em>Description</em>: Module whose received
                        messages will be counted.</li>
                </ul>
            </li>
            <li><strong><code>read_file</code> - Reads the content from the specified file on the local device and
                    stores its value into the defined variable.</strong>
                <ul>
                    <li><code>var_name</code>: <em>Type</em>: string, <em>Description</em>: Variable to store the file
                        content.</li>
                    <li><code>file_path</code>: <em>Type</em>: string, <em>Description</em>: Path to the file to be
                        read.</li>
                </ul>
            </li>
            <li><strong><code>set_var</code> - Sets the specified variable to the defined content.</strong>
                <ul>
                    <li><code>var_name</code>: <em>Type</em>: string, <em>Description</em>: Variable to store the value.
                    </li>
                    <li><code>value</code>: <em>Type</em>: string, <em>Description</em>: The value that will be stored
                        in the variable.</li>
                </ul>
            </li>
            <li><strong><code>replace</code> - Retrieves the content of a specific variable, replacing all desired words
                    with their replacements. The result is stored in another variable.</strong>
                <ul>
                    <li><code>to_var</code>: <em>Type</em>: string, <em>Description</em>: Variable to store the modified
                        text.</li>
                    <li><code>from_var</code>: <em>Type</em>: string, <em>Description</em>: Variable containing the
                        original text.</li>
                    <li><code>str_from</code>: <em>Type</em>: list, <em>Description</em>: String to be replaced in the
                        original text.</li>
                    <li><code>str_to</code>: <em>Type</em>: list, <em>Description</em>: String to replace occurrences of
                        <code>str_from</code> in the original text.</li>
                </ul>
            </li>
            <li><strong><code>write_file</code> - Writes the defined content into a file on the local device.</strong>
                <ul>
                    <li><code>file_path</code>: <em>Type</em>: string, <em>Description</em>: The path to the file where
                        the content will be written.</li>
                    <li><code>content</code>: <em>Type</em>: string, <em>Description</em>: The content to be written to
                        the file.</li>
                </ul>
            </li>
            <li><strong><code>clear_buffer</code> - Clears the content of the message buffer. It&#39;s possible to clear
                    the buffer content for all modules or for a specific one.</strong>
                <ul>
                    <li><code>default</code>: <em>Type</em>: string, <em>Description</em>: Specific module name, or
                        symbol &quot;*&quot; for all modules.</li>
                </ul>
            </li>
            <li><strong><code>json_get</code> - Extracts the value of a specified attribute from the content of a
                    variable in JSON format. It&#39;s possible to access array indices or to traverse multiple levels in
                    one step.</strong>
                <ul>
                    <li><code>to_var</code>: <em>Type</em>: string, <em>Description</em>: Variable to store the
                        extracted value.</li>
                    <li><code>from_var</code>: <em>Type</em>: string, <em>Description</em>: Variable containing the JSON
                        structure.</li>
                    <li><code>param_name</code>: <em>Type</em>: string, <em>Description</em>: Name of the parameter to
                        extract from the JSON. If the structure is a list, specify an index to get one element. It is
                        also possible to approach a certain parameter hierarchically in depth, when the parameter names
                        are separated by &quot;:&quot;. For example: parent_param:child_param.</li>
                </ul>
            </li>
            <li><strong><code>buffer_get</code> - Retrieves the content of a single message from the message buffer of a
                    specific module. The message is accessed using an index, and its content is stored in the defined
                    variable.</strong>
                <ul>
                    <li><code>var_name</code>: <em>Type</em>: string, <em>Description</em>: Variable to store the
                        extracted message value.</li>
                    <li><code>module_name</code>: <em>Type</em>: string, <em>Description</em>: Module name, its message
                        buffer will be accessed.</li>
                    <li><code>index</code>: <em>Type</em>: long, <em>Description</em>: Index of the message whose value
                        will be extracted from the buffer into a variable. When the index is negative, it indexes from
                        the back of the buffer. -1 is the last index of the buffer. At the last position is the last
                        received message.</li>
                </ul>
            </li>
        </ol>
        <h2 id="keywords-for-assertion-definition">Keywords for Assertion Definition</h2>
        <p>This set comprises keywords that allow the definition of assertions that must be met during testing.</p>
        <ol>
            <li><strong><code>assert_string</code> - Verifies if a variable contains the expected string.</strong>
                <ul>
                    <li><code>var_name</code>: <em>Type</em>: string, <em>Description</em>: Variable to perform the
                        assertion on.</li>
                    <li><code>expected</code>: <em>Type</em>: string, <em>Description</em>: The expected string.</li>
                    <li><code>mode</code>: <em>Type</em>: string | not required, <em>Description</em>: Comparison mode.
                        There are these modes: &quot;equals&quot;, &quot;contains&quot;, &quot;startswith&quot;,
                        &quot;endswith&quot;. (default: equals)</li>
                    <li><code>case_sensitive</code>: <em>Type</em>: boolean | not required, <em>Description</em>:
                        Determines if the comparison should be case sensitive. (default: true)</li>
                    <li><code>result</code>: <em>Type</em>: boolean | not required, <em>Description</em>: It determines
                        the expected outcome of the assertion. (default: true)</li>
                </ul>
            </li>
            <li><strong><code>assert_lower</code> - Checks if a numeric variable is lower than the expected
                    value.</strong>
                <ul>
                    <li><code>var_name</code>: <em>Type</em>: string, <em>Description</em>: Variable to perform the
                        assertion on.</li>
                    <li><code>value</code>: <em>Type</em>: float, <em>Description</em>: The upper limit for the variable
                        value.</li>
                    <li><code>result</code>: <em>Type</em>: boolean | not required, <em>Description</em>: It determines
                        the expected outcome of the assertion. (default: true)</li>
                </ul>
            </li>
            <li><strong><code>assert_larger</code> - Checks if a numeric variable is larger than the expected
                    value.</strong>
                <ul>
                    <li><code>var_name</code>: <em>Type</em>: string, <em>Description</em>: Variable to perform the
                        assertion on.</li>
                    <li><code>value</code>: <em>Type</em>: float, <em>Description</em>: The lower limit for the variable
                        value.</li>
                    <li><code>result</code>: <em>Type</em>: boolean | not required, <em>Description</em>: It determines
                        the expected outcome of the assertion. (default: true)</li>
                </ul>
            </li>
            <li><strong><code>assert_equals</code> - Checks if a variable equals the expected number. It&#39;s possible
                    to set a certain tolerance range.</strong>
                <ul>
                    <li><code>var_name</code>: <em>Type</em>: string, <em>Description</em>: Variable to perform the
                        assertion on.</li>
                    <li><code>value</code>: <em>Type</em>: float, <em>Description</em>: Expected value of the variable.
                    </li>
                    <li><code>tolerance</code>: <em>Type</em>: float, <em>Description</em>: Permissible deviation from
                        the expected value.</li>
                    <li><code>result</code>: <em>Type</em>: boolean | not required, <em>Description</em>: It determines
                        the expected outcome of the assertion. (default: true)</li>
                </ul>
            </li>
            <li><strong><code>assert_range</code> - Verifies if the sequence of received messages from two modules falls
                    within a specified segment. Simple comparison rules can also be defined for comparison.</strong>
                <ul>
                    <li><code>module1_name</code>: <em>Type</em>: string, <em>Description</em>: First module involved in
                        the assertion.</li>
                    <li><code>module2_name</code>: <em>Type</em>: string, <em>Description</em>: Second module involved
                        in the assertion.</li>
                    <li><code>start</code>: <em>Type</em>: integer, <em>Description</em>: Start index for the range
                        check.</li>
                    <li><code>count</code>: <em>Type</em>: integer, <em>Description</em>: Number of values to check
                        within the range.</li>
                    <li><code>rule</code>: <em>Type</em>: string, <em>Description</em>: Message content comparison rule.
                        Format is: <message separator>|<X>;<X>;... Where is <X> is # (equals), ? (arbitrary), number
                                        0-100 diff tolerance.</li>
                    <li><code>result</code>: <em>Type</em>: boolean | not required, <em>Description</em>: It determines
                        the expected outcome of the assertion. (default: true)</li>
                </ul>
            </li>
            <li><strong><code>assert_app_is_running</code> - Verifies if an external application is currently
                    running.</strong>
                <ul>
                    <li><code>default</code>: <em>Type</em>: boolean | not required, <em>Description</em>: It determines
                        the expected outcome of the assertion. (default: true)</li>
                </ul>
            </li>
            <li><strong><code>assert_module_is_running</code> - Verifies if a specific module is currently
                    running.</strong>
                <ul>
                    <li><code>module_name</code>: <em>Type</em>: string, <em>Description</em>: Name of module.</li>
                    <li><code>result</code>: <em>Type</em>: boolean | not required, <em>Description</em>: It determines
                        the expected outcome of the assertion. (default: true)</li>
                </ul>
            </li>
            <li><strong><code>assert_json</code> - Allows verification if the JSON object in a variable is identical to
                    the expected JSON object.</strong>
                <ul>
                    <li><code>var_name</code>: <em>Type</em>: string, <em>Description</em>: The name of the variable
                        containing the JSON object to be asserted.</li>
                    <li><code>expected</code>: <em>Type</em>: string, <em>Description</em>: The expected JSON object in
                        string format for comparison.</li>
                    <li><code>exact_mode</code>: <em>Type</em>: string, <em>Description</em>: Specifies a comparison
                        mode for JSON objects that requires strict equality between expected and actual JSON. If is
                        false, it only compares parameters that are in expected JSON. (default: false)</li>
                    <li><code>result</code>: <em>Type</em>: boolean | not required, <em>Description</em>: It determines
                        the expected outcome of the assertion. (default: true)</li>
                </ul>
            </li>
        </ol>
        <h2 id="keywords-for-working-with-modules">Keywords for Working with Modules</h2>
        <p>This set includes keywords that enable working with communication modules.</p>
        <ol>
            <li><strong><code>create_telnet_client</code> - Creates a module that launches a new virtual Telnet
                    client.</strong>
                <ul>
                    <li><code>name</code>: <em>Type</em>: string, <em>Description</em>: Unique name for the module.</li>
                    <li><code>host</code>: <em>Type</em>: string | not required, <em>Description</em>: Hostname or IP
                        address to connect to. (default: localhost)</li>
                    <li><code>port</code>: <em>Type</em>: integer | not required, <em>Description</em>: Port number on
                        the host to connect to. (default: 23)</li>
                </ul>
            </li>
            <li><strong><code>create_telnet_server</code> - Creates a module that launches a virtual Telnet
                    server.</strong>
                <ul>
                    <li><code>name</code>: <em>Type</em>: string, <em>Description</em>: Unique name for the module.</li>
                    <li><code>port</code>: <em>Type</em>: integer | not required, <em>Description</em>: Port number to
                        listen on. (default: 23)</li>
                </ul>
            </li>
            <li><strong><code>create_web_crawler</code> - Creates a module that launches a web crawler.</strong>
                <ul>
                    <li><code>name</code>: <em>Type</em>: string, <em>Description</em>: Unique name for the module.</li>
                    <li><code>start_url</code>: <em>Type</em>: string, <em>Description</em>: URL to start crawling from.
                    </li>
                    <li><code>max_depth</code>: <em>Type</em>: integer, <em>Description</em>: Maximum depth to crawl.
                    </li>
                    <li><code>analyzer</code>: <em>Type</em>: string, <em>Description</em>: Analyzer to use for parsing
                        the web pages.</li>
                </ul>
            </li>
            <li><strong><code>create_email_server</code> - Creates a module that launches a virtual email
                    server.</strong>
                <ul>
                    <li><code>name</code>: <em>Type</em>: string, <em>Description</em>: Unique name for the module.</li>
                    <li><code>port</code>: <em>Type</em>: integer, <em>Description</em>: Port number on which the email
                        server will listen.</li>
                </ul>
            </li>
            <li><strong><code>create_rest_tester</code> - Creates a module that launches an HTTP client for testing REST
                    APIs.</strong>
                <ul>
                    <li><code>name</code>: <em>Type</em>: string, <em>Description</em>: Unique name for the module.</li>
                    <li><code>url</code>: <em>Type</em>: string, <em>Description</em>: URL of the REST API to test.</li>
                    <li><code>request_type</code>: <em>Type</em>: string, <em>Description</em>: Type of HTTP request to
                        send (GET, POST, etc.).</li>
                    <li><code>content_type</code>: <em>Type</em>: string, <em>Description</em>: Data type in request.
                        (default: application/json).</li>
                </ul>
            </li>
            <li><strong><code>create_soap_tester</code> - Creates a module for testing SOAP services.</strong>
                <ul>
                    <li><code>name</code>: <em>Type</em>: string, <em>Description</em>: Unique name for the module.</li>
                    <li><code>url</code>: <em>Type</em>: string, <em>Description</em>: URL of the SOAP service to test.
                    </li>
                </ul>
            </li>
            <li><strong><code>create_mqtt_client</code> - Creates a module that launches a virtual MQTT client.</strong>
                <ul>
                    <li><code>name</code>: <em>Type</em>: string, <em>Description</em>: Unique name for the module.</li>
                    <li><code>topics</code>: <em>Type</em>: array | not required, <em>Description</em>: List of topics
                        to subscribe to. (default: empty)</li>
                    <li><code>broker_url</code>: <em>Type</em>: string | not required, <em>Description</em>: URL of the
                        MQTT broker to connect to. (default: tcp://localhost:1883)</li>
                </ul>
            </li>
            <li><strong><code>create_mqtt_broker</code> - Creates a module that launches an MQTT broker.</strong>
                <ul>
                    <li><code>name</code>: <em>Type</em>: string, <em>Description</em>: Unique name for the module.</li>
                    <li><code>port</code>: <em>Type</em>: integer | not required, <em>Description</em>: Port number for
                        the MQTT broker. (default: 1883)</li>
                </ul>
            </li>
            <li><strong><code>termite_module</code> - Terminates a running module that is no longer needed.</strong>
                <ul>
                    <li><code>default</code>: <em>Type</em>: string, <em>Description</em>: Name of the module to
                        terminate.</li>
                </ul>
            </li>
            <li><strong><code>module_send</code> - Sends a message using a specific module.</strong>
                <ul>
                    <li><code>name</code>: <em>Type</em>: string, <em>Description</em>: Name of the sending module.</li>
                    <li><code>message</code>: <em>Type</em>: string, <em>Description</em>: Message to send.</li>
                    <li><code>delay</code>: <em>Type</em>: long, <em>Description</em>: Delay with which the message will
                        be sent.</li>
                </ul>
            </li>
            <li><strong><code>create_filter_action</code> - Creates a filter for actions triggered upon message
                    reception. Text content can be filtered.</strong>
                <ul>
                    <li><code>name</code>: <em>Type</em>: string, <em>Description</em>: Name of module.</li>
                    <li><code>text</code>: <em>Type</em>: string, <em>Description</em>: Text to filter on.</li>
                    <li><code>tag</code>: <em>Type</em>: string | not required, <em>Description</em>: Tag of message.
                        (default: &quot;&quot;)</li>
                    <li><code>mode</code>: <em>Type</em>: string | not required, <em>Description</em>: Filter mode.
                        There are this modes: &quot;equals&quot;, &quot;contains&quot;, &quot;startswith&quot;,
                        &quot;endswith&quot;. (default: equals)</li>
                    <li><code>case_sensitive | not required</code>: <em>Type</em>: boolean, <em>Description</em>:
                        Whether the filter should be case sensitive. (default: true)</li>
                </ul>
            </li>
            <li><strong><code>clear_filter_actions</code> - Removes all action filters for a specific module.</strong>
                <ul>
                    <li><code>default</code>: <em>Type</em>: string, <em>Description</em>: Name of module.</li>
                </ul>
            </li>
        </ol>
        <h1 id="-working-with-communication-modules">📦 Working with Communication Modules</h1>
        <p>Each module has its specific behavior and ways in which it needs to be handled. This section describes each
            of them and the methods to properly utilize their functionality when writing testing configurations.</p>
        <p>Upon receiving a message by any module, its content is appropriately processed and inserted into the message
            buffer. In all cases, the content of this last received message is also stored in a variable with the
            following name format: &quot;<module-name>-last-msg&quot;. Using this variable can significantly simplify
                configuration writing in certain cases.</p>
        <h2 id="external-application-launcher">External Application Launcher</h2>
        <p>This module is automatically created before the actual testing begins, and it&#39;s not necessary to create
            it manually. It&#39;s not possible to create multiple instances of this module.</p>
        <p>For message sending use <strong>&#39;standard_stream_send&#39;</strong> instead of
            <strong>&#39;module_send&#39;</strong>.</p>
        <p>Messages received by this module are inserted into the message buffer. The tag of each inserted message is
            set to an empty value.</p>
        <h2 id="telnet-client-module">Telnet Client Module</h2>
        <p>This module must be created before its functionalities are utilized during testing. Multiple instances of
            this module can exist within a testing suite. The same applies to all other modules unless stated otherwise.
        </p>
        <p>Messages sent using the &#39;module_send&#39; keyword to this module <strong>don&#39;t require any specific
                format</strong>. It sends any passed text string.</p>
        <p>Messages received by this module are inserted into the message buffer. The tag of each inserted message is
            set to an empty value.</p>
        <h2 id="telnet-server-module">Telnet Server Module</h2>
        <p>For the Telnet server, messages sent using the &#39;module_send&#39; keyword <strong>don&#39;t require any
                specific format</strong>. It sends any passed text string to all connected clients.</p>
        <p>All messages from clients received by this module are inserted into the message buffer. The tag of each
            inserted message is set to the ID of the client that sent the message. The client ID follows the format
            <strong>&quot;client-#&quot;</strong> where <strong>#</strong> represents the client number. The client
            number depends on the order in which they connected to the server. The first connected client will have the
            ID <strong>&quot;client-1&quot;</strong>, the second will have <strong>&quot;client-2&quot;</strong>, and so
            on.</p>
        <h2 id="smtp-email-server-module">SMTP Email Server Module</h2>
        <p>This module <strong>does not support sending</strong> messages using the &#39;module_send&#39; keyword. It
            only starts the email server and accepts emails.</p>
        <p>The content of all emails received by this module is inserted into the message buffer. The tag of each
            inserted message is set to the <strong>subject value</strong> of the respective email.</p>
        <h2 id="rest-tester-module">REST Tester Module</h2>
        <p>For the REST tester module, the message content sent using the &#39;module_send&#39; keyword must
            <strong>have a specific format</strong>. The text sent by this module can contain multiple parameters. For
            this purpose, the text in the message must be in the following format:
            <code><strong>(name_1)=(value_1);(name_2)=(value_2)</strong></code></p>
        <p>Where <strong>(name)</strong> is the parameter name to be inserted into the query string. If this
            name starts with the prefix <strong>&#39;#&#39;</strong>, its content will be inserted into the request
            body.
            All responses to requests from the server received by this module are inserted into the message buffer in
            <strong>JSON format</strong>. The tag of each inserted message is set to the <strong>endpoint
                address</strong> from which the response was received.</p>
        <h2 id="soap-tester-module">SOAP Tester Module</h2>
        <p>For the SOAP tester module, the message content sent using the &#39;module_send&#39; keyword must
            <strong>have a specific format</strong>. The sent request content must be in XML format, and its structure
            must be as required by the tested SOAP web service.
            The request can be entered manually or loaded directly from a prepared file, and the loaded content can be
            sent using this method. </p>
        <p>All responses to requests from the server received by this module are inserted into the message buffer. Each
            message is converted <strong>from XML to JSON format before insertion</strong>. The tag of each inserted
            message is set to the <strong>endpoint address</strong> from which the response was received.</p>
        <h2 id="mqtt-client-module">MQTT Client Module</h2>
        <p>For the MQTT client module, the message content sent using the &#39;module_send&#39; keyword must
            <strong>have a specific format</strong>. The message must specify the topic and the content of the message.
            The format is as follows: <code><strong>(topic):(Message)</strong></code></p>
        <p>Messages received by this module are inserted into the message buffer as they were received. The tag of each
            message is set to the value of the <strong>topic</strong> from which the message was received.</p>
        <h2 id="mqtt-broker-module">MQTT Broker Module</h2>
        <p>This module <strong>does not support</strong> sending messages using the &#39;module_send&#39; keyword. The
            module simply starts an MQTT broker and facilitates its operation. The module does not allow receiving
            incoming communication either. It acts solely as a mediator for MQTT communication between clients connected
            to it.</p>

    </div>

    <script>
        function gotoMain() {
            window.location.href = "/";
        }
    </script>
</body>

</html>