Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Create a better way to run integration tests only on CI #38

Open
paullatzelsperger opened this issue Apr 15, 2021 · 0 comments
Open

Create a better way to run integration tests only on CI #38

paullatzelsperger opened this issue Apr 15, 2021 · 0 comments
Assignees

Comments

@paullatzelsperger
Copy link
Collaborator

currently we have integration tests that are annotated with @EnabledIfEnvironmentVariable(named = "CI", matches = "true") and then we need to evaluate the CI env var again in the @BeforeAll because that one still would get called.

@BeforeAll
public static void setup() {
     // this is necessary because the @EnabledIf... annotation does not prevent @BeforeAll to be called
     var isCi = propOrEnv("CI", "false");
     if(!Boolean.parseBoolean(isCi)) return;
}

Maybe this can be achieved with custom composed annotations (cf. Junit Docs)

@paullatzelsperger paullatzelsperger self-assigned this Apr 15, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant