aboutsummaryrefslogtreecommitdiffstats
path: root/contrib/libs/c-ares/test/ares-test-parse-ns.cc
diff options
context:
space:
mode:
authorshadchin <shadchin@yandex-team.ru>2022-02-17 23:09:13 +0300
committershadchin <shadchin@yandex-team.ru>2022-02-17 23:09:13 +0300
commit1e12ad07b2ad2362e06100f7f32e772e628bef66 (patch)
tree9981af0beb469cfef0d3d1658040f6bbf4206313 /contrib/libs/c-ares/test/ares-test-parse-ns.cc
parent55c6ad7179b9300375e9a16a3956dc706fcb560b (diff)
downloadydb-1e12ad07b2ad2362e06100f7f32e772e628bef66.tar.gz
Update c-ares from 0.16.1 to 0.17.2
MAKEAYAMLHAPPY-12345 ref:6a83ac3af883b2fc963128b7993f0a467b0000cb
Diffstat (limited to 'contrib/libs/c-ares/test/ares-test-parse-ns.cc')
-rw-r--r--contrib/libs/c-ares/test/ares-test-parse-ns.cc18
1 files changed, 9 insertions, 9 deletions
diff --git a/contrib/libs/c-ares/test/ares-test-parse-ns.cc b/contrib/libs/c-ares/test/ares-test-parse-ns.cc
index cd65318969..316492174c 100644
--- a/contrib/libs/c-ares/test/ares-test-parse-ns.cc
+++ b/contrib/libs/c-ares/test/ares-test-parse-ns.cc
@@ -10,7 +10,7 @@ namespace test {
TEST_F(LibraryTest, ParseNsReplyOK) {
DNSPacket pkt;
pkt.set_qid(0x1234).set_response().set_aa()
- .add_question(new DNSQuestion("example.com", ns_t_ns))
+ .add_question(new DNSQuestion("example.com", T_NS))
.add_answer(new DNSNsRR("example.com", 100, "ns.example.com"));
std::vector<byte> data = pkt.data();
@@ -26,7 +26,7 @@ TEST_F(LibraryTest, ParseNsReplyOK) {
TEST_F(LibraryTest, ParseNsReplyMultiple) {
DNSPacket pkt;
pkt.set_qid(10501).set_response().set_rd().set_ra()
- .add_question(new DNSQuestion("google.com", ns_t_ns))
+ .add_question(new DNSQuestion("google.com", T_NS))
.add_answer(new DNSNsRR("google.com", 59, "ns1.google.com"))
.add_answer(new DNSNsRR("google.com", 59, "ns2.google.com"))
.add_answer(new DNSNsRR("google.com", 59, "ns3.google.com"))
@@ -49,7 +49,7 @@ TEST_F(LibraryTest, ParseNsReplyMultiple) {
TEST_F(LibraryTest, ParseNsReplyErrors) {
DNSPacket pkt;
pkt.set_qid(0x1234).set_response().set_aa()
- .add_question(new DNSQuestion("example.com", ns_t_ns))
+ .add_question(new DNSQuestion("example.com", T_NS))
.add_answer(new DNSNsRR("example.com", 100, "ns.example.com"));
std::vector<byte> data;
struct hostent *host = nullptr;
@@ -58,24 +58,24 @@ TEST_F(LibraryTest, ParseNsReplyErrors) {
pkt.questions_.clear();
data = pkt.data();
EXPECT_EQ(ARES_EBADRESP, ares_parse_ns_reply(data.data(), data.size(), &host));
- pkt.add_question(new DNSQuestion("example.com", ns_t_ns));
+ pkt.add_question(new DNSQuestion("example.com", T_NS));
#ifdef DISABLED
// Question != answer
pkt.questions_.clear();
- pkt.add_question(new DNSQuestion("Axample.com", ns_t_ns));
+ pkt.add_question(new DNSQuestion("Axample.com", T_NS));
data = pkt.data();
EXPECT_EQ(ARES_ENODATA, ares_parse_ns_reply(data.data(), data.size(), &host));
pkt.questions_.clear();
- pkt.add_question(new DNSQuestion("example.com", ns_t_ns));
+ pkt.add_question(new DNSQuestion("example.com", T_NS));
#endif
// Two questions.
- pkt.add_question(new DNSQuestion("example.com", ns_t_ns));
+ pkt.add_question(new DNSQuestion("example.com", T_NS));
data = pkt.data();
EXPECT_EQ(ARES_EBADRESP, ares_parse_ns_reply(data.data(), data.size(), &host));
pkt.questions_.clear();
- pkt.add_question(new DNSQuestion("example.com", ns_t_ns));
+ pkt.add_question(new DNSQuestion("example.com", T_NS));
// Wrong sort of answer.
pkt.answers_.clear();
@@ -101,7 +101,7 @@ TEST_F(LibraryTest, ParseNsReplyErrors) {
TEST_F(LibraryTest, ParseNsReplyAllocFail) {
DNSPacket pkt;
pkt.set_qid(0x1234).set_response().set_aa()
- .add_question(new DNSQuestion("example.com", ns_t_ns))
+ .add_question(new DNSQuestion("example.com", T_NS))
.add_answer(new DNSCnameRR("example.com", 300, "c.example.com"))
.add_answer(new DNSNsRR("c.example.com", 100, "ns.example.com"));
std::vector<byte> data = pkt.data();