citrusframework / citrusframework/citrus

Priority attribute ignored with Citrus base class

Open
#671 0 comments 0 reactions 0 assignees View on GitHub
Dominant language
Java
Stars
485
Forks
155
Avg merge
4d 22h
Merged PRs (30d)
6

Description

**Citrus Version**
2.7.4

**Expected behavior**
Using the folowwing code should run the tests in the order
test7
test5
test5

```
public class SimpleTest extends TestNGCitrusTestRunner {
@Test(priority = 0)
public void test7() {
System.out.println("7");
}
@Test(priority = 2)
public void test5() {
System.out.println("5");
}
@Test(priority = 1)
public void test4() {
System.out.println("4");
}
}
```

**Actual behavior**
The priority field is ignored

**Test case sample**
Using the Spring base class or none. The priority is used. But using the citrus one. It doesn't worked

```
@ContextConfiguration(locations = { "classpath:spring-test-config.xml" })
public class SimpleTest extends AbstractTestNGSpringContextTests {

@Test(priority = 0)
public void test7() {
System.out.println("7");
}

@Test(priority = 2)
public void test5() {
System.out.println("5");
}

@Test(priority = 1)
public void test4() {
System.out.println("4");
}
}

```

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.