camel-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From acosent...@apache.org
Subject [camel] 11/16: CAMEL-11600:reverted too much (sigh...). Redo last commit on master
Date Thu, 17 May 2018 09:28:58 GMT
This is an automated email from the ASF dual-hosted git repository.

acosentino pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/camel.git

commit 0b58e3fa04d1b1062a5f38e6e83cff56fe050cc7
Author: Christian Ohr <christian.ohr@gmail.com>
AuthorDate: Wed May 16 16:39:01 2018 +0200

    CAMEL-11600:reverted too much (sigh...). Redo last commit on master
---
 .../java/org/apache/camel/component/metrics/CounterRouteTest.java   | 2 +-
 .../apache/camel/component/metrics/MetricsComponentRouteTest.java   | 4 ++--
 .../org/apache/camel/component/metrics/MetricsComponentTest.java    | 6 +++---
 3 files changed, 6 insertions(+), 6 deletions(-)

diff --git a/components/camel-metrics/src/test/java/org/apache/camel/component/metrics/CounterRouteTest.java
b/components/camel-metrics/src/test/java/org/apache/camel/component/metrics/CounterRouteTest.java
index 4804a2c..fcff3c0 100644
--- a/components/camel-metrics/src/test/java/org/apache/camel/component/metrics/CounterRouteTest.java
+++ b/components/camel-metrics/src/test/java/org/apache/camel/component/metrics/CounterRouteTest.java
@@ -154,7 +154,7 @@ public class CounterRouteTest {
     public void testOverrideIncrementAndDecrement() throws Exception {
         when(mockRegistry.counter("A")).thenReturn(mockCounter);
         endpoint.expectedMessageCount(1);
-        Map<String, Object> headers = new HashMap<String, Object>();
+        Map<String, Object> headers = new HashMap<>();
         headers.put(HEADER_COUNTER_INCREMENT, 912L);
         headers.put(HEADER_COUNTER_DECREMENT, 43219L);
         producer1.sendBodyAndHeaders(new Object(), headers);
diff --git a/components/camel-metrics/src/test/java/org/apache/camel/component/metrics/MetricsComponentRouteTest.java
b/components/camel-metrics/src/test/java/org/apache/camel/component/metrics/MetricsComponentRouteTest.java
index 26fadb8..0d50e9e 100644
--- a/components/camel-metrics/src/test/java/org/apache/camel/component/metrics/MetricsComponentRouteTest.java
+++ b/components/camel-metrics/src/test/java/org/apache/camel/component/metrics/MetricsComponentRouteTest.java
@@ -58,7 +58,7 @@ public class MetricsComponentRouteTest extends CamelTestSupport {
         mock.expectedBodiesReceived(body);
         mock.expectedHeaderReceived(header1, value1);
         mock.expectedHeaderReceived(header2, value2);
-        Map<String, Object> headers = new HashMap<String, Object>();
+        Map<String, Object> headers = new HashMap<>();
         headers.put(header1, value1);
         headers.put(header2, value2);
         template1.sendBodyAndHeaders(body, headers);
@@ -75,7 +75,7 @@ public class MetricsComponentRouteTest extends CamelTestSupport {
         mock.expectedHeaderReceived("." + HEADER_PREFIX, "value");
         mock.expectedHeaderReceived("date", now);
 
-        Map<String, Object> headers = new HashMap<String, Object>();
+        Map<String, Object> headers = new HashMap<>();
         headers.put(HEADER_METRIC_NAME, "a name");
         headers.put(HEADER_HISTOGRAM_VALUE, 34L);
         headers.put(HEADER_PREFIX + "notExistingHeader", "?");
diff --git a/components/camel-metrics/src/test/java/org/apache/camel/component/metrics/MetricsComponentTest.java
b/components/camel-metrics/src/test/java/org/apache/camel/component/metrics/MetricsComponentTest.java
index 906960e..e5bee00 100644
--- a/components/camel-metrics/src/test/java/org/apache/camel/component/metrics/MetricsComponentTest.java
+++ b/components/camel-metrics/src/test/java/org/apache/camel/component/metrics/MetricsComponentTest.java
@@ -69,7 +69,7 @@ public class MetricsComponentTest {
         component.setCamelContext(camelContext);
         when(camelContext.getRegistry()).thenReturn(camelRegistry);
         when(camelRegistry.lookupByNameAndType(MetricsComponent.METRIC_REGISTRY_NAME, MetricRegistry.class)).thenReturn(metricRegistry);
-        Map<String, Object> params = new HashMap<String, Object>();
+        Map<String, Object> params = new HashMap<>();
         Long value = System.currentTimeMillis();
         params.put("mark", value);
         Endpoint result = component.createEndpoint("metrics:meter:long.meter", "meter:long.meter",
params);
@@ -90,7 +90,7 @@ public class MetricsComponentTest {
         component.setCamelContext(camelContext);
         when(camelContext.getRegistry()).thenReturn(camelRegistry);
         when(camelRegistry.lookupByNameAndType(MetricsComponent.METRIC_REGISTRY_NAME, MetricRegistry.class)).thenReturn(metricRegistry);
-        Map<String, Object> params = new HashMap<String, Object>();
+        Map<String, Object> params = new HashMap<>();
         Long value = System.currentTimeMillis();
         params.put("mark", value);
         Endpoint result = component.createEndpoint("metrics:meter:long.meter", "meter:long.meter",
params);
@@ -101,7 +101,7 @@ public class MetricsComponentTest {
         assertThat(me.getMetricsName(), is("long.meter"));
         assertThat(me.getRegistry(), is(metricRegistry));
 
-        params = new HashMap<String, Object>();
+        params = new HashMap<>();
         params.put("increment", value + 1);
         params.put("decrement", value - 1);
 

-- 
To stop receiving notification emails like this one, please contact
acosentino@apache.org.

Mime
View raw message