Skip to content

Commit 7751f51

Browse files
committed
Update ClickHouseConfigTest.java
1 parent 186efac commit 7751f51

File tree

1 file changed

+3
-4
lines changed

1 file changed

+3
-4
lines changed

clickhouse-client/src/test/java/com/clickhouse/client/ClickHouseConfigTest.java

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -74,7 +74,7 @@ public void testCustomValues() {
7474
@Test(groups = { "unit" })
7575
public void testClientInfo() throws UnknownHostException {
7676
ClickHouseConfig config = new ClickHouseConfig();
77-
Assert.assertEquals(config.getProductVersion(), "unknown");
77+
Assert.assertEquals(config.getProductVersion(), ClickHouseClientOption.LATEST_KNOWN_VERSION);
7878
Assert.assertEquals(config.getProductRevision(), "unknown");
7979
Assert.assertEquals(config.getClientOsInfo(),
8080
System.getProperty("os.name") + "/" + System.getProperty("os.version"));
@@ -85,11 +85,10 @@ public void testClientInfo() throws UnknownHostException {
8585
Assert.assertEquals(config.getClientHost(), InetAddress.getLocalHost().getHostName());
8686

8787
Assert.assertEquals(ClickHouseClientOption.buildUserAgent(null, null),
88-
"ClickHouse-JavaClient/unknown (" + System.getProperty("os.name") + "/"
89-
+ System.getProperty("os.version") + "; " + System.getProperty("java.vm.name") + "/"
88+
"ClickHouse-JavaClient/"+ ClickHouseClientOption.PRODUCT_VERSION + " (" + System.getProperty("java.vm.name") + "/"
9089
+ System.getProperty("java.vendor.version",
9190
System.getProperty("java.vm.version", System.getProperty("java.version", "unknown")))
92-
+ "; rv:unknown)");
91+
+ ")");
9392
Assert.assertEquals(ClickHouseClientOption.buildUserAgent(null, null),
9493
ClickHouseClientOption.buildUserAgent("", null));
9594

0 commit comments

Comments
 (0)