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

Update all tests to use JUnit 5 #310

Open
38 tasks
felixbarny opened this issue Nov 15, 2018 · 4 comments
Open
38 tasks

Update all tests to use JUnit 5 #310

felixbarny opened this issue Nov 15, 2018 · 4 comments
Labels
automation Tests & automation that help build & maintain the project chore technical-debt Technical debt

Comments

@felixbarny
Copy link
Member

felixbarny commented Nov 15, 2018

Now that testcontains supports JUnit 5, we should be able to update all remaining JUnit 4 tests to 5. The only thing which might be in the way that there is currently no way of having class-level parameters. But that is on JUnit's roadmap

Checklist

  • apm-agent-core

apm-agent-plugins/

  • apm-apache-httpclient/apm-apache-httpclient3-plugin
  • apm-apache-httpclient/apm-apache-httpclient4-plugin
  • apm-api-plugin
  • apm-ecs-logging-plugin
  • apm-es-restclient-plugin/apm-es-api-client-test
  • apm-es-restclient-plugin/apm-es-restclient-plugin-5_6
  • apm-es-restclient-plugin/apm-es-restclient-plugin-6_4
  • apm-es-restclient-plugin/apm-es-restclient-plugin-7_x
  • apm-finagle-httpclient-plugin
  • apm-httpclient-core
  • apm-java-concurrent-plugin
  • apm-jaxrs-plugin
  • apm-jaxrs-plugin-jakartaee-test
  • apm-jdbc-plugin
  • apm-jms-plugin/apm-jms-plugin-base
  • apm-jms-plugin/apm-jms-spring-plugin
  • apm-kafka-plugin/apm-kafka-base-plugin
  • apm-kafka-plugin/apm-kafka-headers-plugin
  • apm-kafka-plugin/apm-kafka-spring-plugin
  • apm-logging-plugin/apm-log4j2-plugin
  • apm-micrometer-plugin
  • apm-mongodb/apm-mongodb3-plugin
  • apm-mongodb/apm-mongodb4-plugin
  • apm-mongodb/apm-mongodb-common
  • apm-okhttp-test
  • apm-opentelemetry/apm-opentelemetry-plugin
  • apm-opentelemetry/apm-opentelemetry-test
  • apm-rabbitmq/apm-rabbitmq-spring
  • apm-redis-plugin/apm-lettuce-3-tests
  • apm-redis-plugin/apm-lettuce-plugin
  • apm-spring-resttemplate/apm-spring-resttemplate-plugin
  • apm-spring-webmvc-plugin
  • apm-urlconnection-plugin
  • apm-vertx/apm-vertx-common

integration-tests/

  • application-server-integration-tests
  • spring-boot-1-5
  • spring-boot-2/spring-boot-2-base
@yatsenko-julia
Copy link

I’ll work on this one.

@videnkz
Copy link
Contributor

videnkz commented Apr 30, 2019

reference: junit-team/junit5#878

@felixbarny felixbarny removed the good first issue Good for newcomers label May 12, 2019
@SylvainJuge SylvainJuge added the technical-debt Technical debt label Oct 10, 2019
@SylvainJuge SylvainJuge added automation Tests & automation that help build & maintain the project and removed [zube]: Backlog labels Feb 1, 2021
@SylvainJuge
Copy link
Member

@JonasKunz took the time to remove one of the main blockers we had to make progress on this topic: we can now run our "version integration tests" with JUnit 5 : #2962.

I have updated the issue description with a checklist of all the modules that still use Junit4.

@JonasKunz
Copy link
Contributor

The only thing which might be in the way that there is currently no way of having class-level parameters. But that is on JUnit's roadmap

Looks like this is still is open, currently parametrization is only possible on method level (JUnit Issue). I think we should be able to switch to method-level parametrized tests, however there will be problems in cases were we use inheritance to reuse common tests, e.g. AbstractHttpClientInstrumentationTest. Tests inheriting from this class can no longer be parametrized (e.g. our RestTemplate tests). Maybe using Test Templates might be a viable solution here for such general-purpose tests bases.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
automation Tests & automation that help build & maintain the project chore technical-debt Technical debt
Projects
None yet
Development

No branches or pull requests

7 participants