summaryrefslogtreecommitdiffstats
path: root/net/base/net_util_unittest.cc
diff options
context:
space:
mode:
Diffstat (limited to 'net/base/net_util_unittest.cc')
-rw-r--r--net/base/net_util_unittest.cc8
1 files changed, 8 insertions, 0 deletions
diff --git a/net/base/net_util_unittest.cc b/net/base/net_util_unittest.cc
index 2293368..c4083dc 100644
--- a/net/base/net_util_unittest.cc
+++ b/net/base/net_util_unittest.cc
@@ -869,3 +869,11 @@ TEST(NetUtilTest, DISABLED_NetAddressToString_IPv6) {
EXPECT_EQ(std::string(tests[i].result), result);
}
}
+
+TEST(NetUtilTest, GetMyHostName) {
+ // We can't check the result of GetMyHostName() directly, since the result
+ // will differ across machines. Our goal here is to simply exercise the
+ // code path, and check that things "look about right".
+ std::string my_hostname = net::GetMyHostName();
+ EXPECT_FALSE(my_hostname.empty());
+}