Lifecycle: Before: Given running Docker container After: Outcome: ANY Given a stopped container @Given("running $name container") public void startContainer(String name) throws URISyntaxException { .. It runs without any error but IDEA reports there are errors, check attached image: 