Skip to content

Commit 28ecf61

Browse files
Martin Belangerigaw
authored andcommitted
test: Add more code coverage for nvme_ipaddrs_eq()
Signed-off-by: Martin Belanger <[email protected]>
1 parent 43cfb29 commit 28ecf61

1 file changed

Lines changed: 4 additions & 0 deletions

File tree

test/test-util.c

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -48,8 +48,12 @@ static bool test_ipaddrs_eq() {
4848
{x, x, true},
4949
{"::ffff:192.168.56.101", "::ffff:192.168.56.101", true},
5050
{"::ffff:192.168.56.101", "192.168.56.101", true},
51+
{"192.168.56.101", "::ffff:192.168.56.101", true},
5152
{"::ffff:192.168.56.222", "192.168.56.101", false},
53+
{"192.168.56.101", "::ffff:192.168.56.222", false},
5254
{"1.2.3.4", "192.168.56.101", false},
55+
{"!@#$", "192.168.56.101", false},
56+
{"192.168.56.101", "!@#$", false},
5357
{"2001:0db8:0001:0000:0000:ff00:0042:8329", "2001:0db8::ff00:0042:8329", false},
5458
{"2001:0db8:0001:0000:0000:ff00:0042:8329", NULL, false},
5559
};

0 commit comments

Comments
 (0)