You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@commons.apache.org by se...@apache.org on 2020/06/23 14:20:28 UTC
[commons-net] branch master updated: Add test for NET-675
This is an automated email from the ASF dual-hosted git repository.
sebb pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/commons-net.git
The following commit(s) were added to refs/heads/master by this push:
new 57af03c Add test for NET-675
57af03c is described below
commit 57af03c8cbece020780889f13b760d518ff1d0b5
Author: Sebb <se...@apache.org>
AuthorDate: Tue Jun 23 15:20:19 2020 +0100
Add test for NET-675
---
src/test/java/org/apache/commons/net/SubnetUtilsTest.java | 8 +++++++-
1 file changed, 7 insertions(+), 1 deletion(-)
diff --git a/src/test/java/org/apache/commons/net/SubnetUtilsTest.java b/src/test/java/org/apache/commons/net/SubnetUtilsTest.java
index c4d51c3..29c849b 100644
--- a/src/test/java/org/apache/commons/net/SubnetUtilsTest.java
+++ b/src/test/java/org/apache/commons/net/SubnetUtilsTest.java
@@ -204,7 +204,13 @@ public class SubnetUtilsTest extends TestCase {
assertEquals("255.255.255.255", info.getNetmask());
assertEquals(1, info.getAddressCount());
- new SubnetUtils("192.168.0.1/1");
+ }
+
+ public void testNET675() {
+ SubnetUtils utils = new SubnetUtils("192.168.0.15/32");
+ utils.setInclusiveHostCount(true);
+ SubnetInfo info = utils.getInfo();
+ assertTrue(info.isInRange("192.168.0.15"));
}
public void testInvalidMasks() {