1
votes

I try to generate a log which I want to contain all test suites and the number of test cases which are disabled by "-e --exclude tag". The problem I've faces is that disabled test does't run and doesn't generate log which could be used for solving this issue.

Example

TestSuite.txt

*** Test Cases ***

Test 1
    [Tags]  disabled
    Keyword_1
    Keyword_2
    ...

Test 2
    Keyword_1
    Keyword_2
    ...

Test 3
    [Tags]  disabled
    Keyword_1
    Keyword_2
    ...

Any suggestions?

1

1 Answers

0
votes

You cannot both exclude test and run it. A workaround might be to create a skiptest keyword to set tag to disabled and pass execution. This counts test as passed but shows number of disabled cases in tags.

*** Keywords ***
Skiptest
    Set Tags          disabled
    Pass Execution    This test is disabled

*** Test Cases ***
Normal Test
    [tags]    normal
    Should Be Equal    1      1

Disabled Test
    Skiptest
    Should Be Equal    1      2