Skip to main content

Qase Robot Framework Plugin

Project description

Qase TestOps Robot Framework Reporter

License

Installation

pip install qase-robotframework

Upgrade from 2.x to 3.x

The new version 3.x of the Robot Framework reporter has breaking changes. To migrate from versions 2.x, follow the upgrade guide.

Configuration

Qase Robot Framework Reporter is configured in multiple ways:

  • using a config file qase.config.json
  • using environment variables

Environment variables override the values given in the config file.

Configuration options are described in the configuration reference.

Example: qase.config.json

{
  "mode": "testops",
  "fallback": "report",
  "debug": true,
  "testops": {
    "project": "YOUR_PROJECT_CODE",
    "api": {
      "token": "YOUR_API_TOKEN",
      "host": "qase.io"
    },
    "run": {
      "title": "Test run title"
    },
    "batch": {
      "size": 100
    }
  },
  "report": {
    "driver": "local",
    "connection": {
      "local": {
        "path": "./build/qase-report",
        "format": "json"
      }
    }
  },
  "environment": "local"
}

Usage

Link tests with test cases in Qase TestOps

To link the automated tests with the test cases in Qase TestOps, use the tags in form like Q-<case id without project code>. Example:

*** Test Cases ***
Push button
    [Tags]  q-2
    Push button    1
    Result should be    1

Push multiple buttons
    [Tags]  Q-3
    Push button    1
    Push button    2
    Result should be    12
*** Test Cases ***    Expression    Expected
Addition              12 + 2 + 2    16
                      2 + -3        -1
    [Tags]   Q-7

Subtraction           12 - 2 - 2    8
                      2 - -3        5
    [Tags]   Q-8

Working with steps

Listener supports reporting steps results:

Example:

Quick Get A JSON Body Test                                                  ## Test case: "Quick Get A JSON Body Test"
    [Tags]  Q-3
    ${response}=    GET  https://jsonplaceholder.typicode.com/posts/1       ## 1-st step - "GET"
    Should Be Equal As Strings    1  ${response.json()}[id]                 ## 2-nd step - "Should Be Equal As Strings"

Initializing the test case                                                  ## Test case: "Initializing the test case"
    [Tags]  q-4
    Set To Dictionary    ${info}   field1=A sample string                   ## 1-st step - "Set To Dictionary"

Working with parameters

Listener supports reporting parameters:

Example:

*** Variables ***
${var1}            1
${var2}            1
${var3}            2

*** Test Cases ***
Simple test
    [Arguments]    ${var1}    ${var2}   ${var3}
    [Tags]     qase.params:[var1, var2]
    Should Be Equal As Numbers    ${var1}    ${var2}
    Should Be Equal As Numbers    ${var3}    ${var3} 

Only var1 and var2 will be sent to Qase.

Execution:

robot --listener qase.robotframework.Listener someTest.robot

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

qase_robotframework-3.2.2.tar.gz (17.6 kB view details)

Uploaded Source

Built Distribution

qase_robotframework-3.2.2-py3-none-any.whl (16.6 kB view details)

Uploaded Python 3

File details

Details for the file qase_robotframework-3.2.2.tar.gz.

File metadata

  • Download URL: qase_robotframework-3.2.2.tar.gz
  • Upload date:
  • Size: 17.6 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/5.1.1 CPython/3.9.20

File hashes

Hashes for qase_robotframework-3.2.2.tar.gz
Algorithm Hash digest
SHA256 4f2fe78b15b3edbb636c7436dff6e61fd9519cf7c070f731b8809b9287402c2a
MD5 235b8fa8c7e8567f0611c0503ba5f601
BLAKE2b-256 5a152792ebfc7c4fcd817aa6512910c36231f6d7b9b6b85d71f9f188f48791e5

See more details on using hashes here.

File details

Details for the file qase_robotframework-3.2.2-py3-none-any.whl.

File metadata

File hashes

Hashes for qase_robotframework-3.2.2-py3-none-any.whl
Algorithm Hash digest
SHA256 910608d48c75c9469b72dd0feb845faf95b31dd0d06969fce0eff1ef6f32e139
MD5 362f906f5478b492b2f336f8242f4210
BLAKE2b-256 7d5868a1e60de0050c000562bc246f381a7546e23d69404b1472ae1dc2c98e51

See more details on using hashes here.

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page