From bc4573c4475f831181f13abff2eadbf3b5b7cd45 Mon Sep 17 00:00:00 2001 From: Jason Rhinelander Date: Sun, 17 May 2020 00:27:19 -0300 Subject: [PATCH] Disable empty string SockAddr throw test The code intentionally no longer throws and handles this as a special case (resulting in an empty SockAddr). --- test/net/test_sock_addr.cpp | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/test/net/test_sock_addr.cpp b/test/net/test_sock_addr.cpp index c0fc0948c..79bbe7116 100644 --- a/test/net/test_sock_addr.cpp +++ b/test/net/test_sock_addr.cpp @@ -58,7 +58,8 @@ TEST_CASE("SockAddr fromString", "[SockAddr]") CHECK_THROWS_WITH( llarp::SockAddr("0xFF.0xFF.0xFF.0xFF"), "0xFF.0xFF.0xFF.0xFF contains non-numeric values"); - CHECK_THROWS_WITH(llarp::SockAddr(""), "cannot construct IPv4 from empty string"); + // This *is* supported now; it gives you an empty address (same as default constructed). + //CHECK_THROWS_WITH(llarp::SockAddr(""), "cannot construct IPv4 from empty string"); CHECK_THROWS_WITH(llarp::SockAddr(" "), " is not a valid IPv4 address");