diff --git a/java/server/src/org/openqa/selenium/grid/distributor/local/LocalDistributor.java b/java/server/src/org/openqa/selenium/grid/distributor/local/LocalDistributor.java index 90b00381f71ef..a2242eb9a8fae 100644 --- a/java/server/src/org/openqa/selenium/grid/distributor/local/LocalDistributor.java +++ b/java/server/src/org/openqa/selenium/grid/distributor/local/LocalDistributor.java @@ -277,7 +277,7 @@ private void refresh(NodeStatus status) { LOG.fine("Refreshing: " + status.getUri()); // check registrationSecret and stop processing if it doesn't match - if (! Objects.equals(status.getRegistrationSecret(), registrationSecret)) { + if (!Objects.equals(status.getRegistrationSecret(), registrationSecret)) { LOG.severe(String.format("Node at %s failed to send correct registration secret. Node NOT registered.", status.getUri())); bus.fire(new NodeRejectedEvent(status.getUri())); return; diff --git a/java/server/test/org/openqa/selenium/grid/distributor/AddingNodesTest.java b/java/server/test/org/openqa/selenium/grid/distributor/AddingNodesTest.java index 8674859bbe414..b329be8081eef 100644 --- a/java/server/test/org/openqa/selenium/grid/distributor/AddingNodesTest.java +++ b/java/server/test/org/openqa/selenium/grid/distributor/AddingNodesTest.java @@ -175,7 +175,7 @@ public void distributorShouldUpdateStateOfExistingNodeWhenNodePublishesStateChan status.getMaxSessionCount(), status.getStereotypes(), ImmutableSet.of(new NodeStatus.Active(CAPS, new SessionId(UUID.randomUUID()), CAPS)), - "cheese"); + null); bus.fire(new NodeStatusEvent(crafted)); diff --git a/java/server/test/org/openqa/selenium/grid/distributor/DistributorTest.java b/java/server/test/org/openqa/selenium/grid/distributor/DistributorTest.java index da4df78132b60..773babe7c393d 100644 --- a/java/server/test/org/openqa/selenium/grid/distributor/DistributorTest.java +++ b/java/server/test/org/openqa/selenium/grid/distributor/DistributorTest.java @@ -255,7 +255,7 @@ public void registeringTheCorrectRegistrationSecretWorks() latch.await(1, SECONDS); - assertThat(latch.getCount()).isEqualTo(1); + assertThat(latch.getCount()).isEqualTo(0); }