Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(920)

Unified Diff: net/dns/mdns_query_unittest.cc

Issue 15733008: Multicast DNS implementation (initial) (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@mdns_implementation2
Patch Set: Created 7 years, 6 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: net/dns/mdns_query_unittest.cc
diff --git a/net/dns/mdns_query_unittest.cc b/net/dns/mdns_query_unittest.cc
deleted file mode 100644
index 56d75995edfa082dbc328e0771ec07901d7cf908..0000000000000000000000000000000000000000
--- a/net/dns/mdns_query_unittest.cc
+++ /dev/null
@@ -1,42 +0,0 @@
-// Copyright (c) 2011 The Chromium Authors. All rights reserved.
-// Use of this source code is governed by a BSD-style license that can be
-// found in the LICENSE file.
-
-#include "net/dns/mdns_query.h"
-#include "testing/gtest/include/gtest/gtest.h"
-
-namespace net {
-
-namespace {
-
-TEST(MDnsQueryTest, Constructor) {
- // This includes \0 at the end.
- const char qname_data[] = "\x03""www""\x07""example""\x03""com";
- const uint8 query_data[] = {
- // Header
- 0x00, 0x00,
- 0x00, 0x00, // Flags not set.
- 0x00, 0x01, // Set QDCOUNT (question count) to 1, all the
- // rest are 0 for a query.
- 0x00, 0x00,
- 0x00, 0x00,
- 0x00, 0x00,
-
- // Question
- 0x03, 'w', 'w', 'w', // QNAME: www.example.com in DNS format.
- 0x07, 'e', 'x', 'a', 'm', 'p', 'l', 'e',
- 0x03, 'c', 'o', 'm',
- 0x00,
-
- 0x00, 0x01, // QTYPE: A query.
- 0x00, 0x01, // QCLASS: IN class. Unicast bit not set.
- };
-
- base::StringPiece qname(qname_data, sizeof(qname_data));
- MDnsQuery q1(qname, dns_protocol::kTypeA);
-
- EXPECT_EQ(sizeof(query_data), q1.size());
- EXPECT_EQ(0, memcmp(q1.io_buffer()->data(), query_data, sizeof(query_data)));
-}
-}
-}
« net/dns/mdns_client_impl.cc ('K') | « net/dns/mdns_query.cc ('k') | net/net.gyp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698