From: JINMEI Tatuya Date: Wed, 27 Mar 2013 06:27:38 +0000 (-0700) Subject: [2562] update notifyWithoutSession test for the case where zonemgr not running. X-Git-Tag: bind10-1.1.0beta1-release~18^2~5 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=cdb550b4be0db3a37ca40426d288672615335cee;p=thirdparty%2Fkea.git [2562] update notifyWithoutSession test for the case where zonemgr not running. resetting "xfrin session" to NULL doesn't make much sense because it shouldn't happen in production case, so I simply updated the existing test case (and renamed it) rather than adding a new one. --- diff --git a/src/bin/auth/tests/auth_srv_unittest.cc b/src/bin/auth/tests/auth_srv_unittest.cc index 931d1e25fa..a478f4b746 100644 --- a/src/bin/auth/tests/auth_srv_unittest.cc +++ b/src/bin/auth/tests/auth_srv_unittest.cc @@ -868,10 +868,12 @@ TEST_F(AuthSrvTest, notifyWithErrorRcode) { Opcode::NOTIFY().getCode(), QR_FLAG | AA_FLAG, 1, 0, 0, 0); } -TEST_F(AuthSrvTest, notifyWithoutSession) { +TEST_F(AuthSrvTest, notifyWithoutRecipient) { updateInMemory(server, "example.", CONFIG_INMEMORY_EXAMPLE, false); - server.setXfrinSession(NULL); + // Emulate the case where msgq tells auth there's no Zonemgr module. + notify_session.setMessage(isc::config::createAnswer(CC_REPLY_NO_RECPT, + "no recipient")); UnitTestUtil::createRequestMessage(request_message, Opcode::NOTIFY(), default_qid, Name("example"),