Question: I'm having a problem with following integration test

```
import org.junit.jupiter.api.Order;
import org.junit.jupiter.api.TestMethodOrder;
import org.junit.jupiter.api.MethodOrderer.OrderAnnotation;

@SpringBootTest
@ActiveProfiles("test")
@TestMethodOrder(OrderAnnotation.class)
public class FooServiceIT {
    @Test
    @Order(1)
    void testUploadSuccess() { ... }
    @Test
    @Order(2)
    void testDownloadSuccess() { ... }
    @Test
    @Order(3)
    void testDeleteSuccess() { ... }
}

```

I'd expect when I run the test that the execution order would 1, 2, 3 but for some reason, the actual execution order is 2, 3, 1.

Tbh, I'm clueless why the annotation is not working. I'm using Spring Boot 2.1.3 with JUnit 5.4.

Answer: 
I have faced the same issue. But, I found the problem where exactly is on my case. Wrongly import the "Order" class.

**Wrong One**

```
import org.springframework.core.annotation.Order;

```

**Right one**

```
*import org.junit.jupiter.api.Order;*

```

Also, please verify the following five classes with proper import

```
import org.junit.jupiter.api.Assertions;

import org.junit.jupiter.api.MethodOrderer.OrderAnnotation;

import org.junit.jupiter.api.Order;

import org.junit.jupiter.api.Test;

import org.junit.jupiter.api.TestMethodOrder;

```
For example, by using Spring Boot you can use **@FixMethodOrder(MethodSorters.JVM)** instead of **@TestMethodOrder(MethodOrderer.OrderAnnotation.class)**.
All of tests are run in the order they appear.

```
@FixMethodOrder(MethodSorters.JVM)
public class MyTest{

   @Test
   public void zzzz(){}

   @Test
   public void cccc(){}

   @Test
   public void aaaa(){}

   @Test
   public void bbbb(){}
}

```

Order execution is:

```
zzzz()
cccc()
aaaa()
bbbb()

```