allure2 icon indicating copy to clipboard operation
allure2 copied to clipboard

enable = false marked tests with testng is reporting as skipped on all test groups

Open derinbay opened this issue 6 years ago • 2 comments

Describe the bug Hello, I'm trying to manage my suites with testng and got a problem. I have a test class and have groups on all tests. This class is in the package of com.website.uat.mweb for example.

@Test(groups = {"uat"}) public void test1 {...} @Test(groups = {"uat"}) public void test2 {...} @Test(groups = {"other"}) public void test3 {...} @Test(groups = {"other"}, enabled = false) public void test4 {...}

As you see I have 2 groups and 1 of the tests are disabled.

And I have a suite file for other group as:

<!DOCTYPE suite SYSTEM "http://testng.org/testng-1.0.dtd">
<suite name="first_suite" configfailurepolicy="continue" parallel="methods">
    <test name="first_test" preserve-order="false">
        <groups>
            <run>
                <include name="other"/>
            </run>
        </groups>
        <packages>
            <package name="com.website.uat.mweb"></package>
        </packages>
    </test>
</suite>

Now when I execute this, testng results will be as expected: Total tests run: 2 Passes: 2, Failures: 0, Skips: 0

But in the allure reports I see also 1 skipped test (test3), despite that it's not in the running group..

Expected behavior I expect that test4 will not be in the report as skipped. It shouldn't be anywhere in the report.

Environment (please complete the following information):

Allure version 2.9.0
Test framework [email protected]
Allure adaptor [email protected]

derinbay avatar Jul 04 '20 18:07 derinbay

any updates ? I'm facing the same issue.

aLytvynFluke avatar Mar 30 '21 11:03 aLytvynFluke

https://allurereport.org/docs/testng-configuration/#alluretestnghidedisabledtests should help

baev avatar Apr 01 '24 20:04 baev