typedb-driver icon indicating copy to clipboard operation
typedb-driver copied to clipboard

Upgrade cucumber to access @BeforeAll and @AfterAll

Open flyingsilverfin opened this issue 3 years ago • 1 comments

Problem to Solve

Our BDD test implementations currently have a hack to only run a part of the Before scenario hook once, protected by a boolean. This was caused by Cucumber's Java implementation not making @BeforeAll and @AfterAll available in the way JUnit does. However, as of https://github.com/cucumber/cucumber-jvm/pull/1876 it appears the Java Cucumber implementation offeres these hooks.

Proposed Solution

Replace the hack to run part of Before block only once using @BeforeAll and @AfterAll in new Cucumber releases.

flyingsilverfin avatar Dec 17 '21 16:12 flyingsilverfin

Let's find out the difference with @BeforeClass and @AfterClass

haikalpribadi avatar Jan 17 '22 10:01 haikalpribadi