From d5cb6146394173e59d150050057751670015f4db Mon Sep 17 00:00:00 2001 From: Brett Wooldridge Date: Tue, 30 Aug 2016 21:19:33 +0900 Subject: [PATCH] Fix test failure caused by reformatting code --- .../metrics/prometheus/HikariCPCollectorTest.java | 11 ++++++----- 1 file changed, 6 insertions(+), 5 deletions(-) diff --git a/src/test/java/com/zaxxer/hikari/metrics/prometheus/HikariCPCollectorTest.java b/src/test/java/com/zaxxer/hikari/metrics/prometheus/HikariCPCollectorTest.java index a4d48a37..4aa1c1f4 100644 --- a/src/test/java/com/zaxxer/hikari/metrics/prometheus/HikariCPCollectorTest.java +++ b/src/test/java/com/zaxxer/hikari/metrics/prometheus/HikariCPCollectorTest.java @@ -65,6 +65,7 @@ public class HikariCPCollectorTest { try (HikariDataSource ds = new HikariDataSource(config); Connection connection1 = ds.getConnection()) { + assertThat(getValue("hikaricp_active_connections", "connection1"), is(1.0)); assertThat(getValue("hikaricp_idle_connections", "connection1"), is(0.0)); assertThat(getValue("hikaricp_pending_threads", "connection1"), is(0.0)); @@ -82,12 +83,12 @@ public class HikariCPCollectorTest { try (HikariDataSource ds = new HikariDataSource(config); Connection connection1 = ds.getConnection()) { + + assertThat(getValue("hikaricp_active_connections", "connectionClosed"), is(0.0)); + assertThat(getValue("hikaricp_idle_connections", "connectionClosed"), is(1.0)); + assertThat(getValue("hikaricp_pending_threads", "connectionClosed"), is(0.0)); + assertThat(getValue("hikaricp_connections", "connectionClosed"), is(1.0)); } - - assertThat(getValue("hikaricp_active_connections", "connectionClosed"), is(0.0)); - assertThat(getValue("hikaricp_idle_connections", "connectionClosed"), is(1.0)); - assertThat(getValue("hikaricp_pending_threads", "connectionClosed"), is(0.0)); - assertThat(getValue("hikaricp_connections", "connectionClosed"), is(1.0)); } private double getValue(String name, String poolName) {