Skip to content

Commit

Permalink
Replacing opentracing with opentelemetry in server tests
Browse files Browse the repository at this point in the history
  • Loading branch information
barancev committed Mar 7, 2020
1 parent 0d7e57a commit 4b8a481
Showing 1 changed file with 3 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@
import org.openqa.selenium.grid.session.SessionFactory;
import org.openqa.selenium.remote.Dialect;

import io.opentracing.noop.NoopTracerFactory;
import io.opentelemetry.trace.DefaultTracerFactory;

import java.util.Optional;

Expand All @@ -45,7 +45,7 @@ public void factoriesFoundViaServiceLoadersAreUsedFirst() {
Capabilities caps = new ImmutableCapabilities("browserName", "chrome");
DriverProvider provider = new StubbedProvider(caps, driver);

ActiveSessionFactory sessionFactory = new ActiveSessionFactory(NoopTracerFactory.create()) {
ActiveSessionFactory sessionFactory = new ActiveSessionFactory(DefaultTracerFactory.getInstance().get(ActiveSessionFactoryTest.class.getName())) {
@Override
protected Iterable<DriverProvider> loadDriverProviders() {
return ImmutableSet.of(provider);
Expand All @@ -62,7 +62,7 @@ protected Iterable<DriverProvider> loadDriverProviders() {
public void canBindNewFactoriesAtRunTime() {
ActiveSession session = Mockito.mock(ActiveSession.class);

ActiveSessionFactory sessionFactory = new ActiveSessionFactory(NoopTracerFactory.create())
ActiveSessionFactory sessionFactory = new ActiveSessionFactory(DefaultTracerFactory.getInstance().get(ActiveSessionFactoryTest.class.getName()))
.bind(caps ->
"cheese".equals(caps.getBrowserName()),
new SessionFactory() {
Expand Down

0 comments on commit 4b8a481

Please sign in to comment.