BIND 10 track1914, updated. a2be2f5cfe81a85df13a0ea977af6a9bddf3040b [1914] Fix tests
BIND 10 source code commits
bind10-changes at lists.isc.org
Thu May 17 15:27:43 UTC 2012
The branch, track1914 has been updated
via a2be2f5cfe81a85df13a0ea977af6a9bddf3040b (commit)
from 4aea6b74d6a48ee9e3666745ed7da416b31c2728 (commit)
Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.
- Log -----------------------------------------------------------------
commit a2be2f5cfe81a85df13a0ea977af6a9bddf3040b
Author: Michal 'vorner' Vaner <michal.vaner at nic.cz>
Date: Thu May 17 17:26:59 2012 +0200
[1914] Fix tests
The fake session didn't want to support hasQueuedMessages properly.
Also, we need to be subscribed to the correct group to actually get the
messages through the session.
-----------------------------------------------------------------------
Summary of changes:
src/lib/config/tests/ccsession_unittests.cc | 7 ++++++-
src/lib/config/tests/fake_session.cc | 2 +-
2 files changed, 7 insertions(+), 2 deletions(-)
-----------------------------------------------------------------------
diff --git a/src/lib/config/tests/ccsession_unittests.cc b/src/lib/config/tests/ccsession_unittests.cc
index 4238731..2cc6a37 100644
--- a/src/lib/config/tests/ccsession_unittests.cc
+++ b/src/lib/config/tests/ccsession_unittests.cc
@@ -722,7 +722,12 @@ protected:
AsyncReceiveCCSessionTest() :
mccs_(ccspecfile("spec29.spec"), session, NULL, NULL, false, false),
next_flag_(0)
- {}
+ {
+ // This is just to make sure the messages get through the fake
+ // session.
+ session.subscribe("test group");
+ session.subscribe("<ignored>");
+ }
/// \brief Convenience function to queue a request to get a command
/// message.
ModuleCCSession::AsyncRecvRequestID
diff --git a/src/lib/config/tests/fake_session.cc b/src/lib/config/tests/fake_session.cc
index bf4471d..65e12cd 100644
--- a/src/lib/config/tests/fake_session.cc
+++ b/src/lib/config/tests/fake_session.cc
@@ -207,7 +207,7 @@ FakeSession::reply(ConstElementPtr envelope, ConstElementPtr newmsg) {
bool
FakeSession::hasQueuedMsgs() const {
- return (false);
+ return (messages_ && messages_->size() > 0);
}
ConstElementPtr
More information about the bind10-changes
mailing list