In my case the problem was that the @Test annotation was taken from wrong import.
Originally it was imported from org.junit.Test.
Once I have switched it to org.junit.jupiter.api.Test the problem was resolved.
Wrong original code:
import org.junit.Test;
@BeforeEach
...some code
@Test
...some code
Correct fixed code:
import org.junit.jupiter.api.Test;
@BeforeEach
...some code
@Test
...some code